diff options
| author | Jules Aguillon | 2025-09-15 14:15:55 +0200 |
|---|---|---|
| committer | GitHub | 2025-09-15 14:15:55 +0200 |
| commit | 8db00d51ab076dd7732c494851db5ddce9e10855 (patch) | |
| tree | 691a335d150c908983f1e6080ac9f2fa292468e0 /srcs/juloo.keyboard2 | |
| parent | ab85fb717dded6cb2284a1853242fe9f93955f7d (diff) | |
| download | unexpected-keyboard-8db00d51ab076dd7732c494851db5ddce9e10855.tar.gz unexpected-keyboard-8db00d51ab076dd7732c494851db5ddce9e10855.zip | |
Allow smaller row height in custom layouts (#1100)
The height of row set with `<row height="...">` cannot be lower than 0.5
to avoid rendering problems.
This restriction is not necessary when the row has no key and is lifted
in this case.
Diffstat (limited to 'srcs/juloo.keyboard2')
| -rw-r--r-- | srcs/juloo.keyboard2/KeyboardData.java | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/srcs/juloo.keyboard2/KeyboardData.java b/srcs/juloo.keyboard2/KeyboardData.java index 494b95a..b15e836 100644 --- a/srcs/juloo.keyboard2/KeyboardData.java +++ b/srcs/juloo.keyboard2/KeyboardData.java @@ -325,7 +325,7 @@ public final class KeyboardData float kw = 0.f; for (Key k : keys_) kw += k.width + k.shift; keys = keys_; - height = Math.max(h, 0.5f); + height = Math.max(h, keys_.size() == 0 ? 0.0f : 0.5f); shift = Math.max(s, 0f); keysWidth = kw; } |
