Bug 304696 - Display is dimmed in half the time you configure to dim
Summary: Display is dimmed in half the time you configure to dim
Status: RESOLVED FIXED
Alias: None
Product: Powerdevil
Classification: Plasma
Component: general (show other bugs)
Version: 5.24.4
Platform: Arch Linux Linux
: HI task
Target Milestone: ---
Assignee: Plasma Development Mailing List
URL:
Keywords:
: 299979 299980 323041 326526 407681 411497 473562 (view as bug list)
Depends on:
Blocks:
 
Reported: 2012-08-06 23:17 UTC by Adrian Berriel
Modified: 2023-08-30 16:24 UTC (History)
19 users (show)

See Also:
Latest Commit:
Version Fixed In: 5.27.8
Sentry Crash Report:


Attachments
Screenshot of dim screen setting (101.68 KB, image/png)
2017-11-15 09:18 UTC, da-kdebugs-11
Details
Power settings not obeyed (90.50 KB, image/png)
2018-10-24 15:44 UTC, S
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Adrian Berriel 2012-08-06 23:17:44 UTC
I tried to set the display to dim in 3 and 2 minutes. In both cases the display actualy dimmed in 1:30 and 1 minute respectively. I tested on battery and on ac power with same results.

Reproducible: Always

Steps to Reproduce:
1. Open Enrgy Saving
2. Set dim display after 2 minutes
Actual Results:  
Display is dimmed in 1 minute

Expected Results:  
Display dimmed in 2 minutes

I think this is not specific to 4.9, I have noticed this bug from previous versions.
Comment 1 valdikss 2012-10-17 22:16:41 UTC
Not sure if bug or a feature. My display dims 2 times: once in a half of dim timer, for about 50% of current brightness and on a dim timer, to 10%.
Comment 2 Adrian Berriel 2012-12-18 15:16:09 UTC
The bug is still present in 4.9.4. Anyone can confirm?
Comment 3 Adrian Berriel 2012-12-18 15:25:13 UTC
(In reply to comment #1)
> Not sure if bug or a feature. My display dims 2 times: once in a half of dim
> timer, for about 50% of current brightness and on a dim timer, to 10%.

Maybe you are right. It could be a feature, however for me it has more sense that the time you provide should be used to start dimming and not to complete dimming with intermediate steps.
Comment 4 Oliver Henshaw 2013-02-13 19:19:38 UTC
Looks like powerdevil has always behaved like this. It seems to have inherited this behaviour from KDE4PowerSave, its predecessor(?).

I'm not sure how much sense this makes, however. Dario?
Comment 5 Oliver Henshaw 2013-02-17 15:11:51 UTC
*** Bug 299980 has been marked as a duplicate of this bug. ***
Comment 6 Oliver Henshaw 2013-02-17 15:12:53 UTC
*** Bug 299979 has been marked as a duplicate of this bug. ***
Comment 7 Alex Fiestas 2013-07-28 21:45:12 UTC
Are we still dimming using this strategy?

We talked about this at the sprint, what was the decision if any?
Comment 8 Alex Fiestas 2014-01-20 02:05:58 UTC
Closing the bug for inactivity.

Will try to improve in 2.0 anyway.
Comment 9 Kai Uwe Broulik 2015-01-22 21:30:39 UTC
*** Bug 326526 has been marked as a duplicate of this bug. ***
Comment 10 Kai Uwe Broulik 2015-01-25 22:38:51 UTC
*** Bug 323041 has been marked as a duplicate of this bug. ***
Comment 11 da-kdebugs-11 2017-11-15 09:18:17 UTC
Created attachment 108874 [details]
Screenshot of dim screen setting
Comment 12 da-kdebugs-11 2017-11-15 09:19:09 UTC
This is still open. Setting "Dim screen" to "3 min" makes the display dim after 90s (instead of 180s). Unchecking "Dim screen" disables dimming, so it is likely due to this setting.

System settings 5.11.3 on KDE neon.

Can't believe this has been open for 5+ years.
Comment 13 S 2018-10-24 15:44:36 UTC
Created attachment 115877 [details]
Power settings not obeyed

Hi, this bug still exists in Plasma 5.14.1 (on openSUSE Tumbleweed).

With the settings in this screenshot, it appears to dim to about 50% brightness after 2.5 minutes (half of my configured 5 minutes). But what is more strange is that it goes into yet another dimmed state of about 10% brightness at the 5 minute mark, and finally powers off the screen entirely at 6 minutes.
Comment 14 Chris Holland 2018-10-25 01:52:20 UTC
As Oliver said in 2013, it looks like this is the intended behaviour since it was first written (8 years ago?).

https://github.com/KDE/powerdevil/blame/master/daemon/actions/bundled/dimdisplay.cpp#L64

At 50% the set idle duration, it dims to 50% brightness.
At 75% the set idle duration, it dims to 12.5% brightness.
At 100% the set idle duration, it dims to 0% brightness.

We could maybe use different values, say 90% brightness, then 70% brightness, before dropping to 0% at the specified time.

I wonder if there'd be issues with changing it to 5/4 (125% idle duration) and 3/2 (150% idle duration) so that it doesn't start dimming before the user's explicitly defined value.
Comment 15 Christoph Feck 2019-05-30 18:58:14 UTC
*** Bug 407681 has been marked as a duplicate of this bug. ***
Comment 16 Kai Uwe Broulik 2019-09-02 06:38:54 UTC
*** Bug 411497 has been marked as a duplicate of this bug. ***
Comment 17 Paul Gideon Dann 2020-08-21 15:25:33 UTC
If the behaviour is not changed, it would be nice to have the actual behaviour explained in the config panel. The current experience certainly isn't as intuitive as it could be.
Comment 18 Tim Siegel 2022-04-15 13:02:37 UTC
This bug is still present, KDE 5.24.4.

There are 5 proposed solutions, ranked from worst to best.

1. Do nothing, it works as intended.
2. Keep the same behavior, except dim less (90%, 75%). This will cause just as much end-user confusion, while also upsetting people who are used to the current behavior.
3. Keep the same behavior, but document it in the settings interface. This is the least we could do, should ruffle no feathers, and won't even unbalance the UI since that page already contains several long textual explanations.
4. Keep the behavior as is, except change the dimming times to be 1, ⁵⁄₄, ³⁄₂ (instead of ½, ¾, 1), so the screen stays full brightness until the requested dimming time.
5. Remove this unnecessary feature. Dim 50% at the requested time, and let "Screen Energy Saving: Switch off" do the rest.

"Do nothing" has been the KDE response for a decade at this point, and yet it is clearly the wrong answer. There is no way to read "Dim screen: After 3 minutes" to mean "50% at 1:30".
Comment 19 Konstantin Kharlamov 2023-08-23 00:31:06 UTC
I sent an MR to fix this https://invent.kde.org/plasma/powerdevil/-/merge_requests/213
Comment 20 Nate Graham 2023-08-23 01:37:30 UTC
*** Bug 473562 has been marked as a duplicate of this bug. ***
Comment 21 Nate Graham 2023-08-25 14:46:14 UTC
Git commit 14647dc6ffd1104c1c0ab393518de8a65cb39d70 by Nate Graham, on behalf of Konstantin Kharlamov.
Committed on 25/08/2023 at 16:46.
Pushed by ngraham into branch 'master'.

dimdisplay: only dim the screen at configured dim time

The current logic is completely broken:

1. It disables the screen at `m_dimOnIdleTime` even though disabling
   the screen is handled elsewhere with a separate timeout, and the logic
   here has prefix "Dim*" so has nothing to do with disabling it.
2. It does not follow the timeout configured by a user (that is the
   `m_dimOnIdleTime`) and instead dims the screen at completely
   arbitrary 50% and 75% periods of the configured time.

Let's get rid of all that and only do exactly what the user asked: dim
the screen at `m_dimOnIdleTime`.
FIXED-IN: 5.27.8

M  +10   -14   daemon/actions/bundled/dimdisplay.cpp

https://invent.kde.org/plasma/powerdevil/-/commit/14647dc6ffd1104c1c0ab393518de8a65cb39d70
Comment 22 Konstantin Kharlamov 2023-08-29 14:18:30 UTC
Git commit dc4a286037a802f3c18512e761b89082740aa1e9 by Konstantin Kharlamov.
Committed on 29/08/2023 at 01:42.
Pushed by ngraham into branch 'Plasma/5.27'.

dimdisplay: only dim the screen at configured dim time

The current logic is completely broken:

1. It disables the screen at `m_dimOnIdleTime` even though disabling
   the screen is handled elsewhere with a separate timeout, and the logic
   here has prefix "Dim*" so has nothing to do with disabling it.
2. It does not follow the timeout configured by a user (that is the
   `m_dimOnIdleTime`) and instead dims the screen at completely
   arbitrary 50% and 75% periods of the configured time.

Let's get rid of all that and only do exactly what the user asked: dim
the screen at `m_dimOnIdleTime`.
FIXED-IN: 5.27.8

M  +10   -14   daemon/actions/bundled/dimdisplay.cpp

https://invent.kde.org/plasma/powerdevil/-/commit/dc4a286037a802f3c18512e761b89082740aa1e9
Comment 23 Paul Gideon Dann 2023-08-30 07:56:18 UTC
Is there some migration so that the currently-configured timeout doesn't suddenly double at the next upgrade? Some of us have since configured our systems to compensate for the 50% time behaviour.
Comment 24 Konstantin Kharlamov 2023-08-30 07:59:06 UTC
(In reply to Paul Gideon Dann from comment #23)
> Is there some migration so that the currently-configured timeout doesn't
> suddenly double at the next upgrade? Some of us have since configured our
> systems to compensate for the 50% time behaviour.

There isn't, but if you think it is a real problem I think it might be possible to revert the change from stable and just leave it be a breaking change for the next big 6.0 release…
Comment 25 Paul Gideon Dann 2023-08-30 08:50:10 UTC
Nah; this isn't enough of a problem for me for it to be worth delaying the fix. But thanks for confirming that there's no config migration. I'll just keep an eye on the behaviour when upgrading.
Comment 26 Nate Graham 2023-08-30 16:24:35 UTC
There's no real way for us to know whether a person set the time they did because that's the way they wanted it and they never noticed the bug, or because they did notice the bug and were manually working around it. For that reason, any such migration code would probably cause as many problems as it would potentially solve. As a general matter, people who find workarounds for issues are generally expected to undo their workarounds once the issues are fixed.