]> git.saurik.com Git - wxWidgets.git/blame - wxPython/demo/PyColourChooser.py
Patch from Joe "shmengie" Brown joebrown@podiatryfl.com
[wxWidgets.git] / wxPython / demo / PyColourChooser.py
CommitLineData
8fa876ca
RD
1
2import wx
3import wx.lib.colourchooser as cc
1e4a197e
RD
4
5#---------------------------------------------------------------
6
8fa876ca 7class TestColourChooser(wx.Panel):
1e4a197e 8 def __init__(self, parent, log):
8fa876ca 9 wx.Panel.__init__(self, parent, -1)
1e4a197e
RD
10 self.log = log
11
d4b73b1b 12 chooser = cc.PyColourChooser(self, -1)
8fa876ca
RD
13 sizer = wx.BoxSizer(wx.VERTICAL)
14 sizer.Add(chooser, 0, wx.ALL, 25)
1e4a197e
RD
15
16 self.SetAutoLayout(True)
17 self.SetSizer(sizer)
18
19#---------------------------------------------------------------
20
21def runTest(frame, nb, log):
22 win = TestColourChooser(nb, log)
23 return win
24
25#---------------------------------------------------------------
26
27overview = """
d4b73b1b 28The PyColourChooser component creates a colour chooser window
1e4a197e
RD
29that is similar to the Microsoft Windows colour chooser dialog.
30This dialog component is drawn in a panel, and thus can be
31embedded inside any widget (although it cannot be resized).
32This colour chooser may also be substituted for the colour
33chooser on any platform that might have an ugly one :)
34
35How to use it
36------------------------------
37
d4b73b1b 38The demo (demo/PyColourChooser.py code shows how to display
1e4a197e
RD
39a colour chooser and retrieve its options.
40
41Contact and Author Info
42------------------------------
43
d4b73b1b 44PyColourChooser was written and is maintained by:
1e4a197e
RD
45
46 Michael Gilfix <mgilfix@eecs.tufts.edu>
47
d4b73b1b 48You can find the latest PyColourChooser code at
b881fc78 49http://sourceforge.net/projects/wxcolourchooser/. If you have
1e4a197e
RD
50any suggestions or want to submit a patch, please send
51it my way at: mgilfix@eecs.tufts.edu
52"""
53
54
55
56if __name__ == '__main__':
57 import sys,os
58 import run
8eca4fef 59 run.main(['', os.path.basename(sys.argv[0])] + sys.argv[1:])