diff --git a/ui/allg5ui/font.go b/ui/allg5ui/font.go index e767b27..1a4b8cf 100644 --- a/ui/allg5ui/font.go +++ b/ui/allg5ui/font.go @@ -34,7 +34,7 @@ func (f *font) Height() float32 { } func (f *font) WidthOf(t string) float32 { - return f.Measure(t).Dx() + return f.f.TextWidth(t) } func (f *font) Measure(t string) geom.RectangleF32 {