[
Date Prev][
Date Next][
Thread Prev][
Thread Next][
Date Index][
Thread Index]
[
List Home]
[platform-swt-dev] Re: Mac OS X Port
|
In the last couple of months I tried various approaches
of porting SWT to the MacOS X (and last year even for OS 9).
Right now I don't have the time to brain-dump every detail of my experiences
but here are just some findings I found important:
- Whatever you do try to get SWT's event model right first:
SWT applications have an event loop! The loop polls for (OS) events and
dispatches them. However, OS-events are opaque and cannot be interpreted
by an SWT application. But SWT is definitely in control when
processing events.
This makes it hard to use any high-level toolkit where you have no access
to the low level event processing but only callbacks.
(I was not able to implement SWT on top of AWT!).
- SWT widgets seem to reflect some details of the Windows contols.
For instance some
controls (tree, text) inherit from Composite and Scrollable, but it
is not possible
to add child controls, and scrolling isn't implemented by the base
class but comes from the native widget. As a consequence it is
sometimes hard to map the
SWT class hierarchy to widgets coming from a class hierachy with a different
inheritence structure.
On the other hand some things should be simple:
- SWT has a native text widget but the full fledged text editor is based on
SWT's own pure-Java implementation of a text widget.
- a pure-Java implementation of a tree (and a tree table) exists too.
--andre