Pcbnew: cleanup functions: now, cleanup uses same algorithm as connectivity calculations to detect pads connections, and is faster.
therefore tracks which have a end point inside a pad, but not necessaryexactly to the pad position are seen as connected, and are no more removed. Side effect: reconnect to pads option is removed, because it is useless. TODO: use this algorithm in drag functions. Minor other fixes
This commit is contained in:
parent
5aec46049d
commit
3668f4ccc3
|
@ -55,6 +55,13 @@
|
|||
double s_HerscheyScaleFactor = HERSHEY_SCALE_FACTOR;
|
||||
|
||||
|
||||
/* Helper function for texts with over bar
|
||||
*/
|
||||
int OverbarPositionY( int size_v, int thickness )
|
||||
{
|
||||
return KiROUND( ( (double) size_v * 1.1 ) + ( (double) thickness * 1.5 ) );
|
||||
}
|
||||
|
||||
/**
|
||||
* Function GetPensizeForBold
|
||||
* @return the "best" value for a pen size to draw/plot a bold text
|
||||
|
@ -68,7 +75,7 @@ int GetPenSizeForBold( int aTextSize )
|
|||
|
||||
/**
|
||||
* Function Clamp_Text_PenSize
|
||||
*As a rule, pen width should not be >1/4em, otherwise the character
|
||||
* As a rule, pen width should not be >1/4em, otherwise the character
|
||||
* will be cluttered up in its own fatness
|
||||
* so pen width max is aSize/4 for bold text, and aSize/6 for normal text
|
||||
* The "best" pen width is aSize/5 for bold texts,
|
||||
|
@ -219,14 +226,6 @@ static void DrawGraphicTextPline(
|
|||
}
|
||||
|
||||
|
||||
/* Helper function for texts with over bar
|
||||
*/
|
||||
static int overbar_position( int size_v, int thickness )
|
||||
{
|
||||
return KiROUND( ( (double) size_v * 26 * s_HerscheyScaleFactor ) + ( (double) thickness * 1.5 ) );
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* Function DrawGraphicText
|
||||
* Draw a graphic text (like module texts)
|
||||
|
@ -271,7 +270,6 @@ void DrawGraphicText( EDA_DRAW_PANEL* aPanel,
|
|||
int dx, dy; // Draw coordinate for segments to draw. also used in some other calculation
|
||||
wxPoint current_char_pos; // Draw coordinates for the current char
|
||||
wxPoint overbar_pos; // Start point for the current overbar
|
||||
int overbars; // Number of ~ seen
|
||||
int overbar_italic_comp; // Italic compensation for overbar
|
||||
EDA_RECT* clipBox; // Clip box used in basic draw functions
|
||||
|
||||
|
@ -400,7 +398,7 @@ void DrawGraphicText( EDA_DRAW_PANEL* aPanel,
|
|||
|
||||
if( aItalic )
|
||||
{
|
||||
overbar_italic_comp = overbar_position( size_v, aWidth ) / 8;
|
||||
overbar_italic_comp = OverbarPositionY( size_v, aWidth ) / 8;
|
||||
if( italic_reverse )
|
||||
{
|
||||
overbar_italic_comp = -overbar_italic_comp;
|
||||
|
@ -411,7 +409,7 @@ void DrawGraphicText( EDA_DRAW_PANEL* aPanel,
|
|||
overbar_italic_comp = 0;
|
||||
};
|
||||
|
||||
overbars = 0;
|
||||
int overbars = 0; // Number of ~ seen
|
||||
ptr = 0; /* ptr = text index */
|
||||
while( ptr < char_count )
|
||||
{
|
||||
|
@ -420,12 +418,12 @@ void DrawGraphicText( EDA_DRAW_PANEL* aPanel,
|
|||
/* Found an overbar, adjust the pointers */
|
||||
overbars++;
|
||||
|
||||
if( overbars % 2 )
|
||||
if( overbars & 1 ) // odd overbars count
|
||||
{
|
||||
/* Starting the overbar */
|
||||
overbar_pos = current_char_pos;
|
||||
overbar_pos.x += overbar_italic_comp;
|
||||
overbar_pos.y -= overbar_position( size_v, aWidth );
|
||||
overbar_pos.y -= OverbarPositionY( size_v, aWidth );
|
||||
RotatePoint( &overbar_pos, aPos, aOrient );
|
||||
}
|
||||
else
|
||||
|
@ -434,7 +432,7 @@ void DrawGraphicText( EDA_DRAW_PANEL* aPanel,
|
|||
coord[0] = overbar_pos;
|
||||
overbar_pos = current_char_pos;
|
||||
overbar_pos.x += overbar_italic_comp;
|
||||
overbar_pos.y -= overbar_position( size_v, aWidth );
|
||||
overbar_pos.y -= OverbarPositionY( size_v, aWidth );
|
||||
RotatePoint( &overbar_pos, aPos, aOrient );
|
||||
coord[1] = overbar_pos;
|
||||
/* Plot the overbar segment */
|
||||
|
@ -516,7 +514,7 @@ void DrawGraphicText( EDA_DRAW_PANEL* aPanel,
|
|||
/* Close the last overbar */
|
||||
coord[0] = overbar_pos;
|
||||
overbar_pos = current_char_pos;
|
||||
overbar_pos.y -= overbar_position( size_v, aWidth );
|
||||
overbar_pos.y -= OverbarPositionY( size_v, aWidth );
|
||||
RotatePoint( &overbar_pos, aPos, aOrient );
|
||||
coord[1] = overbar_pos;
|
||||
/* Plot the overbar segment */
|
||||
|
|
|
@ -44,6 +44,7 @@
|
|||
|
||||
|
||||
extern void IncrementLabelMember( wxString& name );
|
||||
extern int OverbarPositionY( int size_v, int thickness );
|
||||
|
||||
|
||||
/* Names of sheet label types. */
|
||||
|
@ -273,19 +274,19 @@ void SCH_TEXT::Rotate( wxPoint aPosition )
|
|||
|
||||
switch( GetOrientation() )
|
||||
{
|
||||
case 0: /* horizontal text */
|
||||
case 0: // horizontal text
|
||||
dy = m_Size.y;
|
||||
break;
|
||||
|
||||
case 1: /* Vert Orientation UP */
|
||||
case 1: // Vert Orientation UP
|
||||
dy = 0;
|
||||
break;
|
||||
|
||||
case 2: /* invert horizontal text*/
|
||||
case 2: // invert horizontal text
|
||||
dy = m_Size.y;
|
||||
break;
|
||||
|
||||
case 3: /* Vert Orientation BOTTOM */
|
||||
case 3: // Vert Orientation BOTTOM
|
||||
dy = 0;
|
||||
break;
|
||||
|
||||
|
@ -1241,8 +1242,14 @@ void SCH_GLOBALLABEL::CreateGraphicShape( std::vector <wxPoint>& aPoints, const
|
|||
// Create outline shape : 6 points
|
||||
int x = symb_len + linewidth + 3;
|
||||
|
||||
// 50% more for negation bar
|
||||
int y = KiROUND( (double) HalfSize * 1.5 + (double) linewidth + 3.0 );
|
||||
// Use negation bar Y position to calculate full vertical size
|
||||
#define Y_CORRECTION 1.22
|
||||
// Note: this factor is due to the fact the negation bar Y position
|
||||
// does not give exactly the full Y size of text
|
||||
// and is experimentally set to this value
|
||||
int y = KiROUND( OverbarPositionY( HalfSize, linewidth ) * Y_CORRECTION );
|
||||
// add room for line thickness and space between top of text and graphic shape
|
||||
y += linewidth;
|
||||
|
||||
// Starting point(anchor)
|
||||
aPoints.push_back( wxPoint( 0, 0 ) );
|
||||
|
|
846
pcbnew/clean.cpp
846
pcbnew/clean.cpp
File diff suppressed because it is too large
Load Diff
|
@ -34,11 +34,10 @@
|
|||
#include <macros.h>
|
||||
#include <wxBasePcbFrame.h>
|
||||
|
||||
#include <class_track.h>
|
||||
#include <class_board.h>
|
||||
|
||||
#include <pcbnew.h>
|
||||
|
||||
// Helper classes to handle connection points
|
||||
#include <connect.h>
|
||||
|
||||
extern void Merge_SubNets_Connected_By_CopperAreas( BOARD* aPcb );
|
||||
extern void Merge_SubNets_Connected_By_CopperAreas( BOARD* aPcb, int aNetcode );
|
||||
|
@ -47,204 +46,6 @@ extern void Merge_SubNets_Connected_By_CopperAreas( BOARD* aPcb, int aNetcode );
|
|||
static void RebuildTrackChain( BOARD* pcb );
|
||||
|
||||
|
||||
// A helper class to handle connection points (i.e. candidates) for tracks
|
||||
class CONNECTED_POINT
|
||||
{
|
||||
private:
|
||||
BOARD_CONNECTED_ITEM * m_item; // a link to the parent item (track, via or pad)
|
||||
wxPoint m_point; // the connection point
|
||||
|
||||
public:
|
||||
CONNECTED_POINT( TRACK * aTrack, const wxPoint & aPoint)
|
||||
{
|
||||
m_item = aTrack;
|
||||
m_point = aPoint;
|
||||
}
|
||||
|
||||
CONNECTED_POINT( D_PAD * aPad, const wxPoint & aPoint)
|
||||
{
|
||||
m_item = aPad;
|
||||
m_point = aPoint;
|
||||
}
|
||||
|
||||
TRACK * GetTrack() const
|
||||
{
|
||||
return m_item->Type() != PCB_PAD_T ? (TRACK*) m_item : NULL ;
|
||||
}
|
||||
|
||||
D_PAD * GetPad() const
|
||||
{
|
||||
return m_item->Type() == PCB_PAD_T ? (D_PAD*) m_item : NULL;
|
||||
}
|
||||
|
||||
const wxPoint & GetPoint() const { return m_point; }
|
||||
};
|
||||
|
||||
// A helper class to handle connections calculations:
|
||||
class CONNECTIONS
|
||||
{
|
||||
private:
|
||||
std::vector <TRACK*> m_connected; // List of connected tracks/vias
|
||||
// to a given track or via
|
||||
std::vector <CONNECTED_POINT> m_candidates; // List of points to test
|
||||
// (end points of tracks or vias location )
|
||||
BOARD * m_brd; // the master board.
|
||||
const TRACK * m_firstTrack; // The first track used to build m_Candidates
|
||||
const TRACK * m_lastTrack; // The last track used to build m_Candidates
|
||||
std::vector<D_PAD*> m_sortedPads; // list of sorted pads by X (then Y) coordinate
|
||||
|
||||
public:
|
||||
CONNECTIONS( BOARD * aBrd );
|
||||
~CONNECTIONS() {};
|
||||
|
||||
/** Function BuildPadsList
|
||||
* Fills m_sortedPads with all pads that be connected to tracks
|
||||
* pads are sorted by > then Y coordinates to allow fast binary search in list
|
||||
* @param aNetcode = net code to use to filter pads
|
||||
* if aNetcode < 0, all pads will be put in list (default)
|
||||
*/
|
||||
void BuildPadsList( int aNetcode = -1 );
|
||||
|
||||
/**
|
||||
* @return the pads list used in connections calculations
|
||||
*/
|
||||
std::vector<D_PAD*>& GetPadsList() { return m_sortedPads; }
|
||||
|
||||
/**
|
||||
* Function Build_CurrNet_SubNets_Connections
|
||||
* should be called after a track change (delete or add a track):
|
||||
* Connections to pads and to tracks are recalculated
|
||||
* If a track is deleted, the other pointers to pads do not change.
|
||||
* When a new track is added in track list, its pointers to pads are already initialized
|
||||
* Builds the subnets inside a net (tracks from aFirstTrack to aFirstTrack).
|
||||
* subnets are clusters of pads and tracks that are connected together.
|
||||
* When all tracks are created relative to the net, there is only a cluster
|
||||
* when not tracks there are a cluster per pad
|
||||
* @param aFirstTrack = first track of the given net
|
||||
* @param aLastTrack = last track of the given net
|
||||
* @param aNetcode = the netcode of the given net
|
||||
*/
|
||||
void Build_CurrNet_SubNets_Connections( TRACK* aFirstTrack, TRACK* aLastTrack, int aNetcode );
|
||||
|
||||
/**
|
||||
* Function BuildTracksCandidatesList
|
||||
* Fills m_Candidates with all connecting points (track ends or via location)
|
||||
* with tracks from aBegin to aEnd.
|
||||
* if aEnd == NULL, uses all tracks from aBegin
|
||||
*/
|
||||
void BuildTracksCandidatesList( TRACK * aBegin, TRACK * aEnd = NULL);
|
||||
|
||||
/**
|
||||
* Function BuildPadsCandidatesList
|
||||
* Fills m_Candidates with all pads connecting points (pads position)
|
||||
* m_sortedPads must be built
|
||||
*/
|
||||
void BuildPadsCandidatesList();
|
||||
|
||||
/**
|
||||
* function SearchConnectedTracks
|
||||
* Fills m_Connected with tracks/vias connected to aTrack
|
||||
* @param aTrack = track or via to use as reference
|
||||
*/
|
||||
int SearchConnectedTracks( const TRACK * aTrack );
|
||||
|
||||
/**
|
||||
* Function GetConnectedTracks
|
||||
* Copy m_Connected that contains the list of tracks connected
|
||||
* calculated by SearchConnectedTracks
|
||||
* in aTrack->m_TracksConnected
|
||||
* @param aTrack = track or via to fill with connected tracks
|
||||
*/
|
||||
void GetConnectedTracks(TRACK * aTrack)
|
||||
{
|
||||
aTrack->m_TracksConnected = m_connected;
|
||||
}
|
||||
|
||||
/**
|
||||
* function SearchConnectionsPadsToIntersectingPads
|
||||
* Explores the list of pads and adds to m_PadsConnected member
|
||||
* of each pad pads connected to
|
||||
* Here, connections are due to intersecting pads, not tracks
|
||||
* m_sortedPads must be initialized
|
||||
*/
|
||||
void SearchConnectionsPadsToIntersectingPads();
|
||||
|
||||
/**
|
||||
* function SearchTracksConnectedToPads
|
||||
* Explores the list of pads.
|
||||
* Adds to m_PadsConnected member of each track the pad(s) connected to
|
||||
* Adds to m_TracksConnected member of each pad the track(s) connected to
|
||||
* D_PAD::m_TracksConnected is cleared before adding items
|
||||
* TRACK::m_PadsConnected is not cleared
|
||||
*/
|
||||
void SearchTracksConnectedToPads();
|
||||
|
||||
/**
|
||||
* function CollectItemsNearTo
|
||||
* Used by SearchTracksConnectedToPads
|
||||
* Fills aList with pads near to aPosition
|
||||
* near means aPosition to pad position <= aDistMax
|
||||
* @param aList = list to fill
|
||||
* @param aPosition = aPosition to use as reference
|
||||
* @param aDistMax = dist max from aPosition to a candidate to select it
|
||||
*/
|
||||
void CollectItemsNearTo( std::vector<CONNECTED_POINT*>& aList,
|
||||
const wxPoint& aPosition, int aDistMax );
|
||||
|
||||
/**
|
||||
* Function Propagate_SubNets
|
||||
* Test a list of tracks, to create or propagate a sub netcode to pads and
|
||||
* segments connected together.
|
||||
* The track list must be sorted by nets, and all segments
|
||||
* from m_firstTrack to m_lastTrack have the same net.
|
||||
* When 2 items are connected (a track to a pad, or a track to an other track),
|
||||
* they are grouped in a cluster.
|
||||
* For pads, this is the .m_physical_connexion member which is a cluster identifier
|
||||
* For tracks, this is the .m_Subnet member which is a cluster identifier
|
||||
* For a given net, if all tracks are created, there is only one cluster.
|
||||
* but if not all tracks are created, there are more than one cluster,
|
||||
* and some ratsnests will be left active.
|
||||
*/
|
||||
void Propagate_SubNets();
|
||||
|
||||
private:
|
||||
/**
|
||||
* function searchEntryPointInCandidatesList
|
||||
* Search an item in m_Connected connected to aPoint
|
||||
* note m_Connected containts usually more than one candidate
|
||||
* and searchEntryPointInCandidatesList returns an index to one of these candidates
|
||||
* Others are neightbor of the indexed item.
|
||||
* @param aPoint is the reference coordinates
|
||||
* @return the index of item found or -1 if no candidate
|
||||
*/
|
||||
int searchEntryPointInCandidatesList( const wxPoint & aPoint);
|
||||
|
||||
/**
|
||||
* Function Merge_SubNets
|
||||
* Change a subnet old value to a new value, for tracks and pads which are connected to
|
||||
* tracks from m_firstTrack to m_lastTrack and their connected pads.
|
||||
* and modify the subnet parameter (change the old value to the new value).
|
||||
* After that, 2 cluster (or subnets) are merged into only one.
|
||||
* Note: the resulting sub net value is the smallest between aOldSubNet and aNewSubNet
|
||||
* @return modification count
|
||||
* @param aOldSubNet = subnet value to modify
|
||||
* @param aNewSubNet = new subnet value for each item which have old_val as subnet value
|
||||
*/
|
||||
int Merge_SubNets( int aOldSubNet, int aNewSubNet );
|
||||
|
||||
/**
|
||||
* Function Merge_PadsSubNets
|
||||
* Change a subnet value to a new value, in m_sortedPads pad list
|
||||
* After that, 2 cluster (or subnets) are merged into only one.
|
||||
* Note: the resulting subnet value is the smallest between aOldSubNet et aNewSubNet
|
||||
* @return modification count
|
||||
* @param aOldSubNet = subnet value to modify
|
||||
* @param aNewSubNet = new subnet value for each item which have old_val as subnet value
|
||||
*/
|
||||
int Merge_PadsSubNets( int aOldSubNet, int aNewSubNet );
|
||||
};
|
||||
|
||||
|
||||
CONNECTIONS::CONNECTIONS( BOARD * aBrd )
|
||||
{
|
||||
m_brd = aBrd;
|
||||
|
@ -441,10 +242,6 @@ static bool sortConnectedPointByXthenYCoordinates( const CONNECTED_POINT & aRef,
|
|||
void CONNECTIONS::BuildTracksCandidatesList( TRACK * aBegin, TRACK * aEnd)
|
||||
{
|
||||
m_candidates.clear();
|
||||
|
||||
// if( aBegin == NULL )
|
||||
// aBegin = m_brd->m_Track;
|
||||
|
||||
m_firstTrack = m_lastTrack = aBegin;
|
||||
|
||||
unsigned ii = 0;
|
||||
|
|
|
@ -0,0 +1,258 @@
|
|||
/**
|
||||
* @file connect.h
|
||||
* @brief helper classes to find track to track and track to pad connections.
|
||||
*/
|
||||
#ifndef CONNECT_H
|
||||
#define CONNECT_H
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2012 Jean-Pierre Charras, jp.charras at wanadoo.fr
|
||||
* Copyright (C) 2012 SoftPLC Corporation, Dick Hollenbeck <dick@softplc.com>
|
||||
* Copyright (C) 1992-2012 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
* as published by the Free Software Foundation; either version 2
|
||||
* of the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, you may find one here:
|
||||
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
* or you may search the http://www.gnu.org website for the version 2 license,
|
||||
* or you may write to the Free Software Foundation, Inc.,
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
|
||||
#include <class_track.h>
|
||||
#include <class_board.h>
|
||||
|
||||
|
||||
// Helper classes to handle connection points (i.e. candidates) for tracks
|
||||
|
||||
/* class CONNECTED_POINT describes a coordinate having a track or pad parent.
|
||||
* when a pad is the parent, the coordinate is (obviously) the connection point
|
||||
* when a track is the parent, the coordinate is the staring point
|
||||
* or the ending point.
|
||||
* therefore when building a list of CONNECTED_POINT, a pad or via generates one item,
|
||||
* and a track generates 2 items.
|
||||
*/
|
||||
class CONNECTED_POINT
|
||||
{
|
||||
private:
|
||||
BOARD_CONNECTED_ITEM * m_item; // a link to the parent item (track, via or pad)
|
||||
wxPoint m_point; // the connection point (coordinate of this point)
|
||||
|
||||
public:
|
||||
// ctor to build a CONNECTED_POINT instance, when the parent is a track or via
|
||||
CONNECTED_POINT( TRACK * aTrack, const wxPoint & aPoint)
|
||||
{
|
||||
m_item = aTrack;
|
||||
m_point = aPoint;
|
||||
}
|
||||
|
||||
// ctor to build a CONNECTED_POINT instance, when the parent is a pad
|
||||
CONNECTED_POINT( D_PAD * aPad, const wxPoint & aPoint)
|
||||
{
|
||||
m_item = aPad;
|
||||
m_point = aPoint;
|
||||
}
|
||||
|
||||
/**
|
||||
* Function GetTrack
|
||||
* @return the parent track or via of this connected point,
|
||||
* or null if the parent is a pad
|
||||
*/
|
||||
TRACK * GetTrack() const
|
||||
{
|
||||
return m_item->Type() != PCB_PAD_T ? (TRACK*) m_item : NULL ;
|
||||
}
|
||||
|
||||
/**
|
||||
* Function GetPad
|
||||
* @return the parent pad of this connected point,
|
||||
* or null if the parent is a track or via
|
||||
*/
|
||||
D_PAD * GetPad() const
|
||||
{
|
||||
return m_item->Type() == PCB_PAD_T ? (D_PAD*) m_item : NULL;
|
||||
}
|
||||
|
||||
const wxPoint & GetPoint() const { return m_point; }
|
||||
};
|
||||
|
||||
// A helper class to handle connections calculations:
|
||||
class CONNECTIONS
|
||||
{
|
||||
private:
|
||||
std::vector <TRACK*> m_connected; // List of connected tracks/vias
|
||||
// to a given track or via
|
||||
std::vector <CONNECTED_POINT> m_candidates; // List of points to test
|
||||
// (end points of tracks or vias location )
|
||||
BOARD * m_brd; // the master board.
|
||||
const TRACK * m_firstTrack; // The first track used to build m_Candidates
|
||||
const TRACK * m_lastTrack; // The last track used to build m_Candidates
|
||||
std::vector<D_PAD*> m_sortedPads; // list of sorted pads by X (then Y) coordinate
|
||||
|
||||
public:
|
||||
CONNECTIONS( BOARD * aBrd );
|
||||
~CONNECTIONS() {};
|
||||
|
||||
/**
|
||||
* Function BuildPadsList
|
||||
* Fills m_sortedPads with all pads that be connected to tracks
|
||||
* pads are sorted by > then Y coordinates to allow fast binary search in list
|
||||
* @param aNetcode = net code to use to filter pads
|
||||
* if aNetcode < 0, all pads will be put in list (default)
|
||||
*/
|
||||
void BuildPadsList( int aNetcode = -1 );
|
||||
|
||||
/**
|
||||
* Function GetPadsList
|
||||
* @return the pads list used in connections calculations
|
||||
*/
|
||||
std::vector<D_PAD*>& GetPadsList() { return m_sortedPads; }
|
||||
|
||||
/**
|
||||
* Function Build_CurrNet_SubNets_Connections
|
||||
* should be called after a track change (delete or add a track):
|
||||
* Connections to pads and to tracks are recalculated
|
||||
* If a track is deleted, the other pointers to pads do not change.
|
||||
* When a new track is added in track list, its pointers to pads are already initialized
|
||||
* Builds the subnets inside a net (tracks from aFirstTrack to aFirstTrack).
|
||||
* subnets are clusters of pads and tracks that are connected together.
|
||||
* When all tracks are created relative to the net, there is only a cluster
|
||||
* when not tracks there are a cluster per pad
|
||||
* @param aFirstTrack = first track of the given net
|
||||
* @param aLastTrack = last track of the given net
|
||||
* @param aNetcode = the netcode of the given net
|
||||
*/
|
||||
void Build_CurrNet_SubNets_Connections( TRACK* aFirstTrack, TRACK* aLastTrack, int aNetcode );
|
||||
|
||||
/**
|
||||
* Function BuildTracksCandidatesList
|
||||
* Fills m_Candidates with all connecting points (track ends or via location)
|
||||
* with tracks from aBegin to aEnd.
|
||||
* @param aBegin = first track to store in list (should not be NULL)
|
||||
* @param aEnd = last track to store in list
|
||||
* if aEnd == NULL, uses all tracks from aBegin
|
||||
*/
|
||||
void BuildTracksCandidatesList( TRACK * aBegin, TRACK * aEnd = NULL);
|
||||
|
||||
/**
|
||||
* Function BuildPadsCandidatesList
|
||||
* Fills m_Candidates with all pads connecting points (pads position)
|
||||
* m_sortedPads must be built
|
||||
*/
|
||||
void BuildPadsCandidatesList();
|
||||
|
||||
/**
|
||||
* function SearchConnectedTracks
|
||||
* Fills m_Connected with tracks/vias connected to aTrack
|
||||
* @param aTrack = track or via to use as reference
|
||||
*/
|
||||
int SearchConnectedTracks( const TRACK * aTrack );
|
||||
|
||||
/**
|
||||
* Function GetConnectedTracks
|
||||
* Copy m_Connected that contains the list of tracks connected
|
||||
* calculated by SearchConnectedTracks
|
||||
* in aTrack->m_TracksConnected
|
||||
* @param aTrack = track or via to fill with connected tracks
|
||||
*/
|
||||
void GetConnectedTracks(TRACK * aTrack)
|
||||
{
|
||||
aTrack->m_TracksConnected = m_connected;
|
||||
}
|
||||
|
||||
/**
|
||||
* function SearchConnectionsPadsToIntersectingPads
|
||||
* Explores the list of pads and adds to m_PadsConnected member
|
||||
* of each pad pads connected to
|
||||
* Here, connections are due to intersecting pads, not tracks
|
||||
* m_sortedPads must be initialized
|
||||
*/
|
||||
void SearchConnectionsPadsToIntersectingPads();
|
||||
|
||||
/**
|
||||
* function SearchTracksConnectedToPads
|
||||
* Explores the list of pads.
|
||||
* Adds to m_PadsConnected member of each track the pad(s) connected to
|
||||
* Adds to m_TracksConnected member of each pad the track(s) connected to
|
||||
* D_PAD::m_TracksConnected is cleared before adding items
|
||||
* TRACK::m_PadsConnected is not cleared
|
||||
*/
|
||||
void SearchTracksConnectedToPads();
|
||||
|
||||
/**
|
||||
* function CollectItemsNearTo
|
||||
* Used by SearchTracksConnectedToPads
|
||||
* Fills aList with pads near to aPosition
|
||||
* near means aPosition to pad position <= aDistMax
|
||||
* @param aList = list to fill
|
||||
* @param aPosition = aPosition to use as reference
|
||||
* @param aDistMax = dist max from aPosition to a candidate to select it
|
||||
*/
|
||||
void CollectItemsNearTo( std::vector<CONNECTED_POINT*>& aList,
|
||||
const wxPoint& aPosition, int aDistMax );
|
||||
|
||||
/**
|
||||
* Function Propagate_SubNets
|
||||
* Test a list of tracks, to create or propagate a sub netcode to pads and
|
||||
* segments connected together.
|
||||
* The track list must be sorted by nets, and all segments
|
||||
* from m_firstTrack to m_lastTrack have the same net.
|
||||
* When 2 items are connected (a track to a pad, or a track to an other track),
|
||||
* they are grouped in a cluster.
|
||||
* For pads, this is the .m_physical_connexion member which is a cluster identifier
|
||||
* For tracks, this is the .m_Subnet member which is a cluster identifier
|
||||
* For a given net, if all tracks are created, there is only one cluster.
|
||||
* but if not all tracks are created, there are more than one cluster,
|
||||
* and some ratsnests will be left active.
|
||||
*/
|
||||
void Propagate_SubNets();
|
||||
|
||||
private:
|
||||
/**
|
||||
* function searchEntryPointInCandidatesList
|
||||
* Search an item in m_Connected connected to aPoint
|
||||
* note m_Connected containts usually more than one candidate
|
||||
* and searchEntryPointInCandidatesList returns an index to one of these candidates
|
||||
* Others are neightbor of the indexed item.
|
||||
* @param aPoint is the reference coordinates
|
||||
* @return the index of item found or -1 if no candidate
|
||||
*/
|
||||
int searchEntryPointInCandidatesList( const wxPoint & aPoint);
|
||||
|
||||
/**
|
||||
* Function Merge_SubNets
|
||||
* Change a subnet old value to a new value, for tracks and pads which are connected to
|
||||
* tracks from m_firstTrack to m_lastTrack and their connected pads.
|
||||
* and modify the subnet parameter (change the old value to the new value).
|
||||
* After that, 2 cluster (or subnets) are merged into only one.
|
||||
* Note: the resulting sub net value is the smallest between aOldSubNet and aNewSubNet
|
||||
* @return modification count
|
||||
* @param aOldSubNet = subnet value to modify
|
||||
* @param aNewSubNet = new subnet value for each item which have old_val as subnet value
|
||||
*/
|
||||
int Merge_SubNets( int aOldSubNet, int aNewSubNet );
|
||||
|
||||
/**
|
||||
* Function Merge_PadsSubNets
|
||||
* Change a subnet value to a new value, in m_sortedPads pad list
|
||||
* After that, 2 cluster (or subnets) are merged into only one.
|
||||
* Note: the resulting subnet value is the smallest between aOldSubNet et aNewSubNet
|
||||
* @return modification count
|
||||
* @param aOldSubNet = subnet value to modify
|
||||
* @param aNewSubNet = new subnet value for each item which have old_val as subnet value
|
||||
*/
|
||||
int Merge_PadsSubNets( int aOldSubNet, int aNewSubNet );
|
||||
};
|
||||
|
||||
#endif // ifndef CONNECT_H
|
|
@ -1,8 +1,29 @@
|
|||
/////////////////////////////////////////////////////////////////////////////
|
||||
// Name: dialog_cleaning_options.cpp
|
||||
// Author: jean-pierre Charras
|
||||
/////////////////////////////////////////////////////////////////////////////
|
||||
/**
|
||||
* @file dialog_cleaning_options.cpp
|
||||
*/
|
||||
|
||||
/*
|
||||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 1992-20112 KiCad Developers, see change_log.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
* as published by the Free Software Foundation; either version 2
|
||||
* of the License, or (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, you may find one here:
|
||||
* http://www.gnu.org/licenses/old-licenses/gpl-2.0.html
|
||||
* or you may search the http://www.gnu.org website for the version 2 license,
|
||||
* or you may write to the Free Software Foundation, Inc.,
|
||||
* 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA
|
||||
*/
|
||||
#include <wx/wx.h>
|
||||
|
||||
#include <dialog_cleaning_options.h>
|
||||
|
@ -14,7 +35,6 @@ DIALOG_CLEANING_OPTIONS::DIALOG_CLEANING_OPTIONS( wxWindow* parent ):
|
|||
m_cleanViasOpt->SetValue( cleanVias );
|
||||
m_mergeSegmOpt->SetValue( mergeSegments );
|
||||
m_deleteUnconnectedOpt->SetValue( deleteUnconnectedSegm );
|
||||
m_reconnectToPadsOpt->SetValue( connectToPads );
|
||||
|
||||
m_sdbSizerOK->SetDefault();
|
||||
GetSizer()->SetSizeHints(this);
|
||||
|
@ -25,5 +45,4 @@ DIALOG_CLEANING_OPTIONS::DIALOG_CLEANING_OPTIONS( wxWindow* parent ):
|
|||
bool DIALOG_CLEANING_OPTIONS::cleanVias = true;
|
||||
bool DIALOG_CLEANING_OPTIONS::mergeSegments = true;
|
||||
bool DIALOG_CLEANING_OPTIONS::deleteUnconnectedSegm = true;
|
||||
bool DIALOG_CLEANING_OPTIONS::connectToPads = false;
|
||||
|
||||
|
|
|
@ -14,7 +14,6 @@ public:
|
|||
static bool cleanVias;
|
||||
static bool mergeSegments;
|
||||
static bool deleteUnconnectedSegm;
|
||||
static bool connectToPads;
|
||||
|
||||
public:
|
||||
DIALOG_CLEANING_OPTIONS( wxWindow* parent );
|
||||
|
@ -44,7 +43,6 @@ private:
|
|||
cleanVias = m_cleanViasOpt->GetValue( );
|
||||
mergeSegments = m_mergeSegmOpt->GetValue( );
|
||||
deleteUnconnectedSegm = m_deleteUnconnectedOpt->GetValue( );
|
||||
connectToPads = m_reconnectToPadsOpt->GetValue( );
|
||||
}
|
||||
};
|
||||
|
||||
|
|
|
@ -1,5 +1,5 @@
|
|||
///////////////////////////////////////////////////////////////////////////
|
||||
// C++ code generated with wxFormBuilder (version Sep 8 2010)
|
||||
// C++ code generated with wxFormBuilder (version Apr 10 2012)
|
||||
// http://www.wxformbuilder.org/
|
||||
//
|
||||
// PLEASE DO "NOT" EDIT THIS FILE!
|
||||
|
@ -24,7 +24,7 @@ DIALOG_CLEANING_OPTIONS_BASE::DIALOG_CLEANING_OPTIONS_BASE( wxWindow* parent, wx
|
|||
|
||||
bSizerUpper->Add( m_cleanViasOpt, 0, wxALL, 5 );
|
||||
|
||||
m_mergeSegmOpt = new wxCheckBox( this, wxID_ANY, _("Merge segments"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_mergeSegmOpt = new wxCheckBox( this, wxID_ANY, _("Merge colinear segments"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_mergeSegmOpt->SetToolTip( _("merge aligned track segments, and remove null segments") );
|
||||
|
||||
bSizerUpper->Add( m_mergeSegmOpt, 0, wxALL, 5 );
|
||||
|
@ -34,10 +34,6 @@ DIALOG_CLEANING_OPTIONS_BASE::DIALOG_CLEANING_OPTIONS_BASE( wxWindow* parent, wx
|
|||
|
||||
bSizerUpper->Add( m_deleteUnconnectedOpt, 0, wxALL, 5 );
|
||||
|
||||
m_reconnectToPadsOpt = new wxCheckBox( this, wxID_ANY, _("Connect to pads"), wxDefaultPosition, wxDefaultSize, 0 );
|
||||
m_reconnectToPadsOpt->SetToolTip( _("Extend dangling tracks which partially cover a pad or via, all the way to pad or via center") );
|
||||
|
||||
bSizerUpper->Add( m_reconnectToPadsOpt, 0, wxALL, 5 );
|
||||
|
||||
bSizerMain->Add( bSizerUpper, 1, wxEXPAND|wxALL, 5 );
|
||||
|
||||
|
@ -50,8 +46,10 @@ DIALOG_CLEANING_OPTIONS_BASE::DIALOG_CLEANING_OPTIONS_BASE( wxWindow* parent, wx
|
|||
m_sdbSizerCancel = new wxButton( this, wxID_CANCEL );
|
||||
m_sdbSizer->AddButton( m_sdbSizerCancel );
|
||||
m_sdbSizer->Realize();
|
||||
|
||||
bSizerMain->Add( m_sdbSizer, 0, wxALIGN_RIGHT|wxALL, 5 );
|
||||
|
||||
|
||||
this->SetSizer( bSizerMain );
|
||||
this->Layout();
|
||||
|
||||
|
|
|
@ -1,12 +1,14 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
|
||||
<wxFormBuilder_Project>
|
||||
<FileVersion major="1" minor="10" />
|
||||
<FileVersion major="1" minor="11" />
|
||||
<object class="Project" expanded="1">
|
||||
<property name="class_decoration"></property>
|
||||
<property name="code_generation">C++</property>
|
||||
<property name="disconnect_events">1</property>
|
||||
<property name="disconnect_mode">source_name</property>
|
||||
<property name="disconnect_php_events">0</property>
|
||||
<property name="disconnect_python_events">0</property>
|
||||
<property name="embedded_files_path">res</property>
|
||||
<property name="encoding">UTF-8</property>
|
||||
<property name="event_generation">connect</property>
|
||||
<property name="file">dialog_cleaning_options_base</property>
|
||||
|
@ -18,10 +20,13 @@
|
|||
<property name="path">.</property>
|
||||
<property name="precompiled_header"></property>
|
||||
<property name="relative_path">1</property>
|
||||
<property name="skip_php_events">1</property>
|
||||
<property name="skip_python_events">1</property>
|
||||
<property name="use_enum">0</property>
|
||||
<property name="use_microsoft_bom">0</property>
|
||||
<object class="Dialog" expanded="1">
|
||||
<property name="aui_managed">0</property>
|
||||
<property name="aui_manager_style">wxAUI_MGR_DEFAULT</property>
|
||||
<property name="bg"></property>
|
||||
<property name="center">wxBOTH</property>
|
||||
<property name="context_help"></property>
|
||||
|
@ -37,20 +42,22 @@
|
|||
<property name="minimum_size"></property>
|
||||
<property name="name">DIALOG_CLEANING_OPTIONS_BASE</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size">243,181</property>
|
||||
<property name="size">243,146</property>
|
||||
<property name="style">wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="title">Cleaning options</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnActivate"></event>
|
||||
<event name="OnActivateApp"></event>
|
||||
<event name="OnAuiFindManager"></event>
|
||||
<event name="OnAuiPaneButton"></event>
|
||||
<event name="OnAuiPaneClose"></event>
|
||||
<event name="OnAuiPaneMaximize"></event>
|
||||
<event name="OnAuiPaneRestore"></event>
|
||||
<event name="OnAuiRender"></event>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnClose">OnCloseWindow</event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
|
@ -98,24 +105,55 @@
|
|||
<property name="flag">wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxCheckBox" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="checked">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Delete redundant vias</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_cleanViasOpt</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">remove vias on pads with a through hole</property>
|
||||
<property name="validator_data_type">bool</property>
|
||||
<property name="validator_style">wxFILTER_NUMERIC</property>
|
||||
|
@ -155,24 +193,55 @@
|
|||
<property name="flag">wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxCheckBox" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="checked">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Merge segments</property>
|
||||
<property name="label">Merge colinear segments</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_mergeSegmOpt</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">merge aligned track segments, and remove null segments</property>
|
||||
<property name="validator_data_type">bool</property>
|
||||
<property name="validator_style">wxFILTER_NUMERIC</property>
|
||||
|
@ -212,24 +281,55 @@
|
|||
<property name="flag">wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxCheckBox" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="checked">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Delete unconnected tracks</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_deleteUnconnectedOpt</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip">delete track segment having a dangling end</property>
|
||||
<property name="validator_data_type">bool</property>
|
||||
<property name="validator_style">wxFILTER_NUMERIC</property>
|
||||
|
@ -264,63 +364,6 @@
|
|||
<event name="OnUpdateUI"></event>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
<property name="border">5</property>
|
||||
<property name="flag">wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxCheckBox" expanded="1">
|
||||
<property name="bg"></property>
|
||||
<property name="checked">0</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="font"></property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="label">Connect to pads</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="name">m_reconnectToPadsOpt</property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pos"></property>
|
||||
<property name="size"></property>
|
||||
<property name="style"></property>
|
||||
<property name="subclass"></property>
|
||||
<property name="tooltip">Extend dangling tracks which partially cover a pad or via, all the way to pad or via center</property>
|
||||
<property name="validator_data_type">bool</property>
|
||||
<property name="validator_style">wxFILTER_NUMERIC</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable">connectToPads</property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
<event name="OnChar"></event>
|
||||
<event name="OnCheckBox"></event>
|
||||
<event name="OnEnterWindow"></event>
|
||||
<event name="OnEraseBackground"></event>
|
||||
<event name="OnKeyDown"></event>
|
||||
<event name="OnKeyUp"></event>
|
||||
<event name="OnKillFocus"></event>
|
||||
<event name="OnLeaveWindow"></event>
|
||||
<event name="OnLeftDClick"></event>
|
||||
<event name="OnLeftDown"></event>
|
||||
<event name="OnLeftUp"></event>
|
||||
<event name="OnMiddleDClick"></event>
|
||||
<event name="OnMiddleDown"></event>
|
||||
<event name="OnMiddleUp"></event>
|
||||
<event name="OnMotion"></event>
|
||||
<event name="OnMouseEvents"></event>
|
||||
<event name="OnMouseWheel"></event>
|
||||
<event name="OnPaint"></event>
|
||||
<event name="OnRightDClick"></event>
|
||||
<event name="OnRightDown"></event>
|
||||
<event name="OnRightUp"></event>
|
||||
<event name="OnSetFocus"></event>
|
||||
<event name="OnSize"></event>
|
||||
<event name="OnUpdateUI"></event>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
</object>
|
||||
<object class="sizeritem" expanded="1">
|
||||
|
@ -328,27 +371,54 @@
|
|||
<property name="flag">wxEXPAND | wxALL</property>
|
||||
<property name="proportion">0</property>
|
||||
<object class="wxStaticLine" expanded="1">
|
||||
<property name="BottomDockable">1</property>
|
||||
<property name="LeftDockable">1</property>
|
||||
<property name="RightDockable">1</property>
|
||||
<property name="TopDockable">1</property>
|
||||
<property name="aui_layer"></property>
|
||||
<property name="aui_name"></property>
|
||||
<property name="aui_position"></property>
|
||||
<property name="aui_row"></property>
|
||||
<property name="best_size"></property>
|
||||
<property name="bg"></property>
|
||||
<property name="caption"></property>
|
||||
<property name="caption_visible">1</property>
|
||||
<property name="center_pane">0</property>
|
||||
<property name="close_button">1</property>
|
||||
<property name="context_help"></property>
|
||||
<property name="context_menu">1</property>
|
||||
<property name="default_pane">0</property>
|
||||
<property name="dock">Dock</property>
|
||||
<property name="dock_fixed">0</property>
|
||||
<property name="docking">Left</property>
|
||||
<property name="enabled">1</property>
|
||||
<property name="fg"></property>
|
||||
<property name="floatable">1</property>
|
||||
<property name="font"></property>
|
||||
<property name="gripper">0</property>
|
||||
<property name="hidden">0</property>
|
||||
<property name="id">wxID_ANY</property>
|
||||
<property name="max_size"></property>
|
||||
<property name="maximize_button">0</property>
|
||||
<property name="maximum_size"></property>
|
||||
<property name="min_size"></property>
|
||||
<property name="minimize_button">0</property>
|
||||
<property name="minimum_size"></property>
|
||||
<property name="moveable">1</property>
|
||||
<property name="name">m_staticline</property>
|
||||
<property name="pane_border">1</property>
|
||||
<property name="pane_position"></property>
|
||||
<property name="pane_size"></property>
|
||||
<property name="permission">protected</property>
|
||||
<property name="pin_button">1</property>
|
||||
<property name="pos"></property>
|
||||
<property name="resize">Resizable</property>
|
||||
<property name="show">1</property>
|
||||
<property name="size"></property>
|
||||
<property name="style">wxLI_HORIZONTAL</property>
|
||||
<property name="subclass"></property>
|
||||
<property name="toolbar_pane">0</property>
|
||||
<property name="tooltip"></property>
|
||||
<property name="validator_data_type"></property>
|
||||
<property name="validator_style">wxFILTER_NONE</property>
|
||||
<property name="validator_type">wxDefaultValidator</property>
|
||||
<property name="validator_variable"></property>
|
||||
<property name="window_extra_style"></property>
|
||||
<property name="window_name"></property>
|
||||
<property name="window_style"></property>
|
||||
|
|
|
@ -1,15 +1,16 @@
|
|||
///////////////////////////////////////////////////////////////////////////
|
||||
// C++ code generated with wxFormBuilder (version Sep 8 2010)
|
||||
// C++ code generated with wxFormBuilder (version Apr 10 2012)
|
||||
// http://www.wxformbuilder.org/
|
||||
//
|
||||
// PLEASE DO "NOT" EDIT THIS FILE!
|
||||
///////////////////////////////////////////////////////////////////////////
|
||||
|
||||
#ifndef __dialog_cleaning_options_base__
|
||||
#define __dialog_cleaning_options_base__
|
||||
#ifndef __DIALOG_CLEANING_OPTIONS_BASE_H__
|
||||
#define __DIALOG_CLEANING_OPTIONS_BASE_H__
|
||||
|
||||
#include <wx/artprov.h>
|
||||
#include <wx/xrc/xmlres.h>
|
||||
#include <wx/intl.h>
|
||||
|
||||
#include <wx/string.h>
|
||||
#include <wx/checkbox.h>
|
||||
#include <wx/gdicmn.h>
|
||||
|
@ -35,7 +36,6 @@ class DIALOG_CLEANING_OPTIONS_BASE : public wxDialog
|
|||
wxCheckBox* m_cleanViasOpt;
|
||||
wxCheckBox* m_mergeSegmOpt;
|
||||
wxCheckBox* m_deleteUnconnectedOpt;
|
||||
wxCheckBox* m_reconnectToPadsOpt;
|
||||
wxStaticLine* m_staticline;
|
||||
wxStdDialogButtonSizer* m_sdbSizer;
|
||||
wxButton* m_sdbSizerOK;
|
||||
|
@ -51,11 +51,10 @@ class DIALOG_CLEANING_OPTIONS_BASE : public wxDialog
|
|||
bool cleanVias;
|
||||
bool mergeSegments;
|
||||
bool deleteUnconnectedSegm;
|
||||
bool connectToPads;
|
||||
|
||||
DIALOG_CLEANING_OPTIONS_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Cleaning options"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 243,181 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
|
||||
DIALOG_CLEANING_OPTIONS_BASE( wxWindow* parent, wxWindowID id = wxID_ANY, const wxString& title = _("Cleaning options"), const wxPoint& pos = wxDefaultPosition, const wxSize& size = wxSize( 243,146 ), long style = wxDEFAULT_DIALOG_STYLE|wxRESIZE_BORDER );
|
||||
~DIALOG_CLEANING_OPTIONS_BASE();
|
||||
|
||||
};
|
||||
|
||||
#endif //__dialog_cleaning_options_base__
|
||||
#endif //__DIALOG_CLEANING_OPTIONS_BASE_H__
|
||||
|
|
Loading…
Reference in New Issue