Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » GEF » Can Editor use a picture(ex, jpeg) as its background
Can Editor use a picture(ex, jpeg) as its background [message #166480] Tue, 01 February 2005 11:13 Go to next message
zhangbw is currently offline zhangbwFriend
Messages: 26
Registered: July 2009
Junior Member
Hello everyone,

What i want to realize is:

my editor use a special picture(for example, a jpeg picture) as its
background. Currently its background is "ColorConstants.white"

I really don't know how to, is it relevant to gef rootEditPart & Layers?


Thanks in advance,
zbw
Re: Can Editor use a picture(ex, jpeg) as its background [message #166730 is a reply to message #166480] Wed, 02 February 2005 23:30 Go to previous messageGo to next message
Pratik Shah is currently offline Pratik ShahFriend
Messages: 1077
Registered: July 2009
Senior Member
Yes, this is possible. How exactly depends on what you want to do. Do you
want your picture to stay stationary in the background? Or you want it to
stretch or tile to fill the entire layer (and so the background would scroll
when the viewer scrolls)? For the former, you can paint the image in the
root editpart's viewport's paintFigure() method. For the latter, you can
paint it on one of the layers.

"zbw" <zbw001091@yahoo.com.cn> wrote in message
news:ctno90$4be$1@www.eclipse.org...
> Hello everyone,
>
> What i want to realize is:
>
> my editor use a special picture(for example, a jpeg picture) as its
> background. Currently its background is "ColorConstants.white"
>
> I really don't know how to, is it relevant to gef rootEditPart & Layers?
>
>
> Thanks in advance,
> zbw
>
Re: Can Editor use a picture(ex, jpeg) as its background [message #166799 is a reply to message #166730] Thu, 03 February 2005 09:20 Go to previous message
zhangbw is currently offline zhangbwFriend
Messages: 26
Registered: July 2009
Junior Member
Thank you, Pratik Shah
I'll try on your advice

zbw
Previous Topic:SnapToGuides.KEY_VERTICAL_GUIDE never set in >>request.getExtendedData()<<
Next Topic:Figure not displaying in viewer ?
Goto Forum:
  


Current Time: Thu Apr 25 04:01:16 GMT 2024

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

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

Back to the top