chiark
/
gitweb
/
~ianmdlvl
/
otter.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
5a20c01
)
clock: Explain why separate rendering with abs positions
author
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Sun, 12 Jun 2022 22:43:12 +0000
(23:43 +0100)
committer
Ian Jackson
<ijackson@chiark.greenend.org.uk>
Sun, 12 Jun 2022 22:43:29 +0000
(23:43 +0100)
Signed-off-by: Ian Jackson <ijackson@chiark.greenend.org.uk>
src/clock.rs
patch
|
blob
|
history
diff --git
a/src/clock.rs
b/src/clock.rs
index bd042565b18e48ba8d5e32a069b986d6789b2bd5..67ea4590db4bbdd4bcffff0ba2baa31ebcd00d2d 100644
(file)
--- a/
src/clock.rs
+++ b/
src/clock.rs
@@
-504,6
+504,8
@@
impl PieceTrait for Clock {
y, font, Html::lit(show.text),
mins_pad, HtmlStr::from_html_str(&mins), Html::lit(show.sigil)
)?;
+ // We write this separately because, empirically, not all the
+ // sigil characters have the same width, even in a mono font.
hwrite!(f, r##"
<{} x="14" y="{}" {} fill="{}" >{:02}</text>"##,
HTML_TEXT_LABEL_ELEM_START,