Skip to content
This repository was archived by the owner on Jul 29, 2019. It is now read-only.

Commit dd3639f

Browse files
chontonmojoaxel
authored andcommitted
decrease whitespace in ellipses having long text
1 parent adedd6a commit dd3639f

File tree

1 file changed

+2
-5
lines changed
  • lib/network/modules/components/nodes/shapes

1 file changed

+2
-5
lines changed

lib/network/modules/components/nodes/shapes/Ellipse.js

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,11 +11,8 @@ class Ellipse extends NodeBase {
1111
if (this.width === undefined) {
1212
var textSize = this.labelModule.getTextSize(ctx, selected);
1313

14-
this.width = textSize.width * 1.5;
1514
this.height = textSize.height * 2;
16-
if (this.width < this.height) {
17-
this.width = this.height;
18-
}
15+
this.width = textSize.width + this.height;
1916
this.radius = 0.5*this.width;
2017
}
2118
}
@@ -82,4 +79,4 @@ class Ellipse extends NodeBase {
8279
}
8380
}
8481

85-
export default Ellipse;
82+
export default Ellipse;

0 commit comments

Comments
 (0)