Python GTK+ widget name

How do I get a widget’s “name”? When I define a GUI using Glade, I can “name” the widgets of the window but how do I recover that property when I have a widget object instance? I’ve tried get_property(), get_name() and $widget.name to no avail. Update: I am using GtkBuilder file format (i.e. XML format). … Read more

How to parse a directory tree in python?

I have a directory called “notes” within the notes I have categories which are named “science”, “maths” … within those folder are sub-categories, such as “Quantum Mechanics”, “Linear Algebra”. ./notes –> ./notes/maths ——> ./notes/maths/linear_algebra –> ./notes/physics/ ——> ./notes/physics/quantum_mechanics My problem is that I don’t know how to put the categories and subcategories into TWO SEPARATE … Read more