Demo tweaks
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/branches/WX_2_4_BRANCH@18476 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -44,10 +44,14 @@ class TestPanel(wxPanel):
|
|||||||
wxSize(bmp.GetWidth()+10, bmp.GetHeight()+10))
|
wxSize(bmp.GetWidth()+10, bmp.GetHeight()+10))
|
||||||
EVT_BUTTON(self, 30, self.OnClick)
|
EVT_BUTTON(self, 30, self.OnClick)
|
||||||
|
|
||||||
|
|
||||||
def OnClick(self, event):
|
def OnClick(self, event):
|
||||||
self.log.write("Click! (%d)\n" % event.GetId())
|
self.log.write("Click! (%d)\n" % event.GetId())
|
||||||
|
##wxLogDebug("debug message")
|
||||||
|
|
||||||
|
|
||||||
|
## wxLog_SetLogLevel(wxLOG_Message) # ignore everything above wxLOG_Message
|
||||||
|
|
||||||
#----------------------------------------------------------------------
|
#----------------------------------------------------------------------
|
||||||
|
|
||||||
def runTest(frame, nb, log):
|
def runTest(frame, nb, log):
|
||||||
|
@@ -8,9 +8,7 @@ def runTest(frame, nb, log):
|
|||||||
data.EnableEffects(true)
|
data.EnableEffects(true)
|
||||||
font_colour = wxColour(255, 0, 0) # colour of font (red)
|
font_colour = wxColour(255, 0, 0) # colour of font (red)
|
||||||
data.SetColour(font_colour) # set colour
|
data.SetColour(font_colour) # set colour
|
||||||
##print data.GetColour()
|
|
||||||
dlg = wxFontDialog(frame, data)
|
dlg = wxFontDialog(frame, data)
|
||||||
dlg.SetSize((250,250))
|
|
||||||
if dlg.ShowModal() == wxID_OK:
|
if dlg.ShowModal() == wxID_OK:
|
||||||
data = dlg.GetFontData()
|
data = dlg.GetFontData()
|
||||||
font = data.GetChosenFont()
|
font = data.GetChosenFont()
|
||||||
|
@@ -10,11 +10,11 @@ class TestPanel( wxPanel ):
|
|||||||
|
|
||||||
# 1st group of controls:
|
# 1st group of controls:
|
||||||
self.group1_ctrls = []
|
self.group1_ctrls = []
|
||||||
radio1 = wxRadioButton( panel, -1, "Radio1", style = wxRB_GROUP )
|
radio1 = wxRadioButton( panel, -1, " Radio1 ", style = wxRB_GROUP )
|
||||||
text1 = wxTextCtrl( panel, -1, "" )
|
text1 = wxTextCtrl( panel, -1, "" )
|
||||||
radio2 = wxRadioButton( panel, -1, "Radio2" )
|
radio2 = wxRadioButton( panel, -1, " Radio2 " )
|
||||||
text2 = wxTextCtrl( panel, -1, "" )
|
text2 = wxTextCtrl( panel, -1, "" )
|
||||||
radio3 = wxRadioButton( panel, -1, "Radio3" )
|
radio3 = wxRadioButton( panel, -1, " Radio3 " )
|
||||||
text3 = wxTextCtrl( panel, -1, "" )
|
text3 = wxTextCtrl( panel, -1, "" )
|
||||||
self.group1_ctrls.append((radio1, text1))
|
self.group1_ctrls.append((radio1, text1))
|
||||||
self.group1_ctrls.append((radio2, text2))
|
self.group1_ctrls.append((radio2, text2))
|
||||||
@@ -22,11 +22,11 @@ class TestPanel( wxPanel ):
|
|||||||
|
|
||||||
# 2nd group of controls:
|
# 2nd group of controls:
|
||||||
self.group2_ctrls = []
|
self.group2_ctrls = []
|
||||||
radio4 = wxRadioButton( panel, -1, "Radio1", style = wxRB_GROUP )
|
radio4 = wxRadioButton( panel, -1, " Radio1 ", style = wxRB_GROUP )
|
||||||
text4 = wxTextCtrl( panel, -1, "" )
|
text4 = wxTextCtrl( panel, -1, "" )
|
||||||
radio5 = wxRadioButton( panel, -1, "Radio2" )
|
radio5 = wxRadioButton( panel, -1, " Radio2 " )
|
||||||
text5 = wxTextCtrl( panel, -1, "" )
|
text5 = wxTextCtrl( panel, -1, "" )
|
||||||
radio6 = wxRadioButton( panel, -1, "Radio3" )
|
radio6 = wxRadioButton( panel, -1, " Radio3 " )
|
||||||
text6 = wxTextCtrl( panel, -1, "" )
|
text6 = wxTextCtrl( panel, -1, "" )
|
||||||
self.group2_ctrls.append((radio4, text4))
|
self.group2_ctrls.append((radio4, text4))
|
||||||
self.group2_ctrls.append((radio5, text5))
|
self.group2_ctrls.append((radio5, text5))
|
||||||
@@ -97,7 +97,7 @@ def runTest( frame, nb, log ):
|
|||||||
#----------------------------------------------------------------------
|
#----------------------------------------------------------------------
|
||||||
|
|
||||||
|
|
||||||
overview = """
|
overview = """\
|
||||||
<html><body>
|
<html><body>
|
||||||
<P>
|
<P>
|
||||||
This demo shows how individual radio buttons can be used to build
|
This demo shows how individual radio buttons can be used to build
|
||||||
|
Reference in New Issue
Block a user