diff options
author | Tamás Zolnai <tamas.zolnai@collabora.com> | 2019-01-23 18:33:57 +0100 |
---|---|---|
committer | Tamás Zolnai <tamas.zolnai@collabora.com> | 2019-01-23 21:10:47 +0100 |
commit | 9223799e73177706bf3e2d3370b412b3d1fa531a (patch) | |
tree | 82a58eb50be953a21e32d9608e897685429c4bd9 /cui | |
parent | 1dcdb9b538b3afb3e439d780baa15e5eba4af31f (diff) |
Bullets: Use relative size when it's supported
In Writer it might cause a problem to use relative
size with text based numberings.
Change-Id: Id19b5e45f0f932d1b69028f343daad7dec34ae23
Reviewed-on: https://gerrit.libreoffice.org/66811
Tested-by: Jenkins
Reviewed-by: Tamás Zolnai <tamas.zolnai@collabora.com>
Diffstat (limited to 'cui')
-rw-r--r-- | cui/source/tabpages/numpages.cxx | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/cui/source/tabpages/numpages.cxx b/cui/source/tabpages/numpages.cxx index 5db0609b5b81..16b1186583a1 100644 --- a/cui/source/tabpages/numpages.cxx +++ b/cui/source/tabpages/numpages.cxx @@ -2438,10 +2438,13 @@ void SvxNumberingPreview::Paint(vcl::RenderContext& rRenderContext, const ::tool { vcl::Font aFont(aStdFont); Size aTmpSize(aStdFont.GetFontSize()); - aTmpSize.setWidth( aTmpSize.Width() * ( rFmt.GetBulletRelSize()) ); - aTmpSize.setWidth( aTmpSize.Width() / 100 ) ; - aTmpSize.setHeight( aTmpSize.Height() * ( rFmt.GetBulletRelSize()) ); - aTmpSize.setHeight( aTmpSize.Height() / 100 ) ; + if(pActNum->IsFeatureSupported(SvxNumRuleFlags::BULLET_REL_SIZE)) + { + aTmpSize.setWidth( aTmpSize.Width() * ( rFmt.GetBulletRelSize()) ); + aTmpSize.setWidth( aTmpSize.Width() / 100 ) ; + aTmpSize.setHeight( aTmpSize.Height() * ( rFmt.GetBulletRelSize()) ); + aTmpSize.setHeight( aTmpSize.Height() / 100 ) ; + } if(!aTmpSize.Height()) aTmpSize.setHeight( 1 ); aFont.SetFontSize(aTmpSize); |