[Libreoffice-commits] core.git: vcl/source
Chris Sherlock
chris.sherlock79 at gmail.com
Sat Jan 9 18:33:16 PST 2016
vcl/source/gdi/pdfwriter_impl.cxx | 8 ++++----
vcl/source/gdi/pdfwriter_impl.hxx | 10 +++++-----
2 files changed, 9 insertions(+), 9 deletions(-)
New commits:
commit 251fb51430da29337eb3e74591c8c522e15fc955
Author: Chris Sherlock <chris.sherlock79 at gmail.com>
Date: Sun Jan 10 10:29:10 2016 +1100
vcl: Renamed ImplPdfBuiltinFontData to PdfBuiltinFontFace
Base class's name is PhysicalFontFace, which is used to create a
logical font instance. Each platform (including the PDF writer it
appears!) implements it's own factory function - so it's more than
just a "data" class.
I am also aiming to keep naming in the class heirachy consistent,
thus the reason for the name change.
Change-Id: Idb8c5b6a3b23a39ca727d355dcf421307cacbb2f
Reviewed-on: https://gerrit.libreoffice.org/21302
Tested-by: Jenkins <ci at libreoffice.org>
Reviewed-by: Chris Sherlock <chris.sherlock79 at gmail.com>
diff --git a/vcl/source/gdi/pdfwriter_impl.cxx b/vcl/source/gdi/pdfwriter_impl.cxx
index 2159bc6..9930d977 100644
--- a/vcl/source/gdi/pdfwriter_impl.cxx
+++ b/vcl/source/gdi/pdfwriter_impl.cxx
@@ -2260,12 +2260,12 @@ static ImplFontAttributes GetDevFontAttributes( const PDFWriterImpl::BuiltinFont
return aDFA;
}
-ImplPdfBuiltinFontData::ImplPdfBuiltinFontData( const PDFWriterImpl::BuiltinFont& rBuiltin )
+PdfBuiltinFontFace::PdfBuiltinFontFace( const PDFWriterImpl::BuiltinFont& rBuiltin )
: PhysicalFontFace( GetDevFontAttributes(rBuiltin) ),
mrBuiltin( rBuiltin )
{}
-LogicalFontInstance* ImplPdfBuiltinFontData::CreateFontInstance( FontSelectPattern& rFSD ) const
+LogicalFontInstance* PdfBuiltinFontFace::CreateFontInstance( FontSelectPattern& rFSD ) const
{
LogicalFontInstance* pEntry = new LogicalFontInstance( rFSD );
return pEntry;
@@ -2916,7 +2916,7 @@ bool PDFWriterImpl::emitTilings()
return true;
}
-sal_Int32 PDFWriterImpl::emitBuiltinFont( const ImplPdfBuiltinFontData* pFD, sal_Int32 nFontObject )
+sal_Int32 PDFWriterImpl::emitBuiltinFont( const PdfBuiltinFontFace* pFD, sal_Int32 nFontObject )
{
if( !pFD )
return 0;
@@ -4175,7 +4175,7 @@ bool PDFWriterImpl::emitFonts()
for( std::map< sal_Int32, sal_Int32 >::iterator it = m_aBuiltinFontToObjectMap.begin();
it != m_aBuiltinFontToObjectMap.end(); ++it )
{
- ImplPdfBuiltinFontData aData(m_aBuiltinFonts[it->first]);
+ PdfBuiltinFontFace aData(m_aBuiltinFonts[it->first]);
it->second = emitBuiltinFont( &aData, it->second );
}
appendBuiltinFontsToDict( aFontDict );
diff --git a/vcl/source/gdi/pdfwriter_impl.hxx b/vcl/source/gdi/pdfwriter_impl.hxx
index 4e4ff47..1210759 100644
--- a/vcl/source/gdi/pdfwriter_impl.hxx
+++ b/vcl/source/gdi/pdfwriter_impl.hxx
@@ -71,7 +71,7 @@ namespace vcl
class PDFStreamIf;
class Matrix3;
-class ImplPdfBuiltinFontData;
+class PdfBuiltinFontFace;
class PDFWriterImpl
{
@@ -835,7 +835,7 @@ i12626
/* writes all gradient patterns */
bool emitGradients();
/* writes a builtin font object and returns its objectid (or 0 in case of failure ) */
- sal_Int32 emitBuiltinFont( const ImplPdfBuiltinFontData*, sal_Int32 nObject = -1 );
+ sal_Int32 emitBuiltinFont( const PdfBuiltinFontFace*, sal_Int32 nObject = -1 );
/* writes a type1 embedded font object and returns its mapping from font ids to object ids (or 0 in case of failure ) */
std::map< sal_Int32, sal_Int32 > emitEmbeddedFont( const PhysicalFontFace*, EmbedFont& );
/* writes a type1 system font object and returns its mapping from font ids to object ids (or 0 in case of failure ) */
@@ -1256,16 +1256,16 @@ public:
}
};
-class ImplPdfBuiltinFontData : public PhysicalFontFace
+class PdfBuiltinFontFace : public PhysicalFontFace
{
private:
const PDFWriterImpl::BuiltinFont& mrBuiltin;
public:
- explicit ImplPdfBuiltinFontData( const PDFWriterImpl::BuiltinFont& );
+ explicit PdfBuiltinFontFace( const PDFWriterImpl::BuiltinFont& );
const PDFWriterImpl::BuiltinFont& GetBuiltinFont() const { return mrBuiltin; }
- virtual PhysicalFontFace* Clone() const override { return new ImplPdfBuiltinFontData(*this); }
+ virtual PhysicalFontFace* Clone() const override { return new PdfBuiltinFontFace(*this); }
virtual LogicalFontInstance* CreateFontInstance( FontSelectPattern& ) const override;
virtual sal_IntPtr GetFontId() const override { return reinterpret_cast<sal_IntPtr>(&mrBuiltin); }
};
More information about the Libreoffice-commits
mailing list