Gsettings change budgie panel question

I am creating a post-install bash script to run right after I have installed UB Budgie on any pc. The script contains mostly gsettings set commands and pulls another script to install the Office fonts.

To find the right gsettings, I do the following, for example:

Goal
Move top-panel to left side and set size to 53 (treshold for bigger app icons)

How to figure this out?
Check what settings are modified in the dconf database, then find the right scheme/key/value in gsettings.

~$ dconf watch /
.com.solus-project.budgie-panel.panels.{646c1a06-70da-11ea-b086-ffb616e1ec64}.size
  53

.com.solus-project.budgie-panel.panels.{646c1a06-70da-11ea-b086-ffb616e1ec64}.location
  'left'

.com.solus-project.budgie-panel.panels.{646c1a06-70da-11ea-b086-ffb616e1ec64}.size
  53

Now I can use that information to check what the exact gsettings set command should look like:

~$ gsettings list-recursively com.solus-project.budgie-panel
(...)
com.solus-project.budgie-panel panels ['646c1a06-70da-11ea-b086-ffb616e1ec64']
(...)

For this particular case I have a question:

Is there a uniquely generated string for each panel?
If so, how can I reach my goal via a CLI command that should work on any PC?

yes

This example python code iterates through each panel and sets the key in each panel - for example “size”

The easiest way to customise your panel is to use a layout file - look at https://github.com/UbuntuBudgie/budgie-extras/tree/master/budgie-extras-daemon/data for examples

Save your .layout file in /usr/share/budgie-desktop/layouts

To apply - set the layout name (layout filename without the .layout extension) in gsettings key “layout” com.solus-project.budgie-panel and then reset your panel

hi,
how can I get current layout from a running panel? If I dump /com/solus-project/budgie-panel/ I get the same thing I’m using in my customization script, just there isn’t any reference to a layout

Sil

You can’t get a “layout text file” from the current panel - well not easily without some-sort of in-depth bash scraping and fiddling.

easier dumping the whole panel and loading it in freshly installed machines via script, then!
I don’t fear scripting but if I can do something with a not-so-great effort, why trying to doing it with a horrible effort? :smile:

Sil

Given that all eventually needed applets are already installed on the destination system, this is what I had tried here : Export Budgie Desktop settings to another session?

So you « dump » these from a working system and « load » them on the one to configure.

dconf dump /com/solus-project/ > /your_path/of_choice_to/dconf-dump-solus-project
dconf dump /org/ubuntubudgie/ > /your_path/of_choice_to/dconf-dump-ubuntubudgie

What’s missing here :
⋅ themes, icons, fonts ( but these don’t need so much time to set as panels and applets )
⋅ maybe sometimes some applets config’ are not passed ( things like custom string format for time in calendar, or the font size in show-time )

Well I made my layout file, it wasn’t that difficult only issue: some applets seem to have completely different names!

For example, Workspace Switcher is called Visual Space in the examples on Github.

Mine can be found here, I haven’t tested it yet (afraid to mess up my current panel, although it should be 1:1 identical). Unsure also if Seperators should be numbered just like Spacers.

The ID= field is the name of the applet - look at the .plugin file in /usr/lib/budgie-desktop/applets and the .plugin files in the subfolders.

The […] field is the name in the children= part - so it can be anything e.g.
"children=flintstone

[flintstone]

"

So the string is whatever you want e.g. “separator 1” so that you can easily understand what that part refers to.

1 Like