Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.

Bug 317439

Summary: Support for IMAGE_GRAY and IMAGE_DISABLE
Product: [RT] RAP Reporter: Benjamin Muskalla <b.muskalla>
Component: RWTAssignee: Project Inbox <rap-inbox>
Status: RESOLVED FIXED QA Contact:
Severity: enhancement    
Priority: P3 CC: kRusspamadresse, rsternberg
Version: 1.3   
Target Milestone: 3.0 M4   
Hardware: All   
OS: All   
Whiteboard:
Bug Depends on:    
Bug Blocks: 262787    
Attachments:
Description Flags
Patched Image class to add support for IMAGE_GRAY and IMAGE_DISABLED
none
SWT class change adding two constants IMAGE_GRAY and IMAGE_DISABLED none

Description Benjamin Muskalla CLA 2010-06-21 09:27:23 EDT
Currently we miss the two styles for creating new images. We refer to them in the JavaDoc of Image(Device, Image, int) and they are used in several applications.
Comment 1 Ralf Sternberg CLA 2012-12-05 04:36:07 EST
These style flags modify images using native calls, which is not possible in RAP. However, decolorizing images could be simple operation on the image data.
Contributions are welcome here...
Comment 2 Johannes 'kRu' Mising name CLA 2014-06-22 03:43:08 EDT
As far as I can see, SWT is not using native calls anymore. This means that the SWT code for IMAGE_GRAY and IMAGE_DISABLED can used in RAP with two lines changed.  I'll append a patch for this.
Comment 3 Johannes 'kRu' Mising name CLA 2014-06-22 03:44:38 EDT
Created attachment 244406 [details]
Patched Image class to add support for IMAGE_GRAY and IMAGE_DISABLED

Copied from original SWT
Comment 4 Johannes 'kRu' Mising name CLA 2014-06-22 03:45:56 EDT
Created attachment 244407 [details]
SWT class change adding two constants IMAGE_GRAY and IMAGE_DISABLED

Copied from original SWT. May need to add @Since annotation.
Comment 5 Ralf Sternberg CLA 2014-06-23 04:23:51 EDT
Thanks for your contribution! Would you mind to push your change directly to Gerrit [1]? You'll have to sign your CLA [2] in order to get it approved.

[1] See https://www.eclipse.org/rap/source/
[2] https://wiki.eclipse.org/CLA
Comment 6 Ivan Furnadjiev CLA 2014-11-25 04:41:20 EST
Implemented with change https://git.eclipse.org/r/#/c/36977/.