Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

andeston
Copy link
Contributor

Summary

Fixes consistency issues for devices with low precision when adding or subtracting percentages.

Fixes #118

Behavior

Before

$ ./brightnessctl -m --frac s 50%
amdgpu_bl1,backlight,128,50.2%,255
$ ./brightnessctl -m --frac s 10%+
amdgpu_bl1,backlight,154,60.39%,255
$ ./brightnessctl -m --frac s 10%+
amdgpu_bl1,backlight,180,70.59%,255
$ ./brightnessctl -m --frac s 10%+
amdgpu_bl1,backlight,206,80.78%,255
$ ./brightnessctl -m --frac s 10%+
amdgpu_bl1,backlight,232,90.98%,255

After

$ ./brightnessctl -m --frac s 50%
amdgpu_bl1,backlight,128,50.2%,255
$ ./brightnessctl -m --frac s 10%+
amdgpu_bl1,backlight,153,60%,255
$ ./brightnessctl -m --frac s 10%+
amdgpu_bl1,backlight,179,70.2%,255
$ ./brightnessctl -m --frac s 10%+
amdgpu_bl1,backlight,204,80%,255
$ ./brightnessctl -m --frac s 10%+
amdgpu_bl1,backlight,230,90.2%,255

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant