This commit is contained in:
twocookedfaggots committed 2026-06-21 01:18:50 +03:00
1 parent afd438930e
commit 445a6aab94
21 files changed
+70 -73

No files matched your search

+21 -23
View File
@@ -10,29 +10,27 @@ var (
func main() {
flag.Parse()
f, err := truetype.Parse(gomono.TTF)
if err != nil {
panic(err)
}
face := truetype.NewFace(f, &truetype.Options{
Size: float64(img.Bounds().Dx() / size),
DPI: 72,
Hinting: font.HintingNone,
})
if err != nil {
panic(err)
}
face := truetype.NewFace(f, &truetype.Options{
Size: float64(img.Bounds().Dx() / size),
DPI: 72,
Hinting: font.HintingNone,
})
d := &font.Drawer{
Dst: dst,
Src: image.NewUniform(color.Black),
Face: face,
Dot: fixed.Point26_6{fixed.Int26_6(img.Bounds().Dx() /
x,
),
fixed.Int26_6(img.Bounds().Dy() /
y,
),
},
}
d.DrawString(time.Now().Format(time.Kitchen))
d := &font.Drawer{
Dst: dst,
Src: image.NewUniform(color.Black),
Face: face,
Dot: fixed.Point26_6{fixed.Int26_6(img.Bounds().Dx() /
x,
),
fixed.Int26_6(img.Bounds().Dy() /
y,
),
},
}
d.DrawString(time.Now().Format(time.Kitchen))
}