=================================================================== RCS file: /cvsrepo/anoncvs/cvs/src/usr.bin/tmux/style.c,v retrieving revision 1.1 retrieving revision 1.2 diff -c -r1.1 -r1.2 *** src/usr.bin/tmux/style.c 2014/01/28 23:07:09 1.1 --- src/usr.bin/tmux/style.c 2014/02/22 01:38:47 1.2 *************** *** 1,4 **** ! /* $OpenBSD: style.c,v 1.1 2014/01/28 23:07:09 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott --- 1,4 ---- ! /* $OpenBSD: style.c,v 1.2 2014/02/22 01:38:47 nicm Exp $ */ /* * Copyright (c) 2007 Nicholas Marriott *************** *** 203,210 **** memcpy(gc, &grid_default_cell, sizeof *gc); gcp = options_get_style(oo, name); ! colour_set_fg(gc, gcp->fg); ! colour_set_bg(gc, gcp->bg); gc->attr |= gcp->attr; } --- 203,216 ---- memcpy(gc, &grid_default_cell, sizeof *gc); gcp = options_get_style(oo, name); ! if (gcp->flags & GRID_FLAG_FG256) ! colour_set_fg(gc, gcp->fg | 0x100); ! else ! colour_set_fg(gc, gcp->fg); ! if (gcp->flags & GRID_FLAG_BG256) ! colour_set_bg(gc, gcp->bg | 0x100); ! else ! colour_set_bg(gc, gcp->bg); gc->attr |= gcp->attr; } *************** *** 215,224 **** struct grid_cell *gcp; gcp = options_get_style(oo, name); ! if (gcp->fg != 8) ! colour_set_fg(gc, gcp->fg); ! if (gcp->bg != 8) ! colour_set_bg(gc, gcp->bg); if (gcp->attr != 0) gc->attr |= gcp->attr; } --- 221,238 ---- struct grid_cell *gcp; gcp = options_get_style(oo, name); ! if (gcp->fg != 8) { ! if (gcp->flags & GRID_FLAG_FG256) ! colour_set_fg(gc, gcp->fg | 0x100); ! else ! colour_set_fg(gc, gcp->fg); ! } ! if (gcp->bg != 8) { ! if (gcp->flags & GRID_FLAG_BG256) ! colour_set_bg(gc, gcp->bg | 0x100); ! else ! colour_set_bg(gc, gcp->bg); ! } if (gcp->attr != 0) gc->attr |= gcp->attr; }