mirror of
https://github.com/wxWidgets/Phoenix.git
synced 2026-01-05 03:20:08 +01:00
Add [Show|Hide]NativeCaret for MSW.
This commit is contained in:
@@ -76,6 +76,26 @@ def parseAndTweakModule():
|
||||
#endif
|
||||
""")
|
||||
|
||||
c.addCppMethod('bool', 'ShowNativeCaret', '(bool show = true)',
|
||||
doc="""\
|
||||
Turn on the widget's native caret on Windows.
|
||||
Ignored on other platforms.
|
||||
""",
|
||||
body="""\
|
||||
#ifdef __WXMSW__
|
||||
return self->ShowNativeCaret(show);
|
||||
#endif
|
||||
""")
|
||||
c.addCppMethod('bool', 'HideNativeCaret', '()',
|
||||
doc="""\
|
||||
Turn off the widget's native caret on Windows.
|
||||
Ignored on other platforms.
|
||||
""",
|
||||
body="""\
|
||||
#ifdef __WXMSW__
|
||||
return self->HideNativeCaret();
|
||||
#endif
|
||||
""")
|
||||
|
||||
c = module.find('wxTextUrlEvent')
|
||||
tools.fixEventClass(c)
|
||||
|
||||
@@ -93,6 +93,11 @@ class textctrl_Tests(wtc.WidgetTestCase):
|
||||
ta.URL
|
||||
|
||||
|
||||
def test_textctrlNativeCaret(self):
|
||||
t = wx.TextCtrl(self.frame)
|
||||
t.ShowNativeCaret
|
||||
t.HideNativeCaret
|
||||
|
||||
#---------------------------------------------------------------------------
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user