<?xml version="1.0" encoding="UTF-8" standalone="yes" ?>
<!DOCTYPE bugzilla SYSTEM "https://bugs.kde.org/page.cgi?id=bugzilla.dtd">

<bugzilla version="5.0.6"
          urlbase="https://bugs.kde.org/"
          
          maintainer="sysadmin@kde.org"
>

    <bug>
          <bug_id>415028</bug_id>
          
          <creation_ts>2019-12-10 20:31:02 +0000</creation_ts>
          <short_desc>Night colors doesn&apos;t support times later than 19:00 (24 hour format)</short_desc>
          <delta_ts>2023-01-01 02:44:18 +0000</delta_ts>
          <reporter_accessible>1</reporter_accessible>
          <cclist_accessible>1</cclist_accessible>
          <classification_id>2</classification_id>
          <classification>Applications</classification>
          <product>systemsettings</product>
          <component>kcm_nightlight</component>
          <version>5.17.4</version>
          <rep_platform>Other</rep_platform>
          <op_sys>Linux</op_sys>
          <bug_status>RESOLVED</bug_status>
          <resolution>FIXED</resolution>
          
          
          <bug_file_loc></bug_file_loc>
          <status_whiteboard></status_whiteboard>
          <keywords></keywords>
          <priority>NOR</priority>
          <bug_severity>normal</bug_severity>
          <target_milestone>---</target_milestone>
          
          
          <everconfirmed>1</everconfirmed>
          <reporter>tony.spegel</reporter>
          <assigned_to name="Plasma Bugs List">plasma-bugs-null</assigned_to>
          <cc>clarjon1</cc>
    
    <cc>dchmelik</cc>
    
    <cc>kde</cc>
    
    <cc>kwin-bugs-null</cc>
    
    <cc>mrfrh</cc>
    
    <cc>nate</cc>
    
    <cc>null</cc>
          
          <cf_commitlink>https://invent.kde.org/plasma/plasma-workspace/commit/66a8c134277791c53bc212578e4979f4db171f83</cf_commitlink>
          <cf_versionfixedin>5.26.5</cf_versionfixedin>
          <cf_sentryurl></cf_sentryurl>
          <votes>0</votes>

      

      

      

          <comment_sort_order>oldest_to_newest</comment_sort_order>  
          <long_desc isprivate="0" >
    <commentid>1895839</commentid>
    <comment_count>0</comment_count>
    <who name="">tony.spegel</who>
    <bug_when>2019-12-10 20:31:02 +0000</bug_when>
    <thetext>SUMMARY


STEPS TO REPRODUCE
1. Open Night color settings
2. Select mode &apos;Times&apos;
3. Try setting a time like 20:15

OBSERVED RESULT
You can&apos;t select such a time

EXPECTED RESULT
Being able to set a time later than 19:00

SOFTWARE/OS VERSIONS
Linux/KDE Plasma: 
(available in About System)
KDE Plasma Version: 5.17.4
KDE Frameworks Version: 5.64.0
Qt Version: 5.13.2</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1902690</commentid>
    <comment_count>1</comment_count>
    <who name="Nate Graham">nate</who>
    <bug_when>2020-01-15 00:01:55 +0000</bug_when>
    <thetext>Time input using those text fields is generally quite borked. :/</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1913181</commentid>
    <comment_count>2</comment_count>
    <who name="Nate Graham">nate</who>
    <bug_when>2020-02-26 18:58:28 +0000</bug_when>
    <thetext>*** Bug 418209 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>1986153</commentid>
    <comment_count>3</comment_count>
    <who name="Nate Graham">nate</who>
    <bug_when>2020-12-17 21:08:33 +0000</bug_when>
    <thetext>*** Bug 428589 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2059931</commentid>
    <comment_count>4</comment_count>
    <who name="David Edmundson">kde</who>
    <bug_when>2021-09-09 15:50:19 +0000</bug_when>
    <thetext>*** Bug 429053 has been marked as a duplicate of this bug. ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2059932</commentid>
    <comment_count>5</comment_count>
    <who name="David Edmundson">kde</who>
    <bug_when>2021-09-09 15:50:36 +0000</bug_when>
    <thetext>

*** This bug has been marked as a duplicate of bug 413010 ***</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2189586</commentid>
    <comment_count>6</comment_count>
    <who name="mrfrh">mrfrh</who>
    <bug_when>2022-12-27 20:42:26 +0000</bug_when>
    <thetext>Reopened, as this is actually NOT a duplicate of https://bugs.kde.org/show_bug.cgi?id=413010 (which is only about time format).

I just wanted to report this issue myself as it could be very annoying to new users. Living in a 24hr-Timezone, you can&apos;t set a night color start time later than 19:00.

There seems to be a problem with the time input field:
1. open night color settings
2. select mode &quot;individual times&quot;
3. you can&apos;t enter any start time starting with two (e.g. 22:00), only times starting with one or zero (e.g. 19:00)
4. workaround: type 22:00 in a text editor and copy it --&gt; 22:00 can be pasted in the input field.

Sometimes it also worked to at first try input a time starting with 1, then at second try it was possible to enter a time starting with 2. But I couldn&apos;t reproduce this reliably.

In fact the regex in /usr/share/kpackage/kcms/kcm_nightcolor/contents/ui/TimeField.qml looks correct (/^([0-1]?[0-9]|2[0-3]):[0-5][0-9]$/), so I&apos; don&apos;t know what&apos;s the root cause of this issue :-(</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2189587</commentid>
    <comment_count>7</comment_count>
    <who name="mrfrh">mrfrh</who>
    <bug_when>2022-12-27 20:48:17 +0000</bug_when>
    <thetext>Sorry, forgot to specify up to date software versions:

SOFTWARE/OS VERSIONS
KDE Plasma Version: 5.26.4
KDE Frameworks Version: 5.101.0
Qt Version: 5.15.7</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2190994</commentid>
    <comment_count>8</comment_count>
    <who name="mrfrh">mrfrh</who>
    <bug_when>2022-12-31 14:39:17 +0000</bug_when>
    <thetext>I figured out that the problem is the &quot;or&quot;-part of the regex, this could be an underlying Qt Bug. 
Fortunately there seems to be an easy workaround, as the regex attempt here is more complicated than necessary. 
I&apos;ll try to submit a bugfix.</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2190996</commentid>
    <comment_count>9</comment_count>
    <who name="Bug Janitor Service">bug-janitor</who>
    <bug_when>2022-12-31 14:53:41 +0000</bug_when>
    <thetext>A possibly relevant merge request was started @ https://invent.kde.org/plasma/plasma-workspace/-/merge_requests/2465</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2191082</commentid>
    <comment_count>10</comment_count>
    <who name="Fushan Wen">qydwhotmail</who>
    <bug_when>2023-01-01 02:42:24 +0000</bug_when>
    <thetext>Git commit be56079c4bff876d8c889abe99bfe46dd4004d67 by Fushan Wen, on behalf of Martin Frueh.
Committed on 01/01/2023 at 02:39.
Pushed by fusionfuture into branch &apos;master&apos;.

Fix time input bug caused by &quot;or&quot; in regex

Removed or-condition in regex, Qt.ImhTime can take care of this.
FIXED-IN: tbd

M  +2    -2    kcms/nightcolor/package/contents/ui/TimeField.qml

https://invent.kde.org/plasma/plasma-workspace/commit/be56079c4bff876d8c889abe99bfe46dd4004d67</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2191083</commentid>
    <comment_count>11</comment_count>
    <who name="Fushan Wen">qydwhotmail</who>
    <bug_when>2023-01-01 02:43:19 +0000</bug_when>
    <thetext>Git commit 3059f250d7d07ad04f667ade017b67c8bcd34c14 by Fushan Wen, on behalf of Martin Frueh.
Committed on 01/01/2023 at 02:43.
Pushed by fusionfuture into branch &apos;cherry-pick-be56079c&apos;.

Fix time input bug caused by &quot;or&quot; in regex

Removed or-condition in regex, Qt.ImhTime can take care of this.
FIXED-IN: tbd

(cherry picked from commit be56079c4bff876d8c889abe99bfe46dd4004d67)

M  +2    -2    kcms/nightcolor/package/contents/ui/TimeField.qml

https://invent.kde.org/plasma/plasma-workspace/commit/3059f250d7d07ad04f667ade017b67c8bcd34c14</thetext>
  </long_desc><long_desc isprivate="0" >
    <commentid>2191084</commentid>
    <comment_count>12</comment_count>
    <who name="Fushan Wen">qydwhotmail</who>
    <bug_when>2023-01-01 02:44:18 +0000</bug_when>
    <thetext>Git commit 66a8c134277791c53bc212578e4979f4db171f83 by Fushan Wen.
Committed on 01/01/2023 at 02:44.
Pushed by fusionfuture into branch &apos;Plasma/5.26&apos;.

Fix time input bug caused by &quot;or&quot; in regex

Removed or-condition in regex, Qt.ImhTime can take care of this.
FIXED-IN: 5.26.5

(cherry picked from commit be56079c4bff876d8c889abe99bfe46dd4004d67)

M  +2    -2    kcms/nightcolor/package/contents/ui/TimeField.qml

https://invent.kde.org/plasma/plasma-workspace/commit/66a8c134277791c53bc212578e4979f4db171f83</thetext>
  </long_desc>
      
      

    </bug>

</bugzilla>