mirror of
git://git.suckless.org/st
synced 2025-10-16 14:26:31 +01:00
add a few comments
This commit is contained in:
parent
d6c431859c
commit
5a4666c19e
26
st.c
26
st.c
@ -1420,14 +1420,14 @@ tsetattr(const int *attr, int l)
|
|||||||
if ((idx = tdefcolor(attr, &i, l)) >= 0)
|
if ((idx = tdefcolor(attr, &i, l)) >= 0)
|
||||||
term.c.attr.fg = idx;
|
term.c.attr.fg = idx;
|
||||||
break;
|
break;
|
||||||
case 39:
|
case 39: /* set foreground color to default */
|
||||||
term.c.attr.fg = defaultfg;
|
term.c.attr.fg = defaultfg;
|
||||||
break;
|
break;
|
||||||
case 48:
|
case 48:
|
||||||
if ((idx = tdefcolor(attr, &i, l)) >= 0)
|
if ((idx = tdefcolor(attr, &i, l)) >= 0)
|
||||||
term.c.attr.bg = idx;
|
term.c.attr.bg = idx;
|
||||||
break;
|
break;
|
||||||
case 49:
|
case 49: /* set background color to default */
|
||||||
term.c.attr.bg = defaultbg;
|
term.c.attr.bg = defaultbg;
|
||||||
break;
|
break;
|
||||||
case 58:
|
case 58:
|
||||||
@ -1532,7 +1532,7 @@ tsetmode(int priv, int set, const int *args, int narg)
|
|||||||
case 1006: /* 1006: extended reporting mode */
|
case 1006: /* 1006: extended reporting mode */
|
||||||
xsetmode(set, MODE_MOUSESGR);
|
xsetmode(set, MODE_MOUSESGR);
|
||||||
break;
|
break;
|
||||||
case 1034:
|
case 1034: /* 1034: enable 8-bit mode for keyboard input */
|
||||||
xsetmode(set, MODE_8BIT);
|
xsetmode(set, MODE_8BIT);
|
||||||
break;
|
break;
|
||||||
case 1049: /* swap screen & set/restore cursor as xterm */
|
case 1049: /* swap screen & set/restore cursor as xterm */
|
||||||
@ -1540,8 +1540,8 @@ tsetmode(int priv, int set, const int *args, int narg)
|
|||||||
break;
|
break;
|
||||||
tcursor((set) ? CURSOR_SAVE : CURSOR_LOAD);
|
tcursor((set) ? CURSOR_SAVE : CURSOR_LOAD);
|
||||||
/* FALLTHROUGH */
|
/* FALLTHROUGH */
|
||||||
case 47: /* swap screen */
|
case 47: /* swap screen buffer */
|
||||||
case 1047:
|
case 1047: /* swap screen buffer */
|
||||||
if (!allowaltscreen)
|
if (!allowaltscreen)
|
||||||
break;
|
break;
|
||||||
alt = IS_SET(MODE_ALTSCREEN);
|
alt = IS_SET(MODE_ALTSCREEN);
|
||||||
@ -1554,7 +1554,7 @@ tsetmode(int priv, int set, const int *args, int narg)
|
|||||||
if (*args != 1049)
|
if (*args != 1049)
|
||||||
break;
|
break;
|
||||||
/* FALLTHROUGH */
|
/* FALLTHROUGH */
|
||||||
case 1048:
|
case 1048: /* save/restore cursor (like DECSC/DECRC) */
|
||||||
tcursor((set) ? CURSOR_SAVE : CURSOR_LOAD);
|
tcursor((set) ? CURSOR_SAVE : CURSOR_LOAD);
|
||||||
break;
|
break;
|
||||||
case 2004: /* 2004: bracketed paste mode */
|
case 2004: /* 2004: bracketed paste mode */
|
||||||
@ -1913,7 +1913,7 @@ strhandle(void)
|
|||||||
if (narg > 1)
|
if (narg > 1)
|
||||||
xsettitle(strescseq.args[1]);
|
xsettitle(strescseq.args[1]);
|
||||||
return;
|
return;
|
||||||
case 52:
|
case 52: /* manipulate selection data */
|
||||||
if (narg > 2 && allowwindowops) {
|
if (narg > 2 && allowwindowops) {
|
||||||
dec = base64dec(strescseq.args[2]);
|
dec = base64dec(strescseq.args[2]);
|
||||||
if (dec) {
|
if (dec) {
|
||||||
@ -1924,9 +1924,9 @@ strhandle(void)
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
case 10:
|
case 10: /* set dynamic VT100 text foreground color */
|
||||||
case 11:
|
case 11: /* set dynamic VT100 text background color */
|
||||||
case 12:
|
case 12: /* set dynamic text cursor color */
|
||||||
if (narg < 2)
|
if (narg < 2)
|
||||||
break;
|
break;
|
||||||
p = strescseq.args[1];
|
p = strescseq.args[1];
|
||||||
@ -1967,9 +1967,9 @@ strhandle(void)
|
|||||||
tfulldirt();
|
tfulldirt();
|
||||||
}
|
}
|
||||||
return;
|
return;
|
||||||
case 110:
|
case 110: /* reset dynamic VT100 text foreground color */
|
||||||
case 111:
|
case 111: /* reset dynamic VT100 text background color */
|
||||||
case 112:
|
case 112: /* reset dynamic text cursor color */
|
||||||
if (narg != 1)
|
if (narg != 1)
|
||||||
break;
|
break;
|
||||||
if ((j = par - 110) < 0 || j >= LEN(osc_table))
|
if ((j = par - 110) < 0 || j >= LEN(osc_table))
|
||||||
|
Loading…
x
Reference in New Issue
Block a user