X-Git-Url: https://git.lyx.org/gitweb/?a=blobdiff_plain;f=src%2FPDFOptions.h;h=47e4c4136c07072340ed9eb29616d3ee147b118e;hb=a49c4e3454e428eeb0f2678eb9db3d086b2b789c;hp=84580f23e14e5289f28b88a751435b211f68e909;hpb=d0cd79a7edbf3515f8d239fca1897a17052132de;p=lyx.git diff --git a/src/PDFOptions.h b/src/PDFOptions.h index 84580f23e1..47e4c4136c 100644 --- a/src/PDFOptions.h +++ b/src/PDFOptions.h @@ -12,25 +12,15 @@ #ifndef PDFOPTIONS_H #define PDFOPTIONS_H -#include "support/docstream.h" +#include "support/strfwd.h" + +#include namespace lyx { class Lexer; /// Options for PDF generation - -/* - Possible cleanups, left for next fileformat change: - - - bookmarksopenlevel is stored in .lyx as string; - after change to spinbox it would be appropriate - change to int. - - store_options flag can be completely replaced by - function store_options() doing essentialy the same - as empty() now. -*/ - class PDFOptions { public: /// @@ -40,10 +30,10 @@ public: /// output to lyx header void writeFile(std::ostream &) const; /// output to tex header - void writeLaTeX(odocstringstream &) const; + void writeLaTeX(odocstream &, bool hyperref_already_provided) const; /// read tokens from lyx header std::string readToken(Lexer &lex, std::string const & token); - /// keep implicit hyperref settings + /// set implicit settings for hyperref void clear(); /// @@ -128,6 +118,15 @@ public: * dialog -> PDFOptions.pagemode . */ std::string pagemode; + /** + * Flag indicating whether hyperref tries to derive the values for + * pdftitle and pdfauthor from \title and \author. + * pdfusetitle boolean false + * + * Note that we use true as default value instead. The option is also + * used in latex output only when title and author is not filled. + */ + bool pdfusetitle; ///latex string static const std::string pagemode_fullscreen; /** @@ -136,8 +135,10 @@ public: std::string quoted_options; /** * Possible syntax check of users additional parameters here. + * Returns repaired string. For the time being only newlines + * are checked. */ - std::string quoted_options_get() const; + std::string quoted_options_check(std::string const str) const; /**