mirror of
https://git.lyx.org/repos/lyx.git
synced 2024-11-14 06:57:01 +00:00
tex2lyx: addendum to r39949; handle the case that LyX's defined colors are defined but not used, now it is assures that only the color is used that is actually used for \color and \pagecolor
git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@39989 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
parent
fc75fcafbd
commit
e9d2c866b4
@ -915,6 +915,24 @@ void parse_preamble(Parser & p, ostream & os,
|
|||||||
h_suppress_date = "true";
|
h_suppress_date = "true";
|
||||||
}
|
}
|
||||||
|
|
||||||
|
else if (t.cs() == "color") {
|
||||||
|
string argument = p.getArg('{', '}');
|
||||||
|
// check the case that not a color defined by LyX is used
|
||||||
|
if (argument != "document_fontcolor") {
|
||||||
|
h_preamble << t.asInput() << '{' << argument << '}';
|
||||||
|
h_fontcolor = "";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
else if (t.cs() == "pagecolor") {
|
||||||
|
string argument = p.getArg('{', '}');
|
||||||
|
// check the case that not a color defined by LyX is used
|
||||||
|
if (argument != "page_backgroundcolor") {
|
||||||
|
h_preamble << t.asInput() << '{' << argument << '}';
|
||||||
|
h_backgroundcolor = "";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
else if (t.cs() == "makeatletter") {
|
else if (t.cs() == "makeatletter") {
|
||||||
// LyX takes care of this
|
// LyX takes care of this
|
||||||
p.setCatCode('@', catLetter);
|
p.setCatCode('@', catLetter);
|
||||||
|
@ -15,7 +15,7 @@
|
|||||||
\definecolor{document_fontcolor}{rgb}{0.66796875, 1, 0}
|
\definecolor{document_fontcolor}{rgb}{0.66796875, 1, 0}
|
||||||
\color{document_fontcolor}
|
\color{document_fontcolor}
|
||||||
\definecolor{note_fontcolor}{rgb}{0, 0, 1}
|
\definecolor{note_fontcolor}{rgb}{0, 0, 1}
|
||||||
\definecolor{shadecolor}{rgb}{1, 0, 0}
|
\definecolor{shadecolor}{rgb}{1, 1, 0}
|
||||||
\usepackage{framed}
|
\usepackage{framed}
|
||||||
\usepackage{calc}
|
\usepackage{calc}
|
||||||
\usepackage{fancybox}
|
\usepackage{fancybox}
|
||||||
|
Loading…
Reference in New Issue
Block a user