diff options
Diffstat (limited to 'svx/source/unodraw/unoshape.cxx')
-rw-r--r-- | svx/source/unodraw/unoshape.cxx | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/svx/source/unodraw/unoshape.cxx b/svx/source/unodraw/unoshape.cxx index 4ee178c5e58a..85cd6045a234 100644 --- a/svx/source/unodraw/unoshape.cxx +++ b/svx/source/unodraw/unoshape.cxx @@ -173,7 +173,7 @@ protected: }; /// Calculates what scaling factor will be used for autofit text scaling of this shape. -sal_Int16 GetTextFitToSizeScale(SdrObject* pObject) +double GetTextFitToSizeScale(SdrObject* pObject) { SdrTextObj* pTextObj = DynCastSdrTextObj(pObject); if (!pTextObj) @@ -188,7 +188,7 @@ sal_Int16 GetTextFitToSizeScale(SdrObject* pObject) return 0; } - return pTextObj->GetFontScaleY(); + return pTextObj->GetFontScale(); } } @@ -2361,7 +2361,7 @@ bool SvxShape::setPropertyValueImpl( const OUString&, const SfxItemPropertyMapEn case OWN_ATTR_TEXTFITTOSIZESCALE: { - sal_Int16 nMaxScale = 0; + double nMaxScale = 0.0; if (rValue >>= nMaxScale) { SdrTextFitToSizeTypeItem aItem(pSdrObject->GetMergedItem(SDRATTR_TEXT_FITTOSIZE)); @@ -2871,7 +2871,8 @@ bool SvxShape::getPropertyValueImpl( const OUString&, const SfxItemPropertyMapEn case OWN_ATTR_TEXTFITTOSIZESCALE: { - rValue <<= GetTextFitToSizeScale(GetSdrObject()); + double nScale = GetTextFitToSizeScale(GetSdrObject()); + rValue <<= nScale; break; } |