[Libreoffice-commits] core.git: Branch 'feature/cib_contract57c' - vcl/source
Thorsten Behrens (via logerrit)
logerrit at kemper.freedesktop.org
Mon Jul 1 01:00:34 UTC 2019
vcl/source/gdi/pdfwriter_impl.cxx | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
New commits:
commit 562275d798ea31303efa3844c4c611a248c5de92
Author: Thorsten Behrens <Thorsten.Behrens at CIB.de>
AuthorDate: Mon Jul 1 02:50:13 2019 +0200
Commit: Thorsten Behrens <Thorsten.Behrens at CIB.de>
CommitDate: Mon Jul 1 02:59:05 2019 +0200
Fixup checkbox font export
Conflicts:
vcl/source/gdi/pdfwriter_impl.cxx
Change-Id: Ia451e99003f533dec72cf3309fd843ba0f3f1ed7
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx
index fc734dc27d11..a14f64d54ed5 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -4391,7 +4391,7 @@ void PDFWriterImpl::createDefaultCheckBoxAppearance( PDFWidget& rBox, const PDFW
// reasons require even the standard PS fonts to be embedded!
getReferenceDevice()->Push();
getReferenceDevice()->SetFont(
- Font( OUString( "OpenSymbol" ), Size( 0, 500 ) ) );
+ Font( OUString( "OpenSymbol" ), aFont.GetFontSize() ) );
getReferenceDevice()->ImplNewFont();
FontCharMapRef pMap;
getReferenceDevice()->GetFontCharMap(pMap);
@@ -4401,7 +4401,7 @@ void PDFWriterImpl::createDefaultCheckBoxAppearance( PDFWidget& rBox, const PDFW
// make sure OpenSymbol is embedded, and includes our checkmark
const sal_Unicode cMark=0x2713;
- const GlyphItem aItem(pMap->GetGlyphIndex(cMark), 0, 0,
+ const GlyphItem aItem(0, 0, pMap->GetGlyphIndex(cMark),
Point(), 0, 0, 0);
const std::vector<sal_Ucs> aCodeUnits={ cMark };
sal_uInt8 nMappedGlyph;
@@ -4425,10 +4425,10 @@ void PDFWriterImpl::createDefaultCheckBoxAppearance( PDFWidget& rBox, const PDFW
rBox.m_aRect = aCheckRect;
// create appearance streams
- sal_Int32 nCharXOffset = 1000;
+ sal_Int32 nCharXOffset = 1000 - 787; // metrics from OpenSymbol
nCharXOffset *= aCheckRect.GetHeight();
nCharXOffset /= 2000;
- sal_Int32 nCharYOffset = 1000-(820-143); // metrics from Zapf
+ sal_Int32 nCharYOffset = 1000 - (820-143); // metrics from Zapf
nCharYOffset *= aCheckRect.GetHeight();
nCharYOffset /= 2000;
More information about the Libreoffice-commits
mailing list