39 changed files with 1669 additions and 2440 deletions
-
17change_log.txt
-
10common/eda_doc.cpp
-
9common/edaappl.cpp
-
1common/gestfich.cpp
-
6common/string.cpp
-
1150eeschema/eelibs1.cpp
-
974eeschema/eelibs2.cpp
-
26eeschema/erc.cpp
-
2eeschema/netlist_control.cpp
-
2eeschema/plothpgl.cpp
-
2eeschema/plotps.cpp
-
14eeschema/tool_lib.cpp
-
139eeschema/xx.cpp
-
95eeschema/xx.h
-
1gerbview/export_to_pcbnew.cpp
-
5gerbview/readgerb.cpp
-
11gerbview/rs274x.cpp
-
2include/build_version.h
-
3include/common.h
-
2include/id.h
-
3include/wxstruct.h
-
255pcbnew/cleaningoptions_dialog.cpp
-
115pcbnew/cleaningoptions_dialog.h
-
18pcbnew/controle.cpp
-
703pcbnew/dialog_clean_pcb.pjd
-
4pcbnew/edit.cpp
-
15pcbnew/editrack.cpp
-
23pcbnew/locate.cpp
-
2pcbnew/makefile.include
-
11pcbnew/netlist.cpp
-
8pcbnew/pcbframe.cpp
-
13pcbnew/plotgerb.cpp
-
4pcbnew/plothpgl.cpp
-
3pcbnew/plotps.cpp
-
1pcbnew/sel_layer.cpp
-
1pcbnew/set_color.cpp
-
130pcbnew/tool_pcb.cpp
-
220pcbnew/win_eda_cleaningoptionsframe.cpp
-
109pcbnew/win_eda_cleaningoptionsframe.h
1150
eeschema/eelibs1.cpp
File diff suppressed because it is too large
View File
File diff suppressed because it is too large
View File
@ -1,974 +0,0 @@ |
|||
/********************************************************/ |
|||
/* Module to handle libraries (second part - drawing ). */ |
|||
/********************************************************/ |
|||
|
|||
#include "fctsys.h"
|
|||
#include "gr_basic.h"
|
|||
|
|||
#include "common.h"
|
|||
#include "program.h"
|
|||
#include "libcmp.h"
|
|||
#include "component_class.h"
|
|||
#include "general.h"
|
|||
#include "trigo.h"
|
|||
#include "protos.h"
|
|||
|
|||
#define UNVISIBLE_COLOR DARKGRAY
|
|||
|
|||
//#define DRAW_ARC_WITH_ANGLE // pour trace arc avec routine utilsant les angles
|
|||
|
|||
|
|||
/* Fonctions locales */ |
|||
|
|||
/* Description du composant <DUMMY> utilisé lorsque des composants non trouvés
|
|||
en librarie doivent etre dessinés */ |
|||
/*
|
|||
ce composant est un rectangle de 400 mils de coté avec le texte ?? au centre |
|||
DEF DUMMY U 0 40 Y Y 1 0 N |
|||
F0 "U" 0 -350 60 H V |
|||
F1 "DUMMY" 0 350 60 H V |
|||
DRAW |
|||
T 0 0 0 150 0 0 0 ?? |
|||
S -200 200 200 -200 0 1 0 |
|||
ENDDRAW |
|||
ENDDEF |
|||
*/ |
|||
|
|||
static int s_ItemSelectColor = BROWN; |
|||
|
|||
static EDA_LibComponentStruct * DummyCmp; |
|||
static int * Buf_Poly_Drawings, Buf_Poly_Size; // Used fo polyline drawings
|
|||
static void DrawLibPartAux(WinEDA_DrawPanel * panel, wxDC * DC, |
|||
EDA_SchComponentStruct *Component, |
|||
EDA_LibComponentStruct *Entry, |
|||
const wxPoint & Pos, |
|||
int TransMat[2][2], |
|||
int Multi, int convert, |
|||
int DrawMode, int Color = -1, bool DrawPinText = TRUE); |
|||
|
|||
/******************************/ |
|||
static void CreateDummyCmp(void) |
|||
/******************************/ |
|||
{ |
|||
DummyCmp = new EDA_LibComponentStruct( NULL); |
|||
|
|||
LibDrawSquare * Square = new LibDrawSquare(); |
|||
Square->m_Start = wxPoint(- 200,200); |
|||
Square->m_End = wxPoint(200, - 200); |
|||
Square->m_Width = 4; |
|||
|
|||
LibDrawText * Text = new LibDrawText(); |
|||
Text->m_Size.x = Text->m_Size.y = 150; |
|||
Text->m_Text = wxT("??"); |
|||
|
|||
DummyCmp->m_Drawings = Square; |
|||
Square->Pnext = Text; |
|||
} |
|||
|
|||
|
|||
/*************************************************************/ |
|||
void DrawLibEntry(WinEDA_DrawPanel * panel,wxDC * DC, |
|||
EDA_LibComponentStruct *LibEntry, |
|||
int posX, int posY, |
|||
int Multi, int convert, |
|||
int DrawMode, int Color) |
|||
/**************************************************************/ |
|||
/* Routine de dessin d'un composant d'une librairie
|
|||
LibEntry = pointeur sur la description en librairie |
|||
posX, posY = position du composant |
|||
DrawMode = GrOR .. |
|||
Color = 0 : dessin en vraies couleurs, sinon couleur = Color |
|||
|
|||
Une croix symbolise le point d'accrochage (ref position) du composant |
|||
|
|||
Le composant est toujours trace avec orientation 0 |
|||
*/ |
|||
{ |
|||
int color; |
|||
int TransMat[2][2]; |
|||
wxString Prefix; |
|||
LibDrawField * Field; |
|||
wxPoint text_pos; |
|||
|
|||
/* Orientation normale */ |
|||
TransMat[0][0] = 1; TransMat[1][1] = -1; |
|||
TransMat[1][0] = TransMat[0][1] = 0; |
|||
|
|||
DrawLibPartAux(panel, DC, NULL, LibEntry, wxPoint(posX, posY), |
|||
TransMat, Multi, |
|||
convert, DrawMode, Color); |
|||
|
|||
/* Trace des 2 champs ref et value (Attention aux coord: la matrice
|
|||
de transformation change de signe les coord Y */ |
|||
|
|||
GRSetDrawMode(DC, DrawMode); |
|||
|
|||
if( LibEntry->m_Prefix.m_Attributs & TEXT_NO_VISIBLE ) |
|||
{ |
|||
if( Color >= 0 ) color = Color; |
|||
else color = UNVISIBLE_COLOR; |
|||
} |
|||
|
|||
else { |
|||
if( Color >= 0) color = Color; |
|||
else color = ReturnLayerColor(LAYER_REFERENCEPART); |
|||
} |
|||
|
|||
if (LibEntry->m_UnitCount > 1) |
|||
Prefix.Printf( wxT("%s?%c"),LibEntry->m_Prefix.m_Text.GetData(),Multi + 'A' - 1); |
|||
else Prefix = LibEntry->m_Prefix.m_Text + wxT("?"); |
|||
|
|||
text_pos.x = LibEntry->m_Prefix.m_Pos.x + posX; |
|||
text_pos.y = posY - LibEntry->m_Prefix.m_Pos.y; |
|||
DrawGraphicText(panel, DC, text_pos, |
|||
color,LibEntry->m_Prefix.m_Text.GetData(), |
|||
LibEntry->m_Prefix.m_Orient ? TEXT_ORIENT_VERT : TEXT_ORIENT_HORIZ, |
|||
LibEntry->m_Prefix.m_Size, |
|||
LibEntry->m_Prefix.m_HJustify, LibEntry->m_Prefix.m_VJustify); |
|||
|
|||
if( LibEntry->m_Name.m_Attributs & TEXT_NO_VISIBLE ) |
|||
{ |
|||
if( Color >= 0) color = Color; |
|||
else color = UNVISIBLE_COLOR; |
|||
} |
|||
|
|||
else { |
|||
if( Color >= 0 ) color = Color; |
|||
else color = ReturnLayerColor(LAYER_VALUEPART); |
|||
} |
|||
|
|||
text_pos.x = LibEntry->m_Name.m_Pos.x + posX; |
|||
text_pos.y = posY - LibEntry->m_Name.m_Pos.y; |
|||
DrawGraphicText(panel, DC, text_pos, |
|||
color, LibEntry->m_Name.m_Text.GetData(), |
|||
LibEntry->m_Name.m_Orient ? TEXT_ORIENT_VERT : TEXT_ORIENT_HORIZ, |
|||
LibEntry->m_Name.m_Size, |
|||
LibEntry->m_Name.m_HJustify, LibEntry->m_Name.m_VJustify); |
|||
|
|||
for( Field = LibEntry->Fields; Field != NULL; Field = (LibDrawField *)Field->Pnext ) |
|||
{ |
|||
if( Field->m_Text.IsEmpty() ) return; |
|||
if( Field->m_Attributs & TEXT_NO_VISIBLE ) |
|||
{ |
|||
if( Color >= 0) color = Color; |
|||
else color = UNVISIBLE_COLOR; |
|||
} |
|||
else { |
|||
if( Color >= 0) color = Color; |
|||
else color = ReturnLayerColor(LAYER_FIELDS); |
|||
} |
|||
|
|||
text_pos.x = Field->m_Pos.x + posX; |
|||
text_pos.y = posY - Field->m_Pos.y; |
|||
DrawGraphicText(panel, DC, text_pos, |
|||
color, Field->m_Text, |
|||
Field->m_Orient ? TEXT_ORIENT_VERT : TEXT_ORIENT_HORIZ, |
|||
Field->m_Size, |
|||
Field->m_HJustify, Field->m_VJustify); |
|||
} |
|||
|
|||
// Tracé de l'ancre
|
|||
int len = 3 * panel->GetZoom(); |
|||
GRLine(&panel->m_ClipBox, DC, posX, posY - len, posX, posY + len, color); |
|||
GRLine(&panel->m_ClipBox, DC, posX - len, posY, posX + len, posY, color); |
|||
|
|||
} |
|||
|
|||
/*****************************************************************************
|
|||
* Routine to draw the given part at given position, transformed/mirror as * |
|||
* specified, and in the given drawing mode. Only this one is visible... * |
|||
*****************************************************************************/ |
|||
void EDA_SchComponentStruct::Draw(WinEDA_DrawPanel * panel,wxDC * DC, |
|||
const wxPoint & offset, int DrawMode, int Color) |
|||
{ |
|||
EDA_LibComponentStruct *Entry; |
|||
int ii; |
|||
bool dummy = FALSE; |
|||
|
|||
if( (Entry = FindLibPart(m_ChipName.GetData(),wxEmptyString,FIND_ROOT)) == NULL) |
|||
{ /* composant non trouvé, on affiche un composant "dummy" */ |
|||
dummy = TRUE; |
|||
if( DummyCmp == NULL ) CreateDummyCmp(); |
|||
Entry = DummyCmp; |
|||
} |
|||
|
|||
DrawLibPartAux(panel, DC, this, Entry, m_Pos + offset, |
|||
m_Transform, |
|||
dummy ? 0 : m_Multi, |
|||
dummy ? 0 : m_Convert, |
|||
DrawMode); |
|||
|
|||
/* Trace des champs, avec placement et orientation selon orient. du
|
|||
composant |
|||
*/ |
|||
|
|||
if( ((m_Field[REFERENCE].m_Attributs & TEXT_NO_VISIBLE) == 0) |
|||
&& ! (m_Field[REFERENCE].m_Flags & IS_MOVED) ) |
|||
{ |
|||
if ( Entry->m_UnitCount > 1 ) |
|||
DrawTextField(panel, DC, &m_Field[REFERENCE],1,DrawMode); |
|||
else |
|||
DrawTextField(panel, DC, &m_Field[REFERENCE],0,DrawMode); |
|||
} |
|||
|
|||
for( ii = VALUE; ii < NUMBER_OF_FIELDS; ii++ ) |
|||
{ |
|||
if (m_Field[ii].m_Flags & IS_MOVED) continue; |
|||
DrawTextField(panel, DC, &m_Field[ii],0,DrawMode); |
|||
} |
|||
} |
|||
|
|||
/***********************************************************/ |
|||
void DrawTextField(WinEDA_DrawPanel * panel,wxDC * DC, |
|||
PartTextStruct * Field, int IsMulti, int DrawMode) |
|||
/***********************************************************/ |
|||
/* Routine de trace des textes type Field du composant.
|
|||
entree: |
|||
IsMulti: flag Non Null si il y a plusieurs parts par boitier. |
|||
n'est utile que pour le champ reference pour ajouter a celui ci |
|||
l'identification de la part ( A, B ... ) |
|||
DrawMode: mode de trace |
|||
*/ |
|||
{ |
|||
int orient, color; |
|||
wxPoint pos; /* Position des textes */ |
|||
EDA_SchComponentStruct *DrawLibItem = (EDA_SchComponentStruct *) Field->m_Parent; |
|||
int hjustify, vjustify; |
|||
|
|||
if( Field->m_Attributs & TEXT_NO_VISIBLE ) return; |
|||
if( Field->IsVoid() ) return; |
|||
|
|||
GRSetDrawMode(DC, DrawMode); |
|||
|
|||
/* Calcul de la position des textes, selon orientation du composant */ |
|||
orient = Field->m_Orient; |
|||
hjustify = Field->m_HJustify; vjustify = Field->m_VJustify; |
|||
pos.x = Field->m_Pos.x - DrawLibItem->m_Pos.x; |
|||
pos.y = Field->m_Pos.y - DrawLibItem->m_Pos.y; |
|||
|
|||
pos = DrawLibItem->GetScreenCoord(pos); |
|||
pos.x += DrawLibItem->m_Pos.x; |
|||
pos.y += DrawLibItem->m_Pos.y; |
|||
|
|||
/* Y a t-il rotation (pour l'orientation, la justification)*/ |
|||
if(DrawLibItem->m_Transform[0][1]) // Rotation du composant de 90deg
|
|||
{ |
|||
if ( orient == TEXT_ORIENT_HORIZ) orient = TEXT_ORIENT_VERT; |
|||
else orient = TEXT_ORIENT_HORIZ; |
|||
/* Y a t-il rotation, miroir (pour les justifications)*/ |
|||
EXCHG(hjustify, vjustify); |
|||
if (DrawLibItem->m_Transform[1][0] < 0 ) vjustify = - vjustify; |
|||
if (DrawLibItem->m_Transform[1][0] > 0 ) hjustify = - hjustify; |
|||
} |
|||
else |
|||
{ /* Texte horizontal: Y a t-il miroir (pour les justifications)*/ |
|||
if (DrawLibItem->m_Transform[0][0] < 0 ) |
|||
hjustify = - hjustify; |
|||
if (DrawLibItem->m_Transform[1][1] > 0 ) |
|||
vjustify = - vjustify; |
|||
} |
|||
|
|||
if( Field->m_FieldId == REFERENCE ) |
|||
color = ReturnLayerColor(LAYER_REFERENCEPART); |
|||
else if( Field->m_FieldId == VALUE ) |
|||
color = ReturnLayerColor(LAYER_VALUEPART); |
|||
else color = ReturnLayerColor(LAYER_FIELDS); |
|||
if( !IsMulti || (Field->m_FieldId != REFERENCE) ) |
|||
{ |
|||
DrawGraphicText(panel, DC, pos, color, Field->m_Text.GetData(), |
|||
orient ? TEXT_ORIENT_VERT : TEXT_ORIENT_HORIZ, |
|||
Field->m_Size, |
|||
hjustify, vjustify); |
|||
} |
|||
|
|||
else /* Le champ est la reference, et il y a plusieurs parts par boitier */ |
|||
{/* On ajoute alors A ou B ... a la reference */ |
|||
wxString fulltext = Field->m_Text; |
|||
fulltext.Append('A' - 1 + DrawLibItem->m_Multi); |
|||
DrawGraphicText(panel, DC, pos, color, fulltext.GetData(), |
|||
orient ? TEXT_ORIENT_VERT : TEXT_ORIENT_HORIZ, |
|||
Field->m_Size, |
|||
hjustify, vjustify); |
|||
} |
|||
} |
|||
|
|||
|
|||
/********************************************************************************/ |
|||
EDA_LibComponentStruct *FindLibPart(const wxChar *Name, const wxString & LibName, int Alias) |
|||
/********************************************************************************/ |
|||
/*
|
|||
Routine to find a part in one of the libraries given its name. |
|||
Name = Name of part. |
|||
LibName = Name of Lib; if "": seach in all libs |
|||
Alias = Flag: si flag != 0, retourne un pointeur sur une part ou un alias |
|||
si flag = 0, retourne un pointeur sur une part meme si le nom |
|||
correspond a un alias |
|||
Alias = FIND_ROOT, ou Alias = FIND_ALIAS |
|||
*/ |
|||
{ |
|||
EDA_LibComponentStruct *Entry; |
|||
static EDA_LibComponentStruct DummyEntry(wxEmptyString); /* Used only to call PQFind. */ |
|||
LibraryStruct *Lib = g_LibraryList; |
|||
|
|||
DummyEntry.m_Drawings = NULL; /* Used only to call PQFind. */ |
|||
DummyEntry.m_Name.m_Text = Name; |
|||
|
|||
PQCompFunc((PQCompFuncType) LibraryEntryCompare); |
|||
|
|||
Entry = NULL; FindLibName.Empty(); |
|||
while (Lib) |
|||
{ |
|||
if( ! LibName.IsEmpty() ) |
|||
{ |
|||
if( Lib->m_Name != LibName ) |
|||
{ |
|||
Lib = Lib->m_Pnext; continue ; |
|||
} |
|||
} |
|||
if( Lib == NULL ) break; |
|||
Entry = (EDA_LibComponentStruct*)PQFind(Lib->m_Entries, &DummyEntry); |
|||
if( Entry != NULL) |
|||
{ |
|||
FindLibName = Lib->m_Name; |
|||
break; |
|||
} |
|||
Lib = Lib->m_Pnext; |
|||
} |
|||
|
|||
/* Si le nom est un alias, recherche du vrai composant */ |
|||
if( Entry ) |
|||
{ |
|||
if( (Entry->Type != ROOT ) && (Alias == FIND_ROOT) ) |
|||
Entry = FindLibPart( ((EDA_LibCmpAliasStruct*)Entry)->m_RootName.GetData() , |
|||
Lib->m_Name, FIND_ROOT); |
|||
} |
|||
|
|||
return (Entry); |
|||
} |
|||
|
|||
/*****************************************************************************
|
|||
* Routine to draw the given part at given position, transformed/mirror as |
|||
* specified, and in the given drawing mode. |
|||
* if Color < 0: Draw in normal color |
|||
* else draw in color = Color |
|||
*****************************************************************************/ |
|||
/* DrawMode = GrXOR, GrOR ..*/ |
|||
void DrawLibPartAux(WinEDA_DrawPanel * panel,wxDC * DC, |
|||
EDA_SchComponentStruct *Component, |
|||
EDA_LibComponentStruct *Entry, |
|||
const wxPoint & Pos, |
|||
int TransMat[2][2], |
|||
int Multi, int convert, int DrawMode, |
|||
int Color, bool DrawPinText) |
|||
{ |
|||
int i, x1, y1, x2, y2, t1, t2, orient; |
|||
LibEDA_BaseStruct *DEntry = NULL; |
|||
int CharColor; |
|||
int fill_option; |
|||
int SetHightColor; |
|||
//#define GETCOLOR(l) Color < 0 ? (ReturnLayerColor(l)| SetHightColor) : Color;
|
|||
#define GETCOLOR(l) Color < 0 ? SetHightColor ? s_ItemSelectColor : (ReturnLayerColor(l)| SetHightColor) : Color;
|
|||
|
|||
if (Entry->m_Drawings == NULL) return; |
|||
GRSetDrawMode(DC, DrawMode); |
|||
|
|||
for( DEntry = Entry->m_Drawings; DEntry != NULL;DEntry = DEntry->Next()) |
|||
{ |
|||
/* Elimination des elements non relatifs a l'unite */ |
|||
if( Multi && DEntry->m_Unit && (DEntry->m_Unit != Multi) ) continue; |
|||
if( convert && DEntry->m_Convert && (DEntry->m_Convert != convert) ) |
|||
continue; |
|||
|
|||
if ( DEntry->m_Flags & IS_MOVED ) continue; // Element en deplacement non trace
|
|||
SetHightColor = (DEntry->m_Selected & IS_SELECTED) ? HIGHT_LIGHT_FLAG : 0; |
|||
switch (DEntry->m_StructType) |
|||
{ |
|||
case COMPONENT_ARC_DRAW_TYPE: |
|||
{ |
|||
int xc,yc, x2, y2; |
|||
LibDrawArc * Arc = (LibDrawArc *) DEntry; |
|||
CharColor = GETCOLOR(LAYER_DEVICE); |
|||
xc = Pos.x + TransMat[0][0] * Arc->m_Pos.x + |
|||
TransMat[0][1] * Arc->m_Pos.y; |
|||
yc = Pos.y + TransMat[1][0] * Arc->m_Pos.x + |
|||
TransMat[1][1] * Arc->m_Pos.y; |
|||
x2 = Pos.x + TransMat[0][0] * Arc->m_Start.x + |
|||
TransMat[0][1] * Arc->m_Start.y;; |
|||
y2 = Pos.y + TransMat[1][0] * Arc->m_Start.x + |
|||
TransMat[1][1] * Arc->m_Start.y; |
|||
x1 = Pos.x + TransMat[0][0] * Arc->m_End.x + |
|||
TransMat[0][1] * Arc->m_End.y;; |
|||
y1 = Pos.y + TransMat[1][0] * Arc->m_End.x + |
|||
TransMat[1][1] * Arc->m_End.y; |
|||
t1 = Arc->t1; t2 = Arc->t2; |
|||
bool swap = MapAngles(&t1, &t2, TransMat); |
|||
if ( swap ) { EXCHG(x1,x2); EXCHG(y1, y2) } |
|||
fill_option = Arc->m_Fill & (~g_PrintFillMask); |
|||
if ( Color < 0 ) // Normal Color Layer
|
|||
{ |
|||
if ( (fill_option == FILLED_WITH_BG_BODYCOLOR) && ! g_IsPrinting ) |
|||
GRFilledArc(&panel->m_ClipBox, DC, xc, yc, t1, t2, |
|||
Arc->m_Rayon, CharColor, |
|||
ReturnLayerColor(LAYER_DEVICE_BACKGROUND)); |
|||
else if ( fill_option == FILLED_SHAPE) |
|||
GRFilledArc(&panel->m_ClipBox, DC, xc, yc, t1, t2, |
|||
Arc->m_Rayon, CharColor, CharColor); |
|||
#ifdef DRAW_ARC_WITH_ANGLE
|
|||
else GRArc(&panel->m_ClipBox, DC, xc, yc, t1, t2, |
|||
Arc->m_Rayon, CharColor); |
|||
#else
|
|||
else GRArc1(&panel->m_ClipBox, DC, x1, y1, x2, y2, |
|||
xc, yc , CharColor); |
|||
#endif
|
|||
} |
|||
#ifdef DRAW_ARC_WITH_ANGLE
|
|||
else GRArc(&panel->m_ClipBox, DC, xc, yc, t1, t2, |
|||
Arc->m_Rayon, CharColor); |
|||
#else
|
|||
else GRArc1(&panel->m_ClipBox, DC, x1, y1, x2, y2, |
|||
xc, yc, CharColor); |
|||
#endif
|
|||
} |
|||
break; |
|||
|
|||
case COMPONENT_CIRCLE_DRAW_TYPE: |
|||
{ |
|||
LibDrawCircle * Circle = (LibDrawCircle *) DEntry; |
|||
CharColor = GETCOLOR(LAYER_DEVICE); |
|||
x1 = Pos.x + TransMat[0][0] * Circle->m_Pos.x + |
|||
TransMat[0][1] * Circle->m_Pos.y; |
|||
y1 = Pos.y + TransMat[1][0] * Circle->m_Pos.x + |
|||
TransMat[1][1] * Circle->m_Pos.y; |
|||
fill_option = Circle->m_Fill & (~g_PrintFillMask); |
|||
if ( Color < 0 ) |
|||
{ |
|||
if ( (fill_option == FILLED_WITH_BG_BODYCOLOR) && ! g_IsPrinting ) |
|||
GRFilledCircle(&panel->m_ClipBox, DC, x1, y1, |
|||
Circle->m_Rayon, CharColor, |
|||
ReturnLayerColor(LAYER_DEVICE_BACKGROUND)); |
|||
else if ( fill_option == FILLED_SHAPE) |
|||
GRFilledCircle(&panel->m_ClipBox, DC, x1, y1, |
|||
Circle->m_Rayon, CharColor, CharColor); |
|||
else GRCircle(&panel->m_ClipBox, DC, x1, y1, |
|||
Circle->m_Rayon, CharColor); |
|||
} |
|||
else GRCircle(&panel->m_ClipBox, DC, x1, y1, |
|||
Circle->m_Rayon, CharColor); |
|||
} |
|||
break; |
|||
|
|||
case COMPONENT_GRAPHIC_TEXT_DRAW_TYPE: |
|||
{ |
|||
LibDrawText * Text = (LibDrawText *) DEntry; |
|||
CharColor = GETCOLOR(LAYER_DEVICE); |
|||
|
|||
/* The text orientation may need to be flipped if the
|
|||
transformation matrix cuases xy axes to be flipped. */ |
|||
t1 = (TransMat[0][0] != 0) ^ (Text->m_Horiz != 0); |
|||
x1 = Pos.x + TransMat[0][0] * Text->m_Pos.x |
|||
+ TransMat[0][1] * Text->m_Pos.y; |
|||
y1 = Pos.y + TransMat[1][0] * Text->m_Pos.x |
|||
+ TransMat[1][1] * Text->m_Pos.y; |
|||
PutTextInfo(panel, DC, t1 ? TEXT_ORIENT_HORIZ : TEXT_ORIENT_VERT, |
|||
wxPoint(x1, y1), |
|||
Text->m_Size, |
|||
Text->m_Text, DrawMode,CharColor); |
|||
} |
|||
break; |
|||
|
|||
case COMPONENT_RECT_DRAW_TYPE: |
|||
{ |
|||
LibDrawSquare * Square = (LibDrawSquare *) DEntry; |
|||
CharColor = GETCOLOR(LAYER_DEVICE); |
|||
|
|||
x1 = Pos.x + TransMat[0][0] * Square->m_Start.x |
|||
+ TransMat[0][1] * Square->m_Start.y; |
|||
y1 = Pos.y + TransMat[1][0] * Square->m_Start.x |
|||
+ TransMat[1][1] * Square->m_Start.y; |
|||
x2 = Pos.x + TransMat[0][0] * Square->m_End.x |
|||
+ TransMat[0][1] * Square->m_End.y; |
|||
y2 = Pos.y + TransMat[1][0] * Square->m_End.x |
|||
+ TransMat[1][1] * Square->m_End.y; |
|||
fill_option = Square->m_Fill & (~g_PrintFillMask); |
|||
if ( Color < 0 ) |
|||
{ |
|||
if ( (fill_option == FILLED_WITH_BG_BODYCOLOR) && ! g_IsPrinting ) |
|||
GRFilledRect(&panel->m_ClipBox, DC, x1, y1, x2, y2, |
|||
CharColor, |
|||
ReturnLayerColor(LAYER_DEVICE_BACKGROUND)); |
|||
else if ( fill_option == FILLED_SHAPE) |
|||
GRFilledRect(&panel->m_ClipBox, DC, x1, y1, x2, y2, |
|||
CharColor, CharColor); |
|||
else GRRect(&panel->m_ClipBox, DC, x1, y1, x2, y2, |
|||
CharColor); |
|||
} |
|||
else GRRect(&panel->m_ClipBox, DC, x1, y1, x2, y2, |
|||
CharColor); |
|||
} |
|||
break; |
|||
|
|||
case COMPONENT_PIN_DRAW_TYPE: /* Trace des Pins */ |
|||
{ |
|||
LibDrawPin * Pin = (LibDrawPin *) DEntry; |
|||
if(Pin->m_Attributs & PINNOTDRAW) |
|||
{ |
|||
if( (ActiveScreen->m_Type == SCHEMATIC_FRAME) && |
|||
!g_ShowAllPins ) |
|||
break; |
|||
} |
|||
/* Calcul de l'orientation reelle de la Pin */ |
|||
orient = Pin->ReturnPinDrawOrient(TransMat); |
|||
|
|||
/* Calcul de la position du point de reference */ |
|||
x2 = Pos.x + (TransMat[0][0] * Pin->m_Pos.x) |
|||
+ (TransMat[0][1] * Pin->m_Pos.y); |
|||
y2 = Pos.y + (TransMat[1][0] * Pin->m_Pos.x) |
|||
+ (TransMat[1][1] * Pin->m_Pos.y); |
|||
|
|||
/* Dessin de la pin et du symbole special associe */ |
|||
CharColor = GETCOLOR(LAYER_PIN); |
|||
DrawPinSymbol(panel, DC, x2, y2, Pin->m_PinLen, orient, |
|||
Pin->m_PinShape, DrawMode, |
|||
CharColor ); |
|||
|
|||
if ( DrawPinText ) |
|||
{ |
|||
wxPoint pinpos(x2,y2); |
|||
CharColor = SetHightColor ? s_ItemSelectColor : Color; |
|||
Pin->DrawPinTexts(panel, DC, pinpos, orient, |
|||
Entry->m_TextInside, |
|||
Entry->m_DrawPinNum,Entry->m_DrawPinName, |
|||
CharColor, DrawMode); |
|||
} |
|||
} |
|||
break; |
|||
|
|||
case COMPONENT_POLYLINE_DRAW_TYPE: |
|||
{ |
|||
LibDrawPolyline * polyline = (LibDrawPolyline *) DEntry; |
|||
CharColor = GETCOLOR(LAYER_DEVICE); |
|||
if ( Buf_Poly_Drawings == NULL ) |
|||
{ |
|||
Buf_Poly_Size = polyline->n; |
|||
Buf_Poly_Drawings = (int *) MyMalloc(sizeof(int) * 2 * Buf_Poly_Size); |
|||
} |
|||
else if ( Buf_Poly_Size < polyline->n ) |
|||
{ |
|||
Buf_Poly_Size = polyline->n; |
|||
Buf_Poly_Drawings = (int *) realloc(Buf_Poly_Drawings, |
|||
sizeof(int) * 2 * Buf_Poly_Size); |
|||
} |
|||
for (i = 0; i < polyline->n; i++) |
|||
{ |
|||
Buf_Poly_Drawings[i * 2] = Pos.x + |
|||
TransMat[0][0] * polyline->PolyList[i * 2] + |
|||
TransMat[0][1] * polyline->PolyList[i * 2 + 1]; |
|||
Buf_Poly_Drawings[i * 2 + 1] = Pos.y + |
|||
TransMat[1][0] * polyline->PolyList[i * 2] + |
|||
TransMat[1][1] * polyline->PolyList[i * 2 + 1]; |
|||
} |
|||
fill_option = polyline->m_Fill & (~g_PrintFillMask); |
|||
if ( Color < 0 ) |
|||
{ |
|||
if ( (fill_option == FILLED_WITH_BG_BODYCOLOR) && ! g_IsPrinting ) |
|||
GRPoly(&panel->m_ClipBox, DC, polyline->n, |
|||
Buf_Poly_Drawings, 1, CharColor, |
|||
ReturnLayerColor(LAYER_DEVICE_BACKGROUND)); |
|||
else if ( fill_option == FILLED_SHAPE) |
|||
GRPoly(&panel->m_ClipBox, DC, polyline->n, |
|||
Buf_Poly_Drawings, 1, CharColor, CharColor); |
|||
else GRPoly(&panel->m_ClipBox, DC, polyline->n, |
|||
Buf_Poly_Drawings, 0, CharColor, CharColor); |
|||
} |
|||
else GRPoly(&panel->m_ClipBox, DC, polyline->n, |
|||
Buf_Poly_Drawings, 0, CharColor, CharColor); |
|||
} |
|||
break; |
|||
|
|||
default: |
|||
wxBell(); |
|||
break; |
|||
} /* Fin Switch */ |
|||
} /* Fin Boucle de dessin */ |
|||
if ( g_DebugLevel > 4 ) /* Draw the component boundary box */ |
|||
{ |
|||
EDA_Rect BoundaryBox; |
|||
if ( Component ) BoundaryBox = Component->GetBoundaryBox(); |
|||
else BoundaryBox = Entry->GetBoundaryBox(Multi, convert); |
|||
x1 = BoundaryBox.GetX(); |
|||
y1 = BoundaryBox.GetY(); |
|||
x2 = BoundaryBox.GetRight(); |
|||
y2 = BoundaryBox.GetBottom(); |
|||
GRRect(&panel->m_ClipBox, DC, x1, y1, x2, y2, BROWN); |
|||
BoundaryBox = Component->m_Field[REFERENCE].GetBoundaryBox(); |
|||
x1 = BoundaryBox.GetX(); |
|||
y1 = BoundaryBox.GetY(); |
|||
x2 = BoundaryBox.GetRight(); |
|||
y2 = BoundaryBox.GetBottom(); |
|||
GRRect(&panel->m_ClipBox, DC, x1, y1, x2, y2, BROWN); |
|||
BoundaryBox = Component->m_Field[VALUE].GetBoundaryBox(); |
|||
x1 = BoundaryBox.GetX(); |
|||
y1 = BoundaryBox.GetY(); |
|||
x2 = BoundaryBox.GetRight(); |
|||
y2 = BoundaryBox.GetBottom(); |
|||
GRRect(&panel->m_ClipBox, DC, x1, y1, x2, y2, BROWN); |
|||
} |
|||
} |
|||
|
|||
|
|||
/*******************************************************/ |
|||
void DrawPinSymbol(WinEDA_DrawPanel * panel, wxDC * DC, |
|||
int posX, int posY, int len, int orient, |
|||
int Shape, int DrawMode, int Color) |
|||
/*******************************************************/ |
|||
|
|||
/* Dessine la pin du symbole en cours de trace
|
|||
si Color != 0 dessin en couleur Color, sinon en couleurs standard. |
|||
*/ |
|||
{ |
|||
int MapX1, MapY1, x1, y1; |
|||
int color; |
|||
|
|||
if( Color >= 0) color = Color; |
|||
else color = ReturnLayerColor(LAYER_PIN); |
|||
GRSetDrawMode(DC, DrawMode); |
|||
|
|||
|
|||
MapX1 = MapY1 = 0; x1 = posX; y1 = posY; |
|||
switch ( orient ) |
|||
{ |
|||
case PIN_UP: |
|||
y1 = posY - len; MapY1 = 1; |
|||
break; |
|||
case PIN_DOWN: |
|||
y1 = posY + len; MapY1 = -1; |
|||
break; |
|||
case PIN_LEFT: |
|||
x1 = posX - len, MapX1 = 1; |
|||
break; |
|||
case PIN_RIGHT: |
|||
x1 = posX + len; MapX1 = -1; |
|||
break; |
|||
} |
|||
|
|||
if( Shape & INVERT) |
|||
{ |
|||
GRCircle(&panel->m_ClipBox, DC, MapX1 * INVERT_PIN_RADIUS + x1, |
|||
MapY1 * INVERT_PIN_RADIUS + y1, |
|||
INVERT_PIN_RADIUS, color); |
|||
|
|||
GRMoveTo(MapX1 * INVERT_PIN_RADIUS * 2 + x1, |
|||
MapY1 * INVERT_PIN_RADIUS * 2 + y1); |
|||
GRLineTo(&panel->m_ClipBox, DC, posX, posY, color); |
|||
} |
|||
|
|||
else |
|||
{ |
|||
GRMoveTo(x1, y1); |
|||
GRLineTo(&panel->m_ClipBox, DC, posX, posY, color); |
|||
} |
|||
|
|||
if(Shape & CLOCK) |
|||
{ |
|||
if(MapY1 == 0 ) /* MapX1 = +- 1 */ |
|||
{ |
|||
GRMoveTo(x1, y1 + CLOCK_PIN_DIM); |
|||
GRLineTo(&panel->m_ClipBox, DC, x1 - MapX1 * CLOCK_PIN_DIM, y1, color); |
|||
GRLineTo(&panel->m_ClipBox, DC, x1, y1 - CLOCK_PIN_DIM, color); |
|||
} |
|||
else /* MapX1 = 0 */ |
|||
{ |
|||
GRMoveTo(x1 + CLOCK_PIN_DIM, y1 ); |
|||
GRLineTo(&panel->m_ClipBox, DC, x1, y1 - MapY1 * CLOCK_PIN_DIM, color); |
|||
GRLineTo(&panel->m_ClipBox, DC, x1 - CLOCK_PIN_DIM, y1, color); |
|||
} |
|||
} |
|||
|
|||
if(Shape & LOWLEVEL_IN) /* IEEE symbol "Active Low Input" */ |
|||
{ |
|||
if(MapY1 == 0 ) /* MapX1 = +- 1 */ |
|||
{ |
|||
GRMoveTo(x1 + MapX1 * IEEE_SYMBOL_PIN_DIM*2, y1); |
|||
GRLineTo(&panel->m_ClipBox, DC, x1 + MapX1 * IEEE_SYMBOL_PIN_DIM*2, |
|||
y1 - IEEE_SYMBOL_PIN_DIM, color); |
|||
GRLineTo(&panel->m_ClipBox, DC, x1, y1, color); |
|||
} |
|||
else /* MapX1 = 0 */ |
|||
{ |
|||
GRMoveTo(x1, y1 + MapY1 * IEEE_SYMBOL_PIN_DIM*2); |
|||
GRLineTo(&panel->m_ClipBox, DC, x1 - IEEE_SYMBOL_PIN_DIM, |
|||
y1 + MapY1 * IEEE_SYMBOL_PIN_DIM*2, color); |
|||
GRLineTo(&panel->m_ClipBox, DC, x1 , y1, color); |
|||
} |
|||
} |
|||
|
|||
|
|||
if(Shape & LOWLEVEL_OUT) /* IEEE symbol "Active Low Output" */ |
|||
{ |
|||
if(MapY1 == 0 ) /* MapX1 = +- 1 */ |
|||
{ |
|||
GRMoveTo(x1, y1 - IEEE_SYMBOL_PIN_DIM); |
|||
GRLineTo(&panel->m_ClipBox, DC, x1 + MapX1 * IEEE_SYMBOL_PIN_DIM*2, y1, color); |
|||
} |
|||
else /* MapX1 = 0 */ |
|||
{ |
|||
GRMoveTo(x1 - IEEE_SYMBOL_PIN_DIM, y1); |
|||
GRLineTo(&panel->m_ClipBox, DC, x1 , y1 + MapY1 * IEEE_SYMBOL_PIN_DIM*2, color); |
|||
} |
|||
} |
|||
|
|||
/* Draw the pin end target (active end of the pin) */ |
|||
if ( ! g_IsPrinting ) // Draw but do not print the pin end target */
|
|||
GRCircle(&panel->m_ClipBox, DC, posX,posY,TARGET_PIN_DIAM, color); |
|||
} |
|||
|
|||
|
|||
/*****************************************************************************
|
|||
* Routine to rotate the given angular direction by the given Transformation. * |
|||
* Input (and output) angles must be as follows: * |
|||
* Unit is 0.1 degre * |
|||
* Angle1 in [0..3600], Angle2 > Angle1 in [0..7200]. Arc is assumed to be less * |
|||
* than 180.0 degrees. * |
|||
* Algorithm: * |
|||
* Map the angles to a point on the unit circle which is mapped using the * |
|||
* transform (only mirror and rotate so it remains on the unit circle) to * |
|||
* a new point which is used to detect new angle. * |
|||
*****************************************************************************/ |
|||
bool MapAngles(int *Angle1, int *Angle2, int TransMat[2][2]) |
|||
{ |
|||
int Angle, Delta; |
|||
double x, y, t; |
|||
bool swap = FALSE; |
|||
|
|||
Delta = *Angle2 - *Angle1; |
|||
if ( Delta >= 1800 ) |
|||
{ |
|||
*Angle1 -=1; |
|||
*Angle2 +=1; |
|||
} |
|||
|
|||
x = cos(*Angle1 * M_PI / 1800.0); |
|||
y = sin(*Angle1 * M_PI / 1800.0); |
|||
t = x * TransMat[0][0] + y * TransMat[0][1]; |
|||
y = x * TransMat[1][0] + y * TransMat[1][1]; |
|||
x = t; |
|||
*Angle1 = (int) (atan2(y, x) * 1800.0 / M_PI + 0.5); |
|||
|
|||
x = cos(*Angle2 * M_PI / 1800.0); |
|||
y = sin(*Angle2 * M_PI / 1800.0); |
|||
t = x * TransMat[0][0] + y * TransMat[0][1]; |
|||
y = x * TransMat[1][0] + y * TransMat[1][1]; |
|||
x = t; |
|||
*Angle2 = (int) (atan2(y, x) * 1800.0 / M_PI + 0.5); |
|||
|
|||
NORMALIZE_ANGLE(*Angle1); |
|||
NORMALIZE_ANGLE(*Angle2); |
|||
if (*Angle2 < *Angle1) *Angle2 += 3600; |
|||
|
|||
if (*Angle2 - *Angle1 > 1800) |
|||
{ /* Need to swap the two angles. */ |
|||
Angle = (*Angle1); |
|||
*Angle1 = (*Angle2); |
|||
*Angle2 = Angle; |
|||
|
|||
NORMALIZE_ANGLE(*Angle1); |
|||
NORMALIZE_ANGLE(*Angle2); |
|||
if (*Angle2 < *Angle1) *Angle2 += 3600; |
|||
swap = TRUE; |
|||
} |
|||
|
|||
if ( Delta >= 1800 ) |
|||
{ |
|||
*Angle1 +=1; |
|||
*Angle2 -=1; |
|||
} |
|||
|
|||
return swap; |
|||
} |
|||
|
|||
|
|||
/*****************************************************************************
|
|||
* Routine to display an outline version of given library entry. * |
|||
* This routine is applied by the PlaceLibItem routine above. * |
|||
*****************************************************************************/ |
|||
void DrawingLibInGhost(WinEDA_DrawPanel * panel, wxDC * DC, |
|||
EDA_LibComponentStruct *LibEntry, |
|||
EDA_SchComponentStruct *DrawLibItem, int PartX, int PartY, |
|||
int multi, int convert, int Color, bool DrawPinText) |
|||
{ |
|||
int DrawMode = g_XorMode; |
|||
|
|||
DrawLibPartAux(panel, DC, DrawLibItem, LibEntry, wxPoint(PartX, PartY), |
|||
DrawLibItem->m_Transform, |
|||
multi, convert, DrawMode, Color, DrawPinText); |
|||
|
|||
} |
|||
|
|||
/************************************************************/ |
|||
/* Routine to draw One LibraryDrawStruct at given position, */ |
|||
/* matrice de transformation 1 0 0 -1 (normale) */ |
|||
/* DrawMode = GrXOR, GrOR .. */ |
|||
/************************************************************/ |
|||
/* Utilise en LibEdit et Lib Browse */ |
|||
void DrawLibraryDrawStruct(WinEDA_DrawPanel * panel, wxDC * DC, |
|||
EDA_LibComponentStruct *LibEntry, |
|||
int PartX, int PartY, |
|||
LibEDA_BaseStruct *DrawItem, int Multi, |
|||
int DrawMode, int Color) |
|||
{ |
|||
int i, x1, y1, x2, y2, t1, t2, orient; |
|||
int CharColor; |
|||
int TransMat[2][2]; |
|||
int fill_option; |
|||
|
|||
#undef GETCOLOR
|
|||
#define GETCOLOR(l) Color < 0 ? ReturnLayerColor(l) : Color;
|
|||
|
|||
Multi = 0; /* unused */ |
|||
/* Trace de la structure */ |
|||
CharColor = GETCOLOR(LAYER_DEVICE); |
|||
GRSetDrawMode(DC, DrawMode); |
|||
|
|||
TransMat[0][0] = 1; |
|||
TransMat[0][1] = TransMat[1][0] = 0; |
|||
TransMat[1][1] = -1; |
|||
|
|||
switch (DrawItem->m_StructType) |
|||
{ |
|||
case COMPONENT_ARC_DRAW_TYPE: |
|||
{ |
|||
int xc,yc, x2,y2; |
|||
LibDrawArc * Arc = (LibDrawArc *) DrawItem; |
|||
t1 = Arc->t1; t2 = Arc->t2; |
|||
bool swap = MapAngles(&t1, &t2, TransMat); |
|||
xc = PartX + Arc->m_Pos.x; |
|||
yc = PartY - Arc->m_Pos.y; |
|||
x2 = PartX + Arc->m_Start.x; |
|||
y2 = PartY - Arc->m_Start.y; |
|||
x1 = PartX + Arc->m_End.x; |
|||
y1 = PartY - Arc->m_End.y; |
|||
|
|||
if ( swap ) { EXCHG(x1,x2); EXCHG(y1, y2)} |
|||
fill_option = Arc->m_Fill & (~g_PrintFillMask); |
|||
if ( (Arc->m_Fill == FILLED_WITH_BG_BODYCOLOR) && ! g_IsPrinting ) |
|||
GRFilledArc(&panel->m_ClipBox, DC, xc, yc, t1, t2, |
|||
Arc->m_Rayon, CharColor, |
|||
ReturnLayerColor(LAYER_DEVICE_BACKGROUND)); |
|||
else if ( Arc->m_Fill == FILLED_SHAPE) |
|||
GRFilledArc(&panel->m_ClipBox, DC, xc, yc, t1, t2, |
|||
Arc->m_Rayon, CharColor, CharColor); |
|||
#ifdef DRAW_ARC_WITH_ANGLE
|
|||
else GRArc(&panel->m_ClipBox, DC, xc, yc, t1, t2, |
|||
Arc->m_Rayon, CharColor); |
|||
#else
|
|||
else GRArc1(&panel->m_ClipBox, DC, x1, y1, x2, y2, |
|||
xc, yc, CharColor); |
|||
#endif
|
|||
} |
|||
break; |
|||
|
|||
case COMPONENT_CIRCLE_DRAW_TYPE: |
|||
{ |
|||
LibDrawCircle * Circle = (LibDrawCircle *) DrawItem; |
|||
x1 = PartX + Circle->m_Pos.x; |
|||
y1 = PartY - Circle->m_Pos.y; |
|||
fill_option = Circle->m_Fill & (~g_PrintFillMask); |
|||
if ( (fill_option == FILLED_WITH_BG_BODYCOLOR) && ! g_IsPrinting ) |
|||
GRFilledCircle(&panel->m_ClipBox, DC, x1, y1, |
|||
Circle->m_Rayon, CharColor, |
|||
ReturnLayerColor(LAYER_DEVICE_BACKGROUND)); |
|||
else if ( fill_option == FILLED_SHAPE) |
|||
GRFilledCircle(&panel->m_ClipBox, DC, x1, y1, |
|||
Circle->m_Rayon, CharColor, CharColor); |
|||
else GRCircle(&panel->m_ClipBox, DC, x1, y1, |
|||
Circle->m_Rayon, CharColor); |
|||
} |
|||
break; |
|||
|
|||
case COMPONENT_GRAPHIC_TEXT_DRAW_TYPE: |
|||
{ |
|||
LibDrawText * Text = (LibDrawText *) DrawItem; |
|||
x1 = PartX + Text->m_Pos.x; |
|||
y1 = PartY - Text->m_Pos.y; |
|||
PutTextInfo(panel, DC, Text->m_Horiz, wxPoint(x1, y1), |
|||
Text->m_Size, Text->m_Text, |
|||
DrawMode,CharColor); |
|||
} |
|||
break; |
|||
|
|||
case COMPONENT_RECT_DRAW_TYPE: |
|||
{ |
|||
LibDrawSquare * Square = (LibDrawSquare *) DrawItem; |
|||
x1 = PartX + Square->m_Start.x; |
|||
y1 = PartY - Square->m_Start.y; |
|||
x2 = PartX + Square->m_End.x; |
|||
y2 = PartY - Square->m_End.y; |
|||
fill_option = Square->m_Fill & (~g_PrintFillMask); |
|||
if ( (fill_option == FILLED_WITH_BG_BODYCOLOR) && ! g_IsPrinting ) |
|||
GRFilledRect(&panel->m_ClipBox, DC, x1, y1, x2, y2, |
|||
CharColor, |
|||
ReturnLayerColor(LAYER_DEVICE_BACKGROUND)); |
|||
else if ( fill_option == FILLED_SHAPE) |
|||
GRFilledRect(&panel->m_ClipBox, DC, x1, y1, x2, y2, |
|||
CharColor, CharColor); |
|||
else GRRect(&panel->m_ClipBox, DC, x1, y1, x2, y2, |
|||
CharColor); |
|||
} |
|||
break; |
|||
|
|||
case COMPONENT_PIN_DRAW_TYPE: /* Trace des Pins */ |
|||
{ |
|||
LibDrawPin * Pin = (LibDrawPin *) DrawItem; |
|||
x2 = PartX + Pin->m_Pos.x; |
|||
y2 = PartY - Pin->m_Pos.y; |
|||
/* Compute the real pin orientation, i.e. pin orient + component orient */ |
|||
orient = Pin->ReturnPinDrawOrient(TransMat); |
|||
|
|||
/* Dessin de la pin et du symbole special associe */ |
|||
if( Pin->m_Attributs & PINNOTDRAW) CharColor = DARKGRAY; |
|||
else CharColor = -1; |
|||
|
|||
DrawPinSymbol(panel, DC, x2, y2, Pin->m_PinLen, orient, |
|||
Pin->m_PinShape, DrawMode); |
|||
wxPoint pinpos(x2,y2); |
|||
Pin->DrawPinTexts(panel, DC, pinpos, orient, |
|||
LibEntry->m_TextInside, |
|||
LibEntry->m_DrawPinNum,LibEntry->m_DrawPinName, |
|||
CharColor, DrawMode); |
|||
} |
|||
break; |
|||
|
|||
case COMPONENT_POLYLINE_DRAW_TYPE: |
|||
{ |
|||
LibDrawPolyline * polyline = (LibDrawPolyline *) DrawItem; |
|||
if ( Buf_Poly_Drawings == NULL ) |
|||
{ |
|||
Buf_Poly_Size = polyline->n; |
|||
Buf_Poly_Drawings = (int *) MyMalloc(sizeof(int) * 2 * Buf_Poly_Size); |
|||
} |
|||
else if ( Buf_Poly_Size < polyline->n ) |
|||
{ |
|||
Buf_Poly_Size = polyline->n; |
|||
Buf_Poly_Drawings = (int *) realloc(Buf_Poly_Drawings, |
|||
sizeof(int) * 2 * Buf_Poly_Size); |
|||
} |
|||
for (i = 0; i < polyline->n; i++) |
|||
{ |
|||
Buf_Poly_Drawings[i * 2] = PartX + polyline->PolyList[i * 2]; |
|||
Buf_Poly_Drawings[i * 2 + 1] = PartY - polyline->PolyList[i * 2 + 1]; |
|||
} |
|||
fill_option = polyline->m_Fill & (~g_PrintFillMask); |
|||
if ( (fill_option == FILLED_WITH_BG_BODYCOLOR) && ! g_IsPrinting ) |
|||
GRPoly(&panel->m_ClipBox, DC, polyline->n, |
|||
Buf_Poly_Drawings, 1, CharColor, |
|||
ReturnLayerColor(LAYER_DEVICE_BACKGROUND)); |
|||
else if ( fill_option == FILLED_SHAPE) |
|||
GRPoly(&panel->m_ClipBox, DC, polyline->n, |
|||
Buf_Poly_Drawings, 1, CharColor, CharColor); |
|||
else GRPoly(&panel->m_ClipBox, DC, polyline->n, |
|||
Buf_Poly_Drawings, 0, CharColor, CharColor); |
|||
break; |
|||
} |
|||
} |
|||
} |
|||
|
|||
@ -1,139 +0,0 @@ |
|||
/////////////////////////////////////////////////////////////////////////////
|
|||
// Name: xx.cpp
|
|||
// Purpose:
|
|||
// Author: jean-pierre Charras
|
|||
// Modified by:
|
|||
// Created: 02/03/2006 09:16:35
|
|||
// RCS-ID:
|
|||
// Copyright: License GNU
|
|||
// Licence:
|
|||
/////////////////////////////////////////////////////////////////////////////
|
|||
|
|||
// Generated by DialogBlocks (unregistered), 02/03/2006 09:16:35
|
|||
|
|||
#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
|
|||
#pragma implementation "xx.h"
|
|||
#endif
|
|||
|
|||
// For compilers that support precompilation, includes "wx/wx.h".
|
|||
#include "wx/wxprec.h"
|
|||
|
|||
#ifdef __BORLANDC__
|
|||
#pragma hdrstop
|
|||
#endif
|
|||
|
|||
#ifndef WX_PRECOMP
|
|||
#include "wx/wx.h"
|
|||
#endif
|
|||
|
|||
////@begin includes
|
|||
////@end includes
|
|||
|
|||
#include "xx.h"
|
|||
|
|||
////@begin XPM images
|
|||
|
|||
////@end XPM images
|
|||
|
|||
/*!
|
|||
* xx type definition |
|||
*/ |
|||
|
|||
IMPLEMENT_DYNAMIC_CLASS( xx, wxDialog ) |
|||
|
|||
/*!
|
|||
* xx event table definition |
|||
*/ |
|||
|
|||
BEGIN_EVENT_TABLE( xx, wxDialog ) |
|||
|
|||
////@begin xx event table entries
|
|||
////@end xx event table entries
|
|||
|
|||
END_EVENT_TABLE() |
|||
|
|||
/*!
|
|||
* xx constructors |
|||
*/ |
|||
|
|||
xx::xx( ) |
|||
{ |
|||
} |
|||
|
|||
xx::xx( wxWindow* parent, wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) |
|||
{ |
|||
Create(parent, id, caption, pos, size, style); |
|||
} |
|||
|
|||
/*!
|
|||
* xx creator |
|||
*/ |
|||
|
|||
bool xx::Create( wxWindow* parent, wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) |
|||
{ |
|||
////@begin xx member initialisation
|
|||
////@end xx member initialisation
|
|||
|
|||
////@begin xx creation
|
|||
SetExtraStyle(GetExtraStyle()|wxWS_EX_BLOCK_EVENTS); |
|||
wxDialog::Create( parent, id, caption, pos, size, style ); |
|||
|
|||
CreateControls(); |
|||
GetSizer()->Fit(this); |
|||
GetSizer()->SetSizeHints(this); |
|||
Centre(); |
|||
////@end xx creation
|
|||
return true; |
|||
} |
|||
|
|||
/*!
|
|||
* Control creation for xx |
|||
*/ |
|||
|
|||
void xx::CreateControls() |
|||
{ |
|||
////@begin xx content construction
|
|||
// Generated by DialogBlocks, 02/03/2006 09:16:35 (unregistered)
|
|||
|
|||
xx* itemDialog1 = this; |
|||
|
|||
wxBoxSizer* itemBoxSizer2 = new wxBoxSizer(wxVERTICAL); |
|||
itemDialog1->SetSizer(itemBoxSizer2); |
|||
|
|||
////@end xx content construction
|
|||
} |
|||
|
|||
/*!
|
|||
* Should we show tooltips? |
|||
*/ |
|||
|
|||
bool xx::ShowToolTips() |
|||
{ |
|||
return true; |
|||
} |
|||
|
|||
/*!
|
|||
* Get bitmap resources |
|||
*/ |
|||
|
|||
wxBitmap xx::GetBitmapResource( const wxString& name ) |
|||
{ |
|||
// Bitmap retrieval
|
|||
////@begin xx bitmap retrieval
|
|||
wxUnusedVar(name); |
|||
return wxNullBitmap; |
|||
////@end xx bitmap retrieval
|
|||
} |
|||
|
|||
/*!
|
|||
* Get icon resources |
|||
*/ |
|||
|
|||
wxIcon xx::GetIconResource( const wxString& name ) |
|||
{ |
|||
// Icon retrieval
|
|||
////@begin xx icon retrieval
|
|||
wxUnusedVar(name); |
|||
return wxNullIcon; |
|||
////@end xx icon retrieval
|
|||
} |
|||
@ -1,95 +0,0 @@ |
|||
///////////////////////////////////////////////////////////////////////////// |
|||
// Name: xx.h |
|||
// Purpose: |
|||
// Author: jean-pierre Charras |
|||
// Modified by: |
|||
// Created: 02/03/2006 09:16:35 |
|||
// RCS-ID: |
|||
// Copyright: License GNU |
|||
// Licence: |
|||
///////////////////////////////////////////////////////////////////////////// |
|||
|
|||
// Generated by DialogBlocks (unregistered), 02/03/2006 09:16:35 |
|||
|
|||
#ifndef _XX_H_ |
|||
#define _XX_H_ |
|||
|
|||
#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) |
|||
#pragma interface "xx.h" |
|||
#endif |
|||
|
|||
/*! |
|||
* Includes |
|||
*/ |
|||
|
|||
////@begin includes |
|||
////@end includes |
|||
|
|||
/*! |
|||
* Forward declarations |
|||
*/ |
|||
|
|||
////@begin forward declarations |
|||
////@end forward declarations |
|||
|
|||
/*! |
|||
* Control identifiers |
|||
*/ |
|||
|
|||
////@begin control identifiers |
|||
#define ID_DIALOG 10015 |
|||
#define SYMBOL_XX_STYLE wxCAPTION|wxRESIZE_BORDER|wxSYSTEM_MENU|wxCLOSE_BOX |
|||
#define SYMBOL_XX_TITLE _("xx") |
|||
#define SYMBOL_XX_IDNAME ID_DIALOG |
|||
#define SYMBOL_XX_SIZE wxSize(400, 300) |
|||
#define SYMBOL_XX_POSITION wxDefaultPosition |
|||
////@end control identifiers |
|||
|
|||
/*! |
|||
* Compatibility |
|||
*/ |
|||
|
|||
#ifndef wxCLOSE_BOX |
|||
#define wxCLOSE_BOX 0x1000 |
|||
#endif |
|||
|
|||
/*! |
|||
* xx class declaration |
|||
*/ |
|||
|
|||
class xx: public wxDialog |
|||
{ |
|||
DECLARE_DYNAMIC_CLASS( xx ) |
|||
DECLARE_EVENT_TABLE() |
|||
|
|||
public: |
|||
/// Constructors |
|||
xx( ); |
|||
xx( wxWindow* parent, wxWindowID id = SYMBOL_XX_IDNAME, const wxString& caption = SYMBOL_XX_TITLE, const wxPoint& pos = SYMBOL_XX_POSITION, const wxSize& size = SYMBOL_XX_SIZE, long style = SYMBOL_XX_STYLE ); |
|||
|
|||
/// Creation |
|||
bool Create( wxWindow* parent, wxWindowID id = SYMBOL_XX_IDNAME, const wxString& caption = SYMBOL_XX_TITLE, const wxPoint& pos = SYMBOL_XX_POSITION, const wxSize& size = SYMBOL_XX_SIZE, long style = SYMBOL_XX_STYLE ); |
|||
|
|||
/// Creates the controls and sizers |
|||
void CreateControls(); |
|||
|
|||
////@begin xx event handler declarations |
|||
////@end xx event handler declarations |
|||
|
|||
////@begin xx member function declarations |
|||
/// Retrieves bitmap resources |
|||
wxBitmap GetBitmapResource( const wxString& name ); |
|||
|
|||
/// Retrieves icon resources |
|||
wxIcon GetIconResource( const wxString& name ); |
|||
////@end xx member function declarations |
|||
|
|||
/// Should we show tooltips? |
|||
static bool ShowToolTips(); |
|||
|
|||
////@begin xx member variables |
|||
////@end xx member variables |
|||
}; |
|||
|
|||
#endif |
|||
// _XX_H_ |
|||
@ -0,0 +1,255 @@ |
|||
/////////////////////////////////////////////////////////////////////////////
|
|||
// Name: cleaningoptions_dialog.cpp
|
|||
// Purpose:
|
|||
// Author: jean-pierre Charras
|
|||
// Modified by:
|
|||
// Created: 25/05/2007 14:24:54
|
|||
// RCS-ID:
|
|||
// Copyright: GNU License
|
|||
// Licence:
|
|||
/////////////////////////////////////////////////////////////////////////////
|
|||
|
|||
// Generated by DialogBlocks (unregistered), 25/05/2007 14:24:54
|
|||
|
|||
#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
|
|||
#pragma implementation "cleaningoptions_dialog.h"
|
|||
#endif
|
|||
|
|||
// For compilers that support precompilation, includes "wx/wx.h".
|
|||
#include "wx/wxprec.h"
|
|||
|
|||
#ifdef __BORLANDC__
|
|||
#pragma hdrstop
|
|||
#endif
|
|||
|
|||
#ifndef WX_PRECOMP
|
|||
#include "wx/wx.h"
|
|||
#endif
|
|||
|
|||
////@begin includes
|
|||
////@end includes
|
|||
|
|||
#include "cleaningoptions_dialog.h"
|
|||
|
|||
////@begin XPM images
|
|||
////@end XPM images
|
|||
|
|||
|
|||
/*!
|
|||
* WinEDA_CleaningOptionsFrame type definition |
|||
*/ |
|||
|
|||
IMPLEMENT_DYNAMIC_CLASS( WinEDA_CleaningOptionsFrame, wxDialog ) |
|||
|
|||
|
|||
/*!
|
|||
* WinEDA_CleaningOptionsFrame event table definition |
|||
*/ |
|||
|
|||
BEGIN_EVENT_TABLE( WinEDA_CleaningOptionsFrame, wxDialog ) |
|||
|
|||
////@begin WinEDA_CleaningOptionsFrame event table entries
|
|||
EVT_CLOSE( WinEDA_CleaningOptionsFrame::OnCloseWindow ) |
|||
|
|||
EVT_BUTTON( ID_BUTTON_EXECUTE, WinEDA_CleaningOptionsFrame::OnButtonExecuteClick ) |
|||
|
|||
////@end WinEDA_CleaningOptionsFrame event table entries
|
|||
|
|||
END_EVENT_TABLE() |
|||
|
|||
|
|||
/*!
|
|||
* WinEDA_CleaningOptionsFrame constructors |
|||
*/ |
|||
|
|||
WinEDA_CleaningOptionsFrame::WinEDA_CleaningOptionsFrame() |
|||
{ |
|||
Init(); |
|||
} |
|||
|
|||
WinEDA_CleaningOptionsFrame::WinEDA_CleaningOptionsFrame( WinEDA_PcbFrame* parent, wxDC * DC, wxWindowID id, |
|||
const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) |
|||
{ |
|||
Init(); |
|||
m_Parent = parent; |
|||
m_DC = DC; |
|||
Create(parent, id, caption, pos, size, style); |
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* WinEDA_CleaningOptionsFrame creator |
|||
*/ |
|||
|
|||
bool WinEDA_CleaningOptionsFrame::Create( wxWindow * parent, wxWindowID id, |
|||
const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) |
|||
{ |
|||
////@begin WinEDA_CleaningOptionsFrame creation
|
|||
SetExtraStyle(wxWS_EX_BLOCK_EVENTS); |
|||
wxDialog::Create( parent, id, caption, pos, size, style ); |
|||
|
|||
CreateControls(); |
|||
if (GetSizer()) |
|||
{ |
|||
GetSizer()->SetSizeHints(this); |
|||
} |
|||
Centre(); |
|||
////@end WinEDA_CleaningOptionsFrame creation
|
|||
return true; |
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* WinEDA_CleaningOptionsFrame destructor |
|||
*/ |
|||
|
|||
WinEDA_CleaningOptionsFrame::~WinEDA_CleaningOptionsFrame() |
|||
{ |
|||
////@begin WinEDA_CleaningOptionsFrame destruction
|
|||
////@end WinEDA_CleaningOptionsFrame destruction
|
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* Member initialisation |
|||
*/ |
|||
|
|||
void WinEDA_CleaningOptionsFrame::Init() |
|||
{ |
|||
m_Parent = NULL; |
|||
////@begin WinEDA_CleaningOptionsFrame member initialisation
|
|||
m_CleanViasOpt = NULL; |
|||
m_MergetSegmOpt = NULL; |
|||
m_DeleteunconnectedOpt = NULL; |
|||
m_ConnectToPadsOpt = NULL; |
|||
////@end WinEDA_CleaningOptionsFrame member initialisation
|
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* Control creation for WinEDA_CleaningOptionsFrame |
|||
*/ |
|||
|
|||
void WinEDA_CleaningOptionsFrame::CreateControls() |
|||
{ |
|||
////@begin WinEDA_CleaningOptionsFrame content construction
|
|||
// Generated by DialogBlocks, 28/05/2007 19:08:46 (unregistered)
|
|||
|
|||
WinEDA_CleaningOptionsFrame* itemDialog1 = this; |
|||
|
|||
wxBoxSizer* itemBoxSizer2 = new wxBoxSizer(wxVERTICAL); |
|||
itemDialog1->SetSizer(itemBoxSizer2); |
|||
|
|||
wxBoxSizer* itemBoxSizer3 = new wxBoxSizer(wxHORIZONTAL); |
|||
itemBoxSizer2->Add(itemBoxSizer3, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); |
|||
|
|||
wxStaticBox* itemStaticBoxSizer4Static = new wxStaticBox(itemDialog1, wxID_ANY, _("Static")); |
|||
wxStaticBoxSizer* itemStaticBoxSizer4 = new wxStaticBoxSizer(itemStaticBoxSizer4Static, wxVERTICAL); |
|||
itemBoxSizer3->Add(itemStaticBoxSizer4, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); |
|||
|
|||
m_CleanViasOpt = new wxCheckBox( itemDialog1, ID_CHECKBOX_CLEAN_VIAS, _("Delete redundant vias"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
m_CleanViasOpt->SetValue(false); |
|||
itemStaticBoxSizer4->Add(m_CleanViasOpt, 0, wxALIGN_LEFT|wxALL, 5); |
|||
|
|||
m_MergetSegmOpt = new wxCheckBox( itemDialog1, ID_CHECKBOX_MERGE_SEGMENTS, _("Merge segments"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
m_MergetSegmOpt->SetValue(false); |
|||
itemStaticBoxSizer4->Add(m_MergetSegmOpt, 0, wxALIGN_LEFT|wxALL, 5); |
|||
|
|||
m_DeleteunconnectedOpt = new wxCheckBox( itemDialog1, ID_CHECKBOX1, _("Delete unconnected tracks"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
m_DeleteunconnectedOpt->SetValue(false); |
|||
itemStaticBoxSizer4->Add(m_DeleteunconnectedOpt, 0, wxALIGN_LEFT|wxALL, 5); |
|||
|
|||
m_ConnectToPadsOpt = new wxCheckBox( itemDialog1, ID_CHECKBOX, _("Connect stubs to Pads"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
m_ConnectToPadsOpt->SetValue(false); |
|||
itemStaticBoxSizer4->Add(m_ConnectToPadsOpt, 0, wxALIGN_LEFT|wxALL, 5); |
|||
|
|||
wxBoxSizer* itemBoxSizer9 = new wxBoxSizer(wxVERTICAL); |
|||
itemBoxSizer3->Add(itemBoxSizer9, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); |
|||
|
|||
wxButton* itemButton10 = new wxButton( itemDialog1, ID_BUTTON_EXECUTE, _("Clean pcb"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
itemButton10->SetDefault(); |
|||
itemBoxSizer9->Add(itemButton10, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); |
|||
|
|||
// Set validators
|
|||
m_CleanViasOpt->SetValidator( wxGenericValidator(& s_CleanVias) ); |
|||
m_MergetSegmOpt->SetValidator( wxGenericValidator(& s_MergeSegments) ); |
|||
m_DeleteunconnectedOpt->SetValidator( wxGenericValidator(& s_DeleteUnconnectedSegm) ); |
|||
////@end WinEDA_CleaningOptionsFrame content construction
|
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* Should we show tooltips? |
|||
*/ |
|||
|
|||
bool WinEDA_CleaningOptionsFrame::ShowToolTips() |
|||
{ |
|||
return true; |
|||
} |
|||
|
|||
/*!
|
|||
* Get bitmap resources |
|||
*/ |
|||
|
|||
wxBitmap WinEDA_CleaningOptionsFrame::GetBitmapResource( const wxString& name ) |
|||
{ |
|||
// Bitmap retrieval
|
|||
////@begin WinEDA_CleaningOptionsFrame bitmap retrieval
|
|||
wxUnusedVar(name); |
|||
return wxNullBitmap; |
|||
////@end WinEDA_CleaningOptionsFrame bitmap retrieval
|
|||
} |
|||
|
|||
/*!
|
|||
* Get icon resources |
|||
*/ |
|||
|
|||
wxIcon WinEDA_CleaningOptionsFrame::GetIconResource( const wxString& name ) |
|||
{ |
|||
// Icon retrieval
|
|||
////@begin WinEDA_CleaningOptionsFrame icon retrieval
|
|||
wxUnusedVar(name); |
|||
return wxNullIcon; |
|||
////@end WinEDA_CleaningOptionsFrame icon retrieval
|
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON_EXECUTE |
|||
*/ |
|||
|
|||
void WinEDA_CleaningOptionsFrame::OnButtonExecuteClick( wxCommandEvent& event ) |
|||
{ |
|||
s_CleanVias = m_CleanViasOpt->GetValue(); |
|||
s_MergeSegments = m_MergetSegmOpt->GetValue(); |
|||
s_DeleteUnconnectedSegm = m_DeleteunconnectedOpt->GetValue(); |
|||
s_ConnectToPads = m_ConnectToPadsOpt->GetValue(); |
|||
|
|||
Clean_Pcb_Items(m_Parent, m_DC ); |
|||
|
|||
Close(TRUE); |
|||
} |
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
|
|||
/*!
|
|||
* wxEVT_CLOSE_WINDOW event handler for ID_WIN_EDA_CLEANINGOPTIONSFRAME |
|||
*/ |
|||
|
|||
void WinEDA_CleaningOptionsFrame::OnCloseWindow( wxCloseEvent& event ) |
|||
{ |
|||
s_CleanVias = m_CleanViasOpt->GetValue(); |
|||
s_MergeSegments = m_MergetSegmOpt->GetValue(); |
|||
s_DeleteUnconnectedSegm = m_DeleteunconnectedOpt->GetValue(); |
|||
s_ConnectToPads = m_ConnectToPadsOpt->GetValue(); |
|||
|
|||
event.Skip(); |
|||
} |
|||
|
|||
@ -0,0 +1,115 @@ |
|||
///////////////////////////////////////////////////////////////////////////// |
|||
// Name: cleaningoptions_dialog.h |
|||
// Purpose: |
|||
// Author: jean-pierre Charras |
|||
// Modified by: |
|||
// Created: 25/05/2007 14:24:54 |
|||
// RCS-ID: |
|||
// Copyright: GNU License |
|||
// Licence: |
|||
///////////////////////////////////////////////////////////////////////////// |
|||
|
|||
// Generated by DialogBlocks (unregistered), 25/05/2007 14:24:54 |
|||
|
|||
#ifndef _CLEANINGOPTIONS_DIALOG_H_ |
|||
#define _CLEANINGOPTIONS_DIALOG_H_ |
|||
|
|||
#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) |
|||
#pragma interface "cleaningoptions_dialog.h" |
|||
#endif |
|||
|
|||
/*! |
|||
* Includes |
|||
*/ |
|||
|
|||
////@begin includes |
|||
#include "wx/valgen.h" |
|||
////@end includes |
|||
|
|||
/*! |
|||
* Forward declarations |
|||
*/ |
|||
|
|||
////@begin forward declarations |
|||
////@end forward declarations |
|||
|
|||
/*! |
|||
* Control identifiers |
|||
*/ |
|||
|
|||
////@begin control identifiers |
|||
#define ID_WIN_EDA_CLEANINGOPTIONSFRAME 10000 |
|||
#define ID_CHECKBOX_CLEAN_VIAS 10001 |
|||
#define ID_CHECKBOX_MERGE_SEGMENTS 10003 |
|||
#define ID_CHECKBOX1 10005 |
|||
#define ID_CHECKBOX 10004 |
|||
#define ID_BUTTON_EXECUTE 10006 |
|||
#define SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_STYLE wxCAPTION|wxRESIZE_BORDER|wxSYSTEM_MENU|wxCLOSE_BOX |
|||
#define SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_TITLE _("Cleaning options") |
|||
#define SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_IDNAME ID_WIN_EDA_CLEANINGOPTIONSFRAME |
|||
#define SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_SIZE wxSize(400, 300) |
|||
#define SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_POSITION wxDefaultPosition |
|||
////@end control identifiers |
|||
|
|||
|
|||
/*! |
|||
* WinEDA_CleaningOptionsFrame class declaration |
|||
*/ |
|||
|
|||
class WinEDA_CleaningOptionsFrame: public wxDialog |
|||
{ |
|||
DECLARE_DYNAMIC_CLASS( WinEDA_CleaningOptionsFrame ) |
|||
DECLARE_EVENT_TABLE() |
|||
|
|||
public: |
|||
/// Constructors |
|||
WinEDA_CleaningOptionsFrame(); |
|||
WinEDA_CleaningOptionsFrame( WinEDA_PcbFrame * parent, wxDC * DC, |
|||
wxWindowID id = SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_SIZE, long style = SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_STYLE ); |
|||
|
|||
/// Creation |
|||
bool Create( wxWindow* parent, wxWindowID id = SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_IDNAME, const wxString& caption = SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_TITLE, const wxPoint& pos = SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_POSITION, const wxSize& size = SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_SIZE, long style = SYMBOL_WINEDA_CLEANINGOPTIONSFRAME_STYLE ); |
|||
|
|||
/// Destructor |
|||
~WinEDA_CleaningOptionsFrame(); |
|||
|
|||
/// Initialises member variables |
|||
void Init(); |
|||
|
|||
/// Creates the controls and sizers |
|||
void CreateControls(); |
|||
|
|||
////@begin WinEDA_CleaningOptionsFrame event handler declarations |
|||
|
|||
/// wxEVT_CLOSE_WINDOW event handler for ID_WIN_EDA_CLEANINGOPTIONSFRAME |
|||
void OnCloseWindow( wxCloseEvent& event ); |
|||
|
|||
/// wxEVT_COMMAND_BUTTON_CLICKED event handler for ID_BUTTON_EXECUTE |
|||
void OnButtonExecuteClick( wxCommandEvent& event ); |
|||
|
|||
////@end WinEDA_CleaningOptionsFrame event handler declarations |
|||
|
|||
////@begin WinEDA_CleaningOptionsFrame member function declarations |
|||
|
|||
/// Retrieves bitmap resources |
|||
wxBitmap GetBitmapResource( const wxString& name ); |
|||
|
|||
/// Retrieves icon resources |
|||
wxIcon GetIconResource( const wxString& name ); |
|||
////@end WinEDA_CleaningOptionsFrame member function declarations |
|||
|
|||
/// Should we show tooltips? |
|||
static bool ShowToolTips(); |
|||
|
|||
////@begin WinEDA_CleaningOptionsFrame member variables |
|||
wxCheckBox* m_CleanViasOpt; |
|||
wxCheckBox* m_MergetSegmOpt; |
|||
wxCheckBox* m_DeleteunconnectedOpt; |
|||
wxCheckBox* m_ConnectToPadsOpt; |
|||
////@end WinEDA_CleaningOptionsFrame member variables |
|||
WinEDA_PcbFrame * m_Parent; |
|||
wxDC * m_DC; |
|||
}; |
|||
|
|||
#endif |
|||
// _CLEANINGOPTIONS_DIALOG_H_ |
|||
@ -0,0 +1,703 @@ |
|||
<?xml version="1.0" encoding="UTF-8"?> |
|||
<anthemion-project version="1.0.0.0" xmlns="http://www.anthemion.co.uk"> |
|||
<header> |
|||
<long name="name_counter">0</long> |
|||
<string name="html_path">""</string> |
|||
<string name="title">""</string> |
|||
<string name="author">""</string> |
|||
<string name="description">""</string> |
|||
<string name="xrc_filename">""</string> |
|||
<bool name="convert_images_to_xpm">0</bool> |
|||
<bool name="inline_images">0</bool> |
|||
<bool name="generate_cpp_for_xrc">0</bool> |
|||
<bool name="use_help_text_for_tooltips">1</bool> |
|||
<bool name="translate_strings">1</bool> |
|||
<bool name="extract_strings">0</bool> |
|||
<string name="user_name">"jean-pierre Charras"</string> |
|||
<string name="copyright_string">"GNU License"</string> |
|||
<string name="resource_prefix">""</string> |
|||
<bool name="use_two_step_construction">0</bool> |
|||
<bool name="use_enums">0</bool> |
|||
<string name="current_platform">"<All platforms>"</string> |
|||
<string name="target_wx_version">"2.8.3"</string> |
|||
<string name="cpp_header_comment">"///////////////////////////////////////////////////////////////////////////// |
|||
// Name: %HEADER-FILENAME% |
|||
// Purpose: |
|||
// Author: %AUTHOR% |
|||
// Modified by: |
|||
// Created: %DATE% |
|||
// RCS-ID: |
|||
// Copyright: %COPYRIGHT% |
|||
// Licence: |
|||
///////////////////////////////////////////////////////////////////////////// |
|||
|
|||
"</string> |
|||
<string name="cpp_implementation_comment">"///////////////////////////////////////////////////////////////////////////// |
|||
// Name: %SOURCE-FILENAME% |
|||
// Purpose: |
|||
// Author: %AUTHOR% |
|||
// Modified by: |
|||
// Created: %DATE% |
|||
// RCS-ID: |
|||
// Copyright: %COPYRIGHT% |
|||
// Licence: |
|||
///////////////////////////////////////////////////////////////////////////// |
|||
|
|||
"</string> |
|||
<string name="cpp_symbols_file_comment">"///////////////////////////////////////////////////////////////////////////// |
|||
// Name: %SYMBOLS-FILENAME% |
|||
// Purpose: Symbols file |
|||
// Author: %AUTHOR% |
|||
// Modified by: |
|||
// Created: %DATE% |
|||
// RCS-ID: |
|||
// Copyright: %COPYRIGHT% |
|||
// Licence: |
|||
///////////////////////////////////////////////////////////////////////////// |
|||
|
|||
"</string> |
|||
<string name="cpp_header_preamble">"#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) |
|||
#pragma interface "%HEADER-FILENAME%" |
|||
#endif |
|||
|
|||
"</string> |
|||
<string name="cpp_implementation_preamble">"#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) |
|||
#pragma implementation "%HEADER-FILENAME%" |
|||
#endif |
|||
|
|||
// For compilers that support precompilation, includes "wx/wx.h". |
|||
#include "wx/wxprec.h" |
|||
|
|||
#ifdef __BORLANDC__ |
|||
#pragma hdrstop |
|||
#endif |
|||
|
|||
#ifndef WX_PRECOMP |
|||
#include "wx/wx.h" |
|||
#endif |
|||
|
|||
"</string> |
|||
<string name="cpp_function_declaration_comment">" /// %BODY% |
|||
"</string> |
|||
<string name="cpp_function_implementation_comment">" |
|||
/*! |
|||
* %BODY% |
|||
*/ |
|||
|
|||
"</string> |
|||
<string name="resource_file_header">"app_resources.h"</string> |
|||
<string name="resource_file_implementation">"app_resources.cpp"</string> |
|||
<string name="resource_class_name">"AppResources"</string> |
|||
<string name="app_file_header">"app.h"</string> |
|||
<string name="app_file_implementation">"app.cpp"</string> |
|||
<string name="app_class_name">"Application"</string> |
|||
<bool name="generate_app_class">0</bool> |
|||
<string name="external_symbol_filenames">""</string> |
|||
<string name="configuration">"<None>"</string> |
|||
<string name="source_encoding">"iso-8859-1"</string> |
|||
<string name="xrc_encoding">"utf-8"</string> |
|||
<string name="project_encoding">"utf-8"</string> |
|||
<string name="resource_archive">""</string> |
|||
<long name="text_file_type">0</long> |
|||
<bool name="use_tabs">0</bool> |
|||
<long name="indent_size">4</long> |
|||
<string name="whitespace_after_return_type">" "</string> |
|||
<string name="resource_xrc_cpp">""</string> |
|||
<bool name="use_resource_archive">0</bool> |
|||
<bool name="use_generated_xrc_cpp">0</bool> |
|||
<bool name="always_generate_xrc">1</bool> |
|||
<bool name="archive_xrc_files">1</bool> |
|||
<bool name="archive_image_files">1</bool> |
|||
<bool name="archive_all_image_files">0</bool> |
|||
<bool name="xrc_retain_relative_paths">1</bool> |
|||
</header> |
|||
<data> |
|||
<document> |
|||
<string name="title">""</string> |
|||
<string name="type">"data-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">""</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<document> |
|||
<string name="title">"Configurations"</string> |
|||
<string name="type">"config-data-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">""</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="template-name">""</string> |
|||
<bool name="dirty">1</bool> |
|||
<string name="Compiler name">""</string> |
|||
<string name="Build mode">"Debug"</string> |
|||
<string name="Unicode mode">"ANSI"</string> |
|||
<string name="Shared mode">"Static"</string> |
|||
<string name="Modularity">"Modular"</string> |
|||
<string name="GUI mode">"GUI"</string> |
|||
<string name="Toolkit">"wxMSW"</string> |
|||
<string name="Runtime linking">"Dynamic"</string> |
|||
<string name="Use exceptions">"Yes"</string> |
|||
<string name="Use ODBC">"No"</string> |
|||
<string name="Use OpenGL">"No"</string> |
|||
<string name="wxWidgets version">"%WXVERSION%"</string> |
|||
<string name="Executable name">"%EXECUTABLE%"</string> |
|||
<string name="Program arguments">""</string> |
|||
<string name="Working path">"%AUTO%"</string> |
|||
<string name="Output path">"%AUTO%"</string> |
|||
<string name="Objects path">"%AUTO%"</string> |
|||
<string name="Compiler location">"%AUTO%"</string> |
|||
<string name="wxWidgets location">"%AUTO%"</string> |
|||
<string name="C++ command">"%AUTO%"</string> |
|||
<string name="Resource compiler">"%AUTO%"</string> |
|||
<string name="Make command">"%AUTO%"</string> |
|||
<string name="Project makefile">"%AUTO%"</string> |
|||
<string name="wxWidgets makefile">"%AUTO%"</string> |
|||
<string name="Compiler bin path">"%AUTO%"</string> |
|||
<string name="Compiler include path">"%AUTO%"</string> |
|||
<string name="Compiler lib path">"%AUTO%"</string> |
|||
<string name="Preprocessor flags">"%AUTO%"</string> |
|||
<string name="Optimizations">"%AUTO%"</string> |
|||
<string name="Warnings">"%AUTO%"</string> |
|||
<string name="Debug flags">"%AUTO%"</string> |
|||
<string name="Libraries">"%AUTO%"</string> |
|||
<string name="Library path">"%AUTO%"</string> |
|||
<string name="Linker flags">"%AUTO%"</string> |
|||
<string name="Include path">"%AUTO%"</string> |
|||
<string name="Resource flags">"%AUTO%"</string> |
|||
<string name="Resource path">"%AUTO%"</string> |
|||
<string name="wxWidgets build path">"%AUTO%"</string> |
|||
<string name="wxWidgets build command">"%AUTO%"</string> |
|||
<string name="wxWidgets clean command">"%AUTO%"</string> |
|||
<string name="PATH variable">"%AUTO%"</string> |
|||
</document> |
|||
</document> |
|||
</data> |
|||
|
|||
<documents> |
|||
<document> |
|||
<string name="title">"Projects"</string> |
|||
<string name="type">"root-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"project"</string> |
|||
<long name="is-transient">1</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">1</long> |
|||
<document> |
|||
<string name="title">"Windows"</string> |
|||
<string name="type">"html-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"dialogsfolder"</string> |
|||
<long name="is-transient">1</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">1</long> |
|||
<document> |
|||
<string name="title">"Cleaning options"</string> |
|||
<string name="type">"dialog-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"dialog"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="created">"25/5/2007"</string> |
|||
<string name="proxy-type">"wbDialogProxy"</string> |
|||
<long name="base-id">10000</long> |
|||
<bool name="use-id-prefix">0</bool> |
|||
<string name="id-prefix">""</string> |
|||
<bool name="use-id-suffix">0</bool> |
|||
<string name="id-suffix">""</string> |
|||
<long name="use-xrc">0</long> |
|||
<string name="event-handler-0">"wxEVT_CLOSE_WINDOW|OnCloseWindow|NONE||"</string> |
|||
<string name="proxy-Id name">"ID_WIN_EDA_CLEANINGOPTIONSFRAME"</string> |
|||
<long name="proxy-Id value">10000</long> |
|||
<string name="proxy-Class">"WinEDA_CleaningOptionsFrame"</string> |
|||
<string name="proxy-Base class">"wxDialog"</string> |
|||
<string name="proxy-Window kind">"wxDialog"</string> |
|||
<string name="proxy-Implementation filename">"cleaningoptions_dialog.cpp"</string> |
|||
<string name="proxy-Header filename">"cleaningoptions_dialog.h"</string> |
|||
<string name="proxy-XRC filename">""</string> |
|||
<string name="proxy-Title">"Cleaning options"</string> |
|||
<bool name="proxy-Centre">1</bool> |
|||
<string name="proxy-Icon">""</string> |
|||
<bool name="proxy-Dialog units">0</bool> |
|||
<string name="proxy-Help text">""</string> |
|||
<string name="proxy-Tooltip text">""</string> |
|||
<string name="proxy-Background colour">""</string> |
|||
<string name="proxy-Foreground colour">""</string> |
|||
<string name="proxy-Font">""</string> |
|||
<bool name="proxy-Hidden">0</bool> |
|||
<bool name="proxy-Enabled">1</bool> |
|||
<string name="proxy-Platform">"<Any platform>"</string> |
|||
<bool name="proxy-wxDEFAULT_DIALOG_STYLE">0</bool> |
|||
<bool name="proxy-wxCAPTION">1</bool> |
|||
<bool name="proxy-wxRESIZE_BORDER">1</bool> |
|||
<bool name="proxy-wxTHICK_FRAME">0</bool> |
|||
<bool name="proxy-wxSYSTEM_MENU">1</bool> |
|||
<bool name="proxy-wxSTAY_ON_TOP">0</bool> |
|||
<bool name="proxy-wxDIALOG_NO_PARENT">0</bool> |
|||
<bool name="proxy-wxCLOSE_BOX">1</bool> |
|||
<bool name="proxy-wxMAXIMIZE_BOX">0</bool> |
|||
<bool name="proxy-wxMINIMIZE_BOX">0</bool> |
|||
<bool name="proxy-wxDIALOG_MODAL">1</bool> |
|||
<bool name="proxy-wxNO_BORDER">0</bool> |
|||
<bool name="proxy-wxSIMPLE_BORDER">0</bool> |
|||
<bool name="proxy-wxDOUBLE_BORDER">0</bool> |
|||
<bool name="proxy-wxSUNKEN_BORDER">0</bool> |
|||
<bool name="proxy-wxRAISED_BORDER">0</bool> |
|||
<bool name="proxy-wxSTATIC_BORDER">0</bool> |
|||
<bool name="proxy-wxWANTS_CHARS">0</bool> |
|||
<bool name="proxy-wxNO_FULL_REPAINT_ON_RESIZE">0</bool> |
|||
<bool name="proxy-wxFULL_REPAINT_ON_RESIZE">0</bool> |
|||
<bool name="proxy-wxCLIP_CHILDREN">0</bool> |
|||
<bool name="proxy-wxTAB_TRAVERSAL">0</bool> |
|||
<bool name="proxy-wxWS_EX_VALIDATE_RECURSIVELY">0</bool> |
|||
<bool name="proxy-wxWS_EX_BLOCK_EVENTS">1</bool> |
|||
<bool name="proxy-wxWS_EX_TRANSIENT">0</bool> |
|||
<string name="proxy-Custom styles">""</string> |
|||
<bool name="proxy-wxDIALOG_EX_CONTEXTHELP">0</bool> |
|||
<bool name="proxy-Fit to content">1</bool> |
|||
<long name="proxy-X">-1</long> |
|||
<long name="proxy-Y">-1</long> |
|||
<long name="proxy-Width">400</long> |
|||
<long name="proxy-Height">300</long> |
|||
<bool name="proxy-AUI manager">0</bool> |
|||
<string name="proxy-Event sources">""</string> |
|||
<document> |
|||
<string name="title">"wxBoxSizer V"</string> |
|||
<string name="type">"dialog-control-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"sizer"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="proxy-type">"wbBoxSizerProxy"</string> |
|||
<string name="proxy-Orientation">"Vertical"</string> |
|||
<string name="proxy-Member variable name">""</string> |
|||
<bool name="proxy-wxSHAPED">0</bool> |
|||
<bool name="proxy-wxADJUST_MINSIZE">0</bool> |
|||
<bool name="proxy-wxFIXED_MINSIZE">0</bool> |
|||
<string name="proxy-Platform">"<Any platform>"</string> |
|||
<document> |
|||
<string name="title">"wxBoxSizer H"</string> |
|||
<string name="type">"dialog-control-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"sizer"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="created">"25/5/2007"</string> |
|||
<string name="proxy-type">"wbBoxSizerProxy"</string> |
|||
<string name="proxy-Orientation">"Horizontal"</string> |
|||
<string name="proxy-Member variable name">""</string> |
|||
<string name="proxy-AlignH">"Centre"</string> |
|||
<string name="proxy-AlignV">"Centre"</string> |
|||
<long name="proxy-Stretch factor">0</long> |
|||
<long name="proxy-Border">5</long> |
|||
<bool name="proxy-wxLEFT">1</bool> |
|||
<bool name="proxy-wxRIGHT">1</bool> |
|||
<bool name="proxy-wxTOP">1</bool> |
|||
<bool name="proxy-wxBOTTOM">1</bool> |
|||
<bool name="proxy-wxSHAPED">0</bool> |
|||
<bool name="proxy-wxADJUST_MINSIZE">0</bool> |
|||
<bool name="proxy-wxFIXED_MINSIZE">0</bool> |
|||
<string name="proxy-Platform">"<Any platform>"</string> |
|||
<document> |
|||
<string name="title">"wxStaticBoxSizer V"</string> |
|||
<string name="type">"dialog-control-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"sizer"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="created">"25/5/2007"</string> |
|||
<string name="proxy-type">"wbStaticBoxSizerProxy"</string> |
|||
<string name="proxy-Id name">"wxID_ANY"</string> |
|||
<long name="proxy-Id value">-1</long> |
|||
<string name="proxy-Label">"Static"</string> |
|||
<string name="proxy-Member variable name">""</string> |
|||
<string name="proxy-Sizer member variable name">""</string> |
|||
<string name="proxy-Foreground colour">""</string> |
|||
<string name="proxy-Font">""</string> |
|||
<bool name="proxy-Hidden">0</bool> |
|||
<bool name="proxy-Enabled">1</bool> |
|||
<string name="proxy-Static box class">"wxStaticBox"</string> |
|||
<string name="proxy-Orientation">"Vertical"</string> |
|||
<string name="proxy-AlignH">"Centre"</string> |
|||
<string name="proxy-AlignV">"Centre"</string> |
|||
<long name="proxy-Stretch factor">0</long> |
|||
<long name="proxy-Border">5</long> |
|||
<bool name="proxy-wxLEFT">1</bool> |
|||
<bool name="proxy-wxRIGHT">1</bool> |
|||
<bool name="proxy-wxTOP">1</bool> |
|||
<bool name="proxy-wxBOTTOM">1</bool> |
|||
<bool name="proxy-wxSHAPED">0</bool> |
|||
<bool name="proxy-wxADJUST_MINSIZE">0</bool> |
|||
<bool name="proxy-wxFIXED_MINSIZE">0</bool> |
|||
<string name="proxy-Platform">"<Any platform>"</string> |
|||
<document> |
|||
<string name="title">"wxCheckBox: ID_CHECKBOX_CLEAN_VIAS"</string> |
|||
<string name="type">"dialog-control-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"checkbox"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="created">"25/5/2007"</string> |
|||
<string name="proxy-type">"wbCheckBoxProxy"</string> |
|||
<string name="proxy-Id name">"ID_CHECKBOX_CLEAN_VIAS"</string> |
|||
<long name="proxy-Id value">10001</long> |
|||
<string name="proxy-Class">"wxCheckBox"</string> |
|||
<string name="proxy-Base class">"wxCheckBox"</string> |
|||
<bool name="proxy-External implementation">1</bool> |
|||
<bool name="proxy-Separate files">0</bool> |
|||
<string name="proxy-Implementation filename">""</string> |
|||
<string name="proxy-Header filename">""</string> |
|||
<string name="proxy-Member variable name">"m_CleanViasOpt"</string> |
|||
<string name="proxy-Label">"Delete redundant vias"</string> |
|||
<bool name="proxy-Initial value">0</bool> |
|||
<string name="proxy-Help text">""</string> |
|||
<string name="proxy-Tooltip text">""</string> |
|||
<string name="proxy-Data variable">"s_CleanVias"</string> |
|||
<string name="proxy-Data validator">"wxGenericValidator(& %VARIABLE%)"</string> |
|||
<string name="proxy-Background colour">""</string> |
|||
<string name="proxy-Foreground colour">""</string> |
|||
<string name="proxy-Font">""</string> |
|||
<bool name="proxy-Hidden">0</bool> |
|||
<bool name="proxy-Enabled">1</bool> |
|||
<string name="proxy-Platform">"<Any platform>"</string> |
|||
<bool name="proxy-wxALIGN_RIGHT">0</bool> |
|||
<bool name="proxy-wxCHK_2STATE">0</bool> |
|||
<bool name="proxy-wxCHK_3STATE">0</bool> |
|||
<bool name="proxy-wxCHK_ALLOW_3RD_STATE_FOR_USER">0</bool> |
|||
<bool name="proxy-wxWANTS_CHARS">0</bool> |
|||
<bool name="proxy-wxNO_FULL_REPAINT_ON_RESIZE">0</bool> |
|||
<bool name="proxy-wxFULL_REPAINT_ON_RESIZE">0</bool> |
|||
<string name="proxy-Custom styles">""</string> |
|||
<long name="proxy-X">-1</long> |
|||
<long name="proxy-Y">-1</long> |
|||
<long name="proxy-Width">-1</long> |
|||
<long name="proxy-Height">-1</long> |
|||
<string name="proxy-AlignH">"Left"</string> |
|||
<string name="proxy-AlignV">"Centre"</string> |
|||
<long name="proxy-Stretch factor">0</long> |
|||
<long name="proxy-Border">5</long> |
|||
<bool name="proxy-wxLEFT">1</bool> |
|||
<bool name="proxy-wxRIGHT">1</bool> |
|||
<bool name="proxy-wxTOP">1</bool> |
|||
<bool name="proxy-wxBOTTOM">1</bool> |
|||
<bool name="proxy-wxSHAPED">0</bool> |
|||
<bool name="proxy-wxADJUST_MINSIZE">0</bool> |
|||
<bool name="proxy-wxFIXED_MINSIZE">0</bool> |
|||
<string name="proxy-Custom arguments">""</string> |
|||
<string name="proxy-Custom ctor arguments">""</string> |
|||
</document> |
|||
<document> |
|||
<string name="title">"wxCheckBox: ID_CHECKBOX_MERGE_SEGMENTS"</string> |
|||
<string name="type">"dialog-control-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"checkbox"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="created">"25/5/2007"</string> |
|||
<string name="proxy-type">"wbCheckBoxProxy"</string> |
|||
<string name="proxy-Id name">"ID_CHECKBOX_MERGE_SEGMENTS"</string> |
|||
<long name="proxy-Id value">10003</long> |
|||
<string name="proxy-Class">"wxCheckBox"</string> |
|||
<string name="proxy-Base class">"wxCheckBox"</string> |
|||
<bool name="proxy-External implementation">1</bool> |
|||
<bool name="proxy-Separate files">0</bool> |
|||
<string name="proxy-Implementation filename">""</string> |
|||
<string name="proxy-Header filename">""</string> |
|||
<string name="proxy-Member variable name">"m_MergetSegmOpt"</string> |
|||
<string name="proxy-Label">"Merge segments"</string> |
|||
<bool name="proxy-Initial value">0</bool> |
|||
<string name="proxy-Help text">""</string> |
|||
<string name="proxy-Tooltip text">""</string> |
|||
<string name="proxy-Data variable">"s_MergeSegments"</string> |
|||
<string name="proxy-Data validator">"wxGenericValidator(& %VARIABLE%)"</string> |
|||
<string name="proxy-Background colour">""</string> |
|||
<string name="proxy-Foreground colour">""</string> |
|||
<string name="proxy-Font">""</string> |
|||
<bool name="proxy-Hidden">0</bool> |
|||
<bool name="proxy-Enabled">1</bool> |
|||
<string name="proxy-Platform">"<Any platform>"</string> |
|||
<bool name="proxy-wxALIGN_RIGHT">0</bool> |
|||
<bool name="proxy-wxCHK_2STATE">0</bool> |
|||
<bool name="proxy-wxCHK_3STATE">0</bool> |
|||
<bool name="proxy-wxCHK_ALLOW_3RD_STATE_FOR_USER">0</bool> |
|||
<bool name="proxy-wxWANTS_CHARS">0</bool> |
|||
<bool name="proxy-wxNO_FULL_REPAINT_ON_RESIZE">0</bool> |
|||
<bool name="proxy-wxFULL_REPAINT_ON_RESIZE">0</bool> |
|||
<string name="proxy-Custom styles">""</string> |
|||
<long name="proxy-X">-1</long> |
|||
<long name="proxy-Y">-1</long> |
|||
<long name="proxy-Width">-1</long> |
|||
<long name="proxy-Height">-1</long> |
|||
<string name="proxy-AlignH">"Left"</string> |
|||
<string name="proxy-AlignV">"Centre"</string> |
|||
<long name="proxy-Stretch factor">0</long> |
|||
<long name="proxy-Border">5</long> |
|||
<bool name="proxy-wxLEFT">1</bool> |
|||
<bool name="proxy-wxRIGHT">1</bool> |
|||
<bool name="proxy-wxTOP">1</bool> |
|||
<bool name="proxy-wxBOTTOM">1</bool> |
|||
<bool name="proxy-wxSHAPED">0</bool> |
|||
<bool name="proxy-wxADJUST_MINSIZE">0</bool> |
|||
<bool name="proxy-wxFIXED_MINSIZE">0</bool> |
|||
<string name="proxy-Custom arguments">""</string> |
|||
<string name="proxy-Custom ctor arguments">""</string> |
|||
</document> |
|||
<document> |
|||
<string name="title">"wxCheckBox: ID_CHECKBOX1"</string> |
|||
<string name="type">"dialog-control-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"checkbox"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="created">"25/5/2007"</string> |
|||
<string name="proxy-type">"wbCheckBoxProxy"</string> |
|||
<string name="proxy-Id name">"ID_CHECKBOX1"</string> |
|||
<long name="proxy-Id value">10005</long> |
|||
<string name="proxy-Class">"wxCheckBox"</string> |
|||
<string name="proxy-Base class">"wxCheckBox"</string> |
|||
<bool name="proxy-External implementation">1</bool> |
|||
<bool name="proxy-Separate files">0</bool> |
|||
<string name="proxy-Implementation filename">""</string> |
|||
<string name="proxy-Header filename">""</string> |
|||
<string name="proxy-Member variable name">"m_DeleteunconnectedOpt"</string> |
|||
<string name="proxy-Label">"Delete unconnected tracks"</string> |
|||
<bool name="proxy-Initial value">0</bool> |
|||
<string name="proxy-Help text">""</string> |
|||
<string name="proxy-Tooltip text">""</string> |
|||
<string name="proxy-Data variable">"s_DeleteUnconnectedSegm"</string> |
|||
<string name="proxy-Data validator">"wxGenericValidator(& %VARIABLE%)"</string> |
|||
<string name="proxy-Background colour">""</string> |
|||
<string name="proxy-Foreground colour">""</string> |
|||
<string name="proxy-Font">""</string> |
|||
<bool name="proxy-Hidden">0</bool> |
|||
<bool name="proxy-Enabled">1</bool> |
|||
<string name="proxy-Platform">"<Any platform>"</string> |
|||
<bool name="proxy-wxALIGN_RIGHT">0</bool> |
|||
<bool name="proxy-wxCHK_2STATE">0</bool> |
|||
<bool name="proxy-wxCHK_3STATE">0</bool> |
|||
<bool name="proxy-wxCHK_ALLOW_3RD_STATE_FOR_USER">0</bool> |
|||
<bool name="proxy-wxWANTS_CHARS">0</bool> |
|||
<bool name="proxy-wxNO_FULL_REPAINT_ON_RESIZE">0</bool> |
|||
<bool name="proxy-wxFULL_REPAINT_ON_RESIZE">0</bool> |
|||
<string name="proxy-Custom styles">""</string> |
|||
<long name="proxy-X">-1</long> |
|||
<long name="proxy-Y">-1</long> |
|||
<long name="proxy-Width">-1</long> |
|||
<long name="proxy-Height">-1</long> |
|||
<string name="proxy-AlignH">"Left"</string> |
|||
<string name="proxy-AlignV">"Centre"</string> |
|||
<long name="proxy-Stretch factor">0</long> |
|||
<long name="proxy-Border">5</long> |
|||
<bool name="proxy-wxLEFT">1</bool> |
|||
<bool name="proxy-wxRIGHT">1</bool> |
|||
<bool name="proxy-wxTOP">1</bool> |
|||
<bool name="proxy-wxBOTTOM">1</bool> |
|||
<bool name="proxy-wxSHAPED">0</bool> |
|||
<bool name="proxy-wxADJUST_MINSIZE">0</bool> |
|||
<bool name="proxy-wxFIXED_MINSIZE">0</bool> |
|||
<string name="proxy-Custom arguments">""</string> |
|||
<string name="proxy-Custom ctor arguments">""</string> |
|||
</document> |
|||
<document> |
|||
<string name="title">"wxCheckBox: ID_CHECKBOX"</string> |
|||
<string name="type">"dialog-control-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"checkbox"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="created">"25/5/2007"</string> |
|||
<string name="proxy-type">"wbCheckBoxProxy"</string> |
|||
<string name="proxy-Id name">"ID_CHECKBOX"</string> |
|||
<long name="proxy-Id value">10004</long> |
|||
<string name="proxy-Class">"wxCheckBox"</string> |
|||
<string name="proxy-Base class">"wxCheckBox"</string> |
|||
<bool name="proxy-External implementation">1</bool> |
|||
<bool name="proxy-Separate files">0</bool> |
|||
<string name="proxy-Implementation filename">""</string> |
|||
<string name="proxy-Header filename">""</string> |
|||
<string name="proxy-Member variable name">"m_ConnectToPadsOpt"</string> |
|||
<string name="proxy-Label">"Connect to Pads"</string> |
|||
<bool name="proxy-Initial value">0</bool> |
|||
<string name="proxy-Help text">""</string> |
|||
<string name="proxy-Tooltip text">""</string> |
|||
<string name="proxy-Data variable">""</string> |
|||
<string name="proxy-Data validator">""</string> |
|||
<string name="proxy-Background colour">""</string> |
|||
<string name="proxy-Foreground colour">""</string> |
|||
<string name="proxy-Font">""</string> |
|||
<bool name="proxy-Hidden">0</bool> |
|||
<bool name="proxy-Enabled">1</bool> |
|||
<string name="proxy-Platform">"<Any platform>"</string> |
|||
<bool name="proxy-wxALIGN_RIGHT">0</bool> |
|||
<bool name="proxy-wxCHK_2STATE">0</bool> |
|||
<bool name="proxy-wxCHK_3STATE">0</bool> |
|||
<bool name="proxy-wxCHK_ALLOW_3RD_STATE_FOR_USER">0</bool> |
|||
<bool name="proxy-wxWANTS_CHARS">0</bool> |
|||
<bool name="proxy-wxNO_FULL_REPAINT_ON_RESIZE">0</bool> |
|||
<bool name="proxy-wxFULL_REPAINT_ON_RESIZE">0</bool> |
|||
<string name="proxy-Custom styles">""</string> |
|||
<long name="proxy-X">-1</long> |
|||
<long name="proxy-Y">-1</long> |
|||
<long name="proxy-Width">-1</long> |
|||
<long name="proxy-Height">-1</long> |
|||
<string name="proxy-AlignH">"Left"</string> |
|||
<string name="proxy-AlignV">"Centre"</string> |
|||
<long name="proxy-Stretch factor">0</long> |
|||
<long name="proxy-Border">5</long> |
|||
<bool name="proxy-wxLEFT">1</bool> |
|||
<bool name="proxy-wxRIGHT">1</bool> |
|||
<bool name="proxy-wxTOP">1</bool> |
|||
<bool name="proxy-wxBOTTOM">1</bool> |
|||
<bool name="proxy-wxSHAPED">0</bool> |
|||
<bool name="proxy-wxADJUST_MINSIZE">0</bool> |
|||
<bool name="proxy-wxFIXED_MINSIZE">0</bool> |
|||
<string name="proxy-Custom arguments">""</string> |
|||
<string name="proxy-Custom ctor arguments">""</string> |
|||
</document> |
|||
</document> |
|||
<document> |
|||
<string name="title">"wxBoxSizer V"</string> |
|||
<string name="type">"dialog-control-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"sizer"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="created">"25/5/2007"</string> |
|||
<string name="proxy-type">"wbBoxSizerProxy"</string> |
|||
<string name="proxy-Orientation">"Vertical"</string> |
|||
<string name="proxy-Member variable name">""</string> |
|||
<string name="proxy-AlignH">"Centre"</string> |
|||
<string name="proxy-AlignV">"Centre"</string> |
|||
<long name="proxy-Stretch factor">0</long> |
|||
<long name="proxy-Border">5</long> |
|||
<bool name="proxy-wxLEFT">1</bool> |
|||
<bool name="proxy-wxRIGHT">1</bool> |
|||
<bool name="proxy-wxTOP">1</bool> |
|||
<bool name="proxy-wxBOTTOM">1</bool> |
|||
<bool name="proxy-wxSHAPED">0</bool> |
|||
<bool name="proxy-wxADJUST_MINSIZE">0</bool> |
|||
<bool name="proxy-wxFIXED_MINSIZE">0</bool> |
|||
<string name="proxy-Platform">"<Any platform>"</string> |
|||
<document> |
|||
<string name="title">"wxButton: ID_BUTTON_EXECUTE"</string> |
|||
<string name="type">"dialog-control-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"dialogcontrol"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">0</long> |
|||
<string name="created">"25/5/2007"</string> |
|||
<string name="proxy-type">"wbButtonProxy"</string> |
|||
<string name="event-handler-0">"wxEVT_COMMAND_BUTTON_CLICKED|OnButtonExecuteClick|NONE||"</string> |
|||
<string name="proxy-Id name">"ID_BUTTON_EXECUTE"</string> |
|||
<long name="proxy-Id value">10006</long> |
|||
<string name="proxy-Class">"wxButton"</string> |
|||
<string name="proxy-Base class">"wxButton"</string> |
|||
<bool name="proxy-External implementation">1</bool> |
|||
<bool name="proxy-Separate files">0</bool> |
|||
<string name="proxy-Implementation filename">""</string> |
|||
<string name="proxy-Header filename">""</string> |
|||
<string name="proxy-Member variable name">""</string> |
|||
<string name="proxy-Label">"Clean pcb"</string> |
|||
<bool name="proxy-Default">1</bool> |
|||
<string name="proxy-Help text">""</string> |
|||
<string name="proxy-Tooltip text">""</string> |
|||
<string name="proxy-Background colour">""</string> |
|||
<string name="proxy-Foreground colour">""</string> |
|||
<string name="proxy-Font">""</string> |
|||
<bool name="proxy-Hidden">0</bool> |
|||
<bool name="proxy-Enabled">1</bool> |
|||
<string name="proxy-Platform">"<Any platform>"</string> |
|||
<bool name="proxy-wxBU_LEFT">0</bool> |
|||
<bool name="proxy-wxBU_RIGHT">0</bool> |
|||
<bool name="proxy-wxBU_TOP">0</bool> |
|||
<bool name="proxy-wxBU_BOTTOM">0</bool> |
|||
<bool name="proxy-wxBU_EXACTFIT">0</bool> |
|||
<bool name="proxy-wxNO_BORDER">0</bool> |
|||
<bool name="proxy-wxWANTS_CHARS">0</bool> |
|||
<bool name="proxy-wxNO_FULL_REPAINT_ON_RESIZE">0</bool> |
|||
<bool name="proxy-wxFULL_REPAINT_ON_RESIZE">0</bool> |
|||
<string name="proxy-Custom styles">""</string> |
|||
<long name="proxy-X">-1</long> |
|||
<long name="proxy-Y">-1</long> |
|||
<long name="proxy-Width">-1</long> |
|||
<long name="proxy-Height">-1</long> |
|||
<string name="proxy-AlignH">"Centre"</string> |
|||
<string name="proxy-AlignV">"Centre"</string> |
|||
<long name="proxy-Stretch factor">0</long> |
|||
<long name="proxy-Border">5</long> |
|||
<bool name="proxy-wxLEFT">1</bool> |
|||
<bool name="proxy-wxRIGHT">1</bool> |
|||
<bool name="proxy-wxTOP">1</bool> |
|||
<bool name="proxy-wxBOTTOM">1</bool> |
|||
<bool name="proxy-wxSHAPED">0</bool> |
|||
<bool name="proxy-wxADJUST_MINSIZE">0</bool> |
|||
<bool name="proxy-wxFIXED_MINSIZE">0</bool> |
|||
<string name="proxy-Custom arguments">""</string> |
|||
<string name="proxy-Custom ctor arguments">""</string> |
|||
</document> |
|||
</document> |
|||
</document> |
|||
</document> |
|||
</document> |
|||
</document> |
|||
<document> |
|||
<string name="title">"Sources"</string> |
|||
<string name="type">"html-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"sourcesfolder"</string> |
|||
<long name="is-transient">1</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">1</long> |
|||
<document> |
|||
<string name="title">"dialog_clean_pcb.rc"</string> |
|||
<string name="type">"source-editor-document"</string> |
|||
<string name="filename">"dialog_clean_pcb.rc"</string> |
|||
<string name="icon-name">"source-editor"</string> |
|||
<long name="is-transient">0</long> |
|||
<long name="owns-file">0</long> |
|||
<long name="title-mode">1</long> |
|||
<long name="locked">0</long> |
|||
<string name="created">"25/5/2007"</string> |
|||
<string name="language">""</string> |
|||
</document> |
|||
</document> |
|||
<document> |
|||
<string name="title">"Images"</string> |
|||
<string name="type">"html-document"</string> |
|||
<string name="filename">""</string> |
|||
<string name="icon-name">"bitmapsfolder"</string> |
|||
<long name="is-transient">1</long> |
|||
<long name="owns-file">1</long> |
|||
<long name="title-mode">0</long> |
|||
<long name="locked">1</long> |
|||
</document> |
|||
</document> |
|||
</documents> |
|||
|
|||
</anthemion-project> |
|||
@ -0,0 +1,220 @@ |
|||
/////////////////////////////////////////////////////////////////////////////
|
|||
// Name: win_eda_cleaningoptionsframe.cpp
|
|||
// Purpose:
|
|||
// Author: jean-pierre Charras
|
|||
// Modified by:
|
|||
// Created: 25/05/2007 13:39:29
|
|||
// RCS-ID:
|
|||
// Copyright: GNU License
|
|||
// Licence:
|
|||
/////////////////////////////////////////////////////////////////////////////
|
|||
|
|||
// Generated by DialogBlocks (unregistered), 25/05/2007 13:39:29
|
|||
|
|||
#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
|
|||
#pragma implementation "win_eda_cleaningoptionsframe.h"
|
|||
#endif
|
|||
|
|||
// For compilers that support precompilation, includes "wx/wx.h".
|
|||
#include "wx/wxprec.h"
|
|||
|
|||
#ifdef __BORLANDC__
|
|||
#pragma hdrstop
|
|||
#endif
|
|||
|
|||
#ifndef WX_PRECOMP
|
|||
#include "wx/wx.h"
|
|||
#endif
|
|||
|
|||
////@begin includes
|
|||
////@end includes
|
|||
|
|||
#include "win_eda_cleaningoptionsframe.h"
|
|||
|
|||
////@begin XPM images
|
|||
////@end XPM images
|
|||
|
|||
|
|||
/*!
|
|||
* Win_EDA_CleaningOptionsFrame type definition |
|||
*/ |
|||
|
|||
IMPLEMENT_DYNAMIC_CLASS( Win_EDA_CleaningOptionsFrame, wxDialog ) |
|||
|
|||
|
|||
/*!
|
|||
* Win_EDA_CleaningOptionsFrame event table definition |
|||
*/ |
|||
|
|||
BEGIN_EVENT_TABLE( Win_EDA_CleaningOptionsFrame, wxDialog ) |
|||
|
|||
////@begin Win_EDA_CleaningOptionsFrame event table entries
|
|||
////@end Win_EDA_CleaningOptionsFrame event table entries
|
|||
|
|||
END_EVENT_TABLE() |
|||
|
|||
|
|||
/*!
|
|||
* Win_EDA_CleaningOptionsFrame constructors |
|||
*/ |
|||
|
|||
Win_EDA_CleaningOptionsFrame::Win_EDA_CleaningOptionsFrame() |
|||
{ |
|||
Init(); |
|||
} |
|||
|
|||
Win_EDA_CleaningOptionsFrame::Win_EDA_CleaningOptionsFrame( wxWindow* parent, wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) |
|||
{ |
|||
Init(); |
|||
Create(parent, id, caption, pos, size, style); |
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* Win_EDA_CleaningOptionsFrame creator |
|||
*/ |
|||
|
|||
bool Win_EDA_CleaningOptionsFrame::Create( wxWindow* parent, wxWindowID id, const wxString& caption, const wxPoint& pos, const wxSize& size, long style ) |
|||
{ |
|||
////@begin Win_EDA_CleaningOptionsFrame creation
|
|||
SetExtraStyle(wxWS_EX_BLOCK_EVENTS); |
|||
wxDialog::Create( parent, id, caption, pos, size, style ); |
|||
|
|||
CreateControls(); |
|||
if (GetSizer()) |
|||
{ |
|||
GetSizer()->SetSizeHints(this); |
|||
} |
|||
Centre(); |
|||
////@end Win_EDA_CleaningOptionsFrame creation
|
|||
return true; |
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* Win_EDA_CleaningOptionsFrame destructor |
|||
*/ |
|||
|
|||
Win_EDA_CleaningOptionsFrame::~Win_EDA_CleaningOptionsFrame() |
|||
{ |
|||
////@begin Win_EDA_CleaningOptionsFrame destruction
|
|||
////@end Win_EDA_CleaningOptionsFrame destruction
|
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* Member initialisation |
|||
*/ |
|||
|
|||
void Win_EDA_CleaningOptionsFrame::Init() |
|||
{ |
|||
////@begin Win_EDA_CleaningOptionsFrame member initialisation
|
|||
m_CleanViasOpt = NULL; |
|||
m_MergetSegmOpt = NULL; |
|||
m_DeleteNullSegmOpt = NULL; |
|||
m_DeleteunconnectedOpt = NULL; |
|||
m_ConnectToPadsOpt = NULL; |
|||
////@end Win_EDA_CleaningOptionsFrame member initialisation
|
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* Control creation for Win_EDA_CleaningOptionsFrame |
|||
*/ |
|||
|
|||
void Win_EDA_CleaningOptionsFrame::CreateControls() |
|||
{ |
|||
////@begin Win_EDA_CleaningOptionsFrame content construction
|
|||
// Generated by DialogBlocks, 25/05/2007 13:58:52 (unregistered)
|
|||
|
|||
Win_EDA_CleaningOptionsFrame* itemDialog1 = this; |
|||
|
|||
wxBoxSizer* itemBoxSizer2 = new wxBoxSizer(wxVERTICAL); |
|||
itemDialog1->SetSizer(itemBoxSizer2); |
|||
|
|||
wxBoxSizer* itemBoxSizer3 = new wxBoxSizer(wxHORIZONTAL); |
|||
itemBoxSizer2->Add(itemBoxSizer3, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); |
|||
|
|||
wxStaticBox* itemStaticBoxSizer4Static = new wxStaticBox(itemDialog1, wxID_ANY, _("Static")); |
|||
wxStaticBoxSizer* itemStaticBoxSizer4 = new wxStaticBoxSizer(itemStaticBoxSizer4Static, wxVERTICAL); |
|||
itemBoxSizer3->Add(itemStaticBoxSizer4, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); |
|||
|
|||
m_CleanViasOpt = new wxCheckBox( itemDialog1, ID_CHECKBOX_CLEAN_VIAS, _("Delete redundant vias"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
m_CleanViasOpt->SetValue(true); |
|||
itemStaticBoxSizer4->Add(m_CleanViasOpt, 0, wxALIGN_LEFT|wxALL, 5); |
|||
|
|||
m_MergetSegmOpt = new wxCheckBox( itemDialog1, ID_CHECKBOX_MERGE_SEGMENTS, _("Merge segments"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
m_MergetSegmOpt->SetValue(true); |
|||
itemStaticBoxSizer4->Add(m_MergetSegmOpt, 0, wxALIGN_LEFT|wxALL, 5); |
|||
|
|||
m_DeleteNullSegmOpt = new wxCheckBox( itemDialog1, ID_CHECKBOX_DELETE_NULL_SEGM, _("Delete 0 lenght segments"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
m_DeleteNullSegmOpt->SetValue(true); |
|||
itemStaticBoxSizer4->Add(m_DeleteNullSegmOpt, 0, wxALIGN_LEFT|wxALL, 5); |
|||
|
|||
m_DeleteunconnectedOpt = new wxCheckBox( itemDialog1, ID_CHECKBOX1, _("Delete unconnected tracks"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
m_DeleteunconnectedOpt->SetValue(true); |
|||
itemStaticBoxSizer4->Add(m_DeleteunconnectedOpt, 0, wxALIGN_LEFT|wxALL, 5); |
|||
|
|||
m_ConnectToPadsOpt = new wxCheckBox( itemDialog1, ID_CHECKBOX, _("Connect to Pads"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
m_ConnectToPadsOpt->SetValue(false); |
|||
itemStaticBoxSizer4->Add(m_ConnectToPadsOpt, 0, wxALIGN_LEFT|wxALL, 5); |
|||
|
|||
wxStaticBox* itemStaticBoxSizer10Static = new wxStaticBox(itemDialog1, wxID_ANY, _("Static")); |
|||
wxStaticBoxSizer* itemStaticBoxSizer10 = new wxStaticBoxSizer(itemStaticBoxSizer10Static, wxVERTICAL); |
|||
itemBoxSizer3->Add(itemStaticBoxSizer10, 0, wxALIGN_CENTER_VERTICAL|wxALL, 5); |
|||
|
|||
wxButton* itemButton11 = new wxButton( itemDialog1, ID_BUTTON_EXECUTE, _("Clean pcb"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
itemButton11->SetDefault(); |
|||
itemStaticBoxSizer10->Add(itemButton11, 0, wxALIGN_CENTER_HORIZONTAL|wxALL, 5); |
|||
|
|||
itemBoxSizer2->Add(5, 5, 0, wxGROW|wxALL, 5); |
|||
|
|||
wxStaticText* itemStaticText13 = new wxStaticText( itemDialog1, wxID_STATIC, _("Infos:"), wxDefaultPosition, wxDefaultSize, 0 ); |
|||
itemBoxSizer2->Add(itemStaticText13, 0, wxALIGN_LEFT|wxLEFT|wxRIGHT|wxTOP|wxADJUST_MINSIZE, 5); |
|||
|
|||
wxTextCtrl* itemTextCtrl14 = new wxTextCtrl( itemDialog1, ID_TEXTCTRL1, _T(""), wxDefaultPosition, wxSize(-1, 120), wxTE_MULTILINE ); |
|||
itemBoxSizer2->Add(itemTextCtrl14, 0, wxGROW|wxALL, 5); |
|||
|
|||
// Set validators
|
|||
m_CleanViasOpt->SetValidator( wxGenericValidator(& s_CleanVias) ); |
|||
m_MergetSegmOpt->SetValidator( wxGenericValidator(& s_MergeSegments) ); |
|||
m_DeleteNullSegmOpt->SetValidator( wxGenericValidator(& s_Delete0lenSegm) ); |
|||
m_DeleteunconnectedOpt->SetValidator( wxGenericValidator(& s_DeleteUnconnectedSegm) ); |
|||
////@end Win_EDA_CleaningOptionsFrame content construction
|
|||
} |
|||
|
|||
|
|||
/*!
|
|||
* Should we show tooltips? |
|||
*/ |
|||
|
|||
bool Win_EDA_CleaningOptionsFrame::ShowToolTips() |
|||
{ |
|||
return true; |
|||
} |
|||
|
|||
/*!
|
|||
* Get bitmap resources |
|||
*/ |
|||
|
|||
wxBitmap Win_EDA_CleaningOptionsFrame::GetBitmapResource( const wxString& name ) |
|||
{ |
|||
// Bitmap retrieval
|
|||
////@begin Win_EDA_CleaningOptionsFrame bitmap retrieval
|
|||
wxUnusedVar(name); |
|||
return wxNullBitmap; |
|||
////@end Win_EDA_CleaningOptionsFrame bitmap retrieval
|
|||
} |
|||
|
|||
/*!
|
|||
* Get icon resources |
|||
*/ |
|||
|
|||
wxIcon Win_EDA_CleaningOptionsFrame::GetIconResource( const wxString& name ) |
|||
{ |
|||
// Icon retrieval
|
|||
////@begin Win_EDA_CleaningOptionsFrame icon retrieval
|
|||
wxUnusedVar(name); |
|||
return wxNullIcon; |
|||
////@end Win_EDA_CleaningOptionsFrame icon retrieval
|
|||
} |
|||
@ -0,0 +1,109 @@ |
|||
///////////////////////////////////////////////////////////////////////////// |
|||
// Name: win_eda_cleaningoptionsframe.h |
|||
// Purpose: |
|||
// Author: jean-pierre Charras |
|||
// Modified by: |
|||
// Created: 25/05/2007 13:39:29 |
|||
// RCS-ID: |
|||
// Copyright: GNU License |
|||
// Licence: |
|||
///////////////////////////////////////////////////////////////////////////// |
|||
|
|||
// Generated by DialogBlocks (unregistered), 25/05/2007 13:39:29 |
|||
|
|||
#ifndef _WIN_EDA_CLEANINGOPTIONSFRAME_H_ |
|||
#define _WIN_EDA_CLEANINGOPTIONSFRAME_H_ |
|||
|
|||
#if defined(__GNUG__) && !defined(NO_GCC_PRAGMA) |
|||
#pragma interface "win_eda_cleaningoptionsframe.h" |
|||
#endif |
|||
|
|||
/*! |
|||
* Includes |
|||
*/ |
|||
|
|||
////@begin includes |
|||
#include "wx/valgen.h" |
|||
////@end includes |
|||
|
|||
/*! |
|||
* Forward declarations |
|||
*/ |
|||
|
|||
////@begin forward declarations |
|||
////@end forward declarations |
|||
|
|||
/*! |
|||
* Control identifiers |
|||
*/ |
|||
|
|||
////@begin control identifiers |
|||
#define ID_WIN_EDA_CLEANINGOPTIONSFRAME 10000 |
|||
#define ID_CHECKBOX_CLEAN_VIAS 10001 |
|||
#define ID_CHECKBOX_MERGE_SEGMENTS 10003 |
|||
#define ID_CHECKBOX_DELETE_NULL_SEGM 10002 |
|||
#define ID_CHECKBOX1 10005 |
|||
#define ID_CHECKBOX 10004 |
|||
#define ID_BUTTON_EXECUTE 10006 |
|||
#define ID_TEXTCTRL1 10007 |
|||
#define SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_STYLE wxCAPTION|wxRESIZE_BORDER|wxSYSTEM_MENU|wxCLOSE_BOX |
|||
#define SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_TITLE _("Cleaning options") |
|||
#define SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_IDNAME ID_WIN_EDA_CLEANINGOPTIONSFRAME |
|||
#define SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_SIZE wxSize(400, 300) |
|||
#define SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_POSITION wxDefaultPosition |
|||
////@end control identifiers |
|||
|
|||
|
|||
/*! |
|||
* Win_EDA_CleaningOptionsFrame class declaration |
|||
*/ |
|||
|
|||
class Win_EDA_CleaningOptionsFrame: public wxDialog |
|||
{ |
|||
DECLARE_DYNAMIC_CLASS( Win_EDA_CleaningOptionsFrame ) |
|||
DECLARE_EVENT_TABLE() |
|||
|
|||
public: |
|||
/// Constructors |
|||
Win_EDA_CleaningOptionsFrame(); |
|||
Win_EDA_CleaningOptionsFrame( wxWindow* parent, wxWindowID id = SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_IDNAME, const wxString& caption = SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_TITLE, const wxPoint& pos = SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_POSITION, const wxSize& size = SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_SIZE, long style = SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_STYLE ); |
|||
|
|||
/// Creation |
|||
bool Create( wxWindow* parent, wxWindowID id = SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_IDNAME, const wxString& caption = SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_TITLE, const wxPoint& pos = SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_POSITION, const wxSize& size = SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_SIZE, long style = SYMBOL_WIN_EDA_CLEANINGOPTIONSFRAME_STYLE ); |
|||
|
|||
/// Destructor |
|||
~Win_EDA_CleaningOptionsFrame(); |
|||
|
|||
/// Initialises member variables |
|||
void Init(); |
|||
|
|||
/// Creates the controls and sizers |
|||
void CreateControls(); |
|||
|
|||
////@begin Win_EDA_CleaningOptionsFrame event handler declarations |
|||
|
|||
////@end Win_EDA_CleaningOptionsFrame event handler declarations |
|||
|
|||
////@begin Win_EDA_CleaningOptionsFrame member function declarations |
|||
|
|||
/// Retrieves bitmap resources |
|||
wxBitmap GetBitmapResource( const wxString& name ); |
|||
|
|||
/// Retrieves icon resources |
|||
wxIcon GetIconResource( const wxString& name ); |
|||
////@end Win_EDA_CleaningOptionsFrame member function declarations |
|||
|
|||
/// Should we show tooltips? |
|||
static bool ShowToolTips(); |
|||
|
|||
////@begin Win_EDA_CleaningOptionsFrame member variables |
|||
wxCheckBox* m_CleanViasOpt; |
|||
wxCheckBox* m_MergetSegmOpt; |
|||
wxCheckBox* m_DeleteNullSegmOpt; |
|||
wxCheckBox* m_DeleteunconnectedOpt; |
|||
wxCheckBox* m_ConnectToPadsOpt; |
|||
////@end Win_EDA_CleaningOptionsFrame member variables |
|||
}; |
|||
|
|||
#endif |
|||
// _WIN_EDA_CLEANINGOPTIONSFRAME_H_ |
|||
Write
Preview
Loading…
Cancel
Save
Reference in new issue