Thread: RE: [Java-gnome-developer] Gnome Library
Brought to you by:
afcowie
From: Jeffrey M. <Jef...@Br...> - 2003-06-02 12:29:25
|
I am not completely sure I understand the first question so I will ramble on a little and hope I hit the mark. The GNOME desktop environment is built upon a collection/stack of libraries. There is no need to use every library in the collection but you must support dependent libraries. Perhaps an example will demonstrate. The core gnome stack looks like the following (I am leaving out numerous libs for simplicity sake): libgnomeui & libgnome GTK ATK & Pango glib If you are going to write an application using libgnomeui then you must use GTK. This is also true in Java-GNOME. Now to attempt to answer your first question; you cannot use GNOME with SWT. The GTK2 flavor of SWT is simply a wrapper around a subset of the GTK widgets. It includes no support for GNOME except the inherent support that is there since they are both using the same widget toolkit. SWT is a windowing toolkit that provides a cross platform widget set that utilizes the native widget set on a platform where available. Where those widgets are not available it provides its' own implementation. Java-GNOME is a language binding for the GNOME desktop environment. There is no attempt to provide cross platform capabilities. Since the focus is on GNOME there is very tight integration with that desktop environment which doesn't exist in SWT. Which to use? If you want to write a cross platform Java UI I would recommend SWT. If you want to write an Java UI that targets the GNOME desktop environment I would use Java-GNOME. -Jeff -----Original Message----- From: Gabriele Erba [mailto:nz...@ga...] Sent: Sunday, June 01, 2003 5:58 AM To: java-gnome-developers Subject: [Java-gnome-developer] Gnome Library Hi, I'm Gabriele Erba from Milan, Italy. Fist of all I'm sorry for my little english. This is the fist time I post in this mailing-list. I'm used to develop with SWT for creating java application with native look&fell. I have two question: Is it possibile use gnome library with SWT without using Gtk library ? If this is true what are the advantages of Gtk library in comparison with SWT ? Thanks very much. ---- Gabriele Erba Audendum est: fortes adiuvat ipsa Venus (Tibullo) www.gabriele-erba.it ------------------------------------------------------- This SF.net email is sponsored by: eBay Get office equipment for less on eBay! http://adfarm.mediaplex.com/ad/ck/711-11697-6916-5 _______________________________________________ java-gnome-developer mailing list jav...@li... https://lists.sourceforge.net/lists/listinfo/java-gnome-developer |
From: <fer...@lo...> - 2003-06-02 22:37:30
|
Hi, > I'm used to develop with SWT for creating java application with native > look&fell. > I have two question: > Is it possibile use gnome library with SWT without using Gtk library ? > If this is true what are the advantages of Gtk library in comparison with > SWT ? SWT on Unix uses either Motif or SWT. If you run under Linux and get "native" look and feel you are using GTK already. Gnome is based on GTK. So there's no way to get Gnome features and not using GTK. You can put a layer of software above Gnome and GTK, but not discarding GTK. SWT uses GTK but has no other features for gnome integration. If you need this, you need to expand SWT to use more Gnome APIs and widgets besides the ones provided by GTK. As SWT is a layer on top of GTK, using java-gnome should provide a little better performance, besides access to extra gnome widgets not supported by SWT today. []s, Fernando Lozano |
From: Jeffrey M. <ku...@zo...> - 2003-06-03 00:38:31
|
On Mon, 2003-06-02 at 18:32, fer...@lo... wrote: > As SWT is a layer on top of GTK, using java-gnome should provide a little > better performance, besides access to extra gnome widgets not supported by SWT > today. This last statement is not true. Java-GNOME does perform better that SWT using GTK. This is due to the way SWT was implemented. Two concrete examples are: 1) SWT needed to support Z-order for the widgets (how composites are created). Since GTK doesn't really support this the SWT team decided to do this by creating an X window for each widget. This is the primary reason there is a refresh problem with SWT. It is not unusual to have 50 or more X windows in an application window. 2) The SWT API was created prior to the GTK port. The SWT notion of layout management was already in place. In SWT the container widget tells the child how much space it has whereas in GTK the child usually tells the container how much space it needs. In order to retrofit the SWT model to the GTK widget layout code a big hack was performed that has a negative impact. This is just two examples of differences between SWT and Java-GNOME. As I said before, the SWT API was in place and the developers of SWT had to write code to handle the differences between the SWT model and the GTK toolkit. -Jeff |
From: Gabriele E. <nz...@ga...> - 2003-06-03 19:28:46
|
Hi, first of all thaks for your time. Perhaps I wasn't clear about my question. So I try to explain better my question. Is it possible to use java-gnome for interact with gnome and SWT for draw the GUI in the same application ? ---- Gabriele Erba Audendum est: fortes adiuvat ipsa Venus (Tibullo) www.gabriele-erba.it ----- Original Message ----- From: <fer...@lo...> To: "Gabriele Erba" <nz...@ga...>; "java-gnome-developers" <jav...@li...> Sent: Tuesday, June 03, 2003 12:32 AM Subject: Re: [Java-gnome-developer] Gnome Library > Hi, > > > I'm used to develop with SWT for creating java application with native > > look&fell. > > I have two question: > > Is it possibile use gnome library with SWT without using Gtk library ? > > If this is true what are the advantages of Gtk library in comparison with > > SWT ? > > SWT on Unix uses either Motif or SWT. If you run under Linux and get "native" > look and feel you are using GTK already. > > Gnome is based on GTK. So there's no way to get Gnome features and not using > GTK. You can put a layer of software above Gnome and GTK, but not discarding GTK. > > SWT uses GTK but has no other features for gnome integration. If you need this, > you need to expand SWT to use more Gnome APIs and widgets besides the ones > provided by GTK. > > As SWT is a layer on top of GTK, using java-gnome should provide a little > better performance, besides access to extra gnome widgets not supported by SWT > today. > > > []s, Fernando Lozano > > |
From: <fer...@lo...> - 2003-06-03 11:47:34
|
Hi, > > As SWT is a layer on top of GTK, using java-gnome should provide a little > > better performance, besides access to extra gnome widgets not supported by SWT > > today. > > This last statement is not true. Java-GNOME does perform better > that SWT using GTK. That was what I sad. You just provided a better explanation that should follow the gains are more than "a little". :-) []s, Fernando Lozano |
From: <fer...@lo...> - 2003-06-03 20:02:59
|
Gabriele, > Perhaps I wasn't clear about my question. > So I try to explain better my question. > Is it possible to use java-gnome for interact with gnome and SWT for draw > the GUI in the same application ? Altough this should be possible, I wouldn't recomend. SWT and GTK have very different object models and expect different responsibilities regarding releasing OS and toolkit resources like handles and bitmaps. It would be very hard to mix both APIs and have a working, stable application. If you need something from Gnome or GTK that SWT won't provide, you have two paths: 1. Create a new SWT widget exposing the desired functionality. This may be trivial but may also be a chalending task. Later think about how your new widget would be implemented on other SWT targets like Win32, Motif or MacOS. 2. Drop SWT at all and use only Gnome and GTK widgets. Later if you need Win32 support you may try compiling java-gnome using the GTK port for Win32. I think nobody has done so, but this will happen sooner or later, as Gimp and other big GTK apps are working on Win32 just fine. The reverse is also true: expanding GTK to provide equivalent widgets and the ones you like on SWT or dropping GTK (and Gnome) altogether. []s, Fernando Lozano |
From: Gabriele E. <nz...@ga...> - 2003-06-04 09:06:50
|
Hi Fernando, Thanks for all. I want my application, a GPL P2P Chat with the possibility to live draw ( unfortunatly only in italian ), runs on all system (at the moment I use Swing but look&feel is awful). So I want port my application to SWT, but I want to expand the feature of my application when it runs on gnome for a better system integration. After your answer I think that I have two possibility: 1) Try compiling java-gnome using the GTK port for Win32 ( I try GIMP on windows and it's work very well), so it work on linux, unix and win system; in Italy there are few Mac system ! 2) Using only SWT ( I'm not able to exapand SWT, I'm a 23 years old student of software engineering). > Gabriele, > > > Perhaps I wasn't clear about my question. > > So I try to explain better my question. > > Is it possible to use java-gnome for interact with gnome and SWT for draw > > the GUI in the same application ? > > Altough this should be possible, I wouldn't recomend. SWT and GTK have very > different object models and expect different responsibilities regarding > releasing OS and toolkit resources like handles and bitmaps. It would be very > hard to mix both APIs and have a working, stable application. > > If you need something from Gnome or GTK that SWT won't provide, you have two paths: > > 1. Create a new SWT widget exposing the desired functionality. This may be > trivial but may also be a chalending task. Later think about how your new > widget would be implemented on other SWT targets like Win32, Motif or MacOS. > > 2. Drop SWT at all and use only Gnome and GTK widgets. Later if you need Win32 > support you may try compiling java-gnome using the GTK port for Win32. I think > nobody has done so, but this will happen sooner or later, as Gimp and other big > GTK apps are working on Win32 just fine. > > The reverse is also true: expanding GTK to provide equivalent widgets and the > ones you like on SWT or dropping GTK (and Gnome) altogether. > > > []s, Fernando Lozano > > ---- Gabriele Erba Audendum est: fortes adiuvat ipsa Venus (Tibullo) www.gabriele-erba.it |
From: Gabriele E. <nz...@ga...> - 2003-06-05 08:31:40
|
My problem isn't to extend a widget with canvas but to create new class t= o interact with non-visual gnome fuction like G-conf. I think I must write same code in C and same Java for this work and I must now very well how gnome work. ---- Gabriele Erba Audendum est: fortes adiuvat ipsa Venus (Tibullo) www.gabriele-erba.it ----- Original Message ----- From: "Clemens Eisserer" <lin...@we...> To: "Gabriele Erba" <nz...@ga...> Sent: Wednesday, June 04, 2003 8:52 PM Subject: Re: [Java-gnome-developer] Gnome Library > Hi there! > > >2) Using only SWT ( I'm not able to exapand SWT, I'm a 23 years old student > >of software engineering) > > > Oh, come on, I=B4m only 17 and I wrote also my own widgets using swt. > > Extending SWT (writing own widgets) isnt so hard as it seems. There > exists an interesting paper in the articles-section how to write own > widgets. > > Its really easy! > > Mfg Clemens > > > |
From: Bill H. <bil...@su...> - 2003-06-05 09:59:52
|
On Thu, 2003-06-05 at 09:32, Gabriele Erba wrote: > My problem isn't to extend a widget with canvas but to create new class t= o > interact with non-visual gnome fuction like G-conf. I think I must write > same code in C and same Java for this work and I must now very well how > gnome work. Gabriele: You may want to look at 'monkeybeans2' which is a Java implementation of and connection to GNOME's Bonobo and bonobo-activation APIs. With this code your Java applications can be GNOME components or access GNOME components and services. At the moment monkeybeans2 doesn't include gconf support since gconf is only available via C bindings. However you could use the "gconftool-2" client executable to avoid JNI if you wanted. - Bill > ---- > Gabriele Erba > Audendum est: fortes adiuvat ipsa Venus (Tibullo) > www.gabriele-erba.it > ----- Original Message ----- > From: "Clemens Eisserer" <lin...@we...> > To: "Gabriele Erba" <nz...@ga...> > Sent: Wednesday, June 04, 2003 8:52 PM > Subject: Re: [Java-gnome-developer] Gnome Library >=20 >=20 > > Hi there! > > > > >2) Using only SWT ( I'm not able to exapand SWT, I'm a 23 years old > student > > >of software engineering) > > > > > Oh, come on, I=C2=B4m only 17 and I wrote also my own widgets using swt= . > > > > Extending SWT (writing own widgets) isnt so hard as it seems. There > > exists an interesting paper in the articles-section how to write own > > widgets. > > > > Its really easy! > > > > Mfg Clemens > > > > > > >=20 >=20 >=20 > ------------------------------------------------------- > This SF.net email is sponsored by: Etnus, makers of TotalView, The best > thread debugger on the planet. Designed with thread debugging features > you've never dreamed of, try TotalView 6 free at www.etnus.com. > _______________________________________________ > java-gnome-developer mailing list > jav...@li... > https://lists.sourceforge.net/lists/listinfo/java-gnome-developer >=20 |
From: Jeffrey M. <Jef...@Br...> - 2003-06-04 10:49:53
|
We might be able to assist you in two ways. 1) If you do decide to compile java-gnome on Win32 we will try to offer all of the support we can. There are others in the community that have expressed interest in this and they might be willing to contribute. 2) If you find java-gnome classes that need to be enhanced to support better drawing features please post those requests to the list. We will make every attempt to enhance the bindings. -Jeff -----Original Message----- From: Gabriele Erba [mailto:nz...@ga...] Sent: Wednesday, June 04, 2003 5:07 AM To: java-gnome-developers; fer...@lo... Subject: Re: [Java-gnome-developer] Gnome Library Hi Fernando, Thanks for all. I want my application, a GPL P2P Chat with the possibility to live draw ( unfortunatly only in italian ), runs on all system (at the moment I use Swing but look&feel is awful). So I want port my application to SWT, but I want to expand the feature of my application when it runs on gnome for a better system integration. After your answer I think that I have two possibility: 1) Try compiling java-gnome using the GTK port for Win32 ( I try GIMP on windows and it's work very well), so it work on linux, unix and win system; in Italy there are few Mac system ! 2) Using only SWT ( I'm not able to exapand SWT, I'm a 23 years old student of software engineering). > Gabriele, > > > Perhaps I wasn't clear about my question. > > So I try to explain better my question. > > Is it possible to use java-gnome for interact with gnome and SWT for draw > > the GUI in the same application ? > > Altough this should be possible, I wouldn't recomend. SWT and GTK have very > different object models and expect different responsibilities regarding > releasing OS and toolkit resources like handles and bitmaps. It would be very > hard to mix both APIs and have a working, stable application. > > If you need something from Gnome or GTK that SWT won't provide, you have two paths: > > 1. Create a new SWT widget exposing the desired functionality. This may be > trivial but may also be a chalending task. Later think about how your new > widget would be implemented on other SWT targets like Win32, Motif or MacOS. > > 2. Drop SWT at all and use only Gnome and GTK widgets. Later if you need Win32 > support you may try compiling java-gnome using the GTK port for Win32. I think > nobody has done so, but this will happen sooner or later, as Gimp and other big > GTK apps are working on Win32 just fine. > > The reverse is also true: expanding GTK to provide equivalent widgets and the > ones you like on SWT or dropping GTK (and Gnome) altogether. > > > []s, Fernando Lozano > > ---- Gabriele Erba Audendum est: fortes adiuvat ipsa Venus (Tibullo) www.gabriele-erba.it ------------------------------------------------------- This SF.net email is sponsored by: Etnus, makers of TotalView, The best thread debugger on the planet. Designed with thread debugging features you've never dreamed of, try TotalView 6 free at www.etnus.com. _______________________________________________ java-gnome-developer mailing list jav...@li... https://lists.sourceforge.net/lists/listinfo/java-gnome-developer |
From: Gabriele E. <nz...@ga...> - 2003-06-05 08:35:08
|
Thank for support, when I start with port I will post same message for help. ---- Gabriele Erba Audendum est: fortes adiuvat ipsa Venus (Tibullo) www.gabriele-erba.it ----- Original Message ----- From: "Jeffrey Morgan" <Jef...@Br...> To: "'Gabriele Erba'" <nz...@ga...>; "java-gnome-developers" <jav...@li...>; <fer...@lo...> Sent: Wednesday, June 04, 2003 12:49 PM Subject: RE: [Java-gnome-developer] Gnome Library > We might be able to assist you in two ways. > > 1) If you do decide to compile java-gnome on Win32 we > will try to offer all of the support we can. There are > others in the community that have expressed interest in > this and they might be willing to contribute. > > 2) If you find java-gnome classes that need to be enhanced > to support better drawing features please post those requests > to the list. We will make every attempt to enhance the > bindings. > > -Jeff > > -----Original Message----- > From: Gabriele Erba [mailto:nz...@ga...] > Sent: Wednesday, June 04, 2003 5:07 AM > To: java-gnome-developers; fer...@lo... > Subject: Re: [Java-gnome-developer] Gnome Library > > > Hi Fernando, > Thanks for all. > I want my application, a GPL P2P Chat with the possibility to live draw ( > unfortunatly only in italian ), runs on all system (at the moment I use > Swing but look&feel is awful). > So I want port my application to SWT, but I want to expand the feature of my > application when it runs on gnome for a better system integration. > After your answer I think that I have two possibility: > 1) Try compiling java-gnome using the GTK port for Win32 ( I try GIMP on > windows and it's work very well), so it work on > linux, unix and win system; in Italy there are few Mac system ! > 2) Using only SWT ( I'm not able to exapand SWT, I'm a 23 years old student > of software engineering). > > > > Gabriele, > > > > > Perhaps I wasn't clear about my question. > > > So I try to explain better my question. > > > Is it possible to use java-gnome for interact with gnome and SWT for > draw > > > the GUI in the same application ? > > > > Altough this should be possible, I wouldn't recomend. SWT and GTK have > very > > different object models and expect different responsibilities regarding > > releasing OS and toolkit resources like handles and bitmaps. It would be > very > > hard to mix both APIs and have a working, stable application. > > > > If you need something from Gnome or GTK that SWT won't provide, you have > two paths: > > > > 1. Create a new SWT widget exposing the desired functionality. This may be > > trivial but may also be a chalending task. Later think about how your new > > widget would be implemented on other SWT targets like Win32, Motif or > MacOS. > > > > 2. Drop SWT at all and use only Gnome and GTK widgets. Later if you need > Win32 > > support you may try compiling java-gnome using the GTK port for Win32. I > think > > nobody has done so, but this will happen sooner or later, as Gimp and > other big > > GTK apps are working on Win32 just fine. > > > > The reverse is also true: expanding GTK to provide equivalent widgets and > the > > ones you like on SWT or dropping GTK (and Gnome) altogether. > > > > > > []s, Fernando Lozano > > > > > ---- > Gabriele Erba > Audendum est: fortes adiuvat ipsa Venus (Tibullo) > www.gabriele-erba.it > > > > > ------------------------------------------------------- > This SF.net email is sponsored by: Etnus, makers of TotalView, The best > thread debugger on the planet. Designed with thread debugging features > you've never dreamed of, try TotalView 6 free at www.etnus.com. > _______________________________________________ > java-gnome-developer mailing list > jav...@li... > https://lists.sourceforge.net/lists/listinfo/java-gnome-developer > |
From: <fer...@lo...> - 2003-06-05 14:44:58
|
Gabriele, > I want my application, a GPL P2P Chat with the possibility to live draw ( > unfortunatly only in italian ), runs on all system (at the moment I use > Swing but look&feel is awful). You just want a prettier look or do you want better graphic performance? > So I want port my application to SWT, but I want to expand the feature of my > application when it runs on gnome for a better system integration. Maybe you can get what you want just by using SWT or GTK+. Both, using recent versions, will use the nativve look of the plataform. And both have nice features for drawing. > 1) Try compiling java-gnome using the GTK port for Win32 ( I try GIMP on > windows and it's work very well), so it work on > linux, unix and win system; in Italy there are few Mac system ! There's a GTK+ port for Macs, but I do no know how stable it is. On Windows, use this release of GCC and GCJ: http://www.thisiscool.com/gcc33_mingw.htm Else get MingW from mingw.sourceforge.net and use a standard Java2 SDK. > 2) Using only SWT ( I'm not able to exapand SWT, I'm a 23 years old student > of software engineering). Maybe this will be easier, as you can already get SWT binaries for Win32, Linux and Mac. []s, Fernando Lozano |