From: villberg Date: Thu, 20 Oct 2011 12:24:20 +0000 (+0000) Subject: git-svn-id: https://www.simantics.org/svn/simantics/sysdyn/trunk@22893 ac1ea38d-2e2b... X-Git-Tag: simantics-1.5~4 X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=commitdiff_plain;h=1a12e844171d3f3f6a279206d1c190645ab3c532;p=simantics%2Fsysdyn.git git-svn-id: https://www.simantics.org/svn/simantics/sysdyn/trunk@22893 ac1ea38d-2e2b-0410-8846-a27921b304fc --- diff --git a/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/elements2/HoverTextNode.java b/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/elements2/HoverTextNode.java index ef8bab71..b01d5136 100644 --- a/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/elements2/HoverTextNode.java +++ b/org.simantics.sysdyn.ui/src/org/simantics/sysdyn/ui/elements2/HoverTextNode.java @@ -46,13 +46,13 @@ public class HoverTextNode extends TextNode implements ISelectionPainterNode { Color oldColor = g.getColor(); g.setColor(Color.LIGHT_GRAY); g.setStroke(new BasicStroke((float)(2.0f))); - g.translate(x, y); g.scale(scale, scale); - g.draw(expandBoundsUnscaled(getTextBounds())); + g.translate(x, y); + g.draw(expandBoundsUnscaled(alignBounds(getTextBounds()))); g.translate(-x, -y); + g.scale(scaleRecip, scaleRecip); g.setColor(oldColor); g.setStroke(oldStroke); - g.scale(scaleRecip, scaleRecip); }