Commit 790a6ae5 authored by Owen Taylor's avatar Owen Taylor Committed by Owen Taylor

Empty rows/columns of the table should not have been marked as being able

Tue Aug  4 10:59:19 1998  Owen Taylor  <otaylor@redhat.com>

	* gtk/gtktable.[ch]: Empty rows/columns of the table
        should not have been marked as being able to shrink.
	(Fixes prorlem with shrinking scrollbarless GIMP canvases)
parent fb8cd952
Tue Aug 4 10:59:19 1998 Owen Taylor <otaylor@redhat.com>
* gtk/gtktable.[ch]: Empty rows/columns of the table
should not have been marked as being able to shrink.
(Fixes prorlem with shrinking scrollbarless GIMP canvases)
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
......
Tue Aug 4 10:59:19 1998 Owen Taylor <otaylor@redhat.com>
* gtk/gtktable.[ch]: Empty rows/columns of the table
should not have been marked as being able to shrink.
(Fixes prorlem with shrinking scrollbarless GIMP canvases)
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
......
Tue Aug 4 10:59:19 1998 Owen Taylor <otaylor@redhat.com>
* gtk/gtktable.[ch]: Empty rows/columns of the table
should not have been marked as being able to shrink.
(Fixes prorlem with shrinking scrollbarless GIMP canvases)
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
......
Tue Aug 4 10:59:19 1998 Owen Taylor <otaylor@redhat.com>
* gtk/gtktable.[ch]: Empty rows/columns of the table
should not have been marked as being able to shrink.
(Fixes prorlem with shrinking scrollbarless GIMP canvases)
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
......
Tue Aug 4 10:59:19 1998 Owen Taylor <otaylor@redhat.com>
* gtk/gtktable.[ch]: Empty rows/columns of the table
should not have been marked as being able to shrink.
(Fixes prorlem with shrinking scrollbarless GIMP canvases)
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
......
Tue Aug 4 10:59:19 1998 Owen Taylor <otaylor@redhat.com>
* gtk/gtktable.[ch]: Empty rows/columns of the table
should not have been marked as being able to shrink.
(Fixes prorlem with shrinking scrollbarless GIMP canvases)
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
......
Tue Aug 4 10:59:19 1998 Owen Taylor <otaylor@redhat.com>
* gtk/gtktable.[ch]: Empty rows/columns of the table
should not have been marked as being able to shrink.
(Fixes prorlem with shrinking scrollbarless GIMP canvases)
1998-08-03 Federico Mena Quintero <federico@nuclecu.unam.mx>
* gtk/gtkctree.c (gtk_ctree_find_by_row_data_custom): New public
......
......@@ -1071,6 +1071,7 @@ gtk_table_size_allocate_init (GtkTable *table)
table->cols[col].need_shrink = TRUE;
table->cols[col].expand = FALSE;
table->cols[col].shrink = TRUE;
table->cols[col].empty = TRUE;
}
for (row = 0; row < table->nrows; row++)
{
......@@ -1079,6 +1080,7 @@ gtk_table_size_allocate_init (GtkTable *table)
table->rows[row].need_shrink = TRUE;
table->rows[row].expand = FALSE;
table->rows[row].shrink = TRUE;
table->rows[row].empty = TRUE;
}
/* Loop over all the children and adjust the row and col values
......@@ -1101,6 +1103,8 @@ gtk_table_size_allocate_init (GtkTable *table)
if (!child->xshrink)
table->cols[child->left_attach].shrink = FALSE;
table->cols[child->left_attach].empty = FALSE;
}
if (child->top_attach == (child->bottom_attach - 1))
......@@ -1110,6 +1114,8 @@ gtk_table_size_allocate_init (GtkTable *table)
if (!child->yshrink)
table->rows[child->top_attach].shrink = FALSE;
table->rows[child->top_attach].empty = FALSE;
}
}
}
......@@ -1127,6 +1133,9 @@ gtk_table_size_allocate_init (GtkTable *table)
{
if (child->left_attach != (child->right_attach - 1))
{
for (col = child->left_attach; col < child->right_attach; col++)
table->cols[col].empty = FALSE;
if (child->xexpand)
{
has_expand = FALSE;
......@@ -1160,6 +1169,9 @@ gtk_table_size_allocate_init (GtkTable *table)
if (child->top_attach != (child->bottom_attach - 1))
{
for (row = child->top_attach; row < child->bottom_attach; row++)
table->rows[row].empty = FALSE;
if (child->yexpand)
{
has_expand = FALSE;
......@@ -1198,10 +1210,18 @@ gtk_table_size_allocate_init (GtkTable *table)
*/
for (col = 0; col < table->ncols; col++)
{
if (table->cols[col].need_expand)
table->cols[col].expand = TRUE;
if (!table->cols[col].need_shrink)
table->cols[col].shrink = FALSE;
if (table->cols[col].empty)
{
table->cols[col].expand = FALSE;
table->cols[col].shrink = FALSE;
}
else
{
if (table->cols[col].need_expand)
table->cols[col].expand = TRUE;
if (!table->cols[col].need_shrink)
table->cols[col].shrink = FALSE;
}
}
/* Loop over the rows and set the expand and shrink values
......@@ -1209,10 +1229,17 @@ gtk_table_size_allocate_init (GtkTable *table)
*/
for (row = 0; row < table->nrows; row++)
{
if (table->rows[row].need_expand)
table->rows[row].expand = TRUE;
if (!table->rows[row].need_shrink)
table->rows[row].shrink = FALSE;
if (table->rows[row].empty)
{
table->rows[row].expand = FALSE;
table->rows[row].shrink = FALSE;
}
{
if (table->rows[row].need_expand)
table->rows[row].expand = TRUE;
if (!table->rows[row].need_shrink)
table->rows[row].shrink = FALSE;
}
}
}
......
......@@ -87,6 +87,7 @@ struct _GtkTableRowCol
guint need_shrink : 1;
guint expand : 1;
guint shrink : 1;
guint empty : 1;
};
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment