From 9a92e83940cf51340329c9135ed9f66d39c47090 Mon Sep 17 00:00:00 2001 From: Robin Dunn Date: Fri, 21 Apr 2000 04:59:19 +0000 Subject: [PATCH] demo adjustments git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_2_BRANCH@7221 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775 --- utils/wxPython/demo/wxStyledTextCtrl_1.py | 15 ++++++++++----- 1 file changed, 10 insertions(+), 5 deletions(-) diff --git a/utils/wxPython/demo/wxStyledTextCtrl_1.py b/utils/wxPython/demo/wxStyledTextCtrl_1.py index d45087a264..3dd4a0b173 100644 --- a/utils/wxPython/demo/wxStyledTextCtrl_1.py +++ b/utils/wxPython/demo/wxStyledTextCtrl_1.py @@ -36,9 +36,13 @@ capabilities, (right click to try it out.) if wxPlatform == '__WXMSW__': face1 = 'Ariel' face2 = 'Times New Roman' + face3 = 'Courier New' + pb = 6 else: face1 = 'Helvetica' face2 = 'Times' + face3 = 'Courier' + pb = 10 #---------------------------------------------------------------------- @@ -50,10 +54,11 @@ def runTest(frame, nb, log): # make some styles - ed.StyleSetSpec(1, "size:9,bold,face:%s,fore:#0000FF" % face1) - ed.StyleSetSpec(2, "face:%s,italic,fore:#FF0000,size:8" % face2) - ed.StyleSetSpec(3, "face:%s,bold,size:9" % face2) - ed.StyleSetSpec(4, "face:%s,size:6" % face1) + ed.StyleSetSpec(wxSTC_STYLE_DEFAULT, "size:%d,face:%s" % (pb+2, face3)) + ed.StyleSetSpec(1, "size:%d,bold,face:%s,fore:#0000FF" % (pb+3, face1)) + ed.StyleSetSpec(2, "face:%s,italic,fore:#FF0000,size:%d" % (face2, pb+2)) + ed.StyleSetSpec(3, "face:%s,bold,size:%d" % (face2, pb+3)) + ed.StyleSetSpec(4, "face:%s,size:%d" % (face1, pb)) # now set some text to those styles... Normally this would be @@ -73,7 +78,7 @@ def runTest(frame, nb, log): # line numbers in the margin ed.SetMarginType(0, wxSTC_MARGIN_NUMBER) ed.SetMarginWidth(0, 22) - ed.StyleSetSpec(wxSTC_STYLE_LINENUMBER, "size:6,face:Ariel") + ed.StyleSetSpec(wxSTC_STYLE_LINENUMBER, "size:%d,face:%s" % (pb, face1)) # setup some markers ed.SetMarginType(1, wxSTC_MARGIN_SYMBOL)