Commit Graph

14 Commits

Author SHA1 Message Date
Tor Hedin Brønner
adcfa414ad preference: add use-workspace-name switch
Defaults to true. If false uses gnome shell's `Activities` text and hides the
workspace labels.

Set to false like this:
```
Extension.imports.convenience.getSettings()
  .set_boolean('use-workspace-name', false)
```
2019-02-15 00:15:54 +01:00
Tor Hedin Brønner
c4163c4caf settings: handle state generically 2019-02-14 19:25:35 +01:00
Ole Jørgen Brønner
7aee0d901c Redirect extension prefs windows to scratch layer (winprop)
X11: A regular intermediate window is created before the actual prefs dialog.
This cause trouble - it's inserted shortly into the tiling.
Wayland: The prefs dialog is opened as a regular window

We'd like the prefs dialog (at least our own) to float.
2019-01-26 21:05:05 +01:00
Ole Jørgen Brønner
e268e9ac11 Move winprop related code to settings.js
(leave a shim for backward compatibility)
2019-01-26 21:04:50 +01:00
Ole Jørgen Brønner
e0c9071ee4 Update vertical margin on 'window-gap' change 2019-01-06 16:32:41 +01:00
Tor Hedin Brønner
529102add1 Add animation-time setting 2018-12-17 22:21:57 +01:00
Tor Hedin Brønner
b295e9d00d Add default-background preference
Not exposed in the preference ui yet.

Can be set with dconf or in `user.js` like this:

var settings = Extension.imports.convenience.getSettings();
settings.set_string('default-background', '/path/to/image.jpg');

ref #83
2018-10-19 11:16:36 +02:00
Tor Hedin Brønner
9132979916 Add tooltip describing conflicts
Also add a reset toggle.
2018-07-15 20:35:04 +02:00
Tor Hedin Brønner
b12bc2bb52 Add key conflict machinery to settings.js
This is the common functions needed for both the extension side and prefence UI
side, so it goes in `settings.js`.

`Settings.findConflicts` searches for keycombo conflicts between our own
bindings and the built in Gnome Shell and mutter bindings, returning an array
like this:
```
[{ name: our own action name,
   conflicts: array of conflicting names
   settings: the settings schema the conflicting are part of
   combo: the key combo as generated by keystrToKeycombo},
 ...]
```

keystrToKeycombo now handles `Above_Tab` properly.
2018-07-13 11:40:03 +02:00
Tor Hedin Brønner
d41d6b9033 Fix duplicate workspace settings
Simplyfy things by storing all workspace settings from the get go.
2018-07-11 18:47:56 +02:00
Tor Hedin Brønner
55c6b60803 Add settings UI with workspace controls and gap and margin spinners
`Settings.ui` is built with and can be inpsected with Glade.
2018-07-11 18:47:56 +02:00
Tor Hedin Brønner
c723fa2a4d Use new workspace settings schema
Per workspace settings can be accessed through `space.settings`.

A setting's path is stored under its uuid in
`/org/gnome/shell/extensions/paperwm/workspaces/${uuid}/`. When modifying a
workspace setting the uuid will be recorded in
`org.gnome.Shell.Extensions.PaperWM.WorkspaceList`.

Spaces get their settings by looking for an uuid with an `index` key
corrosponding to its `workspace.index()`. If such a setting can't be found the
space will be given a fresh uuid and the name and color will be assigned as
before.
2018-07-08 12:09:47 +02:00
Tor Hedin Brønner
18b116c2c1 Don't let the selection highlight protrude into the top bar 2018-07-03 18:05:45 +02:00
Tor Hedin Brønner
3548f219a2 Rename prefs.js to settings.js
prefs.js causes issues as its used to lauch the settings gui from eg. tweaks.
2018-07-02 22:31:55 +02:00