mirror of
https://gitlab.com/kicad/code/kicad.git
synced 2025-04-20 21:01:22 +00:00
Migrated the interfaces accepting angles to the double type
The plan goes like this: - eeschema still uses int in decidegrees - all the other things internally use double in decidegrees (or radians in temporaries) - in pcbnew UI the unit is *still* int in decidegrees The idea is to have better precision everywhere while keeping the user with int i angles. Hopefully, if a fractional angle doesn't come in from the outside, everything should *look* like an integer angle (unless I forgot something and it broke) When the time comes, simply updating the UI for allowing doubles from the user should be enough to get arbitrary angles in pcbnew.
This commit is contained in:
parent
cb49ca5ae2
commit
d00c83cde9
3d-viewer
common
class_plotter.cppcommon_plotDXF_functions.cppcommon_plotGERBER_functions.cppcommon_plotHPGL_functions.cppcommon_plotPDF_functions.cppcommon_plotPS_functions.cppcommon_plotSVG_functions.cppconvert_basic_shapes_to_polygon.cppdrawtxt.cppgr_basic.cpp
eeschema
gerbview
include
pcbnew
autorouter
board_items_to_polygon_shape_transform.cppclass_drawsegment.cppclass_pad.cppclass_pad.hclass_pad_draw_functions.cppclass_text_mod.cppclass_text_mod.hclass_track.cppdialogs
dialog_edit_module_text.cppdialog_graphic_item_properties.cppdialog_graphic_item_properties_for_Modedit.cppdialog_orient_footprints.cpp
drc_clearance_test_functions.cppdrc_stuff.hedtxtmod.cppexport_gencad.cppexport_vrml.cppgendrill_Excellon_writer.hglobaleditpad.cppmodules.cpppcad2kicadpcb_plugin
plot_brditems_plotter.cppzones_convert_brd_items_to_polygons_with_Boost.cppzones_convert_to_polygons_aux_functions.cpp@ -370,7 +370,7 @@ void Draw3D_SolidSegment( const wxPoint& aStart, const wxPoint& aEnd,
|
||||
|
||||
|
||||
void Draw3D_ArcSegment( const wxPoint& aCenterPos, const wxPoint& aStartPoint,
|
||||
int aArcAngle, int aWidth, int aThickness,
|
||||
double aArcAngle, int aWidth, int aThickness,
|
||||
int aZpos, double aBiuTo3DUnits )
|
||||
{
|
||||
const int slice = SEGM_PER_CIRCLE;
|
||||
|
@ -85,7 +85,7 @@ void Draw3D_SolidSegment( const wxPoint& aStart, const wxPoint& aEnd,
|
||||
* @param aBiuTo3DUnits = board internal units to 3D units scaling value
|
||||
*/
|
||||
void Draw3D_ArcSegment( const wxPoint& aCenterPos, const wxPoint& aStartPoint,
|
||||
int aArcAngle, int aWidth, int aThickness,
|
||||
double aArcAngle, int aWidth, int aThickness,
|
||||
int aZpos, double aBiuTo3DUnits );
|
||||
|
||||
|
||||
|
@ -111,33 +111,29 @@ double PLOTTER::userToDeviceSize( double size )
|
||||
/**
|
||||
* Generic fallback: arc rendered as a polyline
|
||||
*/
|
||||
void PLOTTER::Arc( const wxPoint& centre, int StAngle, int EndAngle, int radius,
|
||||
void PLOTTER::Arc( const wxPoint& centre, double StAngle, double EndAngle, int radius,
|
||||
FILL_T fill, int width )
|
||||
{
|
||||
wxPoint start, end;
|
||||
const int delta = 50; // increment (in 0.1 degrees) to draw circles
|
||||
double alpha;
|
||||
|
||||
if( StAngle > EndAngle )
|
||||
EXCHG( StAngle, EndAngle );
|
||||
|
||||
SetCurrentLineWidth( width );
|
||||
/* Please NOTE the different sign due to Y-axis flip */
|
||||
alpha = DEG2RAD( StAngle / 10.0 );
|
||||
start.x = centre.x + (int) ( radius * cos( -alpha ) );
|
||||
start.y = centre.y + (int) ( radius * sin( -alpha ) );
|
||||
start.x = centre.x + KiROUND( cosdecideg( radius, -StAngle ) );
|
||||
start.y = centre.y + KiROUND( sindecideg( radius, -StAngle ) );
|
||||
MoveTo( start );
|
||||
for( int ii = StAngle + delta; ii < EndAngle; ii += delta )
|
||||
{
|
||||
alpha = DEG2RAD( ii / 10.0 );
|
||||
end.x = centre.x + (int) ( radius * cos( -alpha ) );
|
||||
end.y = centre.y + (int) ( radius * sin( -alpha ) );
|
||||
end.x = centre.x + KiROUND( cosdecideg( radius, -ii ) );
|
||||
end.y = centre.y + KiROUND( sindecideg( radius, -ii ) );
|
||||
LineTo( end );
|
||||
}
|
||||
|
||||
alpha = DEG2RAD( EndAngle / 10.0 );
|
||||
end.x = centre.x + (int) ( radius * cos( -alpha ) );
|
||||
end.y = centre.y + (int) ( radius * sin( -alpha ) );
|
||||
end.x = centre.x + KiROUND( cosdecideg( radius, -EndAngle ) );
|
||||
end.y = centre.y + KiROUND( sindecideg( radius, -EndAngle ) );
|
||||
FinishTo( end );
|
||||
}
|
||||
|
||||
@ -380,7 +376,7 @@ void PLOTTER::segmentAsOval( const wxPoint& start, const wxPoint& end, int width
|
||||
{
|
||||
wxPoint center( (start.x + end.x) / 2, (start.y + end.y) / 2 );
|
||||
wxSize size( end.x - start.x, end.y - start.y );
|
||||
int orient;
|
||||
double orient;
|
||||
|
||||
if( size.y == 0 )
|
||||
orient = 0;
|
||||
@ -396,7 +392,7 @@ void PLOTTER::segmentAsOval( const wxPoint& start, const wxPoint& end, int width
|
||||
}
|
||||
|
||||
|
||||
void PLOTTER::sketchOval( const wxPoint& pos, const wxSize& aSize, int orient,
|
||||
void PLOTTER::sketchOval( const wxPoint& pos, const wxSize& aSize, double orient,
|
||||
int width )
|
||||
{
|
||||
SetCurrentLineWidth( width );
|
||||
@ -467,8 +463,8 @@ void PLOTTER::ThickSegment( const wxPoint& start, const wxPoint& end, int width,
|
||||
}
|
||||
|
||||
|
||||
void PLOTTER::ThickArc( const wxPoint& centre, int StAngle, int EndAngle, int radius,
|
||||
int width, EDA_DRAW_MODE_T tracemode )
|
||||
void PLOTTER::ThickArc( const wxPoint& centre, double StAngle, double EndAngle,
|
||||
int radius, int width, EDA_DRAW_MODE_T tracemode )
|
||||
{
|
||||
switch( tracemode )
|
||||
{
|
||||
|
@ -389,7 +389,7 @@ void DXF_PLOTTER::ThickSegment( const wxPoint& aStart, const wxPoint& aEnd, int
|
||||
/** Plot an arc in DXF format
|
||||
* Filling is not supported
|
||||
*/
|
||||
void DXF_PLOTTER::Arc( const wxPoint& centre, int StAngle, int EndAngle, int radius,
|
||||
void DXF_PLOTTER::Arc( const wxPoint& centre, double StAngle, double EndAngle, int radius,
|
||||
FILL_T fill, int width )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
@ -412,7 +412,7 @@ void DXF_PLOTTER::Arc( const wxPoint& centre, int StAngle, int EndAngle, int rad
|
||||
/**
|
||||
* DXF oval pad: always done in sketch mode
|
||||
*/
|
||||
void DXF_PLOTTER::FlashPadOval( const wxPoint& pos, const wxSize& aSize, int orient,
|
||||
void DXF_PLOTTER::FlashPadOval( const wxPoint& pos, const wxSize& aSize, double orient,
|
||||
EDA_DRAW_MODE_T trace_mode )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
@ -445,7 +445,7 @@ void DXF_PLOTTER::FlashPadCircle( const wxPoint& pos, int diametre,
|
||||
* DXF rectangular pad: alwayd done in sketch mode
|
||||
*/
|
||||
void DXF_PLOTTER::FlashPadRect( const wxPoint& pos, const wxSize& padsize,
|
||||
int orient, EDA_DRAW_MODE_T trace_mode )
|
||||
double orient, EDA_DRAW_MODE_T trace_mode )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
wxSize size;
|
||||
@ -513,7 +513,7 @@ void DXF_PLOTTER::FlashPadRect( const wxPoint& pos, const wxSize& padsize,
|
||||
* DXF trapezoidal pad: only sketch mode is supported
|
||||
*/
|
||||
void DXF_PLOTTER::FlashPadTrapez( const wxPoint& aPadPos, const wxPoint *aCorners,
|
||||
int aPadOrient, EDA_DRAW_MODE_T aTrace_Mode )
|
||||
double aPadOrient, EDA_DRAW_MODE_T aTrace_Mode )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
wxPoint coord[4]; /* coord actual corners of a trapezoidal trace */
|
||||
@ -555,7 +555,7 @@ bool containsNonAsciiChars( const wxString& string )
|
||||
void DXF_PLOTTER::Text( const wxPoint& aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
|
@ -282,7 +282,7 @@ void GERBER_PLOTTER::Circle( const wxPoint& aCenter, int aDiameter, FILL_T aFill
|
||||
}
|
||||
|
||||
|
||||
void GERBER_PLOTTER::Arc( const wxPoint& aCenter, int aStAngle, int aEndAngle,
|
||||
void GERBER_PLOTTER::Arc( const wxPoint& aCenter, double aStAngle, double aEndAngle,
|
||||
int aRadius, FILL_T aFill, int aWidth )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
@ -370,7 +370,7 @@ void GERBER_PLOTTER::FlashPadCircle( const wxPoint& pos, int diametre,
|
||||
/**
|
||||
* Filled oval flashes are handled as aperture in the 90 degree positions only
|
||||
*/
|
||||
void GERBER_PLOTTER::FlashPadOval( const wxPoint& pos, const wxSize& aSize, int orient,
|
||||
void GERBER_PLOTTER::FlashPadOval( const wxPoint& pos, const wxSize& aSize, double orient,
|
||||
EDA_DRAW_MODE_T trace_mode )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
@ -427,7 +427,7 @@ void GERBER_PLOTTER::FlashPadOval( const wxPoint& pos, const wxSize& aSize, int
|
||||
* Filled rect flashes are handled as aperture in the 90 degree positions only
|
||||
*/
|
||||
void GERBER_PLOTTER::FlashPadRect( const wxPoint& pos, const wxSize& aSize,
|
||||
int orient, EDA_DRAW_MODE_T trace_mode )
|
||||
double orient, EDA_DRAW_MODE_T trace_mode )
|
||||
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
@ -494,7 +494,7 @@ void GERBER_PLOTTER::FlashPadRect( const wxPoint& pos, const wxSize& aSize,
|
||||
* they require aperture macros
|
||||
*/
|
||||
void GERBER_PLOTTER::FlashPadTrapez( const wxPoint& aPadPos, const wxPoint* aCorners,
|
||||
int aPadOrient, EDA_DRAW_MODE_T aTrace_Mode )
|
||||
double aPadOrient, EDA_DRAW_MODE_T aTrace_Mode )
|
||||
|
||||
{
|
||||
// XXX to do: use an aperture macro to declare the pad
|
||||
|
@ -381,7 +381,7 @@ void HPGL_PLOTTER::ThickSegment( const wxPoint& start, const wxPoint& end,
|
||||
* PU PY x, y; PD start_arc_X AA, start_arc_Y, angle, NbSegm; PU;
|
||||
* Or PU PY x, y; PD start_arc_X AA, start_arc_Y, angle, PU;
|
||||
*/
|
||||
void HPGL_PLOTTER::Arc( const wxPoint& centre, int StAngle, int EndAngle, int radius,
|
||||
void HPGL_PLOTTER::Arc( const wxPoint& centre, double StAngle, double EndAngle, int radius,
|
||||
FILL_T fill, int width )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
@ -419,7 +419,7 @@ void HPGL_PLOTTER::Arc( const wxPoint& centre, int StAngle, int EndAngle, int ra
|
||||
|
||||
/* Plot oval pad.
|
||||
*/
|
||||
void HPGL_PLOTTER::FlashPadOval( const wxPoint& pos, const wxSize& aSize, int orient,
|
||||
void HPGL_PLOTTER::FlashPadOval( const wxPoint& pos, const wxSize& aSize, double orient,
|
||||
EDA_DRAW_MODE_T trace_mode )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
@ -499,7 +499,7 @@ void HPGL_PLOTTER::FlashPadCircle( const wxPoint& pos, int diametre,
|
||||
|
||||
|
||||
void HPGL_PLOTTER::FlashPadRect( const wxPoint& pos, const wxSize& padsize,
|
||||
int orient, EDA_DRAW_MODE_T trace_mode )
|
||||
double orient, EDA_DRAW_MODE_T trace_mode )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
wxSize size;
|
||||
@ -616,7 +616,7 @@ void HPGL_PLOTTER::FlashPadRect( const wxPoint& pos, const wxSize& padsize,
|
||||
|
||||
|
||||
void HPGL_PLOTTER::FlashPadTrapez( const wxPoint& aPadPos, const wxPoint* aCorners,
|
||||
int aPadOrient, EDA_DRAW_MODE_T aTrace_Mode )
|
||||
double aPadOrient, EDA_DRAW_MODE_T aTrace_Mode )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
wxPoint polygone[4]; // coordinates of corners relatives to the pad
|
||||
|
@ -201,7 +201,7 @@ void PDF_PLOTTER::Circle( const wxPoint& pos, int diametre, FILL_T aFill, int wi
|
||||
* The PDF engine can't directly plot arcs, it uses the base emulation.
|
||||
* So no filled arcs (not a great loss... )
|
||||
*/
|
||||
void PDF_PLOTTER::Arc( const wxPoint& centre, int StAngle, int EndAngle, int radius,
|
||||
void PDF_PLOTTER::Arc( const wxPoint& centre, double StAngle, double EndAngle, int radius,
|
||||
FILL_T fill, int width )
|
||||
{
|
||||
wxASSERT( workFile );
|
||||
@ -735,7 +735,7 @@ bool PDF_PLOTTER::EndPlot()
|
||||
void PDF_PLOTTER::Text( const wxPoint& aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
|
@ -64,7 +64,7 @@ void PSLIKE_PLOTTER::SetColor( EDA_COLOR_T color )
|
||||
}
|
||||
|
||||
|
||||
void PSLIKE_PLOTTER::FlashPadOval( const wxPoint& pos, const wxSize& aSize, int orient,
|
||||
void PSLIKE_PLOTTER::FlashPadOval( const wxPoint& pos, const wxSize& aSize, double orient,
|
||||
EDA_DRAW_MODE_T modetrace )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
@ -115,7 +115,7 @@ void PSLIKE_PLOTTER::FlashPadCircle( const wxPoint& pos, int diametre,
|
||||
|
||||
|
||||
void PSLIKE_PLOTTER::FlashPadRect( const wxPoint& pos, const wxSize& aSize,
|
||||
int orient, EDA_DRAW_MODE_T trace_mode )
|
||||
double orient, EDA_DRAW_MODE_T trace_mode )
|
||||
{
|
||||
static std::vector< wxPoint > cornerList;
|
||||
wxSize size( aSize );
|
||||
@ -159,7 +159,7 @@ void PSLIKE_PLOTTER::FlashPadRect( const wxPoint& pos, const wxSize& aSize,
|
||||
|
||||
|
||||
void PSLIKE_PLOTTER::FlashPadTrapez( const wxPoint& aPadPos, const wxPoint *aCorners,
|
||||
int aPadOrient, EDA_DRAW_MODE_T aTrace_Mode )
|
||||
double aPadOrient, EDA_DRAW_MODE_T aTrace_Mode )
|
||||
{
|
||||
static std::vector< wxPoint > cornerList;
|
||||
cornerList.clear();
|
||||
@ -471,8 +471,8 @@ void PS_PLOTTER::Circle( const wxPoint& pos, int diametre, FILL_T fill, int widt
|
||||
}
|
||||
|
||||
|
||||
void PS_PLOTTER::Arc( const wxPoint& centre, int StAngle, int EndAngle, int radius,
|
||||
FILL_T fill, int width )
|
||||
void PS_PLOTTER::Arc( const wxPoint& centre, double StAngle, double EndAngle,
|
||||
int radius, FILL_T fill, int width )
|
||||
{
|
||||
wxASSERT( outputFile );
|
||||
if( radius <= 0 )
|
||||
@ -805,7 +805,7 @@ bool PS_PLOTTER::EndPlot()
|
||||
void PS_PLOTTER::Text( const wxPoint& aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
|
@ -321,7 +321,7 @@ void SVG_PLOTTER::Circle( const wxPoint& pos, int diametre, FILL_T fill, int wid
|
||||
}
|
||||
|
||||
|
||||
void SVG_PLOTTER::Arc( const wxPoint& centre, int StAngle, int EndAngle, int radius,
|
||||
void SVG_PLOTTER::Arc( const wxPoint& centre, double StAngle, double EndAngle, int radius,
|
||||
FILL_T fill, int width )
|
||||
{
|
||||
/* Draws an arc of a circle, centred on (xc,yc), with starting point
|
||||
@ -347,7 +347,7 @@ void SVG_PLOTTER::Arc( const wxPoint& centre, int StAngle, int EndAngle, int rad
|
||||
|
||||
if( !plotMirror )
|
||||
{
|
||||
int tmp = StAngle;
|
||||
double tmp = StAngle;
|
||||
StAngle = -EndAngle;
|
||||
EndAngle = -tmp;
|
||||
}
|
||||
@ -550,7 +550,7 @@ bool SVG_PLOTTER::EndPlot()
|
||||
void SVG_PLOTTER::Text( const wxPoint& aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
|
@ -174,8 +174,8 @@ void TransformRoundedEndsSegmentToPolygon( CPOLYGONS_LIST& aCornerBuffer,
|
||||
startp = aEnd;
|
||||
}
|
||||
|
||||
int delta_angle = ArcTangente( endp.y, endp.x ); // delta_angle is in 0.1 degrees
|
||||
int seg_len = KiROUND( EuclideanNorm( endp ) );
|
||||
double delta_angle = ArcTangente( endp.y, endp.x ); // delta_angle is in 0.1 degrees
|
||||
int seg_len = KiROUND( EuclideanNorm( endp ) );
|
||||
|
||||
int delta = 3600 / aCircleToSegmentsCount; // rot angle in 0.1 degree
|
||||
|
||||
@ -237,7 +237,7 @@ void TransformRoundedEndsSegmentToPolygon( CPOLYGONS_LIST& aCornerBuffer,
|
||||
* @param aWidth = width (thickness) of the line
|
||||
*/
|
||||
void TransformArcToPolygon( CPOLYGONS_LIST& aCornerBuffer,
|
||||
wxPoint aCentre, wxPoint aStart, int aArcAngle,
|
||||
wxPoint aCentre, wxPoint aStart, double aArcAngle,
|
||||
int aCircleToSegmentsCount, int aWidth )
|
||||
{
|
||||
wxPoint arc_start, arc_end;
|
||||
|
@ -266,7 +266,7 @@ void DrawGraphicText( EDA_DRAW_PANEL* aPanel,
|
||||
const wxPoint& aPos,
|
||||
EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
@ -566,7 +566,7 @@ void DrawGraphicHaloText( EDA_DRAW_PANEL * aPanel,
|
||||
enum EDA_COLOR_T aColor1,
|
||||
enum EDA_COLOR_T aColor2,
|
||||
const wxString &aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize &aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
@ -611,7 +611,7 @@ void DrawGraphicHaloText( EDA_DRAW_PANEL * aPanel,
|
||||
void PLOTTER::Text( const wxPoint& aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
|
@ -746,7 +746,7 @@ void GRCSegm( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
|
||||
}
|
||||
else
|
||||
{
|
||||
int delta_angle = ArcTangente( dy, dx );
|
||||
double delta_angle = ArcTangente( dy, dx );
|
||||
dwx = 0;
|
||||
dwy = width;
|
||||
RotatePoint( &dwx, &dwy, -delta_angle );
|
||||
@ -1107,8 +1107,8 @@ void GRFilledArc( EDA_RECT* ClipBox,
|
||||
wxDC* DC,
|
||||
int x,
|
||||
int y,
|
||||
int StAngle,
|
||||
int EndAngle,
|
||||
double StAngle,
|
||||
double EndAngle,
|
||||
int r,
|
||||
int width,
|
||||
EDA_COLOR_T Color,
|
||||
@ -1153,7 +1153,8 @@ void GRFilledArc( EDA_RECT* ClipBox,
|
||||
|
||||
|
||||
void GRFilledArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y,
|
||||
int StAngle, int EndAngle, int r, EDA_COLOR_T Color, EDA_COLOR_T BgColor )
|
||||
double StAngle, double EndAngle, int r,
|
||||
EDA_COLOR_T Color, EDA_COLOR_T BgColor )
|
||||
{
|
||||
GRFilledArc( ClipBox, DC, x, y, StAngle, EndAngle, r, 0, Color, BgColor );
|
||||
}
|
||||
@ -1162,8 +1163,8 @@ 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,
|
||||
int EndAngle, int r, EDA_COLOR_T Color )
|
||||
void GRArc( EDA_RECT* ClipBox, wxDC* DC, int xc, int yc, double StAngle,
|
||||
double EndAngle, int r, EDA_COLOR_T Color )
|
||||
{
|
||||
int x1, y1, x2, y2;
|
||||
|
||||
@ -1210,8 +1211,8 @@ void GRArc( EDA_RECT* ClipBox,
|
||||
wxDC* DC,
|
||||
int x,
|
||||
int y,
|
||||
int StAngle,
|
||||
int EndAngle,
|
||||
double StAngle,
|
||||
double EndAngle,
|
||||
int r,
|
||||
int width,
|
||||
EDA_COLOR_T Color )
|
||||
|
@ -748,7 +748,7 @@ void LIB_ARC::calcEdit( const wxPoint& aPosition )
|
||||
// artifacts left behind from the initial draw.
|
||||
int dx, dy;
|
||||
int cX, cY;
|
||||
int angle;
|
||||
double angle;
|
||||
|
||||
cX = aPosition.x;
|
||||
cY = aPosition.y;
|
||||
|
@ -140,7 +140,7 @@ void AM_PRIMITIVE::DrawBasicShape( GERBER_DRAW_ITEM* aParent,
|
||||
|
||||
wxPoint curPos = aShapePos;
|
||||
D_CODE* tool = aParent->GetDcodeDescr();
|
||||
int rotation;
|
||||
double rotation;
|
||||
if( mapExposure( aParent ) == false )
|
||||
{
|
||||
EXCHG(aColor, aAltColor);
|
||||
@ -272,7 +272,7 @@ void AM_PRIMITIVE::DrawBasicShape( GERBER_DRAW_ITEM* aParent,
|
||||
for( int ii = 0; ii < 4; ii++ )
|
||||
{
|
||||
subshape_poly = polybuffer;
|
||||
int sub_rotation = rotation + 900 * ii;
|
||||
double sub_rotation = rotation + 900 * ii;
|
||||
for( unsigned jj = 0; jj < subshape_poly.size(); jj++ )
|
||||
RotatePoint( &subshape_poly[jj], -sub_rotation );
|
||||
|
||||
@ -459,7 +459,7 @@ void AM_PRIMITIVE::ConvertShapeToPolygon( GERBER_DRAW_ITEM* aParent,
|
||||
aBuffer.push_back( currpt );
|
||||
|
||||
// Rotate rectangle and move it to the actual start point
|
||||
int angle = ArcTangente( delta.y, delta.x );
|
||||
double angle = ArcTangente( delta.y, delta.x );
|
||||
|
||||
for( unsigned ii = 0; ii < 4; ii++ )
|
||||
{
|
||||
@ -512,16 +512,15 @@ void AM_PRIMITIVE::ConvertShapeToPolygon( GERBER_DRAW_ITEM* aParent,
|
||||
int outerRadius = scaletoIU( params[2].GetValue( tool ), m_GerbMetric ) / 2;
|
||||
int innerRadius = scaletoIU( params[3].GetValue( tool ), m_GerbMetric ) / 2;
|
||||
int halfthickness = scaletoIU( params[4].GetValue( tool ), m_GerbMetric ) / 2;
|
||||
int angle_start = RAD2DECIDEG( asin( (double) halfthickness / innerRadius ) );
|
||||
double angle_start = RAD2DECIDEG( asin( (double) halfthickness / innerRadius ) );
|
||||
|
||||
// Draw shape in the first cadrant (X and Y > 0)
|
||||
wxPoint pos, startpos;
|
||||
|
||||
// Inner arc
|
||||
startpos.x = innerRadius;
|
||||
int angle_end = 900 - angle_start;
|
||||
int angle;
|
||||
for( angle = angle_start; angle < angle_end; angle += 100 )
|
||||
double angle_end = 900 - angle_start;
|
||||
for( double angle = angle_start; angle < angle_end; angle += 100 )
|
||||
{
|
||||
pos = startpos;
|
||||
RotatePoint( &pos, angle );
|
||||
@ -540,7 +539,7 @@ void AM_PRIMITIVE::ConvertShapeToPolygon( GERBER_DRAW_ITEM* aParent,
|
||||
angle_end = 900 - angle_start;
|
||||
|
||||
// First point, near Y axis, outer arc
|
||||
for( angle = angle_end; angle > angle_start; angle -= 100 )
|
||||
for( double angle = angle_end; angle > angle_start; angle -= 100 )
|
||||
{
|
||||
pos = startpos;
|
||||
RotatePoint( &pos, angle );
|
||||
|
@ -115,7 +115,7 @@ wxPoint GERBER_DRAW_ITEM::GetABPosition( const wxPoint& aXYPosition ) const
|
||||
abPos += m_layerOffset + m_imageParams->m_ImageOffset;
|
||||
abPos.x = KiROUND( abPos.x * m_drawScale.x );
|
||||
abPos.y = KiROUND( abPos.y * m_drawScale.y );
|
||||
int rotation = m_lyrRotation * 10 + m_imageParams->m_ImageRotation * 10;
|
||||
double rotation = m_lyrRotation * 10 + m_imageParams->m_ImageRotation * 10;
|
||||
|
||||
if( rotation )
|
||||
RotatePoint( &abPos, -rotation );
|
||||
@ -142,7 +142,7 @@ wxPoint GERBER_DRAW_ITEM::GetXYPosition( const wxPoint& aABPosition )
|
||||
if( !m_mirrorB )
|
||||
NEGATE( xyPos.y );
|
||||
|
||||
int rotation = m_lyrRotation * 10 + m_imageParams->m_ImageRotation * 10;
|
||||
double rotation = m_lyrRotation * 10 + m_imageParams->m_ImageRotation * 10;
|
||||
|
||||
if( rotation )
|
||||
RotatePoint( &xyPos, rotation );
|
||||
|
@ -502,7 +502,7 @@ void D_CODE::ConvertShapeToPolygon()
|
||||
for( unsigned ii = 0; ii <= SEGS_CNT; ii++ )
|
||||
{
|
||||
currpos = initialpos;
|
||||
RotatePoint( &currpos, ii * 3600 / SEGS_CNT );
|
||||
RotatePoint( &currpos, ii * 3600.0 / SEGS_CNT );
|
||||
m_PolyCorners.push_back( currpos );
|
||||
}
|
||||
|
||||
@ -552,7 +552,7 @@ void D_CODE::ConvertShapeToPolygon()
|
||||
for( ; ii <= SEGS_CNT / 2; ii++ )
|
||||
{
|
||||
currpos = initialpos;
|
||||
RotatePoint( &currpos, ii * 3600 / SEGS_CNT );
|
||||
RotatePoint( &currpos, ii * 3600.0 / SEGS_CNT );
|
||||
currpos.x += delta;
|
||||
m_PolyCorners.push_back( currpos );
|
||||
}
|
||||
@ -561,7 +561,7 @@ void D_CODE::ConvertShapeToPolygon()
|
||||
for( ii = SEGS_CNT / 2; ii <= SEGS_CNT; ii++ )
|
||||
{
|
||||
currpos = initialpos;
|
||||
RotatePoint( &currpos, ii * 3600 / SEGS_CNT );
|
||||
RotatePoint( &currpos, ii * 3600.0 / SEGS_CNT );
|
||||
currpos.x -= delta;
|
||||
m_PolyCorners.push_back( currpos );
|
||||
}
|
||||
@ -592,7 +592,7 @@ void D_CODE::ConvertShapeToPolygon()
|
||||
for( int ii = 0; ii <= m_EdgesCount; ii++ )
|
||||
{
|
||||
currpos = initialpos;
|
||||
RotatePoint( &currpos, ii * 3600 / m_EdgesCount );
|
||||
RotatePoint( &currpos, ii * 3600.0 / m_EdgesCount );
|
||||
m_PolyCorners.push_back( currpos );
|
||||
}
|
||||
|
||||
@ -633,7 +633,7 @@ static void addHoleToPolygon( std::vector<wxPoint>& aBuffer,
|
||||
{
|
||||
currpos.x = 0;
|
||||
currpos.y = aSize.x / 2; // aSize.x / 2 is the radius of the hole
|
||||
RotatePoint( &currpos, ii * 3600 / SEGS_CNT );
|
||||
RotatePoint( &currpos, ii * 3600.0 / SEGS_CNT );
|
||||
aBuffer.push_back( currpos );
|
||||
}
|
||||
|
||||
|
@ -353,7 +353,8 @@ void GBR_LAYOUT::Draw( EDA_DRAW_PANEL* aPanel, wxDC* aDC, GR_DRAWMODE aDrawMode,
|
||||
void GERBVIEW_FRAME::DrawItemsDCodeID( wxDC* aDC, GR_DRAWMODE aDrawMode )
|
||||
{
|
||||
wxPoint pos;
|
||||
int width, orient;
|
||||
int width;
|
||||
double orient;
|
||||
wxString Line;
|
||||
|
||||
GRSetDrawMode( aDC, aDrawMode );
|
||||
|
@ -339,8 +339,8 @@ static void fillArcPOLY( GERBER_DRAW_ITEM* aGbrItem,
|
||||
* angle is trigonometrical (counter-clockwise),
|
||||
* and axis is the X,Y gerber coordinates
|
||||
*/
|
||||
int start_angle = ArcTangente( start.y, start.x );
|
||||
int end_angle = ArcTangente( end.y, end.x );
|
||||
double start_angle = ArcTangente( start.y, start.x );
|
||||
double end_angle = ArcTangente( end.y, end.x );
|
||||
|
||||
// dummyTrack has right geometric parameters, but
|
||||
// fillArcGBRITEM calculates arc parameters for a draw function that expects
|
||||
@ -350,7 +350,7 @@ static void fillArcPOLY( GERBER_DRAW_ITEM* aGbrItem,
|
||||
if( start_angle > end_angle )
|
||||
end_angle += 3600;
|
||||
|
||||
int arc_angle = start_angle - end_angle;
|
||||
double arc_angle = start_angle - end_angle;
|
||||
// Approximate arc by 36 segments per 360 degree
|
||||
const int increment_angle = 3600 / 36;
|
||||
int count = std::abs( arc_angle / increment_angle );
|
||||
@ -361,7 +361,7 @@ static void fillArcPOLY( GERBER_DRAW_ITEM* aGbrItem,
|
||||
wxPoint start_arc = start;
|
||||
for( int ii = 0; ii <= count; ii++ )
|
||||
{
|
||||
int rot;
|
||||
double rot;
|
||||
wxPoint end_arc = start;
|
||||
if( aClockwise )
|
||||
rot = ii * increment_angle; // rot is in 0.1 deg
|
||||
|
@ -106,7 +106,7 @@ void TransformRoundedEndsSegmentToPolygon( CPOLYGONS_LIST& aCornerBuffer,
|
||||
* @param aWidth = width (thickness) of the line
|
||||
*/
|
||||
void TransformArcToPolygon( CPOLYGONS_LIST& aCornerBuffer,
|
||||
wxPoint aCentre, wxPoint aStart, int aArcAngle,
|
||||
wxPoint aCentre, wxPoint aStart, double aArcAngle,
|
||||
int aCircleToSegmentsCount, int aWidth );
|
||||
|
||||
/**
|
||||
|
@ -94,7 +94,7 @@ void DrawGraphicText( EDA_DRAW_PANEL * aPanel,
|
||||
const wxPoint &aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString &aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize &aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
@ -118,7 +118,7 @@ void DrawGraphicHaloText( EDA_DRAW_PANEL * aPanel,
|
||||
enum EDA_COLOR_T aColor1,
|
||||
enum EDA_COLOR_T aColor2,
|
||||
const wxString &aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize &aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
|
@ -203,10 +203,10 @@ void GRFilledCircle( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int r, int width
|
||||
void GRFilledCircle( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, EDA_COLOR_T aColor );
|
||||
void GRCircle( EDA_RECT* aClipBox, wxDC* aDC, wxPoint aPos, int aRadius, int aWidth, EDA_COLOR_T aColor );
|
||||
|
||||
void GRArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int StAngle,
|
||||
int EndAngle, int r, EDA_COLOR_T Color );
|
||||
void GRArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int StAngle,
|
||||
int EndAngle, int r, int width, EDA_COLOR_T Color );
|
||||
void GRArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y, double StAngle,
|
||||
double EndAngle, int r, EDA_COLOR_T Color );
|
||||
void GRArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y, double StAngle,
|
||||
double EndAngle, int r, int width, EDA_COLOR_T Color );
|
||||
void GRArc1( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
|
||||
int xc, int yc, EDA_COLOR_T Color );
|
||||
void GRArc1( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
|
||||
@ -214,9 +214,9 @@ 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,
|
||||
wxPoint aCenter, int aWidth, EDA_COLOR_T aColor );
|
||||
void GRFilledArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y,
|
||||
int StAngle, int EndAngle, int r, EDA_COLOR_T Color, EDA_COLOR_T BgColor );
|
||||
void GRFilledArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y, int StAngle,
|
||||
int EndAngle, int r, int width, EDA_COLOR_T Color, EDA_COLOR_T BgColor );
|
||||
double StAngle, double EndAngle, int r, EDA_COLOR_T Color, EDA_COLOR_T BgColor );
|
||||
void GRFilledArc( EDA_RECT* ClipBox, wxDC* DC, int x, int y, double StAngle,
|
||||
double EndAngle, int r, int width, EDA_COLOR_T Color, EDA_COLOR_T BgColor );
|
||||
void GRCSegm( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2, int width, EDA_COLOR_T Color );
|
||||
|
||||
void GRFillCSegm( EDA_RECT* ClipBox, wxDC* DC, int x1, int y1, int x2, int y2,
|
||||
|
@ -153,8 +153,8 @@ public:
|
||||
int width = DEFAULT_LINE_WIDTH ) = 0;
|
||||
virtual void Circle( const wxPoint& pos, int diametre, FILL_T fill,
|
||||
int width = DEFAULT_LINE_WIDTH ) = 0;
|
||||
virtual void Arc( const wxPoint& centre, int StAngle, int EndAngle, int rayon,
|
||||
FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& centre, double StAngle, double EndAngle,
|
||||
int rayon, FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
|
||||
/**
|
||||
* moveto/lineto primitive, moves the 'pen' to the specified direction
|
||||
@ -214,8 +214,8 @@ public:
|
||||
// Higher level primitives -- can be drawn as line, sketch or 'filled'
|
||||
virtual void ThickSegment( const wxPoint& start, const wxPoint& end, int width,
|
||||
EDA_DRAW_MODE_T tracemode );
|
||||
virtual void ThickArc( const wxPoint& centre, int StAngle, int EndAngle, int rayon,
|
||||
int width, EDA_DRAW_MODE_T tracemode );
|
||||
virtual void ThickArc( const wxPoint& centre, double StAngle, double EndAngle,
|
||||
int rayon, int width, EDA_DRAW_MODE_T tracemode );
|
||||
virtual void ThickRect( const wxPoint& p1, const wxPoint& p2, int width,
|
||||
EDA_DRAW_MODE_T tracemode );
|
||||
virtual void ThickCircle( const wxPoint& pos, int diametre, int width,
|
||||
@ -224,10 +224,10 @@ public:
|
||||
// Flash primitives
|
||||
virtual void FlashPadCircle( const wxPoint& pos, int diametre,
|
||||
EDA_DRAW_MODE_T trace_mode ) = 0;
|
||||
virtual void FlashPadOval( const wxPoint& pos, const wxSize& size, int orient,
|
||||
virtual void FlashPadOval( const wxPoint& pos, const wxSize& size, double orient,
|
||||
EDA_DRAW_MODE_T trace_mode ) = 0;
|
||||
virtual void FlashPadRect( const wxPoint& pos, const wxSize& size,
|
||||
int orient, EDA_DRAW_MODE_T trace_mode ) = 0;
|
||||
double orient, EDA_DRAW_MODE_T trace_mode ) = 0;
|
||||
|
||||
/** virtual function FlashPadTrapez
|
||||
* flash a trapezoidal pad
|
||||
@ -238,7 +238,7 @@ public:
|
||||
* @param aTrace_Mode = FILLED or SKETCH
|
||||
*/
|
||||
virtual void FlashPadTrapez( const wxPoint& aPadPos, const wxPoint *aCorners,
|
||||
int aPadOrient, EDA_DRAW_MODE_T aTrace_Mode ) = 0;
|
||||
double aPadOrient, EDA_DRAW_MODE_T aTrace_Mode ) = 0;
|
||||
|
||||
|
||||
/**
|
||||
@ -247,7 +247,7 @@ public:
|
||||
virtual void Text( const wxPoint& aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
@ -297,7 +297,7 @@ protected:
|
||||
// Helper function for sketched filler segment
|
||||
void segmentAsOval( const wxPoint& start, const wxPoint& end, int width,
|
||||
EDA_DRAW_MODE_T tracemode );
|
||||
void sketchOval( const wxPoint& pos, const wxSize& size, int orient,
|
||||
void sketchOval( const wxPoint& pos, const wxSize& size, double orient,
|
||||
int width );
|
||||
|
||||
// Coordinate and scaling conversion functions
|
||||
@ -402,17 +402,17 @@ public:
|
||||
|
||||
virtual void ThickSegment( const wxPoint& start, const wxPoint& end, int width,
|
||||
EDA_DRAW_MODE_T tracemode );
|
||||
virtual void Arc( const wxPoint& centre, int StAngle, int EndAngle, int rayon,
|
||||
FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& centre, double StAngle, double EndAngle,
|
||||
int rayon, FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void PenTo( const wxPoint& pos, char plume );
|
||||
virtual void FlashPadCircle( const wxPoint& pos, int diametre,
|
||||
EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadOval( const wxPoint& pos, const wxSize& size, int orient,
|
||||
virtual void FlashPadOval( const wxPoint& pos, const wxSize& size, double orient,
|
||||
EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadRect( const wxPoint& pos, const wxSize& size,
|
||||
int orient, EDA_DRAW_MODE_T trace_mode );
|
||||
double orient, EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadTrapez( const wxPoint& aPadPos, const wxPoint *aCorners,
|
||||
int aPadOrient, EDA_DRAW_MODE_T aTrace_Mode );
|
||||
double aPadOrient, EDA_DRAW_MODE_T aTrace_Mode );
|
||||
|
||||
protected:
|
||||
void penControl( char plume );
|
||||
@ -459,12 +459,12 @@ public:
|
||||
// Pad routines are handled with lower level primitives
|
||||
virtual void FlashPadCircle( const wxPoint& pos, int diametre,
|
||||
EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadOval( const wxPoint& pos, const wxSize& size, int orient,
|
||||
virtual void FlashPadOval( const wxPoint& pos, const wxSize& size, double orient,
|
||||
EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadRect( const wxPoint& pos, const wxSize& size,
|
||||
int orient, EDA_DRAW_MODE_T trace_mode );
|
||||
double orient, EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadTrapez( const wxPoint& aPadPos, const wxPoint *aCorners,
|
||||
int aPadOrient, EDA_DRAW_MODE_T aTrace_Mode );
|
||||
double aPadOrient, EDA_DRAW_MODE_T aTrace_Mode );
|
||||
|
||||
/** The SetColor implementation is split with the subclasses:
|
||||
* The PSLIKE computes the rgb values, the subclass emits the
|
||||
@ -543,8 +543,8 @@ public:
|
||||
int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Circle( const wxPoint& pos, int diametre, FILL_T fill,
|
||||
int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& centre, int StAngle, int EndAngle,
|
||||
int rayon, FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& centre, double StAngle, double EndAngle,
|
||||
int rayon, FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
|
||||
virtual void PlotPoly( const std::vector< wxPoint >& aCornerList,
|
||||
FILL_T aFill, int aWidth = DEFAULT_LINE_WIDTH );
|
||||
@ -556,7 +556,7 @@ public:
|
||||
virtual void Text( const wxPoint& aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
@ -610,8 +610,8 @@ public:
|
||||
int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Circle( const wxPoint& pos, int diametre, FILL_T fill,
|
||||
int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& centre, int StAngle, int EndAngle,
|
||||
int rayon, FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& centre, double StAngle, double EndAngle,
|
||||
int rayon, FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
|
||||
virtual void PlotPoly( const std::vector< wxPoint >& aCornerList,
|
||||
FILL_T aFill, int aWidth = DEFAULT_LINE_WIDTH);
|
||||
@ -621,7 +621,7 @@ public:
|
||||
virtual void Text( const wxPoint& aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
@ -677,8 +677,8 @@ public:
|
||||
int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Circle( const wxPoint& pos, int diametre, FILL_T fill,
|
||||
int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& centre, int StAngle, int EndAngle,
|
||||
int rayon, FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& centre, double StAngle, double EndAngle,
|
||||
int rayon, FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
|
||||
virtual void PlotPoly( const std::vector< wxPoint >& aCornerList,
|
||||
FILL_T aFill, int aWidth = DEFAULT_LINE_WIDTH );
|
||||
@ -690,7 +690,7 @@ public:
|
||||
virtual void Text( const wxPoint& aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
@ -786,21 +786,21 @@ public:
|
||||
int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Circle( const wxPoint& pos, int diametre, FILL_T fill,
|
||||
int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& aCenter, int aStAngle, int aEndAngle, int aRadius,
|
||||
FILL_T aFill, int aWidth = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& aCenter, double aStAngle, double aEndAngle,
|
||||
int aRadius, FILL_T aFill, int aWidth = DEFAULT_LINE_WIDTH );
|
||||
virtual void PlotPoly( const std::vector< wxPoint >& aCornerList,
|
||||
FILL_T aFill, int aWidth = DEFAULT_LINE_WIDTH );
|
||||
|
||||
virtual void PenTo( const wxPoint& pos, char plume );
|
||||
virtual void FlashPadCircle( const wxPoint& pos, int diametre,
|
||||
EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadOval( const wxPoint& pos, const wxSize& size, int orient,
|
||||
virtual void FlashPadOval( const wxPoint& pos, const wxSize& size, double orient,
|
||||
EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadRect( const wxPoint& pos, const wxSize& size,
|
||||
int orient, EDA_DRAW_MODE_T trace_mode );
|
||||
double orient, EDA_DRAW_MODE_T trace_mode );
|
||||
|
||||
virtual void FlashPadTrapez( const wxPoint& aPadPos, const wxPoint *aCorners,
|
||||
int aPadOrient, EDA_DRAW_MODE_T aTrace_Mode );
|
||||
double aPadOrient, EDA_DRAW_MODE_T aTrace_Mode );
|
||||
|
||||
virtual void SetLayerPolarity( bool aPositive );
|
||||
|
||||
@ -877,22 +877,22 @@ public:
|
||||
FILL_T aFill, int aWidth = DEFAULT_LINE_WIDTH );
|
||||
virtual void ThickSegment( const wxPoint& start, const wxPoint& end, int width,
|
||||
EDA_DRAW_MODE_T tracemode );
|
||||
virtual void Arc( const wxPoint& centre, int StAngle, int EndAngle, int rayon,
|
||||
FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void Arc( const wxPoint& centre, double StAngle, double EndAngle,
|
||||
int rayon, FILL_T fill, int width = DEFAULT_LINE_WIDTH );
|
||||
virtual void PenTo( const wxPoint& pos, char plume );
|
||||
virtual void FlashPadCircle( const wxPoint& pos, int diametre,
|
||||
EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadOval( const wxPoint& pos, const wxSize& size, int orient,
|
||||
virtual void FlashPadOval( const wxPoint& pos, const wxSize& size, double orient,
|
||||
EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadRect( const wxPoint& pos, const wxSize& size,
|
||||
int orient, EDA_DRAW_MODE_T trace_mode );
|
||||
double orient, EDA_DRAW_MODE_T trace_mode );
|
||||
virtual void FlashPadTrapez( const wxPoint& aPadPos, const wxPoint *aCorners,
|
||||
int aPadOrient, EDA_DRAW_MODE_T aTrace_Mode );
|
||||
double aPadOrient, EDA_DRAW_MODE_T aTrace_Mode );
|
||||
|
||||
virtual void Text( const wxPoint& aPos,
|
||||
enum EDA_COLOR_T aColor,
|
||||
const wxString& aText,
|
||||
int aOrient,
|
||||
double aOrient,
|
||||
const wxSize& aSize,
|
||||
enum EDA_TEXT_HJUSTIFY_T aH_justify,
|
||||
enum EDA_TEXT_VJUSTIFY_T aV_justify,
|
||||
|
@ -291,7 +291,7 @@ public:
|
||||
MODULE* Create_1_Module( const wxString& aModuleName );
|
||||
|
||||
void Edit_Module( MODULE* module, wxDC* DC );
|
||||
void Rotate_Module( wxDC* DC, MODULE* module, int angle, bool incremental );
|
||||
void Rotate_Module( wxDC* DC, MODULE* module, double angle, bool incremental );
|
||||
|
||||
/**
|
||||
* Function PlaceModule
|
||||
|
@ -1482,7 +1482,7 @@ public:
|
||||
* @param include_fixe = true to orient locked footprints
|
||||
* @return true if some footprints modified, false if no change
|
||||
*/
|
||||
bool ReOrientModules( const wxString& ModuleMask, int Orient, bool include_fixe );
|
||||
bool ReOrientModules( const wxString& ModuleMask, double Orient, bool include_fixe );
|
||||
void LockModule( MODULE* aModule, bool aLocked );
|
||||
void AutoMoveModulesOnPcb( bool PlaceModulesHorsPcb );
|
||||
|
||||
|
@ -209,7 +209,7 @@ void TraceFilledRectangle( int ux0, int uy0, int ux1, int uy1,
|
||||
|
||||
/* Same as above, but the rectangle is inclined angle angle. */
|
||||
void TraceFilledRectangle( int ux0, int uy0, int ux1, int uy1,
|
||||
int angle, LAYER_MSK masque_layer,
|
||||
double angle, LAYER_MSK masque_layer,
|
||||
int color, int op_logic );
|
||||
|
||||
/* QUEUE.CPP */
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user