I am having some trouble with some anchors for sections, which automatically start at a new page. The TOC shows the right page numbers, where the PDF bookmarks show the page number of the previous page, which is also used by the anchor referenced by both.
Putting a \clearpage just before \section would solve the problem and defeat the purpose of using LaTeX for layouting.
My LaTeX preamble starts with
\documentclass[fleqn,titlepage=firstiscover,bibliography=totoc]{scrbook}
\usepackage[utf8]{inputenc}
\usepackage[ngerman]{babel}
\usepackage[T1]{fontenc}
\usepackage{bookmark}
\usepackage{url}
\usepackage{hyperref}
\hypersetup{hidelinks}
...
loading and defining some more math and formatting stuff later.
Is there an adaptable solution to this problem? I really do not want to put \clearpage where it does not belong.
bookmarkafterhyperrefpackage. Does it work? – Jan 25 '15 at 00:40bookmarkwasn't the problem. While writing a short example, I discovered a solution. It was a problem withhyperrefafter all. – tynn Jan 25 '15 at 16:00