GNOME Bugzilla – Bug 734894
Support GObject property access as direct Python object attributes
Last modified: 2018-01-10 20:44:22 UTC
The request for accessing GObject properties directly has come up a few times. Furthermore, both vala and gjs support direct property accessors as follows: button = Gtk.Button() button.label vs. button.props.label Implementing this should be trivial in the sense that we just need to implement __getattr__ and __setattr__ which could be done purely in Python and return the results of get/set_property() with TypeError exceptions translated to AttributeErrors.
-- GitLab Migration Automatic Message -- This bug has been migrated to GNOME's GitLab instance and has been closed from further activity. You can subscribe and participate further through the new bug through this link to our GitLab instance: https://gitlab.gnome.org/GNOME/pygobject/issues/77.