Skip to content

Instantly share code, notes, and snippets.

@brimston3
Created October 3, 2016 16:00
Show Gist options
  • Select an option

  • Save brimston3/cf94fb8bf1c546ad9ac327fe93e5a56a to your computer and use it in GitHub Desktop.

Select an option

Save brimston3/cf94fb8bf1c546ad9ac327fe93e5a56a to your computer and use it in GitHub Desktop.
Very simple example generating pdf bookmarks in LaTeX w/ hyperref
\documentclass{article}
\usepackage[bookmarks=true]{hyperref}
\hypersetup{pdfencoding=auto,
pdfauthor={SomeAuthor}
}
\begin{document}
\section{Test 1}
text 1
\subsection{Test 1.1}
text 1.1
\clearpage
\section*{Test 2}
\addcontentsline{toc}{section}{Test 2}
text 2
\subsection*{Test 2.1}
\addcontentsline{toc}{subsection}{Test 2.1}
text 2.1
\end{document}
@brimston3

Copy link
Copy Markdown
Author

Too short to need a license but if you need one, MIT or X11.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment