Skip to content

Commit

Permalink
vg/vgsvg: fix font size handling again
Browse files Browse the repository at this point in the history
  • Loading branch information
kortschak committed Jan 24, 2019
1 parent 1528760 commit 5260e11
Show file tree
Hide file tree
Showing 6 changed files with 44 additions and 44 deletions.
20 changes: 10 additions & 10 deletions plotter/testdata/polygon_holes_golden.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 8 additions & 8 deletions vg/testdata/width_-1.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 8 additions & 8 deletions vg/testdata/width_0.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
16 changes: 8 additions & 8 deletions vg/testdata/width_1.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
18 changes: 9 additions & 9 deletions vg/vgsvg/testdata/scatter_golden.svg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion vg/vgsvg/vgsvg.go
Original file line number Diff line number Diff line change
Expand Up @@ -296,7 +296,7 @@ func (c *Canvas) FillString(font vg.Font, pt vg.Point, str string) {
panic(fmt.Sprintf("Unknown font: %s", font.Name()))
}
sty := style(fontStr,
elm("font-size", "medium", "%.*g", pr, font.Size.Points()),
elm("font-size", "medium", "%.*gpx", pr, font.Size.Points()),
elm("fill", "#000000", colorString(c.context().color)))
if sty != "" {
sty = "\n\t" + sty
Expand Down

0 comments on commit 5260e11

Please sign in to comment.