Label Location

How do I move (set the location) of a link label? I am doing this but it always puts the label in the middle of the link.
Point pnt = new Point(rll.getX(), rll.getY());
link.getMidLabel().setLocation(pnt);

Thanks.

You need to override one of the JGoLabeledLink methods (layoutMidLabel or positionMidLabel) that normally maintains the position of the MidLabel.
The FlowLink class in the Processor example does this, to let the user drag that label around.

So will set location call the overridden method? (It doesn’t seem to) I didn’t see anything in the processor project that actually sets this so how do I actually get it to update?

FlowLink.positionMidLabel calls JGoObject.setSpotLocationOffset (which is a variant of JGoObject.setLocation) to position the label where the FlowLabel thinks it should be relative to the link.
That way when the link’s path is recalculated, FlowLink.positionMidLabel will reposition the FlowLabel according to its guidelines.
To allow the user to move the FlowLabel around manually, ProcessView overrides moveSelection so as to update the FlowLabel’s properties, which can be used later when needed by FlowLink.positionMidLabel.