mirror of
https://gitlab.gnome.org/GNOME/gtk.git
synced 2024-11-07 01:00:28 +00:00
Patch from Soeren Sandmann to improve GtkLabel behavior when it gets a too
Mon Aug 5 17:20:45 2002 Owen Taylor <otaylor@redhat.com> * gtk/gtklabel.c: Patch from Soeren Sandmann to improve GtkLabel behavior when it gets a too small allocation. (Always display the initial portion.) (#71742)
This commit is contained in:
parent
e1826de7e7
commit
9eb97b045c
@ -1,3 +1,10 @@
|
||||
Mon Aug 5 17:20:45 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtklabel.c: Patch from Soeren Sandmann
|
||||
to improve GtkLabel behavior when it gets
|
||||
a too small allocation. (Always display the
|
||||
initial portion.) (#71742)
|
||||
|
||||
Mon Aug 5 17:01:30 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gdk/Makefile.am (LDFLAGS): When overriding LDFLAGS,
|
||||
|
@ -1,3 +1,10 @@
|
||||
Mon Aug 5 17:20:45 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtklabel.c: Patch from Soeren Sandmann
|
||||
to improve GtkLabel behavior when it gets
|
||||
a too small allocation. (Always display the
|
||||
initial portion.) (#71742)
|
||||
|
||||
Mon Aug 5 17:01:30 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gdk/Makefile.am (LDFLAGS): When overriding LDFLAGS,
|
||||
|
@ -1,3 +1,10 @@
|
||||
Mon Aug 5 17:20:45 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtklabel.c: Patch from Soeren Sandmann
|
||||
to improve GtkLabel behavior when it gets
|
||||
a too small allocation. (Always display the
|
||||
initial portion.) (#71742)
|
||||
|
||||
Mon Aug 5 17:01:30 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gdk/Makefile.am (LDFLAGS): When overriding LDFLAGS,
|
||||
|
@ -1,3 +1,10 @@
|
||||
Mon Aug 5 17:20:45 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtklabel.c: Patch from Soeren Sandmann
|
||||
to improve GtkLabel behavior when it gets
|
||||
a too small allocation. (Always display the
|
||||
initial portion.) (#71742)
|
||||
|
||||
Mon Aug 5 17:01:30 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gdk/Makefile.am (LDFLAGS): When overriding LDFLAGS,
|
||||
|
@ -1,3 +1,10 @@
|
||||
Mon Aug 5 17:20:45 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtklabel.c: Patch from Soeren Sandmann
|
||||
to improve GtkLabel behavior when it gets
|
||||
a too small allocation. (Always display the
|
||||
initial portion.) (#71742)
|
||||
|
||||
Mon Aug 5 17:01:30 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gdk/Makefile.am (LDFLAGS): When overriding LDFLAGS,
|
||||
|
@ -1,3 +1,10 @@
|
||||
Mon Aug 5 17:20:45 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gtk/gtklabel.c: Patch from Soeren Sandmann
|
||||
to improve GtkLabel behavior when it gets
|
||||
a too small allocation. (Always display the
|
||||
initial portion.) (#71742)
|
||||
|
||||
Mon Aug 5 17:01:30 2002 Owen Taylor <otaylor@redhat.com>
|
||||
|
||||
* gdk/Makefile.am (LDFLAGS): When overriding LDFLAGS,
|
||||
|
@ -1648,15 +1648,21 @@ get_layout_location (GtkLabel *label,
|
||||
xalign = misc->xalign;
|
||||
else
|
||||
xalign = 1.0 - misc->xalign;
|
||||
|
||||
x = floor (widget->allocation.x + (gint)misc->xpad
|
||||
+ ((widget->allocation.width - widget->requisition.width) * xalign)
|
||||
+ 0.5);
|
||||
|
||||
|
||||
x = floor (widget->allocation.x + (gint)misc->xpad +
|
||||
xalign * (widget->allocation.width - widget->requisition.width)
|
||||
+ 0.5);
|
||||
|
||||
if (gtk_widget_get_direction (widget) == GTK_TEXT_DIR_LTR)
|
||||
x = MAX (x, widget->allocation.x + misc->xpad);
|
||||
else
|
||||
x = MIN (x,
|
||||
widget->allocation.x + widget->allocation.width -
|
||||
widget->requisition.width - misc->xpad);
|
||||
|
||||
y = floor (widget->allocation.y + (gint)misc->ypad
|
||||
+ ((widget->allocation.height - widget->requisition.height) * misc->yalign)
|
||||
+ 0.5);
|
||||
|
||||
+ MAX (((widget->allocation.height - widget->requisition.height) * misc->yalign)
|
||||
+ 0.5, 0));
|
||||
|
||||
if (xp)
|
||||
*xp = x;
|
||||
|
Loading…
Reference in New Issue
Block a user