文章详情

  • 游戏榜单
  • 软件榜单
关闭导航
热搜榜
热门下载
热门标签
php爱好者> php文档>Custom Controls → PyColourChooser

Custom Controls → PyColourChooser

时间:2007-04-18  来源:wxPhoenix

overview = """\   The PyColourChooser component creates a colour chooser window
that is similar to the Microsoft Windows colour chooser dialog.
This dialog component is drawn in a panel, and thus can be
embedded inside any widget (although it cannot be resized).
This colour chooser may also be substituted for the colour
chooser on any platform that might have an ugly one :)
  """    
   
import wx
import wx.lib.colourchooser as colourchooser
  
  
class Frame(wx.Frame):
 
 def __init__(
  self, parent=None, id=wx.ID_ANY, title='wx.lib.colourchooser.PyColourChooser', pos=wx.DefaultPosition,
  size=wx.DefaultSize, style=wx.DEFAULT_FRAME_STYLE
  ):
  
  wx.Frame.__init__(self, parent, id, title, pos, size, style)
  self.SetIcon(wx.Icon('wxWidgets.ico', wx.BITMAP_TYPE_ICO))
  
  # panel = wx.Panel(self, wx.ID_ANY)
  colourChoose = colourchooser.PyColourChooser(self, wx.ID_ANY)
  # Attention!
  # Glanced at wxPython document, we found that PyColourChooser is the subclass
  # of Panel, so PyColourChooser can be directly built as Frame's child.
  # Of course, PyColourChooser is the panel, so it can be built as another panel's child.
  
  
  
def TestFrame():
 app = wx.PySimpleApp()
 frame = Frame(size=(480, 400))
 frame.Centre()
 frame.Show()
 app.MainLoop()
 
 
if __name__ == '__main__':
 TestFrame()
相关阅读 更多 +
排行榜 更多 +
辰域智控app

辰域智控app

系统工具 下载
网医联盟app

网医联盟app

运动健身 下载
汇丰汇选App

汇丰汇选App

金融理财 下载