diff --git a/common/base_struct.cpp b/common/base_struct.cpp
index 2f255dd54b..e9376ec0ff 100644
--- a/common/base_struct.cpp
+++ b/common/base_struct.cpp
@@ -1,7 +1,7 @@
/****************************************/
/* Basic classes for Kicad: */
/* EDA_ITEM */
-/* EDA_TextStruct */
+/* EDA_TEXT */
/****************************************/
#include "fctsys.h"
@@ -180,9 +180,9 @@ std::ostream& EDA_ITEM::NestedSpace( int nestLevel, std::ostream& os )
/**************************************************/
-/* EDA_TextStruct (basic class, not directly used */
+/* EDA_TEXT (basic class, not directly used */
/**************************************************/
-EDA_TextStruct::EDA_TextStruct( const wxString& text )
+EDA_TEXT::EDA_TEXT( const wxString& text )
{
m_Size.x = m_Size.y = DEFAULT_SIZE_TEXT; // Width and height of font.
m_Orient = 0; // Rotation angle in 0.1 degrees.
@@ -198,7 +198,7 @@ EDA_TextStruct::EDA_TextStruct( const wxString& text )
}
-EDA_TextStruct::EDA_TextStruct( const EDA_TextStruct& aText )
+EDA_TEXT::EDA_TEXT( const EDA_TEXT& aText )
{
m_Pos = aText.m_Pos;
m_Size = aText.m_Size;
@@ -215,20 +215,20 @@ EDA_TextStruct::EDA_TextStruct( const EDA_TextStruct& aText )
}
-EDA_TextStruct::~EDA_TextStruct()
+EDA_TEXT::~EDA_TEXT()
{
}
-int EDA_TextStruct::LenSize( const wxString& aLine ) const
+int EDA_TEXT::LenSize( const wxString& aLine ) const
{
return ReturnGraphicTextWidth(aLine, m_Size.x, m_Italic, m_Bold ) + m_Thickness;
}
-EDA_Rect EDA_TextStruct::GetTextBox( int aLine, int aThickness, bool aInvertY ) const
+EDA_RECT EDA_TEXT::GetTextBox( int aLine, int aThickness, bool aInvertY ) const
{
- EDA_Rect rect;
+ EDA_RECT rect;
wxPoint pos;
wxArrayString* list = NULL;
wxString text = m_Text;
@@ -322,9 +322,9 @@ EDA_Rect EDA_TextStruct::GetTextBox( int aLine, int aThickness, bool aInvertY )
}
-bool EDA_TextStruct::TextHitTest( const wxPoint& aPoint, int aAccuracy ) const
+bool EDA_TEXT::TextHitTest( const wxPoint& aPoint, int aAccuracy ) const
{
- EDA_Rect rect = GetTextBox( -1 ); // Get the full text area.
+ EDA_RECT rect = GetTextBox( -1 ); // Get the full text area.
wxPoint location = aPoint;
rect.Inflate( aAccuracy );
@@ -334,9 +334,9 @@ bool EDA_TextStruct::TextHitTest( const wxPoint& aPoint, int aAccuracy ) const
}
-bool EDA_TextStruct::TextHitTest( const EDA_Rect& aRect, bool aContains, int aAccuracy ) const
+bool EDA_TEXT::TextHitTest( const EDA_RECT& aRect, bool aContains, int aAccuracy ) const
{
- EDA_Rect rect = aRect;
+ EDA_RECT rect = aRect;
rect.Inflate( aAccuracy );
@@ -347,7 +347,7 @@ bool EDA_TextStruct::TextHitTest( const EDA_Rect& aRect, bool aContains, int aAc
}
-void EDA_TextStruct::Draw( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint& aOffset,
+void EDA_TEXT::Draw( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint& aOffset,
EDA_Colors aColor, int aDrawMode,
GRTraceMode aFillMode, EDA_Colors aAnchor_color )
{
@@ -391,7 +391,7 @@ void EDA_TextStruct::Draw( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint& aOf
}
-void EDA_TextStruct::DrawOneLineOfText( EDA_DRAW_PANEL* aPanel, wxDC* aDC,
+void EDA_TEXT::DrawOneLineOfText( EDA_DRAW_PANEL* aPanel, wxDC* aDC,
const wxPoint& aOffset, EDA_Colors aColor,
int aDrawMode, GRTraceMode aFillMode,
EDA_Colors aAnchor_color,
@@ -435,7 +435,7 @@ void EDA_TextStruct::DrawOneLineOfText( EDA_DRAW_PANEL* aPanel, wxDC* aDC,
m_HJustify, m_VJustify, width, m_Italic, m_Bold );
}
-wxString EDA_TextStruct::GetTextStyleName()
+wxString EDA_TEXT::GetTextStyleName()
{
int style = 0;
@@ -457,10 +457,10 @@ wxString EDA_TextStruct::GetTextStyleName()
/******************/
-/* Class EDA_Rect */
+/* Class EDA_RECT */
/******************/
-void EDA_Rect::Normalize()
+void EDA_RECT::Normalize()
{
if( m_Size.y < 0 )
{
@@ -476,13 +476,13 @@ void EDA_Rect::Normalize()
}
-void EDA_Rect::Move( const wxPoint& aMoveVector )
+void EDA_RECT::Move( const wxPoint& aMoveVector )
{
m_Pos += aMoveVector;
}
-bool EDA_Rect::Contains( const wxPoint& aPoint ) const
+bool EDA_RECT::Contains( const wxPoint& aPoint ) const
{
wxPoint rel_pos = aPoint - m_Pos;
wxSize size = m_Size;
@@ -505,7 +505,7 @@ bool EDA_Rect::Contains( const wxPoint& aPoint ) const
/*
* return true if aRect is inside me (or on boundaries)
*/
-bool EDA_Rect::Contains( const EDA_Rect& aRect ) const
+bool EDA_RECT::Contains( const EDA_RECT& aRect ) const
{
return Contains( aRect.GetOrigin() ) && Contains( aRect.GetEnd() );
}
@@ -515,12 +515,12 @@ bool EDA_Rect::Contains( const EDA_Rect& aRect ) const
* test for a common area between 2 rect.
* return true if at least a common point is found
*/
-bool EDA_Rect::Intersects( const EDA_Rect& aRect ) const
+bool EDA_RECT::Intersects( const EDA_RECT& aRect ) const
{
// this logic taken from wxWidgets' geometry.cpp file:
bool rc;
- EDA_Rect me(*this);
- EDA_Rect rect(aRect);
+ EDA_RECT me(*this);
+ EDA_RECT rect(aRect);
me.Normalize(); // ensure size is >= 0
rect.Normalize(); // ensure size is >= 0
@@ -543,14 +543,14 @@ bool EDA_Rect::Intersects( const EDA_Rect& aRect ) const
}
-EDA_Rect& EDA_Rect::Inflate( int aDelta )
+EDA_RECT& EDA_RECT::Inflate( int aDelta )
{
Inflate( aDelta, aDelta );
return *this;
}
-EDA_Rect& EDA_Rect::Inflate( wxCoord dx, wxCoord dy )
+EDA_RECT& EDA_RECT::Inflate( wxCoord dx, wxCoord dy )
{
if( m_Size.x >= 0 )
{
@@ -618,10 +618,10 @@ EDA_Rect& EDA_Rect::Inflate( wxCoord dx, wxCoord dy )
}
-void EDA_Rect::Merge( const EDA_Rect& aRect )
+void EDA_RECT::Merge( const EDA_RECT& aRect )
{
Normalize(); // ensure width and height >= 0
- EDA_Rect rect = aRect;
+ EDA_RECT rect = aRect;
rect.Normalize(); // ensure width and height >= 0
wxPoint end = GetEnd();
wxPoint rect_end = rect.GetEnd();
@@ -635,7 +635,7 @@ void EDA_Rect::Merge( const EDA_Rect& aRect )
}
-void EDA_Rect::Merge( const wxPoint& aPoint )
+void EDA_RECT::Merge( const wxPoint& aPoint )
{
Normalize(); // ensure width and height >= 0
@@ -649,7 +649,7 @@ void EDA_Rect::Merge( const wxPoint& aPoint )
}
-double EDA_Rect::GetArea() const
+double EDA_RECT::GetArea() const
{
return (double) GetWidth() * (double) GetHeight();
}
diff --git a/common/block_commande.cpp b/common/block_commande.cpp
index 88ebbaf4c1..dfeae5066a 100644
--- a/common/block_commande.cpp
+++ b/common/block_commande.cpp
@@ -17,7 +17,7 @@
BLOCK_SELECTOR::BLOCK_SELECTOR() :
EDA_ITEM( BLOCK_LOCATE_STRUCT_TYPE ),
- EDA_Rect()
+ EDA_RECT()
{
m_State = STATE_NO_BLOCK; /* State (enum BlockState) of block. */
m_Command = BLOCK_IDLE; /* Type (enum CmdBlockType) of operation. */
diff --git a/common/class_marker_base.cpp b/common/class_marker_base.cpp
index 7440183808..5685e946da 100644
--- a/common/class_marker_base.cpp
+++ b/common/class_marker_base.cpp
@@ -133,7 +133,7 @@ bool MARKER_BASE::HitTestMarker( const wxPoint& refPos ) const
}
-EDA_Rect MARKER_BASE::GetBoundingBoxMarker() const
+EDA_RECT MARKER_BASE::GetBoundingBoxMarker() const
{
wxSize realsize = m_ShapeBoundingBox.GetSize();
wxPoint realposition = m_ShapeBoundingBox.GetPosition();
@@ -142,7 +142,7 @@ EDA_Rect MARKER_BASE::GetBoundingBoxMarker() const
realposition.x *= m_ScalingFactor;
realposition.y *= m_ScalingFactor;
realposition += m_Pos;
- return EDA_Rect( m_Pos, realsize );
+ return EDA_RECT( m_Pos, realsize );
}
void MARKER_BASE::DrawMarker( EDA_DRAW_PANEL* aPanel, wxDC* aDC, int aDrawMode,
diff --git a/common/copy_to_clipboard.cpp b/common/copy_to_clipboard.cpp
index 718e1fa54e..3a60cfe107 100644
--- a/common/copy_to_clipboard.cpp
+++ b/common/copy_to_clipboard.cpp
@@ -76,7 +76,7 @@ bool DrawPageOnClipboard( EDA_DRAW_FRAME* aFrame )
wxMetafileDC dc;
- EDA_Rect tmp = aFrame->DrawPanel->m_ClipBox;
+ EDA_RECT tmp = aFrame->DrawPanel->m_ClipBox;
GRResetPenAndBrush( &dc );
const bool plotBlackAndWhite = false;
GRForceBlackPen( plotBlackAndWhite );
diff --git a/common/drawpanel.cpp b/common/drawpanel.cpp
index 10fa1b86a2..7846190e2b 100644
--- a/common/drawpanel.cpp
+++ b/common/drawpanel.cpp
@@ -185,7 +185,7 @@ wxRealPoint EDA_DRAW_PANEL::GetGrid()
bool EDA_DRAW_PANEL::IsPointOnDisplay( const wxPoint& aPosition )
{
wxPoint pos;
- EDA_Rect display_rect;
+ EDA_RECT display_rect;
INSTALL_UNBUFFERED_DC( dc, this ); // Refresh the clip box to the entire screen size.
SetClipBox( dc );
@@ -200,7 +200,7 @@ bool EDA_DRAW_PANEL::IsPointOnDisplay( const wxPoint& aPosition )
}
-void EDA_DRAW_PANEL::RefreshDrawingRect( const EDA_Rect& aRect, bool aEraseBackground )
+void EDA_DRAW_PANEL::RefreshDrawingRect( const EDA_RECT& aRect, bool aEraseBackground )
{
INSTALL_UNBUFFERED_DC( dc, this );
@@ -418,7 +418,7 @@ void EDA_DRAW_PANEL::EraseScreen( wxDC* DC )
/* Set to one (1) to draw bounding box validate bounding box calculation. */
#if DEBUG_SHOW_CLIP_RECT
- EDA_Rect bBox = m_ClipBox;
+ EDA_RECT bBox = m_ClipBox;
GRRect( NULL, DC, bBox.GetOrigin().x, bBox.GetOrigin().y,
bBox.GetEnd().x, bBox.GetEnd().y, 0, LIGHTMAGENTA );
#endif
diff --git a/common/drawtxt.cpp b/common/drawtxt.cpp
index 580139bf34..8cf6300861 100644
--- a/common/drawtxt.cpp
+++ b/common/drawtxt.cpp
@@ -153,7 +153,7 @@ int ReturnGraphicTextWidth( const wxString& aText, int aXSize, bool aItalic, boo
/* Helper function for drawing character polygons */
static void DrawGraphicTextPline(
- EDA_Rect* aClipBox,
+ EDA_RECT* aClipBox,
wxDC* aDC,
EDA_Colors aColor,
int aWidth,
@@ -247,7 +247,7 @@ void DrawGraphicText( EDA_DRAW_PANEL* aPanel,
wxPoint overbar_pos; // Start point for the current overbar
int overbars; // Number of ~ seen
int overbar_italic_comp; // Italic compensation for overbar
- EDA_Rect* clipBox; // Clip box used in basic draw functions
+ EDA_RECT* clipBox; // Clip box used in basic draw functions
clipBox = aPanel ? &aPanel->m_ClipBox : NULL;
#define BUF_SIZE 100
diff --git a/common/gr_basic.cpp b/common/gr_basic.cpp
index 39ab412734..794f952973 100644
--- a/common/gr_basic.cpp
+++ b/common/gr_basic.cpp
@@ -56,7 +56,7 @@ int g_DrawBgColor = WHITE;
#define USE_CLIP_FILLED_POLYGONS
#ifdef USE_CLIP_FILLED_POLYGONS
-static void ClipAndDrawFilledPoly( EDA_Rect * ClipBox, wxDC * DC, wxPoint Points[], int n );
+static void ClipAndDrawFilledPoly( EDA_RECT * ClipBox, wxDC * DC, wxPoint Points[], int n );
#endif
/* These functions are used by corresponding functions
@@ -64,7 +64,7 @@ static void ClipAndDrawFilledPoly( EDA_Rect * ClipBox, wxDC * DC, wxPoint Points
* from user units to screen units(pixels coordinates)
*/
static void GRSMoveTo( int x, int y );
-static void GRSRect( EDA_Rect* aClipBox, wxDC* aDC, int x1, int y1,
+static void GRSRect( EDA_RECT* aClipBox, wxDC* aDC, int x1, int y1,
int x2, int y2, int aWidth, int aColor,
wxPenStyle aStyle = wxPENSTYLE_SOLID );
@@ -99,7 +99,7 @@ static wxDC* s_DC_lastDC = NULL;
*
* @return - False if any part of the line lies within the rectangle.
*/
-static bool clipLine( EDA_Rect* aClipBox, int& x1, int& y1, int& x2, int& y2 )
+static bool clipLine( EDA_RECT* aClipBox, int& x1, int& y1, int& x2, int& y2 )
{
if( aClipBox->Contains( x1, y1 ) && aClipBox->Contains( x2, y2 ) )
return false;
@@ -318,7 +318,7 @@ static bool clipLine( EDA_Rect* aClipBox, int& x1, int& y1, int& x2, int& y2 )
}
-static void WinClipAndDrawLine( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+static void WinClipAndDrawLine( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int Color, int width = 1 )
{
GRLastMoveToX = x2;
@@ -493,7 +493,7 @@ void GRSetDrawMode( wxDC* DC, int draw_mode )
}
-void GRPutPixel( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int Color )
+void GRPutPixel( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int Color )
{
if( ClipBox && !ClipBox->Contains( x, y ) )
return;
@@ -506,7 +506,7 @@ void GRPutPixel( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int Color )
/*
* Draw a line, in object space.
*/
-void GRLine( EDA_Rect* ClipBox,
+void GRLine( EDA_RECT* ClipBox,
wxDC* DC,
int x1,
int y1,
@@ -521,13 +521,13 @@ void GRLine( EDA_Rect* ClipBox,
}
-void GRLine( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd, int aWidth, int aColor )
+void GRLine( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd, int aWidth, int aColor )
{
GRLine( aClipBox, aDC, aStart.x, aStart.y, aEnd.x, aEnd.y, aWidth, aColor );
}
-void GRDashedLineTo( EDA_Rect* ClipBox, wxDC* DC, int x2, int y2, int width, int Color )
+void GRDashedLineTo( EDA_RECT* ClipBox, wxDC* DC, int x2, int y2, int width, int Color )
{
s_DC_lastcolor = -1;
GRSetColorPen( DC, Color, width, wxPENSTYLE_SHORT_DASH );
@@ -539,7 +539,7 @@ void GRDashedLineTo( EDA_Rect* ClipBox, wxDC* DC, int x2, int y2, int width, int
}
-void GRDashedLine( EDA_Rect* ClipBox,
+void GRDashedLine( EDA_RECT* ClipBox,
wxDC* DC,
int x1,
int y1,
@@ -571,7 +571,7 @@ void GRMoveTo( int x, int y )
/*
* Draw line to a new position, in object space.
*/
-void GRLineTo( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int width, int Color )
+void GRLineTo( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int width, int Color )
{
int GRLineToX, GRLineToY;
@@ -582,7 +582,7 @@ void GRLineTo( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int width, int Color )
}
-void GRMixedLine( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRMixedLine( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int width, int Color )
{
GRSetColorPen( DC, Color, width, wxPENSTYLE_DOT_DASH );
@@ -611,7 +611,7 @@ void GRSMoveTo( int x, int y )
* @param aColor = an index into our color table of RGB colors.
* @see EDA_Colors and colors.h
*/
-void GRLineArray( EDA_Rect* aClipBox, wxDC* aDC, std::vector& aLines,
+void GRLineArray( EDA_RECT* aClipBox, wxDC* aDC, std::vector& aLines,
int aWidth, int aColor )
{
GRSetColorPen( aDC, aColor, aWidth );
@@ -647,7 +647,7 @@ void GRLineArray( EDA_Rect* aClipBox, wxDC* aDC, std::vector& aLines,
}
-void GRCSegm( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRCSegm( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int width, int aPenSize, int Color )
{
long radius;
@@ -800,14 +800,14 @@ void GRCSegm( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
}
-void GRCSegm( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRCSegm( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int width, int Color )
{
GRCSegm( ClipBox, DC, x1, y1, x2, y2, width, 0, Color );
}
-void GRCSegm( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
+void GRCSegm( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
int aWidth, int aColor )
{
GRCSegm( aClipBox, aDC, aStart.x, aStart.y, aEnd.x, aEnd.y, aWidth, 0, aColor );
@@ -817,21 +817,21 @@ void GRCSegm( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
/*
* Draw segment (full) with rounded ends in object space (real coords.).
*/
-void GRFillCSegm( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRFillCSegm( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int width, int Color )
{
WinClipAndDrawLine( ClipBox, DC, x1, y1, x2, y2, Color, width );
}
-void GRFilledSegment( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
+void GRFilledSegment( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
int aWidth, int aColor )
{
WinClipAndDrawLine( aClipBox, aDC, aStart.x, aStart.y, aEnd.x, aEnd.y, aColor, aWidth );
}
-static bool IsGRSPolyDrawable( EDA_Rect* ClipBox, int n, wxPoint Points[] )
+static bool IsGRSPolyDrawable( EDA_RECT* ClipBox, int n, wxPoint Points[] )
{
if( !ClipBox )
return true;
@@ -873,7 +873,7 @@ static bool IsGRSPolyDrawable( EDA_Rect* ClipBox, int n, wxPoint Points[] )
/*
* Draw a new polyline and fill it if Fill, in screen space.
*/
-static void GRSPoly( EDA_Rect* ClipBox,
+static void GRSPoly( EDA_RECT* ClipBox,
wxDC* DC,
int n,
wxPoint Points[],
@@ -919,7 +919,7 @@ static void GRSPoly( EDA_Rect* ClipBox,
/*
* Draw a new closed polyline and fill it if Fill, in screen space.
*/
-static void GRSClosedPoly( EDA_Rect* ClipBox,
+static void GRSClosedPoly( EDA_RECT* ClipBox,
wxDC* DC,
int aPointCount,
wxPoint aPoints[],
@@ -967,7 +967,7 @@ static void GRSClosedPoly( EDA_Rect* ClipBox,
/*
* Draw a new polyline and fill it if Fill, in drawing space.
*/
-void GRPoly( EDA_Rect* ClipBox, wxDC* DC, int n, wxPoint Points[],
+void GRPoly( EDA_RECT* ClipBox, wxDC* DC, int n, wxPoint Points[],
bool Fill, int width, int Color, int BgColor )
{
GRSPoly( ClipBox, DC, n, Points, Fill, width, Color, BgColor );
@@ -977,21 +977,21 @@ void GRPoly( EDA_Rect* ClipBox, wxDC* DC, int n, wxPoint Points[],
/*
* Draw a closed polyline and fill it if Fill, in object space.
*/
-void GRClosedPoly( EDA_Rect* ClipBox, wxDC* DC, int n, wxPoint Points[],
+void GRClosedPoly( EDA_RECT* ClipBox, wxDC* DC, int n, wxPoint Points[],
bool Fill, int Color, int BgColor )
{
GRClosedPoly( ClipBox, DC, n, Points, Fill, 0, Color, BgColor );
}
-void GRClosedPoly( EDA_Rect* ClipBox, wxDC* DC, int n, wxPoint Points[],
+void GRClosedPoly( EDA_RECT* ClipBox, wxDC* DC, int n, wxPoint Points[],
bool Fill, int width, int Color, int BgColor )
{
GRSClosedPoly( ClipBox, DC, n, Points, Fill, width, Color, BgColor );
}
-void GRCircle( EDA_Rect* ClipBox, wxDC* DC, int xc, int yc, int r, int width, int Color )
+void GRCircle( EDA_RECT* ClipBox, wxDC* DC, int xc, int yc, int r, int width, int Color )
{
/* Clip circles off screen. */
if( ClipBox )
@@ -1021,19 +1021,19 @@ void GRCircle( EDA_Rect* ClipBox, wxDC* DC, int xc, int yc, int r, int width, in
}
-void GRCircle( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int r, int Color )
+void GRCircle( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int r, int Color )
{
GRCircle( ClipBox, DC, x, y, r, 0, Color );
}
-void GRCircle( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, int aWidth, int aColor )
+void GRCircle( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, int aWidth, int aColor )
{
GRCircle( aClipBox, aDC, aPos.x, aPos.y, aRadius, aWidth, aColor );
}
-void GRFilledCircle( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int r,
+void GRFilledCircle( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int r,
int width, int Color, int BgColor )
{
/* Clip circles off screen. */
@@ -1060,7 +1060,7 @@ void GRFilledCircle( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int r,
}
-void GRFilledCircle( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, int aColor )
+void GRFilledCircle( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, int aColor )
{
GRFilledCircle( aClipBox, aDC, aPos.x, aPos.y, aRadius, 0, aColor, aColor );
}
@@ -1069,7 +1069,7 @@ void GRFilledCircle( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, i
/*
* Draw an arc in user space.
*/
-void GRArc1( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRArc1( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int xc, int yc, int Color )
{
GRArc1( ClipBox, DC, x1, y1, x2, y2, xc, yc, 0, Color );
@@ -1079,7 +1079,7 @@ void GRArc1( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
/*
* Draw an arc, width = width in user space.
*/
-void GRArc1( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRArc1( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int xc, int yc, int width, int Color )
{
/* Clip arcs off screen. */
@@ -1107,7 +1107,7 @@ void GRArc1( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
}
-void GRArc1( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
+void GRArc1( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
wxPoint aCenter, int aWidth, int aColor )
{
GRArc1( aClipBox, aDC, aStart.x, aStart.y, aEnd.x, aEnd.y, aCenter.x, aCenter.y,
@@ -1118,7 +1118,7 @@ void GRArc1( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
/*
* Draw a filled arc in drawing space.
*/
-void GRFilledArc( EDA_Rect* ClipBox,
+void GRFilledArc( EDA_RECT* ClipBox,
wxDC* DC,
int x,
int y,
@@ -1167,7 +1167,7 @@ void GRFilledArc( EDA_Rect* ClipBox,
}
-void GRFilledArc( EDA_Rect* ClipBox, wxDC* DC, int x, int y,
+void GRFilledArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y,
int StAngle, int EndAngle, int r, int Color, int BgColor )
{
GRFilledArc( ClipBox, DC, x, y, StAngle, EndAngle, r, 0, Color, BgColor );
@@ -1177,7 +1177,7 @@ void GRFilledArc( EDA_Rect* ClipBox, wxDC* DC, int x, int y,
/*
* Draw an arc in drawing space.
*/
-void GRArc( EDA_Rect* ClipBox, wxDC* DC, int xc, int yc, int StAngle,
+void GRArc( EDA_RECT* ClipBox, wxDC* DC, int xc, int yc, int StAngle,
int EndAngle, int r, int Color )
{
int x1, y1, x2, y2;
@@ -1221,7 +1221,7 @@ void GRArc( EDA_Rect* ClipBox, wxDC* DC, int xc, int yc, int StAngle,
/*
* Draw an arc with width = width in drawing space.
*/
-void GRArc( EDA_Rect* ClipBox,
+void GRArc( EDA_RECT* ClipBox,
wxDC* DC,
int x,
int y,
@@ -1272,13 +1272,13 @@ void GRArc( EDA_Rect* ClipBox,
/*
* Draw a rectangle in drawing space.
*/
-void GRRect( EDA_Rect* aClipBox, wxDC* aDC, int x1, int y1, int x2, int y2, int aColor )
+void GRRect( EDA_RECT* aClipBox, wxDC* aDC, int x1, int y1, int x2, int y2, int aColor )
{
GRSRect( aClipBox, aDC, x1, y1, x2, y2, 0, aColor );
}
-void GRRectPs( EDA_Rect* aClipBox, wxDC* aDC, const EDA_Rect& aRect, int aColor, wxPenStyle aStyle )
+void GRRectPs( EDA_RECT* aClipBox, wxDC* aDC, const EDA_RECT& aRect, int aColor, wxPenStyle aStyle )
{
int x1 = aRect.GetX();
int y1 = aRect.GetY();
@@ -1292,13 +1292,13 @@ void GRRectPs( EDA_Rect* aClipBox, wxDC* aDC, const EDA_Rect& aRect, int aColor,
/*
* Draw a rectangle (thick lines) in drawing space.
*/
-void GRRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2, int width, int Color )
+void GRRect( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2, int width, int Color )
{
GRSRect( ClipBox, DC, x1, y1, x2, y2, width, Color );
}
-void GRRect( EDA_Rect* aClipBox, wxDC* aDC, const EDA_Rect& aRect, int aWidth, int aColor )
+void GRRect( EDA_RECT* aClipBox, wxDC* aDC, const EDA_RECT& aRect, int aWidth, int aColor )
{
int x1 = aRect.GetX();
int y1 = aRect.GetY();
@@ -1312,7 +1312,7 @@ void GRRect( EDA_Rect* aClipBox, wxDC* aDC, const EDA_Rect& aRect, int aWidth, i
/*
* Draw a rectangle (filled with AreaColor) in drawing space.
*/
-void GRFilledRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRFilledRect( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int Color, int BgColor )
{
GRSFilledRect( ClipBox, DC, x1, y1, x2, y2, 0, Color, BgColor );
@@ -1322,7 +1322,7 @@ void GRFilledRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
/*
* Draw a rectangle (filled with AreaColor) in drawing space.
*/
-void GRFilledRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRFilledRect( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int width, int Color, int BgColor )
{
GRSFilledRect( ClipBox, DC, x1, y1, x2, y2, width, Color, BgColor );
@@ -1333,7 +1333,7 @@ void GRFilledRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
* Draw a rectangle in screen space.
*/
-void GRSRect( EDA_Rect* aClipBox, wxDC* aDC, int x1, int y1, int x2, int y2,
+void GRSRect( EDA_RECT* aClipBox, wxDC* aDC, int x1, int y1, int x2, int y2,
int aWidth, int aColor, wxPenStyle aStyle )
{
if( x1 > x2 )
@@ -1374,7 +1374,7 @@ void GRSRect( EDA_Rect* aClipBox, wxDC* aDC, int x1, int y1, int x2, int y2,
}
-void GRSFilledRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRSFilledRect( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int width, int Color, int BgColor )
{
if( x1 > x2 )
@@ -1442,7 +1442,7 @@ void GRSFilledRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
*/
#include "SutherlandHodgmanClipPoly.h"
-void ClipAndDrawFilledPoly( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aPoints[], int n )
+void ClipAndDrawFilledPoly( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aPoints[], int n )
{
if( aClipBox == NULL )
{
@@ -1480,7 +1480,7 @@ void ClipAndDrawFilledPoly( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aPoints[], in
#endif
-void GRBezier( EDA_Rect* ClipBox,
+void GRBezier( EDA_RECT* ClipBox,
wxDC* DC,
int x1,
int y1,
@@ -1496,7 +1496,7 @@ void GRBezier( EDA_Rect* ClipBox,
}
-void GRBezier( EDA_Rect* ClipBox,
+void GRBezier( EDA_RECT* ClipBox,
wxDC* DC,
int x1,
int y1,
diff --git a/common/zoom.cpp b/common/zoom.cpp
index 55ba96504c..775b5c635b 100644
--- a/common/zoom.cpp
+++ b/common/zoom.cpp
@@ -60,7 +60,7 @@ void EDA_DRAW_FRAME::Zoom_Automatique( bool aWarpPointer )
* selected area (Rect) in full window screen
* @param Rect = selected area to show after zooming
*/
-void EDA_DRAW_FRAME::Window_Zoom( EDA_Rect& Rect )
+void EDA_DRAW_FRAME::Window_Zoom( EDA_RECT& Rect )
{
double scalex, bestscale;
wxSize size;
diff --git a/eeschema/class_libentry.cpp b/eeschema/class_libentry.cpp
index ad688420a3..f980a7cf37 100644
--- a/eeschema/class_libentry.cpp
+++ b/eeschema/class_libentry.cpp
@@ -377,7 +377,7 @@ void LIB_COMPONENT::Draw( EDA_DRAW_PANEL* aPanel, wxDC* aDc, const wxPoint& aOff
/* Enable this to draw the bounding box around the component to validate
* the bounding box calculations. */
#if 0
- EDA_Rect bBox = GetBoundingBox( aMulti, aConvert );
+ EDA_RECT bBox = GetBoundingBox( aMulti, aConvert );
GRRect( &aPanel->m_ClipBox, aDc, bBox.GetOrigin().x, bBox.GetOrigin().y,
bBox.GetEnd().x, bBox.GetEnd().y, 0, LIGHTMAGENTA );
#endif
@@ -966,9 +966,9 @@ bool LIB_COMPONENT::LoadFootprints( FILE* aFile, char* aLine,
* if aConvert == 0 Convert is non used
* Invisible fields are not taken in account
**/
-EDA_Rect LIB_COMPONENT::GetBoundingBox( int aUnit, int aConvert ) const
+EDA_RECT LIB_COMPONENT::GetBoundingBox( int aUnit, int aConvert ) const
{
- EDA_Rect bBox( wxPoint( 0, 0 ), wxSize( 0, 0 ) );
+ EDA_RECT bBox( wxPoint( 0, 0 ), wxSize( 0, 0 ) );
BOOST_FOREACH( const LIB_DRAW_ITEM& item, drawings )
{
@@ -996,9 +996,9 @@ EDA_Rect LIB_COMPONENT::GetBoundingBox( int aUnit, int aConvert ) const
* if aConvert == 0 Convert is non used
* Fields are not take in account
**/
-EDA_Rect LIB_COMPONENT::GetBodyBoundingBox( int aUnit, int aConvert ) const
+EDA_RECT LIB_COMPONENT::GetBodyBoundingBox( int aUnit, int aConvert ) const
{
- EDA_Rect bBox( wxPoint( 0, 0 ), wxSize( 0, 0 ) );
+ EDA_RECT bBox( wxPoint( 0, 0 ), wxSize( 0, 0 ) );
BOOST_FOREACH( const LIB_DRAW_ITEM& item, drawings )
{
@@ -1220,7 +1220,7 @@ void LIB_COMPONENT::ClearStatus()
}
-int LIB_COMPONENT::SelectItems( EDA_Rect& aRect, int aUnit, int aConvert, bool aEditPinByPin )
+int LIB_COMPONENT::SelectItems( EDA_RECT& aRect, int aUnit, int aConvert, bool aEditPinByPin )
{
int itemCount = 0;
diff --git a/eeschema/class_libentry.h b/eeschema/class_libentry.h
index 96a65661fc..db6c380624 100644
--- a/eeschema/class_libentry.h
+++ b/eeschema/class_libentry.h
@@ -242,7 +242,7 @@ public:
* if aConvert == 0 Convert is non used
* Invisible fields are not taken in account
**/
- EDA_Rect GetBoundingBox( int aUnit, int aConvert ) const;
+ EDA_RECT GetBoundingBox( int aUnit, int aConvert ) const;
/**
* Function GetBodyBoundingBox
@@ -253,7 +253,7 @@ public:
* if aConvert == 0 Convert is non used
* Fields are not taken in account
**/
- EDA_Rect GetBodyBoundingBox( int aUnit, int aConvert ) const;
+ EDA_RECT GetBodyBoundingBox( int aUnit, int aConvert ) const;
bool SaveDateAndTime( FILE* aFile );
bool LoadDateAndTime( char* aLine );
@@ -475,7 +475,7 @@ public:
* @return The number of draw objects found inside the block select
* rectangle.
*/
- int SelectItems( EDA_Rect& aRect, int aUnit, int aConvert, bool aEditPinByPin );
+ int SelectItems( EDA_RECT& aRect, int aUnit, int aConvert, bool aEditPinByPin );
/**
* Clears all the draw items marked by a block select.
diff --git a/eeschema/dialogs/dialog_SVG_print.cpp b/eeschema/dialogs/dialog_SVG_print.cpp
index d72b1ce692..e0be4daafe 100644
--- a/eeschema/dialogs/dialog_SVG_print.cpp
+++ b/eeschema/dialogs/dialog_SVG_print.cpp
@@ -199,7 +199,7 @@ bool DIALOG_SVG_PRINT::DrawSVGPage( EDA_DRAW_FRAME* frame,
float dpi = (float) frame->m_InternalUnits;
wxSVGFileDC dc( FullFileName, SheetSize.x, SheetSize.y, dpi );
- EDA_Rect tmp = panel->m_ClipBox;
+ EDA_RECT tmp = panel->m_ClipBox;
GRResetPenAndBrush( &dc );
GRForceBlackPen( aPrintBlackAndWhite );
diff --git a/eeschema/dialogs/dialog_print_using_printer.cpp b/eeschema/dialogs/dialog_print_using_printer.cpp
index 561a28ac26..087e6cce24 100644
--- a/eeschema/dialogs/dialog_print_using_printer.cpp
+++ b/eeschema/dialogs/dialog_print_using_printer.cpp
@@ -308,7 +308,7 @@ void SCH_PRINTOUT::DrawPage( SCH_SCREEN* aScreen )
wxPoint tmp_startvisu;
wxSize SheetSize; // Page size in internal units
wxPoint old_org;
- EDA_Rect oldClipBox;
+ EDA_RECT oldClipBox;
wxRect fitRect;
wxDC* dc = GetDC();
SCH_EDIT_FRAME* parent = m_Parent->GetParent();
diff --git a/eeschema/lib_arc.cpp b/eeschema/lib_arc.cpp
index 8c2cd3d705..731901424f 100644
--- a/eeschema/lib_arc.cpp
+++ b/eeschema/lib_arc.cpp
@@ -261,7 +261,7 @@ void LIB_ARC::DoOffset( const wxPoint& aOffset )
}
-bool LIB_ARC::DoTestInside( EDA_Rect& aRect ) const
+bool LIB_ARC::DoTestInside( EDA_RECT& aRect ) const
{
return aRect.Contains( m_ArcStart.x, -m_ArcStart.y )
|| aRect.Contains( m_ArcEnd.x, -m_ArcEnd.y );
@@ -325,7 +325,7 @@ int LIB_ARC::GetPenSize()
}
-void LIB_ARC::drawEditGraphics( EDA_Rect* aClipBox, wxDC* aDC, int aColor )
+void LIB_ARC::drawEditGraphics( EDA_RECT* aClipBox, wxDC* aDC, int aColor )
{
// The edit indicators only get drawn when a new arc is being drawn.
if( !IsNew() )
@@ -407,17 +407,17 @@ void LIB_ARC::drawGraphic( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint& aOf
/* Set to one (1) to draw bounding box around arc to validate bounding box
* calculation. */
#if 0
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
GRRect( &aPanel->m_ClipBox, aDC, bBox.GetOrigin().x, bBox.GetOrigin().y,
bBox.GetEnd().x, bBox.GetEnd().y, 0, LIGHTMAGENTA );
#endif
}
-EDA_Rect LIB_ARC::GetBoundingBox() const
+EDA_RECT LIB_ARC::GetBoundingBox() const
{
int minX, minY, maxX, maxY, angleStart, angleEnd;
- EDA_Rect rect;
+ EDA_RECT rect;
wxPoint nullPoint, startPos, endPos, centerPos;
wxPoint normStart = m_ArcStart - m_Pos;
wxPoint normEnd = m_ArcEnd - m_Pos;
@@ -477,7 +477,7 @@ start(%d, %d), end(%d, %d), radius %d" ),
void LIB_ARC::DisplayInfo( EDA_DRAW_FRAME* aFrame )
{
wxString msg;
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
LIB_DRAW_ITEM::DisplayInfo( aFrame );
diff --git a/eeschema/lib_arc.h b/eeschema/lib_arc.h
index 5351a01e43..3069281743 100644
--- a/eeschema/lib_arc.h
+++ b/eeschema/lib_arc.h
@@ -43,7 +43,7 @@ class LIB_ARC : public LIB_DRAW_ITEM
/**
* Draw the graphics when the arc is being edited.
*/
- void drawEditGraphics( EDA_Rect* aClipBox, wxDC* aDC, int aColor );
+ void drawEditGraphics( EDA_RECT* aClipBox, wxDC* aDC, int aColor );
/**
* Calculates the center, radius, and angles at \a aPosition when the arc is being edited.
@@ -96,7 +96,7 @@ public:
*/
virtual bool HitTest( wxPoint aPosition, int aThreshold, const TRANSFORM& aTransform );
- virtual EDA_Rect GetBoundingBox() const;
+ virtual EDA_RECT GetBoundingBox() const;
virtual void DisplayInfo( EDA_DRAW_FRAME* frame );
/**
@@ -133,7 +133,7 @@ protected:
*/
virtual int DoCompare( const LIB_DRAW_ITEM& aOther ) const;
virtual void DoOffset( const wxPoint& aOffset );
- virtual bool DoTestInside( EDA_Rect& aRect ) const;
+ virtual bool DoTestInside( EDA_RECT& aRect ) const;
virtual void DoMove( const wxPoint& aPosition );
virtual wxPoint DoGetPosition() const { return m_Pos; }
virtual void DoMirrorHorizontal( const wxPoint& aCenter );
diff --git a/eeschema/lib_bezier.cpp b/eeschema/lib_bezier.cpp
index f2b4b44bf3..7e2af0dbb1 100644
--- a/eeschema/lib_bezier.cpp
+++ b/eeschema/lib_bezier.cpp
@@ -160,7 +160,7 @@ void LIB_BEZIER::DoOffset( const wxPoint& aOffset )
}
-bool LIB_BEZIER::DoTestInside( EDA_Rect& aRect ) const
+bool LIB_BEZIER::DoTestInside( EDA_RECT& aRect ) const
{
for( size_t i = 0; i < m_PolyPoints.size(); i++ )
{
@@ -289,7 +289,7 @@ void LIB_BEZIER::drawGraphic( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint&
/* Set to one (1) to draw bounding box around bezier curve to validate
* bounding box calculation. */
#if 0
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
bBox.Inflate( m_Thickness + 1, m_Thickness + 1 );
GRRect( &aPanel->m_ClipBox, aDC, bBox.GetOrigin().x, bBox.GetOrigin().y,
bBox.GetEnd().x, bBox.GetEnd().y, 0, LIGHTMAGENTA );
@@ -340,9 +340,9 @@ bool LIB_BEZIER::HitTest( wxPoint aPosRef, int aThreshold, const TRANSFORM& aTra
* Function GetBoundingBox
* @return the boundary box for this, in library coordinates
*/
-EDA_Rect LIB_BEZIER::GetBoundingBox() const
+EDA_RECT LIB_BEZIER::GetBoundingBox() const
{
- EDA_Rect rect;
+ EDA_RECT rect;
int xmin, xmax, ymin, ymax;
if( !GetCornerCount() )
@@ -370,7 +370,7 @@ EDA_Rect LIB_BEZIER::GetBoundingBox() const
void LIB_BEZIER::DisplayInfo( EDA_DRAW_FRAME* aFrame )
{
wxString msg;
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
LIB_DRAW_ITEM::DisplayInfo( aFrame );
diff --git a/eeschema/lib_bezier.h b/eeschema/lib_bezier.h
index 88cde59c9e..4911ecc595 100644
--- a/eeschema/lib_bezier.h
+++ b/eeschema/lib_bezier.h
@@ -67,7 +67,7 @@ public:
/**
* @return the boundary box for this, in library coordinates
*/
- virtual EDA_Rect GetBoundingBox() const;
+ virtual EDA_RECT GetBoundingBox() const;
/**
* @return the size of the "pen" that be used to draw or plot this item
@@ -89,7 +89,7 @@ protected:
virtual int DoCompare( const LIB_DRAW_ITEM& aOther ) const;
virtual void DoOffset( const wxPoint& aOffset );
- virtual bool DoTestInside( EDA_Rect& aRect ) const;
+ virtual bool DoTestInside( EDA_RECT& aRect ) const;
virtual void DoMove( const wxPoint& aPosition );
virtual wxPoint DoGetPosition() const { return m_PolyPoints[0]; }
virtual void DoMirrorHorizontal( const wxPoint& aCenter );
diff --git a/eeschema/lib_circle.cpp b/eeschema/lib_circle.cpp
index 7c2da463a7..2c7d208b2f 100644
--- a/eeschema/lib_circle.cpp
+++ b/eeschema/lib_circle.cpp
@@ -146,7 +146,7 @@ void LIB_CIRCLE::DoOffset( const wxPoint& aOffset )
}
-bool LIB_CIRCLE::DoTestInside( EDA_Rect& aRect ) const
+bool LIB_CIRCLE::DoTestInside( EDA_RECT& aRect ) const
{
/*
* FIXME: This fails to take into account the radius around the center
@@ -231,16 +231,16 @@ void LIB_CIRCLE::drawGraphic( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint&
/* Set to one (1) to draw bounding box around circle to validate bounding
* box calculation. */
#if 0
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
GRRect( &aPanel->m_ClipBox, aDC, bBox.GetOrigin().x, bBox.GetOrigin().y,
bBox.GetEnd().x, bBox.GetEnd().y, 0, LIGHTMAGENTA );
#endif
}
-EDA_Rect LIB_CIRCLE::GetBoundingBox() const
+EDA_RECT LIB_CIRCLE::GetBoundingBox() const
{
- EDA_Rect rect;
+ EDA_RECT rect;
rect.SetOrigin( m_Pos.x - m_Radius, ( m_Pos.y - m_Radius ) * -1 );
rect.SetEnd( m_Pos.x + m_Radius, ( m_Pos.y + m_Radius ) * -1 );
@@ -253,7 +253,7 @@ EDA_Rect LIB_CIRCLE::GetBoundingBox() const
void LIB_CIRCLE::DisplayInfo( EDA_DRAW_FRAME* aFrame )
{
wxString msg;
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
LIB_DRAW_ITEM::DisplayInfo( aFrame );
diff --git a/eeschema/lib_circle.h b/eeschema/lib_circle.h
index 71b9e260d0..95438fb0e2 100644
--- a/eeschema/lib_circle.h
+++ b/eeschema/lib_circle.h
@@ -69,7 +69,7 @@ public:
*/
virtual int GetPenSize( );
- virtual EDA_Rect GetBoundingBox() const;
+ virtual EDA_RECT GetBoundingBox() const;
virtual void DisplayInfo( EDA_DRAW_FRAME* aFrame );
/**
@@ -101,7 +101,7 @@ protected:
virtual int DoCompare( const LIB_DRAW_ITEM& aOther ) const;
virtual void DoOffset( const wxPoint& aOffset );
- virtual bool DoTestInside( EDA_Rect& aRect ) const;
+ virtual bool DoTestInside( EDA_RECT& aRect ) const;
virtual void DoMove( const wxPoint& aPosition );
virtual wxPoint DoGetPosition() const { return m_Pos; }
virtual void DoMirrorHorizontal( const wxPoint& aCenter );
diff --git a/eeschema/lib_draw_item.h b/eeschema/lib_draw_item.h
index 88d911f746..b0fe6928d6 100644
--- a/eeschema/lib_draw_item.h
+++ b/eeschema/lib_draw_item.h
@@ -66,7 +66,7 @@ class LIB_DRAW_ITEM : public EDA_ITEM
* @param aDC - The device context to draw on.
* @param aColor - The index of the color to draw.
*/
- virtual void drawEditGraphics( EDA_Rect* aClipBox, wxDC* aDC, int aColor ) {}
+ virtual void drawEditGraphics( EDA_RECT* aClipBox, wxDC* aDC, int aColor ) {}
/**
* Calculates the attributes of an item at \a aPosition when it is being edited.
@@ -226,7 +226,7 @@ public:
/**
* @return the boundary box for this, in library coordinates
*/
- virtual EDA_Rect GetBoundingBox() const { return EDA_ITEM::GetBoundingBox(); }
+ virtual EDA_RECT GetBoundingBox() const { return EDA_ITEM::GetBoundingBox(); }
/**
* Displays basic info (type, part and convert) about item
@@ -281,7 +281,7 @@ public:
* @param aRect - Rectangle to check against.
* @return - True if object is inside rectangle.
*/
- bool Inside( EDA_Rect& aRect ) const { return DoTestInside( aRect ); }
+ bool Inside( EDA_RECT& aRect ) const { return DoTestInside( aRect ); }
/**
* Move a draw object to a new \a aPosition.
@@ -384,7 +384,7 @@ protected:
*/
virtual int DoCompare( const LIB_DRAW_ITEM& aOther ) const = 0;
virtual void DoOffset( const wxPoint& aOffset ) = 0;
- virtual bool DoTestInside( EDA_Rect& aRect ) const = 0;
+ virtual bool DoTestInside( EDA_RECT& aRect ) const = 0;
virtual void DoMove( const wxPoint& aPosition ) = 0;
virtual wxPoint DoGetPosition() const = 0;
virtual void DoMirrorHorizontal( const wxPoint& aCenter ) = 0;
diff --git a/eeschema/lib_field.cpp b/eeschema/lib_field.cpp
index 544caa01fe..ae5845150d 100644
--- a/eeschema/lib_field.cpp
+++ b/eeschema/lib_field.cpp
@@ -328,7 +328,7 @@ void LIB_FIELD::drawGraphic( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint& a
#if 0
wxString tmp = m_Text;
m_Text = *text;
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
m_Text = tmp;
bBox.Inflate( 1, 1 );
GRRect( &aPanel->m_ClipBox, aDC, bBox, 0, LIGHTMAGENTA );
@@ -453,7 +453,7 @@ void LIB_FIELD::DoOffset( const wxPoint& offset )
}
-bool LIB_FIELD::DoTestInside( EDA_Rect& rect ) const
+bool LIB_FIELD::DoTestInside( EDA_RECT& rect ) const
{
/*
* FIXME: This fails to take into acount the size and/or orientation of
@@ -504,9 +504,9 @@ wxString LIB_FIELD::GetFullText( int unit )
}
-EDA_Rect LIB_FIELD::GetBoundingBox() const
+EDA_RECT LIB_FIELD::GetBoundingBox() const
{
- EDA_Rect rect = GetTextBox();
+ EDA_RECT rect = GetTextBox();
rect.m_Pos.y *= -1;
rect.m_Pos.y -= rect.GetHeight();
diff --git a/eeschema/lib_field.h b/eeschema/lib_field.h
index 74f072f2bd..841ca7f35b 100644
--- a/eeschema/lib_field.h
+++ b/eeschema/lib_field.h
@@ -15,7 +15,7 @@
* the component property editor assumes it.
* @see enum NumFieldType
*/
-class LIB_FIELD : public LIB_DRAW_ITEM, public EDA_TextStruct
+class LIB_FIELD : public LIB_DRAW_ITEM, public EDA_TEXT
{
int m_id; ///< @see enum NumFieldType
wxString m_name; ///< Name (not the field text value itself, that is .m_Text)
@@ -131,7 +131,7 @@ public:
* Return the bounding rectangle of the field text.
* @return Bounding rectangle.
*/
- virtual EDA_Rect GetBoundingBox() const;
+ virtual EDA_RECT GetBoundingBox() const;
/**
* Displays info (type, part convert filed name and value)
@@ -237,7 +237,7 @@ protected:
virtual int DoCompare( const LIB_DRAW_ITEM& other ) const;
virtual void DoOffset( const wxPoint& offset );
- virtual bool DoTestInside( EDA_Rect& rect ) const;
+ virtual bool DoTestInside( EDA_RECT& rect ) const;
virtual void DoMove( const wxPoint& newPosition );
virtual wxPoint DoGetPosition( void ) const { return m_Pos; }
virtual void DoMirrorHorizontal( const wxPoint& center );
diff --git a/eeschema/lib_pin.cpp b/eeschema/lib_pin.cpp
index aaa0e3b429..506793a72b 100644
--- a/eeschema/lib_pin.cpp
+++ b/eeschema/lib_pin.cpp
@@ -831,7 +831,7 @@ void LIB_PIN::drawGraphic( EDA_DRAW_PANEL* aPanel,
/* Set to one (1) to draw bounding box around pin to validate bounding
* box calculation. */
#if 0
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
bBox.Inflate( 5, 5 );
GRRect( &aPanel->m_ClipBox, aDC, bBox.GetOrigin().x, bBox.GetOrigin().y,
bBox.GetEnd().x, bBox.GetEnd().y, 0, LIGHTMAGENTA );
@@ -1652,7 +1652,7 @@ void LIB_PIN::DoOffset( const wxPoint& offset )
}
-bool LIB_PIN::DoTestInside( EDA_Rect& rect ) const
+bool LIB_PIN::DoTestInside( EDA_RECT& rect ) const
{
wxPoint end = ReturnPinEndPoint();
@@ -1755,13 +1755,13 @@ void LIB_PIN::DisplayInfo( EDA_DRAW_FRAME* frame )
* Function GetBoundingBox
* @return the boundary box for this, in schematic coordinates
*/
-EDA_Rect LIB_PIN::GetBoundingBox() const
+EDA_RECT LIB_PIN::GetBoundingBox() const
{
wxPoint pt = m_position;
pt.y *= -1; // Reverse the Y axis, according to the schematic orientation
- return EDA_Rect( pt, wxSize( 1, 1 ) );
+ return EDA_RECT( pt, wxSize( 1, 1 ) );
}
diff --git a/eeschema/lib_pin.h b/eeschema/lib_pin.h
index 8f35295a9f..6fe0a02fae 100644
--- a/eeschema/lib_pin.h
+++ b/eeschema/lib_pin.h
@@ -159,7 +159,7 @@ public:
virtual void DisplayInfo( EDA_DRAW_FRAME* frame );
- virtual EDA_Rect GetBoundingBox() const;
+ virtual EDA_RECT GetBoundingBox() const;
wxPoint ReturnPinEndPoint() const;
@@ -468,7 +468,7 @@ protected:
*/
virtual int DoCompare( const LIB_DRAW_ITEM& aOther ) const;
virtual void DoOffset( const wxPoint& aOffset );
- virtual bool DoTestInside( EDA_Rect& aRect ) const;
+ virtual bool DoTestInside( EDA_RECT& aRect ) const;
virtual void DoMove( const wxPoint& aPosition );
virtual wxPoint DoGetPosition() const { return m_position; }
virtual void DoMirrorHorizontal( const wxPoint& aCenter );
diff --git a/eeschema/lib_polyline.cpp b/eeschema/lib_polyline.cpp
index 1fd6a8e990..df7e10854b 100644
--- a/eeschema/lib_polyline.cpp
+++ b/eeschema/lib_polyline.cpp
@@ -158,7 +158,7 @@ void LIB_POLYLINE::DoOffset( const wxPoint& aOffset )
}
-bool LIB_POLYLINE::DoTestInside( EDA_Rect& aRect ) const
+bool LIB_POLYLINE::DoTestInside( EDA_RECT& aRect ) const
{
for( size_t i = 0; i < m_PolyPoints.size(); i++ )
{
@@ -305,7 +305,7 @@ void LIB_POLYLINE::drawGraphic( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint
/* Set to one (1) to draw bounding box around polyline to validate
* bounding box calculation. */
#if 0
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
bBox.Inflate( m_Thickness + 1, m_Thickness + 1 );
GRRect( &aPanel->m_ClipBox, aDC, bBox.GetOrigin().x, bBox.GetOrigin().y,
bBox.GetEnd().x, bBox.GetEnd().y, 0, LIGHTMAGENTA );
@@ -345,9 +345,9 @@ bool LIB_POLYLINE::HitTest( wxPoint aPosition, int aThreshold, const TRANSFORM&
* Function GetBoundingBox
* @return the boundary box for this, in library coordinates
*/
-EDA_Rect LIB_POLYLINE::GetBoundingBox() const
+EDA_RECT LIB_POLYLINE::GetBoundingBox() const
{
- EDA_Rect rect;
+ EDA_RECT rect;
int xmin, xmax, ymin, ymax;
xmin = xmax = m_PolyPoints[0].x;
@@ -388,7 +388,7 @@ void LIB_POLYLINE::DeleteSegment( const wxPoint aPosition )
void LIB_POLYLINE::DisplayInfo( EDA_DRAW_FRAME* aFrame )
{
wxString msg;
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
LIB_DRAW_ITEM::DisplayInfo( aFrame );
diff --git a/eeschema/lib_polyline.h b/eeschema/lib_polyline.h
index 0b03d96e0a..254d00aec0 100644
--- a/eeschema/lib_polyline.h
+++ b/eeschema/lib_polyline.h
@@ -81,7 +81,7 @@ public:
/**
* @return the boundary box for this, in library coordinates
*/
- virtual EDA_Rect GetBoundingBox() const;
+ virtual EDA_RECT GetBoundingBox() const;
/**
* @return the size of the "pen" that be used to draw or plot this item
@@ -118,7 +118,7 @@ protected:
virtual int DoCompare( const LIB_DRAW_ITEM& aOther ) const;
virtual void DoOffset( const wxPoint& aOffset );
- virtual bool DoTestInside( EDA_Rect& aRect ) const;
+ virtual bool DoTestInside( EDA_RECT& aRect ) const;
virtual void DoMove( const wxPoint& aPosition );
virtual wxPoint DoGetPosition() const { return m_PolyPoints[0]; }
virtual void DoMirrorHorizontal( const wxPoint& aCenter );
diff --git a/eeschema/lib_rectangle.cpp b/eeschema/lib_rectangle.cpp
index d62c7babe4..c0359b47c2 100644
--- a/eeschema/lib_rectangle.cpp
+++ b/eeschema/lib_rectangle.cpp
@@ -117,7 +117,7 @@ void LIB_RECTANGLE::DoOffset( const wxPoint& aOffset )
}
-bool LIB_RECTANGLE::DoTestInside( EDA_Rect& aRect ) const
+bool LIB_RECTANGLE::DoTestInside( EDA_RECT& aRect ) const
{
return aRect.Contains( m_Pos.x, -m_Pos.y ) || aRect.Contains( m_End.x, -m_End.y );
}
@@ -209,7 +209,7 @@ void LIB_RECTANGLE::drawGraphic( EDA_DRAW_PANEL* aPanel, wxDC* aDC,
/* Set to one (1) to draw bounding box around rectangle to validate
* bounding box calculation. */
#if 0
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
bBox.Inflate( m_Thickness + 1, m_Thickness + 1 );
GRRect( &aPanel->m_ClipBox, aDC, bBox.GetOrigin().x, bBox.GetOrigin().y,
bBox.GetEnd().x, bBox.GetEnd().y, 0, LIGHTMAGENTA );
@@ -229,9 +229,9 @@ void LIB_RECTANGLE::DisplayInfo( EDA_DRAW_FRAME* aFrame )
}
-EDA_Rect LIB_RECTANGLE::GetBoundingBox() const
+EDA_RECT LIB_RECTANGLE::GetBoundingBox() const
{
- EDA_Rect rect;
+ EDA_RECT rect;
rect.SetOrigin( m_Pos.x, m_Pos.y * -1 );
rect.SetEnd( m_End.x, m_End.y * -1 );
diff --git a/eeschema/lib_rectangle.h b/eeschema/lib_rectangle.h
index e79835d3d1..32f7018e5b 100644
--- a/eeschema/lib_rectangle.h
+++ b/eeschema/lib_rectangle.h
@@ -74,7 +74,7 @@ public:
*/
virtual int GetPenSize( );
- virtual EDA_Rect GetBoundingBox() const;
+ virtual EDA_RECT GetBoundingBox() const;
virtual void DisplayInfo( EDA_DRAW_FRAME* aFrame );
@@ -108,7 +108,7 @@ protected:
virtual int DoCompare( const LIB_DRAW_ITEM& aOther ) const;
virtual void DoOffset( const wxPoint& aOffset );
- virtual bool DoTestInside( EDA_Rect& aRect ) const;
+ virtual bool DoTestInside( EDA_RECT& aRect ) const;
virtual void DoMove( const wxPoint& aPosition );
virtual wxPoint DoGetPosition() const { return m_Pos; }
virtual void DoMirrorHorizontal( const wxPoint& aCenter );
diff --git a/eeschema/lib_text.cpp b/eeschema/lib_text.cpp
index 430587c48e..605b870e0e 100644
--- a/eeschema/lib_text.cpp
+++ b/eeschema/lib_text.cpp
@@ -26,7 +26,7 @@
LIB_TEXT::LIB_TEXT(LIB_COMPONENT * aParent) :
LIB_DRAW_ITEM( LIB_TEXT_T, aParent ),
- EDA_TextStruct()
+ EDA_TEXT()
{
m_Size = wxSize( 50, 50 );
m_typeName = _( "Text" );
@@ -217,7 +217,7 @@ void LIB_TEXT::DoOffset( const wxPoint& offset )
}
-bool LIB_TEXT::DoTestInside( EDA_Rect& rect ) const
+bool LIB_TEXT::DoTestInside( EDA_RECT& rect ) const
{
/*
* FIXME: This should calculate the text size and justification and
@@ -321,7 +321,7 @@ void LIB_TEXT::drawGraphic( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint& aO
* so the more easily way is to use no justifications ( Centered text )
* and use GetBoundaryBox to know the text coordinate considered as centered
*/
- EDA_Rect bBox = GetBoundingBox();
+ EDA_RECT bBox = GetBoundingBox();
pos1 = bBox.Centre(); // this is the coordinates of the graphic text relative to the
// component position in schematic Y axis orientation.
@@ -339,7 +339,7 @@ void LIB_TEXT::drawGraphic( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint& aO
* the bounding box calculations.
*/
#if 0
- EDA_Rect grBox;
+ EDA_RECT grBox;
bBox.SetY( -bBox.GetY() );
bBox.SetHeight( -bBox.GetHeight());
grBox.SetOrigin( aTransform.TransformCoordinate( bBox.GetOrigin() ) );
@@ -366,12 +366,12 @@ void LIB_TEXT::DisplayInfo( EDA_DRAW_FRAME* frame )
/**
* @return the boundary box for this, in schematic coordinates
*/
-EDA_Rect LIB_TEXT::GetBoundingBox() const
+EDA_RECT LIB_TEXT::GetBoundingBox() const
{
/* Y coordinates for LIB_ITEMS are bottom to top, so we must invert the Y position when
* calling GetTextBox() that works using top to bottom Y axis orientation.
*/
- EDA_Rect rect = GetTextBox( -1, -1, true );
+ EDA_RECT rect = GetTextBox( -1, -1, true );
wxPoint orig = rect.GetOrigin();
wxPoint end = rect.GetEnd();
diff --git a/eeschema/lib_text.h b/eeschema/lib_text.h
index 5a51d28854..aacd42cfab 100644
--- a/eeschema/lib_text.h
+++ b/eeschema/lib_text.h
@@ -12,7 +12,7 @@
/* Fields like Ref , value... are not Text, */
/* they are a separate class */
/*********************************************/
-class LIB_TEXT : public LIB_DRAW_ITEM, public EDA_TextStruct
+class LIB_TEXT : public LIB_DRAW_ITEM, public EDA_TEXT
{
wxString m_savedText; ///< Temporary storage for the string when edition.
bool m_rotate; ///< Flag to indicate a rotation occurred while editing.
@@ -83,10 +83,10 @@ public:
*
* For now, an ending point must be inside this rect.
*
- * @param aRect - the given EDA_Rect
+ * @param aRect - the given EDA_RECT
* @return - true if a hit, else false
*/
- virtual bool HitTest( EDA_Rect& aRect )
+ virtual bool HitTest( EDA_RECT& aRect )
{
return TextHitTest( aRect );
}
@@ -98,7 +98,7 @@ public:
virtual void DisplayInfo( EDA_DRAW_FRAME* aFrame );
- virtual EDA_Rect GetBoundingBox() const;
+ virtual EDA_RECT GetBoundingBox() const;
void Rotate();
@@ -133,7 +133,7 @@ protected:
virtual int DoCompare( const LIB_DRAW_ITEM& aOther ) const;
virtual void DoOffset( const wxPoint& aOffset );
- virtual bool DoTestInside( EDA_Rect& aRect ) const;
+ virtual bool DoTestInside( EDA_RECT& aRect ) const;
virtual void DoMove( const wxPoint& aPosition );
virtual wxPoint DoGetPosition() const { return m_Pos; }
virtual void DoMirrorHorizontal( const wxPoint& aCenter );
diff --git a/eeschema/libeditframe.cpp b/eeschema/libeditframe.cpp
index 3685b30e4e..13edefa9bd 100644
--- a/eeschema/libeditframe.cpp
+++ b/eeschema/libeditframe.cpp
@@ -346,7 +346,7 @@ int LIB_EDIT_FRAME::BestZoom()
{
int dx, dy, ii, jj;
wxSize size;
- EDA_Rect BoundaryBox;
+ EDA_RECT BoundaryBox;
if( m_component )
{
diff --git a/eeschema/plot.cpp b/eeschema/plot.cpp
index 82c7c0c327..5c8461b0e0 100644
--- a/eeschema/plot.cpp
+++ b/eeschema/plot.cpp
@@ -112,7 +112,7 @@ static void PlotTextField( PLOTTER* plotter, SCH_COMPONENT* DrawLibItem,
* so the more easily way is to use no justifications ( Centered text )
* and use GetBoundaryBox to know the text coordinate considered as centered
*/
- EDA_Rect BoundaryBox = field->GetBoundingBox();
+ EDA_RECT BoundaryBox = field->GetBoundingBox();
GRTextHorizJustifyType hjustify = GR_TEXT_HJUSTIFY_CENTER;
GRTextVertJustifyType vjustify = GR_TEXT_VJUSTIFY_CENTER;
wxPoint textpos = BoundaryBox.Centre();
diff --git a/eeschema/sch_bus_entry.cpp b/eeschema/sch_bus_entry.cpp
index 5aaee3f678..c8c3c08fe2 100644
--- a/eeschema/sch_bus_entry.cpp
+++ b/eeschema/sch_bus_entry.cpp
@@ -119,9 +119,9 @@ bool SCH_BUS_ENTRY::Load( LINE_READER& aLine, wxString& aErrorMsg )
}
-EDA_Rect SCH_BUS_ENTRY::GetBoundingBox() const
+EDA_RECT SCH_BUS_ENTRY::GetBoundingBox() const
{
- EDA_Rect box;
+ EDA_RECT box;
box.SetOrigin( m_Pos );
box.SetEnd( m_End() );
@@ -239,9 +239,9 @@ bool SCH_BUS_ENTRY::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
}
-bool SCH_BUS_ENTRY::doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const
+bool SCH_BUS_ENTRY::doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const
{
- EDA_Rect rect = aRect;
+ EDA_RECT rect = aRect;
rect.Inflate( aAccuracy );
diff --git a/eeschema/sch_bus_entry.h b/eeschema/sch_bus_entry.h
index e59e773617..ff3921b70d 100644
--- a/eeschema/sch_bus_entry.h
+++ b/eeschema/sch_bus_entry.h
@@ -70,7 +70,7 @@ public:
* schematic coordinate system. It is OK to overestimate the size
* by a few counts.
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/**
* Function GetPenSize
@@ -113,7 +113,7 @@ public:
private:
virtual bool doHitTest( const wxPoint& aPoint, int aAccuracy ) const;
- virtual bool doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const;
+ virtual bool doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const;
virtual EDA_ITEM* doClone() const;
};
diff --git a/eeschema/sch_component.cpp b/eeschema/sch_component.cpp
index 9d219be709..b8cc4e8a90 100644
--- a/eeschema/sch_component.cpp
+++ b/eeschema/sch_component.cpp
@@ -278,7 +278,7 @@ void SCH_COMPONENT::Draw( EDA_DRAW_PANEL* panel, wxDC* DC, const wxPoint& offset
#if 0
/* Draw the component boundary box */
{
- EDA_Rect BoundaryBox;
+ EDA_RECT BoundaryBox;
BoundaryBox = GetBoundingBox();
GRRect( &panel->m_ClipBox, DC, BoundaryBox, 0, BROWN );
#if 1
@@ -1326,10 +1326,10 @@ bool SCH_COMPONENT::Load( LINE_READER& aLine, wxString& aErrorMsg )
}
-EDA_Rect SCH_COMPONENT::GetBodyBoundingBox() const
+EDA_RECT SCH_COMPONENT::GetBodyBoundingBox() const
{
LIB_COMPONENT* Entry = CMP_LIBRARY::FindLibraryComponent( m_ChipName );
- EDA_Rect bBox;
+ EDA_RECT bBox;
int x0, xm, y0, ym;
if( Entry == NULL )
@@ -1373,7 +1373,7 @@ EDA_Rect SCH_COMPONENT::GetBodyBoundingBox() const
}
-EDA_Rect SCH_COMPONENT::GetBoundingBox() const
+EDA_RECT SCH_COMPONENT::GetBoundingBox() const
{
return GetBodyBoundingBox();
}
@@ -1579,7 +1579,7 @@ bool SCH_COMPONENT::IsSelectStateChanged( const wxRect& aRect )
{
bool previousState = IsSelected();
- EDA_Rect boundingBox = GetBoundingBox();
+ EDA_RECT boundingBox = GetBoundingBox();
if( aRect.Intersects( boundingBox ) )
m_Flags |= SELECTED;
@@ -1693,7 +1693,7 @@ bool SCH_COMPONENT::operator <( const SCH_ITEM& aItem ) const
SCH_COMPONENT* component = (SCH_COMPONENT*) &aItem;
- EDA_Rect rect = GetBodyBoundingBox();
+ EDA_RECT rect = GetBodyBoundingBox();
if( rect.GetArea() != component->GetBodyBoundingBox().GetArea() )
return rect.GetArea() < component->GetBodyBoundingBox().GetArea();
@@ -1710,7 +1710,7 @@ bool SCH_COMPONENT::operator <( const SCH_ITEM& aItem ) const
bool SCH_COMPONENT::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
{
- EDA_Rect bBox = GetBodyBoundingBox();
+ EDA_RECT bBox = GetBodyBoundingBox();
bBox.Inflate( aAccuracy );
if( bBox.Contains( aPoint ) )
@@ -1720,9 +1720,9 @@ bool SCH_COMPONENT::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
}
-bool SCH_COMPONENT::doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const
+bool SCH_COMPONENT::doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const
{
- EDA_Rect rect = aRect;
+ EDA_RECT rect = aRect;
rect.Inflate( aAccuracy );
diff --git a/eeschema/sch_component.h b/eeschema/sch_component.h
index 307797001c..e7a5b21be8 100644
--- a/eeschema/sch_component.h
+++ b/eeschema/sch_component.h
@@ -56,7 +56,7 @@ private:
void Init( const wxPoint& pos = wxPoint( 0, 0 ) );
- EDA_Rect GetBodyBoundingBox() const;
+ EDA_RECT GetBodyBoundingBox() const;
public:
SCH_COMPONENT( const wxPoint& pos = wxPoint( 0, 0 ), SCH_ITEM* aParent = NULL );
@@ -189,7 +189,7 @@ public:
* few counts.
* @return The bounding rectangle of the component.
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
//----------------------------------------------------------------
@@ -380,7 +380,7 @@ public:
private:
virtual bool doHitTest( const wxPoint& aPoint, int aAccuracy ) const;
- virtual bool doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const;
+ virtual bool doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const;
virtual bool doIsConnected( const wxPoint& aPosition ) const;
virtual EDA_ITEM* doClone() const;
};
diff --git a/eeschema/sch_field.cpp b/eeschema/sch_field.cpp
index 5e4d1ff056..550500076a 100644
--- a/eeschema/sch_field.cpp
+++ b/eeschema/sch_field.cpp
@@ -31,7 +31,7 @@
SCH_FIELD::SCH_FIELD( const wxPoint& aPos, int aFieldId, SCH_COMPONENT* aParent, wxString aName ) :
SCH_ITEM( aParent, SCH_FIELD_T ),
- EDA_TextStruct()
+ EDA_TEXT()
{
m_Pos = aPos;
m_FieldId = aFieldId;
@@ -45,7 +45,7 @@ SCH_FIELD::SCH_FIELD( const wxPoint& aPos, int aFieldId, SCH_COMPONENT* aParent,
SCH_FIELD::SCH_FIELD( const SCH_FIELD& aField ) :
SCH_ITEM( aField ),
- EDA_TextStruct( aField )
+ EDA_TEXT( aField )
{
m_FieldId = aField.m_FieldId;
m_Name = aField.m_Name;
@@ -131,7 +131,7 @@ void SCH_FIELD::Draw( EDA_DRAW_PANEL* panel, wxDC* DC,
* so the more easily way is to use no justifications ( Centered text )
* and use GetBoundaryBox to know the text coordinate considered as centered
*/
- EDA_Rect BoundaryBox = GetBoundingBox();
+ EDA_RECT BoundaryBox = GetBoundingBox();
GRTextHorizJustifyType hjustify = GR_TEXT_HJUSTIFY_CENTER;
GRTextVertJustifyType vjustify = GR_TEXT_VJUSTIFY_CENTER;
textpos = BoundaryBox.Centre();
@@ -218,9 +218,9 @@ void SCH_FIELD::SwapData( SCH_FIELD* aField )
}
-EDA_Rect SCH_FIELD::GetBoundingBox() const
+EDA_RECT SCH_FIELD::GetBoundingBox() const
{
- EDA_Rect BoundaryBox;
+ EDA_RECT BoundaryBox;
int hjustify, vjustify;
int orient;
wxSize size;
@@ -429,7 +429,7 @@ bool SCH_FIELD::Matches( wxFindReplaceData& aSearchData, void* aAuxData, wxPoint
if( match )
{
- EDA_Rect BoundaryBox = GetBoundingBox();
+ EDA_RECT BoundaryBox = GetBoundingBox();
if( aFindLocation )
*aFindLocation = GetBoundingBox().Centre();
@@ -486,7 +486,7 @@ bool SCH_FIELD::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
if( !IsVisible() || IsVoid() )
return false;
- EDA_Rect rect = GetBoundingBox();
+ EDA_RECT rect = GetBoundingBox();
rect.Inflate( aAccuracy );
@@ -494,13 +494,13 @@ bool SCH_FIELD::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
}
-bool SCH_FIELD::doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const
+bool SCH_FIELD::doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const
{
// Do not hit test hidden fields.
if( !IsVisible() || IsVoid() )
return false;
- EDA_Rect rect = aRect;
+ EDA_RECT rect = aRect;
rect.Inflate( aAccuracy );
diff --git a/eeschema/sch_field.h b/eeschema/sch_field.h
index 9aa68399c7..6768defa12 100644
--- a/eeschema/sch_field.h
+++ b/eeschema/sch_field.h
@@ -27,7 +27,7 @@ class LIB_FIELD;
* Fields 4 and higher are user defineable.
*/
-class SCH_FIELD : public SCH_ITEM, public EDA_TextStruct
+class SCH_FIELD : public SCH_ITEM, public EDA_TEXT
{
public:
int m_FieldId; ///< Field index, @see enum NumFieldType
@@ -62,7 +62,7 @@ public:
void Place( SCH_EDIT_FRAME* frame, wxDC* DC );
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/**
* Function IsVoid
@@ -179,7 +179,7 @@ public:
private:
virtual bool doHitTest( const wxPoint& aPoint, int aAccuracy ) const;
- virtual bool doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const;
+ virtual bool doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const;
virtual EDA_ITEM* doClone() const;
};
diff --git a/eeschema/sch_junction.cpp b/eeschema/sch_junction.cpp
index 04a05e64a3..cec8499ce1 100644
--- a/eeschema/sch_junction.cpp
+++ b/eeschema/sch_junction.cpp
@@ -89,9 +89,9 @@ bool SCH_JUNCTION::Load( LINE_READER& aLine, wxString& aErrorMsg )
}
-EDA_Rect SCH_JUNCTION::GetBoundingBox() const
+EDA_RECT SCH_JUNCTION::GetBoundingBox() const
{
- EDA_Rect rect;
+ EDA_RECT rect;
rect.SetOrigin( m_Pos );
rect.Inflate( ( GetPenSize() + m_Size.x ) / 2 );
@@ -179,7 +179,7 @@ void SCH_JUNCTION::Show( int nestLevel, std::ostream& os )
bool SCH_JUNCTION::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
{
- EDA_Rect rect = GetBoundingBox();
+ EDA_RECT rect = GetBoundingBox();
rect.Inflate( aAccuracy );
@@ -187,9 +187,9 @@ bool SCH_JUNCTION::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
}
-bool SCH_JUNCTION::doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const
+bool SCH_JUNCTION::doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const
{
- EDA_Rect rect = aRect;
+ EDA_RECT rect = aRect;
rect.Inflate( aAccuracy );
diff --git a/eeschema/sch_junction.h b/eeschema/sch_junction.h
index 8ebdefd4d6..0c99d98531 100644
--- a/eeschema/sch_junction.h
+++ b/eeschema/sch_junction.h
@@ -36,7 +36,7 @@ public:
* schematic coordinate system. It is OK to overestimate the size
* by a few counts.
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
SCH_JUNCTION* GenCopy();
@@ -101,7 +101,7 @@ public:
private:
virtual bool doHitTest( const wxPoint& aPoint, int aAccuracy ) const;
- virtual bool doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const;
+ virtual bool doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const;
virtual bool doIsConnected( const wxPoint& aPosition ) const;
virtual EDA_ITEM* doClone() const;
};
diff --git a/eeschema/sch_line.cpp b/eeschema/sch_line.cpp
index 54deae87da..f2e32004a5 100644
--- a/eeschema/sch_line.cpp
+++ b/eeschema/sch_line.cpp
@@ -91,7 +91,7 @@ void SCH_LINE::Show( int nestLevel, std::ostream& os ) const
#endif
-EDA_Rect SCH_LINE::GetBoundingBox() const
+EDA_RECT SCH_LINE::GetBoundingBox() const
{
int width = 25;
@@ -102,7 +102,7 @@ EDA_Rect SCH_LINE::GetBoundingBox() const
int ymax = MAX( m_Start.y, m_End.y ) + width;
// return a rectangle which is [pos,dim) in nature. therefore the +1
- EDA_Rect ret( wxPoint( xmin, ymin ), wxSize( xmax - xmin + 1, ymax - ymin + 1 ) );
+ EDA_RECT ret( wxPoint( xmin, ymin ), wxSize( xmax - xmin + 1, ymax - ymin + 1 ) );
return ret;
}
@@ -490,9 +490,9 @@ bool SCH_LINE::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
}
-bool SCH_LINE::doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const
+bool SCH_LINE::doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const
{
- EDA_Rect rect = aRect;
+ EDA_RECT rect = aRect;
rect.Inflate( aAccuracy );
diff --git a/eeschema/sch_line.h b/eeschema/sch_line.h
index 97ee517469..85091d8cfb 100644
--- a/eeschema/sch_line.h
+++ b/eeschema/sch_line.h
@@ -52,7 +52,7 @@ public:
* object, and the units should be in the pcb or schematic coordinate system.
* It is OK to overestimate the size by a few counts.
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/**
* Function GetLength
@@ -145,7 +145,7 @@ public:
private:
virtual bool doHitTest( const wxPoint& aPoint, int aAccuracy ) const;
- virtual bool doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const;
+ virtual bool doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const;
virtual bool doIsConnected( const wxPoint& aPosition ) const;
virtual EDA_ITEM* doClone() const;
};
diff --git a/eeschema/sch_marker.cpp b/eeschema/sch_marker.cpp
index a82dddb931..3c0f5cab6f 100644
--- a/eeschema/sch_marker.cpp
+++ b/eeschema/sch_marker.cpp
@@ -141,7 +141,7 @@ bool SCH_MARKER::Matches( wxFindReplaceData& aSearchData, wxPoint * aFindLocatio
* object, and the units should be in the pcb or schematic coordinate system.
* It is OK to overestimate the size by a few counts.
*/
-EDA_Rect SCH_MARKER::GetBoundingBox() const
+EDA_RECT SCH_MARKER::GetBoundingBox() const
{
return GetBoundingBoxMarker();
}
diff --git a/eeschema/sch_marker.h b/eeschema/sch_marker.h
index 33fa400d87..f8a527b13f 100644
--- a/eeschema/sch_marker.h
+++ b/eeschema/sch_marker.h
@@ -57,7 +57,7 @@ public:
* object, and the units should be in the pcb or schematic coordinate system.
* It is OK to overestimate the size by a few counts.
*/
- virtual EDA_Rect GetBoundingBox() const;
+ virtual EDA_RECT GetBoundingBox() const;
// Geometric transforms (used in block operations):
diff --git a/eeschema/sch_no_connect.cpp b/eeschema/sch_no_connect.cpp
index 06d8d0d4b4..d3c80eb903 100644
--- a/eeschema/sch_no_connect.cpp
+++ b/eeschema/sch_no_connect.cpp
@@ -39,10 +39,10 @@ EDA_ITEM* SCH_NO_CONNECT::doClone() const
}
-EDA_Rect SCH_NO_CONNECT::GetBoundingBox() const
+EDA_RECT SCH_NO_CONNECT::GetBoundingBox() const
{
int delta = ( GetPenSize() + m_Size.x ) / 2;
- EDA_Rect box;
+ EDA_RECT box;
box.SetOrigin( m_Pos );
box.Inflate( delta );
@@ -170,9 +170,9 @@ bool SCH_NO_CONNECT::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
}
-bool SCH_NO_CONNECT::doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const
+bool SCH_NO_CONNECT::doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const
{
- EDA_Rect rect = aRect;
+ EDA_RECT rect = aRect;
rect.Inflate( aAccuracy );
diff --git a/eeschema/sch_no_connect.h b/eeschema/sch_no_connect.h
index 4a718f3678..0ecde27c9a 100644
--- a/eeschema/sch_no_connect.h
+++ b/eeschema/sch_no_connect.h
@@ -64,7 +64,7 @@ public:
* schematic coordinate system. It is OK to overestimate the size
* by a few counts.
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
// Geometric transforms (used in block operations):
@@ -101,7 +101,7 @@ public:
private:
virtual bool doIsConnected( const wxPoint& aPosition ) const;
virtual bool doHitTest( const wxPoint& aPoint, int aAccuracy ) const;
- virtual bool doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const;
+ virtual bool doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const;
virtual EDA_ITEM* doClone() const;
};
diff --git a/eeschema/sch_polyline.cpp b/eeschema/sch_polyline.cpp
index 77a2a29e51..72be832de5 100644
--- a/eeschema/sch_polyline.cpp
+++ b/eeschema/sch_polyline.cpp
@@ -256,9 +256,9 @@ bool SCH_POLYLINE::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
}
-bool SCH_POLYLINE::doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const
+bool SCH_POLYLINE::doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const
{
- EDA_Rect rect = aRect;
+ EDA_RECT rect = aRect;
rect.Inflate( aAccuracy );
diff --git a/eeschema/sch_polyline.h b/eeschema/sch_polyline.h
index b7dd50446e..3f8f1715e0 100644
--- a/eeschema/sch_polyline.h
+++ b/eeschema/sch_polyline.h
@@ -100,7 +100,7 @@ public:
private:
virtual bool doHitTest( const wxPoint& aPoint, int aAccuracy ) const;
- virtual bool doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const;
+ virtual bool doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const;
virtual EDA_ITEM* doClone() const;
};
diff --git a/eeschema/sch_screen.cpp b/eeschema/sch_screen.cpp
index 5402e89975..43d5533a20 100644
--- a/eeschema/sch_screen.cpp
+++ b/eeschema/sch_screen.cpp
@@ -802,7 +802,7 @@ void SCH_SCREEN::addConnectedItemsToBlock( const wxPoint& position )
int SCH_SCREEN::UpdatePickList()
{
ITEM_PICKER picker;
- EDA_Rect area;
+ EDA_RECT area;
area.SetOrigin( m_BlockLocate.GetOrigin());
area.SetSize( m_BlockLocate.GetSize() );
area.Normalize();
diff --git a/eeschema/sch_sheet.cpp b/eeschema/sch_sheet.cpp
index f38c4cea8d..23757d1fb0 100644
--- a/eeschema/sch_sheet.cpp
+++ b/eeschema/sch_sheet.cpp
@@ -593,7 +593,7 @@ void SCH_SHEET::Draw( EDA_DRAW_PANEL* aPanel, wxDC* aDC,
}
-EDA_Rect SCH_SHEET::GetBoundingBox() const
+EDA_RECT SCH_SHEET::GetBoundingBox() const
{
int dx, dy;
@@ -607,7 +607,7 @@ EDA_Rect SCH_SHEET::GetBoundingBox() const
dx = MAX( m_Size.x, textlen1 );
dy = m_Size.y + m_SheetNameSize + m_FileNameSize + 16;
- EDA_Rect box( wxPoint( m_Pos.x, m_Pos.y - m_SheetNameSize - 8 ), wxSize( dx, dy ) );
+ EDA_RECT box( wxPoint( m_Pos.x, m_Pos.y - m_SheetNameSize - 8 ), wxSize( dx, dy ) );
return box;
}
@@ -935,7 +935,7 @@ bool SCH_SHEET::IsSelectStateChanged( const wxRect& aRect )
{
bool previousState = IsSelected();
- EDA_Rect boundingBox = GetBoundingBox();
+ EDA_RECT boundingBox = GetBoundingBox();
if( aRect.Intersects( boundingBox ) )
m_Flags |= SELECTED;
@@ -991,7 +991,7 @@ wxString SCH_SHEET::GetSelectMenuText() const
bool SCH_SHEET::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
{
- EDA_Rect rect = GetBoundingBox();
+ EDA_RECT rect = GetBoundingBox();
rect.Inflate( aAccuracy );
@@ -999,9 +999,9 @@ bool SCH_SHEET::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
}
-bool SCH_SHEET::doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const
+bool SCH_SHEET::doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const
{
- EDA_Rect rect = aRect;
+ EDA_RECT rect = aRect;
rect.Inflate( aAccuracy );
diff --git a/eeschema/sch_sheet.h b/eeschema/sch_sheet.h
index 7170f59add..0333b82449 100644
--- a/eeschema/sch_sheet.h
+++ b/eeschema/sch_sheet.h
@@ -369,9 +369,9 @@ public:
/**
* Function GetBoundingBox
- * @return an EDA_Rect giving the bounding box of the sheet
+ * @return an EDA_RECT giving the bounding box of the sheet
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
void SwapData( SCH_SHEET* copyitem );
@@ -541,7 +541,7 @@ protected:
private:
virtual bool doHitTest( const wxPoint& aPoint, int aAccuracy ) const;
- virtual bool doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const;
+ virtual bool doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const;
virtual EDA_ITEM* doClone() const;
};
diff --git a/eeschema/sch_sheet_path.cpp b/eeschema/sch_sheet_path.cpp
index 7403eb021f..5b445d23f2 100644
--- a/eeschema/sch_sheet_path.cpp
+++ b/eeschema/sch_sheet_path.cpp
@@ -25,10 +25,6 @@
#include "dialogs/dialog_schematic_find.h"
-/**********************************************/
-/* class to handle a series of sheets *********/
-/* a 'path' so to speak.. *********************/
-/**********************************************/
SCH_SHEET_PATH::SCH_SHEET_PATH()
{
for( int i = 0; i aSheetPathToTest.m_numSheets )
@@ -108,11 +91,6 @@ int SCH_SHEET_PATH::Cmp( const SCH_SHEET_PATH& aSheetPathToTest ) const
}
-/**
- * Function Last
- * returns a pointer to the last sheet of the list
- * One can see the others sheet as the "path" to reach this last sheet
- */
SCH_SHEET* SCH_SHEET_PATH::Last()
{
if( m_numSheets )
@@ -122,10 +100,6 @@ SCH_SHEET* SCH_SHEET_PATH::Last()
}
-/**
- * Function LastScreen
- * @return the SCH_SCREEN relative to the last sheet in list
- */
SCH_SCREEN* SCH_SHEET_PATH::LastScreen()
{
SCH_SHEET* lastSheet = Last();
@@ -137,11 +111,6 @@ SCH_SCREEN* SCH_SHEET_PATH::LastScreen()
}
-/**
- * Function LastScreen
- * @return a pointer to the first schematic item handled by the
- * SCH_SCREEN relative to the last sheet in list
- */
SCH_ITEM* SCH_SHEET_PATH::LastDrawList()
{
SCH_SHEET* lastSheet = Last();
@@ -178,26 +147,15 @@ SCH_ITEM* SCH_SHEET_PATH::FirstDrawList()
void SCH_SHEET_PATH::Push( SCH_SHEET* aSheet )
{
- if( m_numSheets > DSLSZ )
- {
- wxString msg;
- msg.Printf( _( "Schematic sheets can only be nested %d levels deep." ), DSLSZ );
- wxMessageBox( msg );
- }
+ wxCHECK_RET( m_numSheets < DSLSZ,
+ wxString::Format( _( "Schematic sheets can only be nested %d levels deep." ),
+ DSLSZ ) );
- if( m_numSheets < DSLSZ )
- {
- m_sheets[m_numSheets] = aSheet;
- m_numSheets++;
- }
+ m_sheets[ m_numSheets ] = aSheet;
+ m_numSheets++;
}
-/**
- * Function Pop
- * retrieves (pop) the last entered sheet and remove it from list
- * @return a SCH_SHEET* pointer to the removed sheet in list
- */
SCH_SHEET* SCH_SHEET_PATH::Pop()
{
if( m_numSheets > 0 )
@@ -210,12 +168,6 @@ SCH_SHEET* SCH_SHEET_PATH::Pop()
}
-/**
- * Function Path
- * the path uses the time stamps which do not changes even when editing sheet
- * parameters
- * a path is something like / (root) or /34005677 or /34005677/00AE4523
- */
wxString SCH_SHEET_PATH::Path()
{
wxString s, t;
@@ -235,13 +187,6 @@ wxString SCH_SHEET_PATH::Path()
}
-/**
- * Function PathHumanReadable
- * Return the sheet path in a readable form, i.e.
- * as a path made from sheet names.
- * (the "normal" path uses the time stamps which do not changes even when
- * editing sheet parameters)
- */
wxString SCH_SHEET_PATH::PathHumanReadable() const
{
wxString s, t;
@@ -313,16 +258,18 @@ void SCH_SHEET_PATH::AnnotatePowerSymbols( int* aReference )
}
-void SCH_SHEET_PATH::GetComponents( SCH_REFERENCE_LIST& aReferences,
- bool aIncludePowerSymbols )
+void SCH_SHEET_PATH::GetComponents( SCH_REFERENCE_LIST& aReferences, bool aIncludePowerSymbols )
{
// Search to sheet path number:
int sheetnumber = 1; // 1 = root
SCH_SHEET_LIST sheetList;
+
for( SCH_SHEET_PATH* path = sheetList.GetFirst(); path != NULL;
path = sheetList.GetNext(), sheetnumber++ )
+ {
if( Cmp(*path) == 0 )
break;
+ }
for( SCH_ITEM* item = LastDrawList(); item != NULL; item = item->Next() )
{
@@ -416,7 +363,7 @@ SCH_ITEM* SCH_SHEET_PATH::FindPreviousItem( KICAD_T aType, SCH_ITEM* aLastItem,
SCH_ITEM* SCH_SHEET_PATH::MatchNextItem( wxFindReplaceData& aSearchData,
SCH_ITEM* aLastItem,
- wxPoint * aFindLocation )
+ wxPoint* aFindLocation )
{
bool hasWrapped = false;
bool firstItemFound = false;
@@ -494,15 +441,11 @@ bool SCH_SHEET_PATH::operator==( const SCH_SHEET_PATH& d1 ) const
}
-/*********************************************************************/
+/********************************************************************/
/* Class SCH_SHEET_LIST to handle the list of Sheets in a hierarchy */
-/*********************************************************************/
+/********************************************************************/
-/* The constructor: build the list of sheets from aSheet.
- * If aSheet == NULL (default) build the whole list of sheets in hierarchy
- * So usually call it with no param.
- */
SCH_SHEET_LIST::SCH_SHEET_LIST( SCH_SHEET* aSheet )
{
m_index = 0;
@@ -516,10 +459,6 @@ SCH_SHEET_LIST::SCH_SHEET_LIST( SCH_SHEET* aSheet )
}
-/**
- * Function GetFirst
- * @return the first item (sheet) in m_List and prepare calls to GetNext()
- */
SCH_SHEET_PATH* SCH_SHEET_LIST::GetFirst()
{
m_index = 0;
@@ -531,11 +470,6 @@ SCH_SHEET_PATH* SCH_SHEET_LIST::GetFirst()
}
-/**
- * Function GetNext
- * @return the next item (sheet) in m_List or NULL if no more item in sheet
- * list
- */
SCH_SHEET_PATH* SCH_SHEET_LIST::GetNext()
{
if( m_index < GetCount() )
@@ -567,12 +501,6 @@ SCH_SHEET_PATH* SCH_SHEET_LIST::GetPrevious()
}
-/**
- * Function GetSheet
- * @return the item (sheet) in aIndex position in m_List or NULL if less than
- * index items
- * @param aIndex = index in sheet list to get the sheet
- */
SCH_SHEET_PATH* SCH_SHEET_LIST::GetSheet( int aIndex )
{
if( aIndex < GetCount() )
@@ -755,7 +683,7 @@ SCH_ITEM* SCH_SHEET_LIST::FindPreviousItem( KICAD_T aType, SCH_SHEET_PATH** aShe
SCH_ITEM* SCH_SHEET_LIST::MatchNextItem( wxFindReplaceData& aSearchData,
SCH_SHEET_PATH** aSheetFoundIn,
SCH_ITEM* aLastItem,
- wxPoint * aFindLocation )
+ wxPoint* aFindLocation )
{
bool hasWrapped = false;
bool firstItemFound = false;
diff --git a/eeschema/sch_sheet_path.h b/eeschema/sch_sheet_path.h
index c80759a8c6..bdc5aafd8e 100644
--- a/eeschema/sch_sheet_path.h
+++ b/eeschema/sch_sheet_path.h
@@ -67,33 +67,28 @@ class SCH_REFERENCE_LIST;
* The _last_ sheet is usually the sheet we want to select or reach (which is
* what the function Last() returns).
* Others sheets constitute the "path" from the first to the last sheet.
+ *
*/
class SCH_SHEET_PATH
{
-private:
- unsigned m_numSheets;
-
-public:
#define DSLSZ 32 // Max number of levels for a sheet path
- SCH_SHEET* m_sheets[DSLSZ];
+ SCH_SHEET* m_sheets[ DSLSZ ];
+ unsigned m_numSheets;
public:
SCH_SHEET_PATH();
- // ~SCH_SHEET_PATH() { };
void Clear()
{
m_numSheets = 0;
}
-
unsigned GetSheetsCount()
{
return m_numSheets;
}
-
/**
* Function Cmp
* Compare if this is the same sheet path as aSheetPathToTest
@@ -116,7 +111,7 @@ public:
SCH_SCREEN* LastScreen();
/**
- * Function LastScreen
+ * Function LastDrawList
* @return a pointer to the first schematic item handled by the
* SCH_SCREEN relative to the last sheet in list
*/
@@ -299,6 +294,7 @@ public:
{
if( m_List )
free( m_List );
+
m_List = NULL;
}
@@ -369,8 +365,7 @@ public:
* @param aReferences List of references to populate.
* @param aIncludePowerSymbols Set to false to only get normal components.
*/
- void GetComponents( SCH_REFERENCE_LIST& aReferences,
- bool aIncludePowerSymbols = true );
+ void GetComponents( SCH_REFERENCE_LIST& aReferences, bool aIncludePowerSymbols = true );
/**
* Function FindNextItem
@@ -414,7 +409,7 @@ public:
SCH_ITEM* MatchNextItem( wxFindReplaceData& aSearchData,
SCH_SHEET_PATH** aSheetFound,
SCH_ITEM* aLastItem,
- wxPoint * aFindLocation );
+ wxPoint* aFindLocation );
/**
* Function SetFootprintField
@@ -439,7 +434,7 @@ private:
* @param aSheet is the starting sheet from which the list is built,
* or NULL indicating that g_RootSheet should be used.
*/
- void BuildSheetList( SCH_SHEET* aSheet );
+ void BuildSheetList( SCH_SHEET* aSheet );
};
#endif // CLASS_DRAWSHEET_PATH_H
diff --git a/eeschema/sch_sheet_pin.cpp b/eeschema/sch_sheet_pin.cpp
index a95e66cf87..8d57286ce0 100644
--- a/eeschema/sch_sheet_pin.cpp
+++ b/eeschema/sch_sheet_pin.cpp
@@ -469,7 +469,7 @@ wxString SCH_SHEET_PIN::GetSelectMenuText() const
bool SCH_SHEET_PIN::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
{
- EDA_Rect rect = GetBoundingBox();
+ EDA_RECT rect = GetBoundingBox();
rect.Inflate( aAccuracy );
diff --git a/eeschema/sch_text.cpp b/eeschema/sch_text.cpp
index 2bb3c28046..5b71a941b4 100644
--- a/eeschema/sch_text.cpp
+++ b/eeschema/sch_text.cpp
@@ -77,7 +77,7 @@ static int* TemplateShape[5][4] =
SCH_TEXT::SCH_TEXT( const wxPoint& pos, const wxString& text, KICAD_T aType ) :
SCH_ITEM( NULL, aType ),
- EDA_TextStruct( text )
+ EDA_TEXT( text )
{
m_Layer = LAYER_NOTES;
m_Pos = pos;
@@ -90,7 +90,7 @@ SCH_TEXT::SCH_TEXT( const wxPoint& pos, const wxString& text, KICAD_T aType ) :
SCH_TEXT::SCH_TEXT( const SCH_TEXT& aText ) :
SCH_ITEM( aText ),
- EDA_TextStruct( aText )
+ EDA_TEXT( aText )
{
m_Pos = aText.m_Pos;
m_Shape = aText.m_Shape;
@@ -146,7 +146,7 @@ bool SCH_TEXT::Matches( wxFindReplaceData& aSearchData, void* aAuxData, wxPoint
{
if( SCH_ITEM::Matches( m_Text, aSearchData ) )
{
- EDA_Rect BoundaryBox = GetBoundingBox();
+ EDA_RECT BoundaryBox = GetBoundingBox();
if( aFindLocation )
*aFindLocation = BoundaryBox.Centre();
return true;
@@ -380,7 +380,7 @@ void SCH_TEXT::Draw( EDA_DRAW_PANEL* panel, wxDC* DC, const wxPoint& aOffset,
wxPoint text_offset = aOffset + GetSchematicTextOffset();
EXCHG( linewidth, m_Thickness ); // Set the minimum width
- EDA_TextStruct::Draw( panel, DC, text_offset, color, DrawMode, FILLED, UNSPECIFIED_COLOR );
+ EDA_TEXT::Draw( panel, DC, text_offset, color, DrawMode, FILLED, UNSPECIFIED_COLOR );
EXCHG( linewidth, m_Thickness ); // set initial value
if( m_IsDangling )
@@ -389,7 +389,7 @@ void SCH_TEXT::Draw( EDA_DRAW_PANEL* panel, wxDC* DC, const wxPoint& aOffset,
// Enable these line to draw the bounding box (debug tests purposes only)
#if 0
{
- EDA_Rect BoundaryBox = GetBoundingBox();
+ EDA_RECT BoundaryBox = GetBoundingBox();
GRRect( &panel->m_ClipBox, DC, BoundaryBox, 0, BROWN );
}
#endif
@@ -595,7 +595,7 @@ void SCH_TEXT::GetConnectionPoints( vector< wxPoint >& aPoints ) const
}
-EDA_Rect SCH_TEXT::GetBoundingBox() const
+EDA_RECT SCH_TEXT::GetBoundingBox() const
{
// We must pass the effective text thickness to GetTextBox
// when calculating the bounding box
@@ -603,7 +603,7 @@ EDA_Rect SCH_TEXT::GetBoundingBox() const
linewidth = Clamp_Text_PenSize( linewidth, m_Size, m_Bold );
- EDA_Rect rect = GetTextBox( -1, linewidth );
+ EDA_RECT rect = GetTextBox( -1, linewidth );
if( m_Orient ) // Rotate rect
{
@@ -640,7 +640,7 @@ bool SCH_TEXT::doHitTest( const wxPoint& aPoint, int aAccuracy ) const
}
-bool SCH_TEXT::doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const
+bool SCH_TEXT::doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const
{
return TextHitTest( aRect, aContained, aAccuracy );
}
@@ -809,7 +809,7 @@ void SCH_LABEL::Draw( EDA_DRAW_PANEL* panel, wxDC* DC, const wxPoint& offset,
}
-EDA_Rect SCH_LABEL::GetBoundingBox() const
+EDA_RECT SCH_LABEL::GetBoundingBox() const
{
int x, y, dx, dy, length, height;
@@ -851,7 +851,7 @@ EDA_Rect SCH_LABEL::GetBoundingBox() const
break;
}
- EDA_Rect box( wxPoint( x, y ), wxSize( dx, dy ) );
+ EDA_RECT box( wxPoint( x, y ), wxSize( dx, dy ) );
box.Normalize();
return box;
}
@@ -1136,7 +1136,7 @@ void SCH_GLOBALLABEL::Draw( EDA_DRAW_PANEL* panel,
int linewidth = (m_Thickness == 0) ? g_DrawDefaultLineThickness : m_Thickness;
linewidth = Clamp_Text_PenSize( linewidth, m_Size, m_Bold );
EXCHG( linewidth, m_Thickness ); // Set the minimum width
- EDA_TextStruct::Draw( panel, DC, text_offset, color, DrawMode, FILLED, UNSPECIFIED_COLOR );
+ EDA_TEXT::Draw( panel, DC, text_offset, color, DrawMode, FILLED, UNSPECIFIED_COLOR );
EXCHG( linewidth, m_Thickness ); // set initial value
CreateGraphicShape( Poly, m_Pos + aOffset );
@@ -1148,7 +1148,7 @@ void SCH_GLOBALLABEL::Draw( EDA_DRAW_PANEL* panel,
// Enable these line to draw the bounding box (debug tests purposes only)
#if 0
{
- EDA_Rect BoundaryBox = GetBoundingBox();
+ EDA_RECT BoundaryBox = GetBoundingBox();
GRRect( &panel->m_ClipBox, DC, BoundaryBox, 0, BROWN );
}
#endif
@@ -1239,7 +1239,7 @@ void SCH_GLOBALLABEL::CreateGraphicShape( std::vector & aCorner_list,
}
-EDA_Rect SCH_GLOBALLABEL::GetBoundingBox() const
+EDA_RECT SCH_GLOBALLABEL::GetBoundingBox() const
{
int x, y, dx, dy, length, height;
@@ -1284,7 +1284,7 @@ EDA_Rect SCH_GLOBALLABEL::GetBoundingBox() const
break;
}
- EDA_Rect box( wxPoint( x, y ), wxSize( dx, dy ) );
+ EDA_RECT box( wxPoint( x, y ), wxSize( dx, dy ) );
box.Normalize();
return box;
}
@@ -1471,7 +1471,7 @@ void SCH_HIERLABEL::Draw( EDA_DRAW_PANEL* panel,
EXCHG( linewidth, m_Thickness ); // Set the minimum width
wxPoint text_offset = offset + GetSchematicTextOffset();
- EDA_TextStruct::Draw( panel, DC, text_offset, color, DrawMode, FILLED, UNSPECIFIED_COLOR );
+ EDA_TEXT::Draw( panel, DC, text_offset, color, DrawMode, FILLED, UNSPECIFIED_COLOR );
EXCHG( linewidth, m_Thickness ); // set initial value
CreateGraphicShape( Poly, m_Pos + offset );
@@ -1483,7 +1483,7 @@ void SCH_HIERLABEL::Draw( EDA_DRAW_PANEL* panel,
// Enable these line to draw the bounding box (debug tests purposes only)
#if 0
{
- EDA_Rect BoundaryBox = GetBoundingBox();
+ EDA_RECT BoundaryBox = GetBoundingBox();
GRRect( &panel->m_ClipBox, DC, BoundaryBox, 0, BROWN );
}
#endif
@@ -1514,7 +1514,7 @@ void SCH_HIERLABEL::CreateGraphicShape( std::vector & aCorner_list,
}
-EDA_Rect SCH_HIERLABEL::GetBoundingBox() const
+EDA_RECT SCH_HIERLABEL::GetBoundingBox() const
{
int x, y, dx, dy, length, height;
@@ -1560,7 +1560,7 @@ EDA_Rect SCH_HIERLABEL::GetBoundingBox() const
break;
}
- EDA_Rect box( wxPoint( x, y ), wxSize( dx, dy ) );
+ EDA_RECT box( wxPoint( x, y ), wxSize( dx, dy ) );
box.Normalize();
return box;
}
diff --git a/eeschema/sch_text.h b/eeschema/sch_text.h
index 89bbe43cee..fccd017770 100644
--- a/eeschema/sch_text.h
+++ b/eeschema/sch_text.h
@@ -28,7 +28,7 @@ typedef enum {
extern const char* SheetLabelType[]; /* names of types of labels */
-class SCH_TEXT : public SCH_ITEM, public EDA_TextStruct
+class SCH_TEXT : public SCH_ITEM, public EDA_TEXT
{
public:
int m_Shape;
@@ -131,7 +131,7 @@ public:
* object, and the units should be in the pcb or schematic coordinate system.
* It is OK to overestimate the size by a few counts.
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/**
* Function Save
@@ -212,7 +212,7 @@ public:
private:
virtual bool doHitTest( const wxPoint& aPoint, int aAccuracy ) const;
- virtual bool doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const;
+ virtual bool doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const;
virtual EDA_ITEM* doClone() const;
};
@@ -273,7 +273,7 @@ public:
* object, and the units should be in the pcb or schematic coordinate system.
* It is OK to overestimate the size by a few counts.
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/**
* Function Save
@@ -378,7 +378,7 @@ public:
* object, and the units should be in the pcb or schematic coordinate system.
* It is OK to overestimate the size by a few counts.
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/**
* Function CreateGraphicShape (virual)
@@ -492,7 +492,7 @@ public:
* object, and the units should be in the pcb or schematic coordinate system.
* It is OK to overestimate the size by a few counts.
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/** virtual function Mirror_Y
* mirror item relative to an Y axis
diff --git a/eeschema/viewlib_frame.cpp b/eeschema/viewlib_frame.cpp
index 7b18ce1026..2b3c14ea15 100644
--- a/eeschema/viewlib_frame.cpp
+++ b/eeschema/viewlib_frame.cpp
@@ -348,7 +348,7 @@ int LIB_VIEW_FRAME::BestZoom()
size = m_clientSize;
}
- EDA_Rect BoundaryBox = component->GetBoundingBox( m_unit, m_convert );
+ EDA_RECT BoundaryBox = component->GetBoundingBox( m_unit, m_convert );
// Reserve a 25 mils margin around component bounding box.
size -= wxSize( 25, 25 );
diff --git a/gerbview/class_aperture_macro.cpp b/gerbview/class_aperture_macro.cpp
index ee41bf4363..9244e70423 100644
--- a/gerbview/class_aperture_macro.cpp
+++ b/gerbview/class_aperture_macro.cpp
@@ -128,7 +128,7 @@ int AM_PRIMITIVE::GetExposure(GERBER_DRAW_ITEM* aParent) const
* Draw the primitive shape for flashed items.
*/
void AM_PRIMITIVE::DrawBasicShape( GERBER_DRAW_ITEM* aParent,
- EDA_Rect* aClipBox,
+ EDA_RECT* aClipBox,
wxDC* aDC,
int aColor, int aAltColor,
wxPoint aShapePos,
@@ -725,7 +725,7 @@ int AM_PRIMITIVE::GetShapeDim( GERBER_DRAW_ITEM* aParent )
* When an item is flashed, this is the shape of the item
*/
void APERTURE_MACRO::DrawApertureMacroShape( GERBER_DRAW_ITEM* aParent,
- EDA_Rect* aClipBox, wxDC* aDC,
+ EDA_RECT* aClipBox, wxDC* aDC,
int aColor, int aAltColor,
wxPoint aShapePos, bool aFilledShape )
{
diff --git a/gerbview/class_aperture_macro.h b/gerbview/class_aperture_macro.h
index 92599a8bc6..8f91ba94a2 100644
--- a/gerbview/class_aperture_macro.h
+++ b/gerbview/class_aperture_macro.h
@@ -134,7 +134,7 @@ public: AM_PRIMITIVE( bool aGerbMetric, AM_PRIMITIVE_ID aId = AMP_UNKNOWN )
* @param aShapePos = the actual shape position
* @param aFilledShape = true to draw in filled mode, false to draw in skecth mode
*/
- void DrawBasicShape( GERBER_DRAW_ITEM* aParent, EDA_Rect* aClipBox, wxDC* aDC,
+ void DrawBasicShape( GERBER_DRAW_ITEM* aParent, EDA_RECT* aClipBox, wxDC* aDC,
int aColor, int aAltColor, wxPoint aShapePos, bool aFilledShape );
/** GetShapeDim
@@ -206,7 +206,7 @@ struct APERTURE_MACRO
* @param aShapePos = the actual shape position
* @param aFilledShape = true to draw in filled mode, false to draw in skecth mode
*/
- void DrawApertureMacroShape( GERBER_DRAW_ITEM* aParent, EDA_Rect* aClipBox, wxDC* aDC,
+ void DrawApertureMacroShape( GERBER_DRAW_ITEM* aParent, EDA_RECT* aClipBox, wxDC* aDC,
int aColor, int aAltColor, wxPoint aShapePos, bool aFilledShape );
/**
diff --git a/gerbview/class_gerber_draw_item.cpp b/gerbview/class_gerber_draw_item.cpp
index b603e0c510..ec0f679ea8 100644
--- a/gerbview/class_gerber_draw_item.cpp
+++ b/gerbview/class_gerber_draw_item.cpp
@@ -255,10 +255,10 @@ D_CODE* GERBER_DRAW_ITEM::GetDcodeDescr()
}
-EDA_Rect GERBER_DRAW_ITEM::GetBoundingBox() const
+EDA_RECT GERBER_DRAW_ITEM::GetBoundingBox() const
{
// return a rectangle which is (pos,dim) in nature. therefore the +1
- EDA_Rect bbox( m_Start, wxSize( 1, 1 ) );
+ EDA_RECT bbox( m_Start, wxSize( 1, 1 ) );
bbox.Inflate( m_Size.x / 2, m_Size.y / 2 );
@@ -557,7 +557,7 @@ void GERBER_DRAW_ITEM::ConvertSegmentToPolygon( )
* a helper function used id ::Draw to draw the polygon stored in m_PolyCorners
* Draw filled polygons
*/
-void GERBER_DRAW_ITEM::DrawGbrPoly( EDA_Rect* aClipBox,
+void GERBER_DRAW_ITEM::DrawGbrPoly( EDA_RECT* aClipBox,
wxDC* aDC,
int aColor,
const wxPoint& aOffset,
@@ -659,12 +659,12 @@ bool GERBER_DRAW_ITEM::HitTest( const wxPoint& aRefPos )
/**
* Function HitTest (overlayed)
- * tests if the given EDA_Rect intersect this object.
+ * tests if the given EDA_RECT intersect this object.
* For now, an ending point must be inside this rect.
- * @param aRefArea : the given EDA_Rect in AB plotter axis
+ * @param aRefArea : the given EDA_RECT in AB plotter axis
* @return bool - true if a hit, else false
*/
-bool GERBER_DRAW_ITEM::HitTest( EDA_Rect& aRefArea )
+bool GERBER_DRAW_ITEM::HitTest( EDA_RECT& aRefArea )
{
wxPoint pos = GetABPosition( m_Start );
diff --git a/gerbview/class_gerber_draw_item.h b/gerbview/class_gerber_draw_item.h
index d5121ab1c3..6a41501c05 100644
--- a/gerbview/class_gerber_draw_item.h
+++ b/gerbview/class_gerber_draw_item.h
@@ -196,7 +196,7 @@ public:
*/
D_CODE* GetDcodeDescr();
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/* Display on screen: */
void Draw( EDA_DRAW_PANEL* aPanel,
@@ -216,7 +216,7 @@ public:
* Function DrawGbrPoly
* a helper function used to draw the polygon stored in m_PolyCorners
*/
- void DrawGbrPoly( EDA_Rect* aClipBox,
+ void DrawGbrPoly( EDA_RECT* aClipBox,
wxDC* aDC, int aColor,
const wxPoint& aOffset, bool aFilledShape );
@@ -250,7 +250,7 @@ public:
* @param aRefArea a wxPoint to test
* @return bool - true if a hit, else false
*/
- bool HitTest( EDA_Rect& aRefArea );
+ bool HitTest( EDA_RECT& aRefArea );
/**
* Function GetClass
diff --git a/gerbview/dcode.cpp b/gerbview/dcode.cpp
index c99b4fd26e..20c8d08fab 100644
--- a/gerbview/dcode.cpp
+++ b/gerbview/dcode.cpp
@@ -332,7 +332,7 @@ void GERBVIEW_FRAME::CopyDCodesSizeToItems()
* When an item is flashed, the DCode shape is the shape of the item
*/
void D_CODE::DrawFlashedShape( GERBER_DRAW_ITEM* aParent,
- EDA_Rect* aClipBox, wxDC* aDC, int aColor, int aAltColor,
+ EDA_RECT* aClipBox, wxDC* aDC, int aColor, int aAltColor,
wxPoint aShapePos, bool aFilledShape )
{
int radius;
@@ -450,7 +450,7 @@ void D_CODE::DrawFlashedShape( GERBER_DRAW_ITEM* aParent,
* polygons (shapes with holes)
*/
void D_CODE::DrawFlashedPolygon( GERBER_DRAW_ITEM* aParent,
- EDA_Rect* aClipBox, wxDC* aDC,
+ EDA_RECT* aClipBox, wxDC* aDC,
int aColor, bool aFilled,
const wxPoint& aPosition )
{
diff --git a/gerbview/dcode.h b/gerbview/dcode.h
index 1246d0f035..f2d134e02f 100644
--- a/gerbview/dcode.h
+++ b/gerbview/dcode.h
@@ -167,8 +167,8 @@ public:
* @param aShapePos = the actual shape position
* @param aFilledShape = true to draw in filled mode, false to draw in skecth mode
*/
- void DrawFlashedShape( GERBER_DRAW_ITEM* aParent,
- EDA_Rect* aClipBox, wxDC* aDC, int aColor, int aAltColor,
+ void DrawFlashedShape( GERBER_DRAW_ITEM* aParent, EDA_RECT* aClipBox,
+ wxDC* aDC, int aColor, int aAltColor,
wxPoint aShapePos, bool aFilledShape );
/**
@@ -185,7 +185,7 @@ public:
* @param aPosition = the actual shape position
*/
void DrawFlashedPolygon( GERBER_DRAW_ITEM* aParent,
- EDA_Rect* aClipBox, wxDC* aDC, int aColor,
+ EDA_RECT* aClipBox, wxDC* aDC, int aColor,
bool aFilled, const wxPoint& aPosition );
/**
diff --git a/gerbview/draw_gerber_screen.cpp b/gerbview/draw_gerber_screen.cpp
index 7958063b7a..66891a3f10 100644
--- a/gerbview/draw_gerber_screen.cpp
+++ b/gerbview/draw_gerber_screen.cpp
@@ -134,7 +134,7 @@ void BOARD::Draw( EDA_DRAW_PANEL* aPanel, wxDC* aDC, int aDrawMode, const wxPoin
layerBitmap = new wxBitmap( bitmapWidth, bitmapHeight );
screenBitmap = new wxBitmap( bitmapWidth, bitmapHeight );
layerDC.SelectObject( *layerBitmap );
- EDA_Rect tmpRect = aPanel->m_ClipBox;
+ EDA_RECT tmpRect = aPanel->m_ClipBox;
aPanel->DoPrepareDC( layerDC );
aPanel->m_ClipBox = tmpRect;
layerDC.SetBackground( bgBrush );
@@ -210,7 +210,7 @@ void BOARD::Draw( EDA_DRAW_PANEL* aPanel, wxDC* aDC, int aDrawMode, const wxPoin
GRSetDrawMode( &layerDC, GR_COPY );
- EDA_Rect* cbox = &aPanel->m_ClipBox;
+ EDA_RECT* cbox = &aPanel->m_ClipBox;
GRSFilledRect( cbox, plotDC, cbox->GetX(), cbox->GetY(),
cbox->GetRight(), cbox->GetBottom(),
diff --git a/gerbview/gerbview_frame.cpp b/gerbview/gerbview_frame.cpp
index 17a1cf7d8b..750ee0b800 100644
--- a/gerbview/gerbview_frame.cpp
+++ b/gerbview/gerbview_frame.cpp
@@ -154,7 +154,7 @@ int GERBVIEW_FRAME::BestZoom()
return 16 * GetScreen()->m_ZoomScalar;
double x, y;
- EDA_Rect bbox;
+ EDA_RECT bbox;
BOARD_ITEM* item = GetBoard()->m_Drawings;
bbox = ( (GERBER_DRAW_ITEM*) item )->GetBoundingBox();
diff --git a/include/base_struct.h b/include/base_struct.h
index 367ee9bcc0..28ceee3937 100644
--- a/include/base_struct.h
+++ b/include/base_struct.h
@@ -111,7 +111,7 @@ enum SEARCH_RESULT {
class EDA_ITEM;
class EDA_DRAW_FRAME;
class BOARD;
-class EDA_Rect;
+class EDA_RECT;
class EDA_DRAW_PANEL;
/**
@@ -148,23 +148,23 @@ public:
/**
- * Class EDA_Rect
+ * Class EDA_RECT
* handles the component boundary box.
* This class is similar to wxRect, but some wxRect functions are very curious,
* and are working only if dimensions are >= 0 (not always the case in kicad)
* and also kicad needs some specific method.
* so I prefer this more suitable class
*/
-class EDA_Rect
+class EDA_RECT
{
public:
wxPoint m_Pos; // Rectangle Origin
wxSize m_Size; // Rectangle Size
public:
- EDA_Rect() { };
+ EDA_RECT() { };
- EDA_Rect( const wxPoint& aPos, const wxSize& aSize ) :
+ EDA_RECT( const wxPoint& aPos, const wxSize& aSize ) :
m_Pos( aPos ),
m_Size( aSize )
{ }
@@ -204,10 +204,10 @@ public:
/**
* Function Contains
- * @param aRect = the EDA_Rect to test
+ * @param aRect = the EDA_RECT to test
* @return true if aRect is Contained. A common edge is seen as contained
*/
- bool Contains( const EDA_Rect& aRect ) const;
+ bool Contains( const EDA_RECT& aRect ) const;
wxSize GetSize() const { return m_Size; }
int GetX() const { return m_Pos.x; }
@@ -242,7 +242,7 @@ public:
* @return bool - true if the argument rectangle intersects this rectangle.
* (i.e. if the 2 rectangles have at least a common point)
*/
- bool Intersects( const EDA_Rect& aRect ) const;
+ bool Intersects( const EDA_RECT& aRect ) const;
/**
* Function operator(wxRect)
@@ -255,14 +255,14 @@ public:
* inflates the rectangle horizontally by \a dx and vertically by \a dy. If \a dx
* and/or \a dy is negative the rectangle is deflated.
*/
- EDA_Rect& Inflate( wxCoord dx, wxCoord dy );
+ EDA_RECT& Inflate( wxCoord dx, wxCoord dy );
/**
* Function Inflate
* inflates the rectangle horizontally and vertically by \a aDelta. If \a aDelta
* is negative the rectangle is deflated.
*/
- EDA_Rect& Inflate( int aDelta );
+ EDA_RECT& Inflate( int aDelta );
/**
* Function Merge
@@ -270,7 +270,7 @@ public:
* mainly used to calculate bounding boxes.
* @param aRect The rectangle to merge with this rectangle.
*/
- void Merge( const EDA_Rect& aRect );
+ void Merge( const EDA_RECT& aRect );
/**
* Function Merge
@@ -465,12 +465,12 @@ public:
/**
* Function HitTest (overlaid)
- * tests if the given EDA_Rect intersect this object.
+ * tests if the given EDA_RECT intersect this object.
* For now, an ending point must be inside this rect.
- * @param refArea : the given EDA_Rect
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
- virtual bool HitTest( EDA_Rect& refArea )
+ virtual bool HitTest( EDA_RECT& refArea )
{
return false; // derived classes should override this function
}
@@ -484,7 +484,7 @@ public:
* system.
* It is OK to overestimate the size by a few counts.
*/
- virtual EDA_Rect GetBoundingBox() const
+ virtual EDA_RECT GetBoundingBox() const
{
#if defined(DEBUG)
printf( "Missing GetBoundingBox()\n" );
@@ -493,7 +493,7 @@ public:
// return a zero-sized box per default. derived classes should override
// this
- return EDA_Rect( wxPoint( 0, 0 ), wxSize( 0, 0 ) );
+ return EDA_RECT( wxPoint( 0, 0 ), wxSize( 0, 0 ) );
}
/**
@@ -663,12 +663,12 @@ enum FILL_T {
#define DEFAULT_SIZE_TEXT 60 /* default text height (in mils or 1/1000") */
/**
- * Class EDA_TextStruct
+ * Class EDA_TEXT
* is a basic class to handle texts (labels, texts on components or footprints
* ..) not used directly.
- * The text classes are derived from EDA_ITEM and EDA_TextStruct
+ * The text classes are derived from EDA_ITEM and EDA_TEXT
*/
-class EDA_TextStruct
+class EDA_TEXT
{
public:
wxString m_Text; /* text! */
@@ -689,9 +689,9 @@ public:
* calculations than multiline */
public:
- EDA_TextStruct( const wxString& text = wxEmptyString );
- EDA_TextStruct( const EDA_TextStruct& aText );
- virtual ~EDA_TextStruct();
+ EDA_TEXT( const wxString& text = wxEmptyString );
+ EDA_TEXT( const EDA_TEXT& aText );
+ virtual ~EDA_TEXT();
/**
* Function SetThickness
@@ -744,7 +744,7 @@ private:
/**
* Function DrawOneLineOfText
* Draw a single text line.
- * Used to draw each line of this EDA_TextStruct, that can be multiline
+ * Used to draw each line of this EDA_TEXT, that can be multiline
* @param aPanel = the current DrawPanel
* @param aDC = the current Device Context
* @param aOffset = draw offset (usually (0,0))
@@ -782,7 +782,7 @@ public:
* @param aAccuracy - Amount to inflate the bounding box.
* @return bool - true if a hit, else false
*/
- bool TextHitTest( const EDA_Rect& aRect, bool aContains = false, int aAccuracy = 0 ) const;
+ bool TextHitTest( const EDA_RECT& aRect, bool aContains = false, int aAccuracy = 0 ) const;
/**
* Function LenSize
@@ -806,7 +806,7 @@ public:
* @param aThickness - Overrides the current thickness when greater than 0.
* @param aInvertY - Invert the Y axis when calculating bounding box.
*/
- EDA_Rect GetTextBox( int aLine = -1, int aThickness = -1, bool aInvertY = false ) const;
+ EDA_RECT GetTextBox( int aLine = -1, int aThickness = -1, bool aInvertY = false ) const;
/**
* Function GetInterline
diff --git a/include/block_commande.h b/include/block_commande.h
index 82aa09718d..b4f2e699a6 100644
--- a/include/block_commande.h
+++ b/include/block_commande.h
@@ -53,7 +53,7 @@ typedef enum {
} CmdBlockType;
-class BLOCK_SELECTOR : public EDA_ITEM, public EDA_Rect
+class BLOCK_SELECTOR : public EDA_ITEM, public EDA_RECT
{
public:
BlockState m_State; /* State (enum BlockState)
diff --git a/include/class_collector.h b/include/class_collector.h
index 8d4e85b83d..f74d341aa5 100644
--- a/include/class_collector.h
+++ b/include/class_collector.h
@@ -60,7 +60,7 @@ protected:
wxPoint m_RefPos;
/// A bounding box to test against, and that was used to make the collection.
- EDA_Rect m_RefBox;
+ EDA_RECT m_RefBox;
/// The time at which the collection was made.
int m_TimeAtCollection;
@@ -185,8 +185,8 @@ public:
void SetRefPos( const wxPoint& aRefPos ) { m_RefPos = aRefPos; }
const wxPoint& GetRefPos() const { return m_RefPos; }
- void SetBoundingBox( const EDA_Rect& aRefBox ) { m_RefBox = aRefBox; }
- const EDA_Rect& GetBoundingBox() const { return m_RefBox; }
+ void SetBoundingBox( const EDA_RECT& aRefBox ) { m_RefBox = aRefBox; }
+ const EDA_RECT& GetBoundingBox() const { return m_RefBox; }
/**
diff --git a/include/class_drawpanel.h b/include/class_drawpanel.h
index 720bbe5bdc..8bfea41f82 100644
--- a/include/class_drawpanel.h
+++ b/include/class_drawpanel.h
@@ -36,7 +36,7 @@ private:
int m_cursorLevel; ///< Index for cursor redraw in XOR mode.
public:
- EDA_Rect m_ClipBox; // the clipbox used in screen redraw (usually gives the
+ EDA_RECT m_ClipBox; // the clipbox used in screen redraw (usually gives the
// visible area in internal units)
wxPoint m_CursorStartPos; // useful in testing the cursor movement
int m_scrollIncrementX; // X axis scroll increment in pixels per unit.
@@ -231,7 +231,7 @@ public:
* @param aRect The rectangle to repaint.
* @param aEraseBackground Erases the background if true.
*/
- void RefreshDrawingRect( const EDA_Rect& aRect, bool aEraseBackground = true );
+ void RefreshDrawingRect( const EDA_RECT& aRect, bool aEraseBackground = true );
/**
* Function GetScreenCenterLogicalPosition
diff --git a/include/class_marker_base.h b/include/class_marker_base.h
index 920e15f2b6..cbc3ae379c 100644
--- a/include/class_marker_base.h
+++ b/include/class_marker_base.h
@@ -15,7 +15,7 @@ protected:
std::vector m_Corners; ///< Corner list for shape definition (a polygon)
int m_MarkerType; ///< Can be used as a flag
EDA_Colors m_Color; ///< color
- EDA_Rect m_ShapeBoundingBox; ///< Bounding box of the graphic symbol, relative
+ EDA_RECT m_ShapeBoundingBox; ///< Bounding box of the graphic symbol, relative
///< to the position of the shape, used for Hit
///< Tests
int m_ScalingFactor; ///< Scaling factor for m_Size and m_Corners (can
@@ -190,7 +190,7 @@ public:
* object, and the units should be in the pcb or schematic coordinate system.
* It is OK to overestimate the size by a few counts.
*/
- EDA_Rect GetBoundingBoxMarker() const;
+ EDA_RECT GetBoundingBoxMarker() const;
};
diff --git a/include/gr_basic.h b/include/gr_basic.h
index 12c20e073b..2dbe6a94e2 100644
--- a/include/gr_basic.h
+++ b/include/gr_basic.h
@@ -7,7 +7,7 @@
#include "colors.h"
#include
-class EDA_Rect;
+class EDA_RECT;
#define GR_COPY 0
@@ -65,22 +65,22 @@ void GRForceBlackPen( bool flagforce );
*/
bool GetGRForceBlackPenState( void );
-void GRLine( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd, int aWidth, int aColor );
-void GRLine( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2, int width, int Color );
-void GRMixedLine( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRLine( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd, int aWidth, int aColor );
+void GRLine( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2, int width, int Color );
+void GRMixedLine( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int width, int Color );
-void GRDashedLine( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRDashedLine( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int width, int Color );
-void GRDashedLineTo( EDA_Rect* ClipBox, wxDC* DC, int x2, int y2, int width, int Color );
+void GRDashedLineTo( EDA_RECT* ClipBox, wxDC* DC, int x2, int y2, int width, int Color );
void GRMoveTo( int x, int y );
-void GRLineTo( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int width, int Color );
+void GRLineTo( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int width, int Color );
-void GRPoly( EDA_Rect* ClipBox, wxDC* DC, int n, wxPoint Points[], bool Fill,
+void GRPoly( EDA_RECT* ClipBox, wxDC* DC, int n, wxPoint Points[], bool Fill,
int width, int Color, int BgColor );
-void GRBezier( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRBezier( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int x3, int y3, int width, int Color );
-void GRBezier( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRBezier( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int x3, int y3, int x4, int y4, int width, int Color );
/**
@@ -95,7 +95,7 @@ void GRBezier( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
* @param aPenColor the color index of the border.
* @param aFillColor the fill color of the polygon's interior.
*/
-void GRClosedPoly( EDA_Rect* ClipBox,
+void GRClosedPoly( EDA_RECT* ClipBox,
wxDC * aDC,
int aPointCount,
wxPoint aPoints[],
@@ -119,7 +119,7 @@ void GRClosedPoly( EDA_Rect* ClipBox,
* @param aPenColor the color index of the border.
* @param aFillColor the fill color of the polygon's interior.
*/
-void GRClosedPoly( EDA_Rect* ClipBox,
+void GRClosedPoly( EDA_RECT* ClipBox,
wxDC* aDC,
int aPointCount,
wxPoint aPoints[],
@@ -142,55 +142,55 @@ void GRClosedPoly( EDA_Rect* ClipBox,
* @param aColor is an index into our color table of RGB colors.
* @see EDA_Colors and colors.h
*/
-void GRCircle( EDA_Rect* ClipBox, wxDC* aDC, int x, int y, int aRadius, int aColor );
-void GRCircle( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int r, int width, int Color );
-void GRFilledCircle( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int r, int width,
+void GRCircle( EDA_RECT* ClipBox, wxDC* aDC, int x, int y, int aRadius, int aColor );
+void GRCircle( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int r, int width, int Color );
+void GRFilledCircle( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int r, int width,
int Color, int BgColor );
-void GRFilledCircle( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, int aColor );
-void GRCircle( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, int aWidth, int aColor );
+void GRFilledCircle( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, int aColor );
+void GRCircle( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, int aWidth, int aColor );
-void GRArc( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int StAngle,
+void GRArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int StAngle,
int EndAngle, int r, int Color );
-void GRArc( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int StAngle,
+void GRArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int StAngle,
int EndAngle, int r, int width, int Color );
-void GRArc1( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRArc1( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int xc, int yc, int Color );
-void GRArc1( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRArc1( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int xc, int yc, int width, int Color );
-void GRArc1( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
+void GRArc1( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
wxPoint aCenter, int aWidth, int aColor );
-void GRFilledArc( EDA_Rect* ClipBox, wxDC* DC, int x, int y,
+void GRFilledArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y,
int StAngle, int EndAngle, int r, int Color, int BgColor );
-void GRFilledArc( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int StAngle,
+void GRFilledArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int StAngle,
int EndAngle, int r, int width, int Color, int BgColor );
-void GRCSegm( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2, int width, int Color );
+void GRCSegm( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2, int width, int Color );
-void GRFillCSegm( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRFillCSegm( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int width, int Color );
-void GRFilledSegment( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
+void GRFilledSegment( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
int aWidth, int aColor );
-void GRCSegm( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
+void GRCSegm( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
int width, int aPenSize, int Color );
-void GRCSegm( EDA_Rect* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
+void GRCSegm( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aStart, wxPoint aEnd,
int aWidth, int aColor );
void GRSetColor( int Color );
void GRSetDefaultPalette();
int GRGetColor();
-void GRPutPixel( EDA_Rect* ClipBox, wxDC* DC, int x, int y, int color );
-void GRFilledRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1,
+void GRPutPixel( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int color );
+void GRFilledRect( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1,
int x2, int y2, int Color, int BgColor );
-void GRFilledRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1,
+void GRFilledRect( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1,
int x2, int y2, int width, int Color, int BgColor );
-void GRRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2, int Color );
-void GRRect( EDA_Rect* ClipBox, wxDC* DC,const EDA_Rect& aRect, int aWidth, int Color );
-void GRRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1,
+void GRRect( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2, int Color );
+void GRRect( EDA_RECT* ClipBox, wxDC* DC,const EDA_RECT& aRect, int aWidth, int Color );
+void GRRect( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1,
int x2, int y2, int width, int Color );
-void GRRectPs( EDA_Rect* aClipBox, wxDC* aDC,const EDA_Rect& aRect,
+void GRRectPs( EDA_RECT* aClipBox, wxDC* aDC,const EDA_RECT& aRect,
int aWidth, int aColor, wxPenStyle aStyle = wxPENSTYLE_SOLID );
-void GRSFilledRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1,
+void GRSFilledRect( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1,
int x2, int y2, int width, int Color, int BgColor );
/**
@@ -203,7 +203,7 @@ void GRSFilledRect( EDA_Rect* ClipBox, wxDC* DC, int x1, int y1,
* @param aColor = an index into our color table of RGB colors.
* @see EDA_Colors and colors.h
*/
-void GRLineArray( EDA_Rect* aClipBox, wxDC* aDC,std::vector& aLines,
+void GRLineArray( EDA_RECT* aClipBox, wxDC* aDC,std::vector& aLines,
int aWidth, int aColor );
#endif /* define GR_BASIC */
diff --git a/include/sch_item_struct.h b/include/sch_item_struct.h
index f48e4535ca..793c0f0821 100644
--- a/include/sch_item_struct.h
+++ b/include/sch_item_struct.h
@@ -288,7 +288,7 @@ public:
* @param aAccuracy - Increase aRect by this amount.
* @return True if \a aRect contains or intersects the item bounding box.
*/
- bool HitTest( const EDA_Rect& aRect, bool aContained = false, int aAccuracy = 0 ) const
+ bool HitTest( const EDA_RECT& aRect, bool aContained = false, int aAccuracy = 0 ) const
{
return doHitTest( aRect, aContained, aAccuracy );
}
@@ -309,7 +309,7 @@ private:
return false;
}
- virtual bool doHitTest( const EDA_Rect& aRect, bool aContained, int aAccuracy ) const
+ virtual bool doHitTest( const EDA_RECT& aRect, bool aContained, int aAccuracy ) const
{
return false;
}
diff --git a/include/wxstruct.h b/include/wxstruct.h
index 8a42b4ed82..3f0ba63497 100644
--- a/include/wxstruct.h
+++ b/include/wxstruct.h
@@ -35,7 +35,7 @@
#define KICAD_DEFAULT_DRAWFRAME_STYLE wxDEFAULT_FRAME_STYLE | wxWANTS_CHARS
class EDA_ITEM;
-class EDA_Rect;
+class EDA_RECT;
class EDA_DRAW_PANEL;
class WinEDA_MsgPanel;
class BASE_SCREEN;
@@ -458,7 +458,7 @@ public:
void Zoom_Automatique( bool aWarpPointer );
/* Set the zoom level to show the area Rect */
- void Window_Zoom( EDA_Rect& Rect );
+ void Window_Zoom( EDA_RECT& Rect );
/* Return the zoom level which displays the full page on screen */
virtual int BestZoom() = 0;
diff --git a/pcbnew/autorout.h b/pcbnew/autorout.h
index 71671df795..d53f2a85eb 100644
--- a/pcbnew/autorout.h
+++ b/pcbnew/autorout.h
@@ -65,7 +65,7 @@ public:
bool m_InitBoardDone;
int m_Layers;
int m_GridRouting; // Size of grid for autoplace/autoroute
- EDA_Rect m_BrdBox; // Actual board bouding box
+ EDA_RECT m_BrdBox; // Actual board bouding box
int m_Nrows, m_Ncols;
int m_MemSize;
diff --git a/pcbnew/block_module_editor.cpp b/pcbnew/block_module_editor.cpp
index eac5de463c..486eb76cce 100644
--- a/pcbnew/block_module_editor.cpp
+++ b/pcbnew/block_module_editor.cpp
@@ -26,7 +26,7 @@
static void DrawMovingBlockOutlines( EDA_DRAW_PANEL* aPanel, wxDC* aDC, const wxPoint& aPosition,
bool aErase );
-static int MarkItemsInBloc( MODULE* module, EDA_Rect& Rect );
+static int MarkItemsInBloc( MODULE* module, EDA_RECT& Rect );
static void ClearMarkItems( MODULE* module );
static void CopyMarkedItems( MODULE* module, wxPoint offset );
@@ -637,7 +637,7 @@ void ClearMarkItems( MODULE* module )
/* Mark items inside rect.
* Items are inside rect when an end point is inside rect
*/
-int MarkItemsInBloc( MODULE* module, EDA_Rect& Rect )
+int MarkItemsInBloc( MODULE* module, EDA_RECT& Rect )
{
EDA_ITEM* item;
int ItemsCount = 0;
diff --git a/pcbnew/board.cpp b/pcbnew/board.cpp
index 0e250e9e6c..ba5c8af53c 100644
--- a/pcbnew/board.cpp
+++ b/pcbnew/board.cpp
@@ -243,7 +243,7 @@ void PlaceCells( BOARD* aPcb, int net_code, int flag )
if( PtText->GetLength() == 0 )
break;
- EDA_Rect textbox = PtText->GetTextBox( -1 );
+ EDA_RECT textbox = PtText->GetTextBox( -1 );
ux0 = textbox.GetX(); uy0 = textbox.GetY();
dx = textbox.GetWidth();
dy = textbox.GetHeight();
diff --git a/pcbnew/board_items_to_polygon_shape_transform.cpp b/pcbnew/board_items_to_polygon_shape_transform.cpp
index c0968abf19..137a9a29d4 100644
--- a/pcbnew/board_items_to_polygon_shape_transform.cpp
+++ b/pcbnew/board_items_to_polygon_shape_transform.cpp
@@ -102,7 +102,7 @@ void TEXTE_PCB::TransformShapeWithClearanceToPolygon(
CPolyPt corners[4]; // Buffer of polygon corners
- EDA_Rect rect = GetTextBox( -1 );
+ EDA_RECT rect = GetTextBox( -1 );
rect.Inflate( aClearanceValue );
corners[0].x = rect.GetOrigin().x;
corners[0].y = rect.GetOrigin().y;
diff --git a/pcbnew/class_board.cpp b/pcbnew/class_board.cpp
index dcf318182c..aa6237eac8 100644
--- a/pcbnew/class_board.cpp
+++ b/pcbnew/class_board.cpp
@@ -795,7 +795,7 @@ bool BOARD::ComputeBoundingBox( bool aBoardEdgesOnly )
if( aBoardEdgesOnly )
break;
- EDA_Rect rect = ((DIMENSION*) PtStruct)->GetBoundingBox();
+ EDA_RECT rect = ((DIMENSION*) PtStruct)->GetBoundingBox();
xmin = MIN( xmin, rect.GetX() );
ymin = MIN( ymin, rect.GetY() );
xmax = MAX( xmax, rect.GetRight() );
@@ -808,7 +808,7 @@ bool BOARD::ComputeBoundingBox( bool aBoardEdgesOnly )
if( aBoardEdgesOnly )
break;
- EDA_Rect rect = ((TEXTE_PCB*) PtStruct)->GetTextBox( -1 );
+ EDA_RECT rect = ((TEXTE_PCB*) PtStruct)->GetTextBox( -1 );
xmin = MIN( xmin, rect.GetX() );
ymin = MIN( ymin, rect.GetY() );
xmax = MAX( xmax, rect.GetRight() );
@@ -821,7 +821,7 @@ bool BOARD::ComputeBoundingBox( bool aBoardEdgesOnly )
if( aBoardEdgesOnly )
break;
- EDA_Rect rect = ((DIMENSION*) PtStruct)->GetBoundingBox();
+ EDA_RECT rect = ((DIMENSION*) PtStruct)->GetBoundingBox();
xmin = MIN( xmin, rect.GetX() );
ymin = MIN( ymin, rect.GetY() );
xmax = MAX( xmax, rect.GetRight() );
@@ -839,7 +839,7 @@ bool BOARD::ComputeBoundingBox( bool aBoardEdgesOnly )
// Check modules
for( MODULE* module = m_Modules; module; module = module->Next() )
{
- EDA_Rect bBox = module->GetBoundingBox();
+ EDA_RECT bBox = module->GetBoundingBox();
xmin = MIN( xmin, bBox.GetX() );
ymin = MIN( ymin, bBox.GetY() );
xmax = MAX( xmax, bBox.GetRight() );
@@ -881,7 +881,7 @@ bool BOARD::ComputeBoundingBox( bool aBoardEdgesOnly )
for( unsigned int i = 0; i < m_ZoneDescriptorList.size(); i++ )
{
ZONE_CONTAINER* aZone = m_ZoneDescriptorList[i];
- EDA_Rect bBox = aZone->GetBoundingBox();
+ EDA_RECT bBox = aZone->GetBoundingBox();
xmin = MIN( xmin, bBox.GetX() );
ymin = MIN( ymin, bBox.GetY() );
xmax = MAX( xmax, bBox.GetRight() );
diff --git a/pcbnew/class_board.h b/pcbnew/class_board.h
index 178607ccd2..087dce0499 100644
--- a/pcbnew/class_board.h
+++ b/pcbnew/class_board.h
@@ -112,7 +112,7 @@ private:
public:
PCB_BASE_FRAME* m_PcbFrame; // Window of visualization
- EDA_Rect m_BoundaryBox; // Board size and position
+ EDA_RECT m_BoundaryBox; // Board size and position
int m_Status_Pcb; // Flags used in ratsnet calculation and update
int m_NbNodes; // Active pads (pads attached to a net ) count
int m_NbNoconnect; // Active ratsnet count (rastnests not already connected by tracks)
diff --git a/pcbnew/class_dimension.cpp b/pcbnew/class_dimension.cpp
index f811716c1e..5dd116124f 100644
--- a/pcbnew/class_dimension.cpp
+++ b/pcbnew/class_dimension.cpp
@@ -727,11 +727,11 @@ bool DIMENSION::HitTest( const wxPoint& ref_pos )
/**
* Function HitTest (overlaid)
- * tests if the given EDA_Rect intersect this object.
- * @param refArea : the given EDA_Rect
+ * tests if the given EDA_RECT intersect this object.
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
-bool DIMENSION::HitTest( EDA_Rect& refArea )
+bool DIMENSION::HitTest( EDA_RECT& refArea )
{
if( refArea.Contains( m_Pos ) )
return true;
@@ -739,9 +739,9 @@ bool DIMENSION::HitTest( EDA_Rect& refArea )
}
-EDA_Rect DIMENSION::GetBoundingBox() const
+EDA_RECT DIMENSION::GetBoundingBox() const
{
- EDA_Rect bBox;
+ EDA_RECT bBox;
int xmin, xmax, ymin, ymax;
bBox = m_Text->GetTextBox( -1 );
diff --git a/pcbnew/class_dimension.h b/pcbnew/class_dimension.h
index 30cb13a8c1..8bd05557de 100644
--- a/pcbnew/class_dimension.h
+++ b/pcbnew/class_dimension.h
@@ -115,12 +115,12 @@ public:
/**
* Function HitTest (overlaid)
- * tests if the given EDA_Rect intersect this object.
+ * tests if the given EDA_RECT intersect this object.
* For now, the anchor must be inside this rect.
- * @param refArea : the given EDA_Rect
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
- bool HitTest( EDA_Rect& refArea );
+ bool HitTest( EDA_RECT& refArea );
/**
@@ -133,7 +133,7 @@ public:
return wxT( "DIMENSION" );
}
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
};
#endif // #define DIMENSION_H
diff --git a/pcbnew/class_drawsegment.cpp b/pcbnew/class_drawsegment.cpp
index 61a573a8af..e8534af457 100644
--- a/pcbnew/class_drawsegment.cpp
+++ b/pcbnew/class_drawsegment.cpp
@@ -466,12 +466,12 @@ bool DRAWSEGMENT::HitTest( const wxPoint& aRefPos )
/**
* Function HitTest (overlayed)
- * tests if the given EDA_Rect intersect this object.
+ * tests if the given EDA_RECT intersect this object.
* For now, for arcs and segments, an ending point must be inside this rect.
- * @param refArea : the given EDA_Rect
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
-bool DRAWSEGMENT::HitTest( EDA_Rect& refArea )
+bool DRAWSEGMENT::HitTest( EDA_RECT& refArea )
{
switch(m_Shape)
{
@@ -479,7 +479,7 @@ bool DRAWSEGMENT::HitTest( EDA_Rect& refArea )
{
int radius = GetRadius();
// Text if area intersects the circle:
- EDA_Rect area = refArea;
+ EDA_RECT area = refArea;
area.Inflate(radius);
if( area.Contains(m_Start) )
return true;
diff --git a/pcbnew/class_drawsegment.h b/pcbnew/class_drawsegment.h
index a252e63cd5..a8ad61b0e7 100644
--- a/pcbnew/class_drawsegment.h
+++ b/pcbnew/class_drawsegment.h
@@ -99,12 +99,12 @@ public:
/**
* Function HitTest (overlayed)
- * tests if the given EDA_Rect intersect this object.
+ * tests if the given EDA_RECT intersect this object.
* For now, an ending point must be inside this rect.
- * @param refArea the given EDA_Rect to test
+ * @param refArea the given EDA_RECT to test
* @return bool - true if a hit, else false
*/
- bool HitTest( EDA_Rect& refArea );
+ bool HitTest( EDA_RECT& refArea );
/**
* Function GetClass
diff --git a/pcbnew/class_edge_mod.cpp b/pcbnew/class_edge_mod.cpp
index 4396a5f720..fb06b4e0e6 100644
--- a/pcbnew/class_edge_mod.cpp
+++ b/pcbnew/class_edge_mod.cpp
@@ -62,9 +62,9 @@ void EDGE_MODULE::Copy( EDGE_MODULE* source )
* object, and the units should be in the pcb or schematic coordinate system.
* It is OK to overestimate the size by a few counts.
*/
-EDA_Rect EDGE_MODULE::GetBoundingBox() const
+EDA_RECT EDGE_MODULE::GetBoundingBox() const
{
- EDA_Rect bbox;
+ EDA_RECT bbox;
bbox.SetOrigin( m_Start );
@@ -573,12 +573,12 @@ bool EDGE_MODULE::HitTest( const wxPoint& refPos )
/**
* Function HitTest (overlayed)
- * tests if the given EDA_Rect intersect this object.
+ * tests if the given EDA_RECT intersect this object.
* For now, for arcs and segments, an ending point must be inside this rect.
- * @param refArea : the given EDA_Rect
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
-bool EDGE_MODULE::HitTest( EDA_Rect& refArea )
+bool EDGE_MODULE::HitTest( EDA_RECT& refArea )
{
switch(m_Shape)
{
@@ -586,7 +586,7 @@ bool EDGE_MODULE::HitTest( EDA_Rect& refArea )
{
int radius = GetRadius();
// Test if area intersects the circle:
- EDA_Rect area = refArea;
+ EDA_RECT area = refArea;
area.Inflate(radius);
if( area.Contains(m_Start) )
return true;
diff --git a/pcbnew/class_edge_mod.h b/pcbnew/class_edge_mod.h
index 3edf869a00..50959f62ce 100644
--- a/pcbnew/class_edge_mod.h
+++ b/pcbnew/class_edge_mod.h
@@ -104,7 +104,7 @@ public:
* object, and the units should be in the pcb or schematic coordinate system.
* It is OK to overestimate the size by a few counts.
*/
- virtual EDA_Rect GetBoundingBox() const;
+ virtual EDA_RECT GetBoundingBox() const;
/**
* Function HitTest
@@ -116,12 +116,12 @@ public:
/**
* Function HitTest (overlayed)
- * tests if the given EDA_Rect intersect this object.
+ * tests if the given EDA_RECT intersect this object.
* For now, for segments and arcs, an ending point must be inside this rect.
- * @param refArea the given EDA_Rect to test
+ * @param refArea the given EDA_RECT to test
* @return bool - true if a hit, else false
*/
- bool HitTest( EDA_Rect& refArea );
+ bool HitTest( EDA_RECT& refArea );
/**
* Function GetClass
diff --git a/pcbnew/class_mire.cpp b/pcbnew/class_mire.cpp
index fe2daa027f..af5679d491 100644
--- a/pcbnew/class_mire.cpp
+++ b/pcbnew/class_mire.cpp
@@ -188,11 +188,11 @@ bool MIREPCB::HitTest( const wxPoint& refPos )
/**
* Function HitTest (overlayed)
- * tests if the given EDA_Rect intersect this object.
- * @param refArea : the given EDA_Rect
+ * tests if the given EDA_RECT intersect this object.
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
-bool MIREPCB::HitTest( EDA_Rect& refArea )
+bool MIREPCB::HitTest( EDA_RECT& refArea )
{
if( refArea.Contains( m_Pos ) )
return true;
@@ -224,9 +224,9 @@ void MIREPCB::Flip(const wxPoint& aCentre )
}
-EDA_Rect MIREPCB::GetBoundingBox() const
+EDA_RECT MIREPCB::GetBoundingBox() const
{
- EDA_Rect bBox;
+ EDA_RECT bBox;
bBox.SetX( m_Pos.x - m_Size/2 );
bBox.SetY( m_Pos.y - m_Size/2 );
bBox.SetWidth( m_Size );
diff --git a/pcbnew/class_mire.h b/pcbnew/class_mire.h
index deb4f42da3..c0adc8da06 100644
--- a/pcbnew/class_mire.h
+++ b/pcbnew/class_mire.h
@@ -80,14 +80,14 @@ public:
/**
* Function HitTest (overlaid)
- * tests if the given EDA_Rect intersect this object.
+ * tests if the given EDA_RECT intersect this object.
* For now, the anchor must be inside this rect.
- * @param refArea : the given EDA_Rect
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
- bool HitTest( EDA_Rect& refArea );
+ bool HitTest( EDA_RECT& refArea );
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
};
diff --git a/pcbnew/class_module.cpp b/pcbnew/class_module.cpp
index 5fe6e0cf5a..7666749710 100644
--- a/pcbnew/class_module.cpp
+++ b/pcbnew/class_module.cpp
@@ -710,9 +710,9 @@ void MODULE::Set_Rectangle_Encadrement()
}
-EDA_Rect MODULE::GetFootPrintRect() const
+EDA_RECT MODULE::GetFootPrintRect() const
{
- EDA_Rect area;
+ EDA_RECT area;
area.m_Pos = m_Pos;
area.SetEnd( m_Pos );
@@ -753,12 +753,12 @@ void MODULE::SetRectangleExinscrit()
* returns the full bounding box of this Footprint, including fields
* Mainly used to redraw the screen area occupied by the footprint
*/
-EDA_Rect MODULE::GetBoundingBox() const
+EDA_RECT MODULE::GetBoundingBox() const
{
- EDA_Rect area = GetFootPrintRect();
+ EDA_RECT area = GetFootPrintRect();
// Calculate extended area including text field:
- EDA_Rect text_area;
+ EDA_RECT text_area;
text_area = m_Reference->GetBoundingBox();
area.Merge( text_area );
@@ -885,11 +885,11 @@ bool MODULE::HitTest( const wxPoint& refPos )
/**
* Function HitTest (overlaid)
- * tests if the given EDA_Rect intersect the bounds of this object.
- * @param refArea : the given EDA_Rect
+ * tests if the given EDA_RECT intersect the bounds of this object.
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
-bool MODULE::HitTest( EDA_Rect& refArea )
+bool MODULE::HitTest( EDA_RECT& refArea )
{
bool is_out_of_box = false;
diff --git a/pcbnew/class_module.h b/pcbnew/class_module.h
index 44cf0e4437..9b9d8c049c 100644
--- a/pcbnew/class_module.h
+++ b/pcbnew/class_module.h
@@ -53,9 +53,9 @@ public:
* routing. */
int m_ModuleStatus; /* For autoplace: flags (LOCKED,
* AUTOPLACED) */
- EDA_Rect m_BoundaryBox; /* Bounding box coordinates relatives
+ EDA_RECT m_BoundaryBox; /* Bounding box coordinates relatives
* to the anchor, orient 0*/
- EDA_Rect m_RealBoundaryBox; /* Bounding box : coordinates on board,
+ EDA_RECT m_RealBoundaryBox; /* Bounding box : coordinates on board,
* real orientation */
int m_PadNum; // Pad count
int m_AltPadNum; /* Pad with netcode > 0 (active pads)
@@ -129,14 +129,14 @@ public:
* Function GetFootPrintRect()
* Returns the area of the module footprint excluding any text.
*/
- EDA_Rect GetFootPrintRect() const;
+ EDA_RECT GetFootPrintRect() const;
/**
* Function GetBoundingBox
* returns the bounding box of this Footprint
* Mainly used to redraw the screen area occupied by the footprint
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/**
* Function GetPosition
@@ -264,11 +264,11 @@ public:
/**
* Function HitTest (overlaid)
- * tests if the given EDA_Rect intersect the bounds of this object.
- * @param refArea : the given EDA_Rect
+ * tests if the given EDA_RECT intersect the bounds of this object.
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
- bool HitTest( EDA_Rect& refArea );
+ bool HitTest( EDA_RECT& refArea );
/**
* Function GetReference
diff --git a/pcbnew/class_pad.cpp b/pcbnew/class_pad.cpp
index edcf0eff28..4e0efbf02a 100644
--- a/pcbnew/class_pad.cpp
+++ b/pcbnew/class_pad.cpp
@@ -103,9 +103,9 @@ void D_PAD::ComputeShapeMaxRadius()
* returns the bounding box of this pad
* Mainly used to redraw the screen area occupied by the pad
*/
-EDA_Rect D_PAD::GetBoundingBox() const
+EDA_RECT D_PAD::GetBoundingBox() const
{
- EDA_Rect area;
+ EDA_RECT area;
int radius = GetMaxRadius(); // Calculate the radius of the area, considered as a circle
area.SetOrigin( m_Pos );
diff --git a/pcbnew/class_pad.h b/pcbnew/class_pad.h
index 7418015752..253e88c5a8 100644
--- a/pcbnew/class_pad.h
+++ b/pcbnew/class_pad.h
@@ -245,7 +245,7 @@ public:
* basic function to draw a pad.
* used by Draw after calculation of parameters (color, ) final orientation ...
*/
- void DrawShape( EDA_Rect* aClipBox, wxDC* aDC, PAD_DRAWINFO& aDrawInfo );
+ void DrawShape( EDA_RECT* aClipBox, wxDC* aDC, PAD_DRAWINFO& aDrawInfo );
/**
* Function BuildPadPolygon
@@ -334,7 +334,7 @@ public:
* returns the bounding box of this pad
* Mainly used to redraw the screen area occupied by the pad
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/**
* Function Compare
diff --git a/pcbnew/class_pad_draw_functions.cpp b/pcbnew/class_pad_draw_functions.cpp
index 4a95c9fc8e..719d88688b 100644
--- a/pcbnew/class_pad_draw_functions.cpp
+++ b/pcbnew/class_pad_draw_functions.cpp
@@ -348,7 +348,7 @@ void D_PAD::Draw( EDA_DRAW_PANEL* aPanel, wxDC* aDC, int aDraw_mode, const wxPoi
* this function can be called to draw a pad on a panel
* even if this panel is not a EDA_DRAW_PANEL (for instance on a wxPanel inside the pad editor)
*/
-void D_PAD::DrawShape( EDA_Rect* aClipBox, wxDC* aDC, PAD_DRAWINFO& aDrawInfo )
+void D_PAD::DrawShape( EDA_RECT* aClipBox, wxDC* aDC, PAD_DRAWINFO& aDrawInfo )
{
wxPoint coord[4];
int delta_cx, delta_cy;
diff --git a/pcbnew/class_pcb_text.cpp b/pcbnew/class_pcb_text.cpp
index ab8da9e85c..7c2ca00a5f 100644
--- a/pcbnew/class_pcb_text.cpp
+++ b/pcbnew/class_pcb_text.cpp
@@ -24,7 +24,7 @@
TEXTE_PCB::TEXTE_PCB( BOARD_ITEM* parent ) :
BOARD_ITEM( parent, TYPE_TEXTE ),
- EDA_TextStruct()
+ EDA_TEXT()
{
m_MultilineAllowed = true;
}
@@ -208,7 +208,7 @@ void TEXTE_PCB::Draw( EDA_DRAW_PANEL* panel, wxDC* DC,
if( brd->IsElementVisible( ANCHOR_VISIBLE ) )
anchor_color = brd->GetVisibleElementColor(ANCHOR_VISIBLE);
- EDA_TextStruct::Draw( panel, DC, offset, (EDA_Colors) color,
+ EDA_TEXT::Draw( panel, DC, offset, (EDA_Colors) color,
DrawMode, fillmode, (EDA_Colors) anchor_color );
}
diff --git a/pcbnew/class_pcb_text.h b/pcbnew/class_pcb_text.h
index 1d892297d1..25a8f3456d 100644
--- a/pcbnew/class_pcb_text.h
+++ b/pcbnew/class_pcb_text.h
@@ -8,7 +8,7 @@
#include "PolyLine.h"
#include "richio.h"
-class TEXTE_PCB : public BOARD_ITEM, public EDA_TextStruct
+class TEXTE_PCB : public BOARD_ITEM, public EDA_TEXT
{
public:
TEXTE_PCB( BOARD_ITEM* parent );
@@ -23,7 +23,7 @@ public:
*/
wxPoint& GetPosition()
{
- return m_Pos; // within EDA_TextStruct
+ return m_Pos; // within EDA_TEXT
}
/**
@@ -93,11 +93,11 @@ public:
/**
* Function HitTest (overlaid)
- * tests if the given EDA_Rect intersect this object.
- * @param refArea the given EDA_Rect to test
+ * tests if the given EDA_RECT intersect this object.
+ * @param refArea the given EDA_RECT to test
* @return bool - true if a hit, else false
*/
- bool HitTest( EDA_Rect& refArea )
+ bool HitTest( EDA_RECT& refArea )
{
return TextHitTest( refArea );
}
diff --git a/pcbnew/class_text_mod.cpp b/pcbnew/class_text_mod.cpp
index 93f9253ebd..582b769df4 100644
--- a/pcbnew/class_text_mod.cpp
+++ b/pcbnew/class_text_mod.cpp
@@ -21,7 +21,7 @@
/*******************************************************************/
TEXTE_MODULE::TEXTE_MODULE( MODULE* parent, int text_type ) :
- BOARD_ITEM( parent, TYPE_TEXTE_MODULE ), EDA_TextStruct()
+ BOARD_ITEM( parent, TYPE_TEXTE_MODULE ), EDA_TEXT()
{
MODULE* Module = (MODULE*) m_Parent;
@@ -248,12 +248,12 @@ void TEXTE_MODULE:: SetLocalCoord()
/**
* Function GetTextRect
- * @return an EDA_Rect which gives the position and size of the text area
+ * @return an EDA_RECT which gives the position and size of the text area
* (for the footprint orientation)
*/
-EDA_Rect TEXTE_MODULE::GetTextRect( void ) const
+EDA_RECT TEXTE_MODULE::GetTextRect( void ) const
{
- EDA_Rect area;
+ EDA_RECT area;
int dx, dy;
@@ -283,7 +283,7 @@ EDA_Rect TEXTE_MODULE::GetTextRect( void ) const
bool TEXTE_MODULE::HitTest( const wxPoint& aRefPos )
{
wxPoint rel_pos;
- EDA_Rect area = GetTextRect();
+ EDA_RECT area = GetTextRect();
/* Rotate refPos to - angle
* to test if refPos is within area (which is relative to an horizontal
@@ -304,10 +304,10 @@ bool TEXTE_MODULE::HitTest( const wxPoint& aRefPos )
* returns the bounding box of this Text (according to text and footprint
* orientation)
*/
-EDA_Rect TEXTE_MODULE::GetBoundingBox() const
+EDA_RECT TEXTE_MODULE::GetBoundingBox() const
{
// Calculate area without text fields:
- EDA_Rect text_area;
+ EDA_RECT text_area;
int angle = GetDrawRotation();
wxPoint textstart, textend;
diff --git a/pcbnew/class_text_mod.h b/pcbnew/class_text_mod.h
index 7bb9b38ac4..9e8bd88560 100644
--- a/pcbnew/class_text_mod.h
+++ b/pcbnew/class_text_mod.h
@@ -14,7 +14,7 @@
#define UMBILICAL_COLOR LIGHTBLUE
-class TEXTE_MODULE : public BOARD_ITEM, public EDA_TextStruct
+class TEXTE_MODULE : public BOARD_ITEM, public EDA_TEXT
{
/* Note: orientation in 1/10 deg relative to the footprint
* Physical orient is m_Orient + m_Parent->m_Orient
@@ -54,17 +54,17 @@ public: TEXTE_MODULE( MODULE* parent, int text_type = TEXT_is_DIVERS );
/**
* Function GetTextRect
- * @return an EDA_Rect which gives the position and size of the text area
+ * @return an EDA_RECT which gives the position and size of the text area
* (for the 0 orient text and footprint)
*/
- EDA_Rect GetTextRect( void ) const;
+ EDA_RECT GetTextRect( void ) const;
/**
* Function GetBoundingBox
* returns the bounding box of this Text (according to text and footprint
* orientation)
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
void SetDrawCoord(); // Set absolute coordinates.
diff --git a/pcbnew/class_track.cpp b/pcbnew/class_track.cpp
index 80a2afbd21..61ae63c130 100644
--- a/pcbnew/class_track.cpp
+++ b/pcbnew/class_track.cpp
@@ -212,7 +212,7 @@ int TRACK::IsPointOnEnds( const wxPoint& point, int min_dist )
}
-EDA_Rect TRACK::GetBoundingBox() const
+EDA_RECT TRACK::GetBoundingBox() const
{
// end of track is round, this is its radius, rounded up
int radius = ( m_Width + 1 ) / 2;
@@ -262,7 +262,7 @@ EDA_Rect TRACK::GetBoundingBox() const
xmin -= radius;
// return a rectangle which is [pos,dim) in nature. therefore the +1
- EDA_Rect ret( wxPoint( xmin, ymin ), wxSize( xmax - xmin + 1, ymax - ymin + 1 ) );
+ EDA_RECT ret( wxPoint( xmin, ymin ), wxSize( xmax - xmin + 1, ymax - ymin + 1 ) );
return ret;
}
@@ -1131,12 +1131,12 @@ bool TRACK::HitTest( const wxPoint& refPos )
/**
* Function HitTest (overlaid)
- * tests if the given EDA_Rect intersect this object.
+ * tests if the given EDA_RECT intersect this object.
* For now, an ending point must be inside this rect.
- * @param refArea an EDA_Rect to test
+ * @param refArea an EDA_RECT to test
* @return bool - true if a hit, else false
*/
-bool TRACK::HitTest( EDA_Rect& refArea )
+bool TRACK::HitTest( EDA_RECT& refArea )
{
if( refArea.Contains( m_Start ) )
return true;
diff --git a/pcbnew/class_track.h b/pcbnew/class_track.h
index ad085b5ef2..5e086eaa0c 100644
--- a/pcbnew/class_track.h
+++ b/pcbnew/class_track.h
@@ -96,7 +96,7 @@ public:
return m_Start; // it had to be start or end.
}
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/**
* Function Save
@@ -259,10 +259,10 @@ public:
* Function HitTest (overlaid)
* tests if the given wxRect intersect this object.
* For now, an ending point must be inside this rect.
- * @param refArea an EDA_Rect to test
+ * @param refArea an EDA_RECT to test
* @return bool - true if a hit, else false
*/
- bool HitTest( EDA_Rect& refArea );
+ bool HitTest( EDA_RECT& refArea );
/**
* Function GetClass
diff --git a/pcbnew/class_zone.cpp b/pcbnew/class_zone.cpp
index 53c60378d4..861c87eae1 100644
--- a/pcbnew/class_zone.cpp
+++ b/pcbnew/class_zone.cpp
@@ -686,7 +686,7 @@ void ZONE_CONTAINER::DrawFilledArea( EDA_DRAW_PANEL* panel,
}
-EDA_Rect ZONE_CONTAINER::GetBoundingBox() const
+EDA_RECT ZONE_CONTAINER::GetBoundingBox() const
{
const int PRELOAD = 0x7FFFFFFF; // Biggest integer (32 bits)
@@ -707,7 +707,7 @@ EDA_Rect ZONE_CONTAINER::GetBoundingBox() const
xmin = MIN( xmin, corner.x );
}
- EDA_Rect ret( wxPoint( xmin, ymin ), wxSize( xmax - xmin + 1, ymax - ymin + 1 ) );
+ EDA_RECT ret( wxPoint( xmin, ymin ), wxSize( xmax - xmin + 1, ymax - ymin + 1 ) );
return ret;
}
@@ -905,11 +905,11 @@ bool ZONE_CONTAINER::HitTestForEdge( const wxPoint& refPos )
/**
* Function HitTest (overlayed)
- * tests if the given EDA_Rect contains the bounds of this object.
- * @param refArea : the given EDA_Rect
+ * tests if the given EDA_RECT contains the bounds of this object.
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
-bool ZONE_CONTAINER::HitTest( EDA_Rect& refArea )
+bool ZONE_CONTAINER::HitTest( EDA_RECT& refArea )
{
bool is_out_of_box = false;
diff --git a/pcbnew/class_zone.h b/pcbnew/class_zone.h
index 407dcdc6c3..02f7f0e2cc 100644
--- a/pcbnew/class_zone.h
+++ b/pcbnew/class_zone.h
@@ -134,9 +134,9 @@ public:
/* Function GetBoundingBox
- * @return an EDA_Rect that is the bounding box of the zone outline
+ * @return an EDA_RECT that is the bounding box of the zone outline
*/
- EDA_Rect GetBoundingBox() const;
+ EDA_RECT GetBoundingBox() const;
/**
* Function Test_For_Copper_Island_And_Remove__Insulated_Islands
@@ -149,11 +149,11 @@ public:
* Function CalculateSubAreaBoundaryBox
* Calculates the bounding box of a a filled area ( list of CPolyPt )
* use m_FilledPolysList as list of CPolyPt (that are the corners of one or more polygons or filled areas )
- * @return an EDA_Rect as bounding box
+ * @return an EDA_RECT as bounding box
* @param aIndexStart = index of the first corner of a polygon (filled area) in m_FilledPolysList
* @param aIndexEnd = index of the last corner of a polygon in m_FilledPolysList
*/
- EDA_Rect CalculateSubAreaBoundaryBox( int aIndexStart, int aIndexEnd );
+ EDA_RECT CalculateSubAreaBoundaryBox( int aIndexStart, int aIndexEnd );
/**
* Function IsOnCopperLayer
@@ -260,11 +260,11 @@ public:
/**
* Function HitTest (overlayed)
- * tests if the given EDA_Rect contains the bounds of this object.
- * @param refArea : the given EDA_Rect
+ * tests if the given EDA_RECT contains the bounds of this object.
+ * @param refArea : the given EDA_RECT
* @return bool - true if a hit, else false
*/
- bool HitTest( EDA_Rect& refArea );
+ bool HitTest( EDA_RECT& refArea );
/**
* Function Fill_Zone
diff --git a/pcbnew/dialogs/dialog_SVG_print.cpp b/pcbnew/dialogs/dialog_SVG_print.cpp
index 65d654f30a..ba31bfeed3 100644
--- a/pcbnew/dialogs/dialog_SVG_print.cpp
+++ b/pcbnew/dialogs/dialog_SVG_print.cpp
@@ -242,7 +242,7 @@ bool DIALOG_SVG_PRINT::DrawPage( const wxString& FullFileName,
// to print floating point numbers like 1.3)
wxSVGFileDC dc( FullFileName, SheetSize.x, SheetSize.y, dpi );
- EDA_Rect tmp = panel->m_ClipBox;
+ EDA_RECT tmp = panel->m_ClipBox;
GRResetPenAndBrush( &dc );
GRForceBlackPen( m_ModeColorOption->GetSelection() == 0 ? false : true );
s_Parameters.m_DrillShapeOpt = PRINT_PARAMETERS::FULL_DRILL_SHAPE;
diff --git a/pcbnew/edtxtmod.cpp b/pcbnew/edtxtmod.cpp
index 92425c1572..1a2d1170fa 100644
--- a/pcbnew/edtxtmod.cpp
+++ b/pcbnew/edtxtmod.cpp
@@ -269,7 +269,7 @@ void PCB_BASE_FRAME::ResetTextSize( BOARD_ITEM* aItem, wxDC* aDC )
int newThickness;
TEXTE_PCB* pcbText = NULL;
TEXTE_MODULE* moduleText = NULL;
- EDA_TextStruct* text;
+ EDA_TEXT* text;
switch( aItem->Type() )
{
@@ -277,13 +277,13 @@ void PCB_BASE_FRAME::ResetTextSize( BOARD_ITEM* aItem, wxDC* aDC )
newSize = GetBoard()->GetBoardDesignSettings()->m_PcbTextSize;
newThickness = GetBoard()->GetBoardDesignSettings()->m_PcbTextWidth;
pcbText = (TEXTE_PCB*) aItem;
- text = (EDA_TextStruct*) pcbText;
+ text = (EDA_TEXT*) pcbText;
break;
case TYPE_TEXTE_MODULE:
newSize = g_ModuleTextSize;
newThickness = g_ModuleTextWidth;
moduleText = (TEXTE_MODULE*) aItem;
- text = (EDA_TextStruct*) moduleText;
+ text = (EDA_TEXT*) moduleText;
break;
default:
// Exit if aItem is not a text field
diff --git a/pcbnew/printout_controler.cpp b/pcbnew/printout_controler.cpp
index 4fbc31ad35..a1b6c34847 100644
--- a/pcbnew/printout_controler.cpp
+++ b/pcbnew/printout_controler.cpp
@@ -139,7 +139,7 @@ void BOARD_PRINTOUT_CONTROLER::DrawPage()
PCB_BASE_FRAME* pcbframe = (PCB_BASE_FRAME*) m_Parent;
pcbframe->GetBoard()->ComputeBoundingBox();
- EDA_Rect brd_BBox = pcbframe->GetBoard()->m_BoundaryBox;
+ EDA_RECT brd_BBox = pcbframe->GetBoard()->m_BoundaryBox;
// In module editor, the module is located at 0,0 but for printing
// it is moved to SheetSize.x/2, SheetSize.y/2.
@@ -236,7 +236,7 @@ void BOARD_PRINTOUT_CONTROLER::DrawPage()
EDA_DRAW_PANEL* panel = m_Parent->DrawPanel;
- EDA_Rect tmp = panel->m_ClipBox;
+ EDA_RECT tmp = panel->m_ClipBox;
// Set clip box to the max size
#define MAX_VALUE (INT_MAX/2) // MAX_VALUE is the max we can use in an integer
diff --git a/pcbnew/zone_filling_algorithm.cpp b/pcbnew/zone_filling_algorithm.cpp
index b022ebcbba..0861e475a4 100644
--- a/pcbnew/zone_filling_algorithm.cpp
+++ b/pcbnew/zone_filling_algorithm.cpp
@@ -136,7 +136,7 @@ int ZONE_CONTAINER::Fill_Zone_Areas_With_Segments()
if ( corner->end_contour || (ic == end_list) )
{
iend = ic;
- EDA_Rect rect = CalculateSubAreaBoundaryBox( istart, iend );
+ EDA_RECT rect = CalculateSubAreaBoundaryBox( istart, iend );
// Calculate the y limits of the zone
int refy = rect.GetY();
diff --git a/pcbnew/zones_by_polygon.cpp b/pcbnew/zones_by_polygon.cpp
index 809bf5442e..f81a40873a 100644
--- a/pcbnew/zones_by_polygon.cpp
+++ b/pcbnew/zones_by_polygon.cpp
@@ -847,7 +847,7 @@ void PCB_EDIT_FRAME::Delete_Zone_Contour( wxDC* DC, ZONE_CONTAINER* zone_contain
{
int ncont = zone_container->m_Poly->GetContour( zone_container->m_CornerSelection );
- EDA_Rect dirty = zone_container->GetBoundingBox();
+ EDA_RECT dirty = zone_container->GetBoundingBox();
Delete_Zone_Fill( NULL, zone_container->m_TimeStamp ); // Remove fill segments
diff --git a/pcbnew/zones_convert_brd_items_to_polygons_with_Boost.cpp b/pcbnew/zones_convert_brd_items_to_polygons_with_Boost.cpp
index 0c46914474..0ec3df286a 100644
--- a/pcbnew/zones_convert_brd_items_to_polygons_with_Boost.cpp
+++ b/pcbnew/zones_convert_brd_items_to_polygons_with_Boost.cpp
@@ -160,8 +160,8 @@ void ZONE_CONTAINER::AddClearanceAreasPolygonsToPolysList( BOARD* aPcb )
/* items ouside the zone bounding box are skipped
* the bounding box is the zone bounding box + the biggest clearance found in Netclass list
*/
- EDA_Rect item_boundingbox;
- EDA_Rect zone_boundingbox = GetBoundingBox();
+ EDA_RECT item_boundingbox;
+ EDA_RECT zone_boundingbox = GetBoundingBox();
int biggest_clearance = aPcb->GetBiggestClearanceValue();
biggest_clearance = MAX( biggest_clearance, zone_clearance );
zone_boundingbox.Inflate( biggest_clearance );
diff --git a/pcbnew/zones_convert_brd_items_to_polygons_with_Kbool.cpp b/pcbnew/zones_convert_brd_items_to_polygons_with_Kbool.cpp
index a423872567..901844ba29 100644
--- a/pcbnew/zones_convert_brd_items_to_polygons_with_Kbool.cpp
+++ b/pcbnew/zones_convert_brd_items_to_polygons_with_Kbool.cpp
@@ -192,8 +192,8 @@ void ZONE_CONTAINER::AddClearanceAreasPolygonsToPolysList( BOARD* aPcb )
/* items ouside the zone bounding box are skipped
* the bounding box is the zone bounding box + the biggest clearance found in Netclass list
*/
- EDA_Rect item_boundingbox;
- EDA_Rect zone_boundingbox = GetBoundingBox();
+ EDA_RECT item_boundingbox;
+ EDA_RECT zone_boundingbox = GetBoundingBox();
int biggest_clearance = aPcb->GetBiggestClearanceValue();
biggest_clearance = MAX( biggest_clearance, zone_clearance );
zone_boundingbox.Inflate( biggest_clearance );
diff --git a/pcbnew/zones_convert_to_polygons_aux_functions.cpp b/pcbnew/zones_convert_to_polygons_aux_functions.cpp
index 5a2655b255..011db3bbb8 100644
--- a/pcbnew/zones_convert_to_polygons_aux_functions.cpp
+++ b/pcbnew/zones_convert_to_polygons_aux_functions.cpp
@@ -41,8 +41,8 @@ void BuildUnconnectedThermalStubsPolygonList( std::vector& aCornerBuffe
int zone_clearance = aZone->m_ZoneClearance;
- EDA_Rect item_boundingbox;
- EDA_Rect zone_boundingbox = aZone->GetBoundingBox();
+ EDA_RECT item_boundingbox;
+ EDA_RECT zone_boundingbox = aZone->GetBoundingBox();
int biggest_clearance = aPcb->GetBiggestClearanceValue();
biggest_clearance = MAX( biggest_clearance, zone_clearance );
zone_boundingbox.Inflate( biggest_clearance );
diff --git a/pcbnew/zones_polygons_insulated_copper_islands.cpp b/pcbnew/zones_polygons_insulated_copper_islands.cpp
index c6cf341fb2..becac384ce 100644
--- a/pcbnew/zones_polygons_insulated_copper_islands.cpp
+++ b/pcbnew/zones_polygons_insulated_copper_islands.cpp
@@ -82,7 +82,7 @@ void ZONE_CONTAINER::Test_For_Copper_Island_And_Remove_Insulated_Islands( BOARD
{
if( m_FilledPolysList[indexend].end_contour ) // end of a filled sub-area found
{
- EDA_Rect bbox =
+ EDA_RECT bbox =
CalculateSubAreaBoundaryBox( indexstart,
indexend );
for( unsigned ic = 0;
@@ -122,20 +122,20 @@ void ZONE_CONTAINER::Test_For_Copper_Island_And_Remove_Insulated_Islands( BOARD
/**************************************************************************************/
-EDA_Rect ZONE_CONTAINER::CalculateSubAreaBoundaryBox( int aIndexStart, int aIndexEnd )
+EDA_RECT ZONE_CONTAINER::CalculateSubAreaBoundaryBox( int aIndexStart, int aIndexEnd )
/**************************************************************************************/
/**
* Function CalculateSubAreaBoundaryBox
* Calculates the bounding box of a a filled area ( list of CPolyPt )
* use m_FilledPolysList as list of CPolyPt (that are the corners of one or more polygons or filled areas )
- * @return an EDA_Rect as bounding box
+ * @return an EDA_RECT as bounding box
* @param aIndexStart = index of the first corner of a polygon (filled area) in m_FilledPolysList
* @param aIndexEnd = index of the last corner of a polygon in m_FilledPolysList
*/
{
CPolyPt start_point, end_point;
- EDA_Rect bbox;
+ EDA_RECT bbox;
start_point = m_FilledPolysList[aIndexStart];
end_point = start_point;
diff --git a/pcbnew/zones_polygons_test_connections.cpp b/pcbnew/zones_polygons_test_connections.cpp
index b42ac20e1a..2db393e965 100644
--- a/pcbnew/zones_polygons_test_connections.cpp
+++ b/pcbnew/zones_polygons_test_connections.cpp
@@ -107,7 +107,7 @@ void BOARD::Test_Connections_To_Copper_Areas( int aNetcode )
if( curr_zone->m_FilledPolysList[indexend].end_contour ) // end of a filled sub-area found
{
subnet++;
- EDA_Rect bbox = curr_zone->CalculateSubAreaBoundaryBox( indexstart, indexend );
+ EDA_RECT bbox = curr_zone->CalculateSubAreaBoundaryBox( indexstart, indexend );
for( unsigned ic = 0; ic < Candidates.size(); ic++ )
{ // test if this area is connected to a board item:
item = Candidates[ic];