Skip to content

Commit 9de1af1

Browse files
Add button stretch documentation to config template
1 parent 486119a commit 9de1af1

1 file changed

Lines changed: 21 additions & 1 deletion

File tree

share/tiny-dfr/config.toml

Lines changed: 21 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -40,10 +40,15 @@ ActiveBrightness = 128
4040
# You can change the individual buttons, add, or remove them
4141
# Any number of keys that is greater than 0 is allowed
4242
# however rendering will start to break around 24 keys
43+
# Buttons can be made larger by setting the optional Stretch field
44+
# to a number greater than 1 (which means the button will take up
45+
# that many button spaces).
4346
PrimaryLayerKeys = [
4447
# Action defines the key code to send when the button is pressed
4548
# Text defines the button label
4649
# Icon specifies the icon to be used for the button.
50+
# Stretch specifies how many button spaces the button should take up
51+
# and defaults to 1
4752
# Icons can either be svgs or pngs, with svgs being preferred
4853
# For best results with pngs, they should be 48x48
4954
# Do not include the extension in the file name.
@@ -66,6 +71,22 @@ PrimaryLayerKeys = [
6671
{ Text = "F10", Action = "F10" },
6772
{ Text = "F11", Action = "F11" },
6873
{ Text = "F12", Action = "F12" }
74+
# Example with Stretch:
75+
# # because most buttons have stretch 2, they behave as if they all had 1:
76+
# { Text = "F1", Action = "F1", Stretch = 2 },
77+
# { Text = "F2", Action = "F2", Stretch = 2 },
78+
# # these two buttons are half the size of the other buttons:
79+
# { Text = "F3", Action = "F3", Stretch = 1 },
80+
# { Text = "F4", Action = "F4", Stretch = 1 },
81+
# { Text = "F5", Action = "F5", Stretch = 2 },
82+
# { Text = "F6", Action = "F6", Stretch = 2 },
83+
# { Text = "F7", Action = "F7", Stretch = 2 },
84+
# # these two buttons are one and a half the size of the other buttons:
85+
# { Text = "F8", Action = "F8", Stretch = 3 },
86+
# { Text = "F9", Action = "F9", Stretch = 3 },
87+
# { Text = "F10", Action = "F10", Stretch = 2 },
88+
# { Text = "F11", Action = "F11", Stretch = 2 },
89+
# { Text = "F12", Action = "F12", Stretch = 2 }
6990
]
7091

7192
# This key defines the contents of the media key layer
@@ -83,4 +104,3 @@ MediaLayerKeys = [
83104
{ Icon = "volume_down", Action = "VolumeDown" },
84105
{ Icon = "volume_up", Action = "VolumeUp" }
85106
]
86-

0 commit comments

Comments
 (0)