roundabout,
created on Friday, 15 August 2025, 17:08:21 (1755277701),
received on Friday, 15 August 2025, 17:08:24 (1755277704)
Author identity: Vlad <vlad.muntoiu@gmail.com>
a1a7fdb0bc82d31540c5caa14424a2bdab597cf6
docs/applet-api/implementing-applets.md
@@ -11,6 +11,8 @@ imports this way. Your subclass can set the class attributes `name` and
Try to make your class name reasonably unique, because the panel identifies applets by their `__name__` and doesn't support multiple classes sharing one. Including your name or an organisation's name in the class name is one way to do this.Managing configuration ----------------------
@@ -20,6 +22,9 @@ third parameter. You also have to implement the `get_config(self)` method to
return the configuration when asked to, that is, when the panel is saving its settings. This will be serialised to a YAML file. When you want to write the configuration, emit the signal `config-changed` and the panel will save it to the file. Using other sources of configuration for your applet is not recommended because there may be multiple applet instances.
@@ -65,6 +70,8 @@ You can also override extra methods to get notified about other events:
* `make_draggable(self)`: if you have dangerous controllers, you can disable them when edit mode is enabled. * `restore_drag(self)`: restore the state when edit mode is disabled. * `shutdown(self)`: when the panel is shutting down; use if you want to disconnect from services or similar.Of course, you can override any other `Gtk.Box` methods as well.