gio settings schema

Hi All,

I'm writing a plugin in python for Rhythmbox. I want to use GSettings to record the state of the plugin.

I feel like I should be able to do something like:

  if source.lookup("org.gnome.rhythmbox.plugins.gutenberg", True):
    print ("got settings.")
    print("seems like settings are missing. Creating new ones.")
    self.settings ="org.gnome.rhythmbox.plugins.gutenberg")

... but I can't - and it seems [1] I need to create a schema manually, as root, by copying a file into /usr/share/glib-2.0/schemas/

This feels weird to me: I can install my plug-in as a user, but I can't create a GSetting (that I think my plugin should be using for good hygiene). I imagine I've missed something - and I'd appreciate guidance back to the path.

best regards,
1. Using GSettings with Python/PyGObject

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]