Symbol editor: fix pin increment setting for 100nm units.
This commit is contained in:
parent
aeb3281e27
commit
8bf9a4c811
|
@ -2,7 +2,7 @@
|
|||
* This program source code file is part of KiCad, a free EDA CAD application.
|
||||
*
|
||||
* Copyright (C) 2009 Wayne Stambaugh <stambaughw@verizon.net>
|
||||
* Copyright (C) 1992-2018 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
* Copyright (C) 1992-2019 KiCad Developers, see AUTHORS.txt for contributors.
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or
|
||||
* modify it under the terms of the GNU General Public License
|
||||
|
@ -51,7 +51,7 @@ bool PANEL_LIBEDIT_SETTINGS::TransferDataToWindow()
|
|||
StringFromValue( EDA_UNITS::INCHES, m_frame->GetRepeatStep().x, false, true ) );
|
||||
m_vPitchCtrl->SetValue(
|
||||
StringFromValue( EDA_UNITS::INCHES, m_frame->GetRepeatStep().y, false, true ) );
|
||||
m_choicePinDisplacement->SetSelection( m_frame->GetRepeatPinStep() == 50 ? 1 : 0 );
|
||||
m_choicePinDisplacement->SetSelection( m_frame->GetRepeatPinStep() == Iu2Mils( 50 ) ? 1 : 0 );
|
||||
m_spinRepeatLabel->SetValue( m_frame->GetRepeatDeltaLabel() );
|
||||
|
||||
m_checkShowPinElectricalType->SetValue( m_frame->GetShowElectricalType() );
|
||||
|
@ -73,7 +73,8 @@ bool PANEL_LIBEDIT_SETTINGS::TransferDataFromWindow()
|
|||
m_frame->SetRepeatStep(
|
||||
wxPoint( ValueFromString( EDA_UNITS::INCHES, m_hPitchCtrl->GetValue(), true ),
|
||||
ValueFromString( EDA_UNITS::INCHES, m_vPitchCtrl->GetValue(), true ) ) );
|
||||
m_frame->SetRepeatPinStep( m_choicePinDisplacement->GetSelection() == 1 ? 50 : 100 );
|
||||
m_frame->SetRepeatPinStep( m_choicePinDisplacement->GetSelection() == 1 ?
|
||||
Mils2iu( 50 ) : Mils2iu( 100 ) );
|
||||
m_frame->SetRepeatDeltaLabel( m_spinRepeatLabel->GetValue() );
|
||||
|
||||
m_frame->SetShowElectricalType( m_checkShowPinElectricalType->GetValue() );
|
||||
|
|
|
@ -66,9 +66,9 @@ double LIB_EDIT_FRAME:: g_LastTextAngle = TEXT_ANGLE_HORIZ;
|
|||
int LIB_EDIT_FRAME:: g_LastLineWidth = 0;
|
||||
|
||||
// these values are overridden when reading the config
|
||||
int LIB_EDIT_FRAME:: m_textPinNumDefaultSize = DEFAULTPINNUMSIZE;
|
||||
int LIB_EDIT_FRAME:: m_textPinNameDefaultSize = DEFAULTPINNAMESIZE;
|
||||
int LIB_EDIT_FRAME:: m_defaultPinLength = DEFAULTPINLENGTH;
|
||||
int LIB_EDIT_FRAME:: m_textPinNumDefaultSize = Mils2iu( DEFAULTPINNUMSIZE );
|
||||
int LIB_EDIT_FRAME:: m_textPinNameDefaultSize = Mils2iu( DEFAULTPINNAMESIZE );
|
||||
int LIB_EDIT_FRAME:: m_defaultPinLength = Mils2iu( DEFAULTPINLENGTH );
|
||||
|
||||
FILL_T LIB_EDIT_FRAME:: g_LastFillStyle = NO_FILL;
|
||||
|
||||
|
@ -101,7 +101,7 @@ LIB_EDIT_FRAME::LIB_EDIT_FRAME( KIWAY* aKiway, wxWindow* aParent ) :
|
|||
m_DrawSpecificConvert = true;
|
||||
m_DrawSpecificUnit = false;
|
||||
m_SyncPinEdit = false;
|
||||
m_repeatPinStep = DEFAULT_REPEAT_OFFSET_PIN;
|
||||
m_repeatPinStep = Mils2iu( DEFAULT_REPEAT_OFFSET_PIN );
|
||||
SetShowElectricalType( true );
|
||||
m_FrameSize = ConvertDialogToPixels( wxSize( 500, 350 ) ); // default in case of no prefs
|
||||
|
||||
|
@ -735,7 +735,8 @@ const BOX2I LIB_EDIT_FRAME::GetDocumentExtents() const
|
|||
{
|
||||
if( !m_my_part )
|
||||
{
|
||||
return BOX2I( VECTOR2I(-100, -100), VECTOR2I( 200, 200 ) );
|
||||
return BOX2I( VECTOR2I( Mils2iu( -100 ), Mils2iu( -100 ) ),
|
||||
VECTOR2I( Mils2iu( 200 ), Mils2iu( 200 ) ) );
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue