summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ChangeLog11
-rw-r--r--ChangeLog.pre-2-011
-rw-r--r--ChangeLog.pre-2-1011
-rw-r--r--ChangeLog.pre-2-211
-rw-r--r--ChangeLog.pre-2-411
-rw-r--r--ChangeLog.pre-2-611
-rw-r--r--ChangeLog.pre-2-811
-rw-r--r--gtk/gtkbutton.c12
-rw-r--r--gtk/gtkclist.c14
-rw-r--r--gtk/gtkframe.c8
-rw-r--r--gtk/gtkhandlebox.c4
-rw-r--r--gtk/gtkhbox.c6
-rw-r--r--gtk/gtkhpaned.c4
-rw-r--r--gtk/gtklist.c2
-rw-r--r--gtk/gtkmenu.c2
-rw-r--r--gtk/gtkmenubar.c2
-rw-r--r--gtk/gtkmenuitem.c4
-rw-r--r--gtk/gtknotebook.c20
-rw-r--r--gtk/gtkscrolledwindow.c16
-rw-r--r--gtk/gtktable.c8
-rw-r--r--gtk/gtktree.c2
-rw-r--r--gtk/gtktreeitem.c4
-rw-r--r--gtk/gtkvbox.c6
-rw-r--r--gtk/gtkviewport.c4
-rw-r--r--gtk/gtkvpaned.c4
25 files changed, 138 insertions, 61 deletions
diff --git a/ChangeLog b/ChangeLog
index 7e403c19d..59534b261 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,14 @@
+Wed Jan 13 22:34:29 1999 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkbutton.c gtk/gtkclist.c gtk/gtkhandlebox.c
+ gtk/gtkframe.c gtk/gtk[hv]box.c gtk[hv]paned.c gtk/gtklist.c
+ gtkmenu.c gtkmenuitem.c gtkmenubar.c gtknotebook.c
+ gtk/gtkscrolledwindow.c gtk/gtktable.c gtk/gtktree.c
+ gtk/gtktreeeitem.c gtk/gtkviewport.c
+
+ Fix up comparisons of signed and unsigned ints to avoid
+ assigning negative widths/heigths.
+
Wed Jan 13 21:18:41 1999 Owen Taylor <otaylor@redhat.com>
* acinclude.m4 (ac_result): Unset CATOBJEXT so
diff --git a/ChangeLog.pre-2-0 b/ChangeLog.pre-2-0
index 7e403c19d..59534b261 100644
--- a/ChangeLog.pre-2-0
+++ b/ChangeLog.pre-2-0
@@ -1,3 +1,14 @@
+Wed Jan 13 22:34:29 1999 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkbutton.c gtk/gtkclist.c gtk/gtkhandlebox.c
+ gtk/gtkframe.c gtk/gtk[hv]box.c gtk[hv]paned.c gtk/gtklist.c
+ gtkmenu.c gtkmenuitem.c gtkmenubar.c gtknotebook.c
+ gtk/gtkscrolledwindow.c gtk/gtktable.c gtk/gtktree.c
+ gtk/gtktreeeitem.c gtk/gtkviewport.c
+
+ Fix up comparisons of signed and unsigned ints to avoid
+ assigning negative widths/heigths.
+
Wed Jan 13 21:18:41 1999 Owen Taylor <otaylor@redhat.com>
* acinclude.m4 (ac_result): Unset CATOBJEXT so
diff --git a/ChangeLog.pre-2-10 b/ChangeLog.pre-2-10
index 7e403c19d..59534b261 100644
--- a/ChangeLog.pre-2-10
+++ b/ChangeLog.pre-2-10
@@ -1,3 +1,14 @@
+Wed Jan 13 22:34:29 1999 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkbutton.c gtk/gtkclist.c gtk/gtkhandlebox.c
+ gtk/gtkframe.c gtk/gtk[hv]box.c gtk[hv]paned.c gtk/gtklist.c
+ gtkmenu.c gtkmenuitem.c gtkmenubar.c gtknotebook.c
+ gtk/gtkscrolledwindow.c gtk/gtktable.c gtk/gtktree.c
+ gtk/gtktreeeitem.c gtk/gtkviewport.c
+
+ Fix up comparisons of signed and unsigned ints to avoid
+ assigning negative widths/heigths.
+
Wed Jan 13 21:18:41 1999 Owen Taylor <otaylor@redhat.com>
* acinclude.m4 (ac_result): Unset CATOBJEXT so
diff --git a/ChangeLog.pre-2-2 b/ChangeLog.pre-2-2
index 7e403c19d..59534b261 100644
--- a/ChangeLog.pre-2-2
+++ b/ChangeLog.pre-2-2
@@ -1,3 +1,14 @@
+Wed Jan 13 22:34:29 1999 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkbutton.c gtk/gtkclist.c gtk/gtkhandlebox.c
+ gtk/gtkframe.c gtk/gtk[hv]box.c gtk[hv]paned.c gtk/gtklist.c
+ gtkmenu.c gtkmenuitem.c gtkmenubar.c gtknotebook.c
+ gtk/gtkscrolledwindow.c gtk/gtktable.c gtk/gtktree.c
+ gtk/gtktreeeitem.c gtk/gtkviewport.c
+
+ Fix up comparisons of signed and unsigned ints to avoid
+ assigning negative widths/heigths.
+
Wed Jan 13 21:18:41 1999 Owen Taylor <otaylor@redhat.com>
* acinclude.m4 (ac_result): Unset CATOBJEXT so
diff --git a/ChangeLog.pre-2-4 b/ChangeLog.pre-2-4
index 7e403c19d..59534b261 100644
--- a/ChangeLog.pre-2-4
+++ b/ChangeLog.pre-2-4
@@ -1,3 +1,14 @@
+Wed Jan 13 22:34:29 1999 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkbutton.c gtk/gtkclist.c gtk/gtkhandlebox.c
+ gtk/gtkframe.c gtk/gtk[hv]box.c gtk[hv]paned.c gtk/gtklist.c
+ gtkmenu.c gtkmenuitem.c gtkmenubar.c gtknotebook.c
+ gtk/gtkscrolledwindow.c gtk/gtktable.c gtk/gtktree.c
+ gtk/gtktreeeitem.c gtk/gtkviewport.c
+
+ Fix up comparisons of signed and unsigned ints to avoid
+ assigning negative widths/heigths.
+
Wed Jan 13 21:18:41 1999 Owen Taylor <otaylor@redhat.com>
* acinclude.m4 (ac_result): Unset CATOBJEXT so
diff --git a/ChangeLog.pre-2-6 b/ChangeLog.pre-2-6
index 7e403c19d..59534b261 100644
--- a/ChangeLog.pre-2-6
+++ b/ChangeLog.pre-2-6
@@ -1,3 +1,14 @@
+Wed Jan 13 22:34:29 1999 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkbutton.c gtk/gtkclist.c gtk/gtkhandlebox.c
+ gtk/gtkframe.c gtk/gtk[hv]box.c gtk[hv]paned.c gtk/gtklist.c
+ gtkmenu.c gtkmenuitem.c gtkmenubar.c gtknotebook.c
+ gtk/gtkscrolledwindow.c gtk/gtktable.c gtk/gtktree.c
+ gtk/gtktreeeitem.c gtk/gtkviewport.c
+
+ Fix up comparisons of signed and unsigned ints to avoid
+ assigning negative widths/heigths.
+
Wed Jan 13 21:18:41 1999 Owen Taylor <otaylor@redhat.com>
* acinclude.m4 (ac_result): Unset CATOBJEXT so
diff --git a/ChangeLog.pre-2-8 b/ChangeLog.pre-2-8
index 7e403c19d..59534b261 100644
--- a/ChangeLog.pre-2-8
+++ b/ChangeLog.pre-2-8
@@ -1,3 +1,14 @@
+Wed Jan 13 22:34:29 1999 Owen Taylor <otaylor@redhat.com>
+
+ * gtk/gtkbutton.c gtk/gtkclist.c gtk/gtkhandlebox.c
+ gtk/gtkframe.c gtk/gtk[hv]box.c gtk[hv]paned.c gtk/gtklist.c
+ gtkmenu.c gtkmenuitem.c gtkmenubar.c gtknotebook.c
+ gtk/gtkscrolledwindow.c gtk/gtktable.c gtk/gtktree.c
+ gtk/gtktreeeitem.c gtk/gtkviewport.c
+
+ Fix up comparisons of signed and unsigned ints to avoid
+ assigning negative widths/heigths.
+
Wed Jan 13 21:18:41 1999 Owen Taylor <otaylor@redhat.com>
* acinclude.m4 (ac_result): Unset CATOBJEXT so
diff --git a/gtk/gtkbutton.c b/gtk/gtkbutton.c
index 28e2a57bb..44475d64f 100644
--- a/gtk/gtkbutton.c
+++ b/gtk/gtkbutton.c
@@ -471,9 +471,9 @@ gtk_button_size_allocate (GtkWidget *widget,
child_allocation.x = (CHILD_SPACING + GTK_WIDGET (widget)->style->klass->xthickness);
child_allocation.y = (CHILD_SPACING + GTK_WIDGET (widget)->style->klass->ythickness);
- child_allocation.width = MAX (1, widget->allocation.width - child_allocation.x * 2 -
+ child_allocation.width = MAX (1, (gint)widget->allocation.width - child_allocation.x * 2 -
border_width * 2);
- child_allocation.height = MAX (1, widget->allocation.height - child_allocation.y * 2 -
+ child_allocation.height = MAX (1, (gint)widget->allocation.height - child_allocation.y * 2 -
border_width * 2);
if (GTK_WIDGET_CAN_DEFAULT (button))
@@ -482,10 +482,10 @@ gtk_button_size_allocate (GtkWidget *widget,
DEFAULT_LEFT_POS);
child_allocation.y += (GTK_WIDGET (widget)->style->klass->ythickness +
DEFAULT_TOP_POS);
- child_allocation.width = MAX (1, child_allocation.width -
- (GTK_WIDGET (widget)->style->klass->xthickness * 2 + DEFAULT_SPACING));
- child_allocation.height = MAX (1, child_allocation.height -
- (GTK_WIDGET (widget)->style->klass->xthickness * 2 + DEFAULT_SPACING));
+ child_allocation.width = MAX (1, (gint)child_allocation.width -
+ (gint)(GTK_WIDGET (widget)->style->klass->xthickness * 2 + DEFAULT_SPACING));
+ child_allocation.height = MAX (1, (gint)child_allocation.height -
+ (gint)(GTK_WIDGET (widget)->style->klass->xthickness * 2 + DEFAULT_SPACING));
}
gtk_widget_size_allocate (GTK_BIN (button)->child, &child_allocation);
diff --git a/gtk/gtkclist.c b/gtk/gtkclist.c
index ab6acb6a5..0a0e176d5 100644
--- a/gtk/gtkclist.c
+++ b/gtk/gtkclist.c
@@ -5367,9 +5367,9 @@ gtk_clist_size_allocate (GtkWidget *widget,
* border width */
clist->internal_allocation.x = 0;
clist->internal_allocation.y = 0;
- clist->internal_allocation.width = MAX (1, allocation->width -
+ clist->internal_allocation.width = MAX (1, (gint)allocation->width -
border_width * 2);
- clist->internal_allocation.height = MAX (1, allocation->height -
+ clist->internal_allocation.height = MAX (1, (gint)allocation->height -
border_width * 2);
/* allocate clist window assuming no scrollbars */
@@ -5378,11 +5378,11 @@ gtk_clist_size_allocate (GtkWidget *widget,
clist_allocation.y = (clist->internal_allocation.y +
widget->style->klass->ythickness +
clist->column_title_area.height);
- clist_allocation.width = MAX (1, clist->internal_allocation.width -
- (2 * widget->style->klass->xthickness));
- clist_allocation.height = MAX (1, clist->internal_allocation.height -
- (2 * widget->style->klass->ythickness) -
- clist->column_title_area.height);
+ clist_allocation.width = MAX (1, (gint)clist->internal_allocation.width -
+ (2 * (gint)widget->style->klass->xthickness));
+ clist_allocation.height = MAX (1, (gint)clist->internal_allocation.height -
+ (2 * (gint)widget->style->klass->ythickness) -
+ (gint)clist->column_title_area.height);
clist->clist_window_width = clist_allocation.width;
clist->clist_window_height = clist_allocation.height;
diff --git a/gtk/gtkframe.c b/gtk/gtkframe.c
index 5831382da..789d158de 100644
--- a/gtk/gtkframe.c
+++ b/gtk/gtkframe.c
@@ -497,13 +497,13 @@ gtk_frame_size_allocate (GtkWidget *widget,
{
child_allocation.x = (GTK_CONTAINER (frame)->border_width +
GTK_WIDGET (frame)->style->klass->xthickness);
- child_allocation.width = MAX(0, allocation->width - child_allocation.x * 2);
+ child_allocation.width = MAX(1, (gint)allocation->width - child_allocation.x * 2);
child_allocation.y = (GTK_CONTAINER (frame)->border_width +
MAX (frame->label_height, GTK_WIDGET (frame)->style->klass->ythickness));
- child_allocation.height = MAX (1, (allocation->height - child_allocation.y -
- GTK_CONTAINER (frame)->border_width -
- GTK_WIDGET (frame)->style->klass->ythickness));
+ child_allocation.height = MAX (1, ((gint)allocation->height - child_allocation.y -
+ (gint)GTK_CONTAINER (frame)->border_width -
+ (gint)GTK_WIDGET (frame)->style->klass->ythickness));
child_allocation.x += allocation->x;
child_allocation.y += allocation->y;
diff --git a/gtk/gtkhandlebox.c b/gtk/gtkhandlebox.c
index e39be04d4..de0f01250 100644
--- a/gtk/gtkhandlebox.c
+++ b/gtk/gtkhandlebox.c
@@ -575,8 +575,8 @@ gtk_handle_box_size_allocate (GtkWidget *widget,
}
else
{
- child_allocation.width = MAX (1, widget->allocation.width - 2 * border_width);
- child_allocation.height = MAX (1, widget->allocation.height - 2 * border_width);
+ child_allocation.width = MAX (1, (gint)widget->allocation.width - 2 * border_width);
+ child_allocation.height = MAX (1, (gint)widget->allocation.height - 2 * border_width);
if (hb->handle_position == GTK_POS_LEFT ||
hb->handle_position == GTK_POS_RIGHT)
diff --git a/gtk/gtkhbox.c b/gtk/gtkhbox.c
index 6c3db7484..0c10550b8 100644
--- a/gtk/gtkhbox.c
+++ b/gtk/gtkhbox.c
@@ -200,7 +200,7 @@ gtk_hbox_size_allocate (GtkWidget *widget,
x = allocation->x + GTK_CONTAINER (box)->border_width;
child_allocation.y = allocation->y + GTK_CONTAINER (box)->border_width;
- child_allocation.height = MAX (1, allocation->height - GTK_CONTAINER (box)->border_width * 2);
+ child_allocation.height = MAX (1, (gint)allocation->height - (gint)GTK_CONTAINER (box)->border_width * 2);
children = box->children;
while (children)
@@ -238,7 +238,7 @@ gtk_hbox_size_allocate (GtkWidget *widget,
if (child->fill)
{
- child_allocation.width = MAX (1, child_width - child->padding * 2);
+ child_allocation.width = MAX (1, (gint)child_width - (gint)child->padding * 2);
child_allocation.x = x + child->padding;
}
else
@@ -291,7 +291,7 @@ gtk_hbox_size_allocate (GtkWidget *widget,
if (child->fill)
{
- child_allocation.width = MAX (1, child_width - child->padding * 2);
+ child_allocation.width = MAX (1, (gint)child_width - (gint)child->padding * 2);
child_allocation.x = x + child->padding - child_width;
}
else
diff --git a/gtk/gtkhpaned.c b/gtk/gtkhpaned.c
index 6aabc424e..333ed76ab 100644
--- a/gtk/gtkhpaned.c
+++ b/gtk/gtkhpaned.c
@@ -174,7 +174,7 @@ gtk_hpaned_size_allocate (GtkWidget *widget,
paned->groove_rectangle.height);
}
- child1_allocation.height = child2_allocation.height = MAX (1, allocation->height - border_width * 2);
+ child1_allocation.height = child2_allocation.height = MAX (1, (gint)allocation->height - border_width * 2);
child1_allocation.width = paned->child1_size;
child1_allocation.x = border_width;
child1_allocation.y = child2_allocation.y = border_width;
@@ -186,7 +186,7 @@ gtk_hpaned_size_allocate (GtkWidget *widget,
paned->groove_rectangle.height = allocation->height;
child2_allocation.x = paned->groove_rectangle.x + paned->gutter_size / 2 + 1;
- child2_allocation.width = MAX (1, allocation->width
+ child2_allocation.width = MAX (1, (gint)allocation->width
- child2_allocation.x - border_width);
/* Now allocate the childen, making sure, when resizing not to
diff --git a/gtk/gtklist.c b/gtk/gtklist.c
index 45527aa94..0a2f0c3a7 100644
--- a/gtk/gtklist.c
+++ b/gtk/gtklist.c
@@ -368,7 +368,7 @@ gtk_list_size_allocate (GtkWidget *widget,
{
child_allocation.x = GTK_CONTAINER (list)->border_width;
child_allocation.y = GTK_CONTAINER (list)->border_width;
- child_allocation.width = MAX (1, allocation->width -
+ child_allocation.width = MAX (1, (gint)allocation->width -
child_allocation.x * 2);
children = list->children;
diff --git a/gtk/gtkmenu.c b/gtk/gtkmenu.c
index c603279b5..d3fcb3c71 100644
--- a/gtk/gtkmenu.c
+++ b/gtk/gtkmenu.c
@@ -766,7 +766,7 @@ gtk_menu_size_allocate (GtkWidget *widget,
widget->style->klass->xthickness);
child_allocation.y = (GTK_CONTAINER (menu)->border_width +
widget->style->klass->ythickness);
- child_allocation.width = MAX (1, allocation->width - child_allocation.x * 2);
+ child_allocation.width = MAX (1, (gint)allocation->width - child_allocation.x * 2);
children = menu_shell->children;
while (children)
diff --git a/gtk/gtkmenubar.c b/gtk/gtkmenubar.c
index e79e9ebe1..bf75e395f 100644
--- a/gtk/gtkmenubar.c
+++ b/gtk/gtkmenubar.c
@@ -293,7 +293,7 @@ gtk_menu_bar_size_allocate (GtkWidget *widget,
child_allocation.y = (GTK_CONTAINER (menu_bar)->border_width +
widget->style->klass->ythickness +
BORDER_SPACING);
- child_allocation.height = MAX (1, allocation->height - child_allocation.y * 2);
+ child_allocation.height = MAX (1, (gint)allocation->height - child_allocation.y * 2);
children = menu_shell->children;
while (children)
diff --git a/gtk/gtkmenuitem.c b/gtk/gtkmenuitem.c
index 4b506e015..3241a1a76 100644
--- a/gtk/gtkmenuitem.c
+++ b/gtk/gtkmenuitem.c
@@ -386,8 +386,8 @@ gtk_menu_item_size_allocate (GtkWidget *widget,
BORDER_SPACING);
child_allocation.y = (GTK_CONTAINER (widget)->border_width +
widget->style->klass->ythickness);
- child_allocation.width = MAX (1, allocation->width - child_allocation.x * 2);
- child_allocation.height = MAX (1, allocation->height - child_allocation.y * 2);
+ child_allocation.width = MAX (1, (gint)allocation->width - child_allocation.x * 2);
+ child_allocation.height = MAX (1, (gint)allocation->height - child_allocation.y * 2);
child_allocation.x += GTK_MENU_ITEM (widget)->toggle_size;
child_allocation.width -= GTK_MENU_ITEM (widget)->toggle_size;
if (menu_item->submenu && menu_item->show_submenu_indicator)
diff --git a/gtk/gtknotebook.c b/gtk/gtknotebook.c
index 1432ea976..eea6d90a3 100644
--- a/gtk/gtknotebook.c
+++ b/gtk/gtknotebook.c
@@ -823,17 +823,17 @@ gtk_notebook_size_allocate (GtkWidget *widget,
{
child_allocation.x = GTK_CONTAINER (widget)->border_width;
child_allocation.y = GTK_CONTAINER (widget)->border_width;
- child_allocation.width = MAX (1, allocation->width - child_allocation.x * 2);
- child_allocation.height = MAX (1, allocation->height - child_allocation.y * 2);
+ child_allocation.width = MAX (1, (gint)allocation->width - child_allocation.x * 2);
+ child_allocation.height = MAX (1, (gint)allocation->height - child_allocation.y * 2);
if (notebook->show_tabs || notebook->show_border)
{
child_allocation.x += widget->style->klass->xthickness;
child_allocation.y += widget->style->klass->ythickness;
- child_allocation.width = MAX (1, child_allocation.width -
- widget->style->klass->xthickness * 2);
- child_allocation.height = MAX (1, child_allocation.height -
- widget->style->klass->ythickness * 2);
+ child_allocation.width = MAX (1, (gint)child_allocation.width -
+ (gint) widget->style->klass->xthickness * 2);
+ child_allocation.height = MAX (1, (gint)child_allocation.height -
+ (gint) widget->style->klass->ythickness * 2);
if (notebook->show_tabs && notebook->children && notebook->cur_page)
{
@@ -843,15 +843,15 @@ gtk_notebook_size_allocate (GtkWidget *widget,
child_allocation.y += notebook->cur_page->requisition.height;
case GTK_POS_BOTTOM:
child_allocation.height =
- MAX (1, child_allocation.height -
- notebook->cur_page->requisition.height);
+ MAX (1, (gint)child_allocation.height -
+ (gint)notebook->cur_page->requisition.height);
break;
case GTK_POS_LEFT:
child_allocation.x += notebook->cur_page->requisition.width;
case GTK_POS_RIGHT:
child_allocation.width =
- MAX (1, child_allocation.width -
- notebook->cur_page->requisition.width);
+ MAX (1, (gint)child_allocation.width -
+ (gint)notebook->cur_page->requisition.width);
break;
}
}
diff --git a/gtk/gtkscrolledwindow.c b/gtk/gtkscrolledwindow.c
index 760964c52..d994449a4 100644
--- a/gtk/gtkscrolledwindow.c
+++ b/gtk/gtkscrolledwindow.c
@@ -676,8 +676,8 @@ gtk_scrolled_window_relative_allocation (GtkWidget *widget,
allocation->x = GTK_CONTAINER (widget)->border_width;
allocation->y = GTK_CONTAINER (widget)->border_width;
- allocation->width = MAX (1, widget->allocation.width - allocation->x * 2);
- allocation->height = MAX (1, widget->allocation.height - allocation->y * 2);
+ allocation->width = MAX (1, (gint)widget->allocation.width - allocation->x * 2);
+ allocation->height = MAX (1, (gint)widget->allocation.height - allocation->y * 2);
if (scrolled_window->vscrollbar_visible)
{
@@ -686,9 +686,9 @@ gtk_scrolled_window_relative_allocation (GtkWidget *widget,
allocation->x += (scrolled_window->vscrollbar->requisition.width +
SCROLLBAR_SPACING (scrolled_window));
- allocation->width = MAX (1, allocation->width -
- (scrolled_window->vscrollbar->requisition.width +
- SCROLLBAR_SPACING (scrolled_window)));
+ allocation->width = MAX (1, (gint)allocation->width -
+ ((gint)scrolled_window->vscrollbar->requisition.width +
+ (gint)SCROLLBAR_SPACING (scrolled_window)));
}
if (scrolled_window->hscrollbar_visible)
{
@@ -697,9 +697,9 @@ gtk_scrolled_window_relative_allocation (GtkWidget *widget,
allocation->y += (scrolled_window->hscrollbar->requisition.height +
SCROLLBAR_SPACING (scrolled_window));
- allocation->height = MAX (1, allocation->height -
- (scrolled_window->hscrollbar->requisition.height +
- SCROLLBAR_SPACING (scrolled_window)));
+ allocation->height = MAX (1, (gint)allocation->height -
+ ((gint)scrolled_window->hscrollbar->requisition.height +
+ (gint)SCROLLBAR_SPACING (scrolled_window)));
}
}
diff --git a/gtk/gtktable.c b/gtk/gtktable.c
index d47fe498f..f3e5aca30 100644
--- a/gtk/gtktable.c
+++ b/gtk/gtktable.c
@@ -1348,7 +1348,7 @@ gtk_table_size_allocate_pass1 (GtkTable *table)
if (table->cols[col].shrink)
{
extra = width / nshrink;
- table->cols[col].allocation = MAX (1, table->cols[col].allocation - extra);
+ table->cols[col].allocation = MAX (1, (gint)table->cols[col].allocation - extra);
width -= extra;
nshrink -= 1;
@@ -1426,7 +1426,7 @@ gtk_table_size_allocate_pass1 (GtkTable *table)
if (table->rows[row].shrink)
{
extra = height / nshrink;
- table->rows[row].allocation = MAX (1, table->rows[row].allocation - extra);
+ table->rows[row].allocation = MAX (1, (gint)table->rows[row].allocation - extra);
height -= extra;
nshrink -= 1;
@@ -1487,7 +1487,7 @@ gtk_table_size_allocate_pass2 (GtkTable *table)
if (child->xfill)
{
- allocation.width = MAX (1, max_width - child->xpadding * 2);
+ allocation.width = MAX (1, max_width - (gint)child->xpadding * 2);
allocation.x = x + (max_width - allocation.width) / 2;
}
else
@@ -1498,7 +1498,7 @@ gtk_table_size_allocate_pass2 (GtkTable *table)
if (child->yfill)
{
- allocation.height = MAX (1, max_height - child->ypadding * 2);
+ allocation.height = MAX (1, max_height - (gint)child->ypadding * 2);
allocation.y = y + (max_height - allocation.height) / 2;
}
else
diff --git a/gtk/gtktree.c b/gtk/gtktree.c
index e94c35fdf..058006ecd 100644
--- a/gtk/gtktree.c
+++ b/gtk/gtktree.c
@@ -928,7 +928,7 @@ gtk_tree_size_allocate (GtkWidget *widget,
{
child_allocation.x = GTK_CONTAINER (tree)->border_width;
child_allocation.y = GTK_CONTAINER (tree)->border_width;
- child_allocation.width = MAX (1, allocation->width - child_allocation.x * 2);
+ child_allocation.width = MAX (1, (gint)allocation->width - child_allocation.x * 2);
children = tree->children;
diff --git a/gtk/gtktreeitem.c b/gtk/gtktreeitem.c
index 53bb5e58a..8e99d59a5 100644
--- a/gtk/gtktreeitem.c
+++ b/gtk/gtktreeitem.c
@@ -551,11 +551,11 @@ gtk_tree_item_size_allocate (GtkWidget *widget,
gtk_widget_size_allocate (item->pixmaps_box, &child_allocation);
child_allocation.y = GTK_CONTAINER (widget)->border_width;
- child_allocation.height = MAX (1, allocation->height - child_allocation.y * 2);
+ child_allocation.height = MAX (1, (gint)allocation->height - child_allocation.y * 2);
child_allocation.x += item->pixmaps_box->requisition.width+DEFAULT_DELTA;
child_allocation.width =
- MAX (1, allocation->width - (child_allocation.x + border_width));
+ MAX (1, (gint)allocation->width - ((gint)child_allocation.x + border_width));
gtk_widget_size_allocate (bin->child, &child_allocation);
}
diff --git a/gtk/gtkvbox.c b/gtk/gtkvbox.c
index 486b89706..cd48869cc 100644
--- a/gtk/gtkvbox.c
+++ b/gtk/gtkvbox.c
@@ -200,7 +200,7 @@ gtk_vbox_size_allocate (GtkWidget *widget,
y = allocation->y + GTK_CONTAINER (box)->border_width;
child_allocation.x = allocation->x + GTK_CONTAINER (box)->border_width;
- child_allocation.width = MAX (1, allocation->width - GTK_CONTAINER (box)->border_width * 2);
+ child_allocation.width = MAX (1, (gint)allocation->width - (gint)GTK_CONTAINER (box)->border_width * 2);
children = box->children;
while (children)
@@ -238,7 +238,7 @@ gtk_vbox_size_allocate (GtkWidget *widget,
if (child->fill)
{
- child_allocation.height = MAX (1, child_height - child->padding * 2);
+ child_allocation.height = MAX (1, child_height - (gint)child->padding * 2);
child_allocation.y = y + child->padding;
}
else
@@ -291,7 +291,7 @@ gtk_vbox_size_allocate (GtkWidget *widget,
if (child->fill)
{
- child_allocation.height = MAX (1, child_height - child->padding * 2);
+ child_allocation.height = MAX (1, child_height - (gint)child->padding * 2);
child_allocation.y = y + child->padding - child_height;
}
else
diff --git a/gtk/gtkviewport.c b/gtk/gtkviewport.c
index 0edc3a3b7..86769f1c9 100644
--- a/gtk/gtkviewport.c
+++ b/gtk/gtkviewport.c
@@ -449,8 +449,8 @@ gtk_viewport_realize (GtkWidget *widget)
attributes.y = 0;
}
- attributes.width = MAX (1, widget->allocation.width - attributes.x * 2 - border_width * 2);
- attributes.height = MAX (1, widget->allocation.height - attributes.y * 2 - border_width * 2);
+ attributes.width = MAX (1, (gint)widget->allocation.width - attributes.x * 2 - border_width * 2);
+ attributes.height = MAX (1, (gint)widget->allocation.height - attributes.y * 2 - border_width * 2);
attributes.event_mask = 0;
viewport->view_window = gdk_window_new (widget->window, &attributes, attributes_mask);
diff --git a/gtk/gtkvpaned.c b/gtk/gtkvpaned.c
index ecbe7ca34..ff5f25f0a 100644
--- a/gtk/gtkvpaned.c
+++ b/gtk/gtkvpaned.c
@@ -174,7 +174,7 @@ gtk_vpaned_size_allocate (GtkWidget *widget,
paned->groove_rectangle.height);
}
- child1_allocation.width = child2_allocation.width = MAX (1, allocation->width - border_width * 2);
+ child1_allocation.width = child2_allocation.width = MAX (1, (gint)allocation->width - border_width * 2);
child1_allocation.height = paned->child1_size;
child1_allocation.x = child2_allocation.x = border_width;
child1_allocation.y = border_width;
@@ -186,7 +186,7 @@ gtk_vpaned_size_allocate (GtkWidget *widget,
paned->groove_rectangle.width = allocation->width;
child2_allocation.y = paned->groove_rectangle.y + paned->gutter_size / 2 + 1;
- child2_allocation.height = MAX (1, allocation->height
+ child2_allocation.height = MAX (1, (gint)allocation->height
- child2_allocation.y - border_width);
/* Now allocate the childen, making sure, when resizing not to