qt5/src/poppler-fontinfo.cc |    5 +++++
 qt5/src/poppler-private.h   |    2 ++
 qt5/src/poppler-qt5.h       |    6 ++++++
 3 files changed, 13 insertions(+)

New commits:
commit 623983346bb2075d572aa2d8c1757bff5b807126
Author: Jan Grulich <[email protected]>
Date:   Wed Aug 7 07:46:29 2019 +0200

    Add subsitute-font information to Qt bindings

diff --git a/qt5/src/poppler-fontinfo.cc b/qt5/src/poppler-fontinfo.cc
index b563461e..609a83f2 100644
--- a/qt5/src/poppler-fontinfo.cc
+++ b/qt5/src/poppler-fontinfo.cc
@@ -52,6 +52,11 @@ QString FontInfo::name() const
        return m_data->fontName;
 }
 
+QString FontInfo::substituteName() const
+{
+       return m_data->fontSubstituteName;
+}
+
 QString FontInfo::file() const
 {
        return m_data->fontFile;
diff --git a/qt5/src/poppler-private.h b/qt5/src/poppler-private.h
index 80f6581e..93195550 100644
--- a/qt5/src/poppler-private.h
+++ b/qt5/src/poppler-private.h
@@ -175,6 +175,7 @@ namespace Poppler {
                {
                        if (fi->getName()) fontName = fi->getName()->c_str();
                        if (fi->getFile()) fontFile = fi->getFile()->c_str();
+                       if (fi->getSubstituteName()) fontSubstituteName = 
fi->getSubstituteName()->c_str();
                        isEmbedded = fi->getEmbedded();
                        isSubset = fi->getSubset();
                        type = (Poppler::FontInfo::Type)fi->getType();
@@ -185,6 +186,7 @@ namespace Poppler {
                FontInfoData& operator=(const FontInfoData &) = default;
 
                QString fontName;
+               QString fontSubstituteName;
                QString fontFile;
                bool isEmbedded : 1;
                bool isSubset : 1;
diff --git a/qt5/src/poppler-qt5.h b/qt5/src/poppler-qt5.h
index ebbc456a..6102aa20 100644
--- a/qt5/src/poppler-qt5.h
+++ b/qt5/src/poppler-qt5.h
@@ -210,6 +210,12 @@ namespace Poppler {
        QString name() const;
 
        /**
+          The name of the substitute font. Can be a null QString if the font 
has no substitute font
+          @since 0.80
+       */
+       QString substituteName() const;
+
+       /**
           The path of the font file used to represent this font on this system,
           or a null string is the font is embedded
        */
_______________________________________________
poppler mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/poppler

Reply via email to