Bug 416638

Summary: Dark Background detection is not working
Product: [Applications] konsole Reporter: Manuel Rüger <manuel>
Component: generalAssignee: Konsole Developer <konsole-devel>
Status: RESOLVED FIXED    
Severity: normal CC: asturm, nate
Priority: NOR    
Version: unspecified   
Target Milestone: ---   
Platform: Other   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: ColorScheme-Fix-DarkBackground-Detection.patch

Description Manuel Rüger 2020-01-23 10:01:45 UTC
Created attachment 125318 [details]
ColorScheme-Fix-DarkBackground-Detection.patch

Commit https://github.com/KDE/konsole/commit/dc29be39a640e9300204f5f1ec676e7b09a2fa08#diff-29f711eecf64b2a15f382213e5b36a77R407
changed the way a dark background is detected in the color scheme.

STEPS TO REPRODUCE
1. Set to dark background
2. Check COLORFGBG variable


OBSERVED RESULT
Dark Background is not detected and COLORFGBG is set to 0;15

EXPECTED RESULT
Dark Background is detected and COLORFGBG is set to 15;0

SOFTWARE/OS VERSIONS

Linux/KDE Plasma: Gentoo Linux
KDE Plasma Version: 5.17.5
KDE Frameworks Version: 5.66.0
Qt Version: 5.13.2


I believe the luminance returned by rgb2hsluv is actually between 0 and 100 and not a percentage that is between 0 and 1.
Comment 1 Kurt Hindenburg 2020-02-09 14:36:04 UTC
Nice catch, thanks.
Comment 2 Kurt Hindenburg 2020-02-09 14:45:46 UTC
Fixed in e5b2ada1a6f06e0eea76af1f26ff4c0c4aad8497