mirror of
https://github.com/tmux/tmux.git
synced 2024-11-17 18:08:51 +00:00
Merge branch 'obsd-master'
This commit is contained in:
commit
80235d6fdd
25
tty.c
25
tty.c
@ -1841,10 +1841,18 @@ tty_check_fg(struct tty *tty, const struct window_pane *wp,
|
|||||||
u_int colours;
|
u_int colours;
|
||||||
int c;
|
int c;
|
||||||
|
|
||||||
/* Perform substitution if this pane has a palette */
|
/*
|
||||||
if ((~gc->flags & GRID_FLAG_NOPALETTE) &&
|
* Perform substitution if this pane has a palette. If the bright
|
||||||
(c = window_pane_get_palette(wp, gc->fg)) != -1)
|
* attribute is set, use the bright entry in the palette by changing to
|
||||||
gc->fg = c;
|
* the aixterm colour.
|
||||||
|
*/
|
||||||
|
if (~gc->flags & GRID_FLAG_NOPALETTE) {
|
||||||
|
c = gc->fg;
|
||||||
|
if (gc->fg < 8 && gc->attr & GRID_ATTR_BRIGHT)
|
||||||
|
c += 90;
|
||||||
|
if ((c = window_pane_get_palette(wp, c)) != -1)
|
||||||
|
gc->fg = c;
|
||||||
|
}
|
||||||
|
|
||||||
/* Is this a 24-bit colour? */
|
/* Is this a 24-bit colour? */
|
||||||
if (gc->fg & COLOUR_FLAG_RGB) {
|
if (gc->fg & COLOUR_FLAG_RGB) {
|
||||||
@ -1894,10 +1902,11 @@ tty_check_bg(struct tty *tty, const struct window_pane *wp,
|
|||||||
u_int colours;
|
u_int colours;
|
||||||
int c;
|
int c;
|
||||||
|
|
||||||
/* Perform substitution if this pane has a palette */
|
/* Perform substitution if this pane has a palette. */
|
||||||
if ((~gc->flags & GRID_FLAG_NOPALETTE) &&
|
if (~gc->flags & GRID_FLAG_NOPALETTE) {
|
||||||
(c = window_pane_get_palette(wp, gc->bg)) != -1)
|
if ((c = window_pane_get_palette(wp, gc->bg)) != -1)
|
||||||
gc->bg = c;
|
gc->bg = c;
|
||||||
|
}
|
||||||
|
|
||||||
/* Is this a 24-bit colour? */
|
/* Is this a 24-bit colour? */
|
||||||
if (gc->bg & COLOUR_FLAG_RGB) {
|
if (gc->bg & COLOUR_FLAG_RGB) {
|
||||||
|
Loading…
Reference in New Issue
Block a user