user361697
user361697

Reputation: 1131

GTK Widget object naming

I am writting a PyGTK application. I am using the glade interface designer for layouts.

I want to know if there is any standard way of naming a Widget object.

eg : For a button called "Configure" how should I name it ? eg : ConfigureBt, ButtonConfigure, ConfigureButton, etc

I want the app to be accepted in the default ubuntu/debian/gnome setup. I want to follow all the standards requirements for it.

Upvotes: 1

Views: 253

Answers (1)

detly
detly

Reputation: 30332

There's no "official" standard, but you'll save yourself headaches if you use lowercase, underscore separated names (eg. refresh_button). That way, signal handlers can be called eg. refresh_button_clicked, and Glade can automatically connect to them. Then it will match up nicely with Python coding standards.

Upvotes: 1

Related Questions