WIP: [Night Color] Display time when the next transition will start
Changes PlannedPublic

Authored by zzag on Jan 15 2020, 12:16 PM.

Details

Reviewers
ngraham
Group Reviewers
Plasma
VDG
Summary

Currently the applet displays "Night Color is active (%screen color
temperature% K)" all the time even if the screen is not actually
red-ish. It may be really confusing for ordinary people and I expect
that a few bug reports saying "the applet shows that Night Color is
active, but in reality it isn't" might be reported.

The best thing would be to display "Night Color is not active, the next
transition will start at %datetime% and end at %datetime%" or something
along the line.

This patch is still WIP because I'm not 100% sure how to present this
kind of information to user.

Test Plan

Diff Detail

Repository
R114 Plasma Addons
Branch
show-next-transition-timings
Lint
No Linters Available
Unit
No Unit Test Coverage
Build Status
Buildable 24107
Build 24125: arc lint + arc unit
zzag created this revision.Jan 15 2020, 12:16 PM
Restricted Application added a project: Plasma. · View Herald TranscriptJan 15 2020, 12:16 PM
Restricted Application added a subscriber: plasma-devel. · View Herald Transcript
zzag requested review of this revision.Jan 15 2020, 12:16 PM
zzag edited the test plan for this revision. (Show Details)Jan 15 2020, 12:16 PM
zzag edited the test plan for this revision. (Show Details)
zzag edited the test plan for this revision. (Show Details)
anthonyfieroni added inline comments.
applets/nightcolor/package/contents/ui/main.qml
57

The bigger todo is hardcoded 6500K ?

ngraham added inline comments.
applets/nightcolor/package/contents/ui/main.qml
59

This is a comma splice. Change to:

Night Color is not active. The next transition...

or

Night Color is not active; the next transition...

or

Night Color is not active, but the next transition...

zzag added inline comments.Jan 15 2020, 6:59 PM
applets/nightcolor/package/contents/ui/main.qml
57

6500K is the neutral screen color temperature. Although I don't think that I follow you. Do you recommend not to hardcode this constant?

59

Thank you very much for suggesting correct messages. As a VDG person, do you have tips how to better inform the user that Night Color currently doesn't have any effect and it will activate a bit later? Given tight time budget, I don't target 5.18 so no rush. Although it would be great to get this little feature in the next release.

Also, what time format should we use? The current one is way too informative if you ask me.

I'm pretty happy about the backend side, but the frontend obviously still needs some work... :(

anthonyfieroni added inline comments.Jan 16 2020, 8:25 AM
applets/nightcolor/package/contents/ui/main.qml
57

Do you recommend not to hardcode this constant?

Yes.

zzag updated this revision to Diff 73685.Jan 16 2020, 10:03 AM
  • Add Monitor.NeutralTemperature constant
  • Display locale time
  • Nate's suggestion
zzag marked 3 inline comments as done.Jan 16 2020, 10:04 AM
zzag edited the test plan for this revision. (Show Details)
zzag updated this revision to Diff 73686.Jan 16 2020, 10:09 AM
  • Use i18nc().

Here's my suggestions for what to display in the applet for various conditions:

Feature disabled: no tray icon shown anywhere

Feature enabled but not active: tray icon in passive state (only in pop-up) with the following text:

Night color is inactive
Activation will begin at <time>

Feature enabled, transition to turning on is in progress: tray icon is in active state with the following text:

Night color is activating
Colors fully changed at <time>

Feature enabled and colors are fully changed: tray icon is in active state with the following text:

Night color is active with color temperature <target color temperature>
Deactivation will begin at <time> tomorrow

Feature enabled, transition to turning off is in progress: tray icon is in active state with the following text:

Night color is deactivating
Colors will return to normal at <time>

ngraham requested changes to this revision.Mar 19 2020, 7:00 PM
This revision now requires changes to proceed.Mar 19 2020, 7:00 PM
zzag updated this revision to Diff 78291.Mar 23 2020, 4:13 PM

Rebase on master.

zzag planned changes to this revision.Mar 23 2020, 4:13 PM