"\\dvipost{osend color pop}\n"
"\\dvipost{cbstart color push Blue}\n"
"\\dvipost{cbend color pop}\n"
- "\\newcommand{\\lyxinserted}[3]{\\changestart#3\\changeend}\n"
+ "\\newcommand{\\lyxadded}[3]{\\changestart#3\\changeend}\n"
"\\newcommand{\\lyxdeleted}[3]{%\n"
"\\changestart\\overstrikeon#3\\overstrikeoff\\changeend}\n";
-// TODO
-//static string const changetracking_soul_def =
-// "\\newcommand{\\lyxinserted}[3]{\\uwave{\\textcolor{blue}{#3}}}\n"
-// "\\newcommand{\\lyxdeleted}[3]{\\sout{\\textcolor{red}{#3}}}";
-
static string const changetracking_none_def =
- "\\newcommand{\\lyxinserted}[3]{#3}\n"
- "\\newcommand{\\lyxdeleted}[3]{}";
+ "\\newcommand{\\lyxadded}[3]{#3}\n"
+ "\\newcommand{\\lyxdeleted}[3]{}\n";
/////////////////////////////////////////////////////////////////////
"nicefrac",
"tipa",
"framed",
+ "pdfcolmk",
+ "soul",
"textcomp",
+ "xcolor",
};
int const nb_simplefeatures = sizeof(simplefeatures) / sizeof(char const *);
<< "]{graphicx}\n";
}
// shadecolor for shaded
- if (mustProvide("framed")) {
+ if (mustProvide("framed") && mustProvide("color")) {
RGBColor c = RGBColor(lcolor.getX11Name(Color::shadedbg));
packages << "\\definecolor{shadecolor}{rgb}{"
<< c.r/255 << ',' << c.g/255 << ',' << c.b/255 << "}\n";
getFloatDefinitions(macros);
// change tracking
- if (mustProvide("dvipost"))
+ if (mustProvide("ct-dvipost")) {
macros << changetracking_dvipost_def;
- if (mustProvide("ct-none"))
+ }
+ if (mustProvide("ct-xcolor-soul")) {
+ RGBColor cadd = RGBColor(lcolor.getX11Name(Color::addedtext));
+ macros << "\\providecolor{lyxadded}{rgb}{"
+ << cadd.r/255 << ',' << cadd.g/255 << ',' << cadd.b/255 << "}\n";
+
+ RGBColor cdel = RGBColor(lcolor.getX11Name(Color::deletedtext));
+ macros << "\\providecolor{lyxdeleted}{rgb}{"
+ << cdel.r/255 << ',' << cdel.g/255 << ',' << cdel.b/255 << "}\n";
+
+ macros << "\\newcommand{\\lyxadded}[3]{\\color{lyxadded}{#3}}\n"
+ << "\\newcommand{\\lyxdeleted}[3]{\\color{lyxdeleted}{\\st{#3}}}\n";
+ }
+ if (mustProvide("ct-none")) {
macros << changetracking_none_def;
+ }
return macros.str();
}