I use hyperref
for a number of reasons, but among other things it sets up the document properties up well. As long as I compile with XeLaTeX that is. As soon as I compile with LuaLaTeX, everything is a jumble. There are many more fields with issues in my real project, but here is an MWE using just the title field:
\documentclass{scrartcl}
\usepackage{polyglossia}
\setmainlanguage{turkish}
\makeatletter
\usepackage[hidelinks]{hyperref}
\AtBeginDocument{%
\hypersetup{%
pdftitle = {\@title}
}
}{}
\makeatother
\title{RAB'BİN GÜNÜ}
\begin{document}
Title in document properties should match: RAB'BİN GÜNÜ
\end{document}
Compile with xelatex
gives me:
Title: RAB’BİN GÜNÜ
But lualatex
eats Unicode for lunch and has indigestion:
Title: RAB'BİN GÜNÜ
How do I get proper Unicode characters into the document property fields when compiling with LuaLaTeX?