本文整理汇总了Python中wx.ID_OPEN属性的典型用法代码示例。如果您正苦于以下问题:Python wx.ID_OPEN属性的具体用法?Python wx.ID_OPEN怎么用?Python wx.ID_OPEN使用的例子?那么恭喜您, 这里精选的属性代码示例或许可以为您提供帮助。您也可以进一步了解该属性所在类wx
的用法示例。
在下文中一共展示了wx.ID_OPEN属性的13个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: OnSelect
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def OnSelect(self, event):
wildcard = "image source(*.jpg)|*.jpg|" \
"Compile Python(*.pyc)|*.pyc|" \
"All file(*.*)|*.*"
dialog = wx.FileDialog(None, "Choose a file", os.getcwd(),
"", wildcard, wx.ID_OPEN)
if dialog.ShowModal() == wx.ID_OK:
print(dialog.GetPath())
img = Image.open(dialog.GetPath())
imag = img.resize([64, 64])
image = np.array(imag)
result = evaluate_one_image(image)
result_text = wx.StaticText(self.pnl, label=result, pos=(320, 0))
font = result_text.GetFont()
font.PointSize += 8
result_text.SetFont(font)
self.initimage(name= dialog.GetPath())
# 生成图片控件
示例2: _init_coll_FileMenu_Items
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def _init_coll_FileMenu_Items(self, parent):
parent.Append(help='', id=wx.ID_NEW,
kind=wx.ITEM_NORMAL, text=_('New\tCTRL+N'))
parent.Append(help='', id=wx.ID_OPEN,
kind=wx.ITEM_NORMAL, text=_('Open\tCTRL+O'))
parent.Append(help='', id=wx.ID_CLOSE,
kind=wx.ITEM_NORMAL, text=_('Close\tCTRL+W'))
parent.AppendSeparator()
parent.Append(help='', id=wx.ID_SAVE,
kind=wx.ITEM_NORMAL, text=_('Save\tCTRL+S'))
parent.AppendSeparator()
parent.Append(help='', id=wx.ID_EXIT,
kind=wx.ITEM_NORMAL, text=_('Exit'))
self.Bind(wx.EVT_MENU, self.OnNewProjectMenu, id=wx.ID_NEW)
self.Bind(wx.EVT_MENU, self.OnOpenProjectMenu, id=wx.ID_OPEN)
self.Bind(wx.EVT_MENU, self.OnCloseProjectMenu, id=wx.ID_CLOSE)
self.Bind(wx.EVT_MENU, self.OnSaveProjectMenu, id=wx.ID_SAVE)
self.Bind(wx.EVT_MENU, self.OnQuitMenu, id=wx.ID_EXIT)
示例3: __init__
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def __init__(self, *args, **kwds):
# begin wxGlade: TemplateListDialog.__init__
kwds["style"] = wx.DEFAULT_DIALOG_STYLE
wx.Dialog.__init__(self, *args, **kwds)
self.template_names = wx.ListBox(self, wx.ID_ANY, choices=[])
self.template_name = wx.StaticText(self, wx.ID_ANY, _("wxGlade template:\n"))
self.author = wx.TextCtrl(self, wx.ID_ANY, "", style=wx.TE_READONLY)
self.description = wx.TextCtrl(self, wx.ID_ANY, "", style=wx.TE_MULTILINE | wx.TE_READONLY)
self.instructions = wx.TextCtrl(self, wx.ID_ANY, "", style=wx.TE_MULTILINE | wx.TE_READONLY)
self.btn_open = wx.Button(self, wx.ID_OPEN, "")
self.btn_edit = wx.Button(self, ID_EDIT, _("&Edit"))
self.btn_delete = wx.Button(self, wx.ID_DELETE, "")
self.btn_cancel = wx.Button(self, wx.ID_CANCEL, "")
self.__set_properties()
self.__do_layout()
self.Bind(wx.EVT_LISTBOX_DCLICK, self.on_open, self.template_names)
self.Bind(wx.EVT_LISTBOX, self.on_select_template, self.template_names)
self.Bind(wx.EVT_BUTTON, self.on_open, self.btn_open)
self.Bind(wx.EVT_BUTTON, self.on_edit, id=ID_EDIT)
self.Bind(wx.EVT_BUTTON, self.on_delete, self.btn_delete)
# end wxGlade
示例4: __init__
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def __init__(self):
super().__init__()
file_menu = wx.Menu()
new_menu_item = wx.MenuItem(file_menu, wx.ID_NEW, text="New", kind=wx.ITEM_NORMAL)
new_menu_item.SetBitmap(wx.Bitmap("new.gif"))
file_menu.Append(new_menu_item)
load_menu_item = wx.MenuItem(file_menu, wx.ID_OPEN, text="Open", kind=wx.ITEM_NORMAL)
load_menu_item.SetBitmap(wx.Bitmap("load.gif"))
file_menu.Append(load_menu_item)
file_menu.AppendSeparator()
save_menu_item = wx.MenuItem(file_menu, wx.ID_SAVE, text="Save", kind=wx.ITEM_NORMAL)
save_menu_item.SetBitmap(wx.Bitmap("save.gif"))
file_menu.Append(save_menu_item)
file_menu.AppendSeparator()
quit = wx.MenuItem(file_menu, wx.ID_EXIT, '&Quit\tCtrl+Q')
file_menu.Append(quit)
self.Append(file_menu, '&File')
drawing_menu = wx.Menu()
line_menu_item = wx.MenuItem(drawing_menu, PyDrawConstants.LINE_ID, text="Line", kind=wx.ITEM_NORMAL)
drawing_menu.Append(line_menu_item)
square_menu_item = wx.MenuItem(drawing_menu, PyDrawConstants.SQUARE_ID, text="Square", kind=wx.ITEM_NORMAL)
drawing_menu.Append(square_menu_item)
circle_menu_item = wx.MenuItem(drawing_menu, PyDrawConstants.CIRCLE_ID, text="Circle", kind=wx.ITEM_NORMAL)
drawing_menu.Append(circle_menu_item)
text_menu_item = wx.MenuItem(drawing_menu, PyDrawConstants.TEXT_ID, text="Text", kind=wx.ITEM_NORMAL)
drawing_menu.Append(text_menu_item)
self.Append(drawing_menu, '&Drawing')
示例5: command_menu_handler
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def command_menu_handler(self, command_event):
id = command_event.GetId()
if id == wx.ID_NEW:
print('Clear the drawing area')
self.clear_drawing()
elif id == wx.ID_OPEN:
print('Open a drawing file')
elif id == wx.ID_SAVE:
print('Save a drawing file')
elif id == wx.ID_EXIT:
print('Quite the application')
self.view.Close()
elif id == PyDrawConstants.LINE_ID:
print('set drawing mode to line')
self.set_line_mode()
elif id == PyDrawConstants.SQUARE_ID:
print('set drawing mode to square')
self.set_square_mode()
elif id == PyDrawConstants.CIRCLE_ID:
print('set drawing mode to circle')
self.set_circle_mode()
elif id == PyDrawConstants.TEXT_ID:
print('set drawing mode to Text')
self.set_text_mode()
else:
print('Unknown option', id)
示例6: _create_menu
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def _create_menu(self):
menubar = wx.MenuBar()
file = wx.Menu()
edit = wx.Menu()
help = wx.Menu()
file.Append(wx.ID_OPEN, '&Open', 'Open a schematic')
file.Append(wx.ID_SAVE, '&Save', 'Save the schematic')
file.AppendSeparator()
file.Append(103, '&Export BOM as CSV', 'Export the BOM as CSV')
file.AppendSeparator()
# Create a new submenu for recent files
recent = wx.Menu()
file.AppendSubMenu(recent, 'Recent')
self.filehistory.UseMenu(recent)
self.filehistory.AddFilesToMenu()
file.AppendSeparator()
quit = wx.MenuItem(file, 105, '&Quit\tCtrl+Q', 'Quit the Application')
file.AppendItem(quit)
edit.Append(201, 'Consolidate Components', 'Consolidate duplicated components')
menubar.Append(file, '&File')
menubar.Append(edit, '&Edit')
menubar.Append(help, '&Help')
self.SetMenuBar(menubar)
self.Bind(wx.EVT_MENU, self.on_quit, id=105)
self.Bind(wx.EVT_MENU, self.on_open, id=wx.ID_OPEN)
self.Bind(wx.EVT_MENU, self.on_consolidate, id=201)
self.Bind(wx.EVT_MENU, self.on_export, id=103)
self.Bind(wx.EVT_MENU, self.on_save, id=wx.ID_SAVE)
self.Bind(wx.EVT_MENU_RANGE, self.on_file_history,
id=wx.ID_FILE1, id2=wx.ID_FILE9)
示例7: _init_coll_FileMenu_Items
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def _init_coll_FileMenu_Items(self, parent):
parent.Append(help='', id=wx.ID_NEW,
kind=wx.ITEM_NORMAL, text=_('New\tCTRL+N'))
parent.Append(help='', id=wx.ID_OPEN,
kind=wx.ITEM_NORMAL, text=_('Open\tCTRL+O'))
parent.Append(help='', id=wx.ID_CLOSE,
kind=wx.ITEM_NORMAL, text=_('Close\tCTRL+W'))
parent.AppendSeparator()
parent.Append(help='', id=wx.ID_SAVE,
kind=wx.ITEM_NORMAL, text=_('Save\tCTRL+S'))
parent.Append(help='', id=wx.ID_SAVEAS,
kind=wx.ITEM_NORMAL, text=_('Save As...\tALT+S'))
parent.AppendSeparator()
parent.Append(help='', id=ID_OBJDICTEDITFILEMENUIMPORTEDS,
kind=wx.ITEM_NORMAL, text=_('Import EDS file'))
parent.Append(help='', id=ID_OBJDICTEDITFILEMENUEXPORTEDS,
kind=wx.ITEM_NORMAL, text=_('Export to EDS file'))
parent.Append(help='', id=ID_OBJDICTEDITFILEMENUEXPORTC,
kind=wx.ITEM_NORMAL, text=_('Build Dictionary\tCTRL+B'))
parent.AppendSeparator()
parent.Append(help='', id=wx.ID_EXIT,
kind=wx.ITEM_NORMAL, text=_('Exit'))
self.Bind(wx.EVT_MENU, self.OnNewMenu, id=wx.ID_NEW)
self.Bind(wx.EVT_MENU, self.OnOpenMenu, id=wx.ID_OPEN)
self.Bind(wx.EVT_MENU, self.OnCloseMenu, id=wx.ID_CLOSE)
self.Bind(wx.EVT_MENU, self.OnSaveMenu, id=wx.ID_SAVE)
self.Bind(wx.EVT_MENU, self.OnSaveAsMenu, id=wx.ID_SAVEAS)
self.Bind(wx.EVT_MENU, self.OnImportEDSMenu,
id=ID_OBJDICTEDITFILEMENUIMPORTEDS)
self.Bind(wx.EVT_MENU, self.OnExportEDSMenu,
id=ID_OBJDICTEDITFILEMENUEXPORTEDS)
self.Bind(wx.EVT_MENU, self.OnExportCMenu,
id=ID_OBJDICTEDITFILEMENUEXPORTC)
self.Bind(wx.EVT_MENU, self.OnQuitMenu, id=wx.ID_EXIT)
示例8: on_open
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def on_open(self, event):
self.selected_template = self.get_selected()
self.EndModal(wx.ID_OPEN)
示例9: select_template
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def select_template():
"Returns the filename of a template to load"
dlg = TemplateListDialog()
dlg.btn_delete.Hide()
dlg.btn_edit.Hide()
if dlg.ShowModal() == wx.ID_OPEN:
ret = dlg.selected_template
else:
ret = None
dlg.Destroy()
return ret
示例10: __init__
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def __init__(self, *args, **kwds):
# begin wxGlade: PyOgg3_MyDialog.__init__
kwds["style"] = wx.DEFAULT_DIALOG_STYLE | wx.RESIZE_BORDER
wx.Dialog.__init__(self, *args, **kwds)
self.notebook_1 = wx.Notebook(self, wx.ID_ANY)
self.notebook_1_pane_1 = wx.Panel(self.notebook_1, wx.ID_ANY)
self.text_ctrl_1 = wx.TextCtrl(self.notebook_1_pane_1, wx.ID_ANY, "")
self.button_3 = wx.Button(self.notebook_1_pane_1, wx.ID_OPEN, "")
self.notebook_1_pane_2 = wx.Panel(self.notebook_1, wx.ID_ANY)
self.radio_box_1 = wx.RadioBox(self.notebook_1_pane_2, wx.ID_ANY, _("Sampling Rate"), choices=[_("44 kbit"), _("128 kbit")], majorDimension=0, style=wx.RA_SPECIFY_ROWS)
self.notebook_1_pane_3 = wx.Panel(self.notebook_1, wx.ID_ANY)
self.text_ctrl_2 = wx.TextCtrl(self.notebook_1_pane_3, wx.ID_ANY, "", style=wx.TE_MULTILINE)
self.notebook_1_pane_4 = wx.Panel(self.notebook_1, wx.ID_ANY)
self.label_2 = wx.StaticText(self.notebook_1_pane_4, wx.ID_ANY, _("File name:"))
self.text_ctrl_3 = wx.TextCtrl(self.notebook_1_pane_4, wx.ID_ANY, "")
self.button_4 = wx.Button(self.notebook_1_pane_4, wx.ID_OPEN, "")
self.checkbox_1 = wx.CheckBox(self.notebook_1_pane_4, wx.ID_ANY, _("Overwrite existing file"))
self.static_line_1 = wx.StaticLine(self, wx.ID_ANY)
self.button_5 = wx.Button(self, wx.ID_CLOSE, "")
self.button_2 = wx.Button(self, wx.ID_CANCEL, "", style=wx.BU_TOP)
self.button_1 = wx.Button(self, wx.ID_OK, "", style=wx.BU_TOP)
self.__set_properties()
self.__do_layout()
self.Bind(wx.EVT_BUTTON, self.startConverting, self.button_1)
# end wxGlade
# manually added code
print( 'Dialog has been created at ', time.asctime() )
示例11: CreateMenuBar
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def CreateMenuBar(self):
# menu creation
menuBar = wx.MenuBar()
def AddMenuItem(name, func, itemId):
menu.Append(itemId, name)
self.Bind(wx.EVT_MENU, func, id=itemId)
# file menu
menu = wx.Menu()
menuBar.Append(menu, "&File")
AddMenuItem("&Open...\tCtrl+O", self.OnCmdOpen, wx.ID_OPEN)
AddMenuItem("&Save\tCtrl+S", self.OnCmdSave, wx.ID_SAVE)
menu.AppendSeparator()
AddMenuItem("E&xit\tAlt+F4", self.OnCmdExit, wx.ID_EXIT)
# edit menu
menu = wx.Menu()
menuBar.Append(menu, "&Edit")
AddMenuItem("&Undo\tCtrl+Z", self.OnCmdUndo, wx.ID_UNDO)
AddMenuItem("&Redo\tCtrl+Y", self.OnCmdRedo, wx.ID_REDO)
menu.AppendSeparator()
AddMenuItem("Cu&t\tCtrl+X", self.OnCmdCut, wx.ID_CUT)
AddMenuItem("&Copy\tCtrl+C", self.OnCmdCopy, wx.ID_COPY)
AddMenuItem("&Paste\tCtrl+V", self.OnCmdPaste, wx.ID_PASTE)
AddMenuItem("&Delete", self.OnCmdDelete, wx.ID_DELETE)
menu.AppendSeparator()
AddMenuItem(
"Find &Next Untranslated\tF3", self.OnCmdFindNext, wx.ID_FIND
)
# help menu
menu = wx.Menu()
menuBar.Append(menu, "&Help")
AddMenuItem("About Language Editor...", self.OnCmdAbout, wx.ID_ABOUT)
self.SetMenuBar(menuBar)
return menuBar
示例12: create_toolbar
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def create_toolbar(self):
# new, open, save, generate, add, delete, re-do, Layout 1, 2, 3, pin, help
# insert slot/page?
# Layout: Alt + 1,2,3
self.toolbar = tb = wx.ToolBar(self, -1)
self.SetToolBar(tb)
size = (21,21)
add = functools.partial(self._add_label_tool, tb, size)
t = add( wx.ID_NEW, "New", wx.ART_NEW, wx.ITEM_NORMAL, "Open a new file (Ctrl+N)")
self.Bind(wx.EVT_TOOL, self.new_app, t)
t = add( wx.ID_OPEN, "Open", wx.ART_FILE_OPEN, wx.ITEM_NORMAL, "Open a file (Ctrl+O)")
self.Bind(wx.EVT_TOOL, self.open_app, t)
t = add( wx.ID_SAVE, "Save", wx.ART_FILE_SAVE, wx.ITEM_NORMAL, "Save file (Ctrl+S)")
self.Bind(wx.EVT_TOOL, self.save_app, t)
if config.debugging and hasattr(wx, "ART_PLUS"):
t = add( wx.ID_SAVE, "Add", wx.ART_PLUS, wx.ITEM_NORMAL, "Add widget (Ctrl+A)")
t.Enable(False)
# XXX switch between wx.ART_DELETE for filled slots and wx.ART_MINUS for empty slots
t = add( wx.ID_SAVE, "Remove", wx.ART_MINUS, wx.ITEM_NORMAL, "Add widget (Ctrl+A)")
t.Enable(False)
tb.AddSeparator()
self._tool_redo = t = add( wx.ID_SAVE, "Re-do", wx.ART_REDO, wx.ITEM_NORMAL, "Re-do (Ctrl+Y)" )
t.Enable(False)
self._tool_repeat = t = add( wx.ID_SAVE, "Repeat", wx.ART_REDO, wx.ITEM_NORMAL, "Repeat (Ctrl+R)" )
t.Enable(False)
tb.AddSeparator()
t = add(-1, "Generate Code", wx.ART_EXECUTABLE_FILE, wx.ITEM_NORMAL, "Generate Code (Ctrl+G)" )
self.Bind(wx.EVT_TOOL, lambda event: common.root.generate_code(), t)
tb.AddSeparator()
t1 = add(-1, "Layout 1", "layout1.xpm", wx.ITEM_RADIO, "Switch layout: Tree",
"Switch layout: Palette and Properties left, Tree right")
self.Bind(wx.EVT_TOOL, lambda event: self.switch_layout(0), t1)
t2 = add(-1, "Layout 2", "layout2.xpm", wx.ITEM_RADIO,"Switch layout: Properties",
"Switch layout: Palette and Tree top, Properties bottom")
self.Bind(wx.EVT_TOOL, lambda event: self.switch_layout(1), t2)
t3 = add(-1, "Layout 3", "layout3.xpm", wx.ITEM_RADIO, "Switch layout: narrow",
"Switch layout: Palette, Tree and Properties on top of each other")
self.Bind(wx.EVT_TOOL, lambda event: self.switch_layout(2), t3)
self._layout_tools = [t1,t2,t3]
tb.AddSeparator()
t = add(-1, "Pin Design Window", "pin_design.xpm", wx.ITEM_CHECK, "Pin Design Window",
"Pin Design Window to stay on top")
self.Bind(wx.EVT_TOOL, lambda event: self.pin_design_window(), t)
self._t_pin_design_window = t
tb.AddSeparator()
t = add(wx.ID_HELP, "Help", wx.ART_HELP_BOOK, wx.ITEM_NORMAL, "Show manual (F1)")
self.Bind(wx.EVT_TOOL, self.show_manual, t)
self.toolbar.Realize()
示例13: _init_coll_FileMenu_Items
# 需要导入模块: import wx [as 别名]
# 或者: from wx import ID_OPEN [as 别名]
def _init_coll_FileMenu_Items(self, parent):
AppendMenu(parent, help='', id=wx.ID_NEW,
kind=wx.ITEM_NORMAL, text=_(u'New') + '\tCTRL+N')
AppendMenu(parent, help='', id=wx.ID_OPEN,
kind=wx.ITEM_NORMAL, text=_(u'Open') + '\tCTRL+O')
AppendMenu(parent, help='', id=wx.ID_CLOSE,
kind=wx.ITEM_NORMAL, text=_(u'Close Tab') + '\tCTRL+W')
AppendMenu(parent, help='', id=wx.ID_CLOSE_ALL,
kind=wx.ITEM_NORMAL, text=_(u'Close Project') + '\tCTRL+SHIFT+W')
parent.AppendSeparator()
AppendMenu(parent, help='', id=wx.ID_SAVE,
kind=wx.ITEM_NORMAL, text=_(u'Save') + '\tCTRL+S')
AppendMenu(parent, help='', id=wx.ID_SAVEAS,
kind=wx.ITEM_NORMAL, text=_(u'Save As...') + '\tCTRL+SHIFT+S')
AppendMenu(parent, help='', id=ID_PLCOPENEDITORFILEMENUGENERATE,
kind=wx.ITEM_NORMAL, text=_(u'Generate Program') + '\tCTRL+G')
AppendMenu(parent, help='', id=ID_PLCOPENEDITORFILEMENUGENERATEAS,
kind=wx.ITEM_NORMAL, text=_(u'Generate Program As...') + '\tCTRL+SHIFT+G')
parent.AppendSeparator()
AppendMenu(parent, help='', id=wx.ID_PAGE_SETUP,
kind=wx.ITEM_NORMAL, text=_(u'Page Setup') + '\tCTRL+ALT+P')
AppendMenu(parent, help='', id=wx.ID_PREVIEW,
kind=wx.ITEM_NORMAL, text=_(u'Preview') + '\tCTRL+SHIFT+P')
AppendMenu(parent, help='', id=wx.ID_PRINT,
kind=wx.ITEM_NORMAL, text=_(u'Print') + '\tCTRL+P')
parent.AppendSeparator()
AppendMenu(parent, help='', id=wx.ID_PROPERTIES,
kind=wx.ITEM_NORMAL, text=_(u'&Properties'))
parent.AppendSeparator()
AppendMenu(parent, help='', id=wx.ID_EXIT,
kind=wx.ITEM_NORMAL, text=_(u'Quit') + '\tCTRL+Q')
self.Bind(wx.EVT_MENU, self.OnNewProjectMenu, id=wx.ID_NEW)
self.Bind(wx.EVT_MENU, self.OnOpenProjectMenu, id=wx.ID_OPEN)
self.Bind(wx.EVT_MENU, self.OnCloseTabMenu, id=wx.ID_CLOSE)
self.Bind(wx.EVT_MENU, self.OnCloseProjectMenu, id=wx.ID_CLOSE_ALL)
self.Bind(wx.EVT_MENU, self.OnSaveProjectMenu, id=wx.ID_SAVE)
self.Bind(wx.EVT_MENU, self.OnSaveProjectAsMenu, id=wx.ID_SAVEAS)
self.Bind(wx.EVT_MENU, self.OnGenerateProgramMenu,
id=ID_PLCOPENEDITORFILEMENUGENERATE)
self.Bind(wx.EVT_MENU, self.OnGenerateProgramAsMenu,
id=ID_PLCOPENEDITORFILEMENUGENERATEAS)
self.Bind(wx.EVT_MENU, self.OnPageSetupMenu, id=wx.ID_PAGE_SETUP)
self.Bind(wx.EVT_MENU, self.OnPreviewMenu, id=wx.ID_PREVIEW)
self.Bind(wx.EVT_MENU, self.OnPrintMenu, id=wx.ID_PRINT)
self.Bind(wx.EVT_MENU, self.OnPropertiesMenu, id=wx.ID_PROPERTIES)
self.Bind(wx.EVT_MENU, self.OnQuitMenu, id=wx.ID_EXIT)
self.AddToMenuToolBar([(wx.ID_NEW, "new", _(u'New'), None),
(wx.ID_OPEN, "open", _(u'Open'), None),
(wx.ID_SAVE, "save", _(u'Save'), None),
(wx.ID_SAVEAS, "saveas", _(u'Save As...'), None),
(wx.ID_PRINT, "print", _(u'Print'), None),
(ID_PLCOPENEDITORFILEMENUGENERATE, "Build", _(u'Generate Program'), None)])