diff --git a/eeschema/lib_field.cpp b/eeschema/lib_field.cpp index 4452d804ff..14095030ff 100644 --- a/eeschema/lib_field.cpp +++ b/eeschema/lib_field.cpp @@ -664,6 +664,11 @@ static struct LIB_FIELD_DESC propMgr.Mask( TYPE_HASH( LIB_FIELD ), TYPE_HASH( EDA_TEXT ), _HKI( "Width" ) ); propMgr.Mask( TYPE_HASH( LIB_FIELD ), TYPE_HASH( EDA_TEXT ), _HKI( "Height" ) ); + propMgr.AddProperty( new PROPERTY( + _HKI( "Text Size" ), &LIB_FIELD::SetLibTextSize, + &LIB_FIELD::GetLibTextSize, PROPERTY_DISPLAY::PT_SIZE ), + _HKI( "Text Properties" ) ); + propMgr.Mask( TYPE_HASH( LIB_FIELD ), TYPE_HASH( EDA_TEXT ), _HKI( "Orientation" ) ); } } _LIB_FIELD_DESC; diff --git a/eeschema/lib_field.h b/eeschema/lib_field.h index d07343af2d..01beb5d1aa 100644 --- a/eeschema/lib_field.h +++ b/eeschema/lib_field.h @@ -161,6 +161,9 @@ public: wxString GetShownText( bool aAllowExtraText, int aDepth = 0 ) const override; + int GetLibTextSize() const { return GetTextWidth(); } + void SetLibTextSize( int aSize ) { SetTextSize( VECTOR2I( aSize, aSize ) ); } + SCH_LAYER_ID GetDefaultLayer() const; void BeginEdit( const VECTOR2I& aStartPoint ) override;