Mojca Miklavec wrote:
Mojca Miklavec wrote:
VnPenguin wrote:
Mojca Miklavec wrote:
How can I add Author/Title/Creator/Keywords/... to PDF documents, possibly with non-ascii characters?
Try: \setupinteraction [state=start, title={...}, author={...}, keyword={...}]
Adobe seems to have some strange way of encoding those strings: I can use scaron in those fields (if I write something manually in Acrobat), but then the whole string becomes two-byte with some prefix and resembles unicode encoding.
For example, to get the Hàn Thế Thành's name in the Author's field of the PDF manual properly, one should probably write something like /Author(feff 0048 00e0 006e 0054 0068 1ebf 0054 0068 00e0 006e 0068), without the spaces and with characters instead of the corresponding hex-code. (Note: If someone writes ConTeXt support for it, be careful about escaping parenthesis for U+29xx - not that anyone would need those arrows in comments, but you never know.)
feff ("byte order mark", whatever that means) at the beginning seems to be only a switch for multi byte encoding inside the parenthesis.
I didn't try this out yet, so perhaps I'm missing something else here as well. If anyone knows how to try it out, please report if it works. I guess that another encoding, similar to enco-pdf should be defined first and then used inside the \doPDFsetupidentity definition. If characters other than those present in one-byte pdf encoding are present in an argument (Author, Comment, ...), than this more advanced encoding should be used for that field.
\PDFunicodetrue should do the trick (i need to look into the bookmarks since pdftex needed a fix for that)
Out of curiosity: can you manually write Vietnamese characters to those fields in Adobe? I have a feeling that they loose the second accent if I copy-paste some double-accented characters, but I don't know if this is just a visual effect/lack of proper fonts or if it really isn't supported.
in principle, it should be possible; the problem with cut and paste is that the operating system may do things with the buffer Hans ----------------------------------------------------------------- Hans Hagen | PRAGMA ADE Ridderstraat 27 | 8061 GH Hasselt | The Netherlands tel: 038 477 53 69 | fax: 038 477 53 74 | www.pragma-ade.com | www.pragma-pod.nl -----------------------------------------------------------------