Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » Draw a border around an ellipse figure
Draw a border around an ellipse figure [message #152044] Sun, 26 September 2004 15:23 Go to next message
Eclipse UserFriend
Originally posted by: paolino125.hotmail.com

Hi, what I have to do to paint a border around an ellipse and not around the
rectangle which contains the ellipse?

Thanks!
Re: Draw a border around an ellipse figure [message #152050 is a reply to message #152044] Sun, 26 September 2004 15:59 Go to previous messageGo to next message
Alex Selkov is currently offline Alex SelkovFriend
Messages: 73
Registered: July 2009
Member
"funky79" <paolino125@hotmail.com>
Re: Draw a border around an ellipse figure [message #152053 is a reply to message #152050] Sun, 26 September 2004 16:11 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: paolino125.hotmail.com

Ok, it works!! Thanks a lot!

"Alex Selkov" <as@empproject.com> ha scritto nel messaggio
news:1096214192.117122@builder.empproject.com...
>
> "funky79" <paolino125@hotmail.com>
Re: Draw a border around an ellipse figure [message #228752 is a reply to message #152053] Tue, 09 January 2007 15:34 Go to previous messageGo to next message
Eclipse UserFriend
Originally posted by: spam.rosis-fotos.de

I know, that this thread is very old, but i need a border around an ellipse-figure too.

Is it possible to modify a SimpleRaisedBorder, so that it works with an ellipse?

Regards,

Martin
Re: Draw a border around an ellipse figure [message #228800 is a reply to message #228752] Wed, 10 January 2007 10:37 Go to previous messageGo to next message
Manuel Selva is currently offline Manuel SelvaFriend
Messages: 189
Registered: July 2009
Location: Grenoble, France
Senior Member
Hi,

Of course you can. You should override the paint method coming from
SchemeBorder class and draw an oval instead of drawing lines to represent
a rectangle which size are excatly the bounds of the ellipse.

You can also override the outlineShape method of the Ellipse class to draw
your own border.

You should be aware that it quite be quite difficult to draw a nice
border. May be you ll have to draw it sometimes using the drawpoint method
of graphics class ...

Hope this can help you

Manu


Re: Draw a border around an ellipse figure [message #228990 is a reply to message #228800] Fri, 12 January 2007 14:22 Go to previous message
Eclipse UserFriend
Originally posted by: spam.rosis-fotos.de

Hey thanks,

overriding the outlineshape(Graphic) method was a very good idea.

Regards Martin
Previous Topic:Draw2D zooming
Next Topic:GEF Containment editPart
Goto Forum:
  


Current Time: Thu Apr 25 16:12:20 GMT 2024

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

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

Back to the top