From d944e67a69b14e8c78e8105a066e1ede9f3d3597 Mon Sep 17 00:00:00 2001 From: Wayne Stambaugh Date: Sat, 9 Nov 2013 11:30:49 -0500 Subject: [PATCH] Eeschema multiple unit component nomenclature improvements (fixes 1226874). * Replace all occurrences of the word "part" with "unit" when referring to multiple unit components for improved consistency. * Replace "shared by" with "common to" when referring to objects (lines, arcs, pins, etc.) that are common to all units. * Improve wording in library component properties dialog. --- .../dialog_edit_component_in_lib_base.cpp | 48 +++---- .../dialog_edit_component_in_lib_base.fbp | 50 +++---- .../dialog_edit_component_in_lib_base.h | 2 +- .../dialogs/dialog_lib_edit_draw_item.fbp | 130 ++++++------------ .../dialog_lib_edit_draw_item_base.cpp | 15 +- .../dialogs/dialog_lib_edit_draw_item_base.h | 4 +- eeschema/dialogs/dialog_lib_edit_pin_base.cpp | 4 +- eeschema/dialogs/dialog_lib_edit_pin_base.fbp | 4 +- .../dialogs/dialog_lib_edit_text_base.cpp | 16 +-- .../dialogs/dialog_lib_edit_text_base.fbp | 14 +- eeschema/dialogs/dialog_lib_edit_text_base.h | 2 +- eeschema/dialogs/dialog_lib_new_component.fbp | 2 +- .../dialogs/dialog_lib_new_component_base.cpp | 6 +- .../dialogs/dialog_lib_new_component_base.h | 4 +- eeschema/libedit.cpp | 14 +- eeschema/libeditframe.cpp | 23 ++-- eeschema/menubar_libedit.cpp | 2 +- eeschema/sch_component.cpp | 5 +- eeschema/tool_viewlib.cpp | 8 +- eeschema/viewlib_frame.cpp | 7 +- 20 files changed, 161 insertions(+), 199 deletions(-) diff --git a/eeschema/dialogs/dialog_edit_component_in_lib_base.cpp b/eeschema/dialogs/dialog_edit_component_in_lib_base.cpp index 6f9b889844..bd98cc4053 100644 --- a/eeschema/dialogs/dialog_edit_component_in_lib_base.cpp +++ b/eeschema/dialogs/dialog_edit_component_in_lib_base.cpp @@ -19,32 +19,32 @@ DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE::DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wx wxBoxSizer* bUpperSizer; bUpperSizer = new wxBoxSizer( wxVERTICAL ); - m_NoteBook = new wxNotebook( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0 ); - m_PanelBasic = new wxPanel( m_NoteBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSUNKEN_BORDER|wxTAB_TRAVERSAL ); + m_NoteBook = new wxNotebook( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, 0|wxTAB_TRAVERSAL ); + m_PanelBasic = new wxPanel( m_NoteBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); wxBoxSizer* bSizerBasicPanel; bSizerBasicPanel = new wxBoxSizer( wxVERTICAL ); wxStaticBoxSizer* m_OptionsBoxSizer; - m_OptionsBoxSizer = new wxStaticBoxSizer( new wxStaticBox( m_PanelBasic, wxID_ANY, _("General :") ), wxVERTICAL ); + m_OptionsBoxSizer = new wxStaticBoxSizer( new wxStaticBox( m_PanelBasic, wxID_ANY, _("General") ), wxVERTICAL ); - m_AsConvertButt = new wxCheckBox( m_PanelBasic, wxID_ANY, _("As Convert"), wxDefaultPosition, wxDefaultSize, 0 ); - m_AsConvertButt->SetToolTip( _("Check this option for components that have a De Morgan representation.\nThis is usual for gates.") ); + m_AsConvertButt = new wxCheckBox( m_PanelBasic, wxID_ANY, _("Has alternate symbol (DeMorgan)"), wxDefaultPosition, wxDefaultSize, 0 ); + m_AsConvertButt->SetToolTip( _("Check this option if the component has an alternate body style (De Morgan)") ); m_OptionsBoxSizer->Add( m_AsConvertButt, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); - m_ShowPinNumButt = new wxCheckBox( m_PanelBasic, wxID_ANY, _("Show Pin Num"), wxDefaultPosition, wxDefaultSize, 0 ); + m_ShowPinNumButt = new wxCheckBox( m_PanelBasic, wxID_ANY, _("Show pin number"), wxDefaultPosition, wxDefaultSize, 0 ); m_ShowPinNumButt->SetValue(true); m_ShowPinNumButt->SetToolTip( _("Show or hide pin numbers") ); m_OptionsBoxSizer->Add( m_ShowPinNumButt, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); - m_ShowPinNameButt = new wxCheckBox( m_PanelBasic, wxID_ANY, _("Show Pin Name"), wxDefaultPosition, wxDefaultSize, 0 ); + m_ShowPinNameButt = new wxCheckBox( m_PanelBasic, wxID_ANY, _("Show pin name"), wxDefaultPosition, wxDefaultSize, 0 ); m_ShowPinNameButt->SetValue(true); m_ShowPinNameButt->SetToolTip( _("Show or hide pin names") ); m_OptionsBoxSizer->Add( m_ShowPinNameButt, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); - m_PinsNameInsideButt = new wxCheckBox( m_PanelBasic, wxID_ANY, _("Pin Name Inside"), wxDefaultPosition, wxDefaultSize, 0 ); + m_PinsNameInsideButt = new wxCheckBox( m_PanelBasic, wxID_ANY, _("Place pin names inside"), wxDefaultPosition, wxDefaultSize, 0 ); m_PinsNameInsideButt->SetValue(true); m_PinsNameInsideButt->SetToolTip( _("Check this option to have pin names inside the body and pin number outside.\nIf not checked pins names and pins numbers are outside.") ); @@ -62,9 +62,9 @@ DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE::DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wx wxBoxSizer* bSizernbunits; bSizernbunits = new wxBoxSizer( wxVERTICAL ); - m_staticTextNbUnits = new wxStaticText( m_PanelBasic, wxID_ANY, _("Number of Units:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_staticTextNbUnits = new wxStaticText( m_PanelBasic, wxID_ANY, _("Number of Units"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextNbUnits->Wrap( -1 ); - m_staticTextNbUnits->SetToolTip( _("This is the number of parts in this component package.\nA 74LS00 gate has 4 parts per packages.") ); + m_staticTextNbUnits->SetToolTip( _("Enter the number of units in for a component that contains more than one unit") ); bSizernbunits->Add( m_staticTextNbUnits, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); @@ -77,7 +77,7 @@ DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE::DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wx wxBoxSizer* bSizer17; bSizer17 = new wxBoxSizer( wxVERTICAL ); - m_staticTextskew = new wxStaticText( m_PanelBasic, wxID_ANY, _("Skew:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_staticTextskew = new wxStaticText( m_PanelBasic, wxID_ANY, _("Pin Name Position Offset"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextskew->Wrap( -1 ); m_staticTextskew->SetToolTip( _("Margin (in 0.001 inches) between a pin name position and the component body.\nA value from 10 to 40 is usually good.") ); @@ -95,13 +95,13 @@ DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE::DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wx m_staticline1 = new wxStaticLine( m_PanelBasic, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); bSizerBasicPanel->Add( m_staticline1, 0, wxEXPAND | wxALL, 5 ); - m_OptionPower = new wxCheckBox( m_PanelBasic, wxID_ANY, _("Power Symbol"), wxDefaultPosition, wxDefaultSize, 0 ); - m_OptionPower->SetToolTip( _("Check this option for power symbols.\nPower symbols have specific properties for Eeschema:\n- Value cannot be edited (to avoid mistakes) because this is the pin name that is important for a power symbol\n- Reference is updated automatically when a netlist is created (no need to run Annotate)") ); + m_OptionPower = new wxCheckBox( m_PanelBasic, wxID_ANY, _("Define as power symbol"), wxDefaultPosition, wxDefaultSize, 0 ); + m_OptionPower->SetToolTip( _("Check this option when the component is a power symbol") ); bSizerBasicPanel->Add( m_OptionPower, 0, wxALL, 5 ); - m_OptionPartsLocked = new wxCheckBox( m_PanelBasic, wxID_ANY, _("Parts are locked"), wxDefaultPosition, wxDefaultSize, 0 ); - m_OptionPartsLocked->SetToolTip( _("Check this option if Eeschema cannot change parts selections inside a given package\nThis happens when parts are different in this package.\nWhen this option is not checked, Eeschema automatically choose the parts in packages to minimize packages count") ); + m_OptionPartsLocked = new wxCheckBox( m_PanelBasic, wxID_ANY, _("All units are not interchangeable"), wxDefaultPosition, wxDefaultSize, 0 ); + m_OptionPartsLocked->SetToolTip( _("Check this option when creating multiple unit components and all units are not interchangeable") ); bSizerBasicPanel->Add( m_OptionPartsLocked, 0, wxALL, 5 ); @@ -110,11 +110,11 @@ DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE::DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wx m_PanelBasic->Layout(); bSizerBasicPanel->Fit( m_PanelBasic ); m_NoteBook->AddPage( m_PanelBasic, _("Options"), true ); - m_PanelDoc = new wxPanel( m_NoteBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSUNKEN_BORDER|wxTAB_TRAVERSAL ); + m_PanelDoc = new wxPanel( m_NoteBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); wxBoxSizer* m_PanelDocBoxSizer; m_PanelDocBoxSizer = new wxBoxSizer( wxVERTICAL ); - m_staticTextDescription = new wxStaticText( m_PanelDoc, wxID_ANY, _("Description:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_staticTextDescription = new wxStaticText( m_PanelDoc, wxID_ANY, _("Description"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextDescription->Wrap( -1 ); m_staticTextDescription->SetToolTip( _("A short description that is displayed in Eeschema.\nCan be a very good help when selecting components in libraries components lists.") ); @@ -124,7 +124,7 @@ DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE::DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wx m_DocCtrl->SetMaxLength( 0 ); m_PanelDocBoxSizer->Add( m_DocCtrl, 0, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 ); - m_staticTextKeywords = new wxStaticText( m_PanelDoc, wxID_ANY, _("Keywords:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_staticTextKeywords = new wxStaticText( m_PanelDoc, wxID_ANY, _("Keywords"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextKeywords->Wrap( -1 ); m_staticTextKeywords->SetToolTip( _("Enter key words that can be used to select this component.\nKey words cannot have spaces and are separated by a space.") ); @@ -134,7 +134,7 @@ DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE::DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wx m_KeywordsCtrl->SetMaxLength( 0 ); m_PanelDocBoxSizer->Add( m_KeywordsCtrl, 0, wxEXPAND|wxBOTTOM|wxRIGHT|wxLEFT, 5 ); - m_staticTextDocFileName = new wxStaticText( m_PanelDoc, wxID_ANY, _("DocFileName:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_staticTextDocFileName = new wxStaticText( m_PanelDoc, wxID_ANY, _("Documentation File Name"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextDocFileName->Wrap( -1 ); m_staticTextDocFileName->SetToolTip( _("Enter the documentation file (a .pdf document) associated to the component.") ); @@ -147,10 +147,10 @@ DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE::DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wx wxBoxSizer* bSizerPaneldocbutts; bSizerPaneldocbutts = new wxBoxSizer( wxHORIZONTAL ); - m_ButtonCopyDoc = new wxButton( m_PanelDoc, ID_COPY_DOC_TO_ALIAS, _("Copy Doc from Parent"), wxDefaultPosition, wxDefaultSize, 0 ); + m_ButtonCopyDoc = new wxButton( m_PanelDoc, ID_COPY_DOC_TO_ALIAS, _("Copy Document from Parent"), wxDefaultPosition, wxDefaultSize, 0 ); bSizerPaneldocbutts->Add( m_ButtonCopyDoc, 0, wxALL, 5 ); - m_buttonBrowseDocFiles = new wxButton( m_PanelDoc, ID_BROWSE_DOC_FILES, _("Browse DocFiles"), wxDefaultPosition, wxDefaultSize, 0 ); + m_buttonBrowseDocFiles = new wxButton( m_PanelDoc, ID_BROWSE_DOC_FILES, _("Browse Files"), wxDefaultPosition, wxDefaultSize, 0 ); bSizerPaneldocbutts->Add( m_buttonBrowseDocFiles, 0, wxALL, 5 ); @@ -161,14 +161,14 @@ DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE::DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wx m_PanelDoc->Layout(); m_PanelDocBoxSizer->Fit( m_PanelDoc ); m_NoteBook->AddPage( m_PanelDoc, _("Description"), false ); - m_PanelAlias = new wxPanel( m_NoteBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSUNKEN_BORDER|wxTAB_TRAVERSAL ); + m_PanelAlias = new wxPanel( m_NoteBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); wxBoxSizer* bSizerMainPanelAlias; bSizerMainPanelAlias = new wxBoxSizer( wxHORIZONTAL ); wxBoxSizer* bLeftBoxSizerPanelAlias; bLeftBoxSizerPanelAlias = new wxBoxSizer( wxVERTICAL ); - m_staticTextAlias = new wxStaticText( m_PanelAlias, wxID_ANY, _("Alias List:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_staticTextAlias = new wxStaticText( m_PanelAlias, wxID_ANY, _("Alias List"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticTextAlias->Wrap( -1 ); m_staticTextAlias->SetToolTip( _("An alias is a component that uses the body of its root component.\nIt has its own documentation and keywords.\nA fast way to extend a library with similar components") ); @@ -200,7 +200,7 @@ DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE::DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wx m_PanelAlias->Layout(); bSizerMainPanelAlias->Fit( m_PanelAlias ); m_NoteBook->AddPage( m_PanelAlias, _("Alias"), false ); - m_PanelFootprintFilter = new wxPanel( m_NoteBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxSUNKEN_BORDER|wxTAB_TRAVERSAL ); + m_PanelFootprintFilter = new wxPanel( m_NoteBook, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxTAB_TRAVERSAL ); wxBoxSizer* bPanelFpFilterBoxSizer; bPanelFpFilterBoxSizer = new wxBoxSizer( wxHORIZONTAL ); diff --git a/eeschema/dialogs/dialog_edit_component_in_lib_base.fbp b/eeschema/dialogs/dialog_edit_component_in_lib_base.fbp index 4db20d476f..6417c11a0e 100644 --- a/eeschema/dialogs/dialog_edit_component_in_lib_base.fbp +++ b/eeschema/dialogs/dialog_edit_component_in_lib_base.fbp @@ -45,7 +45,7 @@ -1,-1 wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER DIALOG_SHIM; dialog_shim.h - Lib Component Properties + Library Component Properties @@ -156,7 +156,7 @@ - + wxTAB_TRAVERSAL @@ -236,7 +236,7 @@ - wxSUNKEN_BORDER|wxTAB_TRAVERSAL + wxTAB_TRAVERSAL @@ -271,7 +271,7 @@ 0 wxID_ANY - General : + General m_OptionsBoxSizer wxVERTICAL @@ -310,7 +310,7 @@ 0 0 wxID_ANY - As Convert + Has alternate symbol (DeMorgan) 0 @@ -331,7 +331,7 @@ 0 - Check this option for components that have a De Morgan representation. This is usual for gates. + Check this option if the component has an alternate body style (De Morgan) wxFILTER_NONE wxDefaultValidator @@ -398,7 +398,7 @@ 0 0 wxID_ANY - Show Pin Num + Show pin number 0 @@ -486,7 +486,7 @@ 0 0 wxID_ANY - Show Pin Name + Show pin name 0 @@ -574,7 +574,7 @@ 0 0 wxID_ANY - Pin Name Inside + Place pin names inside 0 @@ -762,7 +762,7 @@ 0 0 wxID_ANY - Number of Units: + Number of Units 0 @@ -783,7 +783,7 @@ 0 - This is the number of parts in this component package. A 74LS00 gate has 4 parts per packages. + Enter the number of units in for a component that contains more than one unit @@ -943,7 +943,7 @@ 0 0 wxID_ANY - Skew: + Pin Name Position Offset 0 @@ -1199,7 +1199,7 @@ 0 0 wxID_ANY - Power Symbol + Define as power symbol 0 @@ -1220,7 +1220,7 @@ 0 - Check this option for power symbols. Power symbols have specific properties for Eeschema: - Value cannot be edited (to avoid mistakes) because this is the pin name that is important for a power symbol - Reference is updated automatically when a netlist is created (no need to run Annotate) + Check this option when the component is a power symbol wxFILTER_NONE wxDefaultValidator @@ -1287,7 +1287,7 @@ 0 0 wxID_ANY - Parts are locked + All units are not interchangeable 0 @@ -1308,7 +1308,7 @@ 0 - Check this option if Eeschema cannot change parts selections inside a given package This happens when parts are different in this package. When this option is not checked, Eeschema automatically choose the parts in packages to minimize packages count + Check this option when creating multiple unit components and all units are not interchangeable wxFILTER_NONE wxDefaultValidator @@ -1399,7 +1399,7 @@ - wxSUNKEN_BORDER|wxTAB_TRAVERSAL + wxTAB_TRAVERSAL @@ -1460,7 +1460,7 @@ 0 0 wxID_ANY - Description: + Description 0 @@ -1634,7 +1634,7 @@ 0 0 wxID_ANY - Keywords: + Keywords 0 @@ -1808,7 +1808,7 @@ 0 0 wxID_ANY - DocFileName: + Documentation File Name 0 @@ -1992,7 +1992,7 @@ 0 0 ID_COPY_DOC_TO_ALIAS - Copy Doc from Parent + Copy Document from Parent 0 @@ -2080,7 +2080,7 @@ 0 0 ID_BROWSE_DOC_FILES - Browse DocFiles + Browse Files 0 @@ -2194,7 +2194,7 @@ - wxSUNKEN_BORDER|wxTAB_TRAVERSAL + wxTAB_TRAVERSAL @@ -2264,7 +2264,7 @@ 0 0 wxID_ANY - Alias List: + Alias List 0 @@ -2737,7 +2737,7 @@ - wxSUNKEN_BORDER|wxTAB_TRAVERSAL + wxTAB_TRAVERSAL diff --git a/eeschema/dialogs/dialog_edit_component_in_lib_base.h b/eeschema/dialogs/dialog_edit_component_in_lib_base.h index d07b912be2..e627de5431 100644 --- a/eeschema/dialogs/dialog_edit_component_in_lib_base.h +++ b/eeschema/dialogs/dialog_edit_component_in_lib_base.h @@ -109,7 +109,7 @@ class DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE : public DIALOG_SHIM public: - DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wxWindow* parent, wxWindowID id = ID_LIBEDIT_NOTEBOOK, const wxString& title = _("Lib Component Properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); + DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE( wxWindow* parent, wxWindowID id = ID_LIBEDIT_NOTEBOOK, const wxString& title = _("Library Component Properties"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( -1,-1 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER ); ~DIALOG_EDIT_COMPONENT_IN_LIBRARY_BASE(); }; diff --git a/eeschema/dialogs/dialog_lib_edit_draw_item.fbp b/eeschema/dialogs/dialog_lib_edit_draw_item.fbp index bfc8819aed..323b7d37bc 100644 --- a/eeschema/dialogs/dialog_lib_edit_draw_item.fbp +++ b/eeschema/dialogs/dialog_lib_edit_draw_item.fbp @@ -1,11 +1,12 @@ - + C++ 1 source_name + 0 0 res UTF-8 @@ -19,66 +20,33 @@ . 1 + 1 1 1 0 - 1 - 1 - 1 - 1 0 - - + wxAUI_MGR_DEFAULT - - 1 wxBOTH - 0 - 1 1 - 0 - Dock - 0 - Left 1 impl_virtual - 1 - 0 0 wxID_ANY - - - 0 - - 0 - 1 DIALOG_LIB_EDIT_DRAW_ITEM_BASE - 1 - - - 1 - - Resizable - - 1 wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER Drawing Properties - 0 - - wxFILTER_NONE - wxDefaultValidator - @@ -141,7 +109,10 @@ 1 1 1 + + + @@ -162,7 +133,6 @@ 0 wxID_ANY General - 0 @@ -177,19 +147,13 @@ protected 1 - Resizable - 1 0 - - wxFILTER_NONE - wxDefaultValidator - @@ -247,7 +211,10 @@ 1 1 1 + + + @@ -268,7 +235,6 @@ 0 wxID_ANY &Width: - 0 @@ -283,19 +249,13 @@ protected 1 - Resizable - 1 0 - - wxFILTER_NONE - wxDefaultValidator - @@ -344,7 +304,10 @@ 1 1 1 + + + @@ -364,7 +327,6 @@ 0 0 wxID_ANY - 0 @@ -380,9 +342,7 @@ protected 1 - Resizable - 1 @@ -435,7 +395,10 @@ 1 1 1 + + + @@ -456,7 +419,6 @@ 0 wxID_ANY mm - 0 @@ -471,19 +433,13 @@ protected 1 - Resizable - 1 0 - - wxFILTER_NONE - wxDefaultValidator - @@ -524,7 +480,10 @@ 1 1 1 + + + @@ -545,7 +504,6 @@ 0 ID_M_STATICTEXTSHARING Sharing - 0 @@ -560,19 +518,13 @@ protected 1 - Resizable - 1 0 - - wxFILTER_NONE - wxDefaultValidator - @@ -630,7 +582,10 @@ 1 1 1 + + + @@ -651,8 +606,7 @@ 0 0 wxID_ANY - Shared by all &parts in component - + Common to all &units in component 0 @@ -667,9 +621,7 @@ protected 1 - Resizable - 1 @@ -739,7 +691,10 @@ 1 1 1 + + + @@ -760,8 +715,7 @@ 0 0 wxID_ANY - Shared by all body &styles (DeMorgan) - + Common to all body &styles (DeMorgan) 0 @@ -776,9 +730,7 @@ protected 1 - Resizable - 1 @@ -839,7 +791,10 @@ 1 1 1 + + + @@ -860,7 +815,6 @@ 0 wxID_ANY Fill Style - 0 @@ -875,19 +829,13 @@ protected 1 - Resizable - 1 0 - - wxFILTER_NONE - wxDefaultValidator - @@ -954,7 +902,10 @@ 1 1 1 + + + @@ -975,7 +926,6 @@ 0 wxID_ANY Do &not fill - 0 @@ -990,9 +940,7 @@ protected 1 - Resizable - 1 wxRB_GROUP @@ -1042,7 +990,10 @@ 1 1 1 + + + @@ -1063,7 +1014,6 @@ 0 wxID_ANY Fill &foreground - 0 @@ -1078,9 +1028,7 @@ protected 1 - Resizable - 1 @@ -1130,7 +1078,10 @@ 1 1 1 + + + @@ -1151,7 +1102,6 @@ 0 wxID_ANY Fill &background - 0 @@ -1166,9 +1116,7 @@ protected 1 - Resizable - 1 diff --git a/eeschema/dialogs/dialog_lib_edit_draw_item_base.cpp b/eeschema/dialogs/dialog_lib_edit_draw_item_base.cpp index 792a383c0f..a215aa2444 100644 --- a/eeschema/dialogs/dialog_lib_edit_draw_item_base.cpp +++ b/eeschema/dialogs/dialog_lib_edit_draw_item_base.cpp @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Jun 30 2011) +// C++ code generated with wxFormBuilder (version Oct 8 2012) // http://www.wxformbuilder.org/ // // PLEASE DO "NOT" EDIT THIS FILE! @@ -39,12 +39,14 @@ DIALOG_LIB_EDIT_DRAW_ITEM_BASE::DIALOG_LIB_EDIT_DRAW_ITEM_BASE( wxWindow* parent bSizer3->Add( 0, 0, 1, wxEXPAND, 3 ); m_textWidth = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxDefaultSize, 0 ); + m_textWidth->SetMaxLength( 0 ); bSizer3->Add( m_textWidth, 0, wxALIGN_CENTER_VERTICAL|wxALL, 3 ); m_staticWidthUnits = new wxStaticText( this, wxID_ANY, _("mm"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticWidthUnits->Wrap( -1 ); bSizer3->Add( m_staticWidthUnits, 0, wxALIGN_CENTER_VERTICAL|wxALL, 3 ); + dlgBorderSizer->Add( bSizer3, 0, wxALL|wxEXPAND, 0 ); m_staticTextSharing = new wxStaticText( this, ID_M_STATICTEXTSHARING, _("Sharing"), wxDefaultPosition, wxDefaultSize, 0 ); @@ -59,9 +61,10 @@ DIALOG_LIB_EDIT_DRAW_ITEM_BASE::DIALOG_LIB_EDIT_DRAW_ITEM_BASE( wxWindow* parent bSizer4->Add( 12, 0, 0, wxEXPAND, 3 ); - m_checkApplyToAllUnits = new wxCheckBox( this, wxID_ANY, _("Shared by all &parts in component"), wxDefaultPosition, wxDefaultSize, 0 ); + m_checkApplyToAllUnits = new wxCheckBox( this, wxID_ANY, _("Common to all &units in component"), wxDefaultPosition, wxDefaultSize, 0 ); bSizer4->Add( m_checkApplyToAllUnits, 0, wxALIGN_CENTER_VERTICAL|wxALL, 3 ); + dlgBorderSizer->Add( bSizer4, 0, wxALL|wxEXPAND, 0 ); wxBoxSizer* bSizer5; @@ -70,9 +73,10 @@ DIALOG_LIB_EDIT_DRAW_ITEM_BASE::DIALOG_LIB_EDIT_DRAW_ITEM_BASE( wxWindow* parent bSizer5->Add( 12, 0, 0, wxEXPAND, 3 ); - m_checkApplyToAllConversions = new wxCheckBox( this, wxID_ANY, _("Shared by all body &styles (DeMorgan)"), wxDefaultPosition, wxDefaultSize, 0 ); + m_checkApplyToAllConversions = new wxCheckBox( this, wxID_ANY, _("Common to all body &styles (DeMorgan)"), wxDefaultPosition, wxDefaultSize, 0 ); bSizer5->Add( m_checkApplyToAllConversions, 0, wxALIGN_CENTER_VERTICAL|wxALL, 3 ); + dlgBorderSizer->Add( bSizer5, 0, wxEXPAND, 3 ); @@ -103,8 +107,10 @@ DIALOG_LIB_EDIT_DRAW_ITEM_BASE::DIALOG_LIB_EDIT_DRAW_ITEM_BASE( wxWindow* parent m_radioFillBackground = new wxRadioButton( this, wxID_ANY, _("Fill &background"), wxDefaultPosition, wxDefaultSize, 0 ); bSizer7->Add( m_radioFillBackground, 0, wxALL, 3 ); + bSizer6->Add( bSizer7, 0, wxEXPAND, 0 ); + dlgBorderSizer->Add( bSizer6, 1, wxALL|wxEXPAND, 0 ); @@ -116,10 +122,13 @@ DIALOG_LIB_EDIT_DRAW_ITEM_BASE::DIALOG_LIB_EDIT_DRAW_ITEM_BASE( wxWindow* parent m_sdbSizer1Cancel = new wxButton( this, wxID_CANCEL ); m_sdbSizer1->AddButton( m_sdbSizer1Cancel ); m_sdbSizer1->Realize(); + dlgBorderSizer->Add( m_sdbSizer1, 0, wxALL|wxEXPAND, 0 ); + mainSizer->Add( dlgBorderSizer, 1, wxALL|wxEXPAND, 12 ); + this->SetSizer( mainSizer ); this->Layout(); mainSizer->Fit( this ); diff --git a/eeschema/dialogs/dialog_lib_edit_draw_item_base.h b/eeschema/dialogs/dialog_lib_edit_draw_item_base.h index 80d8b364e9..404e108cc5 100644 --- a/eeschema/dialogs/dialog_lib_edit_draw_item_base.h +++ b/eeschema/dialogs/dialog_lib_edit_draw_item_base.h @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Jun 30 2011) +// C++ code generated with wxFormBuilder (version Oct 8 2012) // http://www.wxformbuilder.org/ // // PLEASE DO "NOT" EDIT THIS FILE! @@ -36,7 +36,7 @@ class DIALOG_LIB_EDIT_DRAW_ITEM_BASE : public wxDialog protected: enum { - ID_M_STATICTEXTSHARING = 1000, + ID_M_STATICTEXTSHARING = 1000 }; wxStaticText* m_staticText1; diff --git a/eeschema/dialogs/dialog_lib_edit_pin_base.cpp b/eeschema/dialogs/dialog_lib_edit_pin_base.cpp index e1990a9407..cbb0cf20b4 100644 --- a/eeschema/dialogs/dialog_lib_edit_pin_base.cpp +++ b/eeschema/dialogs/dialog_lib_edit_pin_base.cpp @@ -80,10 +80,10 @@ DIALOG_LIB_EDIT_PIN_BASE::DIALOG_LIB_EDIT_PIN_BASE( wxWindow* parent, wxWindowID wxStaticBoxSizer* sbSizerPinSharing; sbSizerPinSharing = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Sharing") ), wxVERTICAL ); - m_checkApplyToAllParts = new wxCheckBox( this, wxID_ANY, _("Shared by all &parts in component"), wxDefaultPosition, wxDefaultSize, 0 ); + m_checkApplyToAllParts = new wxCheckBox( this, wxID_ANY, _("Common to all &units in component"), wxDefaultPosition, wxDefaultSize, 0 ); sbSizerPinSharing->Add( m_checkApplyToAllParts, 0, wxALIGN_CENTER_VERTICAL|wxALL, 3 ); - m_checkApplyToAllConversions = new wxCheckBox( this, wxID_ANY, _("Shared by all body &styles (DeMorgan)"), wxDefaultPosition, wxDefaultSize, 0 ); + m_checkApplyToAllConversions = new wxCheckBox( this, wxID_ANY, _("Common to all body &styles (DeMorgan)"), wxDefaultPosition, wxDefaultSize, 0 ); sbSizerPinSharing->Add( m_checkApplyToAllConversions, 0, wxALIGN_CENTER_VERTICAL|wxALL, 3 ); diff --git a/eeschema/dialogs/dialog_lib_edit_pin_base.fbp b/eeschema/dialogs/dialog_lib_edit_pin_base.fbp index 268c5d0722..09ddd2aca7 100644 --- a/eeschema/dialogs/dialog_lib_edit_pin_base.fbp +++ b/eeschema/dialogs/dialog_lib_edit_pin_base.fbp @@ -1051,7 +1051,7 @@ 0 0 wxID_ANY - Shared by all &parts in component + Common to all &units in component 0 @@ -1139,7 +1139,7 @@ 0 0 wxID_ANY - Shared by all body &styles (DeMorgan) + Common to all body &styles (DeMorgan) 0 diff --git a/eeschema/dialogs/dialog_lib_edit_text_base.cpp b/eeschema/dialogs/dialog_lib_edit_text_base.cpp index 1a6996035e..14cf94f803 100644 --- a/eeschema/dialogs/dialog_lib_edit_text_base.cpp +++ b/eeschema/dialogs/dialog_lib_edit_text_base.cpp @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Apr 30 2013) +// C++ code generated with wxFormBuilder (version Oct 8 2012) // http://www.wxformbuilder.org/ // // PLEASE DO "NOT" EDIT THIS FILE! @@ -25,7 +25,7 @@ DIALOG_LIB_EDIT_TEXT_BASE::DIALOG_LIB_EDIT_TEXT_BASE( wxWindow* parent, wxWindow wxBoxSizer* bTextValueBoxSizer; bTextValueBoxSizer = new wxBoxSizer( wxVERTICAL ); - m_staticText1 = new wxStaticText( this, wxID_ANY, _("Text:"), wxDefaultPosition, wxDefaultSize, 0 ); + m_staticText1 = new wxStaticText( this, wxID_ANY, _("Text"), wxDefaultPosition, wxDefaultSize, 0 ); m_staticText1->Wrap( -1 ); bTextValueBoxSizer->Add( m_staticText1, 0, wxTOP|wxRIGHT|wxLEFT, 5 ); @@ -59,7 +59,7 @@ DIALOG_LIB_EDIT_TEXT_BASE::DIALOG_LIB_EDIT_TEXT_BASE( wxWindow* parent, wxWindow bBottomtBoxSizer = new wxBoxSizer( wxHORIZONTAL ); wxStaticBoxSizer* sOptionsSizer; - sOptionsSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Text Options:") ), wxVERTICAL ); + sOptionsSizer = new wxStaticBoxSizer( new wxStaticBox( this, wxID_ANY, _("Options") ), wxVERTICAL ); m_Orient = new wxCheckBox( this, wxID_ANY, _("Vertical"), wxDefaultPosition, wxDefaultSize, 0 ); sOptionsSizer->Add( m_Orient, 0, wxALL, 5 ); @@ -67,10 +67,10 @@ DIALOG_LIB_EDIT_TEXT_BASE::DIALOG_LIB_EDIT_TEXT_BASE( wxWindow* parent, wxWindow m_staticline1 = new wxStaticLine( this, wxID_ANY, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); sOptionsSizer->Add( m_staticline1, 0, wxEXPAND | wxALL, 5 ); - m_CommonUnit = new wxCheckBox( this, wxID_ANY, _("Common to Units"), wxDefaultPosition, wxDefaultSize, 0 ); + m_CommonUnit = new wxCheckBox( this, wxID_ANY, _("Common to all units"), wxDefaultPosition, wxDefaultSize, 0 ); sOptionsSizer->Add( m_CommonUnit, 0, wxALL, 5 ); - m_CommonConvert = new wxCheckBox( this, wxID_ANY, _("Common to convert"), wxDefaultPosition, wxDefaultSize, 0 ); + m_CommonConvert = new wxCheckBox( this, wxID_ANY, _("Common to all body styles"), wxDefaultPosition, wxDefaultSize, 0 ); sOptionsSizer->Add( m_CommonConvert, 0, wxALL|wxEXPAND, 5 ); m_Invisible = new wxCheckBox( this, wxID_ANY, _("Invisible"), wxDefaultPosition, wxDefaultSize, 0 ); @@ -81,19 +81,19 @@ DIALOG_LIB_EDIT_TEXT_BASE::DIALOG_LIB_EDIT_TEXT_BASE( wxWindow* parent, wxWindow wxString m_TextShapeOptChoices[] = { _("Normal"), _("Italic"), _("Bold"), _("Bold Italic") }; int m_TextShapeOptNChoices = sizeof( m_TextShapeOptChoices ) / sizeof( wxString ); - m_TextShapeOpt = new wxRadioBox( this, wxID_ANY, _("Text Shape:"), wxDefaultPosition, wxDefaultSize, m_TextShapeOptNChoices, m_TextShapeOptChoices, 1, wxRA_SPECIFY_COLS ); + m_TextShapeOpt = new wxRadioBox( this, wxID_ANY, _("Style"), wxDefaultPosition, wxDefaultSize, m_TextShapeOptNChoices, m_TextShapeOptChoices, 1, wxRA_SPECIFY_COLS ); m_TextShapeOpt->SetSelection( 0 ); bBottomtBoxSizer->Add( m_TextShapeOpt, 1, wxALL|wxEXPAND, 5 ); wxString m_TextHJustificationOptChoices[] = { _("Align left"), _("Align center"), _("Align right") }; int m_TextHJustificationOptNChoices = sizeof( m_TextHJustificationOptChoices ) / sizeof( wxString ); - m_TextHJustificationOpt = new wxRadioBox( this, wxID_ANY, _("Horiz. Justify:"), wxDefaultPosition, wxDefaultSize, m_TextHJustificationOptNChoices, m_TextHJustificationOptChoices, 1, wxRA_SPECIFY_COLS ); + m_TextHJustificationOpt = new wxRadioBox( this, wxID_ANY, _("Horizontal Justify"), wxDefaultPosition, wxDefaultSize, m_TextHJustificationOptNChoices, m_TextHJustificationOptChoices, 1, wxRA_SPECIFY_COLS ); m_TextHJustificationOpt->SetSelection( 1 ); bBottomtBoxSizer->Add( m_TextHJustificationOpt, 1, wxALL|wxEXPAND, 5 ); wxString m_TextVJustificationOptChoices[] = { _("Align bottom"), _("Align center"), _("Align top") }; int m_TextVJustificationOptNChoices = sizeof( m_TextVJustificationOptChoices ) / sizeof( wxString ); - m_TextVJustificationOpt = new wxRadioBox( this, wxID_ANY, _("Vert. Justify:"), wxDefaultPosition, wxDefaultSize, m_TextVJustificationOptNChoices, m_TextVJustificationOptChoices, 1, wxRA_SPECIFY_COLS ); + m_TextVJustificationOpt = new wxRadioBox( this, wxID_ANY, _("Verticle Justify"), wxDefaultPosition, wxDefaultSize, m_TextVJustificationOptNChoices, m_TextVJustificationOptChoices, 1, wxRA_SPECIFY_COLS ); m_TextVJustificationOpt->SetSelection( 1 ); bBottomtBoxSizer->Add( m_TextVJustificationOpt, 1, wxALL|wxEXPAND, 5 ); diff --git a/eeschema/dialogs/dialog_lib_edit_text_base.fbp b/eeschema/dialogs/dialog_lib_edit_text_base.fbp index babd55e379..4cb52473d6 100644 --- a/eeschema/dialogs/dialog_lib_edit_text_base.fbp +++ b/eeschema/dialogs/dialog_lib_edit_text_base.fbp @@ -150,7 +150,7 @@ 0 0 wxID_ANY - Text: + Text 0 @@ -496,7 +496,7 @@ 1 wxID_ANY - Text Options: + Options sOptionsSizer wxVERTICAL @@ -704,7 +704,7 @@ 0 0 wxID_ANY - Common to Units + Common to all units 0 @@ -792,7 +792,7 @@ 0 0 wxID_ANY - Common to convert + Common to all body styles 0 @@ -970,7 +970,7 @@ 0 0 wxID_ANY - Text Shape: + Style 1 0 @@ -1060,7 +1060,7 @@ 0 0 wxID_ANY - Horiz. Justify: + Horizontal Justify 1 0 @@ -1150,7 +1150,7 @@ 0 0 wxID_ANY - Vert. Justify: + Verticle Justify 1 0 diff --git a/eeschema/dialogs/dialog_lib_edit_text_base.h b/eeschema/dialogs/dialog_lib_edit_text_base.h index efb00025db..fe68b8be27 100644 --- a/eeschema/dialogs/dialog_lib_edit_text_base.h +++ b/eeschema/dialogs/dialog_lib_edit_text_base.h @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Apr 30 2013) +// C++ code generated with wxFormBuilder (version Oct 8 2012) // http://www.wxformbuilder.org/ // // PLEASE DO "NOT" EDIT THIS FILE! diff --git a/eeschema/dialogs/dialog_lib_new_component.fbp b/eeschema/dialogs/dialog_lib_new_component.fbp index 54660f05a6..d9393e75a9 100644 --- a/eeschema/dialogs/dialog_lib_new_component.fbp +++ b/eeschema/dialogs/dialog_lib_new_component.fbp @@ -1094,7 +1094,7 @@ 0 0 wxID_ANY - Parts in package locked (cannot be swapped) + Units in package locked (cannot be swapped) 0 diff --git a/eeschema/dialogs/dialog_lib_new_component_base.cpp b/eeschema/dialogs/dialog_lib_new_component_base.cpp index 37f30b736c..4a8f1a64e5 100644 --- a/eeschema/dialogs/dialog_lib_new_component_base.cpp +++ b/eeschema/dialogs/dialog_lib_new_component_base.cpp @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Apr 11 2012) +// C++ code generated with wxFormBuilder (version Oct 8 2012) // http://www.wxformbuilder.org/ // // PLEASE DO "NOT" EDIT THIS FILE! @@ -41,6 +41,7 @@ DIALOG_LIB_NEW_COMPONENT_BASE::DIALOG_LIB_NEW_COMPONENT_BASE( wxWindow* parent, bSizer2->Add( 0, 0, 1, wxEXPAND, 3 ); m_textName = new wxTextCtrl( this, wxID_ANY, wxEmptyString, wxDefaultPosition, wxSize( 100,-1 ), 0 ); + m_textName->SetMaxLength( 0 ); bSizer2->Add( m_textName, 0, wxALIGN_CENTER_VERTICAL|wxALL, 3 ); @@ -65,6 +66,7 @@ DIALOG_LIB_NEW_COMPONENT_BASE::DIALOG_LIB_NEW_COMPONENT_BASE( wxWindow* parent, bSizer3->Add( 0, 0, 1, wxEXPAND, 5 ); m_textReference = new wxTextCtrl( this, wxID_ANY, _("U"), wxDefaultPosition, wxSize( 100,-1 ), 0 ); + m_textReference->SetMaxLength( 0 ); bSizer3->Add( m_textReference, 0, wxALIGN_CENTER_VERTICAL|wxALL, 3 ); @@ -131,7 +133,7 @@ DIALOG_LIB_NEW_COMPONENT_BASE::DIALOG_LIB_NEW_COMPONENT_BASE( wxWindow* parent, bSizer9->Add( 12, 0, 0, wxEXPAND, 3 ); - m_checkLockItems = new wxCheckBox( this, wxID_ANY, _("Parts in package locked (cannot be swapped)"), wxDefaultPosition, wxDefaultSize, 0 ); + m_checkLockItems = new wxCheckBox( this, wxID_ANY, _("Units in package locked (cannot be swapped)"), wxDefaultPosition, wxDefaultSize, 0 ); m_checkLockItems->SetToolTip( _("Check this option if Eeschema cannot change parts selections inside a given package\nThis happens when parts are different in this package.\nWhen this option is not checked, Eeschema automatically choose the parts in packages to minimize packages count") ); bSizer9->Add( m_checkLockItems, 0, wxALIGN_CENTER_VERTICAL|wxALL, 3 ); diff --git a/eeschema/dialogs/dialog_lib_new_component_base.h b/eeschema/dialogs/dialog_lib_new_component_base.h index 8c6846745e..0d07e105e1 100644 --- a/eeschema/dialogs/dialog_lib_new_component_base.h +++ b/eeschema/dialogs/dialog_lib_new_component_base.h @@ -1,5 +1,5 @@ /////////////////////////////////////////////////////////////////////////// -// C++ code generated with wxFormBuilder (version Apr 11 2012) +// C++ code generated with wxFormBuilder (version Oct 8 2012) // http://www.wxformbuilder.org/ // // PLEASE DO "NOT" EDIT THIS FILE! @@ -11,6 +11,8 @@ #include #include #include +class DIALOG_SHIM; + #include "dialog_shim.h" #include #include diff --git a/eeschema/libedit.cpp b/eeschema/libedit.cpp index 5f04ec52cd..8d49af7651 100644 --- a/eeschema/libedit.cpp +++ b/eeschema/libedit.cpp @@ -87,7 +87,7 @@ void LIB_EDIT_FRAME::SelectActiveLibrary( CMP_LIBRARY* aLibrary ) bool LIB_EDIT_FRAME::LoadComponentAndSelectLib( LIB_ALIAS* aLibEntry, CMP_LIBRARY* aLibrary ) { if( GetScreen()->IsModify() - && !IsOK( this, _( "Current part not saved.\n\nDiscard current changes?" ) ) ) + && !IsOK( this, _( "The current component is not saved.\n\nDiscard current changes?" ) ) ) return false; SelectActiveLibrary( aLibrary ); @@ -119,7 +119,7 @@ void LIB_EDIT_FRAME::LoadOneLibraryPart( wxCommandEvent& event ) m_canvas->EndMouseCapture( ID_NO_TOOL_SELECTED, m_canvas->GetDefaultCursor() ); if( GetScreen()->IsModify() - && !IsOK( this, _( "Current part not saved.\n\nDiscard current changes?" ) ) ) + && !IsOK( this, _( "Current component is not saved.\n\nDiscard current changes?" ) ) ) return; // No current lib, ask user for the library to use. @@ -151,10 +151,12 @@ void LIB_EDIT_FRAME::LoadOneLibraryPart( wxCommandEvent& event ) /* Load the new library component */ libEntry = m_library->FindEntry( CmpName ); CMP_LIBRARY* searchLib = m_library; + if( libEntry == NULL ) { // Not found in the active library: search inside the full list // (can happen when using Viewlib to load a component) libEntry = CMP_LIBRARY::FindLibraryEntry( CmpName ); + if( libEntry ) { searchLib = libEntry->GetLibrary(); @@ -164,6 +166,7 @@ void LIB_EDIT_FRAME::LoadOneLibraryPart( wxCommandEvent& event ) msg << _("The selected component is not in the active library"); msg << wxT("\n\n"); msg << _("Do you want to change the active library?"); + if( IsOK( this, msg ) ) SelectActiveLibrary( searchLib ); } @@ -221,7 +224,7 @@ bool LIB_EDIT_FRAME::LoadOneLibraryPartAux( LIB_ALIAS* aEntry, CMP_LIBRARY* aLib if( m_component == NULL ) { - msg.Printf( _( "Could not create copy of part <%s> in library <%s>." ), + msg.Printf( _( "Could not create copy of component <%s> in library <%s>." ), GetChars( aEntry->GetName() ), GetChars( aLibrary->GetName() ) ); DisplayError( this, msg ); @@ -261,8 +264,7 @@ void LIB_EDIT_FRAME::RedrawComponent( wxDC* aDC, wxPoint aOffset ) wxString fieldText = field->GetText(); wxString fieldfullText = field->GetFullText( m_unit ); field->EDA_TEXT::SetText( fieldfullText ); // change the field text string only - m_component->Draw( m_canvas, aDC, aOffset, m_unit, - m_convert, GR_DEFAULT_DRAWMODE ); + m_component->Draw( m_canvas, aDC, aOffset, m_unit, m_convert, GR_DEFAULT_DRAWMODE ); field->EDA_TEXT::SetText( fieldText ); // restore the field text string } } @@ -455,7 +457,7 @@ void LIB_EDIT_FRAME::DisplayCmpDoc() msg = m_component->GetName(); - AppendMsgPanel( _( "Part" ), msg, BLUE, 8 ); + AppendMsgPanel( _( "Name" ), msg, BLUE, 8 ); if( m_aliasName == m_component->GetName() ) msg = _( "None" ); diff --git a/eeschema/libeditframe.cpp b/eeschema/libeditframe.cpp index 07fd36dd1c..fbbddde564 100644 --- a/eeschema/libeditframe.cpp +++ b/eeschema/libeditframe.cpp @@ -288,24 +288,18 @@ LIB_EDIT_FRAME::~LIB_EDIT_FRAME() m_tempCopyComponent = NULL; } -/** - * Function GetLibEditFrameName (static) - * @return the frame name used when creating the frame - * used to get a reference to this frame, if exists - */ const wxChar* LIB_EDIT_FRAME::GetLibEditFrameName() { return LIB_EDIT_FRAME_NAME; } -/* return a reference to the current opened Library editor - * or NULL if no Library editor currently opened - */ + LIB_EDIT_FRAME* LIB_EDIT_FRAME::GetActiveLibraryEditor() { return (LIB_EDIT_FRAME*) wxWindow::FindWindowByName(GetLibEditFrameName()); } + void LIB_EDIT_FRAME::LoadSettings() { wxConfig* cfg; @@ -470,7 +464,7 @@ void LIB_EDIT_FRAME::UpdatePartSelectList() for( int i = 0; i < m_component->GetPartCount(); i++ ) { wxString sub = LIB_COMPONENT::ReturnSubReference( i+1, false ); - wxString part = wxString::Format( _( "Part %s" ), GetChars( sub ) ); + wxString part = wxString::Format( _( "Unit %s" ), GetChars( sub ) ); m_partSelectBox->Append( part ); } } @@ -753,9 +747,11 @@ void LIB_EDIT_FRAME::Process_Special_Functions( wxCommandEvent& event ) m_canvas->MoveCursorToCrossHair(); STATUS_FLAGS oldFlags = m_drawItem->GetFlags(); m_drawItem->ClearFlags(); - m_drawItem->Draw( m_canvas, &dc, wxPoint( 0, 0 ), UNSPECIFIED_COLOR, g_XorMode, NULL, DefaultTransform ); + m_drawItem->Draw( m_canvas, &dc, wxPoint( 0, 0 ), UNSPECIFIED_COLOR, g_XorMode, NULL, + DefaultTransform ); ( (LIB_POLYLINE*) m_drawItem )->DeleteSegment( GetCrossHairPosition( true ) ); - m_drawItem->Draw( m_canvas, &dc, wxPoint( 0, 0 ), UNSPECIFIED_COLOR, g_XorMode, NULL, DefaultTransform ); + m_drawItem->Draw( m_canvas, &dc, wxPoint( 0, 0 ), UNSPECIFIED_COLOR, g_XorMode, NULL, + DefaultTransform ); m_drawItem->SetFlags( oldFlags ); m_lastDrawItem = NULL; break; @@ -962,7 +958,8 @@ void LIB_EDIT_FRAME::EditSymbolText( wxDC* DC, LIB_ITEM* DrawItem ) // Deleting old text if( DC && !DrawItem->InEditMode() ) - DrawItem->Draw( m_canvas, DC, wxPoint( 0, 0 ), UNSPECIFIED_COLOR, g_XorMode, NULL, DefaultTransform ); + DrawItem->Draw( m_canvas, DC, wxPoint( 0, 0 ), UNSPECIFIED_COLOR, g_XorMode, NULL, + DefaultTransform ); DIALOG_LIB_EDIT_TEXT* frame = new DIALOG_LIB_EDIT_TEXT( this, (LIB_TEXT*) DrawItem ); frame->ShowModal(); @@ -1028,7 +1025,7 @@ void LIB_EDIT_FRAME::OnSelectTool( wxCommandEvent& aEvent ) m_lastDrawItem = NULL; m_canvas->EndMouseCapture( ID_NO_TOOL_SELECTED, m_canvas->GetDefaultCursor(), - wxEmptyString ); + wxEmptyString ); switch( id ) { diff --git a/eeschema/menubar_libedit.cpp b/eeschema/menubar_libedit.cpp index f0901d103c..eba56c6188 100644 --- a/eeschema/menubar_libedit.cpp +++ b/eeschema/menubar_libedit.cpp @@ -120,7 +120,7 @@ void LIB_EDIT_FRAME::ReCreateMenuBar() AddMenuItem( editMenu, wxID_UNDO, text, - _( "Undo last edition" ), + _( "Undo last edit" ), KiBitmap( undo_xpm ) ); // Redo diff --git a/eeschema/sch_component.cpp b/eeschema/sch_component.cpp index 22861fe5f4..4d214bdd16 100644 --- a/eeschema/sch_component.cpp +++ b/eeschema/sch_component.cpp @@ -1462,7 +1462,7 @@ void SCH_COMPONENT::GetMsgPanelInfo( MSG_PANEL_ITEMS& aList ) if( root_component->IsPower() ) msg = _( "Power symbol" ); else - msg = _( "Name" ); + msg = _( "Value" ); aList.push_back( MSG_PANEL_ITEM( msg, GetField( VALUE )->GetText(), DARKCYAN ) ); @@ -1478,7 +1478,8 @@ void SCH_COMPONENT::GetMsgPanelInfo( MSG_PANEL_ITEMS& aList ) if( ! GetField( FOOTPRINT )->IsVoid() ) msg = GetField( FOOTPRINT )->GetText(); else - msg = _(""); + msg = _( "" ); + aList.push_back( MSG_PANEL_ITEM( _( "Footprint" ), msg, DARKRED ) ); // Display description of the component, and keywords found in lib diff --git a/eeschema/tool_viewlib.cpp b/eeschema/tool_viewlib.cpp index 8c32511a9c..ec0f1daed5 100644 --- a/eeschema/tool_viewlib.cpp +++ b/eeschema/tool_viewlib.cpp @@ -61,16 +61,16 @@ void LIB_VIEW_FRAME::ReCreateHToolbar() m_mainToolBar->AddTool( ID_LIBVIEW_SELECT_PART, wxEmptyString, KiBitmap( add_component_xpm ), - _( "Select part to browse" ) ); + _( "Select component to browse" ) ); m_mainToolBar->AddSeparator(); m_mainToolBar->AddTool( ID_LIBVIEW_PREVIOUS, wxEmptyString, KiBitmap( lib_previous_xpm ), - _( "Display previous part" ) ); + _( "Display previous component" ) ); m_mainToolBar->AddTool( ID_LIBVIEW_NEXT, wxEmptyString, KiBitmap( lib_next_xpm ), - _( "Display next part" ) ); + _( "Display next component" ) ); m_mainToolBar->AddSeparator(); msg = AddHotkeyName( _( "Zoom in" ), s_Viewlib_Hokeys_Descr, @@ -173,7 +173,7 @@ void LIB_VIEW_FRAME::ReCreateHToolbar() for( ii = 0; ii < parts_count; ii++ ) { wxString msg; - msg.Printf( _( "Part %c" ), 'A' + ii ); + msg.Printf( _( "Unit %c" ), 'A' + ii ); SelpartBox->Append( msg ); } diff --git a/eeschema/viewlib_frame.cpp b/eeschema/viewlib_frame.cpp index 3300c5a923..a2ae42f879 100644 --- a/eeschema/viewlib_frame.cpp +++ b/eeschema/viewlib_frame.cpp @@ -261,19 +261,19 @@ LIB_VIEW_FRAME::~LIB_VIEW_FRAME() { } + const wxChar* LIB_VIEW_FRAME::GetLibViewerFrameName() { return LIB_VIEW_FRAME_NAME; } -/* return a reference to the current opened Library viewer - * or NULL if no Library viewer currently opened - */ + LIB_VIEW_FRAME* LIB_VIEW_FRAME::GetActiveLibraryViewer() { return (LIB_VIEW_FRAME*) wxWindow::FindWindowByName(GetLibViewerFrameName()); } + void LIB_VIEW_FRAME::OnCloseWindow( wxCloseEvent& Event ) { SaveSettings(); @@ -509,6 +509,7 @@ void LIB_VIEW_FRAME::DClickOnCmpList( wxCommandEvent& event ) } } + void LIB_VIEW_FRAME::ExportToSchematicLibraryPart( wxCommandEvent& event ) { int ii = m_CmpList->GetSelection();