commit
dd0f48eebe
3 changed files with 5 additions and 2 deletions
|
|
@ -44,6 +44,9 @@ func (diagram Diagram) HashID() (string, error) {
|
|||
}
|
||||
|
||||
func (diagram Diagram) BoundingBox() (topLeft, bottomRight Point) {
|
||||
if len(diagram.Shapes) == 0 {
|
||||
return Point{0, 0}, Point{0, 0}
|
||||
}
|
||||
x1 := int(math.MaxInt64)
|
||||
y1 := int(math.MaxInt64)
|
||||
x2 := int(-math.MaxInt64)
|
||||
|
|
|
|||
|
|
@ -2,7 +2,7 @@
|
|||
<svg
|
||||
style="background: white;"
|
||||
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||
width="202" height="202" viewBox="9223372036854775707 9223372036854775707 202 202"><style type="text/css">
|
||||
width="200" height="200" viewBox="-100 -100 200 200"><style type="text/css">
|
||||
<![CDATA[
|
||||
.shape {
|
||||
shape-rendering: geometricPrecision;
|
||||
|
|
|
|||
|
Before Width: | Height: | Size: 526 B After Width: | Height: | Size: 496 B |
|
|
@ -2,7 +2,7 @@
|
|||
<svg
|
||||
style="background: white;"
|
||||
xmlns="http://www.w3.org/2000/svg" xmlns:xlink="http://www.w3.org/1999/xlink"
|
||||
width="202" height="202" viewBox="9223372036854775707 9223372036854775707 202 202"><style type="text/css">
|
||||
width="200" height="200" viewBox="-100 -100 200 200"><style type="text/css">
|
||||
<![CDATA[
|
||||
.shape {
|
||||
shape-rendering: geometricPrecision;
|
||||
|
|
|
|||
|
Before Width: | Height: | Size: 526 B After Width: | Height: | Size: 496 B |
Loading…
Reference in a new issue