[clock.py] Fix colours

This commit is contained in:
M1dgard 2018-08-19 01:54:30 +02:00
parent 5790bb6b72
commit 4f45e2f9ab
Signed by untrusted user who does not match committer: midgard
GPG key ID: 511C112F1331BBB4

View file

@ -26,7 +26,7 @@ try:
minute = minutehands[ t.minute // 5 ]
hour = hourhands [ t.hour % 12 ]
return color_for(t) + "%{T8}%{F#000}%{O-24}" + hour + "%{O-24}" + minute + "%{T-}%{F}"
return color_for(t) + "%{T8}%{F}%{F#000}%{O-24}" + hour + "%{O-24}" + minute + "%{T-}%{F}"
def color_for(t):
@ -51,20 +51,23 @@ try:
localcolor = color_for(localnow)
print(
localcolor +
localnow.strftime("%A") +
" " +
"%{F} " +
# face_for(leftnow) +
" %{T4}" + localcolor + localnow.strftime("%H") +
" %{T4}" + localcolor + localnow.strftime("%H") + "%{F}"
"%{O2}%{T8}" + face_for(localnow) +
"%{O2}%{T4}" + localcolor + localnow.strftime("%M") + "%{T-}" +
"%{O2}%{T4}" + localcolor + localnow.strftime("%M") + "%{T-}%{F}" +
" " +
# face_for(rightnow) + " " +
" " +
localnow.strftime("%d %b"),
localcolor +
localnow.strftime("%d %b") +
"%{F}",
flush = True
)