PoDoFo  1.0.0-dev
PdfEncodingFactory.h
1 
7 #ifndef PDF_ENCODING_FACTORY_H
8 #define PDF_ENCODING_FACTORY_H
9 
10 #include "PdfEncoding.h"
11 
12 namespace PoDoFo {
13 
14 class PdfFontMetrics;
15 
19 class PODOFO_API PdfEncodingFactory final
20 {
21 public:
30  static PdfEncoding CreateEncoding(
31  const PdfObject& fontObj, const PdfFontMetrics& metrics);
32 
33 public:
41  static PdfEncoding CreateWinAnsiEncoding();
42 
48  static PdfEncoding CreateMacRomanEncoding();
49 
55  static PdfEncoding CreateMacExpertEncoding();
56 
57 private:
58  static PdfEncodingMapConstPtr createEncodingMap(const PdfObject& obj,
59  const PdfFontMetrics& metrics);
60 
61 private:
62  PdfEncodingFactory() = delete;
63 };
64 
65 }
66 
67 #endif // PDF_ENCODING_FACTORY_H
This factory creates a PdfEncoding from an existing object in the PDF.
Definition: PdfEncodingFactory.h:20
A PdfEncoding is in PdfFont to transform a text string into a representation so that it can be displa...
Definition: PdfEncoding.h:55
This abstract class provides access to font metrics information.
Definition: PdfFontMetrics.h:33
This class represents a PDF indirect Object in memory.
Definition: PdfObject.h:35
SPDX-FileCopyrightText: (C) 2022 Francesco Pretto ceztko@gmail.com SPDX-License-Identifier: LGPL-2....
Definition: basetypes.h:16
std::shared_ptr< const PdfEncodingMap > PdfEncodingMapConstPtr
Convenience typedef for a const /Encoding map entry shared ptr.
Definition: PdfEncodingMap.h:343