Implementation of font drawing - first part

This commit is contained in:
Jakub Melka
2019-03-30 18:45:30 +01:00
parent 21e125bd40
commit 81be3cbd21
8 changed files with 725 additions and 33 deletions

View File

@@ -87,6 +87,11 @@ public:
inline explicit PDFDocumentDataLoaderDecorator(const PDFDocument* document) : m_document(document) { }
inline ~PDFDocumentDataLoaderDecorator() = default;
/// Reads a name from the object, if it is possible. If object is not a name,
/// then empty byte array is returned.
/// \param object Object, can be an indirect reference to object (it is dereferenced)
QByteArray readName(const PDFObject& object);
/// Reads an integer from the object, if it is possible.
/// \param object Object, can be an indirect reference to object (it is dereferenced)
/// \param defaultValue Default value
@@ -217,6 +222,11 @@ public:
/// \param defaultValue Default value
bool readBooleanFromDictionary(const PDFDictionary* dictionary, const char* key, bool defaultValue) const;
/// Reads a name from dictionary. If dictionary entry doesn't exist, or error occurs, empty byte array is returned.
/// \param dictionary Dictionary containing desired data
/// \param key Entry key
QByteArray readNameFromDictionary(const PDFDictionary* dictionary, const char* key);
private:
const PDFDocument* m_document;
};