svx/source/fmcomp/fmgridif.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
New commits: commit d8e2ad45000a08c5e5b6e028c2c8fcc69c06fd74 Author: Noel <noelgran...@gmail.com> AuthorDate: Tue Oct 20 09:51:53 2020 +0200 Commit: Noel Grandin <noel.gran...@collabora.co.uk> CommitDate: Tue Oct 20 12:13:31 2020 +0200 fix orientation in vcl::Font<->awt::FontDescriptor conversion one is in degrees, the other deci-degrees Change-Id: I85270c15f483e959819fcb54d37435388975f766 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/104552 Tested-by: Jenkins Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk> diff --git a/svx/source/fmcomp/fmgridif.cxx b/svx/source/fmcomp/fmgridif.cxx index 6ffeabaa08d5..a944d591d8c9 100644 --- a/svx/source/fmcomp/fmgridif.cxx +++ b/svx/source/fmcomp/fmgridif.cxx @@ -97,7 +97,7 @@ static css::awt::FontDescriptor ImplCreateFontDescriptor( const vcl::Font& rFont aFD.Slant = vcl::unohelper::ConvertFontSlant( rFont.GetItalic() ); aFD.Underline = static_cast<sal_Int16>(rFont.GetUnderline()); aFD.Strikeout = static_cast<sal_Int16>(rFont.GetStrikeout()); - aFD.Orientation = rFont.GetOrientation(); + aFD.Orientation = rFont.GetOrientation() / 10.0; aFD.Kerning = rFont.IsKerning(); aFD.WordLineMode = rFont.IsWordLineMode(); aFD.Type = 0; // ??? => only to metric... @@ -119,7 +119,7 @@ static vcl::Font ImplCreateFont( const css::awt::FontDescriptor& rDescr ) aFont.SetItalic( static_cast<FontItalic>(rDescr.Slant) ); aFont.SetUnderline( static_cast<::FontLineStyle>(rDescr.Underline) ); aFont.SetStrikeout( static_cast<::FontStrikeout>(rDescr.Strikeout) ); - aFont.SetOrientation( static_cast<sal_Int16>(rDescr.Orientation) ); + aFont.SetOrientation( static_cast<sal_Int16>(rDescr.Orientation * 10) ); aFont.SetKerning( static_cast<FontKerning>(rDescr.Kerning) ); aFont.SetWordLineMode( rDescr.WordLineMode ); return aFont; _______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits