]>
Commit | Line | Data |
---|---|---|
8fa876ca RD |
1 | # 11/21/2003 - Jeff Grimmett (grimmtooth@softhome.net) |
2 | # | |
3 | # o Updated for wx namespace | |
4 | # | |
cf694132 | 5 | |
8fa876ca | 6 | import wx |
cf694132 | 7 | |
cf694132 RD |
8 | #---------------------------------------------------------------------- |
9 | ||
8fa876ca | 10 | class TestPanel(wx.Panel): |
cf694132 | 11 | def __init__(self, parent, log): |
8fa876ca | 12 | wx.Panel.__init__(self, parent, -1) |
cf694132 RD |
13 | self.log = log |
14 | self.count = 0 | |
15 | ||
8fa876ca RD |
16 | wx.StaticText(self, -1, "This is a wxSlider.", (45, 15)) |
17 | ||
18 | slider = wx.Slider( | |
19 | self, 100, 25, 1, 100, (30, 60), (250, -1), | |
20 | wx.SL_HORIZONTAL | wx.SL_AUTOTICKS | wx.SL_LABELS | |
21 | ) | |
cf694132 | 22 | |
cf694132 RD |
23 | slider.SetTickFreq(5, 1) |
24 | ||
25 | ||
26 | ||
27 | #---------------------------------------------------------------------- | |
28 | ||
29 | def runTest(frame, nb, log): | |
30 | win = TestPanel(nb, log) | |
31 | return win | |
32 | ||
33 | #---------------------------------------------------------------------- | |
34 | ||
35 | ||
36 | ||
37 | ||
1e4a197e | 38 | overview = """\ |
8fa876ca RD |
39 | A slider is a control with a handle which can be pulled back and forth to |
40 | change the value. | |
cf694132 | 41 | |
8fa876ca RD |
42 | In Windows versions below Windows 95, a scrollbar is used to simulate the slider. |
43 | In Windows 95, the track bar control is used. | |
44 | ||
45 | """ | |
cf694132 RD |
46 | |
47 | ||
1e4a197e RD |
48 | if __name__ == '__main__': |
49 | import sys,os | |
50 | import run | |
51 | run.main(['', os.path.basename(sys.argv[0])]) | |
cf694132 | 52 |