Loading change_log.txt +12 −0 Original line number Diff line number Diff line Loading @@ -4,6 +4,18 @@ Started 2007-June-11 Please add newer entries at the top, list the date and your name with email address. 2007-Nov-13 UPDATE Geoff Harland <gharlandau@yahoo.com.au> ================================================================================ + eeschema & pcbnew * The "Page Settings" dialog box has been enhanced; it now includes a wxStdDialogButtonSizer, and is also now designed to be expandable. + pcbnew * The "DRC Control" and "Netlist:" dialog boxes have also been enhanced. Each of those dialogs now includes a wxStdDialogButtonSizer and a "Cancel" button, (so each of those dialogs can now (otherwise) be cancelled by pressing the "Esc" key), and is also now designed to be expandable. 2007-Nov-11 UPDATE Dick Hollenbeck <dick@softplc.com> ================================================================================ + pcbnew Loading pcbnew/dialog_drc.cpp +120 −101 Original line number Diff line number Diff line Loading @@ -47,8 +47,6 @@ IMPLEMENT_DYNAMIC_CLASS( WinEDA_DrcFrame, wxDialog ) BEGIN_EVENT_TABLE( WinEDA_DrcFrame, wxDialog ) ////@begin WinEDA_DrcFrame event table entries EVT_CLOSE( WinEDA_DrcFrame::OnCloseWindow ) EVT_BUTTON( ID_DRC_RUN, WinEDA_DrcFrame::OnDrcRunClick ) EVT_BUTTON( ID_STOP_CONTROL_DRC, WinEDA_DrcFrame::OnStopControlDrcClick ) Loading @@ -57,10 +55,12 @@ BEGIN_EVENT_TABLE( WinEDA_DrcFrame, wxDialog ) EVT_BUTTON( ID_LIST_UNCONNECTED_PADS, WinEDA_DrcFrame::OnListUnconnectedPadsClick ) EVT_BUTTON( wxID_CLOSE, WinEDA_DrcFrame::OnCloseClick ) EVT_BUTTON( ID_BUTTON_BROWSE_RPT_FILE, WinEDA_DrcFrame::OnButtonBrowseRptFileClick ) EVT_BUTTON( wxID_OK, WinEDA_DrcFrame::OnOkClick ) EVT_BUTTON( wxID_CANCEL, WinEDA_DrcFrame::OnCancelClick ) ////@end WinEDA_DrcFrame event table entries END_EVENT_TABLE() Loading @@ -74,7 +74,11 @@ WinEDA_DrcFrame::WinEDA_DrcFrame( ) } WinEDA_DrcFrame::WinEDA_DrcFrame( WinEDA_PcbFrame* parent, wxDC * panelDC, wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) { m_Parent = parent; m_DC = panelDC; Loading Loading @@ -103,6 +107,8 @@ bool WinEDA_DrcFrame::Create( wxWindow* parent, wxWindowID id, const wxString& c m_CreateRptCtrl = NULL; m_RptFilenameCtrl = NULL; m_logWindow = NULL; Line = NULL; StdDialogButtonSizer = NULL; ////@end WinEDA_DrcFrame member initialisation ////@begin WinEDA_DrcFrame creation Loading @@ -128,7 +134,7 @@ void WinEDA_DrcFrame::CreateControls() SetFont( *g_DialogFont ); ////@begin WinEDA_DrcFrame content construction // Generated by DialogBlocks, Tue 02 Oct 2007 16:31:47 CDT (unregistered) // Generated by DialogBlocks, 13/11/2007 16:40:34 (unregistered) WinEDA_DrcFrame* itemDialog1 = this; Loading @@ -136,16 +142,16 @@ void WinEDA_DrcFrame::CreateControls() itemDialog1->SetSizer(m_MainSizer); m_CommandSizer = new wxBoxSizer(wxHORIZONTAL); m_MainSizer->Add(m_CommandSizer, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); m_MainSizer->Add(m_CommandSizer, 0, wxGROW|wxALL, 5); wxStaticBox* itemStaticBoxSizer4Static = new wxStaticBox(itemDialog1, wxID_ANY, _("Options")); wxStaticBoxSizer* itemStaticBoxSizer4 = new wxStaticBoxSizer(itemStaticBoxSizer4Static, wxVERTICAL); m_CommandSizer->Add(itemStaticBoxSizer4, 0, wxGROW|wxALL, 5); m_CommandSizer->Add(itemStaticBoxSizer4, 0, wxALIGN_TOP|wxLEFT|wxTOP|wxBOTTOM, 5); m_ClearenceTitle = new wxStaticText( itemDialog1, wxID_STATIC, _("Clearance"), wxDefaultPosition, wxDefaultSize, 0 ); itemStaticBoxSizer4->Add(m_ClearenceTitle, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP|wxADJUST_MINSIZE, 5); m_SetClearance = new wxTextCtrl( itemDialog1, ID_TEXTCTRL1, _T(""), wxDefaultPosition, wxDefaultSize, 0 ); m_SetClearance = new wxTextCtrl( itemDialog1, ID_TEXTCTRL_CLEARANCE, _T(""), wxDefaultPosition, wxDefaultSize, 0 ); itemStaticBoxSizer4->Add(m_SetClearance, 0, wxGROW|wxLEFT|wxRIGHT|wxBOTTOM, 5); itemStaticBoxSizer4->Add(5, 5, 0, wxGROW|wxALL, 5); Loading @@ -158,7 +164,7 @@ void WinEDA_DrcFrame::CreateControls() m_Pad2PadTestCtrl->SetValue(false); itemStaticBoxSizer8->Add(m_Pad2PadTestCtrl, 0, wxGROW|wxALL, 5); m_UnconnectedTestCtrl = new wxCheckBox( itemDialog1, ID_CHECKBOX, _("Include unconnected"), wxDefaultPosition, wxDefaultSize, 0 ); m_UnconnectedTestCtrl = new wxCheckBox( itemDialog1, ID_CHECKBOX_UNCONNECTED, _("Include unconnected"), wxDefaultPosition, wxDefaultSize, 0 ); m_UnconnectedTestCtrl->SetValue(false); itemStaticBoxSizer8->Add(m_UnconnectedTestCtrl, 0, wxGROW|wxALL, 5); Loading @@ -170,40 +176,39 @@ void WinEDA_DrcFrame::CreateControls() m_CreateRptCtrl->SetValue(false); itemStaticBoxSizer8->Add(m_CreateRptCtrl, 0, wxGROW|wxALL, 5); wxBoxSizer* itemBoxSizer13 = new wxBoxSizer(wxVERTICAL); m_CommandSizer->Add(itemBoxSizer13, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); m_CommandSizer->Add(5, 5, 1, wxALIGN_CENTER_VERTICAL|wxLEFT|wxTOP|wxBOTTOM, 5); wxBoxSizer* itemBoxSizer14 = new wxBoxSizer(wxHORIZONTAL); itemBoxSizer13->Add(itemBoxSizer14, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); wxBoxSizer* itemBoxSizer14 = new wxBoxSizer(wxVERTICAL); m_CommandSizer->Add(itemBoxSizer14, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM, 5); wxBoxSizer* itemBoxSizer15 = new wxBoxSizer(wxVERTICAL); itemBoxSizer14->Add(itemBoxSizer15, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); wxBoxSizer* itemBoxSizer15 = new wxBoxSizer(wxHORIZONTAL); itemBoxSizer14->Add(itemBoxSizer15, 0, wxALIGN_CENTER_HORIZONTAL|wxRIGHT|wxTOP, 5); wxButton* itemButton16 = new wxButton( itemDialog1, ID_DRC_RUN, _("Test Drc"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton16->SetForegroundColour(wxColour(202, 0, 0)); itemBoxSizer15->Add(itemButton16, 0, wxGROW|wxALL, 5); wxBoxSizer* itemBoxSizer16 = new wxBoxSizer(wxVERTICAL); itemBoxSizer15->Add(itemBoxSizer16, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); wxButton* itemButton17 = new wxButton( itemDialog1, ID_STOP_CONTROL_DRC, _("Stop Drc"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton17->SetForegroundColour(wxColour(0, 128, 128)); itemBoxSizer15->Add(itemButton17, 0, wxGROW|wxALL, 5); wxButton* itemButton17 = new wxButton( itemDialog1, ID_DRC_RUN, _("Test Drc"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton17->SetForegroundColour(wxColour(202, 0, 0)); itemBoxSizer16->Add(itemButton17, 0, wxGROW|wxALL, 5); wxBoxSizer* itemBoxSizer18 = new wxBoxSizer(wxVERTICAL); itemBoxSizer14->Add(itemBoxSizer18, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); wxButton* itemButton18 = new wxButton( itemDialog1, ID_STOP_CONTROL_DRC, _("Stop Drc"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton18->SetForegroundColour(wxColour(0, 128, 128)); itemBoxSizer16->Add(itemButton18, 0, wxGROW|wxALL, 5); wxButton* itemButton19 = new wxButton( itemDialog1, ID_ERASE_DRC_MARKERS, _("Del Markers"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton19->SetForegroundColour(wxColour(0, 128, 0)); itemBoxSizer18->Add(itemButton19, 0, wxGROW|wxALL, 5); wxBoxSizer* itemBoxSizer19 = new wxBoxSizer(wxVERTICAL); itemBoxSizer15->Add(itemBoxSizer19, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); wxButton* itemButton20 = new wxButton( itemDialog1, ID_LIST_UNCONNECTED_PADS, _("List Unconn"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton20->SetForegroundColour(wxColour(0, 0, 255)); itemBoxSizer18->Add(itemButton20, 0, wxGROW|wxALL, 5); wxButton* itemButton20 = new wxButton( itemDialog1, ID_ERASE_DRC_MARKERS, _("Del Markers"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton20->SetForegroundColour(wxColour(0, 128, 0)); itemBoxSizer19->Add(itemButton20, 0, wxGROW|wxALL, 5); wxButton* itemButton21 = new wxButton( itemDialog1, wxID_CLOSE, _("&Close"), wxDefaultPosition, wxDefaultSize, 0 ); itemBoxSizer13->Add(itemButton21, 0, wxGROW|wxALL, 5); wxButton* itemButton21 = new wxButton( itemDialog1, ID_LIST_UNCONNECTED_PADS, _("List Unconn"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton21->SetForegroundColour(wxColour(0, 0, 255)); itemBoxSizer19->Add(itemButton21, 0, wxGROW|wxALL, 5); wxStaticBox* itemStaticBoxSizer22Static = new wxStaticBox(itemDialog1, wxID_ANY, _("Report File")); wxStaticBoxSizer* itemStaticBoxSizer22 = new wxStaticBoxSizer(itemStaticBoxSizer22Static, wxVERTICAL); itemBoxSizer13->Add(itemStaticBoxSizer22, 0, wxGROW|wxALL, 5); itemBoxSizer14->Add(itemStaticBoxSizer22, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP, 5); wxButton* itemButton23 = new wxButton( itemDialog1, ID_BUTTON_BROWSE_RPT_FILE, _("Browse"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton23->SetForegroundColour(wxColour(0, 128, 128)); Loading @@ -213,10 +218,26 @@ void WinEDA_DrcFrame::CreateControls() itemStaticBoxSizer22->Add(m_RptFilenameCtrl, 0, wxGROW|wxALL, 5); wxStaticText* itemStaticText25 = new wxStaticText( itemDialog1, wxID_STATIC, _("Messages:"), wxDefaultPosition, wxDefaultSize, 0 ); m_MainSizer->Add(itemStaticText25, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP|wxADJUST_MINSIZE, 5); m_MainSizer->Add(itemStaticText25, 0, wxGROW|wxLEFT|wxRIGHT|wxADJUST_MINSIZE, 10); m_logWindow = new wxTextCtrl( itemDialog1, ID_TEXTCTRL, _T(""), wxDefaultPosition, wxSize(-1, 300), wxTE_MULTILINE|wxTE_READONLY|wxHSCROLL|wxFULL_REPAINT_ON_RESIZE ); m_MainSizer->Add(m_logWindow, 0, wxGROW|wxLEFT|wxRIGHT|wxBOTTOM, 5); m_MainSizer->Add(m_logWindow, 1, wxGROW|wxLEFT|wxRIGHT|wxBOTTOM, 10); Line = new wxStaticLine( itemDialog1, ID_STATICLINE, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); m_MainSizer->Add(Line, 0, wxGROW|wxLEFT|wxRIGHT, 5); StdDialogButtonSizer = new wxStdDialogButtonSizer; m_MainSizer->Add(StdDialogButtonSizer, 0, wxGROW|wxALL, 10); wxButton* itemButton29 = new wxButton( itemDialog1, wxID_OK, _("&OK"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton29->SetForegroundColour(wxColour(200, 0, 0)); StdDialogButtonSizer->AddButton(itemButton29); wxButton* itemButton30 = new wxButton( itemDialog1, wxID_CANCEL, _("&Cancel"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton30->SetForegroundColour(wxColour(0, 0, 255)); StdDialogButtonSizer->AddButton(itemButton30); StdDialogButtonSizer->Realize(); // Set validators m_Pad2PadTestCtrl->SetValidator( wxGenericValidator(& s_Pad2PadTestOpt) ); Loading Loading @@ -282,8 +303,10 @@ void WinEDA_DrcFrame::OnDrcRunClick( wxCommandEvent& event ) void WinEDA_DrcFrame::OnStopControlDrcClick( wxCommandEvent& event ) { if ( DrcInProgress ) AbortDrc = TRUE; else wxBell(); if( DrcInProgress ) AbortDrc = TRUE; else wxBell(); } /*! Loading @@ -304,37 +327,6 @@ void WinEDA_DrcFrame::OnListUnconnectedPadsClick( wxCommandEvent& event ) ListUnconnectedPads(event); } /*! * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CLOSE */ void WinEDA_DrcFrame::OnCloseClick( wxCommandEvent& event ) { s_Pad2PadTestOpt = m_Pad2PadTestCtrl->IsChecked(); s_UnconnectedTestOpt = m_UnconnectedTestCtrl->IsChecked(); s_ZonesTestOpt = m_ZonesTestCtrl->IsChecked(); s_CreateRptFileOpt = m_CreateRptCtrl->IsChecked(); Close(); } /*! * wxEVT_CLOSE_WINDOW event handler for ID_DIALOG */ void WinEDA_DrcFrame::OnCloseWindow( wxCloseEvent& event ) { s_Pad2PadTestOpt = m_Pad2PadTestCtrl->IsChecked(); s_UnconnectedTestOpt = m_UnconnectedTestCtrl->IsChecked(); s_ZonesTestOpt = m_ZonesTestCtrl->IsChecked(); s_CreateRptFileOpt = m_CreateRptCtrl->IsChecked(); event.Skip(); } /*! * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON_BROWSE_RPT_FILE */ Loading @@ -356,7 +348,8 @@ wxString FileName, Mask(wxT("*")), Ext(wxT(".rpt")); wxFD_SAVE, TRUE ); if ( FileName.IsEmpty()) return; if( FileName.IsEmpty() ) return; m_RptFilenameCtrl->SetValue(FileName); s_RptFilename = FileName; Loading Loading @@ -409,3 +402,29 @@ bool WinEDA_DrcFrame::ProcessEvent( wxEvent& event ) } } /*! * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_OK */ void WinEDA_DrcFrame::OnOkClick( wxCommandEvent& event ) { s_Pad2PadTestOpt = m_Pad2PadTestCtrl->IsChecked(); s_UnconnectedTestOpt = m_UnconnectedTestCtrl->IsChecked(); s_ZonesTestOpt = m_ZonesTestCtrl->IsChecked(); s_CreateRptFileOpt = m_CreateRptCtrl->IsChecked(); event.Skip(); } /*! * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL */ void WinEDA_DrcFrame::OnCancelClick( wxCommandEvent& event ) { ////@begin wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL in WinEDA_DrcFrame. // Before editing this code, remove the block markers. event.Skip(); ////@end wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL in WinEDA_DrcFrame. } pcbnew/dialog_drc.h +26 −16 Original line number Diff line number Diff line Loading @@ -24,6 +24,7 @@ ////@begin includes #include "wx/valgen.h" #include "wx/statline.h" ////@end includes /*! Loading @@ -32,6 +33,8 @@ ////@begin forward declarations class wxBoxSizer; class wxStaticLine; class wxStdDialogButtonSizer; ////@end forward declarations /*! Loading @@ -40,9 +43,9 @@ class wxBoxSizer; ////@begin control identifiers #define ID_DIALOG 10000 #define ID_TEXTCTRL1 10002 #define ID_TEXTCTRL_CLEARANCE 10002 #define ID_CHECKBOX_PAD2PAD 10009 #define ID_CHECKBOX 10008 #define ID_CHECKBOX_UNCONNECTED 10008 #define ID_CHECKBOX_TEST_ZONES 10007 #define ID_CHECKBOX_CREATE_FILE 10012 #define ID_DRC_RUN 10003 Loading @@ -52,7 +55,8 @@ class wxBoxSizer; #define ID_BUTTON_BROWSE_RPT_FILE 10011 #define ID_TEXTCTRL_GET_RPT_FILENAME 10010 #define ID_TEXTCTRL 10001 #define SYMBOL_WINEDA_DRCFRAME_STYLE wxCAPTION|wxSYSTEM_MENU|wxCLOSE_BOX|MAYBE_RESIZE_BORDER #define ID_STATICLINE 10013 #define SYMBOL_WINEDA_DRCFRAME_STYLE wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER #define SYMBOL_WINEDA_DRCFRAME_TITLE _("DRC Control") #define SYMBOL_WINEDA_DRCFRAME_IDNAME ID_DIALOG #define SYMBOL_WINEDA_DRCFRAME_SIZE wxSize(400, 300) Loading Loading @@ -80,7 +84,11 @@ public: /// Constructors WinEDA_DrcFrame( ); WinEDA_DrcFrame( WinEDA_PcbFrame* parent, wxDC * panelDC, wxWindowID id = SYMBOL_WINEDA_DRCFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_DRCFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_DRCFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_DRCFRAME_SIZE, long style = SYMBOL_WINEDA_DRCFRAME_STYLE ); wxWindowID id = SYMBOL_WINEDA_DRCFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_DRCFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_DRCFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_DRCFRAME_SIZE, long style = SYMBOL_WINEDA_DRCFRAME_STYLE ); /// Creation bool Create( wxWindow* parent, wxWindowID id = SYMBOL_WINEDA_DRCFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_DRCFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_DRCFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_DRCFRAME_SIZE, long style = SYMBOL_WINEDA_DRCFRAME_STYLE ); Loading @@ -93,9 +101,6 @@ public: ////@begin WinEDA_DrcFrame event handler declarations /// wxEVT_CLOSE_WINDOW event handler for ID_DIALOG void OnCloseWindow( wxCloseEvent& event ); /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_DRC_RUN void OnDrcRunClick( wxCommandEvent& event ); Loading @@ -108,12 +113,15 @@ public: /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_LIST_UNCONNECTED_PADS void OnListUnconnectedPadsClick( wxCommandEvent& event ); /// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CLOSE void OnCloseClick( wxCommandEvent& event ); /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON_BROWSE_RPT_FILE void OnButtonBrowseRptFileClick( wxCommandEvent& event ); /// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_OK void OnOkClick( wxCommandEvent& event ); /// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL void OnCancelClick( wxCommandEvent& event ); ////@end WinEDA_DrcFrame event handler declarations ////@begin WinEDA_DrcFrame member function declarations Loading Loading @@ -143,6 +151,8 @@ public: wxCheckBox* m_CreateRptCtrl; wxTextCtrl* m_RptFilenameCtrl; wxTextCtrl* m_logWindow; wxStaticLine* Line; wxStdDialogButtonSizer* StdDialogButtonSizer; ////@end WinEDA_DrcFrame member variables WinEDA_PcbFrame * m_Parent; wxDC * m_DC; Loading pcbnew/dialog_drc.pjd +267 −104 File changed.Preview size limit exceeded, changes collapsed. Show changes pcbnew/dialog_netlist.cpp +54 −46 Original line number Diff line number Diff line Loading @@ -52,7 +52,7 @@ BEGIN_EVENT_TABLE( WinEDA_NetlistFrame, wxDialog ) EVT_BUTTON( ID_COMPILE_RATSNEST, WinEDA_NetlistFrame::OnCompileRatsnestClick ) EVT_BUTTON( wxID_CLOSE, WinEDA_NetlistFrame::OnCloseClick ) EVT_BUTTON( wxID_CANCEL, WinEDA_NetlistFrame::OnCancelClick ) ////@end WinEDA_NetlistFrame event table entries Loading @@ -79,7 +79,6 @@ WinEDA_NetlistFrame::WinEDA_NetlistFrame( WinEDA_PcbFrame* parent, wxDC * DC, wxString title = GetTitle() + NetNameBuffer; SetTitle(title); } /*! Loading @@ -94,15 +93,18 @@ bool WinEDA_NetlistFrame::Create( wxWindow* parent, wxWindowID id, const wxStrin m_ChangeExistantModuleCtrl = NULL; m_DisplayWarningCtrl = NULL; m_MessageWindow = NULL; StdDialogButtonSizer = NULL; ////@end WinEDA_NetlistFrame member initialisation ////@begin WinEDA_NetlistFrame creation SetExtraStyle(GetExtraStyle()|wxWS_EX_BLOCK_EVENTS); SetExtraStyle(wxWS_EX_BLOCK_EVENTS); wxDialog::Create( parent, id, caption, pos, size, style ); CreateControls(); GetSizer()->Fit(this); if (GetSizer()) { GetSizer()->SetSizeHints(this); } Centre(); ////@end WinEDA_NetlistFrame creation return true; Loading @@ -116,7 +118,7 @@ void WinEDA_NetlistFrame::CreateControls() { SetFont( *g_DialogFont ); ////@begin WinEDA_NetlistFrame content construction // Generated by DialogBlocks, 26/02/2006 18:24:19 (unregistered) // Generated by DialogBlocks, 13/11/2007 15:31:19 (unregistered) WinEDA_NetlistFrame* itemDialog1 = this; Loading @@ -124,40 +126,40 @@ void WinEDA_NetlistFrame::CreateControls() itemDialog1->SetSizer(itemBoxSizer2); wxBoxSizer* itemBoxSizer3 = new wxBoxSizer(wxHORIZONTAL); itemBoxSizer2->Add(itemBoxSizer3, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); itemBoxSizer2->Add(itemBoxSizer3, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP, 5); wxBoxSizer* itemBoxSizer4 = new wxBoxSizer(wxVERTICAL); itemBoxSizer3->Add(itemBoxSizer4, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); itemBoxSizer3->Add(itemBoxSizer4, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM, 5); wxString m_Select_By_TimestampStrings[] = { _("Reference"), _("Timestamp") }; m_Select_By_Timestamp = new wxRadioBox( itemDialog1, ID_RADIOBOX, _("Module Selection:"), wxDefaultPosition, wxDefaultSize, 2, m_Select_By_TimestampStrings, 1, wxRA_SPECIFY_COLS ); wxArrayString m_Select_By_TimestampStrings; m_Select_By_TimestampStrings.Add(_("Reference")); m_Select_By_TimestampStrings.Add(_("Timestamp")); m_Select_By_Timestamp = new wxRadioBox( itemDialog1, ID_RADIOBOX, _("Module Selection:"), wxDefaultPosition, wxDefaultSize, m_Select_By_TimestampStrings, 1, wxRA_SPECIFY_COLS ); m_Select_By_Timestamp->SetSelection(0); itemBoxSizer4->Add(m_Select_By_Timestamp, 0, wxGROW|wxALL, 5); wxString m_DeleteBadTracksStrings[] = { _("Keep"), _("Delete") }; m_DeleteBadTracks = new wxRadioBox( itemDialog1, ID_RADIOBOX1, _("Bad Tracks Deletion:"), wxDefaultPosition, wxDefaultSize, 2, m_DeleteBadTracksStrings, 1, wxRA_SPECIFY_COLS ); wxArrayString m_DeleteBadTracksStrings; m_DeleteBadTracksStrings.Add(_("Keep")); m_DeleteBadTracksStrings.Add(_("Delete")); m_DeleteBadTracks = new wxRadioBox( itemDialog1, ID_RADIOBOX1, _("Bad Tracks Deletion:"), wxDefaultPosition, wxDefaultSize, m_DeleteBadTracksStrings, 1, wxRA_SPECIFY_COLS ); m_DeleteBadTracks->SetSelection(0); itemBoxSizer4->Add(m_DeleteBadTracks, 0, wxGROW|wxALL, 5); wxString m_ChangeExistantModuleCtrlStrings[] = { _("Keep"), _("Change") }; m_ChangeExistantModuleCtrl = new wxRadioBox( itemDialog1, ID_RADIOBOX2, _("Exchange Module:"), wxDefaultPosition, wxDefaultSize, 2, m_ChangeExistantModuleCtrlStrings, 1, wxRA_SPECIFY_COLS ); wxArrayString m_ChangeExistantModuleCtrlStrings; m_ChangeExistantModuleCtrlStrings.Add(_("Keep")); m_ChangeExistantModuleCtrlStrings.Add(_("Change")); m_ChangeExistantModuleCtrl = new wxRadioBox( itemDialog1, ID_RADIOBOX2, _("Exchange Module:"), wxDefaultPosition, wxDefaultSize, m_ChangeExistantModuleCtrlStrings, 1, wxRA_SPECIFY_COLS ); m_ChangeExistantModuleCtrl->SetSelection(0); itemBoxSizer4->Add(m_ChangeExistantModuleCtrl, 0, wxGROW|wxALL, 5); m_DisplayWarningCtrl = new wxCheckBox( itemDialog1, ID_CHECKBOX, _("Display Warnings"), wxDefaultPosition, wxDefaultSize, wxCHK_2STATE ); m_DisplayWarningCtrl->SetValue(false); itemBoxSizer4->Add(m_DisplayWarningCtrl, 0, wxGROW|wxALL, 5); itemBoxSizer4->Add(m_DisplayWarningCtrl, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP, 5); itemBoxSizer3->Add(5, 5, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); itemBoxSizer3->Add(5, 5, 1, wxALIGN_CENTER_VERTICAL|wxALL, 5); wxBoxSizer* itemBoxSizer10 = new wxBoxSizer(wxVERTICAL); itemBoxSizer3->Add(itemBoxSizer10, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); itemBoxSizer3->Add(itemBoxSizer10, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM, 5); wxButton* itemButton11 = new wxButton( itemDialog1, ID_OPEN_NELIST, _("Select"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton11->SetForegroundColour(wxColour(217, 0, 0)); Loading @@ -175,12 +177,20 @@ void WinEDA_NetlistFrame::CreateControls() itemButton14->SetForegroundColour(wxColour(0, 0, 132)); itemBoxSizer10->Add(itemButton14, 0, wxGROW|wxALL, 5); wxButton* itemButton15 = new wxButton( itemDialog1, wxID_CLOSE, _("&Close"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton15->SetForegroundColour(wxColour(128, 0, 128)); itemBoxSizer10->Add(itemButton15, 0, wxGROW|wxALL, 5); m_MessageWindow = new wxTextCtrl( itemDialog1, ID_TEXTCTRL, _T(""), wxDefaultPosition, wxSize(-1, 120), wxTE_MULTILINE|wxTE_READONLY ); itemBoxSizer2->Add(m_MessageWindow, 0, wxGROW|wxALL, 5); itemBoxSizer2->Add(m_MessageWindow, 1, wxGROW|wxALL, 10); wxStaticLine* itemStaticLine16 = new wxStaticLine( itemDialog1, ID_STATICLINE, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); itemBoxSizer2->Add(itemStaticLine16, 0, wxGROW|wxLEFT|wxRIGHT, 5); StdDialogButtonSizer = new wxStdDialogButtonSizer; itemBoxSizer2->Add(StdDialogButtonSizer, 0, wxGROW|wxALL, 10); wxButton* itemButton18 = new wxButton( itemDialog1, wxID_CANCEL, _("&Cancel"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton18->SetForegroundColour(wxColour(0, 0, 255)); StdDialogButtonSizer->AddButton(itemButton18); StdDialogButtonSizer->Realize(); // Set validators m_DisplayWarningCtrl->SetValidator( wxGenericValidator(& DisplayWarning) ); Loading Loading @@ -258,12 +268,10 @@ void WinEDA_NetlistFrame::OnCompileRatsnestClick( wxCommandEvent& event ) } /*! * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CLOSE * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL */ void WinEDA_NetlistFrame::OnCloseClick( wxCommandEvent& event ) void WinEDA_NetlistFrame::OnCancelClick( wxCommandEvent& event ) { Close(); EndModal( -1 ); } Loading
change_log.txt +12 −0 Original line number Diff line number Diff line Loading @@ -4,6 +4,18 @@ Started 2007-June-11 Please add newer entries at the top, list the date and your name with email address. 2007-Nov-13 UPDATE Geoff Harland <gharlandau@yahoo.com.au> ================================================================================ + eeschema & pcbnew * The "Page Settings" dialog box has been enhanced; it now includes a wxStdDialogButtonSizer, and is also now designed to be expandable. + pcbnew * The "DRC Control" and "Netlist:" dialog boxes have also been enhanced. Each of those dialogs now includes a wxStdDialogButtonSizer and a "Cancel" button, (so each of those dialogs can now (otherwise) be cancelled by pressing the "Esc" key), and is also now designed to be expandable. 2007-Nov-11 UPDATE Dick Hollenbeck <dick@softplc.com> ================================================================================ + pcbnew Loading
pcbnew/dialog_drc.cpp +120 −101 Original line number Diff line number Diff line Loading @@ -47,8 +47,6 @@ IMPLEMENT_DYNAMIC_CLASS( WinEDA_DrcFrame, wxDialog ) BEGIN_EVENT_TABLE( WinEDA_DrcFrame, wxDialog ) ////@begin WinEDA_DrcFrame event table entries EVT_CLOSE( WinEDA_DrcFrame::OnCloseWindow ) EVT_BUTTON( ID_DRC_RUN, WinEDA_DrcFrame::OnDrcRunClick ) EVT_BUTTON( ID_STOP_CONTROL_DRC, WinEDA_DrcFrame::OnStopControlDrcClick ) Loading @@ -57,10 +55,12 @@ BEGIN_EVENT_TABLE( WinEDA_DrcFrame, wxDialog ) EVT_BUTTON( ID_LIST_UNCONNECTED_PADS, WinEDA_DrcFrame::OnListUnconnectedPadsClick ) EVT_BUTTON( wxID_CLOSE, WinEDA_DrcFrame::OnCloseClick ) EVT_BUTTON( ID_BUTTON_BROWSE_RPT_FILE, WinEDA_DrcFrame::OnButtonBrowseRptFileClick ) EVT_BUTTON( wxID_OK, WinEDA_DrcFrame::OnOkClick ) EVT_BUTTON( wxID_CANCEL, WinEDA_DrcFrame::OnCancelClick ) ////@end WinEDA_DrcFrame event table entries END_EVENT_TABLE() Loading @@ -74,7 +74,11 @@ WinEDA_DrcFrame::WinEDA_DrcFrame( ) } WinEDA_DrcFrame::WinEDA_DrcFrame( WinEDA_PcbFrame* parent, wxDC * panelDC, wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) { m_Parent = parent; m_DC = panelDC; Loading Loading @@ -103,6 +107,8 @@ bool WinEDA_DrcFrame::Create( wxWindow* parent, wxWindowID id, const wxString& c m_CreateRptCtrl = NULL; m_RptFilenameCtrl = NULL; m_logWindow = NULL; Line = NULL; StdDialogButtonSizer = NULL; ////@end WinEDA_DrcFrame member initialisation ////@begin WinEDA_DrcFrame creation Loading @@ -128,7 +134,7 @@ void WinEDA_DrcFrame::CreateControls() SetFont( *g_DialogFont ); ////@begin WinEDA_DrcFrame content construction // Generated by DialogBlocks, Tue 02 Oct 2007 16:31:47 CDT (unregistered) // Generated by DialogBlocks, 13/11/2007 16:40:34 (unregistered) WinEDA_DrcFrame* itemDialog1 = this; Loading @@ -136,16 +142,16 @@ void WinEDA_DrcFrame::CreateControls() itemDialog1->SetSizer(m_MainSizer); m_CommandSizer = new wxBoxSizer(wxHORIZONTAL); m_MainSizer->Add(m_CommandSizer, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); m_MainSizer->Add(m_CommandSizer, 0, wxGROW|wxALL, 5); wxStaticBox* itemStaticBoxSizer4Static = new wxStaticBox(itemDialog1, wxID_ANY, _("Options")); wxStaticBoxSizer* itemStaticBoxSizer4 = new wxStaticBoxSizer(itemStaticBoxSizer4Static, wxVERTICAL); m_CommandSizer->Add(itemStaticBoxSizer4, 0, wxGROW|wxALL, 5); m_CommandSizer->Add(itemStaticBoxSizer4, 0, wxALIGN_TOP|wxLEFT|wxTOP|wxBOTTOM, 5); m_ClearenceTitle = new wxStaticText( itemDialog1, wxID_STATIC, _("Clearance"), wxDefaultPosition, wxDefaultSize, 0 ); itemStaticBoxSizer4->Add(m_ClearenceTitle, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP|wxADJUST_MINSIZE, 5); m_SetClearance = new wxTextCtrl( itemDialog1, ID_TEXTCTRL1, _T(""), wxDefaultPosition, wxDefaultSize, 0 ); m_SetClearance = new wxTextCtrl( itemDialog1, ID_TEXTCTRL_CLEARANCE, _T(""), wxDefaultPosition, wxDefaultSize, 0 ); itemStaticBoxSizer4->Add(m_SetClearance, 0, wxGROW|wxLEFT|wxRIGHT|wxBOTTOM, 5); itemStaticBoxSizer4->Add(5, 5, 0, wxGROW|wxALL, 5); Loading @@ -158,7 +164,7 @@ void WinEDA_DrcFrame::CreateControls() m_Pad2PadTestCtrl->SetValue(false); itemStaticBoxSizer8->Add(m_Pad2PadTestCtrl, 0, wxGROW|wxALL, 5); m_UnconnectedTestCtrl = new wxCheckBox( itemDialog1, ID_CHECKBOX, _("Include unconnected"), wxDefaultPosition, wxDefaultSize, 0 ); m_UnconnectedTestCtrl = new wxCheckBox( itemDialog1, ID_CHECKBOX_UNCONNECTED, _("Include unconnected"), wxDefaultPosition, wxDefaultSize, 0 ); m_UnconnectedTestCtrl->SetValue(false); itemStaticBoxSizer8->Add(m_UnconnectedTestCtrl, 0, wxGROW|wxALL, 5); Loading @@ -170,40 +176,39 @@ void WinEDA_DrcFrame::CreateControls() m_CreateRptCtrl->SetValue(false); itemStaticBoxSizer8->Add(m_CreateRptCtrl, 0, wxGROW|wxALL, 5); wxBoxSizer* itemBoxSizer13 = new wxBoxSizer(wxVERTICAL); m_CommandSizer->Add(itemBoxSizer13, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); m_CommandSizer->Add(5, 5, 1, wxALIGN_CENTER_VERTICAL|wxLEFT|wxTOP|wxBOTTOM, 5); wxBoxSizer* itemBoxSizer14 = new wxBoxSizer(wxHORIZONTAL); itemBoxSizer13->Add(itemBoxSizer14, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); wxBoxSizer* itemBoxSizer14 = new wxBoxSizer(wxVERTICAL); m_CommandSizer->Add(itemBoxSizer14, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM, 5); wxBoxSizer* itemBoxSizer15 = new wxBoxSizer(wxVERTICAL); itemBoxSizer14->Add(itemBoxSizer15, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); wxBoxSizer* itemBoxSizer15 = new wxBoxSizer(wxHORIZONTAL); itemBoxSizer14->Add(itemBoxSizer15, 0, wxALIGN_CENTER_HORIZONTAL|wxRIGHT|wxTOP, 5); wxButton* itemButton16 = new wxButton( itemDialog1, ID_DRC_RUN, _("Test Drc"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton16->SetForegroundColour(wxColour(202, 0, 0)); itemBoxSizer15->Add(itemButton16, 0, wxGROW|wxALL, 5); wxBoxSizer* itemBoxSizer16 = new wxBoxSizer(wxVERTICAL); itemBoxSizer15->Add(itemBoxSizer16, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); wxButton* itemButton17 = new wxButton( itemDialog1, ID_STOP_CONTROL_DRC, _("Stop Drc"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton17->SetForegroundColour(wxColour(0, 128, 128)); itemBoxSizer15->Add(itemButton17, 0, wxGROW|wxALL, 5); wxButton* itemButton17 = new wxButton( itemDialog1, ID_DRC_RUN, _("Test Drc"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton17->SetForegroundColour(wxColour(202, 0, 0)); itemBoxSizer16->Add(itemButton17, 0, wxGROW|wxALL, 5); wxBoxSizer* itemBoxSizer18 = new wxBoxSizer(wxVERTICAL); itemBoxSizer14->Add(itemBoxSizer18, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); wxButton* itemButton18 = new wxButton( itemDialog1, ID_STOP_CONTROL_DRC, _("Stop Drc"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton18->SetForegroundColour(wxColour(0, 128, 128)); itemBoxSizer16->Add(itemButton18, 0, wxGROW|wxALL, 5); wxButton* itemButton19 = new wxButton( itemDialog1, ID_ERASE_DRC_MARKERS, _("Del Markers"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton19->SetForegroundColour(wxColour(0, 128, 0)); itemBoxSizer18->Add(itemButton19, 0, wxGROW|wxALL, 5); wxBoxSizer* itemBoxSizer19 = new wxBoxSizer(wxVERTICAL); itemBoxSizer15->Add(itemBoxSizer19, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); wxButton* itemButton20 = new wxButton( itemDialog1, ID_LIST_UNCONNECTED_PADS, _("List Unconn"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton20->SetForegroundColour(wxColour(0, 0, 255)); itemBoxSizer18->Add(itemButton20, 0, wxGROW|wxALL, 5); wxButton* itemButton20 = new wxButton( itemDialog1, ID_ERASE_DRC_MARKERS, _("Del Markers"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton20->SetForegroundColour(wxColour(0, 128, 0)); itemBoxSizer19->Add(itemButton20, 0, wxGROW|wxALL, 5); wxButton* itemButton21 = new wxButton( itemDialog1, wxID_CLOSE, _("&Close"), wxDefaultPosition, wxDefaultSize, 0 ); itemBoxSizer13->Add(itemButton21, 0, wxGROW|wxALL, 5); wxButton* itemButton21 = new wxButton( itemDialog1, ID_LIST_UNCONNECTED_PADS, _("List Unconn"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton21->SetForegroundColour(wxColour(0, 0, 255)); itemBoxSizer19->Add(itemButton21, 0, wxGROW|wxALL, 5); wxStaticBox* itemStaticBoxSizer22Static = new wxStaticBox(itemDialog1, wxID_ANY, _("Report File")); wxStaticBoxSizer* itemStaticBoxSizer22 = new wxStaticBoxSizer(itemStaticBoxSizer22Static, wxVERTICAL); itemBoxSizer13->Add(itemStaticBoxSizer22, 0, wxGROW|wxALL, 5); itemBoxSizer14->Add(itemStaticBoxSizer22, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP, 5); wxButton* itemButton23 = new wxButton( itemDialog1, ID_BUTTON_BROWSE_RPT_FILE, _("Browse"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton23->SetForegroundColour(wxColour(0, 128, 128)); Loading @@ -213,10 +218,26 @@ void WinEDA_DrcFrame::CreateControls() itemStaticBoxSizer22->Add(m_RptFilenameCtrl, 0, wxGROW|wxALL, 5); wxStaticText* itemStaticText25 = new wxStaticText( itemDialog1, wxID_STATIC, _("Messages:"), wxDefaultPosition, wxDefaultSize, 0 ); m_MainSizer->Add(itemStaticText25, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP|wxADJUST_MINSIZE, 5); m_MainSizer->Add(itemStaticText25, 0, wxGROW|wxLEFT|wxRIGHT|wxADJUST_MINSIZE, 10); m_logWindow = new wxTextCtrl( itemDialog1, ID_TEXTCTRL, _T(""), wxDefaultPosition, wxSize(-1, 300), wxTE_MULTILINE|wxTE_READONLY|wxHSCROLL|wxFULL_REPAINT_ON_RESIZE ); m_MainSizer->Add(m_logWindow, 0, wxGROW|wxLEFT|wxRIGHT|wxBOTTOM, 5); m_MainSizer->Add(m_logWindow, 1, wxGROW|wxLEFT|wxRIGHT|wxBOTTOM, 10); Line = new wxStaticLine( itemDialog1, ID_STATICLINE, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); m_MainSizer->Add(Line, 0, wxGROW|wxLEFT|wxRIGHT, 5); StdDialogButtonSizer = new wxStdDialogButtonSizer; m_MainSizer->Add(StdDialogButtonSizer, 0, wxGROW|wxALL, 10); wxButton* itemButton29 = new wxButton( itemDialog1, wxID_OK, _("&OK"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton29->SetForegroundColour(wxColour(200, 0, 0)); StdDialogButtonSizer->AddButton(itemButton29); wxButton* itemButton30 = new wxButton( itemDialog1, wxID_CANCEL, _("&Cancel"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton30->SetForegroundColour(wxColour(0, 0, 255)); StdDialogButtonSizer->AddButton(itemButton30); StdDialogButtonSizer->Realize(); // Set validators m_Pad2PadTestCtrl->SetValidator( wxGenericValidator(& s_Pad2PadTestOpt) ); Loading Loading @@ -282,8 +303,10 @@ void WinEDA_DrcFrame::OnDrcRunClick( wxCommandEvent& event ) void WinEDA_DrcFrame::OnStopControlDrcClick( wxCommandEvent& event ) { if ( DrcInProgress ) AbortDrc = TRUE; else wxBell(); if( DrcInProgress ) AbortDrc = TRUE; else wxBell(); } /*! Loading @@ -304,37 +327,6 @@ void WinEDA_DrcFrame::OnListUnconnectedPadsClick( wxCommandEvent& event ) ListUnconnectedPads(event); } /*! * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CLOSE */ void WinEDA_DrcFrame::OnCloseClick( wxCommandEvent& event ) { s_Pad2PadTestOpt = m_Pad2PadTestCtrl->IsChecked(); s_UnconnectedTestOpt = m_UnconnectedTestCtrl->IsChecked(); s_ZonesTestOpt = m_ZonesTestCtrl->IsChecked(); s_CreateRptFileOpt = m_CreateRptCtrl->IsChecked(); Close(); } /*! * wxEVT_CLOSE_WINDOW event handler for ID_DIALOG */ void WinEDA_DrcFrame::OnCloseWindow( wxCloseEvent& event ) { s_Pad2PadTestOpt = m_Pad2PadTestCtrl->IsChecked(); s_UnconnectedTestOpt = m_UnconnectedTestCtrl->IsChecked(); s_ZonesTestOpt = m_ZonesTestCtrl->IsChecked(); s_CreateRptFileOpt = m_CreateRptCtrl->IsChecked(); event.Skip(); } /*! * wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON_BROWSE_RPT_FILE */ Loading @@ -356,7 +348,8 @@ wxString FileName, Mask(wxT("*")), Ext(wxT(".rpt")); wxFD_SAVE, TRUE ); if ( FileName.IsEmpty()) return; if( FileName.IsEmpty() ) return; m_RptFilenameCtrl->SetValue(FileName); s_RptFilename = FileName; Loading Loading @@ -409,3 +402,29 @@ bool WinEDA_DrcFrame::ProcessEvent( wxEvent& event ) } } /*! * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_OK */ void WinEDA_DrcFrame::OnOkClick( wxCommandEvent& event ) { s_Pad2PadTestOpt = m_Pad2PadTestCtrl->IsChecked(); s_UnconnectedTestOpt = m_UnconnectedTestCtrl->IsChecked(); s_ZonesTestOpt = m_ZonesTestCtrl->IsChecked(); s_CreateRptFileOpt = m_CreateRptCtrl->IsChecked(); event.Skip(); } /*! * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL */ void WinEDA_DrcFrame::OnCancelClick( wxCommandEvent& event ) { ////@begin wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL in WinEDA_DrcFrame. // Before editing this code, remove the block markers. event.Skip(); ////@end wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL in WinEDA_DrcFrame. }
pcbnew/dialog_drc.h +26 −16 Original line number Diff line number Diff line Loading @@ -24,6 +24,7 @@ ////@begin includes #include "wx/valgen.h" #include "wx/statline.h" ////@end includes /*! Loading @@ -32,6 +33,8 @@ ////@begin forward declarations class wxBoxSizer; class wxStaticLine; class wxStdDialogButtonSizer; ////@end forward declarations /*! Loading @@ -40,9 +43,9 @@ class wxBoxSizer; ////@begin control identifiers #define ID_DIALOG 10000 #define ID_TEXTCTRL1 10002 #define ID_TEXTCTRL_CLEARANCE 10002 #define ID_CHECKBOX_PAD2PAD 10009 #define ID_CHECKBOX 10008 #define ID_CHECKBOX_UNCONNECTED 10008 #define ID_CHECKBOX_TEST_ZONES 10007 #define ID_CHECKBOX_CREATE_FILE 10012 #define ID_DRC_RUN 10003 Loading @@ -52,7 +55,8 @@ class wxBoxSizer; #define ID_BUTTON_BROWSE_RPT_FILE 10011 #define ID_TEXTCTRL_GET_RPT_FILENAME 10010 #define ID_TEXTCTRL 10001 #define SYMBOL_WINEDA_DRCFRAME_STYLE wxCAPTION|wxSYSTEM_MENU|wxCLOSE_BOX|MAYBE_RESIZE_BORDER #define ID_STATICLINE 10013 #define SYMBOL_WINEDA_DRCFRAME_STYLE wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER #define SYMBOL_WINEDA_DRCFRAME_TITLE _("DRC Control") #define SYMBOL_WINEDA_DRCFRAME_IDNAME ID_DIALOG #define SYMBOL_WINEDA_DRCFRAME_SIZE wxSize(400, 300) Loading Loading @@ -80,7 +84,11 @@ public: /// Constructors WinEDA_DrcFrame( ); WinEDA_DrcFrame( WinEDA_PcbFrame* parent, wxDC * panelDC, wxWindowID id = SYMBOL_WINEDA_DRCFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_DRCFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_DRCFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_DRCFRAME_SIZE, long style = SYMBOL_WINEDA_DRCFRAME_STYLE ); wxWindowID id = SYMBOL_WINEDA_DRCFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_DRCFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_DRCFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_DRCFRAME_SIZE, long style = SYMBOL_WINEDA_DRCFRAME_STYLE ); /// Creation bool Create( wxWindow* parent, wxWindowID id = SYMBOL_WINEDA_DRCFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_DRCFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_DRCFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_DRCFRAME_SIZE, long style = SYMBOL_WINEDA_DRCFRAME_STYLE ); Loading @@ -93,9 +101,6 @@ public: ////@begin WinEDA_DrcFrame event handler declarations /// wxEVT_CLOSE_WINDOW event handler for ID_DIALOG void OnCloseWindow( wxCloseEvent& event ); /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_DRC_RUN void OnDrcRunClick( wxCommandEvent& event ); Loading @@ -108,12 +113,15 @@ public: /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_LIST_UNCONNECTED_PADS void OnListUnconnectedPadsClick( wxCommandEvent& event ); /// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CLOSE void OnCloseClick( wxCommandEvent& event ); /// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON_BROWSE_RPT_FILE void OnButtonBrowseRptFileClick( wxCommandEvent& event ); /// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_OK void OnOkClick( wxCommandEvent& event ); /// wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL void OnCancelClick( wxCommandEvent& event ); ////@end WinEDA_DrcFrame event handler declarations ////@begin WinEDA_DrcFrame member function declarations Loading Loading @@ -143,6 +151,8 @@ public: wxCheckBox* m_CreateRptCtrl; wxTextCtrl* m_RptFilenameCtrl; wxTextCtrl* m_logWindow; wxStaticLine* Line; wxStdDialogButtonSizer* StdDialogButtonSizer; ////@end WinEDA_DrcFrame member variables WinEDA_PcbFrame * m_Parent; wxDC * m_DC; Loading
pcbnew/dialog_drc.pjd +267 −104 File changed.Preview size limit exceeded, changes collapsed. Show changes
pcbnew/dialog_netlist.cpp +54 −46 Original line number Diff line number Diff line Loading @@ -52,7 +52,7 @@ BEGIN_EVENT_TABLE( WinEDA_NetlistFrame, wxDialog ) EVT_BUTTON( ID_COMPILE_RATSNEST, WinEDA_NetlistFrame::OnCompileRatsnestClick ) EVT_BUTTON( wxID_CLOSE, WinEDA_NetlistFrame::OnCloseClick ) EVT_BUTTON( wxID_CANCEL, WinEDA_NetlistFrame::OnCancelClick ) ////@end WinEDA_NetlistFrame event table entries Loading @@ -79,7 +79,6 @@ WinEDA_NetlistFrame::WinEDA_NetlistFrame( WinEDA_PcbFrame* parent, wxDC * DC, wxString title = GetTitle() + NetNameBuffer; SetTitle(title); } /*! Loading @@ -94,15 +93,18 @@ bool WinEDA_NetlistFrame::Create( wxWindow* parent, wxWindowID id, const wxStrin m_ChangeExistantModuleCtrl = NULL; m_DisplayWarningCtrl = NULL; m_MessageWindow = NULL; StdDialogButtonSizer = NULL; ////@end WinEDA_NetlistFrame member initialisation ////@begin WinEDA_NetlistFrame creation SetExtraStyle(GetExtraStyle()|wxWS_EX_BLOCK_EVENTS); SetExtraStyle(wxWS_EX_BLOCK_EVENTS); wxDialog::Create( parent, id, caption, pos, size, style ); CreateControls(); GetSizer()->Fit(this); if (GetSizer()) { GetSizer()->SetSizeHints(this); } Centre(); ////@end WinEDA_NetlistFrame creation return true; Loading @@ -116,7 +118,7 @@ void WinEDA_NetlistFrame::CreateControls() { SetFont( *g_DialogFont ); ////@begin WinEDA_NetlistFrame content construction // Generated by DialogBlocks, 26/02/2006 18:24:19 (unregistered) // Generated by DialogBlocks, 13/11/2007 15:31:19 (unregistered) WinEDA_NetlistFrame* itemDialog1 = this; Loading @@ -124,40 +126,40 @@ void WinEDA_NetlistFrame::CreateControls() itemDialog1->SetSizer(itemBoxSizer2); wxBoxSizer* itemBoxSizer3 = new wxBoxSizer(wxHORIZONTAL); itemBoxSizer2->Add(itemBoxSizer3, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); itemBoxSizer2->Add(itemBoxSizer3, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP, 5); wxBoxSizer* itemBoxSizer4 = new wxBoxSizer(wxVERTICAL); itemBoxSizer3->Add(itemBoxSizer4, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); itemBoxSizer3->Add(itemBoxSizer4, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM, 5); wxString m_Select_By_TimestampStrings[] = { _("Reference"), _("Timestamp") }; m_Select_By_Timestamp = new wxRadioBox( itemDialog1, ID_RADIOBOX, _("Module Selection:"), wxDefaultPosition, wxDefaultSize, 2, m_Select_By_TimestampStrings, 1, wxRA_SPECIFY_COLS ); wxArrayString m_Select_By_TimestampStrings; m_Select_By_TimestampStrings.Add(_("Reference")); m_Select_By_TimestampStrings.Add(_("Timestamp")); m_Select_By_Timestamp = new wxRadioBox( itemDialog1, ID_RADIOBOX, _("Module Selection:"), wxDefaultPosition, wxDefaultSize, m_Select_By_TimestampStrings, 1, wxRA_SPECIFY_COLS ); m_Select_By_Timestamp->SetSelection(0); itemBoxSizer4->Add(m_Select_By_Timestamp, 0, wxGROW|wxALL, 5); wxString m_DeleteBadTracksStrings[] = { _("Keep"), _("Delete") }; m_DeleteBadTracks = new wxRadioBox( itemDialog1, ID_RADIOBOX1, _("Bad Tracks Deletion:"), wxDefaultPosition, wxDefaultSize, 2, m_DeleteBadTracksStrings, 1, wxRA_SPECIFY_COLS ); wxArrayString m_DeleteBadTracksStrings; m_DeleteBadTracksStrings.Add(_("Keep")); m_DeleteBadTracksStrings.Add(_("Delete")); m_DeleteBadTracks = new wxRadioBox( itemDialog1, ID_RADIOBOX1, _("Bad Tracks Deletion:"), wxDefaultPosition, wxDefaultSize, m_DeleteBadTracksStrings, 1, wxRA_SPECIFY_COLS ); m_DeleteBadTracks->SetSelection(0); itemBoxSizer4->Add(m_DeleteBadTracks, 0, wxGROW|wxALL, 5); wxString m_ChangeExistantModuleCtrlStrings[] = { _("Keep"), _("Change") }; m_ChangeExistantModuleCtrl = new wxRadioBox( itemDialog1, ID_RADIOBOX2, _("Exchange Module:"), wxDefaultPosition, wxDefaultSize, 2, m_ChangeExistantModuleCtrlStrings, 1, wxRA_SPECIFY_COLS ); wxArrayString m_ChangeExistantModuleCtrlStrings; m_ChangeExistantModuleCtrlStrings.Add(_("Keep")); m_ChangeExistantModuleCtrlStrings.Add(_("Change")); m_ChangeExistantModuleCtrl = new wxRadioBox( itemDialog1, ID_RADIOBOX2, _("Exchange Module:"), wxDefaultPosition, wxDefaultSize, m_ChangeExistantModuleCtrlStrings, 1, wxRA_SPECIFY_COLS ); m_ChangeExistantModuleCtrl->SetSelection(0); itemBoxSizer4->Add(m_ChangeExistantModuleCtrl, 0, wxGROW|wxALL, 5); m_DisplayWarningCtrl = new wxCheckBox( itemDialog1, ID_CHECKBOX, _("Display Warnings"), wxDefaultPosition, wxDefaultSize, wxCHK_2STATE ); m_DisplayWarningCtrl->SetValue(false); itemBoxSizer4->Add(m_DisplayWarningCtrl, 0, wxGROW|wxALL, 5); itemBoxSizer4->Add(m_DisplayWarningCtrl, 0, wxGROW|wxLEFT|wxRIGHT|wxTOP, 5); itemBoxSizer3->Add(5, 5, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); itemBoxSizer3->Add(5, 5, 1, wxALIGN_CENTER_VERTICAL|wxALL, 5); wxBoxSizer* itemBoxSizer10 = new wxBoxSizer(wxVERTICAL); itemBoxSizer3->Add(itemBoxSizer10, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); itemBoxSizer3->Add(itemBoxSizer10, 0, wxALIGN_CENTER_VERTICAL|wxTOP|wxBOTTOM, 5); wxButton* itemButton11 = new wxButton( itemDialog1, ID_OPEN_NELIST, _("Select"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton11->SetForegroundColour(wxColour(217, 0, 0)); Loading @@ -175,12 +177,20 @@ void WinEDA_NetlistFrame::CreateControls() itemButton14->SetForegroundColour(wxColour(0, 0, 132)); itemBoxSizer10->Add(itemButton14, 0, wxGROW|wxALL, 5); wxButton* itemButton15 = new wxButton( itemDialog1, wxID_CLOSE, _("&Close"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton15->SetForegroundColour(wxColour(128, 0, 128)); itemBoxSizer10->Add(itemButton15, 0, wxGROW|wxALL, 5); m_MessageWindow = new wxTextCtrl( itemDialog1, ID_TEXTCTRL, _T(""), wxDefaultPosition, wxSize(-1, 120), wxTE_MULTILINE|wxTE_READONLY ); itemBoxSizer2->Add(m_MessageWindow, 0, wxGROW|wxALL, 5); itemBoxSizer2->Add(m_MessageWindow, 1, wxGROW|wxALL, 10); wxStaticLine* itemStaticLine16 = new wxStaticLine( itemDialog1, ID_STATICLINE, wxDefaultPosition, wxDefaultSize, wxLI_HORIZONTAL ); itemBoxSizer2->Add(itemStaticLine16, 0, wxGROW|wxLEFT|wxRIGHT, 5); StdDialogButtonSizer = new wxStdDialogButtonSizer; itemBoxSizer2->Add(StdDialogButtonSizer, 0, wxGROW|wxALL, 10); wxButton* itemButton18 = new wxButton( itemDialog1, wxID_CANCEL, _("&Cancel"), wxDefaultPosition, wxDefaultSize, 0 ); itemButton18->SetForegroundColour(wxColour(0, 0, 255)); StdDialogButtonSizer->AddButton(itemButton18); StdDialogButtonSizer->Realize(); // Set validators m_DisplayWarningCtrl->SetValidator( wxGenericValidator(& DisplayWarning) ); Loading Loading @@ -258,12 +268,10 @@ void WinEDA_NetlistFrame::OnCompileRatsnestClick( wxCommandEvent& event ) } /*! * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CLOSE * wxEVT_COMMAND_BUTTON_CLICKED event handler for wxID_CANCEL */ void WinEDA_NetlistFrame::OnCloseClick( wxCommandEvent& event ) void WinEDA_NetlistFrame::OnCancelClick( wxCommandEvent& event ) { Close(); EndModal( -1 ); }