Make the color of the misspelled marking customizable.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@36612 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Vincent van Ravesteijn 2010-11-30 00:37:09 +00:00
parent d4fb2ac2ac
commit 51c5b13db1
3 changed files with 5 additions and 1 deletions

View File

@ -243,6 +243,7 @@ ColorSet::ColorSet()
{ Color_previewframe, N_("preview frame"), "previewframe", "black", "previewframe"},
{ Color_inherit, N_("inherit"), "inherit", "black", "inherit" },
{ Color_regexpframe, N_("regexp frame"), "green", "green", "green" },
{ Color_misspelled, N_("misspelled marking"), "misspelled", "red", "misspelled" },
{ Color_ignore, N_("ignore"), "ignore", "black", "ignore" },
{ Color_ignore, 0, 0, 0, 0 }
};

View File

@ -189,6 +189,8 @@ enum ColorCode {
Color_paragraphmarker,
/// Preview frame color
Color_previewframe,
/// The color of the misspelled marking
Color_misspelled,
// Logical attributes

View File

@ -361,7 +361,8 @@ void RowPainter::paintMisspelledMark(double orig_x, int desc, bool changed)
// to avoid drawing at the same vertical offset
int const offset = int(1.5 * lyxrc.zoom / 100.0); // [percent]
int const y = yo_ + desc + (changed ? offset : 0);
pi_.pain.line(int(orig_x), y, int(x_), y, Color_red, Painter::line_onoffdash, 1.0);
pi_.pain.line(int(orig_x), y, int(x_), y, Color_misspelled,
Painter::line_onoffdash, 1.0);
}