Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 324301

Summary: Label position incorrect for curved connections
Product: [Tools] GEF Reporter: Mike Wrighton <mike.wrighton>
Component: GEF-Legacy ZestAssignee: gef-inbox <gef-inbox>
Status: NEW --- QA Contact:
Severity: normal    
Priority: P3 CC: plasticfloor, szabta89, zoltan.ujhelyi
Version: unspecified   
Target Milestone: ---   
Hardware: PC   
OS: Linux   
Whiteboard:
Attachments:
Description Flags
MidpointLocator path none

Description Mike Wrighton CLA 2010-09-02 08:55:56 EDT
Build Identifier: M20090917-0800

The position of Labels in curved connections is not at the midpoint where it should be. This is because the MidpointLocator class will only return the midpoint between 2 points and a PolylineArcConnection contains several.

Reproducible: Always
Comment 1 Tamas Szabo CLA 2013-06-26 07:46:31 EDT
What is the status of this issue? This is still reproducible. At least the Locator should be customizable (with a setter) for the Connection.
Comment 2 Zoltan Ujhelyi CLA 2013-06-26 09:00:59 EDT
As far as I know, nobody has started working on this issue. If you are interested, and provide some solution, we can try to find a way to integrate it.
Comment 3 Tamas Szabo CLA 2013-06-28 10:01:46 EDT
Created attachment 232883 [details]
MidpointLocator path

The MidpointLocator implementation in the patch computes the reference point between the given index and the last point in the point list. As far as I know only the BendpointCreationHandle invokes the constructor with a custom index, all other occurrences sets the index to 0. In my opinion it makes sense to use the last point, but this should be verified.
Comment 4 Tamas Szabo CLA 2013-07-08 10:41:12 EDT
Can somebody provide me feedback about this issue? Will the fix be applied / new one will be created / etc?
Comment 5 Zoltan Ujhelyi CLA 2013-07-08 13:51:20 EDT
(In reply to comment #3)
> Created attachment 232883 [details]
> MidpointLocator path
> 
> The MidpointLocator implementation in the patch computes the reference point
> between the given index and the last point in the point list. As far as I
> know only the BendpointCreationHandle invokes the constructor with a custom
> index, all other occurrences sets the index to 0. In my opinion it makes
> sense to use the last point, but this should be verified.

Sorry for the late answer.

One of my basic "problems" is that I am not "qualified" to accept this patch, as this change reflects Draw2D instead of Zest, and that can have more serious consequences (e.g. all GEF, GMF and Graphiti-based editors might also be affected), so someone else is needed.

Is it not possible to change this behavior in a way that only changes Zest?