(turn_on_face): In standout mode apply specified

fg to bg, and specified bg to fg (this makes the logic of
inversion on terminal consistent with X).
This commit is contained in:
Juri Linkov 2005-06-30 14:57:50 +00:00
parent 7ecc34e9e6
commit 9b08f2c11b

View file

@ -2005,14 +2005,20 @@ turn_on_face (f, face_id)
if (fg >= 0 && TS_set_foreground)
{
p = tparam (TS_set_foreground, NULL, 0, (int) fg);
if (standout_mode)
p = tparam (TS_set_background, NULL, 0, (int) fg);
else
p = tparam (TS_set_foreground, NULL, 0, (int) fg);
OUTPUT (p);
xfree (p);
}
if (bg >= 0 && TS_set_background)
{
p = tparam (TS_set_background, NULL, 0, (int) bg);
if (standout_mode)
p = tparam (TS_set_foreground, NULL, 0, (int) bg);
else
p = tparam (TS_set_background, NULL, 0, (int) bg);
OUTPUT (p);
xfree (p);
}