linuxmint / linuxmint/cinnamon

power@cinnamon.org applet keyboard backlight brightness slider value setting logic is wrong

Open
#11,389 0 comments 2 reactions 1 assignee View on GitHub

@mtwebster is already working on this.

Since Mar 24, 2023.

BUG New
Dominant language
JavaScript
Stars
5.6k
Forks
915
Avg merge
5d 22h
Merged PRs (30d)
3

Description

 * Cinnamon version (cinnamon --version) - 5.4.12
   - Please specify if you are using the daily builds PPA - I'm not
     (https://launchpad.net/~linuxmint-daily-build-team/+archive/ubuntu/daily-builds).
 * Distribution - Mint 21
 * Graphics hardware *and* driver used - AMD ATI 04:00.0 Renoir (integrated GPU of Ryzen 5 4500U), amdgpu driver
 * 32 or 64 bit - 64-bit

xsession-errors.log

Issue

On Zenbook 14 UM425I which has a 4-stage (off + 3 levels of brightness) keyboard backlight I noticed the backlight brightness slider provided by the power@cinnamon.org GUI applet simply sets the brightness to 0% on the first two values which doesn't make a lot of sense.

Steps to reproduce

Try to set keyboard backlight to 33% by moving the slider to the second step
The first two slider steps act the exact same, effectively capping my maximum keyboard backlight control via the applet GUI at 66%

Expected behaviour

Moving to first step gives 0% brightness
Moving to second step gives 33% brightness
...
Moving to last step gives 100% brightness

Other information

GUI showing 0% on both the first and second slider value steps
image

Doubt it's of much use but as per https://github.com/Gigadoc2/i3-cinnamon/blob/master/README.md#keyboard-backlight I was able to test StepUp / StepDown worked just fine and let me reach 100% keyboard backlight brightness for example.

/sys/class/leds/asus::kbd_backlight/brightness goes from 0 up to 3 in value fwiw.

https://github.com/linuxmint/cinnamon/blob/master/files/usr/share/cinnamon/applets/power%40cinnamon.org/applet.js

Configuration info, if applicable
{
    "labelinfo": {
        "type": "combobox",
        "description": "Display",
        "default": "nothing",
        "options": {
            "Show percentage": "percentage",
            "Show time remaining": "time",
            "Show percentage and time remaining": "percentage_time",
            "Hide label": "nothing"
        },
        "value": "percentage_time"
    },
    "showmulti": {
        "type": "switch",
        "default": false,
        "description": "Always show all batteries",
        "tooltip": "Check this to always show multiple batteries in the panel, regardless of whether one of them is marked primary.",
        "value": false
    },
    "__md5__": "db29025b0930e93063f745d0adcc675a"
}

Contributor guide

No contributing guide indexed for this repository

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.