Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Remote Application Platform (RAP) » Overlaying Images in RAP
Overlaying Images in RAP [message #124525] Fri, 13 March 2009 15:09 Go to next message
Bastian is currently offline BastianFriend
Messages: 7
Registered: July 2009
Junior Member
Hello,
I want to realize Icon decorators.
I used the following Tutorial as base:
http://www.eclipse.org/articles/Article-Decorators/decorator s.html

I wrote a class, which implements the interface "ILabelDecorator".

In the implementation of the method "public Image decorateImage(Image
image, Object element)" I got the following situation:

- image is my baseImage.
- element contains my decorator icons. I can get it via setters.

I tried to implement a solution from the tutorial, which creates class,
which implements the interface "CompositeImageDescriptor". The class can
overlay Images.

The Problem:
------------
The getImageData() method makes problems in RAP. It works fine in RCP.
ImageData baseImageData = this.baseImage.getImageData();

The following error is displayed on my import:
Eclipse changes the import automatically from
"import org.eclipse.swt.graphics.ImageData;"
to
"import org.eclipse.swt.internal.graphics.ImageData;"

with the warning "Discouraged access: The type ImageData is not accessible
due to restriction on required library
/pathToLibs/org.eclipse/org.eclipse.rap.rwt.jar"

-> So I cannot use this implementation. Why is there restricted accecss?

-> Is there any other possibility in RAP to generate decorated icons
dynamically?

Thanks, Bastian
Re: Overlaying Images in RAP solution [message #124739 is a reply to message #124525] Mon, 16 March 2009 12:47 Go to previous message
Bastian is currently offline BastianFriend
Messages: 7
Registered: July 2009
Junior Member
Finally I found out by my self, how to solve the problem:
http://www.eclipse.org/rap/noteworthy/news_11.php#Workbench
Previous Topic:Text and CUSTOM_VARIANT does not set background
Next Topic:Redirection with parameters
Goto Forum:
  


Current Time: Mon Dec 06 21:46:50 GMT 2021

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

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

Back to the top