def _add_edit_menu(self):
        """Adds the edit menu"""
        editMenu = wx.Menu()

        self._add_menu_item(editMenu, ide.ID_UNDO, ide.id_text_undo,
                            menu_icons.get_icon_undo())

        self._add_menu_item(editMenu, ide.ID_REDO, ide.id_text_redo,
                            menu_icons.get_icon_redo())

        editMenu.AppendSeparator()

        self._add_menu_item(editMenu, ide.ID_CUT, ide.id_text_cut,
                            menu_icons.get_icon_cut())

        self._add_menu_item(editMenu, ide.ID_COPY, ide.id_text_copy,
                            menu_icons.get_icon_copy())

        self._add_menu_item(editMenu, ide.ID_PASTE, ide.id_text_paste,
                            menu_icons.get_icon_paste())

        self._add_menu_item(editMenu, ide.ID_DELETE, ide.id_text_delete,
                            menu_icons.get_icon_delete())

        editMenu.AppendSeparator()

        self._add_menu_item(editMenu, ide.ID_SELECTALL, ide.id_text_selectall)

        self.Append(editMenu, "&Edit")
    def _add_edit_menu(self):
        """Adds the edit menu"""
        editMenu = wx.Menu()

        self._add_menu_item(editMenu, ide.ID_UNDO, ide.id_text_undo, menu_icons.get_icon_undo())

        self._add_menu_item(editMenu, ide.ID_REDO, ide.id_text_redo, menu_icons.get_icon_redo())

        editMenu.AppendSeparator()

        self._add_menu_item(editMenu, ide.ID_CUT, ide.id_text_cut, menu_icons.get_icon_cut())

        self._add_menu_item(editMenu, ide.ID_COPY, ide.id_text_copy, menu_icons.get_icon_copy())

        self._add_menu_item(editMenu, ide.ID_PASTE, ide.id_text_paste, menu_icons.get_icon_paste())

        self._add_menu_item(editMenu, ide.ID_DELETE, ide.id_text_delete, menu_icons.get_icon_delete())

        editMenu.AppendSeparator()

        self._add_menu_item(editMenu, ide.ID_SELECTALL, ide.id_text_selectall)

        self.Append(editMenu, "&Edit")
Exemple #3
0
    def __init__(self, *args, **kwargs):
        """Create the toolbar"""
        super(ToolBar, self).__init__(*args, **kwargs)
        self.SetToolBitmapSize((16, 16))
        self._add_toolbar_btn(ide.ID_NEW, ide.id_text_new,
                              menu_icons.get_icon_new())

        self._add_toolbar_btn(ide.ID_OPEN, ide.id_text_open,
                              menu_icons.get_icon_open())

        self._add_toolbar_btn(ide.ID_SAVE, ide.id_text_save,
                              menu_icons.get_icon_save())

        self._add_toolbar_btn(ide.ID_SAVEAS, ide.id_text_saveas,
                              menu_icons.get_icon_saveas())

        self.AddSeparator()

        self._add_toolbar_btn(ide.ID_CUT, ide.id_text_cut,
                              menu_icons.get_icon_cut())

        self._add_toolbar_btn(ide.ID_COPY, ide.id_text_copy,
                              menu_icons.get_icon_copy())

        self._add_toolbar_btn(ide.ID_PASTE, ide.id_text_paste,
                              menu_icons.get_icon_paste())

        self.AddSeparator()

        self._add_toolbar_btn(ide.ID_UNDO, ide.id_text_undo,
                              menu_icons.get_icon_undo())

        self._add_toolbar_btn(ide.ID_REDO, ide.id_text_redo,
                              menu_icons.get_icon_redo())

        self.Realize()