Someone on a java.net thread was asking if Pivot supported native L&F. I 
explained that we intentionally don't support that because it is too much of a 
moving target, etc. But it got me thinking that we (or someone, anyways) could 
theoretically create a theme that is backed by native components (for example, 
via SWT). The fact that we pass a Graphics2D object to our paint() method 
doesn't really matter in that case since those components are painted by the 
native peer anyways. We wouldn't be able to use decorators since those rely on 
Java2D, but there are ways around that (such as providing our own graphics 
abstraction, which is something we have talked about in the past).

Basically, every skin would have a native peer. Layout containers could simply 
use an empty container peer and just perform layout on the native children. 
Navigation containers could just use the native equivalent. If a native 
equivalent doesn't exist, that component just wouldn't be supported (or could 
be emulated, if a Pivot-native graphics API existed).

I think it is an interesting idea. This would allow developers to use Pivot to 
build applications that could be deployed via Eclipse RCP as well as our 
existing application contexts. It would work on Android and iPhone as well, 
assuming that Java can be made to run there (which, based on some recent 
announcements, seems possible).

I'm curious to know what others think about this idea.

G

Reply via email to