In a long document I have two title pages and want to start the page numbering from one on the first non-title page. Thus I use \addtocounter{page}{-2}
at the begin of the document.
Pages before the first chapter is numbered in Roman, from there on in arabic.
Now I started to use the glossaries-package. I found that the page links in the glossary are pointing to the total page numbers in the pdf.
So if the first \gls{label}
is on page 2
in the arabic numbered section, the link behind the glossary entry points to the second title page.
All other links generated by hyperref are good.
In a different posting I learned, that it is because of the hypertexnames=false
option of hyperref. If I replace it as supposed in the other post, all the links to floats are broken.
How can I fix this problem? Or if not, how can I hide those page numbers? Did not find it in the manual of the package...
Example with broken links:
(comment the line hypertexnames=true,
and replace it by the two lines above to get the glossaries links working but loose the links to floats)
% 1. latex minimalgls
% 2. makeglossaries minimalgls (note no extension)
% 3. pdflatex minimalgls
\documentclass[ngerman]{article}
\listfiles
\usepackage[utf8]{inputenc}
\usepackage[ps2pdf,
bookmarks=true,% %%% generate bookmarks ...
bookmarksnumbered=true,% %%% ... with numbers
%
%plainpages=false,
%pdfpagelabels,
hypertexnames=true,% %%% needed for correct links to figures !!!
%
%breaklinks=true,% %%% breaks lines, but links are very small
%linkbordercolor={0 0 0},% %%% blue frames around links
pdfborder={0 0 0}]{hyperref}
\usepackage[hyperfirst=false]{glossaries} % acronym will go in main glossary
%\usepackage[acronym]{glossaries} % make a separate list of acronyms
\makeglossaries
\newglossaryentry{sample}{name={sample},
description={a sample entry}}
\newacronym[\glsshortpluralkey=cas,\glslongpluralkey=contrived
acronyms]{aca}{aca}{a contrived acronym}
\begin{document}
\pagenumbering{fnsymbol}
Title One
\clearpage
Title Two
\clearpage
\pagenumbering{Roman}
\printglossaries
\clearpage
\pagenumbering{arabic}
A \gls{sample} entry and \gls{aca}. Second use: \gls{aca}.
\clearpage
Plurals: \glspl{sample}. Reset acronym\glsreset{aca}.
First use: \glspl{aca}. Second use: \glspl{aca}.
\end{document}
ps2pdf
hyperref
option) works correctly for me (both withpdflatex
and withlatex
+dvips
+ps2pdf
). What version ofglossaries
andhyperref
do you have installed?