Commit fd521f37 authored by charras's avatar charras
Browse files

More work about Netclasses in Design Rules dialog

parent 44e588dc
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -109,7 +109,7 @@ double PLOTTER::user_to_device_size( double size )
void PLOTTER::center_square( const wxPoint& position, int diametre, FILL_T fill )
/************************************************************************************/
{
    int rayon     = diametre / 2.8284;
    int rayon     = wxRound( diametre / 2.8284 );
    int coord[10] =
    {
        position.x + rayon, position.y + rayon,
+1 −1
Original line number Diff line number Diff line
@@ -280,7 +280,7 @@ void GERBER_PLOTTER::circle( wxPoint aCentre, int aDiameter, FILL_T fill, int aW
    double    radius = aDiameter / 2;
    const int delta  = 3600 / 32; /* increment (in 0.1 degrees) to draw circles */

    start.x = aCentre.x + radius;
    start.x = aCentre.x + wxRound( radius );
    start.y = aCentre.y;
    set_current_line_width( aWidth );
    move_to( start );
+6 −6
Original line number Diff line number Diff line
@@ -251,7 +251,7 @@ void HPGL_PLOTTER::flash_pad_oval( wxPoint pos, wxSize size, int orient,
    rayon   = size.x / 2;
    if( trace_mode == FILLED )
    {
        flash_pad_rect( pos, wxSize( size.x, deltaxy+pen_diameter ),
        flash_pad_rect( pos, wxSize( size.x, deltaxy + wxRound( pen_diameter ) ),
                                 orient, trace_mode );
        cx = 0; cy = deltaxy / 2;
        RotatePoint( &cx, &cy, orient );
@@ -262,7 +262,7 @@ void HPGL_PLOTTER::flash_pad_oval( wxPoint pos, wxSize size, int orient,
    }
    else    /* Trace en mode SKETCH */
    {
	sketch_oval(pos, size, orient, pen_diameter);
	sketch_oval(pos, size, orient, wxRound( pen_diameter) );
    }
}

@@ -277,11 +277,11 @@ void HPGL_PLOTTER::flash_pad_circle(wxPoint pos, int diametre,

    user_to_device_coordinates( pos );

    delta = pen_diameter - pen_overlap;
    delta = wxRound( pen_diameter - pen_overlap ) ;
    rayon = diametre / 2;
    if( trace_mode != FILAIRE )
    {
        rayon = (diametre - pen_diameter ) / 2;
        rayon = (diametre - wxRound( pen_diameter) ) / 2;
    }

    if( rayon < 0 )
@@ -437,7 +437,7 @@ void HPGL_PLOTTER::flash_pad_trapez( wxPoint pos, wxSize size, wxSize delta,
    wxPoint coord[4];       /* coord reelles des sommets du trapeze a tracer */
    int     moveX, moveY; /* variation de position plume selon axe X et Y , lors
			   *  du remplissage du trapeze */
    moveX = moveY = pen_diameter;
    moveX = moveY = wxRound( pen_diameter );

    size.x  /= 2;  size.y /= 2;
    delta.x /= 2; delta.y /= 2;
@@ -471,7 +471,7 @@ void HPGL_PLOTTER::flash_pad_trapez( wxPoint pos, wxSize size, wxSize delta,
    {
	int     jj;
	/* Fill the shape */
	moveX = moveY = pen_diameter - pen_overlap;
	moveX = moveY = wxRound( pen_diameter - pen_overlap );
	/* calcul de jj = hauteur du remplissage */
	if( delta.y ) /* Trapeze horizontal */
	{
+1 −1
Original line number Diff line number Diff line
@@ -168,7 +168,7 @@ void PS_PLOTTER::arc( wxPoint centre, int StAngle, int EndAngle, int rayon,

    // Calcul des coord du point de depart :
    user_to_device_coordinates( centre );
    rayon = user_to_device_size(rayon);
    rayon = wxRound( user_to_device_size(rayon) );
    if( plot_orient_options == PLOT_MIROIR )
        fprintf( output_file, "%d %d %d %g %g arc%d\n", centre.x, centre.y,
            rayon, (double) -EndAngle / 10, (double) -StAngle / 10,
+3 −2
Original line number Diff line number Diff line
@@ -399,14 +399,15 @@ LIB_DRAW_ITEM* LIB_COMPONENT::GetNextDrawItem( LIB_DRAW_ITEM* item,
    return NULL;
}


/*************************************************************************/
void LIB_COMPONENT::GetPins( LIB_PIN_LIST& pins, int unit, int convert )
/*************************************************************************/
{
    /* Notes:
     * when unit == 0: no unit filtering
     * when convert == 0: no convert (shape selection) filtering
     * when .m_Unit == 0, the body item is common to units
     * when .m_Convert == 0, the body item is common to shape
     * when .m_Convert == 0, the body item is common to shapes
     */
    BOOST_FOREACH( LIB_DRAW_ITEM& item, m_Drawings )
    {
Loading