|
@@ -129,6 +129,9 @@ func (m *Image) calculateSizes(width, height, ncount int) {
|
|
|
}
|
|
}
|
|
|
// Calculate dot size.
|
|
// Calculate dot size.
|
|
|
m.dotSize = int(nh / fh)
|
|
m.dotSize = int(nh / fh)
|
|
|
|
|
+ if m.dotSize < 1 {
|
|
|
|
|
+ m.dotSize = 1
|
|
|
|
|
+ }
|
|
|
// Save everything, making the actual width smaller by 1 dot to account
|
|
// Save everything, making the actual width smaller by 1 dot to account
|
|
|
// for spacing between digits.
|
|
// for spacing between digits.
|
|
|
m.numWidth = int(nw) - m.dotSize
|
|
m.numWidth = int(nw) - m.dotSize
|