Skip to main content



      Home
Home » Eclipse Projects » GEF » draw2d - setBackgroundPattern
draw2d - setBackgroundPattern [message #668368] Thu, 05 May 2011 09:01 Go to next message
Eclipse UserFriend
Hello all,

I have a problem with the

org.eclipse.draw2d.Graphics.setBackgroundPattern(Pattern pattern)

method.

I am using this mehod in the fillShape method of a draw2d figure in order to use an image as background:

g.setBackgroundPattern(new Pattern(Display.getDefault(),bgImage));


The image is displayed. However, depending on the coordinates/position of my figure in the editor, the background image is shifted:

http://img4web.com/tbnl/V6NCB5.png

Thank you!

Best regards,
Lukas



Re: draw2d - setBackgroundPattern [message #671838 is a reply to message #668368] Thu, 19 May 2011 02:55 Go to previous message
Eclipse UserFriend
Check with the Size of your Figure ... Might be it is clipping ... As there is no concept of image stretching in draw2d
Previous Topic:z-order of children edit parts
Next Topic:How to update GEF editor if file renamed?
Goto Forum:
  


Current Time: Sat Apr 26 21:21:42 EDT 2025

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

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

Back to the top