Gtk peer access with CNI
Tom Tromey
tromey@redhat.com
Sat May 21 00:30:00 GMT 2005
>>>>> "Sandor" == Sandor Bodo-Merle <sbodomerle@gmail.com> writes:
Sandor> can someone point me how to access the GtkWidget of a peer
Sandor> component from a native method? I figured it out how to do
Sandor> this via JNI but i cant see how to do it with CNI. I
Sandor> appreciate any hints.
You could do it pretty much the same way, I think. Just access the
private fields of the peers. But, I would recommend against it.
This isn't supported, and will probably break. For one thing we are
most likely going to BC-compile AWT, Swing, and the peers, and CNI and
BC don't really work that well together (yet).
There is also the 'libjawt' stuff; this is a portable way to access
the underlying rendering surface of the awt peers.
Tom
More information about the Java
mailing list