+Mon Jan 18 01:21:03 1999 Lars Hamann <lars@gtk.org>
+
+ * gtk/gtkctree.c (draw_row): fixed auto resize bug.
+
Sun Jan 17 17:35:28 CST 1999 Shawn T. Amundson <amundson@gtk.org>
* Released GTK+ 1.1.13
(GTK_CELL_PIXTEXT (clist_row->cell[i])->pixmap,
&pixmap_width, &height);
- width = (pixmap_width +
- GTK_CELL_PIXTEXT (clist_row->cell[i])->spacing);
+ width = pixmap_width;
if (GTK_CELL_PIXTEXT (clist_row->cell[i])->text)
{
width += string_width;
}
+ if (GTK_CELL_PIXTEXT (clist_row->cell[i])->text &&
+ GTK_CELL_PIXTEXT (clist_row->cell[i])->pixmap)
+ width += GTK_CELL_PIXTEXT (clist_row->cell[i])->spacing;
+
if (i == ctree->tree_column)
width += (ctree->tree_indent *
((GtkCTreeRow *)clist_row)->level);
if (string_width)
{
if (clist->column[i].justification == GTK_JUSTIFY_RIGHT)
- offset = (old_offset - string_width -
- GTK_CELL_PIXTEXT (clist_row->cell[i])->spacing);
+ {
+ offset = (old_offset - string_width);
+ if (GTK_CELL_PIXTEXT (clist_row->cell[i])->pixmap)
+ offset -= GTK_CELL_PIXTEXT (clist_row->cell[i])->spacing;
+ }
else
- offset += GTK_CELL_PIXTEXT (clist_row->cell[i])->spacing;
+ {
+ if (GTK_CELL_PIXTEXT (clist_row->cell[i])->pixmap)
+ offset += GTK_CELL_PIXTEXT (clist_row->cell[i])->spacing;
+ }
if (style != GTK_WIDGET (clist)->style)
row_center_offset = (((clist->row_height - style->font->ascent -