Re: Center align labels in container using label top as reference

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 03 Jan 2010 16:44:37 -0500
Vikram Noel Ambrose <noel.ambrose@xxxxxxxxx> wrote:
> Chris Vine wrote:
> > On Sat, 02 Jan 2010 21:22:40 -0500
> > Vikram Noel Ambrose <noel.ambrose@xxxxxxxxx> wrote:
> >   
> >> I have two labels in a horizontal box. left_label and right_label.
> >> I'd like the first line of text in each label to be vertically
> >> aligned with each other always. But at the same time I'd like both
> >> labels to be in the center (vertical) of the box they have been
> >> placed in.
> >>
> >> In other words, I'm looking for a gtk_misc_set_alignment that will
> >> allow me to pass a 3rd and 4th option - the child's reference
> >> coordinates.
> >>
> >> Does anyone know how to align the labels like that?
> >>     
> >
> > If you pack with expand as TRUE but filling as FALSE, I think that
> > is supposed to do what you want.
> >
> 
> You mean when the labels are packed into the button's horizontal box?
> If I do that the button itself doesn't even show up.

No, I misunderstood what you meant by having labels which are "in the
center (vertical) of the box they have been placed in".  You would have
to use a GtkAlignment object, which I see you have code for now.

Chris


_______________________________________________
gtk-list mailing list
gtk-list@xxxxxxxxx
http://mail.gnome.org/mailman/listinfo/gtk-list

[Index of Archives]     [Touch Screen Library]     [GIMP Users]     [Gnome]     [KDE]     [Yosemite News]     [Steve's Art]

  Powered by Linux