KiCad PCB EDA Suite
dialog_erc.h
Go to the documentation of this file.
1 /*
2  * This program source code file is part of KiCad, a free EDA CAD application.
3  *
4  * Copyright (C) 2007 Jean-Pierre Charras, jp.charras at wanadoo.fr
5  * Copyright (C) 1992-2021 KiCad Developers, see AUTHORS.txt for contributors.
6  *
7  * This program is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License
9  * as published by the Free Software Foundation; either version 2
10  * of the License, or (at your option) any later version.
11  *
12  * This program is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with this program; if not, you may find one here:
19  * http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
20  * or you may search the http://www.gnu.org website for the version 2 license,
21  * or you may write to the Free Software Foundation, Inc.,
22  * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
23  */
24 
25 #ifndef _DIALOG_ERC_H_
26 #define _DIALOG_ERC_H_
27 
28 #include <wx/htmllbox.h>
29 #include <vector>
30 #include <lib_pin.h> // For PINTYPE_COUNT definition
31 
32 #include <dialog_erc_base.h>
34 #include <erc_settings.h>
35 
36 
38 {
39 public:
40  DIALOG_ERC( SCH_EDIT_FRAME* parent );
41  ~DIALOG_ERC();
42 
43  // PROGRESS_REPORTER_BASE calls
44  bool updateUI() override;
45  void AdvancePhase( const wxString& aMessage ) override;
46  void Report( const wxString& aMessage ) override;
47 
48  void PrevMarker();
49  void NextMarker();
50  void ExcludeMarker();
51 
52 private:
53  // from DIALOG_ERC_BASE:
54  void OnCloseErcDialog( wxCloseEvent& event ) override;
55  void OnRunERCClick( wxCommandEvent& event ) override;
56  void OnEraseDrcMarkersClick( wxCommandEvent& event ) override;
57  void OnERCItemSelected( wxDataViewEvent& aEvent ) override;
58  void OnERCItemDClick( wxDataViewEvent& aEvent ) override;
59  void OnERCItemRClick( wxDataViewEvent& aEvent ) override;
60  void OnLinkClicked( wxHtmlLinkEvent& event ) override;
61 
62  void OnSeverity( wxCommandEvent& aEvent ) override;
63  void OnSaveReport( wxCommandEvent& aEvent ) override;
64  void OnCancelClick( wxCommandEvent& event ) override;
65 
66  void redrawDrawPanel();
67 
68  void testErc();
69 
70  bool writeReport( const wxString& aFullFileName );
71 
72  void deleteAllMarkers( bool aIncludeExclusions );
73 
74  void syncCheckboxes();
75  void updateDisplayedCounts();
76 
77 private:
79 
82 
83  bool m_running;
84  bool m_ercRun;
85 
87 };
88 
89 
90 #endif
91 
92 // _DIALOG_ERC_H_
void deleteAllMarkers(bool aIncludeExclusions)
Definition: dialog_erc.cpp:723
void OnERCItemRClick(wxDataViewEvent &aEvent) override
Definition: dialog_erc.cpp:471
void OnCancelClick(wxCommandEvent &event) override
Definition: dialog_erc.cpp:215
RC_TREE_MODEL * m_markerTreeModel
Definition: dialog_erc.h:81
bool m_running
Definition: dialog_erc.h:83
void ExcludeMarker()
Definition: dialog_erc.cpp:663
void syncCheckboxes()
Definition: dialog_erc.cpp:240
virtual void AdvancePhase() override
Use the next available virtual zone of the dialog progress bar.
Class DIALOG_ERC_BASE.
void OnLinkClicked(wxHtmlLinkEvent &event) override
Definition: dialog_erc.cpp:249
bool writeReport(const wxString &aFullFileName)
Definition: dialog_erc.cpp:766
void OnEraseDrcMarkersClick(wxCommandEvent &event) override
Definition: dialog_erc.cpp:184
void PrevMarker()
Definition: dialog_erc.cpp:645
RC_ITEMS_PROVIDER * m_markerProvider
Definition: dialog_erc.h:80
void updateDisplayedCounts()
Definition: dialog_erc.cpp:157
Schematic editor (Eeschema) main window.
void OnSeverity(wxCommandEvent &aEvent) override
Definition: dialog_erc.cpp:689
Provide an abstract interface of a RC_ITEM* list manager.
Definition: rc_item.h:45
void Report(const wxString &aMessage) override
Display aMessage in the progress bar dialog.
Definition: dialog_erc.cpp:151
int m_severities
Definition: dialog_erc.h:86
DIALOG_ERC(SCH_EDIT_FRAME *parent)
Definition: dialog_erc.cpp:55
void OnERCItemSelected(wxDataViewEvent &aEvent) override
Definition: dialog_erc.cpp:429
SCH_EDIT_FRAME * m_parent
Definition: dialog_erc.h:78
void OnCloseErcDialog(wxCloseEvent &event) override
Definition: dialog_erc.cpp:229
This implements all the tricky bits for thread safety, but the GUI is left to derived classes.
void testErc()
Definition: dialog_erc.cpp:339
void OnERCItemDClick(wxDataViewEvent &aEvent) override
Definition: dialog_erc.cpp:457
bool updateUI() override
Definition: dialog_erc.cpp:129
void NextMarker()
Definition: dialog_erc.cpp:654
void OnSaveReport(wxCommandEvent &aEvent) override
Definition: dialog_erc.cpp:732
bool m_ercRun
Definition: dialog_erc.h:84
void redrawDrawPanel()
Definition: dialog_erc.cpp:331
void OnRunERCClick(wxCommandEvent &event) override
Definition: dialog_erc.cpp:261