Commit 3c208f5e authored by Hauptmech's avatar Hauptmech Committed by Wayne Stambaugh

Apply Hauptmech's patch to improve EESchema's menu and main toolbar.

* Improve main (top) toolbar button organization.
* Add commands from main toolbar to menubar that were not already defined.
parent c5c98f95
...@@ -156,8 +156,7 @@ void SCH_EDIT_FRAME::ReCreateMenuBar() ...@@ -156,8 +156,7 @@ void SCH_EDIT_FRAME::ReCreateMenuBar()
// Plot submenu // Plot submenu
ADD_MENUITEM_WITH_HELP_AND_SUBMENU( fileMenu, choice_plot_fmt, ADD_MENUITEM_WITH_HELP_AND_SUBMENU( fileMenu, choice_plot_fmt,
ID_GEN_PLOT, _( "&Plot" ), ID_GEN_PLOT, _( "&Plot" ),
_( _( "Plot schematic sheet in HPGL, PostScript or SVG format" ),
"Plot schematic sheet in HPGL, PostScript or SVG format" ),
plot_xpm ); plot_xpm );
// Separator // Separator
...@@ -484,6 +483,23 @@ void SCH_EDIT_FRAME::ReCreateMenuBar() ...@@ -484,6 +483,23 @@ void SCH_EDIT_FRAME::ReCreateMenuBar()
_( "Generate bill of materials" ), _( "Generate bill of materials" ),
tools_xpm ); tools_xpm );
// Separator
toolsMenu->AppendSeparator();
//Run CVPcb
ADD_MENUITEM_WITH_HELP( toolsMenu,
ID_TO_CVPCB,
_( "A&ssign component footprints" ),
_( "Run CVPcb" ),
cvpcb_xpm );
// Run PCBNew
ADD_MENUITEM_WITH_HELP( toolsMenu,
ID_TO_PCB,
_( "&Layout printed circuit board" ),
_( "Run PCBNew" ),
pcbnew_xpm );
// Help Menu: // Help Menu:
wxMenu* helpMenu = new wxMenu; wxMenu* helpMenu = new wxMenu;
......
...@@ -37,23 +37,24 @@ void SCH_EDIT_FRAME::ReCreateHToolbar() ...@@ -37,23 +37,24 @@ void SCH_EDIT_FRAME::ReCreateHToolbar()
m_HToolBar->AddTool( ID_SAVE_PROJECT, wxEmptyString, KiBitmap( save_project_xpm ), m_HToolBar->AddTool( ID_SAVE_PROJECT, wxEmptyString, KiBitmap( save_project_xpm ),
_( "Save schematic project" ) ); _( "Save schematic project" ) );
m_HToolBar->AddSeparator(); m_HToolBar->AddSeparator();
m_HToolBar->AddTool( ID_SHEET_SET, wxEmptyString, KiBitmap( sheetset_xpm ), m_HToolBar->AddTool( ID_SHEET_SET, wxEmptyString, KiBitmap( sheetset_xpm ),
_( "Page settings" ) ); _( "Page settings" ) );
m_HToolBar->AddSeparator(); m_HToolBar->AddSeparator();
m_HToolBar->AddTool( ID_TO_LIBRARY, wxEmptyString, KiBitmap( libedit_xpm ),
_( "Library editor" ) );
m_HToolBar->AddTool( ID_TO_LIBVIEW, wxEmptyString, KiBitmap( library_browse_xpm ),
_( "Library browser" ) );
m_HToolBar->AddSeparator(); m_HToolBar->AddTool( wxID_PRINT, wxEmptyString, KiBitmap( print_button_xpm ),
m_HToolBar->AddTool( ID_HIERARCHY, wxEmptyString, KiBitmap( hierarchy_nav_xpm ), _( "Print schematic" ) );
_( "Navigate schematic hierarchy" ) );
m_HToolBar->AddSeparator(); m_HToolBar->AddSeparator();
m_HToolBar->AddTool( wxID_CUT, wxEmptyString, KiBitmap( cut_button_xpm ), m_HToolBar->AddTool( wxID_CUT, wxEmptyString, KiBitmap( cut_button_xpm ),
_( "Cut selected item" ) ); _( "Cut selected item" ) );
...@@ -63,25 +64,27 @@ void SCH_EDIT_FRAME::ReCreateHToolbar() ...@@ -63,25 +64,27 @@ void SCH_EDIT_FRAME::ReCreateHToolbar()
m_HToolBar->AddTool( wxID_PASTE, wxEmptyString, KiBitmap( paste_xpm ), m_HToolBar->AddTool( wxID_PASTE, wxEmptyString, KiBitmap( paste_xpm ),
_( "Paste" ) ); _( "Paste" ) );
m_HToolBar->AddSeparator(); m_HToolBar->AddSeparator();
msg = AddHotkeyName( HELP_UNDO, s_Schematic_Hokeys_Descr, HK_UNDO, false ); msg = AddHotkeyName( HELP_UNDO, s_Schematic_Hokeys_Descr, HK_UNDO, false );
m_HToolBar->AddTool( wxID_UNDO, wxEmptyString, KiBitmap( undo_xpm ), msg ); m_HToolBar->AddTool( wxID_UNDO, wxEmptyString, KiBitmap( undo_xpm ), msg );
msg = AddHotkeyName( HELP_REDO, s_Schematic_Hokeys_Descr, HK_REDO, false ); msg = AddHotkeyName( HELP_REDO, s_Schematic_Hokeys_Descr, HK_REDO, false );
m_HToolBar->AddTool( wxID_REDO, wxEmptyString, KiBitmap( redo_xpm ), msg ); m_HToolBar->AddTool( wxID_REDO, wxEmptyString, KiBitmap( redo_xpm ), msg );
m_HToolBar->AddSeparator();
m_HToolBar->AddTool( wxID_PRINT, wxEmptyString, KiBitmap( print_button_xpm ),
_( "Print schematic" ) );
m_HToolBar->AddSeparator(); m_HToolBar->AddSeparator();
m_HToolBar->AddTool( ID_TO_CVPCB, wxEmptyString, KiBitmap( cvpcb_xpm ),
_( "Run Cvpcb" ) );
m_HToolBar->AddTool( ID_TO_PCB, wxEmptyString, KiBitmap( pcbnew_xpm ),
_( "Run pcbnew" ) ); msg = AddHotkeyName( HELP_FIND, s_Schematic_Hokeys_Descr, HK_FIND_ITEM, false );
m_HToolBar->AddTool( ID_FIND_ITEMS, wxEmptyString, KiBitmap( find_xpm ), msg );
m_HToolBar->AddSeparator(); m_HToolBar->AddSeparator();
msg = AddHotkeyName( HELP_ZOOM_IN, s_Schematic_Hokeys_Descr, HK_ZOOM_IN, false ); msg = AddHotkeyName( HELP_ZOOM_IN, s_Schematic_Hokeys_Descr, HK_ZOOM_IN, false );
m_HToolBar->AddTool( ID_ZOOM_IN, wxEmptyString, KiBitmap( zoom_in_xpm ), msg ); m_HToolBar->AddTool( ID_ZOOM_IN, wxEmptyString, KiBitmap( zoom_in_xpm ), msg );
...@@ -94,13 +97,26 @@ void SCH_EDIT_FRAME::ReCreateHToolbar() ...@@ -94,13 +97,26 @@ void SCH_EDIT_FRAME::ReCreateHToolbar()
msg = AddHotkeyName( HELP_ZOOM_FIT, s_Schematic_Hokeys_Descr, HK_ZOOM_AUTO, false ); msg = AddHotkeyName( HELP_ZOOM_FIT, s_Schematic_Hokeys_Descr, HK_ZOOM_AUTO, false );
m_HToolBar->AddTool( ID_ZOOM_PAGE, wxEmptyString, KiBitmap( zoom_fit_in_page_xpm ), msg ); m_HToolBar->AddTool( ID_ZOOM_PAGE, wxEmptyString, KiBitmap( zoom_fit_in_page_xpm ), msg );
m_HToolBar->AddSeparator(); m_HToolBar->AddSeparator();
msg = AddHotkeyName( HELP_FIND, s_Schematic_Hokeys_Descr, HK_FIND_ITEM, false );
m_HToolBar->AddTool( ID_FIND_ITEMS, wxEmptyString, KiBitmap( find_xpm ), msg );
m_HToolBar->AddTool( ID_HIERARCHY, wxEmptyString, KiBitmap( hierarchy_nav_xpm ),
_( "Navigate schematic hierarchy" ) );
m_HToolBar->AddSeparator(); m_HToolBar->AddSeparator();
m_HToolBar->AddTool( ID_GET_NETLIST, wxEmptyString, KiBitmap( netlist_xpm ),
_( "Generate netlist" ) );
m_HToolBar->AddTool( ID_TO_LIBRARY, wxEmptyString, KiBitmap( libedit_xpm ),
_( "Library editor - Create and edit components" ) );
m_HToolBar->AddTool( ID_TO_LIBVIEW, wxEmptyString, KiBitmap( library_browse_xpm ),
_( "Library browser - Browse components" ) );
m_HToolBar->AddSeparator();
m_HToolBar->AddTool( ID_GET_ANNOTATE, wxEmptyString, KiBitmap( annotate_xpm ), m_HToolBar->AddTool( ID_GET_ANNOTATE, wxEmptyString, KiBitmap( annotate_xpm ),
_( "Annotate schematic" ) ); _( "Annotate schematic" ) );
...@@ -108,9 +124,22 @@ void SCH_EDIT_FRAME::ReCreateHToolbar() ...@@ -108,9 +124,22 @@ void SCH_EDIT_FRAME::ReCreateHToolbar()
m_HToolBar->AddTool( ID_GET_ERC, wxEmptyString, KiBitmap( erc_xpm ), m_HToolBar->AddTool( ID_GET_ERC, wxEmptyString, KiBitmap( erc_xpm ),
_( "Perform electric rules check" ) ); _( "Perform electric rules check" ) );
m_HToolBar->AddTool( ID_GET_NETLIST, wxEmptyString, KiBitmap( netlist_xpm ),
_( "Generate netlist" ) );
m_HToolBar->AddTool( ID_GET_TOOLS, wxEmptyString, KiBitmap( tools_xpm ), m_HToolBar->AddTool( ID_GET_TOOLS, wxEmptyString, KiBitmap( tools_xpm ),
_( "Generate bill of materials and/or cross references" ) ); _( "Generate bill of materials and/or cross references" ) );
m_HToolBar->AddSeparator();
m_HToolBar->AddTool( ID_TO_CVPCB, wxEmptyString, KiBitmap( cvpcb_xpm ),
_( "Run CVPcb - Associate components and footprints" ) );
m_HToolBar->AddTool( ID_TO_PCB, wxEmptyString, KiBitmap( pcbnew_xpm ),
_( "Run PCBNew - Layout printed circuit board" ) );
m_HToolBar->AddTool( ID_BACKANNO_ITEMS, wxEmptyString, KiBitmap( import_footprint_names_xpm ), m_HToolBar->AddTool( ID_BACKANNO_ITEMS, wxEmptyString, KiBitmap( import_footprint_names_xpm ),
_( "Back annotate component foot prints" ) ); _( "Back annotate component foot prints" ) );
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment