mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-03-21 22:28:37 -05:00
Fix line cursor colours (fallout from `256-colours'), on both Windows and Unix.
[originally from svn r5012]
This commit is contained in:
parent
cbfd7bb7f5
commit
a27ce0492b
@ -2163,7 +2163,7 @@ void do_cursor(Context ctx, int x, int y, wchar_t *text, int len,
|
|||||||
length = inst->font_height;
|
length = inst->font_height;
|
||||||
}
|
}
|
||||||
|
|
||||||
gdk_gc_set_foreground(gc, &inst->cols[NCFGCOLOURS-1]);
|
gdk_gc_set_foreground(gc, &inst->cols[261]);
|
||||||
if (passive) {
|
if (passive) {
|
||||||
for (i = 0; i < length; i++) {
|
for (i = 0; i < length; i++) {
|
||||||
if (i % 2 == 0) {
|
if (i % 2 == 0) {
|
||||||
|
@ -3234,7 +3234,7 @@ void do_cursor(Context ctx, int x, int y, wchar_t *text, int len,
|
|||||||
if (attr & TATTR_ACTCURS) {
|
if (attr & TATTR_ACTCURS) {
|
||||||
HPEN oldpen;
|
HPEN oldpen;
|
||||||
oldpen =
|
oldpen =
|
||||||
SelectObject(hdc, CreatePen(PS_SOLID, 0, colours[23]));
|
SelectObject(hdc, CreatePen(PS_SOLID, 0, colours[261]));
|
||||||
MoveToEx(hdc, startx, starty, NULL);
|
MoveToEx(hdc, startx, starty, NULL);
|
||||||
LineTo(hdc, startx + dx * length, starty + dy * length);
|
LineTo(hdc, startx + dx * length, starty + dy * length);
|
||||||
oldpen = SelectObject(hdc, oldpen);
|
oldpen = SelectObject(hdc, oldpen);
|
||||||
@ -3242,7 +3242,7 @@ void do_cursor(Context ctx, int x, int y, wchar_t *text, int len,
|
|||||||
} else {
|
} else {
|
||||||
for (i = 0; i < length; i++) {
|
for (i = 0; i < length; i++) {
|
||||||
if (i % 2 == 0) {
|
if (i % 2 == 0) {
|
||||||
SetPixel(hdc, startx, starty, colours[23]);
|
SetPixel(hdc, startx, starty, colours[261]);
|
||||||
}
|
}
|
||||||
startx += dx;
|
startx += dx;
|
||||||
starty += dy;
|
starty += dy;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user