diff options
| author | Jules Aguillon | 2022-11-11 19:47:37 +0100 |
|---|---|---|
| committer | Jules Aguillon | 2022-11-11 19:47:37 +0100 |
| commit | 815e30a505eb6766e29d85c2e1a5d8f4da9c83d3 (patch) | |
| tree | 415978b27fc48e109b005ba01ca7324b46c2bcc3 /srcs/juloo.keyboard2/Config.java | |
| parent | 4d99bd4f4b049d27a02f794b395aac3c56ff7fee (diff) | |
| download | unexpected-keyboard-815e30a505eb6766e29d85c2e1a5d8f4da9c83d3.tar.gz unexpected-keyboard-815e30a505eb6766e29d85c2e1a5d8f4da9c83d3.zip | |
Add option for brightness of labels
The brightness value is used as the alpha value when drawing the labels.
Diffstat (limited to 'srcs/juloo.keyboard2/Config.java')
| -rw-r--r-- | srcs/juloo.keyboard2/Config.java | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/srcs/juloo.keyboard2/Config.java b/srcs/juloo.keyboard2/Config.java index 76415b7..b2c23a5 100644 --- a/srcs/juloo.keyboard2/Config.java +++ b/srcs/juloo.keyboard2/Config.java @@ -36,6 +36,7 @@ final class Config public float horizontalMargin; public float keyVerticalInterval; public float keyHorizontalInterval; + public int labelBrightness; // 0 - 255 public boolean preciseRepeat; public boolean double_tap_lock_shift; public float characterSize; // Ratio @@ -131,6 +132,8 @@ final class Config keyHorizontalInterval = getDipPref(dm, _prefs, "key_horizontal_space", keyHorizontalInterval) * horizontalIntervalScale; + // Label brightness is used as the alpha channel + labelBrightness = _prefs.getInt("label_brightness", 100) * 255 / 100; // Do not substract keyVerticalInterval from keyHeight because this is done // during rendered. keyHeight = dm.heightPixels * keyboardHeightPercent / 100 / 4; |
