some demo tweaks
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@32787 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -226,15 +226,16 @@ class KeyLog(wx.ListCtrl, listmix.ListCtrlAutoWidthMixin):
|
||||
keycode = evt.GetKeyCode()
|
||||
keyname = keyMap.get(keycode, None)
|
||||
if keyname is None:
|
||||
if keycode < 256:
|
||||
if "unicode" in wx.PlatformInfo and keycode < 128:
|
||||
keyname = "\"" + unichr(evt.GetUnicodeKey()) + "\""
|
||||
|
||||
elif keycode < 256:
|
||||
if keycode == 0:
|
||||
keyname = "NUL"
|
||||
elif keycode < 27:
|
||||
keyname = "Ctrl-%s" % chr(ord('A') + keycode-1)
|
||||
else:
|
||||
keyname = "\"%s\"" % chr(keycode)
|
||||
elif "unicode" in wx.PlatformInfo:
|
||||
keyname = "\"" + unichr(keycode) + "\""
|
||||
else:
|
||||
keyname = "unknown (%s)" % keycode
|
||||
|
||||
|
@@ -88,7 +88,7 @@ class AnchorsDemoFrame(wx.Frame):
|
||||
self.leftCheckBox = wx.CheckBox(
|
||||
label='Left', id=ID_ANCHORSDEMOFRAMELEFTCHECKBOX,
|
||||
parent=self.mainPanel, name='leftCheckBox',
|
||||
size=(40, 16), style=0, pos=(8, 8)
|
||||
style=0, pos=(8, 8)
|
||||
)
|
||||
|
||||
self.leftCheckBox.SetConstraints(
|
||||
@@ -103,7 +103,7 @@ class AnchorsDemoFrame(wx.Frame):
|
||||
self.topCheckBox = wx.CheckBox(
|
||||
label='Top', id=ID_ANCHORSDEMOFRAMETOPCHECKBOX,
|
||||
parent=self.mainPanel, name='topCheckBox',
|
||||
size=(40, 16), style=0, pos=(88, 8)
|
||||
style=0, pos=(88, 8)
|
||||
)
|
||||
|
||||
self.topCheckBox.SetConstraints(
|
||||
@@ -118,7 +118,7 @@ class AnchorsDemoFrame(wx.Frame):
|
||||
self.rightCheckBox = wx.CheckBox(
|
||||
label='Right', id=ID_ANCHORSDEMOFRAMERIGHTCHECKBOX,
|
||||
parent=self.mainPanel, name='rightCheckBox',
|
||||
size=(48, 16), style=0, pos=(168, 8)
|
||||
style=0, pos=(168, 8)
|
||||
)
|
||||
|
||||
self.rightCheckBox.SetConstraints(
|
||||
@@ -133,7 +133,7 @@ class AnchorsDemoFrame(wx.Frame):
|
||||
self.bottomCheckBox = wx.CheckBox(
|
||||
label='Bottom', id=ID_ANCHORSDEMOFRAMEBOTTOMCHECKBOX,
|
||||
parent=self.mainPanel, name='bottomCheckBox',
|
||||
size=(56, 16), style=0, pos=(248, 8)
|
||||
style=0, pos=(248, 8)
|
||||
)
|
||||
|
||||
self.bottomCheckBox.SetConstraints(
|
||||
|
@@ -197,6 +197,7 @@ def runTest(frame, nb, log):
|
||||
|
||||
# make some styles
|
||||
ed.StyleSetSpec(stc.STC_STYLE_DEFAULT, "size:%d,face:%s" % (pb, face3))
|
||||
ed.StyleClearAll()
|
||||
ed.StyleSetSpec(1, "size:%d,bold,face:%s,fore:#0000FF" % (pb+2, face1))
|
||||
ed.StyleSetSpec(2, "face:%s,italic,fore:#FF0000,size:%d" % (face2, pb))
|
||||
ed.StyleSetSpec(3, "face:%s,bold,size:%d" % (face2, pb+2))
|
||||
|
Reference in New Issue
Block a user