-
Notifications
You must be signed in to change notification settings - Fork 1
/
dg.conf
executable file
·1114 lines (930 loc) · 42.7 KB
/
dg.conf
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
594
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
--------------------------------------------------------------------------------------------------------------
- INTRODUCTION -----------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------
- This is a reference configuration file for the DG library which details all the available options, which
- range from GUI behavior, styling, and input (keys and pointer buttons) bindings.
-
- The configuration file should be located in one of the following default locations, sorted by
- priority, from first to last :
- ~/.config/dg.conf
- /usr/share/dg/dg.conf
- /etc/dg.conf
-
- If the environment variable "DG_CORE_RESOURCE_FILE" is set, the file it points to will be parsed instead, if
- that path is invalid, default locations will be then checked.
-
- If the environment variable is not set and a configuration file at the default paths does not exist, or if
- some resources are not specified in the selected configuration file, hard coded built-in values will be used
- instead for all missing resources. The values given to resources in this reference configuration file
- reflect said hard coded values.
--------------------------------------------------------------------------------------------------------------
- SYNTAX -----------------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------
- The DG configuration syntax follows a few simple rules.
- In the syntax definitions, <whitespaces> (space and tab characters) are ignored.
- All definitions are read linearly from top to bottom, if there are duplicate defintions with different
- values, the latest definitions will overwrite the previous ones.
--------------------------------------------------------------------------------------------------------------
- Rows starting with special characters hold special functions.
-
- Comments :
- <whitespace> - string
-
- Child file inclusions, with protection against circular inclusions :
- <whitespace> @ <whitespace> path <whitespace>
-
- Variables definitions, they are stored as a raw strings until they are used in a resource definition :
- <whitespace> $ <whitespace> variable_name <whitespace> = <whitespace> string <whitespace>
-
- Section inclusion, sections not included with these lines will not be parsed, useful to create groups of
- resources that can be easily added or removed from the active configuration :
- <whitespace> + <whitespace> section_name <whitespace>
-
- Sections start, a section ends when a new one starts.
- <whitespace> [ <whitespace> section_name <whitespace>
- If the name is left empty, then the following resources will be part of the "default" group and will
- always be processed, just like resources defined before any section start.
-
- Examples :
- comment
- @../.local/shared/file
- @ ../.local/shared/file
- @ ../.local/shared/file
- $ var = val
- $ var = val
- $var=val
- +SECTION
- + SECTION
- [SECTION
- [ SECTION
--------------------------------------------------------------------------------------------------------------
- Other rows are considered to be resources definitions, and have their own syntax rules :
- <whitespace> namespace.property <whitespace> = <whitespace> value <whitespace>
-
- Namespaces, as the name implies, help avoid collisions with property names coming from different sources.
- Generally, each DG module or DG application (that requires custom resources) will have their own namespaces
- There are currently 4 of them between the Core and Base modules :
- core
- key
- button
- base
-
- The property field is the actual name of a given resource within its namespace. While not a requirement,
- properties follow the snake_case convention.
-
- Finally, for each resource, a value has to be assigned. A value's syntax depends on its type, which itself
- depends on the property. There are 9 types, and for each type, there is a specific sub-syntax.
-
- STRING
- Some text, written as is. Some properties only accept a few specific case-sensitive strings and for each
- case, all available options will be listed. In some other cases, like for "core.font_face" it expects an
- arbitrary name of something. Double quotes are not necessary, but they can be useful if the supplied string
- has leading or trailing whitespaces that need to be conserved.
-
- INT
- Integer numeral value, matches C's int type and bounds.
-
- UINT
- Unsigned integer numeral value, matches C's int type and bounds.
-
- INT16
- 16-bit integer numeral value, its value is bound between -32767 and 32767.
- Usually used for anything related to positioning.
-
- UINT16
- 16-bit unsigned integer numeral value, its value is bound between 0 and 65535.
- Usually used for anything related to a length or size.
-
- DOUBLE
- Double floating point numeral value, matches C's double type and bounds.
-
- UDOUBLE
- Unsigned double floating point numeral value, matches C's double type and upper bounds but its minimal
- value is 0.0.
-
- COLOR
- Hexadecimal RGBA color representation. the leading "#" and alpha bytes are optional. If alpha values are
- omitted, full opacity "ff" is assumed. It is not case sensitive.
- All these four values definitions are valid :
- #123abc88
- #123ABC
- 123abc88
- 123abc
-
- BOOL
- Boolean value, has to be written explicitly "true" or "false" without double quotes.
--------------------------------------------------------------------------------------------------------------
- Lastyl, for numeral (INT, UINT, INT16, UINT16, DOUBLE, UDOUBLE) and COLOR values, an optional syntaxt that
- enables value interpolation is available :
- <whitespace> ~ <whitespace> value_1 <whitespace> : <whitespace> value_2 <whitespace> : ratio <whitespace>
-
- This subsyntax helps making color mixes or from a few base colors. Same for numeral values.
- "value_1", "value_2" and "ratio" can all be variables too. "ratio" will always be interpreted as a decimal
- value bound between 0.0 and 1.0. "value_1" and "value_2" interpretation depends on the value type the
- property expects.
-
- Examples :
- namespace.property = ~1:3:0.5
- namespace.property = ~aaaaaa:#10101010:0.6
- namespace.property = ~$var : #45454545 : 0.1
- namespace.property = ~ $var1 : $var2 : 1
- namespace.property = ~ $var1 : $var2 : $var3
--------------------------------------------------------------------------------------------------------------
- FULL EXAMPLE -----------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------
- $color_background = #121212
- $thickness = 4
-
- @themes/amber.conf
- @themes/retro.conf
-
- +COLORS
-
- [COLORS
- namespace_1.property_A = #232323
- namespace_1.property_B = 34ffFFA0
- namespace_2.property_A = $color_background
- +INPUTS
-
- [BEHAVIORS
- namespace_1.property_C = $thickness
- namespace_1.property_D = $thickness
-
- [
- namespace_3.property_A = true
- namespace_3.property_B = false
-
- [INPUTS
- $var_string = "string"
- namespace_4.property_A = 3.0
- namespace_4.property_B = "string"
- namespace_4.property_C = string
- namespace_4.property_D = $var_string
- namespace_4.property_E = ~$thickness:6:0.6
--------------------------------------------------------------------------------------------------------------
- In this example, only the resources "namespace_1.property_C" and "namespace_1.property_D" will not be
- processed by the parser, because the section "BEHAVIORS" has not been explicitly added, unless there is a
- "+ BEHAVIORS" definition somewhere in the included files "themes/amber.conf" or "themes/retro.conf". By the
- way, these two child files can also make use of the "color_background" and "thickness" variables, because
- they have been defined before the inclusions. And thanks to the section "COLORS" being added and therefore
- parsed, the "INPUTS" section will be processed too, since it's added within that section. But it also means
- that if the "+ COLORS" definition gets commented out or removed, then both the sections "COLORS" and
- "INPUTS" will stop being parsed.
--------------------------------------------------------------------------------------------------------------
- CORE RESOURCES ---------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------
- Overall scale of the UI, every geometric value is affected with the exception of "core.popup_*" resources.
- Fractional scaling is supported.
- type : UDOUBLE
scale = 1.0
- Modifier key to use for keybinds and input swap-maps.
- type : STRING
- values :
- ctrl
- mod1
- mod4
meta_modifier = ctrl
--------------------------------------------------------------------------------------------------------------
- Name of the font family to use. Has to be a monospace font.
- type : STRING
core.font_face = "Monospace"
- Enable font geometry overrides in case the font's geometry is not properly detected.
- If enabled you will have to set "core.font_override_*" resources.
- type : BOOL
core.font_enable_overrides = false
- Size of the font to use.
- type : UINT16
core.font_size = 14
- Horizontal correction offset in case the rendered text is not properly aligned. Does not require overrides
- to be enabled.
- type : INT16
core.font_x_offset = 0
- Vertical correction offset in case the rendered text is not properly aligned. Does not require overrides
- to be enabled.
- type : INT16
core.font_y_offset = 0
- Extra horizontal spacing between rendered characters.
- type : UINT16
core.font_horizontal_spacing = 0
- Extra vertical spacing between rendered characters.
- type : UINT16
core.font_vertical_spacing = 2
- Override parameter to manually set the font's ascent from its baseline.
- type : UINT16
core.font_override_ascent = 14
- Override parameter to manually set the font's descent from its baseline.
- type : UINT16
core.font_override_descent = 0
- Override parameter to manually set the font's width from its baseline.
- type : UINT16
core.font_override_width = 7
- Font rendering parameter from cairo.
- See https://cairographics.org/manual/cairo-cairo-font-options-t.html#cairo-hint-metrics-t
- type : BOOL
core.font_enable_hint_metrics = true
- Font rendering parameter from cairo.
- See https://cairographics.org/manual/cairo-cairo-font-options-t.html#cairo-subpixel-order-t
- type : STRING
- values :
- none
- grey
- subpixel
core.font_antialias = subpixel
- Font rendering parameter from cairo.
- See https://cairographics.org/manual/cairo-cairo-t.html#cairo-antialias-t
- type : STRING
- values :
- rgb
- bgr
- vrgb
- vbgr
core.font_subpixel_order = rgb
--------------------------------------------------------------------------------------------------------------
- Cope feature in case the WM does not provides a border or other means of seeing the window focus,
- enabled/disabled window state, or enabled/disabled grid lock.
- type : BOOL
core.window_enable_dynamic_border = false
- If enabled the window will be considered focused upon mapping even if it does not receives a focus event.
- type : BOOL
core.window_focus_when_activated = false
- Thickness of the window's border.
- type : UINT16
core.window_thickness_border = 0
- Padding between cells.
- type : UINT16
core.window_padding_inner = 3
- Padding between the cell area and the border.
- type : UINT16
core.window_padding_outer = 3
- Padding within the cells, between their boundary and text area. This, along with the font size is the main
- parameter that determines the size of cells. Other padding values from the "base" namespace only apply to
- specific elements and have to bearing on the cell's maximum geometry.
- type : UINT16
core.window_padding_cell = 15
- Color of the window's background
- type : COLOR
core.window_color_background = #000000
- Color of the window border in its default state, when it's not focused, enabled and has its grids unlocked.
- type : COLOR
core.window_color_border = #000000
- Color of the window border when the window is focused.
- Only applies if the "core.window_enable_dynamic_border" resource is enabled.
- type : COLOR
core.window_color_border_focused = #AB8123
- Color of the window border when the window is disabled
- Only applies if the "core.window_enable_dynamic_border" resource is enabled.
- type : COLOR
core.window_color_border_disabled = #666666
- Color of the window border when the window is focus and its grid lock is engaged.
- Only applies if the "core.window_enable_dynamic_border" resource is enabled.
- type : COLOR
core.window_color_border_locked = #7f1919
--------------------------------------------------------------------------------------------------------------
- Enable popups position overrides for custom absolute positioning on the screen.
- Intented for devices with little display real estate.
- type : BOOL
core.popup_enable_position_overrides = false
- Enable popups width override to set a custom absolute width.
- Intented for devices with little display real estate.
- type : BOOL
core.popup_enable_width_override = false
- Enable popups height override to set a custom absolute height.
- Intented for devices with little display real estate.
- type : BOOL
core.popup_enable_height_override = false
- Maximum allowed width for popups.
- type : UINT16
core.popup_max_width = 0
- Maximum allowed height for popups.
- type : UINT16
core.popup_max_height = 0
- Override parameter to force all popups to spawn at a specified horizontal position.
- Only applies if the "core.popup_enable_position_overrides" resource is enabled.
- type : INT16
core.popup_override_x_position = 0
- Override parameter to force all popups to spawn at a specified vertical position.
- Only applies if the "core.popup_enable_position_overrides" resource is enabled.
- type : INT16
core.popup_override_y_position = 0
- Override paramter to force all popups to have the specified fixed width.
- Only applies if the "core.popup_enable_width_override" resource is enabled.
- type : UINT16
core.popup_override_width = 0
- Override paramter to force all popups to have the specified fixed height.
- Only applies if the "core.popup_enable_height_override" resource is enabled.
- type : UINT16
core.popup_override_height = 0
--------------------------------------------------------------------------------------------------------------
- Allows cells that request it, on any event, to lock the focus if they have it.
- type : BOOL
core.misc_allow_cell_to_lock_focus = true
- If enabled, the currently focused cell will not lose focus until another cell get focused, event if the
- pointer leaves the cell.
- type : BOOL
core.misc_enable_persistent_pointer = false
- If enabled, the currently focused cell will not lose focus until another cell get focused, even if the
- cell's first touch action leaves the cell.
- type : BOOL
core.misc_enable_persistent_touch = false
- Vertical sync parameter. Set to 0 to disable, in which case the windows will be redrawn as fast as possible,
- and animation fps will not be capped. Set to 1 to redraw the windows at the monitor's refresh rate. Bigger
- values act as a divider, like 2 being half the monitor's refresh rate. Introduce latency but creates a lot
- less redraws if there is an animation running. If disabled with 0, tearing can appear.
- type : UINT
core.misc_animation_framerate_divider = 1
--------------------------------------------------------------------------------------------------------------
- BASE RESOURCES ---------------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------
- Generic color.
- type : COLOR
base.common_color_black = #252525
- Generic color.
- type : COLOR
base.common_color_red = #C2211C
- Generic color.
- type : COLOR
base.common_color_green = #908F18
- Generic color.
- type : COLOR
base.common_color_yellow = #CC911F
- Generic color.
- type : COLOR
base.common_color_blue = #427D81
- Generic color.
- type : COLOR
base.common_color_magenta = #A85D7E
- Generic color.
- type : COLOR
base.common_color_cyan = #629464
- Generic color.
- type : COLOR
base.common_color_white = #9F917C
- Generic color.
- type : COLOR
base.common_color_bright_black = #8A7B6D
- Generic color.
- type : COLOR
base.common_color_bright_red = #ED4530
- Generic color.
- type : COLOR
base.common_color_bright_green = #AEB123
- Generic color.
- type : COLOR
base.common_color_bright_yellow = #EDB42B
- Generic color.
- type : COLOR
base.common_color_bright_blue = #7B9D90
- Generic color.
- type : COLOR
base.common_color_bright_magenta = #C77E90
- Generic color.
- type : COLOR
base.common_color_bright_cyan = #86B676
- Generic color.
- type : COLOR
base.common_color_bright_white = #DFD0A9
--------------------------------------------------------------------------------------------------------------
- Thickness of the focus outline around cells.
- type : UINT16
base.focus_thickness = 3
- Offset of the focus outline from cells. Take in account the cells style margin offset.
- type : UINT16
base.focus_margin = 0
- Color of the secondary focus outline.
- type : COLOR
base.focus_color_secondary = #C8BBB4
- Color of the primary focus outline.
- type : COLOR
base.focus_color_primary = #C8BBB4
- Color of the primary focus outline when it's locked onto the cell.
- type : COLOR
base.focus_color_primary_locked = #AB2323
--------------------------------------------------------------------------------------------------------------
- BASE STYLES RESOURCES --------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------
- To simplify theming, cells share multiple styling attributes and said attributes are all names and
- interpreted the same way. However not all cells make use of all styling attributes. Moreover some cells
- have multiple styles, one for each internal state. In this subsection are defined all the cell styling
- resources named "base.*_something" with something being a cell's name + state (if any). The next
- subsections only show the resources that are actually used by a given cell at a given state, and as before
- the value that are set matches the hard coded ones.
- Whether or not to use a bold font for the labels / main text elements.
- type : BOOL
- base.*_use_bold_font
- Thickness of the border. It's drawn within the cell boundary and margin.
- type : UINT16
- base.*_thickness_border
- Thickness of separator lines.
- type : UINT16
- base.*_thickness_separator
- Thickness of limiter lines. Limiters are different from separators, as they are a cut-off text indicator.
- Usually only appears on labels that cannot fit within their cells.
- type : UINT16
- base.*_thickness_limiter
- Thickness of vector lines used in icon drawing.
- type : UINT16
- base.*_thickness_icon_lines
- Cell boundary inner offset. Used to make the cell and its content smaller than the maximum available space.
- type : UINT16
- base.*_margin
- Padding from the cell's boundary (not border) to the area on which miscellaneous content is drawn.
- The margin is taken in account.
- type : UINT16
- base.*_padding_foreground
- Padding from the cell's boundary (not border) to the icon drawing area.
- The margin is taken in account.
- type : UINT16
- base.*_padding_icon
- Gap between the cut-off text and limiter line.
- type : UINT16
- base.*_gap_limiter
- Animation speed, its meaning is cell dependent.
- type : UINT
- base.*_animation_speed
- Color of the cell's background.
- type : COLOR
- base.*_color_background
- Color of the cell's border.
- type : COLOR
- base.*_color_border
- Color of the label / main text elements.
- type : COLOR
- base.*_color_font
- Color of the separator lines.
- type : COLOR
- base.*_color_separator
- Color of the limiter lines.
- type : COLOR
- base.*_color_limiter
- Arbitrary primary color to be used by the cell to draw icons or other miscellaneous components.
- type : COLOR
- base.*_color_primary
- Arbitrary secondary color to be used by the cell to draw icons or other miscellaneous components.
- type : COLOR
- base.*_color_secondary
- Arbitrary highlight color to be used by the cell to draw icons or other miscellaneous components.
- type : COLOR
- base.*_color_highlight
--------------------------------------------------------------------------------------------------------------
- Variables used by styles
$thick_bd = 0
$thick_sep = 3
$thick_lim = 3
$thick_icon = 2
$pad_fg = 6
$pad_icon = 15
$gap_lim = 3
$margin = 0
$cl_bd = #000000
$cl_fg = #0A0A0A
$cl_hili = #AB8123
$cl_warn = #AB2323
$cl_bg_passive = #141414
$cl_bg_idle = #634500
$cl_bg_focused = #634500
$cl_bg_pressed = #1A1200
$cl_bg_disabled = #382700
$cl_ft_warn = #000000
$cl_ft_passive = #C8BBB4
$cl_ft_idle = #C8BBB4
$cl_ft_focused = #C8BBB4
$cl_ft_pressed = #C8BBB4
$cl_ft_disabled = #7C736D
--------------------------------------------------------------------------------------------------------------
- Gap cell style
base.gap_thickness_border = $thick_bd
base.gap_margin = $margin
base.gap_color_background = $cl_bg_passive
base.gap_color_border = $cl_bd
--------------------------------------------------------------------------------------------------------------
- Label cell style
- There is an extra resource that's not part of the regular styling attributes.
base.label_use_bold_font = false
base.label_thickness_border = $thick_bd
base.label_thickness_limiter = $thick_lim
base.label_margin = $margin
base.label_gap_limiter = $gap_lim
base.label_color_background = $cl_bg_passive
base.label_color_border = $cl_bd
base.label_color_font = $cl_ft_passive
base.label_color_limiter = $cl_warn
- In case the program uses a colored label, this values sets the actual cell background color by mixing the
- default background color with the label's custom color.
- type : UDOUBLE (but significant values are between 0.0 and 1.0)
base.label_color_background_ratio = 0.05
--------------------------------------------------------------------------------------------------------------
- cell style
base.placeholder_thickness_border = $thick_bd
base.placeholder_thickness_separator = $thick_sep
base.placeholder_margin = $margin
base.placeholder_padding_foreground = 0
base.placeholder_color_background = $cl_bg_passive
base.placeholder_color_border = $cl_bd
base.placeholder_color_separator = ~$cl_bg_passive:#000000:0.3
--------------------------------------------------------------------------------------------------------------
- Gauge cell style with 3 states.
- Default state is used when the gauge is not full and its value is not unknown.
- The animation value (only relevant when the gauge's value is unknown) represent the translation speed of the
- bar in pixel/s.
base.gauge_default_use_bold_font = false
base.gauge_default_thickness_border = $thick_bd
base.gauge_default_thickness_separator = 9
base.gauge_default_thickness_limiter = $thick_lim
base.gauge_default_margin = $margin
base.gauge_default_padding_foreground = 0
base.gauge_default_gap_limiter = $gap_lim
base.gauge_default_color_background = $cl_bg_passive
base.gauge_default_color_border = $cl_bd
base.gauge_default_color_font = $cl_ft_passive
base.gauge_default_color_separator = $cl_hili
base.gauge_default_color_limiter = $cl_warn
base.gauge_default_color_primary = ~$cl_bg_passive:$cl_hili:0.4
base.gauge_full_use_bold_font = false
base.gauge_full_thickness_border = $thick_bd
base.gauge_full_thickness_separator = 9
base.gauge_full_thickness_limiter = $thick_lim
base.gauge_full_margin = $margin
base.gauge_full_padding_foreground = 0
base.gauge_full_gap_limiter = $gap_lim
base.gauge_full_color_background = $cl_bg_passive
base.gauge_full_color_border = $cl_bd
base.gauge_full_color_font = $cl_hili
base.gauge_full_color_separator = $cl_hili
base.gauge_full_color_limiter = $cl_warn
base.gauge_full_color_primary = ~$cl_bg_passive:$cl_hili:0.6
base.gauge_unknown_thickness_border = $thick_bd
base.gauge_unknown_margin = $margin
base.gauge_unknown_padding_foreground = $pad_fg
base.gauge_unknown_animation_speed = 200
base.gauge_unknown_color_background = $cl_bg_passive
base.gauge_unknown_color_border = $cl_bd
base.gauge_unknown_color_primary = $cl_hili
--------------------------------------------------------------------------------------------------------------
- Indicator cell style with 4 states.
- Both critical states are actually substates of the indicator's critical mode, and are switched back and
- forth to create a blinking animation. The animation speed value of both critical substates represent the
- delay in milliseconds a given state stays up before switching over. They don't necessarily need to be
- identical.
base.indicator_off_use_bold_font = false
base.indicator_off_thickness_border = $thick_bd
base.indicator_off_thickness_limiter = $thick_lim
base.indicator_off_margin = $margin
base.indicator_off_padding_foreground = $pad_fg
base.indicator_off_gap_limiter = $gap_lim
base.indicator_off_color_background = $cl_bg_passive
base.indicator_off_color_border = $cl_bd
base.indicator_off_color_font = $cl_ft_disabled
base.indicator_off_color_limiter = $cl_warn
base.indicator_off_color_highlight = $cl_fg
base.indicator_on_use_bold_font = false
base.indicator_on_thickness_border = $thick_bd
base.indicator_on_thickness_limiter = $thick_lim
base.indicator_on_margin = $margin
base.indicator_on_padding_foreground = $pad_fg
base.indicator_on_gap_limiter = $gap_lim
base.indicator_on_color_background = ~$cl_bg_passive:$cl_warn:0.1
base.indicator_on_color_border = $cl_bd
base.indicator_on_color_font = $cl_ft_warn
base.indicator_on_color_limiter = $cl_ft_warn
base.indicator_on_color_highlight = $cl_warn
base.indicator_critical_off_use_bold_font = false
base.indicator_critical_off_thickness_border = $thick_bd
base.indicator_critical_off_thickness_limiter = $thick_lim
base.indicator_critical_off_margin = $margin
base.indicator_critical_off_padding_foreground = $pad_fg
base.indicator_critical_off_gap_limiter = $gap_lim
base.indicator_critical_off_animation_speed = 500
base.indicator_critical_off_color_background = $cl_bg_passive
base.indicator_critical_off_color_border = $cl_warn
base.indicator_critical_off_color_font = $cl_ft_disabled
base.indicator_critical_off_color_limiter = $cl_warn
base.indicator_critical_off_color_highlight = $cl_fg
base.indicator_critical_on_use_bold_font = false
base.indicator_critical_on_thickness_border = $thick_bd
base.indicator_critical_on_thickness_limiter = $thick_lim
base.indicator_critical_on_margin = $margin
base.indicator_critical_on_padding_foreground = $pad_fg
base.indicator_critical_on_gap_limiter = $gap_lim
base.indicator_critical_on_animation_speed = 500
base.indicator_critical_on_color_background = ~$cl_bg_passive:$cl_warn:0.1
base.indicator_critical_on_color_border = $cl_bd
base.indicator_critical_on_color_font = $cl_ft_warn
base.indicator_critical_on_color_limiter = $cl_ft_warn
base.indicator_critical_on_color_highlight = $cl_warn
--------------------------------------------------------------------------------------------------------------
- Button cell style with 4 states
base.button_idle_use_bold_font = false
base.button_idle_thickness_border = $thick_bd
base.button_idle_thickness_limiter = $thick_lim
base.button_idle_thickness_icon_lines = $thick_icon
base.button_idle_margin = $margin
base.button_idle_padding_icon = $pad_icon
base.button_idle_gap_limiter = $gap_lim
base.button_idle_color_background = $cl_bg_idle
base.button_idle_color_border = $cl_bd
base.button_idle_color_font = $cl_ft_idle
base.button_idle_color_limiter = $cl_warn
base.button_idle_color_primary = $cl_ft_idle
base.button_idle_color_secondary = $cl_bd
base.button_focused_use_bold_font = false
base.button_focused_thickness_border = $thick_bd
base.button_focused_thickness_limiter = $thick_lim
base.button_focused_thickness_icon_lines = $thick_icon
base.button_focused_margin = $margin
base.button_focused_padding_icon = $pad_icon
base.button_focused_gap_limiter = $gap_lim
base.button_focused_color_background = $cl_bg_focused
base.button_focused_color_border = $cl_bd
base.button_focused_color_font = $cl_ft_focused
base.button_focused_color_limiter = $cl_warn
base.button_focused_color_primary = $cl_ft_focused
base.button_focused_color_secondary = $cl_bd
base.button_pressed_use_bold_font = false
base.button_pressed_thickness_border = $thick_bd
base.button_pressed_thickness_limiter = $thick_lim
base.button_pressed_thickness_icon_lines = $thick_icon
base.button_pressed_margin = $margin
base.button_pressed_padding_icon = $pad_icon
base.button_pressed_gap_limiter = $gap_lim
base.button_pressed_color_background = $cl_bg_pressed
base.button_pressed_color_border = $cl_bd
base.button_pressed_color_font = $cl_ft_pressed
base.button_pressed_color_limiter = $cl_warn
base.button_pressed_color_primary = $cl_ft_pressed
base.button_pressed_color_secondary = $cl_bd
base.button_disabled_use_bold_font = false
base.button_disabled_thickness_border = $thick_bd
base.button_disabled_thickness_limiter = $thick_lim
base.button_disabled_thickness_icon_lines = $thick_icon
base.button_disabled_margin = $margin
base.button_disabled_padding_icon = $pad_icon
base.button_disabled_gap_limiter = $gap_lim
base.button_disabled_color_background = $cl_bg_disabled
base.button_disabled_color_border = $cl_bd
base.button_disabled_color_font = $cl_ft_disabled
base.button_disabled_color_limiter = $cl_warn
base.button_disabled_color_primary = $cl_ft_disabled
base.button_disabled_color_secondary = $cl_bd
--------------------------------------------------------------------------------------------------------------
- Switch cell style with 4 states.
base.switch_idle_use_bold_font = false
base.switch_idle_thickness_border = $thick_bd
base.switch_idle_thickness_limiter = $thick_lim
base.switch_idle_thickness_icon_lines = $thick_icon
base.switch_idle_margin = $margin
base.switch_idle_padding_icon = $pad_icon
base.switch_idle_gap_limiter = $gap_lim
base.switch_idle_color_background = $cl_bg_idle
base.switch_idle_color_border = $cl_bd
base.switch_idle_color_font = $cl_ft_idle
base.switch_idle_color_limiter = $cl_warn
base.switch_idle_color_primary = $cl_bd
base.switch_idle_color_highlight = $cl_hili
base.switch_focused_use_bold_font = false
base.switch_focused_thickness_border = $thick_bd
base.switch_focused_thickness_limiter = $thick_lim
base.switch_focused_thickness_icon_lines = $thick_icon
base.switch_focused_margin = $margin
base.switch_focused_padding_icon = $pad_icon
base.switch_focused_gap_limiter = $gap_lim
base.switch_focused_color_background = $cl_bg_focused
base.switch_focused_color_border = $cl_bd
base.switch_focused_color_font = $cl_ft_focused
base.switch_focused_color_limiter = $cl_warn
base.switch_focused_color_primary = $cl_bd
base.switch_focused_color_highlight = $cl_hili
base.switch_pressed_use_bold_font = false
base.switch_pressed_thickness_border = $thick_bd
base.switch_pressed_thickness_limiter = $thick_lim
base.switch_pressed_thickness_icon_lines = $thick_icon
base.switch_pressed_margin = $margin
base.switch_pressed_padding_icon = $pad_icon
base.switch_pressed_gap_limiter = $gap_lim
base.switch_pressed_color_background = $cl_bg_pressed
base.switch_pressed_color_border = $cl_bd
base.switch_pressed_color_font = $cl_ft_pressed
base.switch_pressed_color_limiter = $cl_warn
base.switch_pressed_color_primary = $cl_bd
base.switch_pressed_color_highlight = $cl_hili
base.switch_disabled_use_bold_font = false
base.switch_disabled_thickness_border = $thick_bd
base.switch_disabled_thickness_limiter = $thick_lim
base.switch_disabled_thickness_icon_lines = $thick_icon
base.switch_disabled_margin = $margin
base.switch_disabled_padding_icon = $pad_icon
base.switch_disabled_gap_limiter = $gap_lim
base.switch_disabled_color_background = $cl_bg_disabled
base.switch_disabled_color_border = $cl_bd
base.switch_disabled_color_font = $cl_ft_disabled
base.switch_disabled_color_limiter = $cl_warn
base.switch_disabled_color_primary = $cl_bd
base.switch_disabled_color_highlight = $cl_hili
--------------------------------------------------------------------------------------------------------------
- Spinner cell style.
- The animation value represent the icon's spinning speed, in rad/s.
base.spinner_use_bold_font = false
base.spinner_thickness_border = $thick_bd
base.spinner_thickness_limiter = $thick_lim
base.spinner_thickness_icon_lines = $thick_icon
base.spinner_margin = $margin
base.spinner_padding_icon = $pad_icon
base.spinner_gap_limiter = $gap_lim
base.spinner_animation_speed = 4
base.spinner_color_background = $cl_bg_passive
base.spinner_color_border = $cl_bd
base.spinner_color_font = $cl_ft_passive
base.spinner_color_limiter = $cl_warn
base.spinner_color_primary = $cl_ft_passive
--------------------------------------------------------------------------------------------------------------
- KEY & BUTTON BINDINGS --------------------------------------------------------------------------------------
--------------------------------------------------------------------------------------------------------------
- "key" and "button" namespaces are special because they are reserved specifically for input swap-maps and
- add their own sets of rules on top of the normal syntax. They are mostly used to configure key-binds (or
- button-binds) called Actions. Internally they have a custom resource parser. And while the
- "namespace.property = value" resource structure still holds, both the property and value are treated a bit
- differently than usual. Because swap-maps cover a large array of inputs (all keyboard keys and pointer
- buttons, 200 and 12 respectively) that can be combined with the modkey and shift key resulting in
- technically 636 total different potential resources.
-
- The properties are therefore composed of 2 elements, a swap-map level, and an input code, joined together
- without a whitespace in-between. There are 3 swap-map levels : normal, modifier, and modifier + shift. To
- access keybinds on the last two levels, you need to hold the modifier key and (or not) shift then trigger
- the appropriate key or button. The "normal" swap-map level does not require any special keys to be accessed
- and it is, therefore, dangerous to set keybinds on this level, because it may block a normal input, like a
- letter. It is thus recommended to only use this level on keys that are never used by cells, like the
- function row. The swap-map level is symbolized with the following character, which has to be preprended to
- the input code : none, "M" and "S" respectively. The input codes themselves are interpreted as keycodes and
- button IDs for the keyboard and pointer respectively. Here keycodes are used instead of keysyms to make any
- key-bind independent from the keymap, that way if you temporarily change your keymap, all DG key-binds
- remain the sames, thus avoiding potential confusion, especially with different alphabets. It also helps
- make DG independent from any language. Finally, it allows for easy keybind configuration on custom
- keyboards. If in doubt about which keycode is which, use xev to find out.
- Duplicate actions on different keys or buttons combos are allowed.
- Touch inputs are not affected by swap-maps.
-
- On the other hand, the values, are technically 2 strings separated by ":", the first one for the swap
- type and the second for the swap value. Both "key" and "button" swap-maps share the same swap types and
- values.
--------------------------------------------------------------------------------------------------------------
- There are 11 kinds of swaps.
-
- "default"
- Placeholder value, the input will not be attributed to any specific action.
- Exceptionally, the value is not needed and can be omitted, along with the separating ":".
-
- "none"
- The input will be explicitely blocked / disabled.
- Exceptionally, the value is not needed and can be omitted, along with the separating ":".
-
- "value"
- The keycode or button ID that will be normally passed down to a cell is swapped to the indicated value.
- For example "button.1 = value:3" will make DG interpret button 1 input as if they were made with button 3
- instead. Useful to reach certain keycodes or buttons IDs that may not be available on your hardware. It
- cannot however make a button be interpreted as a key and vice-versa.
- The value field is an integer, from 0 to 200 for keycodes, and from 0 to 12 for button ids.
-
- "accel"
- An accelerator action. Similar to a custom shortcut set by an application developer. They are not cell
- dependent, but instead window dependent. There are only 12 of them available. That's not a lot, because they
- are reserved only for custom actions, common ones like clipboard copy/cut/paste have their own dedicated
- actions. Moreover, their presence on a given window is hinted through window X properties "_DG_WINDOW_FNx",
- with "x" being the accelerator number. Accelerators are intended to be visible to the end-user through a
- desktop WM/Shell component, hence the limit of 12.
- The value field here is an integer, from 1 to 12.
-
- "cut"
- Clipboard action.
- The value field is an integer, form 1 to 3, for each clipboard.
-
- "copy"
- Clipboard action.
- The value field is an integer, form 1 to 3, for each clipboard.
-
- "paste"
- Clipboard action.
- The value field is an integer, form 1 to 3, for each clipboard.
-
- "cell"
- Specific Cell level actions.
- The value field is a string with special values and significations :
- "select-" = reduce selection
- "select+" = increase selection
- "unselect" = remove all selection
- "selectAll" = select everything within the cell
- "redraw" = force the cell to be redrawn
- "trigger1" = custom, cell specific action 1
- "trigger2" = custom, cell specific action 2
- "trigger3" = custom, cell specific action 3
- "trigger4" = custom, cell specific action 4
- "trigger5" = custom, cell specific action 5
-
- "focus"
- Focus navigation actions. The reference navigation point of each cell is their top left corner and the scan
- to find the next cell to focus (only for directional actions) is done the cell's width or length.
- The value field is a string with special values and significations :
- "left" = focus left
- "right" = focus right
- "up" = focus up
- "down" = focus down
- "leftmost" = focus all the way left
- "rightmost" = focus all the way right
- "top" = focus all the way up
- "bottom" = focus all the way down
- "next" = focus the next cell
- "previous" = focus the previous cell
- "first" = focus the first cell
- "last" = focus the last cell
- "none" = unfocus
-
- "window"
- Specific window level actions.
- The value field is a string with special values and significations :
- "lockGrid" = lock the current grid, if there are more on the same windows they will not be switched to
- "lockFocus" = lock the focus, it can be broken by focus actions, but not by touch or pointer movement
- "redraw" = force the whole window to be redrawn
-
- "misc"
- Specific application level actions.
- The value field is a string with special values and significations :
- "reconfig" = reload the configuration
- "exit" = force the application to exit, can be disabled by the application developer.
--------------------------------------------------------------------------------------------------------------
- Examples :
- key.67 = focus:next