Thanks for tip Dieter, but I have tried gtk.Widget.get_name(widget)
function, returns eg GtKEntry for a TextEntry field and GtkLabel for a
label, ie the same as I get when using widget.get_name(). Code:
print j.get_name()
print gtk.Widget.get_name(j)
Both returns GtkEntry when run on a TextEntry.
I am after the name of the TextEntry as given in Glade, such as enTime
or enDate.
Any ideas?
Regards
Olaf Devik
e-mail: olaf.de...@mollefaret.no
mobile: +47 911 70 849
Den 2011-09-27 18:14, skrev Dieter Verfaillie:
On Tue, 27 Sep 2011 17:12:39 +0200, Olaf Devik wrote:
I have a number of textEntries used to hold setup values. Each of the
textentries has distinctive names in Glade (Glade 3.6).
I would like to retrieve the name of the textEntry and the content.
The latter is easy, but I fail to find a property of the textEntry
which holds the name given to it in the Glade editor.
The name combined with the contents is planned to be used to
construct a list to be saved in a setup file.
You can get at the name of any widget (provided either libglade
or gtkbuilder does the right thing) by:
gtk.Widget.get_name(widget)
mvg,
Dieter
_______________________________________________
pygtk mailing list pygtk@daa.com.au
http://www.daa.com.au/mailman/listinfo/pygtk
Read the PyGTK FAQ: http://faq.pygtk.org/