Differences
This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revisionNext revisionBoth sides next revision |
dev:howto:panel_plugins [2017/04/18 03:40] – Update some links and add hint to load plugins during development. andreldm | dev:howto:panel_plugins [2017/10/17 22:50] – Fix links in introduction andreashae |
---|
Starting from version 4.4 the Xfce Panel support two types of plugins: internal and external. | Starting from version 4.4 the Xfce Panel support two types of plugins: internal and external. |
The internal plugins are loadable modules, using the | The internal plugins are loadable modules, using the |
[[http://developer.gnome.org/doc/API/2.0/glib/glib-Dynamic-Loading-of-Modules.html|GModule]] | [[https://developer.gnome.org/glib/stable/glib-Dynamic-Loading-of-Modules.html|GModule]] |
interface. External plugins are separate programs that are embedded into the panel using the | interface. External plugins are separate programs that are embedded into the panel using the |
[[http://developer.gnome.org/doc/API/2.0/gtk/GtkPlug.html|GtkPlug]] and | [[https://developer.gnome.org/gtk3/stable/GtkPlug.html|GtkPlug]] and |
[[http://developer.gnome.org/doc/API/2.0/gtk/GtkSocket.html|GtkSocket]] mechanism. | [[https://developer.gnome.org/gtk3/stable/GtkSocket.html|GtkSocket]] mechanism. |
| |
In order to handle these plugins the plugin system was entirely rewritten, along with the rest | In order to handle these plugins the plugin system was entirely rewritten, along with the rest |
To help development, you can also test plugins without installing them on panel's prefix (e.g. /usr), you can also directly run plugins from the source so you don't need to to overwrite a plugin version from your distribution. To accomplish this, build the plugin with make and then follow these steps: | To help development, you can also test plugins without installing them on panel's prefix (e.g. /usr), you can also directly run plugins from the source so you don't need to to overwrite a plugin version from your distribution. To accomplish this, build the plugin with make and then follow these steps: |
| |
* Create a symbolic link from your plugin binary to the panel's prefix installation, e.g. ''ln -s /home/johndoe/where/your/src/is/panel-plugin/.libs/libyourplugin.so /usr/lib/xfce4/panel/plugins/libyourplugin-git.so'' | * Create a symbolic link from your plugin binary to the panel's prefix installation, e.g. ''ln -s /home/johndoe/where/your/src/is/panel-plugin/.libs/libyourplugin.so /usr/lib/xfce4/panel-plugins/libyourplugin-git.so'' |
* Copy ''/usr/share/xfce4/panel/plugins/yourplugin.desktop'' to ''/usr/share/xfce4/panel/plugins/yourplugin-git.desktop'' | * Copy ''/usr/share/xfce4/panel/plugins/yourplugin.desktop'' to ''/usr/share/xfce4/panel/plugins/yourplugin-git.desktop'' |
* Edit the latter to point at 'yourplugin-git' instead of 'yourplugin', modify the 'Name' entry to distinguish your instance. | * Edit the latter to point at 'yourplugin-git' instead of 'yourplugin', modify the ''Name'' entry to distinguish your instance and ''X-XFCE-Module'' to match the symbolic link, i.e. ''libyourplugin-git''. |
* If you're porting a plugin to GTK+ 3, make sure to add ''X-XFCE-API=2.0'' to the desktop-git file. | * If you're porting a plugin to GTK+ 3, make sure to add ''X-XFCE-API=2.0'' to the desktop-git file. |
| |