diff --git a/CHANGES.rst b/CHANGES.rst index 3d243224..91847393 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -38,6 +38,9 @@ Changes in this release include the following: * Add missing ``wx.GetLocale`` function. (#572) +* Add methods to wx.TextCtrl for output "file-like" compatibility. (#578) + + diff --git a/etg/textctrl.py b/etg/textctrl.py index a825b0f7..e45cee34 100644 --- a/etg/textctrl.py +++ b/etg/textctrl.py @@ -98,6 +98,14 @@ def parseAndTweakModule(): #endif """) + # Methods for "file-like" compatibility + c.addCppMethod('void', 'write', '(const wxString* text)', + doc="Append text to the textctrl, for file-like compatibility.", + body="self->AppendText(*text);") + c.addCppMethod('void', 'flush', '()', + doc="NOP, for file-like compatibility.", + body="") + c = module.find('wxTextUrlEvent') tools.fixEventClass(c)