3 * \file src/PDFOptions.h
4 * This file is part of LyX, the document processor.
5 * Licence details can be found in the file COPYING.
9 * Full author contact details are available in file CREDITS.
17 #include "support/docstream.h"
23 /// Options for PDF generation
26 PDFOptions() { clear(); }
38 * A set of Acrobat bookmarks are written, in a manner similar to the
40 * bookmarks boolean true
44 * If Acrobat bookmarks are requested, include section numbers.
45 * bookmarksnumbered boolean false
47 bool bookmarksnumbered;
49 * If Acrobat bookmarks are requested, show them with all the subtrees
51 * bookmarksopen boolean false
55 * Level (\maxdimen) to which bookmarks are open
56 * bookmarksopenlevel parameter
58 std::string bookmarksopenlevel;
60 * Allows link text to break across lines.
61 * breaklinks boolean false
65 * The style of box around links; defaults to a box with lines of 1pt
66 * thickness, but the colorlinks option resets it to produce no border.
67 * pdfborder "0 0 1" / "0 0 0"
68 * Note that the color of link borders can be specified only as 3
69 * numbers in the range 0..1, giving an RGB color.
70 * You cannot use colors defined in TEX.
72 * We represent here only the last bit, there is no semantics in the
73 * first two. Morover the aim is not to represent the whole pdfborder,
74 * but just to deny the ugly boxes around pdf links.
78 * colorlinks boolean false
82 * Adds backlink text to the end of each item in the bibliography,
83 * as a list of section numbers.
84 * This can only work properly if there is a blank line after each
86 * backref boolean false
90 * Adds backlink text to the end of each item in the bibliography,
91 * as a list of page numbers.
92 * pagebackref boolean false
96 * Determines how the file is opening in Acrobat;
97 * the possibilities are None, UseThumbs (show thumbnails), UseOutlines
98 * (show bookmarks), and FullScreen.
99 * If no mode if explicitly chosen, but the bookmarks option is set,
100 * UseOutlines is used.
101 * pagemode text empty
103 * We currently implement only FullScreen, but all modes can be saved
104 * here, lyx format & latex writer is prepared.
105 * The only thing needed in such a case is wider Settings
106 * dialog -> PDFOptions.pagemode .
108 std::string pagemode;
110 static const std::string pagemode_fullscreen;
112 * Additional parameters for hyperref given from user.
114 std::string quoted_options;
116 * Possible syntax check of users additional parameters here.
118 std::string quoted_options_get() const;
122 * Flag indicating whether user made some input into PDF preferences.
123 * We want to save options, when user decide to switch off PDF support
127 /// check for string settings
129 /// output to lyx header
130 void writeFile(std::ostream &) const;
131 /// output to tex header
132 void writeLaTeX(odocstream &) const;
133 /// read tokens from lyx header
134 std::string readToken(Lexer &lex, std::string const & token);
135 /// keep implicit hyperref settings
142 #endif // PDFOPTIONS_H