Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
K
kicad-source-mirror
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Commits
Open sidebar
Elphel
kicad-source-mirror
Commits
15b70020
Commit
15b70020
authored
Dec 03, 2007
by
dickelbeck
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
drc work
parent
4002c6f4
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
35 additions
and
32 deletions
+35
-32
dialog_drc.cpp
pcbnew/dialog_drc.cpp
+30
-26
dialog_drc.h
pcbnew/dialog_drc.h
+4
-1
drc.cpp
pcbnew/drc.cpp
+1
-0
drc_stuff.h
pcbnew/drc_stuff.h
+0
-5
No files found.
pcbnew/dialog_drc.cpp
View file @
15b70020
...
...
@@ -39,6 +39,12 @@
////@end XPM images
/**
* Class DRC_LIST_MARKERS
* is an implementation of the interface named DRC_ITEM_LIST which uses
* a BOARD instance to fulfill the interface. No ownership is taken of the
* BOARD.
*/
class
DRC_LIST_MARKERS
:
public
DRC_ITEM_LIST
{
BOARD
*
m_board
;
...
...
@@ -55,7 +61,7 @@ public:
*/
//-----<Interface DRC_ITEM_LIST
>---------------------------------------
//-----<Interface DRC_ITEM_LIST>---------------------------------------
void
DeleteAllItems
()
{
...
...
@@ -86,13 +92,11 @@ public:
return
m_board
->
GetMARKERCount
();
}
//-----</Interface DRC_ITEM_LIST
>--------------------------------------
//-----</Interface DRC_ITEM_LIST>--------------------------------------
};
/**
* Class DRCLISTBOX
* is used to display a DRC_ITEM_LIST.
...
...
@@ -120,7 +124,7 @@ public:
/**
* Function SetList
* sets the DRC_LIST for this listbox. Ownership of the DRC_ITEM_LIST is
* sets the DRC_
ITEM_
LIST for this listbox. Ownership of the DRC_ITEM_LIST is
* transfered to this DRCLISTBOX.
* @param aList The DRC_ITEM_LIST* containing the DRC_ITEMs which will be
* displayed in the wxHtmlListBox
...
...
@@ -139,7 +143,7 @@ public:
* Function OnGetItem
* returns the html text associated with the DRC_ITEM given by index 'n'.
* @param n An index into the list.
* @return wxString - the simpl
y
html text to show in the listbox.
* @return wxString - the simpl
e
html text to show in the listbox.
*/
wxString
OnGetItem
(
size_t
n
)
const
{
...
...
@@ -157,7 +161,7 @@ public:
* Function OnGetItem
* returns the html text associated with the given index 'n'.
* @param n An index into the list.
* @return wxString - the simpl
y
html text to show in the listbox.
* @return wxString - the simpl
e
html text to show in the listbox.
*/
wxString
OnGetItemMarkup
(
size_t
n
)
const
{
...
...
@@ -463,7 +467,6 @@ void DrcDialog::CreateControls()
m_UnconnectedListBox
->
Connect
(
ID_UNCONNECTED_LIST
,
wxEVT_RIGHT_UP
,
wxMouseEventHandler
(
DrcDialog
::
OnRightUpUnconnected
),
NULL
,
this
);
////@end DrcDialog content construction
// @todo this is expanding the Clearance text, so we need to recalc sizers.
AddUnitSymbol
(
*
m_ClearenceTitle
);
Layout
();
// adding the units above expanded Clearance text, now resize.
...
...
@@ -535,12 +538,12 @@ void DrcDialog::OnStartdrcClick( wxCommandEvent& event )
m_ZonesTestCtrl
->
IsChecked
(),
reportName
,
m_CreateRptCtrl
->
IsChecked
()
);
m_Parent
->
Erase_Marqueurs
();
m_Parent
->
ReDrawPanel
();
DelDRCMarkers
();
SetCursor
(
wxCursor
(
wxCURSOR_WAIT
)
);
wxYield
();
// process the cursor change event and the redraw.
// run all the tests, with no UI at this time.
m_tester
->
RunTests
();
...
...
@@ -557,24 +560,20 @@ void DrcDialog::OnStartdrcClick( wxCommandEvent& event )
//msg.Printf( _( "Report file <%s> created\n" ), s_RptFilename.GetData() );
}
SetCursor
(
wxCursor
(
wxCURSOR_WATCH
)
);
// @todo set the list counts in the DRCLISTITEMS here.
m_Parent
->
ReDrawPanel
();
SetCursor
(
wxCursor
(
wxCURSOR_ARROW
)
);
// printf("done with tests\n"
);
RedrawDrawPanel
(
);
}
/*!
* wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_ERASE_DRC_MARKERS
*/
void
DrcDialog
::
OnDeleteAllClick
(
wxCommandEvent
&
event
)
{
m_ClearanceListBox
->
DeleteAllItems
();
m_UnconnectedListBox
->
DeleteAllItems
();
m_Parent
->
ReDrawPanel
();
DelDRCMarkers
();
RedrawDrawPanel
();
}
...
...
@@ -607,11 +606,12 @@ void DrcDialog::OnListUnconnectedClick( wxCommandEvent& event )
m_ZonesTestCtrl
->
IsChecked
(),
reportName
,
m_CreateRptCtrl
->
IsChecked
()
);
DelDRCMarkers
();
SetCursor
(
wxCursor
(
wxCURSOR_WAIT
)
);
wxYield
();
// run all the tests, with no UI at this time.
m_tester
->
ListUnconnectedPads
();
...
...
@@ -628,11 +628,11 @@ void DrcDialog::OnListUnconnectedClick( wxCommandEvent& event )
//msg.Printf( _( "Report file <%s> created\n" ), s_RptFilename.GetData() );
}
SetCursor
(
wxCursor
(
wxCURSOR_
WATCH
)
);
SetCursor
(
wxCursor
(
wxCURSOR_
ARROW
)
);
// @todo set the list counts in the DRCLISTITEMS here.
m_Parent
->
Re
DrawPanel
();
Redraw
DrawPanel
();
}
/*!
...
...
@@ -826,14 +826,18 @@ void DrcDialog::OnUnconnectedSelectionEvent( wxCommandEvent& event )
}
void
DrcDialog
::
RedrawDrawPanel
()
{
m_Parent
->
DrawPanel
->
Refresh
();
}
/*********************************************************/
void
DrcDialog
::
DelDRCMarkers
()
/*********************************************************/
{
m_
Parent
->
Erase_Marqueur
s
();
m_
Parent
->
ReDrawPanel
();
m_
ClearanceListBox
->
DeleteAllItem
s
();
m_
UnconnectedListBox
->
DeleteAllItems
();
}
...
...
pcbnew/dialog_drc.h
View file @
15b70020
...
...
@@ -160,6 +160,8 @@ public:
static
bool
ShowToolTips
();
void
DelDRCMarkers
();
void
RedrawDrawPanel
();
////@begin DrcDialog member variables
wxBoxSizer
*
m_MainSizer
;
...
...
@@ -181,6 +183,7 @@ public:
////@end DrcDialog member variables
DRC
*
m_tester
;
WinEDA_PcbFrame
*
m_Parent
;
int
m_UnconnectedCount
;
...
...
pcbnew/drc.cpp
View file @
15b70020
...
...
@@ -92,6 +92,7 @@ DRC::DRC( WinEDA_PcbFrame* aPcbWindow )
m_mainWindow
=
aPcbWindow
;
m_drawPanel
=
aPcbWindow
->
DrawPanel
;
m_pcb
=
aPcbWindow
->
m_Pcb
;
m_ui
=
0
;
// establish initial values for everything:
m_doPad2PadTest
=
true
;
...
...
pcbnew/drc_stuff.h
View file @
15b70020
...
...
@@ -250,11 +250,6 @@ public:
/**
* Class DRC
* is the Design Rule Checker, and performs all the DRC tests. The output of
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment