本文整理汇总了Python中wx.EmptyString方法的典型用法代码示例。如果您正苦于以下问题:Python wx.EmptyString方法的具体用法?Python wx.EmptyString怎么用?Python wx.EmptyString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类wx
的用法示例。
在下文中一共展示了wx.EmptyString方法的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: __init__
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def __init__(self, parent):
wx.Dialog.__init__(self, parent, id=wx.ID_ANY, title=u"控制台日志", pos=wx.DefaultPosition, size=wx.Size(500, 500),
style=wx.DEFAULT_DIALOG_STYLE)
self.SetSizeHints(wx.DefaultSize, wx.DefaultSize)
sizer_global = wx.BoxSizer(wx.VERTICAL)
self.textctrl_log = wx.TextCtrl(self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.Size(427, 381),
wx.TE_AUTO_URL | wx.TE_MULTILINE | wx.TE_PROCESS_ENTER | wx.TE_PROCESS_TAB)
# self.listctrl_log = ListCtrl_DLLog(self, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.LC_REPORT)
sizer_global.Add(self.textctrl_log, 1, wx.ALL | wx.EXPAND, 5)
self.SetSizer(sizer_global)
self.Layout()
self.Centre(wx.BOTH)
self.Bind(wx.EVT_CLOSE, self.onClose)
示例2: __init__
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def __init__( self, parent ):
wx.Frame.__init__ ( self, parent, id = wx.ID_ANY, title = u"Encrypted Files", pos = wx.DefaultPosition, size = wx.Size( 600,400 ), style = wx.DEFAULT_FRAME_STYLE|wx.TAB_TRAVERSAL )
self.SetSizeHints( wx.DefaultSize, wx.DefaultSize )
BodySizer = wx.BoxSizer( wx.VERTICAL )
self.m_panel4 = wx.Panel( self, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.TAB_TRAVERSAL )
TextCtrlSizer = wx.BoxSizer( wx.VERTICAL )
self.EncryptedFilesTextCtrl = wx.TextCtrl( self.m_panel4, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, wx.TE_DONTWRAP|wx.TE_MULTILINE|wx.TE_READONLY )
TextCtrlSizer.Add( self.EncryptedFilesTextCtrl, 1, wx.ALL|wx.EXPAND, 5 )
self.m_panel4.SetSizer( TextCtrlSizer )
self.m_panel4.Layout()
TextCtrlSizer.Fit( self.m_panel4 )
BodySizer.Add( self.m_panel4, 1, wx.EXPAND |wx.ALL, 5 )
self.SetSizer( BodySizer )
self.Layout()
self.Centre( wx.BOTH )
示例3: CreateMenuBar
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def CreateMenuBar(self):
# Create menu
m_menubar = wx.MenuBar(0)
# File menu
m_menuFile = wx.Menu()
m_menuItemQuit = wx.MenuItem(m_menuFile, wx.ID_ANY, u'&Quit' + u'\t' + u'Ctrl+Q',
wx.EmptyString, wx.ITEM_NORMAL)
m_menuFile.Append(m_menuItemQuit)
m_menubar.Append(m_menuFile, u'&File')
# About menu
m_menuAbout = wx.Menu()
m_menuItemAbout = wx.MenuItem(m_menuAbout, wx.ID_ANY, u'&About' + u'\t' + u'Shift+?',
wx.EmptyString, wx.ITEM_NORMAL)
m_menuAbout.Append(m_menuItemAbout)
m_menubar.Append(m_menuAbout, u'&Help')
# Set menu
self.SetMenuBar(m_menubar)
self.Bind(wx.EVT_MENU, self.OnMenuQuit, id=m_menuItemQuit.GetId())
self.Bind(wx.EVT_MENU, self.OnMenuAbout, id=m_menuItemAbout.GetId())
示例4: __init__
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def __init__( self, parent, id = wx.ID_ANY, pos = wx.DefaultPosition, size = wx.Size( 400,300 ), style = wx.TAB_TRAVERSAL, name = wx.EmptyString ):
wx.Panel.__init__ ( self, parent, id = id, pos = pos, size = size, style = style, name = name )
bSizer20 = wx.BoxSizer( wx.VERTICAL )
self.notebook = wx.Notebook( self, wx.ID_ANY, wx.DefaultPosition, wx.DefaultSize, wx.NB_TOP|wx.BORDER_DEFAULT )
bSizer20.Add( self.notebook, 1, wx.EXPAND |wx.ALL, 5 )
bSizer39 = wx.BoxSizer( wx.HORIZONTAL )
self.m_button41 = wx.Button( self, wx.ID_ANY, u"Save current settings", wx.DefaultPosition, wx.DefaultSize, 0|wx.BORDER_DEFAULT )
bSizer39.Add( self.m_button41, 0, wx.ALL, 5 )
bSizer39.Add( ( 50, 0), 0, wx.EXPAND, 5 )
self.m_button42 = wx.Button( self, wx.ID_ANY, u"Generate BOM", wx.DefaultPosition, wx.DefaultSize, 0|wx.BORDER_DEFAULT )
self.m_button42.SetDefault()
bSizer39.Add( self.m_button42, 0, wx.ALL, 5 )
self.m_button43 = wx.Button( self, wx.ID_CANCEL, u"Cancel", wx.DefaultPosition, wx.DefaultSize, 0|wx.BORDER_DEFAULT )
bSizer39.Add( self.m_button43, 0, wx.ALL, 5 )
bSizer20.Add( bSizer39, 0, wx.ALIGN_CENTER, 5 )
self.SetSizer( bSizer20 )
self.Layout()
# Connect Events
self.m_button41.Bind( wx.EVT_BUTTON, self.OnSaveSettings )
self.m_button42.Bind( wx.EVT_BUTTON, self.OnGenerateBom )
self.m_button43.Bind( wx.EVT_BUTTON, self.OnExit )
示例5: text_in_rect
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def text_in_rect(self):
wxr = wx.Rect(self.fromLeft.Value, self.fromTop.Value,
self.fromWidth.Value, self.fromHeight.Value)
r = self.wxRect_to_Rect(wxr)
text = wx.EmptyString
for b in self.text_blocks:
if fitz.Rect(b[:4]) in r:
text += b[4]
return text
示例6: initMenuItems
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def initMenuItems(self):
self.logs = wx.MenuItem(self, wx.ID_ANY, '&Logs\tF2', wx.EmptyString, wx.ITEM_NORMAL)
self.settings = wx.MenuItem(self, wx.ID_ANY, 'Settings', wx.EmptyString, wx.ITEM_NORMAL)
self.exit = wx.MenuItem(self, wx.ID_ANY, 'Exit', wx.EmptyString, wx.ITEM_NORMAL)
self.Append(self.logs)
self.AppendSeparator()
self.Append(self.settings)
self.AppendSeparator()
self.Append(self.exit)
示例7: initItems
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def initItems(self):
self.godownload = wx.MenuItem(self, wx.ID_ANY, u'下载所选项', wx.EmptyString, wx.ITEM_NORMAL)
self.Append(self.godownload)
self.AppendSeparator()
self.copylinks = wx.MenuItem(self, wx.ID_ANY, u'复制下载链接', wx.EmptyString, wx.ITEM_NORMAL)
self.Append(self.copylinks)
# self.copylinks.Enable(False)
示例8: initMenuItems
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def initMenuItems(self):
self.logs = wx.MenuItem(self, wx.ID_ANY, '&Logs\tF2', wx.EmptyString, wx.ITEM_NORMAL)
self.Append(self.logs)
self.AppendSeparator()
self.exit = wx.MenuItem(self, wx.ID_ANY, 'Exit', wx.EmptyString, wx.ITEM_NORMAL)
self.Append(self.exit)
示例9: initMenuItems
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def initMenuItems(self):
self.logs = wx.MenuItem(self, wx.ID_ANY, '&Logs\tF2', wx.EmptyString, wx.ITEM_NORMAL)
# self.parse.Enable(False)
self.settings = wx.MenuItem(self, wx.ID_ANY, 'Settings', wx.EmptyString, wx.ITEM_NORMAL)
# self.settings.Enable(False)
self.exit = wx.MenuItem(self, wx.ID_ANY, 'Exit', wx.EmptyString, wx.ITEM_NORMAL)
self.Append(self.logs)
self.AppendSeparator()
self.Append(self.settings)
self.AppendSeparator()
self.Append(self.exit)
示例10: OnContext
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def OnContext(self, event):
popup_menu = wx.Menu()
m_menuItemRenameBoard = wx.MenuItem(popup_menu, wx.ID_ANY,
u"Rename board (F2)", wx.EmptyString,
wx.ITEM_NORMAL)
popup_menu.Append(m_menuItemRenameBoard)
popup_menu.AppendSeparator()
m_menuItemAddBoard = wx.MenuItem(popup_menu, wx.ID_ANY,
u"Add board (Ctrl+B)", wx.EmptyString,
wx.ITEM_NORMAL)
popup_menu.Append(m_menuItemAddBoard)
m_menuItemRemoveBoard = wx.MenuItem(popup_menu, wx.ID_ANY,
u"Remove board (Ctrl+D)", wx.EmptyString,
wx.ITEM_NORMAL)
popup_menu.Append(m_menuItemRemoveBoard)
self.Bind(wx.EVT_MENU, self.OnBoardRenameClick, id=m_menuItemRenameBoard.GetId())
self.Bind(wx.EVT_MENU, self.OnBoardAddClick, id=m_menuItemAddBoard.GetId())
self.Bind(wx.EVT_MENU, self.OnBoardRemoveClick, id=m_menuItemRemoveBoard.GetId())
self.PopupMenu(popup_menu)
popup_menu.Destroy()
示例11: CreatePopupMenu
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def CreatePopupMenu(self):
# Create popupmenu
popup_menu = wx.Menu()
# Add Restore/Minimize menu
if self.frame.IsIconized():
menu_text = u"Restore"
else:
menu_text = u"Minimize"
m_menuItemRestore = wx.MenuItem(popup_menu, wx.ID_ANY, menu_text, wx.EmptyString,
wx.ITEM_NORMAL)
popup_menu.Append(m_menuItemRestore)
self.Bind(wx.EVT_MENU, self.OnTaskBarLeftClick, id=m_menuItemRestore.GetId())
# Add separator
popup_menu.AppendSeparator()
# Add toggle relays menu
for relay in range(8):
m_menuItemRelayToggle = wx.MenuItem(popup_menu, relay + 1,
u"Toggle relay {}".format(relay + 1),
wx.EmptyString,
wx.ITEM_NORMAL)
popup_menu.Append(m_menuItemRelayToggle)
self.Bind(wx.EVT_MENU, self.OnRelayClick, id=m_menuItemRelayToggle.GetId())
# Add separator
popup_menu.AppendSeparator()
# Add Quit menu
m_menuItemQuit = wx.MenuItem(popup_menu, wx.ID_ANY, u"Quit", wx.EmptyString,
wx.ITEM_NORMAL)
popup_menu.Append(m_menuItemQuit)
self.Bind(wx.EVT_MENU, self.OnClose, id=m_menuItemQuit.GetId())
# Return popupmenu
return popup_menu
示例12: __init__
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def __init__( self, parent ):
wx.Dialog.__init__ ( self, parent, id = wx.ID_ANY, title = wx.EmptyString, pos = wx.DefaultPosition, size = wx.Size( 292,103 ), style = wx.DEFAULT_DIALOG_STYLE )
self.SetSizeHintsSz( wx.DefaultSize, wx.DefaultSize )
bSizer45 = wx.BoxSizer( wx.VERTICAL )
bSizer45.AddSpacer( ( 0, 0), 1, wx.EXPAND, 5 )
bSizer46 = wx.BoxSizer( wx.HORIZONTAL )
self._statictextCommandName = wx.StaticText( self, wx.ID_ANY, u"Command Name", wx.DefaultPosition, wx.DefaultSize, 0 )
self._statictextCommandName.Wrap( -1 )
bSizer46.Add( self._statictextCommandName, 0, wx.ALL|wx.ALIGN_CENTER_VERTICAL, 5 )
self._textctrlCommandValue = wx.TextCtrl( self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0 )
self._textctrlCommandValue.SetExtraStyle( wx.WS_EX_VALIDATE_RECURSIVELY )
bSizer46.Add( self._textctrlCommandValue, 1, wx.ALL|wx.ALIGN_CENTER_VERTICAL, 5 )
bSizer45.Add( bSizer46, 0, wx.EXPAND, 5 )
bSizer47 = wx.BoxSizer( wx.HORIZONTAL )
bSizer47.AddSpacer( ( 0, 0), 1, wx.EXPAND, 5 )
self._buttonOK = wx.Button( self, wx.ID_ANY, u"OK", wx.DefaultPosition, wx.DefaultSize, 0 )
self._buttonOK.SetDefault()
bSizer47.Add( self._buttonOK, 0, wx.ALL|wx.ALIGN_CENTER_VERTICAL, 5 )
self._buttonCancel = wx.Button( self, wx.ID_ANY, u"Cancel", wx.DefaultPosition, wx.DefaultSize, 0 )
bSizer47.Add( self._buttonCancel, 0, wx.ALL|wx.ALIGN_CENTER_VERTICAL, 5 )
bSizer47.AddSpacer( ( 0, 0), 1, wx.EXPAND, 5 )
bSizer45.Add( bSizer47, 0, wx.EXPAND, 5 )
bSizer45.AddSpacer( ( 0, 0), 1, wx.EXPAND, 5 )
self.SetSizer( bSizer45 )
self.Layout()
self.Centre( wx.BOTH )
# Connect Events
self._buttonOK.Bind( wx.EVT_BUTTON, self._buttonOKOnButtonClick )
self._buttonCancel.Bind( wx.EVT_BUTTON, self._buttonCancelOnButtonClick )
示例13: __init__
# 需要导入模块: import wx [as 别名]
# 或者: from wx import EmptyString [as 别名]
def __init__( self, parent ):
wx.Dialog.__init__ ( self, parent, id = wx.ID_ANY, title = wx.EmptyString, pos = wx.DefaultPosition, size = wx.Size( 373,480 ), style = wx.DEFAULT_DIALOG_STYLE )
self.SetSizeHints( wx.DefaultSize, wx.DefaultSize )
bSizer2 = wx.BoxSizer( wx.VERTICAL )
self.m_staticText4 = wx.StaticText( self, wx.ID_ANY, u"Add copper pour keepout\nto selected traces.", wx.DefaultPosition, wx.DefaultSize, 0 )
self.m_staticText4.Wrap( -1 )
bSizer2.Add( self.m_staticText4, 0, wx.ALL, 5 )
bSizer5 = wx.BoxSizer( wx.HORIZONTAL )
self.m_bitmap = wx.StaticBitmap( self, wx.ID_ANY, wx.NullBitmap, wx.DefaultPosition, wx.DefaultSize, 0 )
bSizer5.Add( self.m_bitmap, 0, wx.ALL, 5 )
bSizer2.Add( bSizer5, 1, wx.EXPAND, 5 )
bSizer3 = wx.BoxSizer( wx.HORIZONTAL )
self.m_staticText5 = wx.StaticText( self, wx.ID_ANY, u"Zone clearance (mm)", wx.DefaultPosition, wx.DefaultSize, 0 )
self.m_staticText5.Wrap( -1 )
bSizer3.Add( self.m_staticText5, 0, wx.ALL, 5 )
self.m_clearance = wx.TextCtrl( self, wx.ID_ANY, wx.EmptyString, wx.DefaultPosition, wx.DefaultSize, 0 )
bSizer3.Add( self.m_clearance, 0, wx.ALL, 5 )
bSizer2.Add( bSizer3, 1, wx.EXPAND, 5 )
bSizer4 = wx.BoxSizer( wx.HORIZONTAL )
self.m_button_ok = wx.Button( self, wx.ID_OK, u"OK", wx.DefaultPosition, wx.DefaultSize, 0 )
bSizer4.Add( self.m_button_ok, 0, wx.ALL, 5 )
self.m_button_cancel = wx.Button( self, wx.ID_CANCEL, u"Cancel", wx.DefaultPosition, wx.DefaultSize, 0 )
bSizer4.Add( self.m_button_cancel, 0, wx.ALL, 5 )
bSizer2.Add( bSizer4, 1, wx.EXPAND, 5 )
self.SetSizer( bSizer2 )
self.Layout()
self.Centre( wx.BOTH )