diff options
author | Jay Berkenbilt <ejb@ql.org> | 2019-08-21 19:05:06 +0200 |
---|---|---|
committer | Jay Berkenbilt <ejb@ql.org> | 2019-08-22 23:55:16 +0200 |
commit | 4b674b42e4c1b9b470dd4ca8b84ac4db1d430055 (patch) | |
tree | ead9bbce0f9acd2851b7ab14ae03d7ca7b4a6faa /include | |
parent | 225cd9dac27d685833156dfc249838cda11cd2ef (diff) | |
download | qpdf-4b674b42e4c1b9b470dd4ca8b84ac4db1d430055.tar.zst |
Mention name tokens in TokenFilter comments
Diffstat (limited to 'include')
-rw-r--r-- | include/qpdf/QPDFObjectHandle.hh | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/include/qpdf/QPDFObjectHandle.hh b/include/qpdf/QPDFObjectHandle.hh index 1b0d481b..0569ec5d 100644 --- a/include/qpdf/QPDFObjectHandle.hh +++ b/include/qpdf/QPDFObjectHandle.hh @@ -98,7 +98,13 @@ class QPDFObjectHandle // for being written to output, or calling writeToken with a // string token will also work. The correct way to construct a // string token that would write the literal value (str) is - // QPDFTokenizer::Token(QPDFTokenizer::tt_string, "str"). + // QPDFTokenizer::Token(QPDFTokenizer::tt_string, "str"). A + // similar situation exists with tt_name. token.getValue() returns + // a normalized name with # codes resolved into characters, and + // may not be suitable for writing. You can pass it to + // QPDF_Name::normalizeName first, or you can use writeToken with + // a name token. The correct way to create a name token is + // QPDFTokenizer::Token(QPDFTokenizer::tt_name, "/Name"). class QPDF_DLL_CLASS TokenFilter { public: |