]>
git.saurik.com Git - wxWidgets.git/blob - wxPython/demo/ScrolledMessageDialog.py
   5 #--------------------------------------------------------------------------- 
   7 class TestPanel(wx
.Panel
): 
   8     def __init__(self
, parent
, log
): 
  10         wx
.Panel
.__init
__(self
, parent
, -1) 
  12         b 
= wx
.Button(self
, -1, "Create and Show a ScrolledMessageDialog", (50,50)) 
  13         self
.Bind(wx
.EVT_BUTTON
, self
.OnButton
, b
) 
  16     def OnButton(self
, evt
): 
  17         f 
= open("Main.py", "r") 
  21         dlg 
= wx
.lib
.dialogs
.ScrolledMessageDialog(self
, msg
, "message test") 
  26 #--------------------------------------------------------------------------- 
  29 def runTest(frame
, nb
, log
): 
  30     win 
= TestPanel(nb
, log
) 
  33 #--------------------------------------------------------------------------- 
  39 <code><b>ScrolledMessageDialog</b>(parent, msg, caption, pos=wx.DefaultPosition, size=(500,300))</code> 
  41 This class represents a message dialog that uses a wxTextCtrl to display the 
  42 message. This allows more flexible information display without having to be 
  43 as much concerned with layout requirements. A text file can simply be used  
  45 This dialog offers no special attributes or methods beyond those supported 
  50 if __name__ 
== '__main__': 
  53     run
.main(['', os
.path
.basename(sys
.argv
[0])] + sys
.argv
[1:])