Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » Connection line visible at PolygonDecoration arrow point
Connection line visible at PolygonDecoration arrow point [message #215548] Thu, 04 May 2006 18:32 Go to next message
Eclipse UserFriend
Originally posted by: ben.vitale.precipia.com

This is a multi-part message in MIME format.
--------------080405060600040608000305
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit

I've attached a screenshot of the behavior I'm about to describe.

I have a PolygonDecoration.TRIANGLE_TIP for my connection line target
decoration. If my connection line is of width 1, then the point of the
arrow looks perfect.

But if I set the connection width to a larger value (say, 8), then I can
start to see pieces of the connection line appear around the point of
the arrow. It is clear in the attached screenshot, where the arrow and
the connection line are different colors.

The only solution I can think of is..

1) Instead of a PolygonDecoration, use a figure with an endpointlocator
which is a square and then add a triangle-shaped child figure. The
square would be opaque (to cover the pieces of connection line that are
showing up), and the triangle would mimick the arrow decoration.

Are there other suggestions?

Thanks
Ben

--------------080405060600040608000305
Content-Type: image/gif;
name="arrowhead.GIF"
Content-Transfer-Encoding: base64
Content-Disposition: inline;
filename="arrowhead.GIF"

R0lGODlhCAF1APcAAAAAAIAAAACAAICAAAAAgIAAgACAgICAgMDAwP8AAAD/ AP//AAAA//8A
/wD//////wAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA AAAAAAAAAAAA
AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAMwAAZgAAmQAAzAAA/wAz AAAzMwAzZgAz
mQAzzAAz/wBmAABmMwBmZgBmmQBmzABm/wCZAACZMwCZZgCZmQCZzACZ/wDM AADMMwDMZgDM
mQDMzADM/wD/AAD/MwD/ZgD/mQD/zAD//zMAADMAMzMAZjMAmTMAzDMA/zMz ADMzMzMzZjMz
mTMzzDMz/zNmADNmMzNmZjNmmTNmzDNm/zOZADOZMzOZZjOZmTOZzDOZ/zPM ADPMMzPMZjPM
mTPMzDPM/zP/AD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AHYoHnXQWjghOQlaOGC GHbX34YRdkgd
gSD+sw0X2YkonYYgnhhDfioi92CJ1XARw4vQxXgciRtWg8ONOKao428sWkgN kDhUw+GQvX24
ISxIKhkik7rxCCGUN3KxDWPyUXlbkQoaAqSWkDHo5YDobShmlpVJOKSVBa4Z A4qVdTkkmP7J
SSdmZuropII23mgIaG52CCd+gcYwKGh2dohnei4KWlqfGM5YYKQxwJJaoQIe Kl6NQGqaWqMC
PooZNRUy5COQ97FGaYB/Ev+KQqoJHXljkrRxOp+np365EJYx4EobqfOZipmE aR4ELJnPvdqe
paRVeZAqY24pnq4e0gqaH7s5R5Ce+BHbnbGY9dYquP45y12soKlrW3joFoht ddqC9lsKWwC5
qILirgheau7iJumGAScHbbTBpbDvhvPuWG9nBeP2sH/9HkfusQaX+E/EvrHL 6HLegthwkxNz
NnK3JVbs3b+jUteqhRzndjBpJ5tbYs228cqZysCxbCRyF2NM3Xclpxezx6FN N4V1S79s4cg6
c8atckt/F7LGKjPhc2rJVT1FKk5rvLFvcSQLsMVMXy12QUzwFgcTsfXMtB9h r01QLrsxwUQu
sAX/7LXadh+USxy6xREH363x9nfdgRsUUdu3vR1Ra6/+3bhFEt2mt0StSUg0 3ZdfJBHhKBjO
eWqq2JbCC1aHntFEeu99emnVpICC7aC3debuvPeOAloo3CL88MQXb/zxyCev /PLMN+/889BH
L/30x/9+VvDbZK/99tx37/3335MG/vjklz9+NdVQox3wt5jv/vvZiw///PSj r771ZmFP//7b
y8///+Czn/rWd732AXB//jugArMnwPuxb4EIxMht5ALBCm6jgQPEX1j0lz1q TG1AqUiFBfsn
QdtQcIQKbCDYCJg/A3qwNyi01kUmeJYYLhCDA2ThBttXjfWkohodVEV0/2KY ERqaxYYpTJ/6
wMZEDYIFewyiRveq4YcRbsSIX0HiATGoClWE0IEF3MZ6tEjCIpowLGT8nwq7 +EXjPPA25oPj
9uSYPThSg0G5G8gE72gbsBVkglNzGuNykkYF5nCJIVyhE7+CvfVIkXx0rKNt 5mib1OXmZbex
JG4waUL5mO0fnwxKIQ84QCYmsonsqwYeyxfJbURykx0UDkE2KRD5pIqGWPzH Igk5yv8dkhps
PKUbC5i+9XwNFo/sXitf+a7tMShkt3lZFPV4xmnWcpc46aUvc5iKYJ4Sm1kJ nv3c1BwgUhIF
3GMmOrcnH2iecSCepKb14ikQbiFFm/z7pTATCf9OrIjTnC/MDSzOmc5Jaq+V upyVPA0iS4EY
0ZH/kM898Um/Q+6Tn6k0p/bU98FkLtOgklynDI2Yy4Tiz4jyCY9ERUnR/enz ov28yj+/t8qQ
FlSkrgTpQh36zp2aFJ6ynJpQWupSbl50mC1E3/eqQceP4hSOf3xnSUna0yj2 EShEzadFYZpR
8DUVpDY96CQJQs+fkvWqPNVgowbZkqwWtZRHjelUxCnC7/VRrDjN6VN7GtFK +vSaKGhVLiX2
E7dq1aj7lKtUxImCunLPkqrQXiA3qs6CBPKvoHwXZs3E1pUY9q2I5CoxhaO+ DtY0lo3Nnib3
GlglbeOZs9SsQGCL2S6b8fKzFd1qCJvTHMVGha5NSmb23NSlc0ortihDbkHK ahPcgvaOwuSt
b6Hyz/RZ5zZg854q+yhFdfJxQGGLJh7Dy9fLZtO583vpblPR266OsKQM5atF Gnpe9L5Pt4mU
rnshmFaGwJchtG2ufdOLX94idYdKrWB/F/LfhUD0JgMmMFxPqV9iavSAymWw fBnCXJdEOLeI
Za+IpwuSgAAAOw==
--------------080405060600040608000305--
Re: Connection line visible at PolygonDecoration arrow point [message #215593 is a reply to message #215548] Thu, 04 May 2006 20:19 Go to previous messageGo to next message
Steven R. Shaw is currently offline Steven R. ShawFriend
Messages: 128
Registered: July 2009
Senior Member
You could override fillShape on the PolygonDecoration to draw a background
colored square at the head of the polygon? fillShape gets called before
outlineShape so it would erase the area of the line before the arrow head
gets drawn.

-Steve

"Ben Vitale" <ben.vitale@precipia.com> wrote in message
news:e3dhbi$234$1@utils.eclipse.org...
> I've attached a screenshot of the behavior I'm about to describe.
>
> I have a PolygonDecoration.TRIANGLE_TIP for my connection line target
> decoration. If my connection line is of width 1, then the point of the
> arrow looks perfect.
>
> But if I set the connection width to a larger value (say, 8), then I can
> start to see pieces of the connection line appear around the point of
> the arrow. It is clear in the attached screenshot, where the arrow and
> the connection line are different colors.
>
> The only solution I can think of is..
>
> 1) Instead of a PolygonDecoration, use a figure with an endpointlocator
> which is a square and then add a triangle-shaped child figure. The
> square would be opaque (to cover the pieces of connection line that are
> showing up), and the triangle would mimick the arrow decoration.
>
> Are there other suggestions?
>
> Thanks
> Ben
>


------------------------------------------------------------ ----------------
----
Re: Connection line visible at PolygonDecoration arrow point [message #215616 is a reply to message #215548] Fri, 05 May 2006 13:48 Go to previous message
Eclipse UserFriend
Originally posted by: none.us.ibm.com

The best solution would be to not paint the line there, rather than erase
it. You could subclass polylineconnection and stop short of drawing the line
all the way, based on the decoration's needs. You could create an anchor
whichs returns a location further out, and then put the base of the triangle
at the end of the line instead of the tip.


"Ben Vitale" <ben.vitale@precipia.com> wrote in message
news:e3dhbi$234$1@utils.eclipse.org...
> I've attached a screenshot of the behavior I'm about to describe.
>
> I have a PolygonDecoration.TRIANGLE_TIP for my connection line target
> decoration. If my connection line is of width 1, then the point of the
> arrow looks perfect.
>
> But if I set the connection width to a larger value (say, 8), then I can
> start to see pieces of the connection line appear around the point of
> the arrow. It is clear in the attached screenshot, where the arrow and
> the connection line are different colors.
>
> The only solution I can think of is..
>
> 1) Instead of a PolygonDecoration, use a figure with an endpointlocator
> which is a square and then add a triangle-shaped child figure. The
> square would be opaque (to cover the pieces of connection line that are
> showing up), and the triangle would mimick the arrow decoration.
>
> Are there other suggestions?
>
> Thanks
> Ben
>
Previous Topic:Draw2d very large figures
Next Topic:Bypassing a figure for selection but not for a tooltip.
Goto Forum:
  


Current Time: Fri Jan 17 08:20:07 GMT 2025

Powered by FUDForum. Page generated in 0.03646 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top