Some Eclipse Foundation services are deprecated, or will be soon. Please ensure you've read this important communication.
Bug 356374 - Public access to Win32 OS class (org.eclipse.swt.internal.win32.OS) for custom Windows component development
Summary: Public access to Win32 OS class (org.eclipse.swt.internal.win32.OS) for custo...
Status: CLOSED WONTFIX
Alias: None
Product: Platform
Classification: Eclipse Project
Component: SWT (show other bugs)
Version: 4.2   Edit
Hardware: PC Windows 7
: P3 enhancement (vote)
Target Milestone: ---   Edit
Assignee: Platform-SWT-Inbox CLA
QA Contact:
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2011-08-31 13:39 EDT by Fernando Colombo CLA
Modified: 2011-08-31 14:47 EDT (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Fernando Colombo CLA 2011-08-31 13:39:58 EDT
Build Identifier: swt-3.7-win32-win32-x86

We had a custom widget toolkit written in Delphi Object Pascal. It contained some unique widgets such as a special data grid, chart and graph utilities. These components were targeted to Windows, so they call many Windows APIs from GDI and USER libraries (RegisterClass, CreateWindow, BeginPaint, DrawText, etc).

We ported them to Java by using SWT OS class for API calls (org.eclipse.swt.internal.win32.OS). It worked very fine! We can even add our widgets to SWT forms! We have no plan to support other operating systems.

But we understand that the OS class is internal and is not meant to be part of SWT specification. This request is to make it public, so it at least appears on javadoc, just like org.eclipse.swt.ole.win32.OLE. There no need to actually explain API semantics and parameters - they just need to appear as public entities, so that they will be preserved on future releases.

There is also no need to add missing APIs. Since SWT can do almost any visual thing in Windows, the used APIs are enough. But we are afraid of using an API that is removed or changed for cleanup reasons.

Reproducible: Always
Comment 1 Felipe Heidrich CLA 2011-08-31 14:47:33 EDT
Sorry Fernando, I can't add OS to our API.

SWT is not in the business of native wrappers, maybe a better option for you is to write your own JNI code (best performance), or use JNA.


That said, it is very uncommon that we remove methods in OS.
Comment 2 Felipe Heidrich CLA 2011-08-31 14:47:52 EDT
closing.