Bug 468771

Summary: "Copy time to clipboard" feature doesn't copy the exact current time when using C locale
Product: [Plasma] plasmashell Reporter: Puspam Adak <puspitaadak9876>
Component: Digital Clock widgetAssignee: Plasma Bugs List <plasma-bugs-null>
Status: CONFIRMED ---    
Severity: minor CC: nate
Priority: NOR    
Version First Reported In: 5.27.4   
Target Milestone: 1.0   
Platform: Arch Linux   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:
Attachments: All the entries show the second to be 01

Description Puspam Adak 2023-04-21 16:29:22 UTC
Created attachment 158277 [details]
All the entries show the second to be 01

SUMMARY
The "Copy to clipboard" option of the Digital clock applet copies the time with the second set to 1, no matter what the current second value is.

STEPS TO REPRODUCE
1. Right-click on the Digital clock applet.
2. Hover over Copy to clipboard

OBSERVED RESULT
All the entries in the menu show second to be 01. If you click on them, the copied time also reflects the second to be 01.

EXPECTED RESULT
The copied item should have the current second value.

SOFTWARE/OS VERSIONS
Linux: 6.1.24-1-lts (64-bit)
KDE Plasma Version: 5.27.4
KDE Frameworks Version: 5.105.0
Qt Version: 5.15.9
Comment 1 Nate Graham 2023-04-21 20:29:34 UTC
Are you using a locale that always shows the seconds, or are you using the "Show Seconds" setting in the config window? With en_US I don't see seconds in the menu items there unless I check the "Show seconds" checkbox.
Comment 2 Puspam Adak 2023-04-21 20:34:07 UTC
(In reply to Nate Graham from comment #1)
> Are you using a locale that always shows the seconds, or are you using the
> "Show Seconds" setting in the config window? With en_US I don't see seconds
> in the menu items there unless I check the "Show seconds" checkbox.

Yes, I have the time locale (LC_TIME) set to "C" which shows seconds.