keyboard: Add/document "height" optional property

This will allow OSK descriptions to declare "tall" keys. May be
used in combination with the "start" property added in previous
commits, in case a gap needs to be explicitly left.

No OSK description uses this yet.

Part-of: <https://gitlab.gnome.org/GNOME/gnome-shell/-/merge_requests/3162>
This commit is contained in:
Carlos Garnacho 2024-01-26 14:25:57 +01:00
parent d1aa2acef1
commit cfc0d42c7a
2 changed files with 5 additions and 2 deletions

View File

@ -63,7 +63,10 @@ it has the following structure:
accepted.
- width (Double): Relative width of the key in the
row. 1 is for a square key. Multiples of 0.5 are
accepted.
accepted. The implicit default value is 1.
- height (Double): Relative height of the key in
the grid. The key will overflow downwards. Multiples
of 0.5 are accepted. The implicit default value is 1.
- level (Integer): Level that the key switches to.
See the levelSwitch action.
- action (string): Action performed by the key,

View File

@ -1564,7 +1564,7 @@ export const Keyboard = GObject.registerClass({
if (key.action || key.keyval)
button.keyButton.add_style_class_name('default-key');
layout.appendKey(button, key.width, 1, key.leftOffset);
layout.appendKey(button, key.width, key.height, key.leftOffset);
}
}