comparison finch/libgnt/gnttree.c @ 21264:ad49d9dace9f

Draw the 'header' correctly when not showing borders.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Fri, 26 Oct 2007 08:41:17 +0000
parents f35b480841dc
children ca16de222b76
comparison
equal deleted inserted replaced
21263:1812b8ccfd7a 21264:ad49d9dace9f
453 mvwaddnstr(widget->window, pos, x + (x != pos), tree->columns[i].title, tree->columns[i].width); 453 mvwaddnstr(widget->window, pos, x + (x != pos), tree->columns[i].title, tree->columns[i].width);
454 NEXT_X; 454 NEXT_X;
455 } 455 }
456 if (pos) 456 if (pos)
457 { 457 {
458 tree_mark_columns(tree, pos, 0, ACS_TTEE | gnt_color_pair(GNT_COLOR_NORMAL)); 458 tree_mark_columns(tree, pos, 0,
459 (tree->show_separator ? ACS_TTEE : ACS_HLINE) | gnt_color_pair(GNT_COLOR_NORMAL));
459 tree_mark_columns(tree, pos, widget->priv.height - pos, 460 tree_mark_columns(tree, pos, widget->priv.height - pos,
460 ACS_BTEE | gnt_color_pair(GNT_COLOR_NORMAL)); 461 (tree->show_separator ? ACS_BTEE : ACS_HLINE) | gnt_color_pair(GNT_COLOR_NORMAL));
461 } 462 }
462 tree_mark_columns(tree, pos, pos + 1, 463 tree_mark_columns(tree, pos, pos + 1,
463 (tree->show_separator ? ACS_PLUS : ACS_HLINE) | gnt_color_pair(GNT_COLOR_NORMAL)); 464 (tree->show_separator ? ACS_PLUS : ACS_HLINE) | gnt_color_pair(GNT_COLOR_NORMAL));
464 tree_mark_columns(tree, pos, pos, 465 tree_mark_columns(tree, pos, pos,
465 (tree->show_separator ? ACS_VLINE : ' ') | gnt_color_pair(GNT_COLOR_NORMAL)); 466 (tree->show_separator ? ACS_VLINE : ' ') | gnt_color_pair(GNT_COLOR_NORMAL));