diff options
author | Gnome CVS User <gnomecvs@src.gnome.org> | 1997-11-25 07:15:41 +0000 |
---|---|---|
committer | Gnome CVS User <gnomecvs@src.gnome.org> | 1997-11-25 07:15:41 +0000 |
commit | 33b94315803c6a7c9fe3826f0d4b11a26392137a (patch) | |
tree | 48c12426b37871cf7863595503e27f0f3472e8d3 /gtk/gtkaspectframe.c | |
parent | c82e82dafc507469f48547702841f0946a888104 (diff) | |
download | gtk+-33b94315803c6a7c9fe3826f0d4b11a26392137a.tar.gz |
Mon Nov 24 1997 Jay Painter <jpaint@serv.net>
gtk-dairiki-971117-2.patch
gtk/gtkaspectframe.c (gtk_aspect_frame_size_allocate): When
computing new dimensions of the subwidget, round to nearest
integer rather than truncating.
Mon Nov 24 1997 Jay Painter <jpaint@serv.net>
gtk-dairiki-971117-1.patch
* gtk/gtkvruler.c (gtk_vruler_draw_ticks):
* gtk/gtkhruler.c (gtk_hruler_draw_ticks): Ensure that subticks
always are drawn when they should be (sometimes they were getting
drawn with zero length --- invisible). Also clear rectangle
behind text labels to ensure they don't touch or overlap ticks.
Mon Nov 24 1997 Jay Painter <jpaint@serv.net>
* gtk/gtkaspectframe.c (gtk_aspect_frame_set):
gtk-dairiki-971117-0.patch
Clear window when aspect ratio or alignment is changed.
Diffstat (limited to 'gtk/gtkaspectframe.c')
-rw-r--r-- | gtk/gtkaspectframe.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/gtk/gtkaspectframe.c b/gtk/gtkaspectframe.c index 2e6594fea8..16feba5f02 100644 --- a/gtk/gtkaspectframe.c +++ b/gtk/gtkaspectframe.c @@ -319,14 +319,14 @@ gtk_aspect_frame_size_allocate (GtkWidget *widget, GTK_CONTAINER (frame)->border_width - GTK_WIDGET (frame)->style->klass->ythickness); - if (ratio * height > width) + if (height > width / ratio) { child_allocation.width = width; - child_allocation.height = width/ratio; + child_allocation.height = width/ratio + 0.5; } - else + else if (width > height * ratio) { - child_allocation.width = ratio*height; + child_allocation.width = ratio * height + 0.5; child_allocation.height = height; } |