I've written a small app that creates a GUI for setting up uShare. Currently it depends heavily on the 'w' (write) and 'a' (append) functions to generate/edit ushare.conf file. But I've been trying to find a way for the app to store all the changes until a save button is pressed, and only then committing them to the actual file. I think that would be the best way of getting around having the user press enter every time they change any field (and indeed allow for GtkCheckButton).
If you want to store configuration like this, what I recommend you do is to use the Python
ConfigParser
module. Please note you should ensure you store config files in~/.config/<your-app-name>
. You can store config like this:Please note: I didn't actually run this code and just wrote it here, but it should work fine.