RE: question for packing
- From: "Tom Liu" <tom liu flextrade com>
- To: "'Olexiy Avramchenko'" <olexiy irtech cn ua>
- Cc: <gtk-app-devel-list gnome org>
- Subject: RE: question for packing
- Date: Mon, 27 Oct 2003 09:15:15 -0500
Thanks Olexiy,
But gtk_misc_set_alignment(GTK_MISC(w_lab), 0.0, 0.5) solve the problem
of the label, but the entry still can't pack at the left of right area.
-----Original Message-----
From: gtk-app-devel-list-admin gnome org
[mailto:gtk-app-devel-list-admin gnome org] On Behalf Of Olexiy
Avramchenko
Sent: Saturday, October 25, 2003 5:38 AM
To: Tom Liu
Cc: gtk-app-devel-list gnome org
Subject: Re: question for packing
Tom Liu wrote:
Hi,
When I using GtkHBox to packing, I set the homogeneous to true,
I want to pack a label and an entry. Label should be right aligment,
entry should be left aligment, how can I do this?
------------------------------------------------
| ------------ -------------- |
| |the label | | the entry | |
| ------------ -------------- |
------------------------------------------------
^
center
I know this should be easy, but I can't do this.
This is my code:
m_w=gtk_hbox_new(TRUE,3);
w_lab=gtk_label_new(label_string);
gtk_box_pack_start(GTK_BOX(m_w),w_lab,FALSE,TRUE,0);
gtk_label_set_justify(GTK_LABEL(w_lab),GTK_JUSTIFY_RIGHT);
w_edit=gtk_entry_new ();
gtk_box_pack_start(GTK_BOX(m_w),w_edit,TRUE,TRUE,0);
the justify doesn't work at all!.
Use:
gtk_misc_set_alignment(GTK_MISC(w_lab), 0.0, 0.5);
Olexiy
_______________________________________________
gtk-app-devel-list mailing list
gtk-app-devel-list gnome org
http://mail.gnome.org/mailman/listinfo/gtk-app-devel-list
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]