git.iko.soy/typeable/pandoc
on master help sign in
Added PDF metadata (title,author) in LaTeX standalone + PDF output.
7bc4dc3John MacFarlane
src/Text/Pandoc/Writers/LaTeX.hs+2
@@ -134,6 +134,8 @@ pandocToLaTeX options (Pandoc (Meta title authors date) blocks) = do
134 [ ("toc", if writerTableOfContents options then "yes" else "")
134 [ ("toc", if writerTableOfContents options then "yes" else "")
135 , ("body", main)
135 , ("body", main)
136 , ("title", titletext)
136 , ("title", titletext)
137+ , ("title-meta", stringify title)
138+ , ("author-meta", intercalate "; " $ map stringify authors)
137 , ("date", dateText)
139 , ("date", dateText)
138 , ("documentclass", if writerBeamer options
140 , ("documentclass", if writerBeamer options
139 then "beamer"
141 then "beamer"
templates+1−1

Submodule changed.

tests/lhs-test.latex+6
@@ -39,10 +39,16 @@
39 \usepackage[setpagesize=false, % page size defined by xetex
39 \usepackage[setpagesize=false, % page size defined by xetex
40 unicode=false, % unicode breaks when used with xetex
40 unicode=false, % unicode breaks when used with xetex
41 xetex,
41 xetex,
42+ bookmarks=true,
43+ pdfauthor={},
44+ pdftitle={},
42 colorlinks=true,
45 colorlinks=true,
43 linkcolor=blue]{hyperref}
46 linkcolor=blue]{hyperref}
44\else
47\else
45 \usepackage[unicode=true,
48 \usepackage[unicode=true,
49+ bookmarks=true,
50+ pdfauthor={},
51+ pdftitle={},
46 colorlinks=true,
52 colorlinks=true,
47 linkcolor=blue]{hyperref}
53 linkcolor=blue]{hyperref}
48\fi
54\fi
tests/lhs-test.latex+lhs+6
@@ -21,10 +21,16 @@
21 \usepackage[setpagesize=false, % page size defined by xetex
21 \usepackage[setpagesize=false, % page size defined by xetex
22 unicode=false, % unicode breaks when used with xetex
22 unicode=false, % unicode breaks when used with xetex
23 xetex,
23 xetex,
24+ bookmarks=true,
25+ pdfauthor={},
26+ pdftitle={},
24 colorlinks=true,
27 colorlinks=true,
25 linkcolor=blue]{hyperref}
28 linkcolor=blue]{hyperref}
26\else
29\else
27 \usepackage[unicode=true,
30 \usepackage[unicode=true,
31+ bookmarks=true,
32+ pdfauthor={},
33+ pdftitle={},
28 colorlinks=true,
34 colorlinks=true,
29 linkcolor=blue]{hyperref}
35 linkcolor=blue]{hyperref}
30\fi
36\fi
tests/writer.latex+6
@@ -38,10 +38,16 @@
38 \usepackage[setpagesize=false, % page size defined by xetex
38 \usepackage[setpagesize=false, % page size defined by xetex
39 unicode=false, % unicode breaks when used with xetex
39 unicode=false, % unicode breaks when used with xetex
40 xetex,
40 xetex,
41+ bookmarks=true,
42+ pdfauthor={John MacFarlane; Anonymous},
43+ pdftitle={Pandoc Test Suite},
41 colorlinks=true,
44 colorlinks=true,
42 linkcolor=blue]{hyperref}
45 linkcolor=blue]{hyperref}
43\else
46\else
44 \usepackage[unicode=true,
47 \usepackage[unicode=true,
48+ bookmarks=true,
49+ pdfauthor={John MacFarlane; Anonymous},
50+ pdftitle={Pandoc Test Suite},
45 colorlinks=true,
51 colorlinks=true,
46 linkcolor=blue]{hyperref}
52 linkcolor=blue]{hyperref}
47\fi
53\fi