mirror of
https://github.com/openbsd/xenocara.git
synced 2025-12-11 03:39:26 +00:00
Update to xterm 279. Tested by krw@, mpi@, shadchin@.
This commit is contained in:
@@ -1,7 +1,7 @@
|
||||
/* $XTermId: doublechr.c,v 1.76 2011/09/11 14:59:40 tom Exp $ */
|
||||
/* $XTermId: doublechr.c,v 1.81 2012/04/15 23:39:53 tom Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright 1997-2010,2011 by Thomas E. Dickey
|
||||
* Copyright 1997-2011,2012 by Thomas E. Dickey
|
||||
*
|
||||
* All Rights Reserved
|
||||
*
|
||||
@@ -60,7 +60,8 @@ repaint_line(XtermWidget xw, unsigned newChrSet)
|
||||
/*
|
||||
* Ignore repetition.
|
||||
*/
|
||||
if ((ld = getLineData(screen, currow)) != 0) {
|
||||
if (!IsLeftRightMode(xw)
|
||||
&& (ld = getLineData(screen, currow)) != 0) {
|
||||
unsigned oldChrSet = GetLineDblCS(ld);
|
||||
|
||||
if (oldChrSet != newChrSet) {
|
||||
@@ -83,10 +84,11 @@ repaint_line(XtermWidget xw, unsigned newChrSet)
|
||||
* single-size and double-size font. So we paint our own.
|
||||
*/
|
||||
ClearCurBackground(xw,
|
||||
CursorY(screen, currow),
|
||||
LineCursorX(screen, ld, 0),
|
||||
(unsigned) FontHeight(screen),
|
||||
len * (unsigned) LineFontWidth(screen, ld));
|
||||
currow,
|
||||
0,
|
||||
1,
|
||||
len,
|
||||
(unsigned) LineFontWidth(screen, ld));
|
||||
|
||||
SetLineDblCS(ld, newChrSet);
|
||||
|
||||
@@ -134,6 +136,34 @@ xterm_DECDWL(XtermWidget xw GCC_UNUSED)
|
||||
#endif
|
||||
}
|
||||
|
||||
/*
|
||||
* Reset all lines on the screen to single-width/single-height.
|
||||
*/
|
||||
void
|
||||
xterm_ResetDouble(XtermWidget xw)
|
||||
{
|
||||
#if OPT_DEC_CHRSET
|
||||
TScreen *screen = TScreenOf(xw);
|
||||
Boolean changed = False;
|
||||
LineData *ld;
|
||||
unsigned code;
|
||||
int row;
|
||||
|
||||
for (row = 0; row < screen->max_row; ++row) {
|
||||
if ((ld = getLineData(screen, ROW2INX(screen, row))) != 0) {
|
||||
code = GetLineDblCS(ld);
|
||||
if (code != CSET_SWL) {
|
||||
SetLineDblCS(ld, CSET_SWL);
|
||||
changed = True;
|
||||
}
|
||||
}
|
||||
}
|
||||
if (changed) {
|
||||
xtermRepaint(xw);
|
||||
}
|
||||
#endif
|
||||
}
|
||||
|
||||
#if OPT_DEC_CHRSET
|
||||
static void
|
||||
discard_font(XtermWidget xw, int n)
|
||||
|
||||
Reference in New Issue
Block a user