I am trying to generate a PDF file (using pdflatex
) with hyperref
references; both the title and author should be visible as pdf properties, and both contain accents or non us-ASCII. The rest of the document compiles fine using \documentclass[a4paper,openright]{book}
, \usepackage[utf8]{inputenc}
and \usepackage[spanish]{babel}
.
I would expect this to work:
\usepackage[pdftex,colorlinks=true,
% ...
pdftitle={Título con acentos o eñes},
pdfauthor={Migueláñez}
]{hyperref}
-- it generates around 54 warnings and outputs something like
Title: T19 tulo con acentos o en126 nes
Author: Miguela19 an126 nez
Creator: LaTeX with hyperref package
Producer: pdfTeX-1.40.10
I have also tried leaving the pdfauthor empty and later using
\pdfstringdef{myauthor}{Miguel\'{a}\~{n}ez}
or
\pdfstringdef{myauthor}{Migueláñez}
and
\hypersetup{pdfauthor={\myauthor}}
But all variants result in errors instead of warnings.
pdfstringdef
like that:\pdfstringdef\mtGEP{gedit \176/.profile}
where\176
in this example is octal notation of tilde character.