Reputation: 3402
I use the classical code example :
from gi.repository import Gtk
class Handler():
def onDeleteWindow(self, *args):
Gtk.main_quit(*args)
def on_button1_clicked(self, button):
print("Hello World!")
builder = Gtk.Builder()
builder.add_from_file("D:/temp/test1.glade")
builder.connect_signals(Handler())
window = builder.get_object("window1")
window.show_all()
Gtk.main()
And all is OK. But :
Upvotes: 0
Views: 1957
Reputation: 2302
Where/how to have all the Python/Gtk informations about widgets, like widgets properties names?
https://lazka.github.io/pgi-docs/#Gtk-3.0
How to change a widget property in event. Like change the button1 label on click on it.
button.set_label()
https://lazka.github.io/pgi-docs/#Gtk-3.0/classes/Button.html#Gtk.Button.set_label
Upvotes: 2