Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
91530e7a
Commit
91530e7a
authored
Aug 24, 2010
by
Wayne Stambaugh
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added help menu item to copy bug report information to clipboard.
parent
80bc0ad6
Changes
11
Hide whitespace changes
Inline
Side-by-side
Showing
11 changed files
with
508 additions
and
416 deletions
+508
-416
about_kicad.cpp
common/about_kicad.cpp
+12
-3
basicframe.cpp
common/basicframe.cpp
+99
-12
menucfg.cpp
cvpcb/menucfg.cpp
+7
-7
menubar.cpp
eeschema/menubar.cpp
+49
-70
menubar_libedit.cpp
eeschema/menubar_libedit.cpp
+7
-4
tool_gerber.cpp
gerbview/tool_gerber.cpp
+9
-11
id.h
include/id.h
+3
-2
wxstruct.h
include/wxstruct.h
+19
-7
menubar.cpp
kicad/menubar.cpp
+5
-3
menubar_modedit.cpp
pcbnew/menubar_modedit.cpp
+290
-291
menubar_pcbframe.cpp
pcbnew/menubar_pcbframe.cpp
+8
-6
No files found.
common/about_kicad.cpp
View file @
91530e7a
...
@@ -63,7 +63,16 @@ void InitKiCadAbout( wxAboutDialogInfo& info )
...
@@ -63,7 +63,16 @@ void InitKiCadAbout( wxAboutDialogInfo& info )
* Check Operating System *
* Check Operating System *
**************************/
**************************/
#if defined __WINDOWS__
#if defined __WINDOWS__
description
<<
(
wxT
(
"on Windows"
)
);
description
<<
wxT
(
"on "
);
#if defined _WIN64
description
<<
wxT
(
"64 bit"
);
#else
description
<<
wxT
(
"32 bit"
);
#endif
description
<<
wxT
(
" Windows"
);
/* Check for wxMAC */
/* Check for wxMAC */
# elif defined __WXMAC__
# elif defined __WXMAC__
...
@@ -71,11 +80,11 @@ void InitKiCadAbout( wxAboutDialogInfo& info )
...
@@ -71,11 +80,11 @@ void InitKiCadAbout( wxAboutDialogInfo& info )
/* Linux 64 bits */
/* Linux 64 bits */
# elif defined _LP64 && __LINUX__
# elif defined _LP64 && __LINUX__
description
<<
(
wxT
(
"on 64
Bits
GNU/Linux"
)
);
description
<<
(
wxT
(
"on 64
bit
GNU/Linux"
)
);
/* Linux 32 bits */
/* Linux 32 bits */
# elif defined __LINUX__
# elif defined __LINUX__
description
<<
(
wxT
(
"on 32
Bits
GNU/Linux"
)
);
description
<<
(
wxT
(
"on 32
bit
GNU/Linux"
)
);
/* OpenBSD */
/* OpenBSD */
# elif defined __OpenBSD__
# elif defined __OpenBSD__
...
...
common/basicframe.cpp
View file @
91530e7a
...
@@ -5,10 +5,12 @@
...
@@ -5,10 +5,12 @@
#include <wx/aboutdlg.h>
#include <wx/aboutdlg.h>
#include <wx/fontdlg.h>
#include <wx/fontdlg.h>
#include <wx/clipbrd.h>
#include <wx/statline.h>
#include <wx/aboutdlg.h>
#include <wx/platinfo.h>
#include "wx/statline.h"
#include "build_version.h"
#include "wx/generic/aboutdlgg.h"
#include "fctsys.h"
#include "fctsys.h"
#include "appl_wxstruct.h"
#include "appl_wxstruct.h"
#include "common.h"
#include "common.h"
...
@@ -18,6 +20,8 @@
...
@@ -18,6 +20,8 @@
#include "eda_doc.h"
#include "eda_doc.h"
#include "wxstruct.h"
#include "wxstruct.h"
#include "macros.h"
#include "macros.h"
#include "bitmaps.h"
/*
/*
* Class constructor for WinEDA_BasicFrame general options
* Class constructor for WinEDA_BasicFrame general options
...
@@ -32,7 +36,7 @@ WinEDA_BasicFrame::WinEDA_BasicFrame( wxWindow* father,
...
@@ -32,7 +36,7 @@ WinEDA_BasicFrame::WinEDA_BasicFrame( wxWindow* father,
{
{
wxSize
minsize
;
wxSize
minsize
;
m_Ident
=
idtype
;
m_Ident
=
idtype
;
m_HToolBar
=
NULL
;
m_HToolBar
=
NULL
;
m_FrameIsActive
=
TRUE
;
m_FrameIsActive
=
TRUE
;
...
@@ -53,6 +57,9 @@ WinEDA_BasicFrame::WinEDA_BasicFrame( wxWindow* father,
...
@@ -53,6 +57,9 @@ WinEDA_BasicFrame::WinEDA_BasicFrame( wxWindow* father,
m_FramePos
.
x
=
m_FramePos
.
y
=
0
;
m_FramePos
.
x
=
m_FramePos
.
y
=
0
;
m_FrameSize
.
y
-=
m_MsgFrameHeight
;
m_FrameSize
.
y
-=
m_MsgFrameHeight
;
Connect
(
ID_HELP_COPY_VERSION_STRING
,
wxEVT_COMMAND_MENU_SELECTED
,
wxCommandEventHandler
(
WinEDA_BasicFrame
::
CopyVersionInfoToClipboard
)
);
}
}
...
@@ -62,10 +69,10 @@ WinEDA_BasicFrame::~WinEDA_BasicFrame()
...
@@ -62,10 +69,10 @@ WinEDA_BasicFrame::~WinEDA_BasicFrame()
delete
wxGetApp
().
m_HtmlCtrl
;
delete
wxGetApp
().
m_HtmlCtrl
;
wxGetApp
().
m_HtmlCtrl
=
NULL
;
wxGetApp
().
m_HtmlCtrl
=
NULL
;
/* This needed for OSX: avoids furter OnDraw processing after this
/* This needed for OSX: avoids furt
h
er OnDraw processing after this
* destructor and before the native window is destroyed
* destructor and before the native window is destroyed
*/
*/
this
->
Freeze
(
);
this
->
Freeze
();
}
}
...
@@ -77,7 +84,7 @@ void WinEDA_BasicFrame::ReCreateMenuBar()
...
@@ -77,7 +84,7 @@ void WinEDA_BasicFrame::ReCreateMenuBar()
}
}
/** Vitual function SetLanguage
/** Vi
r
tual function SetLanguage
* called on a language menu selection
* called on a language menu selection
* when using a derived function, do not forget to call this one
* when using a derived function, do not forget to call this one
*/
*/
...
@@ -124,7 +131,7 @@ void WinEDA_BasicFrame::LoadSettings()
...
@@ -124,7 +131,7 @@ void WinEDA_BasicFrame::LoadSettings()
// Ensure Window title bar is visible
// Ensure Window title bar is visible
#if defined( __WXMAC__ )
#if defined( __WXMAC__ )
// for macOSX, the window must be below system (macOSX) toolbar
// for macOSX, the window must be below system (macOSX) toolbar
// Ypos_min = GetMBarHeight(); seems no more exist in ne API (subject to change)
// Ypos_min = GetMBarHeight(); seems no more exist in ne
w
API (subject to change)
Ypos_min
=
20
;
Ypos_min
=
20
;
#else
#else
Ypos_min
=
0
;
Ypos_min
=
0
;
...
@@ -203,8 +210,7 @@ void WinEDA_BasicFrame::SetLastProject( const wxString& FullFileName )
...
@@ -203,8 +210,7 @@ void WinEDA_BasicFrame::SetLastProject( const wxString& FullFileName )
/*
/*
* Fetch the file name from the file history list.
* Fetch the file name from the file history list.
*/
*/
wxString
WinEDA_BasicFrame
::
GetFileFromHistory
(
int
cmdId
,
wxString
WinEDA_BasicFrame
::
GetFileFromHistory
(
int
cmdId
,
const
wxString
&
type
)
const
wxString
&
type
)
{
{
wxString
fn
,
msg
;
wxString
fn
,
msg
;
size_t
i
;
size_t
i
;
...
@@ -254,8 +260,7 @@ void WinEDA_BasicFrame::GetKicadHelp( wxCommandEvent& event )
...
@@ -254,8 +260,7 @@ void WinEDA_BasicFrame::GetKicadHelp( wxCommandEvent& event )
}
}
else
else
{
{
msg
.
Printf
(
_
(
"Help file %s not found"
),
msg
.
Printf
(
_
(
"Help file %s not found"
),
GetChars
(
wxGetApp
().
m_HelpFileName
)
);
GetChars
(
wxGetApp
().
m_HelpFileName
)
);
DisplayError
(
this
,
msg
);
DisplayError
(
this
,
msg
);
}
}
...
@@ -285,3 +290,85 @@ void WinEDA_BasicFrame::GetKicadAbout( wxCommandEvent& WXUNUSED(event) )
...
@@ -285,3 +290,85 @@ void WinEDA_BasicFrame::GetKicadAbout( wxCommandEvent& WXUNUSED(event) )
InitKiCadAbout
(
info
);
InitKiCadAbout
(
info
);
wxAboutBox
(
info
);
wxAboutBox
(
info
);
}
}
void
WinEDA_BasicFrame
::
AddHelpVersionInfoMenuEntry
(
wxMenu
*
aMenu
)
{
wxASSERT
(
aMenu
!=
NULL
);
wxMenuItem
*
item
=
NULL
;
// Copy version string to clipboard for bug report purposes.
item
=
new
wxMenuItem
(
aMenu
,
ID_HELP_COPY_VERSION_STRING
,
_
(
"Copy &Version Information"
),
_
(
"Copy the version string to clipboard to send with bug reports"
)
);
// For some reason images are not always added to the OSX menu items. Anyone want
// to clarify as to why this is the case? Putting this information in some formal
// developer notes would be helpful. A good place to put this information would be
// ./documentation/guidelines/UIpolicies.txt.
#if !defined( __WXMAC__ )
item
->
SetBitmap
(
copy_button
);
#endif
aMenu
->
Append
(
item
);
}
void
WinEDA_BasicFrame
::
CopyVersionInfoToClipboard
(
wxCommandEvent
&
WXUNUSED
(
event
)
)
{
if
(
!
wxTheClipboard
->
Open
()
)
{
wxMessageBox
(
_
(
"Could not open clipboard to write version information."
),
_
(
"Clipboard Error"
),
wxOK
|
wxICON_EXCLAMATION
,
this
);
return
;
}
wxString
tmp
;
wxPlatformInfo
info
;
// This is an enhanced version of the compiler build macro provided by wxWidgets
// in <wx/build.h>. Please do not make any of these strings translatable. They
// are used for conveying troubleshooting information to developers.
#if defined(__GXX_ABI_VERSION)
#define __ABI_VERSION ",compiler with C++ ABI " __WX_BO_STRINGIZE(__GXX_ABI_VERSION)
#else
#define __ABI_VERSION ",compiler without C++ ABI "
#endif
#if defined(__INTEL_COMPILER)
#define __BO_COMPILER ",Intel C++"
#elif defined(__GNUG__)
#define __BO_COMPILER ",GCC " \
__WX_BO_STRINGIZE(__GNUC__) "." \
__WX_BO_STRINGIZE(__GNUC_MINOR__) "." \
__WX_BO_STRINGIZE(__GNUC_PATCHLEVEL__)
#elif defined(__VISUALC__)
#define __BO_COMPILER ",Visual C++"
#elif defined(__BORLANDC__)
#define __BO_COMPILER ",Borland C++"
#elif defined(__DIGITALMARS__)
#define __BO_COMPILER ",DigitalMars"
#elif defined(__WATCOMC__)
#define __BO_COMPILER ",Watcom C++"
#else
#define __BO_COMPILER ",unknown"
#endif
#define KICAD_BUILD_OPTIONS_SIGNATURE \
" (" __WX_BO_DEBUG "," __WX_BO_UNICODE \
__ABI_VERSION __BO_COMPILER \
__WX_BO_STL \
__WX_BO_WXWIN_COMPAT_2_4 __WX_BO_WXWIN_COMPAT_2_6 \
")"
tmp
=
wxT
(
"Application: "
)
+
wxGetApp
().
GetTitle
()
+
wxT
(
"
\n
"
);
tmp
+=
wxT
(
"Version: "
)
+
GetBuildVersion
()
+
wxT
(
"
\n
"
);
tmp
<<
wxT
(
"Build: "
)
<<
wxVERSION_STRING
<<
wxT
(
KICAD_BUILD_OPTIONS_SIGNATURE
)
<<
wxT
(
"
\n
"
)
<<
wxT
(
"Platform: "
)
<<
wxGetOsDescription
()
<<
wxT
(
", "
)
<<
info
.
GetArchName
()
<<
wxT
(
", "
)
<<
info
.
GetEndiannessName
()
<<
wxT
(
", "
)
<<
info
.
GetPortIdName
();
wxTheClipboard
->
SetData
(
new
wxTextDataObject
(
tmp
)
);
wxTheClipboard
->
Close
();
}
cvpcb/menucfg.cpp
View file @
91530e7a
...
@@ -31,10 +31,9 @@ void WinEDA_CvpcbFrame::ReCreateMenuBar()
...
@@ -31,10 +31,9 @@ void WinEDA_CvpcbFrame::ReCreateMenuBar()
/* Open Recent submenu */
/* Open Recent submenu */
wxMenu
*
openRecentMenu
=
new
wxMenu
();
wxMenu
*
openRecentMenu
=
new
wxMenu
();
wxGetApp
().
m_fileHistory
.
AddFilesToMenu
(
openRecentMenu
);
wxGetApp
().
m_fileHistory
.
AddFilesToMenu
(
openRecentMenu
);
ADD_MENUITEM_WITH_HELP_AND_SUBMENU
(
filesMenu
,
openRecentMenu
,
ADD_MENUITEM_WITH_HELP_AND_SUBMENU
(
filesMenu
,
openRecentMenu
,
-
1
,
_
(
"Open &Recent"
),
-
1
,
_
(
"Open &Recent"
),
_
(
"Open a recent opened netlist document"
),
_
(
"Open a recent opened netlist document"
),
open_project_xpm
);
open_project_xpm
);
...
@@ -49,8 +48,7 @@ void WinEDA_CvpcbFrame::ReCreateMenuBar()
...
@@ -49,8 +48,7 @@ void WinEDA_CvpcbFrame::ReCreateMenuBar()
#if !defined(__WXMAC__)
#if !defined(__WXMAC__)
filesMenu
->
AppendSeparator
();
filesMenu
->
AppendSeparator
();
item
=
new
wxMenuItem
(
filesMenu
,
wxID_EXIT
,
_
(
"&Quit"
),
item
=
new
wxMenuItem
(
filesMenu
,
wxID_EXIT
,
_
(
"&Quit"
),
_
(
"Quit CvPCB"
)
);
_
(
"Quit CvPCB"
)
);
filesMenu
->
Append
(
item
);
filesMenu
->
Append
(
item
);
#endif
/* !defined( __WXMAC__) */
#endif
/* !defined( __WXMAC__) */
...
@@ -78,6 +76,9 @@ void WinEDA_CvpcbFrame::ReCreateMenuBar()
...
@@ -78,6 +76,9 @@ void WinEDA_CvpcbFrame::ReCreateMenuBar()
// Menu Help:
// Menu Help:
wxMenu
*
helpMenu
=
new
wxMenu
;
wxMenu
*
helpMenu
=
new
wxMenu
;
AddHelpVersionInfoMenuEntry
(
helpMenu
);
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
_
(
"Open the cvpcb manual"
)
);
_
(
"Open the cvpcb manual"
)
);
item
->
SetBitmap
(
online_help_xpm
);
item
->
SetBitmap
(
online_help_xpm
);
...
@@ -105,4 +106,3 @@ void WinEDA_CvpcbFrame::ReCreateMenuBar()
...
@@ -105,4 +106,3 @@ void WinEDA_CvpcbFrame::ReCreateMenuBar()
* rebuilt. This allows language changes of the menu text on the fly. */
* rebuilt. This allows language changes of the menu text on the fly. */
SetMenuBar
(
menuBar
);
SetMenuBar
(
menuBar
);
}
}
eeschema/menubar.cpp
View file @
91530e7a
...
@@ -44,14 +44,14 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -44,14 +44,14 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
/* New */
/* New */
item
=
new
wxMenuItem
(
filesMenu
,
ID_NEW_PROJECT
,
_
(
"&New
\t
Ctrl+N"
),
item
=
new
wxMenuItem
(
filesMenu
,
ID_NEW_PROJECT
,
_
(
"&New
\t
Ctrl+N"
),
_
(
"New schematic project"
)
);
_
(
"New schematic project"
)
);
item
->
SetBitmap
(
new_xpm
);
item
->
SetBitmap
(
new_xpm
);
filesMenu
->
Append
(
item
);
filesMenu
->
Append
(
item
);
/* Open */
/* Open */
item
=
new
wxMenuItem
(
filesMenu
,
ID_LOAD_PROJECT
,
_
(
"&Open
\t
Ctrl+O"
),
item
=
new
wxMenuItem
(
filesMenu
,
ID_LOAD_PROJECT
,
_
(
"&Open
\t
Ctrl+O"
),
_
(
"Open an existing schematic project"
)
);
_
(
"Open an existing schematic project"
)
);
item
->
SetBitmap
(
open_xpm
);
item
->
SetBitmap
(
open_xpm
);
filesMenu
->
Append
(
item
);
filesMenu
->
Append
(
item
);
...
@@ -69,20 +69,20 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -69,20 +69,20 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
/* Save */
/* Save */
/* Save Project */
/* Save Project */
item
=
new
wxMenuItem
(
filesMenu
,
ID_SAVE_PROJECT
,
item
=
new
wxMenuItem
(
filesMenu
,
ID_SAVE_PROJECT
,
_
(
"&Save Whole Schematic Project
\t
Ctrl+S"
),
_
(
"&Save Whole Schematic Project
\t
Ctrl+S"
),
_
(
"Save all sheets in the schematic project"
)
);
_
(
"Save all sheets in the schematic project"
)
);
item
->
SetBitmap
(
save_project_xpm
);
item
->
SetBitmap
(
save_project_xpm
);
filesMenu
->
Append
(
item
);
filesMenu
->
Append
(
item
);
item
=
new
wxMenuItem
(
filesMenu
,
ID_SAVE_ONE_SHEET
,
_
(
"Save &Current Sheet Only"
),
item
=
new
wxMenuItem
(
filesMenu
,
ID_SAVE_ONE_SHEET
,
_
(
"Save &Current Sheet Only"
),
_
(
"Save only current schematic sheet"
)
);
_
(
"Save only current schematic sheet"
)
);
item
->
SetBitmap
(
save_xpm
);
item
->
SetBitmap
(
save_xpm
);
filesMenu
->
Append
(
item
);
filesMenu
->
Append
(
item
);
/* Save as... */
/* Save as... */
item
=
new
wxMenuItem
(
filesMenu
,
ID_SAVE_ONE_SHEET_AS
,
item
=
new
wxMenuItem
(
filesMenu
,
ID_SAVE_ONE_SHEET_AS
,
_
(
"Save Current Sheet &as"
),
_
(
"Save Current Sheet &as"
),
_
(
"Save current schematic sheet as..."
)
);
_
(
"Save current schematic sheet as..."
)
);
item
->
SetBitmap
(
save_as_xpm
);
item
->
SetBitmap
(
save_as_xpm
);
filesMenu
->
Append
(
item
);
filesMenu
->
Append
(
item
);
...
@@ -90,34 +90,33 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -90,34 +90,33 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
filesMenu
->
AppendSeparator
();
filesMenu
->
AppendSeparator
();
/* Print */
/* Print */
item
=
new
wxMenuItem
(
filesMenu
,
wxID_PRINT
,
_
(
"P&rint"
),
item
=
new
wxMenuItem
(
filesMenu
,
wxID_PRINT
,
_
(
"P&rint"
),
_
(
"Print schematic"
)
);
_
(
"Print schematic"
)
);
item
->
SetBitmap
(
print_button
);
item
->
SetBitmap
(
print_button
);
filesMenu
->
Append
(
item
);
filesMenu
->
Append
(
item
);
/* Plot submenu */
/* Plot submenu */
wxMenu
*
choice_plot_fmt
=
new
wxMenu
;
wxMenu
*
choice_plot_fmt
=
new
wxMenu
;
item
=
new
wxMenuItem
(
choice_plot_fmt
,
ID_GEN_PLOT_PS
,
item
=
new
wxMenuItem
(
choice_plot_fmt
,
ID_GEN_PLOT_PS
,
_
(
"Plot PostScript"
),
_
(
"Plot PostScript"
),
_
(
"Plot schematic sheet in PostScript format"
)
);
_
(
"Plot schematic sheet in PostScript format"
)
);
item
->
SetBitmap
(
plot_PS_xpm
);
item
->
SetBitmap
(
plot_PS_xpm
);
choice_plot_fmt
->
Append
(
item
);
choice_plot_fmt
->
Append
(
item
);
/* Plot HPGL */
/* Plot HPGL */
item
=
new
wxMenuItem
(
choice_plot_fmt
,
ID_GEN_PLOT_HPGL
,
_
(
"Plot HPGL"
),
item
=
new
wxMenuItem
(
choice_plot_fmt
,
ID_GEN_PLOT_HPGL
,
_
(
"Plot HPGL"
),
_
(
"Plot schematic sheet in HPGL format"
)
);
_
(
"Plot schematic sheet in HPGL format"
)
);
item
->
SetBitmap
(
plot_HPG_xpm
);
item
->
SetBitmap
(
plot_HPG_xpm
);
choice_plot_fmt
->
Append
(
item
);
choice_plot_fmt
->
Append
(
item
);
/* Plot SVG */
/* Plot SVG */
item
=
new
wxMenuItem
(
choice_plot_fmt
,
ID_GEN_PLOT_SVG
,
_
(
"Plot SVG"
),
item
=
new
wxMenuItem
(
choice_plot_fmt
,
ID_GEN_PLOT_SVG
,
_
(
"Plot SVG"
),
_
(
"Plot schematic sheet in SVG format"
)
);
_
(
"Plot schematic sheet in SVG format"
)
);
item
->
SetBitmap
(
plot_xpm
);
item
->
SetBitmap
(
plot_xpm
);
choice_plot_fmt
->
Append
(
item
);
choice_plot_fmt
->
Append
(
item
);
/* Plot DXF */
/* Plot DXF */
item
=
new
wxMenuItem
(
choice_plot_fmt
,
ID_GEN_PLOT_DXF
,
_
(
"Plot DXF"
),
item
=
new
wxMenuItem
(
choice_plot_fmt
,
ID_GEN_PLOT_DXF
,
_
(
"Plot DXF"
),
_
(
"Plot schematic sheet in DXF format"
)
);
_
(
"Plot schematic sheet in DXF format"
)
);
item
->
SetBitmap
(
plot_xpm
);
item
->
SetBitmap
(
plot_xpm
);
choice_plot_fmt
->
Append
(
item
);
choice_plot_fmt
->
Append
(
item
);
...
@@ -125,8 +124,8 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -125,8 +124,8 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
#ifdef __WINDOWS__
#ifdef __WINDOWS__
item
=
new
wxMenuItem
(
choice_plot_fmt
,
ID_GEN_COPY_SHEET_TO_CLIPBOARD
,
item
=
new
wxMenuItem
(
choice_plot_fmt
,
ID_GEN_COPY_SHEET_TO_CLIPBOARD
,
_
(
"Plot to Clipboard"
),
_
(
"Plot to Clipboard"
),
_
(
"Export drawings to clipboard"
)
);
_
(
"Export drawings to clipboard"
)
);
item
->
SetBitmap
(
copy_button
);
item
->
SetBitmap
(
copy_button
);
choice_plot_fmt
->
Append
(
item
);
choice_plot_fmt
->
Append
(
item
);
...
@@ -134,16 +133,14 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -134,16 +133,14 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
ADD_MENUITEM_WITH_HELP_AND_SUBMENU
(
filesMenu
,
choice_plot_fmt
,
ADD_MENUITEM_WITH_HELP_AND_SUBMENU
(
filesMenu
,
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
);
/* Quit on all platforms except WXMAC */
/* Quit on all platforms except WXMAC */
#if !defined(__WXMAC__)
#if !defined(__WXMAC__)
filesMenu
->
AppendSeparator
();
filesMenu
->
AppendSeparator
();
item
=
new
wxMenuItem
(
filesMenu
,
wxID_EXIT
,
_
(
"&Quit"
),
item
=
new
wxMenuItem
(
filesMenu
,
wxID_EXIT
,
_
(
"&Quit"
),
_
(
"Quit EESchema"
)
);
_
(
"Quit EESchema"
)
);
item
->
SetBitmap
(
exit_xpm
);
item
->
SetBitmap
(
exit_xpm
);
filesMenu
->
Append
(
item
);
filesMenu
->
Append
(
item
);
...
@@ -158,16 +155,14 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -158,16 +155,14 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
/* Undo */
/* Undo */
text
=
AddHotkeyName
(
_
(
"Undo"
),
s_Schematic_Hokeys_Descr
,
HK_UNDO
);
text
=
AddHotkeyName
(
_
(
"Undo"
),
s_Schematic_Hokeys_Descr
,
HK_UNDO
);
item
=
new
wxMenuItem
(
editMenu
,
wxID_UNDO
,
text
,
item
=
new
wxMenuItem
(
editMenu
,
wxID_UNDO
,
text
,
HELP_UNDO
,
wxITEM_NORMAL
);
HELP_UNDO
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
undo_xpm
);
item
->
SetBitmap
(
undo_xpm
);
editMenu
->
Append
(
item
);
editMenu
->
Append
(
item
);
/* Redo */
/* Redo */
text
=
AddHotkeyName
(
_
(
"Redo"
),
s_Schematic_Hokeys_Descr
,
HK_REDO
);
text
=
AddHotkeyName
(
_
(
"Redo"
),
s_Schematic_Hokeys_Descr
,
HK_REDO
);
item
=
new
wxMenuItem
(
editMenu
,
wxID_REDO
,
text
,
item
=
new
wxMenuItem
(
editMenu
,
wxID_REDO
,
text
,
HELP_REDO
,
wxITEM_NORMAL
);
HELP_REDO
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
redo_xpm
);
item
->
SetBitmap
(
redo_xpm
);
editMenu
->
Append
(
item
);
editMenu
->
Append
(
item
);
...
@@ -185,8 +180,7 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -185,8 +180,7 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
/* Find */
/* Find */
text
=
AddHotkeyName
(
_
(
"&Find"
),
s_Schematic_Hokeys_Descr
,
HK_FIND_ITEM
);
text
=
AddHotkeyName
(
_
(
"&Find"
),
s_Schematic_Hokeys_Descr
,
HK_FIND_ITEM
);
item
=
new
wxMenuItem
(
editMenu
,
ID_FIND_ITEMS
,
text
,
item
=
new
wxMenuItem
(
editMenu
,
ID_FIND_ITEMS
,
text
,
HELP_FIND
,
wxITEM_NORMAL
);
HELP_FIND
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
find_xpm
);
item
->
SetBitmap
(
find_xpm
);
editMenu
->
Append
(
item
);
editMenu
->
Append
(
item
);
...
@@ -210,9 +204,9 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -210,9 +204,9 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
* we cannot add hotkey shortcut here, because the hotkey HK_ZOOM_IN and HK_ZOOM_OUT
* we cannot add hotkey shortcut here, because the hotkey HK_ZOOM_IN and HK_ZOOM_OUT
* events(default = WXK_F1 and WXK_F2) are *NOT* equivalent to this menu command:
* events(default = WXK_F1 and WXK_F2) are *NOT* equivalent to this menu command:
* zoom in and out from hotkeys are equivalent to the pop up menu zoom
* zoom in and out from hotkeys are equivalent to the pop up menu zoom
* From here, zoom
m
ing is made around the screen center
* From here, zooming is made around the screen center
* From hotkeys, zoom
m
ing is made around the mouse cursor position
* From hotkeys, zooming is made around the mouse cursor position
* (obviou
lsy not possible from the toolbat
or menubar command)
* (obviou
sly not possible from the toolbar
or menubar command)
*
*
* in others words HK_ZOOM_IN and HK_ZOOM_OUT *are NOT* accelerators
* in others words HK_ZOOM_IN and HK_ZOOM_OUT *are NOT* accelerators
* for Zoom in and Zoom out sub menus
* for Zoom in and Zoom out sub menus
...
@@ -222,36 +216,28 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -222,36 +216,28 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
/* Zoom in */
/* Zoom in */
text
=
AddHotkeyName
(
_
(
"Zoom In"
),
s_Schematic_Hokeys_Descr
,
text
=
AddHotkeyName
(
_
(
"Zoom In"
),
s_Schematic_Hokeys_Descr
,
ID_ZOOM_IN
,
false
);
// add comment, not a shortcut
ID_ZOOM_IN
,
false
);
// add comment, not a shortcut
item
=
new
wxMenuItem
(
viewMenu
,
ID_ZOOM_IN
,
text
,
HELP_ZOOM_IN
,
item
=
new
wxMenuItem
(
viewMenu
,
ID_ZOOM_IN
,
text
,
HELP_ZOOM_IN
,
wxITEM_NORMAL
);
wxITEM_NORMAL
);
item
->
SetBitmap
(
zoom_in_xpm
);
item
->
SetBitmap
(
zoom_in_xpm
);
viewMenu
->
Append
(
item
);
viewMenu
->
Append
(
item
);
/* Zoom out */
/* Zoom out */
text
=
AddHotkeyName
(
_
(
"Zoom Out"
),
s_Schematic_Hokeys_Descr
,
text
=
AddHotkeyName
(
_
(
"Zoom Out"
),
s_Schematic_Hokeys_Descr
,
ID_ZOOM_OUT
,
false
);
// add comment, not a shortcut
ID_ZOOM_OUT
,
false
);
// add comment, not a shortcut
item
=
new
wxMenuItem
(
viewMenu
,
ID_ZOOM_OUT
,
text
,
HELP_ZOOM_OUT
,
item
=
new
wxMenuItem
(
viewMenu
,
ID_ZOOM_OUT
,
text
,
HELP_ZOOM_OUT
,
wxITEM_NORMAL
);
wxITEM_NORMAL
);
item
->
SetBitmap
(
zoom_out_xpm
);
item
->
SetBitmap
(
zoom_out_xpm
);
viewMenu
->
Append
(
item
);
viewMenu
->
Append
(
item
);
/* Fit on screen */
/* Fit on screen */
text
=
AddHotkeyName
(
_
(
"Fit on Screen"
),
s_Schematic_Hokeys_Descr
,
text
=
AddHotkeyName
(
_
(
"Fit on Screen"
),
s_Schematic_Hokeys_Descr
,
HK_ZOOM_AUTO
);
HK_ZOOM_AUTO
);
item
=
new
wxMenuItem
(
viewMenu
,
ID_ZOOM_PAGE
,
text
,
HELP_ZOOM_FIT
,
wxITEM_NORMAL
);
item
=
new
wxMenuItem
(
viewMenu
,
ID_ZOOM_PAGE
,
text
,
HELP_ZOOM_FIT
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
zoom_auto_xpm
);
item
->
SetBitmap
(
zoom_auto_xpm
);
viewMenu
->
Append
(
item
);
viewMenu
->
Append
(
item
);
viewMenu
->
AppendSeparator
();
viewMenu
->
AppendSeparator
();
/* Redraw view */
/* Redraw view */
text
=
AddHotkeyName
(
_
(
"Redraw"
),
s_Schematic_Hokeys_Descr
,
text
=
AddHotkeyName
(
_
(
"Redraw"
),
s_Schematic_Hokeys_Descr
,
HK_ZOOM_REDRAW
);
HK_ZOOM_REDRAW
);
item
=
new
wxMenuItem
(
viewMenu
,
ID_ZOOM_REDRAW
,
text
,
HELP_ZOOM_REDRAW
,
wxITEM_NORMAL
);
item
=
new
wxMenuItem
(
viewMenu
,
ID_ZOOM_REDRAW
,
text
,
HELP_ZOOM_REDRAW
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
zoom_redraw_xpm
);
item
->
SetBitmap
(
zoom_redraw_xpm
);
viewMenu
->
Append
(
item
);
viewMenu
->
Append
(
item
);
...
@@ -291,15 +277,13 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -291,15 +277,13 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
/* Wire to Bus */
/* Wire to Bus */
item
=
new
wxMenuItem
(
placeMenu
,
ID_WIRETOBUS_ENTRY_BUTT
,
item
=
new
wxMenuItem
(
placeMenu
,
ID_WIRETOBUS_ENTRY_BUTT
,
_
(
"W&ire to bus entry"
),
_
(
"W&ire to bus entry"
),
HELP_PLACE_WIRE2BUS_ENTRY
,
wxITEM_NORMAL
);
HELP_PLACE_WIRE2BUS_ENTRY
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
add_line2bus_xpm
);
item
->
SetBitmap
(
add_line2bus_xpm
);
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
/* Bus to Bus */
/* Bus to Bus */
item
=
new
wxMenuItem
(
placeMenu
,
ID_BUSTOBUS_ENTRY_BUTT
,
item
=
new
wxMenuItem
(
placeMenu
,
ID_BUSTOBUS_ENTRY_BUTT
,
_
(
"B&us to bus entry"
),
_
(
"B&us to bus entry"
),
HELP_PLACE_BUS2BUS_ENTRY
,
wxITEM_NORMAL
);
HELP_PLACE_BUS2BUS_ENTRY
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
add_bus2bus_xpm
);
item
->
SetBitmap
(
add_bus2bus_xpm
);
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
...
@@ -307,8 +291,7 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -307,8 +291,7 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
/* No connect flag */
/* No connect flag */
text
=
AddHotkeyName
(
_
(
"No connect flag"
),
s_Schematic_Hokeys_Descr
,
text
=
AddHotkeyName
(
_
(
"No connect flag"
),
s_Schematic_Hokeys_Descr
,
HK_ADD_NOCONN_FLAG
,
false
);
// add comment, not a shortcut
HK_ADD_NOCONN_FLAG
,
false
);
// add comment, not a shortcut
item
=
new
wxMenuItem
(
placeMenu
,
ID_NOCONN_BUTT
,
text
,
item
=
new
wxMenuItem
(
placeMenu
,
ID_NOCONN_BUTT
,
text
,
HELP_PLACE_NC_FLAG
,
wxITEM_NORMAL
);
HELP_PLACE_NC_FLAG
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
noconn_button
);
item
->
SetBitmap
(
noconn_button
);
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
...
@@ -322,8 +305,7 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -322,8 +305,7 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
/* Global label */
/* Global label */
item
=
new
wxMenuItem
(
placeMenu
,
ID_GLABEL_BUTT
,
_
(
"Global label"
),
item
=
new
wxMenuItem
(
placeMenu
,
ID_GLABEL_BUTT
,
_
(
"Global label"
),
_
(
_
(
"Place a global label. Warning: all global labels with the same name are connected in whole hierarchy"
),
"Place a global label. Warning: all global labels with the same name are connected in whole hierarchy"
),
wxITEM_NORMAL
);
wxITEM_NORMAL
);
item
->
SetBitmap
(
add_glabel_xpm
);
item
->
SetBitmap
(
add_glabel_xpm
);
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
...
@@ -338,29 +320,25 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -338,29 +320,25 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
placeMenu
->
AppendSeparator
();
placeMenu
->
AppendSeparator
();
/* Hierarchical label */
/* Hierarchical label */
item
=
new
wxMenuItem
(
placeMenu
,
ID_HIERLABEL_BUTT
,
item
=
new
wxMenuItem
(
placeMenu
,
ID_HIERLABEL_BUTT
,
_
(
"Hierarchical label"
),
_
(
"Hierarchical label"
),
HELP_PLACE_HIER_LABEL
,
wxITEM_NORMAL
);
HELP_PLACE_HIER_LABEL
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
add_hierarchical_label_xpm
);
item
->
SetBitmap
(
add_hierarchical_label_xpm
);
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
/* Hierarchical sheet */
/* Hierarchical sheet */
item
=
new
wxMenuItem
(
placeMenu
,
ID_SHEET_SYMBOL_BUTT
,
item
=
new
wxMenuItem
(
placeMenu
,
ID_SHEET_SYMBOL_BUTT
,
_
(
"Hierarchical sheet"
),
_
(
"Hierarchical sheet"
),
HELP_PLACE_SHEET
,
wxITEM_NORMAL
);
HELP_PLACE_SHEET
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
add_hierarchical_subsheet_xpm
);
item
->
SetBitmap
(
add_hierarchical_subsheet_xpm
);
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
/* Import hierarchical sheet */
/* Import hierarchical sheet */
item
=
new
wxMenuItem
(
placeMenu
,
ID_IMPORT_HLABEL_BUTT
,
item
=
new
wxMenuItem
(
placeMenu
,
ID_IMPORT_HLABEL_BUTT
,
_
(
"Import Hierarchical Label"
),
_
(
"Import Hierarchical Label"
),
HELP_IMPORT_PINSHEET
,
wxITEM_NORMAL
);
HELP_IMPORT_PINSHEET
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
import_hierarchical_label_xpm
);
item
->
SetBitmap
(
import_hierarchical_label_xpm
);
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
/* Add hierarchical Pin to Sheet */
/* Add hierarchical Pin to Sheet */
item
=
new
wxMenuItem
(
placeMenu
,
ID_SHEET_LABEL_BUTT
,
item
=
new
wxMenuItem
(
placeMenu
,
ID_SHEET_LABEL_BUTT
,
_
(
"Add Hierarchical Pin to Sheet"
),
_
(
"Add Hierarchical Pin to Sheet"
),
HELP_PLACE_PINSHEET
,
wxITEM_NORMAL
);
HELP_PLACE_PINSHEET
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
add_hierar_pin_xpm
);
item
->
SetBitmap
(
add_hierar_pin_xpm
);
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
...
@@ -369,15 +347,13 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -369,15 +347,13 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
placeMenu
->
AppendSeparator
();
placeMenu
->
AppendSeparator
();
/* Graphic line or polygon */
/* Graphic line or polygon */
item
=
new
wxMenuItem
(
placeMenu
,
ID_LINE_COMMENT_BUTT
,
item
=
new
wxMenuItem
(
placeMenu
,
ID_LINE_COMMENT_BUTT
,
_
(
"Graphic line or polygon"
),
_
(
"Graphic line or polygon"
),
HELP_PLACE_GRAPHICLINES
,
wxITEM_NORMAL
);
HELP_PLACE_GRAPHICLINES
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
add_dashed_line_xpm
);
item
->
SetBitmap
(
add_dashed_line_xpm
);
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
/* Graphic text */
/* Graphic text */
item
=
new
wxMenuItem
(
placeMenu
,
ID_TEXT_COMMENT_BUTT
,
item
=
new
wxMenuItem
(
placeMenu
,
ID_TEXT_COMMENT_BUTT
,
_
(
"Graphic text"
),
_
(
"Graphic text"
),
HELP_PLACE_GRAPHICTEXTS
,
wxITEM_NORMAL
);
HELP_PLACE_GRAPHICTEXTS
,
wxITEM_NORMAL
);
item
->
SetBitmap
(
add_text_xpm
);
item
->
SetBitmap
(
add_text_xpm
);
placeMenu
->
Append
(
item
);
placeMenu
->
Append
(
item
);
...
@@ -390,19 +366,19 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -390,19 +366,19 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
/* Library */
/* Library */
item
=
new
wxMenuItem
(
configmenu
,
ID_CONFIG_REQ
,
_
(
"&Library"
),
item
=
new
wxMenuItem
(
configmenu
,
ID_CONFIG_REQ
,
_
(
"&Library"
),
_
(
"Library preferences"
)
);
_
(
"Library preferences"
)
);
item
->
SetBitmap
(
library_xpm
);
item
->
SetBitmap
(
library_xpm
);
configmenu
->
Append
(
item
);
configmenu
->
Append
(
item
);
/* Colors */
/* Colors */
item
=
new
wxMenuItem
(
configmenu
,
ID_COLORS_SETUP
,
_
(
"&Colors"
),
item
=
new
wxMenuItem
(
configmenu
,
ID_COLORS_SETUP
,
_
(
"&Colors"
),
_
(
"Color preferences"
)
);
_
(
"Color preferences"
)
);
item
->
SetBitmap
(
palette_xpm
);
item
->
SetBitmap
(
palette_xpm
);
configmenu
->
Append
(
item
);
configmenu
->
Append
(
item
);
/* Options */
/* Options */
item
=
new
wxMenuItem
(
configmenu
,
ID_OPTIONS_SETUP
,
_
(
"&Options"
),
item
=
new
wxMenuItem
(
configmenu
,
ID_OPTIONS_SETUP
,
_
(
"&Options"
),
_
(
"Eeschema general options and preferences"
)
);
_
(
"Eeschema general options and preferences"
)
);
item
->
SetBitmap
(
preference_xpm
);
item
->
SetBitmap
(
preference_xpm
);
configmenu
->
Append
(
item
);
configmenu
->
Append
(
item
);
...
@@ -417,13 +393,13 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -417,13 +393,13 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
/* Save preferences */
/* Save preferences */
item
=
new
wxMenuItem
(
configmenu
,
ID_CONFIG_SAVE
,
_
(
"&Save preferences"
),
item
=
new
wxMenuItem
(
configmenu
,
ID_CONFIG_SAVE
,
_
(
"&Save preferences"
),
_
(
"Save application preferences"
)
);
_
(
"Save application preferences"
)
);
item
->
SetBitmap
(
save_setup_xpm
);
item
->
SetBitmap
(
save_setup_xpm
);
configmenu
->
Append
(
item
);
configmenu
->
Append
(
item
);
/* Read preferences */
/* Read preferences */
item
=
new
wxMenuItem
(
configmenu
,
ID_CONFIG_READ
,
_
(
"&Read preferences"
),
item
=
new
wxMenuItem
(
configmenu
,
ID_CONFIG_READ
,
_
(
"&Read preferences"
),
_
(
"Read application preferences"
)
);
_
(
"Read application preferences"
)
);
item
->
SetBitmap
(
read_setup_xpm
);
item
->
SetBitmap
(
read_setup_xpm
);
configmenu
->
Append
(
item
);
configmenu
->
Append
(
item
);
...
@@ -432,8 +408,11 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -432,8 +408,11 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
* Help Menu
* Help Menu
*/
*/
wxMenu
*
helpMenu
=
new
wxMenu
;
wxMenu
*
helpMenu
=
new
wxMenu
;
AddHelpVersionInfoMenuEntry
(
helpMenu
);
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
_
(
"Open the eeschema manual"
)
);
_
(
"Open the eeschema manual"
)
);
item
->
SetBitmap
(
online_help_xpm
);
item
->
SetBitmap
(
online_help_xpm
);
helpMenu
->
Append
(
item
);
helpMenu
->
Append
(
item
);
...
@@ -441,7 +420,7 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
...
@@ -441,7 +420,7 @@ void WinEDA_SchematicFrame::ReCreateMenuBar()
#if !defined(__WXMAC__)
#if !defined(__WXMAC__)
item
=
new
wxMenuItem
(
helpMenu
,
ID_KICAD_ABOUT
,
_
(
"&About"
),
item
=
new
wxMenuItem
(
helpMenu
,
ID_KICAD_ABOUT
,
_
(
"&About"
),
_
(
"About eeschema schematic designer"
)
);
_
(
"About eeschema schematic designer"
)
);
item
->
SetBitmap
(
info_xpm
);
item
->
SetBitmap
(
info_xpm
);
helpMenu
->
Append
(
item
);
helpMenu
->
Append
(
item
);
...
...
eeschema/menubar_libedit.cpp
View file @
91530e7a
...
@@ -119,9 +119,9 @@ void WinEDA_LibeditFrame::ReCreateMenuBar()
...
@@ -119,9 +119,9 @@ void WinEDA_LibeditFrame::ReCreateMenuBar()
* we cannot add hotkey info here, because the hotkey HK_ZOOM_IN and HK_ZOOM_OUT
* we cannot add hotkey info here, because the hotkey HK_ZOOM_IN and HK_ZOOM_OUT
* events(default = WXK_F1 and WXK_F2) are *NOT* equivalent to this menu command:
* events(default = WXK_F1 and WXK_F2) are *NOT* equivalent to this menu command:
* zoom in and out from hotkeys are equivalent to the pop up menu zoom
* zoom in and out from hotkeys are equivalent to the pop up menu zoom
* From here, zoom
m
ing is made around the screen center
* From here, zooming is made around the screen center
* From hotkeys, zoom
m
ing is made around the mouse cursor position
* From hotkeys, zooming is made around the mouse cursor position
* (obviou
lsy not possible from the toolbat
or menubar command)
* (obviou
sly not possible from the toolbar
or menubar command)
*
*
* in others words HK_ZOOM_IN and HK_ZOOM_OUT *are NOT* accelerators
* in others words HK_ZOOM_IN and HK_ZOOM_OUT *are NOT* accelerators
* for Zoom in and Zoom out sub menus
* for Zoom in and Zoom out sub menus
...
@@ -228,7 +228,7 @@ void WinEDA_LibeditFrame::ReCreateMenuBar()
...
@@ -228,7 +228,7 @@ void WinEDA_LibeditFrame::ReCreateMenuBar()
#if 0 // work in progress. activated when finished
#if 0 // work in progress. activated when finished
/* Dimension */
/* Dimension */
item = new wxMenuItem( configmenu, ID_LIBEDIT_DIMENSIONS, _( "&Dimensions" ),
item = new wxMenuItem( configmenu, ID_LIBEDIT_DIMENSIONS, _( "&Dimensions" ),
_( "Tickness of graphic lines, texts sizes and others" ) );
_( "T
h
ickness of graphic lines, texts sizes and others" ) );
item->SetBitmap( add_dimension_xpm );
item->SetBitmap( add_dimension_xpm );
configmenu->Append( item );
configmenu->Append( item );
#endif
#endif
...
@@ -257,6 +257,9 @@ void WinEDA_LibeditFrame::ReCreateMenuBar()
...
@@ -257,6 +257,9 @@ void WinEDA_LibeditFrame::ReCreateMenuBar()
* Help Menu
* Help Menu
*/
*/
wxMenu
*
helpMenu
=
new
wxMenu
;
wxMenu
*
helpMenu
=
new
wxMenu
;
AddHelpVersionInfoMenuEntry
(
helpMenu
);
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
_
(
"Open the eeschema manual"
)
);
_
(
"Open the eeschema manual"
)
);
item
->
SetBitmap
(
online_help_xpm
);
item
->
SetBitmap
(
online_help_xpm
);
...
...
gerbview/tool_gerber.cpp
View file @
91530e7a
...
@@ -118,6 +118,7 @@ void WinEDA_GerberFrame::ReCreateMenuBar( void )
...
@@ -118,6 +118,7 @@ void WinEDA_GerberFrame::ReCreateMenuBar( void )
// Menu Help:
// Menu Help:
wxMenu
*
helpMenu
=
new
wxMenu
;
wxMenu
*
helpMenu
=
new
wxMenu
;
AddHelpVersionInfoMenuEntry
(
helpMenu
);
ADD_MENUITEM_WITH_HELP
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
ADD_MENUITEM_WITH_HELP
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
_
(
"Open the gerbview manual"
),
help_xpm
);
_
(
"Open the gerbview manual"
),
help_xpm
);
ADD_MENUITEM_WITH_HELP
(
helpMenu
,
ID_KICAD_ABOUT
,
_
(
"&About Gerbview"
),
ADD_MENUITEM_WITH_HELP
(
helpMenu
,
ID_KICAD_ABOUT
,
_
(
"&About Gerbview"
),
...
@@ -161,7 +162,7 @@ void WinEDA_GerberFrame::ReCreateHToolbar( void )
...
@@ -161,7 +162,7 @@ void WinEDA_GerberFrame::ReCreateHToolbar( void )
// Set up toolbar
// Set up toolbar
m_HToolBar
->
AddTool
(
ID_NEW_BOARD
,
wxEmptyString
,
m_HToolBar
->
AddTool
(
ID_NEW_BOARD
,
wxEmptyString
,
wxBitmap
(
new_xpm
),
wxBitmap
(
new_xpm
),
_
(
"New world"
)
);
_
(
"New world"
)
);
m_HToolBar
->
AddTool
(
wxID_FILE
,
wxEmptyString
,
m_HToolBar
->
AddTool
(
wxID_FILE
,
wxEmptyString
,
...
@@ -262,8 +263,7 @@ void WinEDA_GerberFrame::ReCreateVToolbar( void )
...
@@ -262,8 +263,7 @@ void WinEDA_GerberFrame::ReCreateVToolbar( void )
m_VToolBar
=
new
WinEDA_Toolbar
(
TOOLBAR_TOOL
,
this
,
ID_V_TOOLBAR
,
FALSE
);
m_VToolBar
=
new
WinEDA_Toolbar
(
TOOLBAR_TOOL
,
this
,
ID_V_TOOLBAR
,
FALSE
);
// Set up toolbar
// Set up toolbar
m_VToolBar
->
AddTool
(
ID_NO_SELECT_BUTT
,
wxEmptyString
,
m_VToolBar
->
AddTool
(
ID_NO_SELECT_BUTT
,
wxEmptyString
,
wxBitmap
(
cursor_xpm
)
);
wxBitmap
(
cursor_xpm
)
);
m_VToolBar
->
ToggleTool
(
ID_NO_SELECT_BUTT
,
TRUE
);
m_VToolBar
->
ToggleTool
(
ID_NO_SELECT_BUTT
,
TRUE
);
m_VToolBar
->
AddSeparator
();
m_VToolBar
->
AddSeparator
();
m_VToolBar
->
AddTool
(
ID_GERBVIEW_DELETE_ITEM_BUTT
,
wxEmptyString
,
m_VToolBar
->
AddTool
(
ID_GERBVIEW_DELETE_ITEM_BUTT
,
wxEmptyString
,
...
@@ -285,11 +285,10 @@ void WinEDA_GerberFrame::ReCreateOptToolbar( void )
...
@@ -285,11 +285,10 @@ void WinEDA_GerberFrame::ReCreateOptToolbar( void )
wxWindowUpdateLocker
dummy
(
this
);
wxWindowUpdateLocker
dummy
(
this
);
// creation of tool bar options
// creation of tool bar options
m_OptionsToolBar
=
new
WinEDA_Toolbar
(
TOOLBAR_OPTION
,
this
,
m_OptionsToolBar
=
new
WinEDA_Toolbar
(
TOOLBAR_OPTION
,
this
,
ID_OPT_TOOLBAR
,
FALSE
);
ID_OPT_TOOLBAR
,
FALSE
);
m_OptionsToolBar
->
AddTool
(
ID_TB_OPTIONS_SHOW_GRID
,
wxEmptyString
,
m_OptionsToolBar
->
AddTool
(
ID_TB_OPTIONS_SHOW_GRID
,
wxEmptyString
,
wxBitmap
(
grid_xpm
),
wxBitmap
(
grid_xpm
),
_
(
"Turn grid off"
),
wxITEM_CHECK
);
_
(
"Turn grid off"
),
wxITEM_CHECK
);
m_OptionsToolBar
->
AddTool
(
ID_TB_OPTIONS_SHOW_POLAR_COORD
,
wxEmptyString
,
m_OptionsToolBar
->
AddTool
(
ID_TB_OPTIONS_SHOW_POLAR_COORD
,
wxEmptyString
,
...
@@ -329,11 +328,10 @@ void WinEDA_GerberFrame::ReCreateOptToolbar( void )
...
@@ -329,11 +328,10 @@ void WinEDA_GerberFrame::ReCreateOptToolbar( void )
// Tools to show/hide toolbars:
// Tools to show/hide toolbars:
m_OptionsToolBar
->
AddSeparator
();
m_OptionsToolBar
->
AddSeparator
();
m_OptionsToolBar
->
AddTool
(
ID_TB_OPTIONS_SHOW_LAYERS_MANAGER_VERTICAL_TOOLBAR
,
m_OptionsToolBar
->
AddTool
(
ID_TB_OPTIONS_SHOW_LAYERS_MANAGER_VERTICAL_TOOLBAR
,
wxEmptyString
,
wxEmptyString
,
wxBitmap
(
layers_manager_xpm
),
wxBitmap
(
layers_manager_xpm
),
_
(
_
(
"Show/hide the layers manager toolbar"
),
"Show/hide the layers manager toolbar"
),
wxITEM_CHECK
);
wxITEM_CHECK
);
m_OptionsToolBar
->
Realize
();
m_OptionsToolBar
->
Realize
();
...
...
include/id.h
View file @
91530e7a
...
@@ -71,6 +71,7 @@ enum main_id
...
@@ -71,6 +71,7 @@ enum main_id
ID_AUX_TOOLBAR
,
ID_AUX_TOOLBAR
,
ID_GENERAL_HELP
,
ID_GENERAL_HELP
,
ID_HELP_COPY_VERSION_STRING
,
ID_LOCAL_HELP
,
ID_LOCAL_HELP
,
ID_KICAD_ABOUT
,
ID_KICAD_ABOUT
,
...
@@ -218,10 +219,10 @@ enum main_id
...
@@ -218,10 +219,10 @@ enum main_id
ID_TB_OPTIONS_SHOW_ZONES_DISABLE
,
ID_TB_OPTIONS_SHOW_ZONES_DISABLE
,
ID_TB_OPTIONS_SHOW_ZONES_OUTLINES_ONLY
,
ID_TB_OPTIONS_SHOW_ZONES_OUTLINES_ONLY
,
ID_TB_OPTIONS_HIDDEN_PINS
,
ID_TB_OPTIONS_HIDDEN_PINS
,
ID_TB_OPTIONS_BUS_WIRES_ORIENT
,
ID_TB_OPTIONS_BUS_WIRES_ORIENT
,
ID_TB_OPTIONS_SHOW_PADS_SKETCH
,
ID_TB_OPTIONS_SHOW_PADS_SKETCH
,
ID_TB_OPTIONS_SHOW_VIAS_SKETCH
,
ID_TB_OPTIONS_SHOW_VIAS_SKETCH
,
ID_TB_OPTIONS_SHOW_TRACKS_SKETCH
,
ID_TB_OPTIONS_SHOW_TRACKS_SKETCH
,
ID_TB_OPTIONS_SHOW_MODULE_TEXT_SKETCH
,
ID_TB_OPTIONS_SHOW_MODULE_TEXT_SKETCH
,
ID_TB_OPTIONS_SHOW_MODULE_EDGE_SKETCH
,
ID_TB_OPTIONS_SHOW_MODULE_EDGE_SKETCH
,
...
...
include/wxstruct.h
View file @
91530e7a
...
@@ -110,8 +110,20 @@ public:
...
@@ -110,8 +110,20 @@ public:
void
GetKicadHelp
(
wxCommandEvent
&
event
);
void
GetKicadHelp
(
wxCommandEvent
&
event
);
void
GetKicadAbout
(
wxCommandEvent
&
event
);
void
GetKicadAbout
(
wxCommandEvent
&
event
);
/**
* Copy the version information to the clipboard for bug reporting purposes.
*/
void
CopyVersionInfoToClipboard
(
wxCommandEvent
&
event
);
void
PrintMsg
(
const
wxString
&
text
);
void
PrintMsg
(
const
wxString
&
text
);
/**
* Append the copy version information to clipboard help menu entry to \a aMenu.
*
* @param aMenu - The menu to append.
*/
void
AddHelpVersionInfoMenuEntry
(
wxMenu
*
aMenu
);
virtual
void
LoadSettings
();
virtual
void
LoadSettings
();
virtual
void
SaveSettings
();
virtual
void
SaveSettings
();
...
@@ -148,7 +160,7 @@ public:
...
@@ -148,7 +160,7 @@ public:
WinEDA_Toolbar
*
m_AuxVToolBar
;
// Auxiliary Vertical (right side)
WinEDA_Toolbar
*
m_AuxVToolBar
;
// Auxiliary Vertical (right side)
// Toolbar
// Toolbar
WinEDA_Toolbar
*
m_OptionsToolBar
;
// Options Toolbar (left side)
WinEDA_Toolbar
*
m_OptionsToolBar
;
// Options Toolbar (left side)
WinEDA_Toolbar
*
m_AuxiliaryToolBar
;
// Auxiliay Toolbar used in pcbnew
WinEDA_Toolbar
*
m_AuxiliaryToolBar
;
// Auxilia
r
y Toolbar used in pcbnew
WinEDAChoiceBox
*
m_SelGridBox
;
// Choice box to choose the grid
WinEDAChoiceBox
*
m_SelGridBox
;
// Choice box to choose the grid
// size
// size
...
@@ -254,9 +266,9 @@ public:
...
@@ -254,9 +266,9 @@ public:
*/
*/
virtual
void
SetToolID
(
int
aId
,
int
aCursor
,
const
wxString
&
aToolMsg
);
virtual
void
SetToolID
(
int
aId
,
int
aCursor
,
const
wxString
&
aToolMsg
);
/* Thes
4 functions provide a basic way to sho
/hide grid
/* Thes
e 4 functions provide a basic way to show
/hide grid
* and /get/set grid color.
* and /get/set grid color.
*
thes
parameters are saved in kicad config for each main frame
*
These
parameters are saved in kicad config for each main frame
*/
*/
/** Function IsGridVisible() , virtual
/** Function IsGridVisible() , virtual
* @return true if the grid must be shown
* @return true if the grid must be shown
...
@@ -425,8 +437,8 @@ public:
...
@@ -425,8 +437,8 @@ public:
* @param aData = a pointer on an auxiliary data (not always used, NULL if not used)
* @param aData = a pointer on an auxiliary data (not always used, NULL if not used)
*/
*/
virtual
void
PrintPage
(
wxDC
*
aDC
,
bool
aPrint_Sheet_Ref
,
virtual
void
PrintPage
(
wxDC
*
aDC
,
bool
aPrint_Sheet_Ref
,
int
aPrintMask
,
bool
aPrintMirrorMode
,
int
aPrintMask
,
bool
aPrintMirrorMode
,
void
*
aData
=
NULL
);
void
*
aData
=
NULL
);
DECLARE_EVENT_TABLE
();
DECLARE_EVENT_TABLE
();
};
};
...
@@ -520,7 +532,7 @@ public:
...
@@ -520,7 +532,7 @@ public:
* Append a message to the message panel.
* Append a message to the message panel.
*
*
* This method automatically adjusts for the width of the text string.
* This method automatically adjusts for the width of the text string.
* Making consec
t
utive calls to AppendMessage will append each message
* Making consecutive calls to AppendMessage will append each message
* to the right of the last message. This message is not compatible
* to the right of the last message. This message is not compatible
* with Affiche_1_Parametre.
* with Affiche_1_Parametre.
*
*
...
@@ -730,7 +742,7 @@ class WinEDA_Toolbar : public wxAuiToolBar
...
@@ -730,7 +742,7 @@ class WinEDA_Toolbar : public wxAuiToolBar
public
:
public
:
wxWindow
*
m_Parent
;
wxWindow
*
m_Parent
;
id_toolbar
m_Ident
;
id_toolbar
m_Ident
;
bool
m_Horizontal
;
// some auxilary TB are horizontal, others vertical
bool
m_Horizontal
;
// some auxil
i
ary TB are horizontal, others vertical
public
:
public
:
WinEDA_Toolbar
(
id_toolbar
type
,
wxWindow
*
parent
,
WinEDA_Toolbar
(
id_toolbar
type
,
wxWindow
*
parent
,
...
...
kicad/menubar.cpp
View file @
91530e7a
...
@@ -167,7 +167,7 @@ void WinEDA_MainFrame::ReCreateMenuBar()
...
@@ -167,7 +167,7 @@ void WinEDA_MainFrame::ReCreateMenuBar()
/* Text editor */
/* Text editor */
item
=
new
wxMenuItem
(
browseMenu
,
ID_TO_EDITOR
,
_
(
"Text E&ditor"
),
item
=
new
wxMenuItem
(
browseMenu
,
ID_TO_EDITOR
,
_
(
"Text E&ditor"
),
_
(
"Open prefered text editor"
)
);
_
(
"Open prefer
r
ed text editor"
)
);
#if !defined( __WXMAC__ )
#if !defined( __WXMAC__ )
item
->
SetBitmap
(
editor_xpm
);
item
->
SetBitmap
(
editor_xpm
);
#endif
/* !defined( __WXMAC__ ) */
#endif
/* !defined( __WXMAC__ ) */
...
@@ -194,7 +194,7 @@ void WinEDA_MainFrame::ReCreateMenuBar()
...
@@ -194,7 +194,7 @@ void WinEDA_MainFrame::ReCreateMenuBar()
/* Text editor */
/* Text editor */
item
=
new
wxMenuItem
(
PreferencesMenu
,
ID_SELECT_PREFERED_EDITOR
,
item
=
new
wxMenuItem
(
PreferencesMenu
,
ID_SELECT_PREFERED_EDITOR
,
_
(
"&Text Editor"
),
_
(
"&Text Editor"
),
_
(
"Select your prefered text editor"
)
);
_
(
"Select your prefer
r
ed text editor"
)
);
#if !defined( __WXMAC__ )
#if !defined( __WXMAC__ )
item
->
SetBitmap
(
editor_xpm
);
item
->
SetBitmap
(
editor_xpm
);
#endif
/* !defined( __WXMAC__ ) */
#endif
/* !defined( __WXMAC__ ) */
...
@@ -264,9 +264,12 @@ void WinEDA_MainFrame::ReCreateMenuBar()
...
@@ -264,9 +264,12 @@ void WinEDA_MainFrame::ReCreateMenuBar()
*/
*/
wxMenu
*
helpMenu
=
new
wxMenu
;
wxMenu
*
helpMenu
=
new
wxMenu
;
AddHelpVersionInfoMenuEntry
(
helpMenu
);
/* Contents */
/* Contents */
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
_
(
"Open the kicad manual"
)
);
_
(
"Open the kicad manual"
)
);
#if !defined( __WXMAC__ )
#if !defined( __WXMAC__ )
item
->
SetBitmap
(
online_help_xpm
);
item
->
SetBitmap
(
online_help_xpm
);
#endif
/* !defined( __WXMAC__ ) */
#endif
/* !defined( __WXMAC__ ) */
...
@@ -343,4 +346,3 @@ void WinEDA_MainFrame::RecreateBaseHToolbar()
...
@@ -343,4 +346,3 @@ void WinEDA_MainFrame::RecreateBaseHToolbar()
/* Create m_HToolBar */
/* Create m_HToolBar */
m_HToolBar
->
Realize
();
m_HToolBar
->
Realize
();
}
}
pcbnew/menubar_modedit.cpp
View file @
91530e7a
...
@@ -22,295 +22,294 @@ void WinEDA_ModuleEditFrame::ReCreateMenuBar()
...
@@ -22,295 +22,294 @@ void WinEDA_ModuleEditFrame::ReCreateMenuBar()
if
(
menuBar
)
if
(
menuBar
)
return
;
return
;
menuBar
=
new
wxMenuBar
();
menuBar
=
new
wxMenuBar
();
/* File menu */
/* File menu */
wxMenu
*
fileMenu
=
new
wxMenu
;
wxMenu
*
fileMenu
=
new
wxMenu
;
/* New module */
/* New module */
item
=
new
wxMenuItem
(
fileMenu
,
item
=
new
wxMenuItem
(
fileMenu
,
ID_MODEDIT_NEW_MODULE
,
ID_MODEDIT_NEW_MODULE
,
_
(
"New Module"
),
_
(
"New Module"
),
_
(
"Create new module"
)
);
_
(
"Create new module"
)
);
item
->
SetBitmap
(
new_footprint_xpm
);
item
->
SetBitmap
(
new_footprint_xpm
);
fileMenu
->
Append
(
item
);
fileMenu
->
Append
(
item
);
/* Open submenu */
/* Open submenu */
wxMenu
*
openSubmenu
=
new
wxMenu
;
wxMenu
*
openSubmenu
=
new
wxMenu
;
/* from File */
/* from File */
item
=
new
wxMenuItem
(
openSubmenu
,
item
=
new
wxMenuItem
(
openSubmenu
,
ID_MODEDIT_IMPORT_PART
,
ID_MODEDIT_IMPORT_PART
,
_
(
"from File (Import)"
),
_
(
"from File (Import)"
),
_
(
"Import a footprint from an existing file"
)
);
_
(
"Import a footprint from an existing file"
)
);
item
->
SetBitmap
(
import_module_xpm
);
item
->
SetBitmap
(
import_module_xpm
);
openSubmenu
->
Append
(
item
);
openSubmenu
->
Append
(
item
);
/* from Library */
/* from Library */
item
=
new
wxMenuItem
(
openSubmenu
,
item
=
new
wxMenuItem
(
openSubmenu
,
ID_MODEDIT_LOAD_MODULE
,
ID_MODEDIT_LOAD_MODULE
,
_
(
"Load from Library"
),
_
(
"Load from Library"
),
_
(
"Open a footprint module from a Library"
)
);
_
(
"Open a footprint module from a Library"
)
);
item
->
SetBitmap
(
module_xpm
);
item
->
SetBitmap
(
module_xpm
);
openSubmenu
->
Append
(
item
);
openSubmenu
->
Append
(
item
);
/* from current Board */
/* from current Board */
item
=
new
wxMenuItem
(
openSubmenu
,
item
=
new
wxMenuItem
(
openSubmenu
,
ID_MODEDIT_LOAD_MODULE_FROM_BOARD
,
ID_MODEDIT_LOAD_MODULE_FROM_BOARD
,
_
(
"Load from current Board"
),
_
(
"Load from current Board"
),
_
(
"Load a footprint module from the current loaded board"
)
);
_
(
"Load a footprint module from the current loaded board"
)
);
item
->
SetBitmap
(
load_module_board_xpm
);
item
->
SetBitmap
(
load_module_board_xpm
);
openSubmenu
->
Append
(
item
);
openSubmenu
->
Append
(
item
);
/* Append openSubmenu to fileMenu */
/* Append openSubmenu to fileMenu */
ADD_MENUITEM_WITH_HELP_AND_SUBMENU
(
fileMenu
,
openSubmenu
,
-
1
,
ADD_MENUITEM_WITH_HELP_AND_SUBMENU
(
fileMenu
,
openSubmenu
,
-
1
,
_
(
"&Load Module"
),
_
(
"&Load Module"
),
_
(
"Load a footprint module"
),
open_xpm
);
_
(
"Load a footprint module"
),
open_xpm
);
/* Save module */
/* Save module */
item
=
new
wxMenuItem
(
fileMenu
,
ID_MODEDIT_SAVE_LIBMODULE
,
item
=
new
wxMenuItem
(
fileMenu
,
ID_MODEDIT_SAVE_LIBMODULE
,
_
(
"&Save Module in Current Lib"
),
_
(
"&Save Module in Current Lib"
),
_
(
"Save Module in working library"
)
);
_
(
"Save Module in working library"
)
);
item
->
SetBitmap
(
save_library_xpm
);
item
->
SetBitmap
(
save_library_xpm
);
fileMenu
->
Append
(
item
);
fileMenu
->
Append
(
item
);
item
=
new
wxMenuItem
(
fileMenu
,
item
=
new
wxMenuItem
(
fileMenu
,
ID_MODEDIT_CREATE_NEW_LIB_AND_SAVE_CURRENT_PART
,
ID_MODEDIT_CREATE_NEW_LIB_AND_SAVE_CURRENT_PART
,
_
(
"&Save Module in a New Lib"
),
_
(
"&Save Module in a New Lib"
),
_
(
"Create new library and save current module"
)
);
_
(
"Create new library and save current module"
)
);
item
->
SetBitmap
(
new_library_xpm
);
item
->
SetBitmap
(
new_library_xpm
);
fileMenu
->
Append
(
item
);
fileMenu
->
Append
(
item
);
item
=
new
wxMenuItem
(
fileMenu
,
item
=
new
wxMenuItem
(
fileMenu
,
ID_MODEDIT_EXPORT_PART
,
ID_MODEDIT_EXPORT_PART
,
_
(
"&Export module"
),
_
(
"&Export module"
),
_
(
"Save the current loaded module to a file on the harddisk"
)
);
_
(
"Save the current loaded module to a file"
)
);
item
->
SetBitmap
(
export_module_xpm
);
item
->
SetBitmap
(
export_module_xpm
);
fileMenu
->
Append
(
item
);
fileMenu
->
Append
(
item
);
/* Separator */
/* Separator */
fileMenu
->
AppendSeparator
();
fileMenu
->
AppendSeparator
();
/* Print */
/* Print */
item
=
new
wxMenuItem
(
fileMenu
,
wxID_PRINT
,
_
(
"&Print"
),
item
=
new
wxMenuItem
(
fileMenu
,
wxID_PRINT
,
_
(
"&Print"
),
_
(
"Print the current module"
)
);
_
(
"Print the current module"
)
);
item
->
SetBitmap
(
plot_xpm
);
item
->
SetBitmap
(
plot_xpm
);
fileMenu
->
Append
(
item
);
fileMenu
->
Append
(
item
);
/* Separator */
/* Separator */
fileMenu
->
AppendSeparator
();
fileMenu
->
AppendSeparator
();
/* Close editor */
/* Close editor */
item
=
new
wxMenuItem
(
fileMenu
,
wxID_EXIT
,
_
(
"Close"
),
item
=
new
wxMenuItem
(
fileMenu
,
wxID_EXIT
,
_
(
"Close"
),
_
(
"Close the footprint editor"
)
);
_
(
"Close the footprint editor"
)
);
item
->
SetBitmap
(
exit_xpm
);
item
->
SetBitmap
(
exit_xpm
);
fileMenu
->
Append
(
item
);
fileMenu
->
Append
(
item
);
/* Edit menu */
/* Edit menu */
wxMenu
*
editMenu
=
new
wxMenu
;
wxMenu
*
editMenu
=
new
wxMenu
;
/* Undo */
/* Undo */
item
=
new
wxMenuItem
(
editMenu
,
item
=
new
wxMenuItem
(
editMenu
,
wxID_UNDO
,
wxID_UNDO
,
_
(
"Undo"
),
_
(
"Undo"
),
_
(
"Undo last edit"
)
);
_
(
"Undo last edit"
)
);
item
->
SetBitmap
(
undo_xpm
);
item
->
SetBitmap
(
undo_xpm
);
editMenu
->
Append
(
item
);
editMenu
->
Append
(
item
);
/* Redo */
/* Redo */
item
=
new
wxMenuItem
(
editMenu
,
item
=
new
wxMenuItem
(
editMenu
,
wxID_REDO
,
wxID_REDO
,
_
(
"Redo"
),
_
(
"Redo"
),
_
(
"Redo the last undo action"
)
);
_
(
"Redo the last undo action"
)
);
item
->
SetBitmap
(
redo_xpm
);
item
->
SetBitmap
(
redo_xpm
);
editMenu
->
Append
(
item
);
editMenu
->
Append
(
item
);
/* Delete items */
/* Delete items */
item
=
new
wxMenuItem
(
editMenu
,
item
=
new
wxMenuItem
(
editMenu
,
ID_MODEDIT_DELETE_ITEM_BUTT
,
ID_MODEDIT_DELETE_ITEM_BUTT
,
_
(
"Delete"
),
_
(
"Delete"
),
_
(
"Delete objects with the eraser"
)
);
_
(
"Delete objects with the eraser"
)
);
item
->
SetBitmap
(
delete_body_xpm
);
item
->
SetBitmap
(
delete_body_xpm
);
editMenu
->
Append
(
item
);
editMenu
->
Append
(
item
);
/* Separator */
/* Separator */
editMenu
->
AppendSeparator
();
editMenu
->
AppendSeparator
();
/* Properties */
/* Properties */
item
=
new
wxMenuItem
(
editMenu
,
item
=
new
wxMenuItem
(
editMenu
,
ID_MODEDIT_EDIT_MODULE_PROPERTIES
,
ID_MODEDIT_EDIT_MODULE_PROPERTIES
,
_
(
"Properties"
),
_
(
"Properties"
),
_
(
"Edit module properties"
)
);
_
(
"Edit module properties"
)
);
item
->
SetBitmap
(
module_options_xpm
);
item
->
SetBitmap
(
module_options_xpm
);
editMenu
->
Append
(
item
);
editMenu
->
Append
(
item
);
/* Dimensions submenu */
/* Dimensions submenu */
wxMenu
*
dimensions_Submenu
=
new
wxMenu
;
wxMenu
*
dimensions_Submenu
=
new
wxMenu
;
/* Sizes and Widths */
/* Sizes and Widths */
item
=
new
wxMenuItem
(
dimensions_Submenu
,
item
=
new
wxMenuItem
(
dimensions_Submenu
,
ID_PCB_DRAWINGS_WIDTHS_SETUP
,
ID_PCB_DRAWINGS_WIDTHS_SETUP
,
_
(
"Sizes and Widths"
),
_
(
"Sizes and Widths"
),
_
(
"Adjust width for texts and drawings"
)
);
_
(
"Adjust width for texts and drawings"
)
);
item
->
SetBitmap
(
options_text_xpm
);
item
->
SetBitmap
(
options_text_xpm
);
dimensions_Submenu
->
Append
(
item
);
dimensions_Submenu
->
Append
(
item
);
/* Pad settings */
item
=
new
wxMenuItem
(
dimensions_Submenu
,
/* Pad settings */
ID_MODEDIT_PAD_SETTINGS
,
item
=
new
wxMenuItem
(
dimensions_Submenu
,
_
(
"Pad settings"
),
ID_MODEDIT_PAD_SETTINGS
,
_
(
"Edit the settings for new pads"
)
);
_
(
"Pad settings"
),
item
->
SetBitmap
(
options_pad_xpm
);
_
(
"Edit the settings for new pads"
)
);
dimensions_Submenu
->
Append
(
item
);
item
->
SetBitmap
(
options_pad_xpm
);
dimensions_Submenu
->
Append
(
item
);
/* User Grid Size */
item
=
new
wxMenuItem
(
dimensions_Submenu
,
/* User Grid Size */
ID_PCB_USER_GRID_SETUP
,
item
=
new
wxMenuItem
(
dimensions_Submenu
,
_
(
"User Grid Size"
),
ID_PCB_USER_GRID_SETUP
,
_
(
"Adjust user grid"
)
);
_
(
"User Grid Size"
),
item
->
SetBitmap
(
grid_xpm
);
_
(
"Adjust user grid"
)
);
dimensions_Submenu
->
Append
(
item
);
item
->
SetBitmap
(
grid_xpm
);
dimensions_Submenu
->
Append
(
item
);
/* Append dimensions_Submenu to editMenu */
ADD_MENUITEM_WITH_HELP_AND_SUBMENU
(
editMenu
,
/* Append dimensions_Submenu to editMenu */
dimensions_Submenu
,
-
1
,
ADD_MENUITEM_WITH_HELP_AND_SUBMENU
(
editMenu
,
_
(
"&Dimensions"
),
dimensions_Submenu
,
-
1
,
_
(
"Edit dimensions preferences"
),
_
(
"&Dimensions"
),
add_dimension_xpm
);
_
(
"Edit dimensions preferences"
),
add_dimension_xpm
);
/* View menu */
wxMenu
*
viewMenu
=
new
wxMenu
;
/* View menu */
wxMenu
*
viewMenu
=
new
wxMenu
;
/* Zoom In */
item
=
new
wxMenuItem
(
viewMenu
,
/* Zoom In */
ID_ZOOM_IN
,
item
=
new
wxMenuItem
(
viewMenu
,
_
(
"Zoom In"
),
ID_ZOOM_IN
,
_
(
"Zoom in on the module"
)
);
_
(
"Zoom In"
),
item
->
SetBitmap
(
zoom_in_xpm
);
_
(
"Zoom in on the module"
)
);
viewMenu
->
Append
(
item
);
item
->
SetBitmap
(
zoom_in_xpm
);
viewMenu
->
Append
(
item
);
/* Zoom Out */
item
=
new
wxMenuItem
(
viewMenu
,
/* Zoom Out */
ID_ZOOM_OUT
,
item
=
new
wxMenuItem
(
viewMenu
,
_
(
"Zoom Out"
),
ID_ZOOM_OUT
,
_
(
"Zoom out on the module"
)
);
_
(
"Zoom Out"
),
item
->
SetBitmap
(
zoom_out_xpm
);
_
(
"Zoom out on the module"
)
);
viewMenu
->
Append
(
item
);
item
->
SetBitmap
(
zoom_out_xpm
);
viewMenu
->
Append
(
item
);
/* Fit on Screen */
item
=
new
wxMenuItem
(
viewMenu
,
/* Fit on Screen */
ID_ZOOM_PAGE
,
item
=
new
wxMenuItem
(
viewMenu
,
_
(
"Fit on Screen"
),
ID_ZOOM_PAGE
,
_
(
"Zoom and fit the module in the window"
)
);
_
(
"Fit on Screen"
),
item
->
SetBitmap
(
zoom_auto_xpm
);
_
(
"Zoom and fit the module in the window"
)
);
viewMenu
->
Append
(
item
);
item
->
SetBitmap
(
zoom_auto_xpm
);
viewMenu
->
Append
(
item
);
/* Separator */
viewMenu
->
AppendSeparator
();
/* Separator */
viewMenu
->
AppendSeparator
();
/* Redraw */
item
=
new
wxMenuItem
(
viewMenu
,
/* Redraw */
ID_ZOOM_REDRAW
,
item
=
new
wxMenuItem
(
viewMenu
,
_
(
"Redraw"
),
ID_ZOOM_REDRAW
,
_
(
"Redraw the window's viewport"
)
);
_
(
"Redraw"
),
item
->
SetBitmap
(
zoom_redraw_xpm
);
_
(
"Redraw the window's viewport"
)
);
viewMenu
->
Append
(
item
);
item
->
SetBitmap
(
zoom_redraw_xpm
);
viewMenu
->
Append
(
item
);
/* 3D Viewer */
item
=
new
wxMenuItem
(
viewMenu
,
/* 3D Viewer */
ID_MENU_PCB_SHOW_3D_FRAME
,
item
=
new
wxMenuItem
(
viewMenu
,
_
(
"3D View"
),
ID_MENU_PCB_SHOW_3D_FRAME
,
_
(
"Show board in 3D viewer"
)
);
_
(
"3D View"
),
item
->
SetBitmap
(
show_3d_xpm
);
_
(
"Show board in 3D viewer"
)
);
viewMenu
->
Append
(
item
);
item
->
SetBitmap
(
show_3d_xpm
);
viewMenu
->
Append
(
item
);
/* Place menu */
wxMenu
*
placeMenu
=
new
wxMenu
;
/* Place menu */
wxMenu
*
placeMenu
=
new
wxMenu
;
/* Pad */
item
=
new
wxMenuItem
(
placeMenu
,
/* Pad */
ID_MODEDIT_ADD_PAD
,
item
=
new
wxMenuItem
(
placeMenu
,
_
(
"Pad"
),
ID_MODEDIT_ADD_PAD
,
_
(
"Add Pads"
)
);
_
(
"Pad"
),
item
->
SetBitmap
(
pad_xpm
);
_
(
"Add Pads"
)
);
placeMenu
->
Append
(
item
);
item
->
SetBitmap
(
pad_xpm
);
placeMenu
->
Append
(
item
);
/* Separator */
placeMenu
->
AppendSeparator
();
/* Separator */
placeMenu
->
AppendSeparator
();
/* Circle */
item
=
new
wxMenuItem
(
placeMenu
,
/* Circle */
ID_PCB_CIRCLE_BUTT
,
item
=
new
wxMenuItem
(
placeMenu
,
_
(
"Circle"
),
ID_PCB_CIRCLE_BUTT
,
_
(
"Add graphic circle"
)
);
_
(
"Circle"
),
item
->
SetBitmap
(
add_circle_xpm
);
_
(
"Add graphic circle"
)
);
placeMenu
->
Append
(
item
);
item
->
SetBitmap
(
add_circle_xpm
);
placeMenu
->
Append
(
item
);
/* Line or Polygon */
item
=
new
wxMenuItem
(
placeMenu
,
ID_PCB_ADD_LINE_BUTT
,
/* Line or Polygon */
_
(
"Line or Polygon"
),
item
=
new
wxMenuItem
(
placeMenu
,
_
(
"Add graphic line or polygon"
)
);
ID_PCB_ADD_LINE_BUTT
,
item
->
SetBitmap
(
add_polygon_xpm
);
_
(
"Line or Polygon"
),
placeMenu
->
Append
(
item
);
_
(
"Add graphic line or polygon"
)
);
item
->
SetBitmap
(
add_polygon_xpm
);
/* Arc */
placeMenu
->
Append
(
item
);
item
=
new
wxMenuItem
(
placeMenu
,
ID_PCB_ARC_BUTT
,
/* Arc */
_
(
"Arc"
),
item
=
new
wxMenuItem
(
placeMenu
,
_
(
"Add graphic arc"
)
);
ID_PCB_ARC_BUTT
,
item
->
SetBitmap
(
add_arc_xpm
);
_
(
"Arc"
),
placeMenu
->
Append
(
item
);
_
(
"Add graphic arc"
)
);
item
->
SetBitmap
(
add_arc_xpm
);
/* Text */
placeMenu
->
Append
(
item
);
item
=
new
wxMenuItem
(
placeMenu
,
ID_PCB_ADD_TEXT_BUTT
,
/* Text */
_
(
"Text"
),
item
=
new
wxMenuItem
(
placeMenu
,
_
(
"Add graphic text"
)
);
ID_PCB_ADD_TEXT_BUTT
,
item
->
SetBitmap
(
add_text_xpm
);
_
(
"Text"
),
placeMenu
->
Append
(
item
);
_
(
"Add graphic text"
)
);
item
->
SetBitmap
(
add_text_xpm
);
/* Anchor */
placeMenu
->
Append
(
item
);
placeMenu
->
AppendSeparator
();
item
=
new
wxMenuItem
(
placeMenu
,
/* Anchor */
ID_MODEDIT_PLACE_ANCHOR
,
placeMenu
->
AppendSeparator
();
_
(
"Anchor"
),
item
=
new
wxMenuItem
(
placeMenu
,
_
(
"Place the footprint module reference anchor"
)
);
ID_MODEDIT_PLACE_ANCHOR
,
item
->
SetBitmap
(
anchor_xpm
);
_
(
"Anchor"
),
placeMenu
->
Append
(
item
);
_
(
"Place the footprint module reference anchor"
)
);
item
->
SetBitmap
(
anchor_xpm
);
placeMenu
->
Append
(
item
);
/* Help menu */
wxMenu
*
helpMenu
=
new
wxMenu
;
/* Help menu */
AddHelpVersionInfoMenuEntry
(
helpMenu
);
wxMenu
*
helpMenu
=
new
wxMenu
;
/* Contents */
/* Contents */
item
=
new
wxMenuItem
(
helpMenu
,
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
_
(
"&Contents"
),
_
(
"Open the PCBNew manual"
)
);
_
(
"Open the PCBNew pdf manual"
)
);
item
->
SetBitmap
(
online_help_xpm
);
item
->
SetBitmap
(
online_help_xpm
);
helpMenu
->
Append
(
item
);
helpMenu
->
Append
(
item
);
/* About PCBNew */
/* About PCBNew */
item
=
new
wxMenuItem
(
helpMenu
,
item
=
new
wxMenuItem
(
helpMenu
,
ID_KICAD_ABOUT
,
ID_KICAD_ABOUT
,
_
(
"&About PCBNew"
),
_
(
"&About PCBNew"
),
_
(
"About PCBNew PCB designer"
)
);
_
(
"About PCBNew PCB designer"
)
);
item
->
SetBitmap
(
info_xpm
);
item
->
SetBitmap
(
info_xpm
);
helpMenu
->
Append
(
item
);
helpMenu
->
Append
(
item
);
/* Append all the menu's to the menubar */
/* Append all the menu's to the menubar */
menuBar
->
Append
(
fileMenu
,
_
(
"&File"
)
);
menuBar
->
Append
(
fileMenu
,
_
(
"&File"
)
);
menuBar
->
Append
(
editMenu
,
_
(
"&Edit"
)
);
menuBar
->
Append
(
editMenu
,
_
(
"&Edit"
)
);
menuBar
->
Append
(
viewMenu
,
_
(
"&View"
)
);
menuBar
->
Append
(
viewMenu
,
_
(
"&View"
)
);
menuBar
->
Append
(
placeMenu
,
_
(
"&Place"
)
);
menuBar
->
Append
(
placeMenu
,
_
(
"&Place"
)
);
menuBar
->
Append
(
helpMenu
,
_
(
"&Help"
)
);
menuBar
->
Append
(
helpMenu
,
_
(
"&Help"
)
);
/* Associate the menu bar with the frame */
/* Associate the menu bar with the frame */
SetMenuBar
(
menuBar
);
SetMenuBar
(
menuBar
);
}
}
pcbnew/menubar_pcbframe.cpp
View file @
91530e7a
...
@@ -196,7 +196,7 @@ void WinEDA_PcbFrame::ReCreateMenuBar()
...
@@ -196,7 +196,7 @@ void WinEDA_PcbFrame::ReCreateMenuBar()
/* Print */
/* Print */
item
=
new
wxMenuItem
(
filesMenu
,
wxID_PRINT
,
_
(
"&Print"
),
item
=
new
wxMenuItem
(
filesMenu
,
wxID_PRINT
,
_
(
"&Print"
),
_
(
"Print
pcb
board"
)
);
_
(
"Print board"
)
);
item
->
SetBitmap
(
print_button
);
item
->
SetBitmap
(
print_button
);
filesMenu
->
Append
(
item
);
filesMenu
->
Append
(
item
);
...
@@ -235,8 +235,7 @@ void WinEDA_PcbFrame::ReCreateMenuBar()
...
@@ -235,8 +235,7 @@ void WinEDA_PcbFrame::ReCreateMenuBar()
#if !defined( __WXMAC__ )
#if !defined( __WXMAC__ )
filesMenu
->
AppendSeparator
();
filesMenu
->
AppendSeparator
();
item
=
new
wxMenuItem
(
filesMenu
,
wxID_EXIT
,
_
(
"&Quit"
),
item
=
new
wxMenuItem
(
filesMenu
,
wxID_EXIT
,
_
(
"&Quit"
),
_
(
"Quit PCBNew"
)
);
_
(
"Quit PCBNew"
)
);
item
->
SetBitmap
(
exit_xpm
);
item
->
SetBitmap
(
exit_xpm
);
filesMenu
->
Append
(
item
);
filesMenu
->
Append
(
item
);
...
@@ -306,9 +305,9 @@ void WinEDA_PcbFrame::ReCreateMenuBar()
...
@@ -306,9 +305,9 @@ void WinEDA_PcbFrame::ReCreateMenuBar()
* we cannot add hotkey info here, because the hotkey HK_ZOOM_IN and HK_ZOOM_OUT
* we cannot add hotkey info here, because the hotkey HK_ZOOM_IN and HK_ZOOM_OUT
* events(default = WXK_F1 and WXK_F2) are *NOT* equivalent to this menu command:
* events(default = WXK_F1 and WXK_F2) are *NOT* equivalent to this menu command:
* zoom in and out from hotkeys are equivalent to the pop up menu zoom
* zoom in and out from hotkeys are equivalent to the pop up menu zoom
* From here, zoom
m
ing is made around the screen center
* From here, zooming is made around the screen center
* From hotkeys, zoom
m
ing is made around the mouse cursor position
* From hotkeys, zooming is made around the mouse cursor position
* (obviou
lsy not possible from the toolbat
or menubar command)
* (obviou
sly not possible from the toolbar
or menubar command)
*
*
* in others words HK_ZOOM_IN and HK_ZOOM_OUT *are NOT* accelerators
* in others words HK_ZOOM_IN and HK_ZOOM_OUT *are NOT* accelerators
* for Zoom in and Zoom out sub menus
* for Zoom in and Zoom out sub menus
...
@@ -487,6 +486,9 @@ void WinEDA_PcbFrame::ReCreateMenuBar()
...
@@ -487,6 +486,9 @@ void WinEDA_PcbFrame::ReCreateMenuBar()
* Help menu
* Help menu
*/
*/
wxMenu
*
helpMenu
=
new
wxMenu
;
wxMenu
*
helpMenu
=
new
wxMenu
;
AddHelpVersionInfoMenuEntry
(
helpMenu
);
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
item
=
new
wxMenuItem
(
helpMenu
,
ID_GENERAL_HELP
,
_
(
"&Contents"
),
_
(
"Open the PCBnew manual"
)
);
_
(
"Open the PCBnew manual"
)
);
item
->
SetBitmap
(
online_help_xpm
);
item
->
SetBitmap
(
online_help_xpm
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment