mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-12-22 13:18:28 +00:00
PDFOptions: patch by Pavel to store the settings when the user switches hyperref temporarily off
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@20456 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
9966b45cf4
commit
d0cd79a7ed
@ -31,12 +31,23 @@ const string PDFOptions::pagemode_fullscreen("FullScreen");
|
||||
|
||||
bool PDFOptions::empty() const
|
||||
{
|
||||
return author.empty()
|
||||
&& title.empty()
|
||||
&& subject.empty()
|
||||
&& keywords.empty()
|
||||
&& pagemode.empty()
|
||||
&& quoted_options.empty();
|
||||
PDFOptions x; //implicit hyperref settings
|
||||
|
||||
return author == x.author
|
||||
&& title == x.title
|
||||
&& subject == x.subject
|
||||
&& keywords == x.keywords
|
||||
&& pagemode == x.pagemode
|
||||
&& quoted_options == x.quoted_options
|
||||
&& bookmarks == x.bookmarks
|
||||
&& bookmarksnumbered == x.bookmarksnumbered
|
||||
&& bookmarksopen == x.bookmarksopen
|
||||
&& bookmarksopenlevel == x.bookmarksopenlevel
|
||||
&& breaklinks == x.breaklinks
|
||||
&& pdfborder == x.pdfborder
|
||||
&& colorlinks == x.colorlinks
|
||||
&& backref == x.backref
|
||||
&& pagebackref == x.pagebackref ;
|
||||
}
|
||||
|
||||
void PDFOptions::writeFile(ostream & os) const
|
||||
|
@ -19,11 +19,23 @@ 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:
|
||||
///
|
||||
PDFOptions() { clear(); }
|
||||
/// check for string settings
|
||||
/// check whether user added any settings for hyperref
|
||||
bool empty() const;
|
||||
/// output to lyx header
|
||||
void writeFile(std::ostream &) const;
|
||||
|
Loading…
Reference in New Issue
Block a user