comparison finch/libgnt/gnttree.c @ 18726:68fec9f954dd

Make sure long titles remain within their own cell.
author Sadrul Habib Chowdhury <imadil@gmail.com>
date Mon, 30 Jul 2007 20:46:07 +0000
parents a69ab280147b
children b5d6e360eca0
comparison
equal deleted inserted replaced
18725:1aeda1e812a8 18726:68fec9f954dd
448 for (i = 0; i < tree->ncol; i++) 448 for (i = 0; i < tree->ncol; i++)
449 { 449 {
450 if (COLUMN_INVISIBLE(tree, i)) { 450 if (COLUMN_INVISIBLE(tree, i)) {
451 continue; 451 continue;
452 } 452 }
453 mvwaddstr(widget->window, pos, x + 1, tree->columns[i].title); 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 | COLOR_PAIR(GNT_COLOR_NORMAL)); 458 tree_mark_columns(tree, pos, 0, ACS_TTEE | COLOR_PAIR(GNT_COLOR_NORMAL));