Re: Label justification in table cell



On Thu, Jun 03, 2004 at 03:54:10AM +1000, Russell Shaw wrote:
When i put GtkLabels into GtkTable cells, they get centered.
How do i get them left justified? I tried:

You probably mean left aligned?

  gtk_misc_set_alignment(GTK_MISC(label),0,0.5);
  gtk_table_attach(GTK_TABLE(tab),label,0,1,0,1,GTK_SHRINK,GTK_SHRINK,0,0);

Just let them fill the cell

  gtk_table_attach(GTK_TABLE(tab),label,0,1,0,1,
                   GTK_SHRINK|GTK_EXPAND|GTK_FILL,GTK_SHRINK,0,0);

Yeti


--
Do not use tab characters. Their effect is not predictable.



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