Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » WindowBuilder » How to begin well a Rich Client app (on MS Windows)
How to begin well a Rich Client app (on MS Windows) [message #755525] Tue, 08 November 2011 17:13 Go to next message
Virgilio Ravagli is currently offline Virgilio RavagliFriend
Messages: 12
Registered: November 2011
Junior Member
Hi.
I've got to build a graphical interface, composed by a full screen window with four tabular grids that show data coming from a remote object (CORBA Orbacus), some buttons, two or three menus, perhaps a few stuff more.
It's a standalone application on desktop (over Windows XP or Vista PC), neither Internet nor browsers involved: the user fires the application with a double click and begins to work.

Nothing really tricky, but I want to create a good, handy application, designed for every kind of users, easy to use.

I've little experience in designing Java GUI (I've got a deep experience with MS Visual Studio, C#).

My question is:
what type of project and wizard do I have to select ?

I saw File-->New-->Other-->Window Builder proposes several choices:
eRCP UI, GWT UI, SWT UI, XWT UI, Swing Designer with Application Window.
As far as I'm concerned, eRCP isn't the case, it's suitable for smartphones.
GWT is web-oriented, so I'm going to eliminate it.

SWT, XWT and Swing App Window seem to be good for my job...
which should I use ???
Can anybody give me an advice ?
Thanks a lot
Virgilio

Re: How to begin well a Rich Client app (on MS Windows) [message #755528 is a reply to message #755525] Tue, 08 November 2011 17:24 Go to previous messageGo to next message
Virgilio Ravagli is currently offline Virgilio RavagliFriend
Messages: 12
Registered: November 2011
Junior Member
Just another info.
I'm working with Eclipse Indigo for Java Developer; till now, I haven't installed any plug-ins.
If I'm right, the last version of Window Builder is already included into Indigo for Java dev, pleae tell me if I'm wrong...
Re: How to begin well a Rich Client app (on MS Windows) [message #755532 is a reply to message #755525] Tue, 08 November 2011 17:52 Go to previous messageGo to next message
Eric Clayberg is currently offline Eric ClaybergFriend
Messages: 886
Registered: July 2009
Location: Boston, MA
Senior Member
SWT, RCP, XWT or Swing would all work for this purpose.

SWT, RCP and XWT will get you platform native look and feel. Swing is emulated but should look fine.

With RCP, you could use the complete Eclipse framework which might be helpful.

With SWT, RCP and Swing, your UI would be in Java. With XWT it would be defined in XML.
Re: How to begin well a Rich Client app (on MS Windows) [message #755541 is a reply to message #755532] Tue, 08 November 2011 18:28 Go to previous messageGo to next message
Virgilio Ravagli is currently offline Virgilio RavagliFriend
Messages: 12
Registered: November 2011
Junior Member
Thanks, Eric, you cleared my ideas...
I must work in Java, that's a commitment, so I can exclude XWT.
Now I'm following a SWT tutorial, probably I'll use SWT.
Just a detail: you said that "Swing is emulated", what does it mean ?
Bye
Re: How to begin well a Rich Client app (on MS Windows) [message #755543 is a reply to message #755541] Tue, 08 November 2011 18:40 Go to previous messageGo to next message
rjcmln is currently offline rjcmlnFriend
Messages: 4
Registered: November 2011
Junior Member
Hi Virgilio,

I am a beginner too, but I think I have an answer to your question

Quote:

Just a detail: you said that "Swing is emulated", what does it mean ?
Bye


Search YouTube for "What is SWT"
guy explains Swing, SWT (and AWT)

Re: How to begin well a Rich Client app (on MS Windows) [message #755550 is a reply to message #755541] Tue, 08 November 2011 19:17 Go to previous messageGo to next message
Eric Clayberg is currently offline Eric ClaybergFriend
Messages: 886
Registered: July 2009
Location: Boston, MA
Senior Member
SWT uses native platform widgets as defined by the OS, so any SWT app should look like any other native app on a give platform.

Swing uses emulated widgets which means that Swing actually draws the widgets using a pluggable look and feel. This means that you can make your app look like a native app or something completely different (you could use a Linux L&F under Windows). The emulations tend to be pretty good, but sometimes can be subtly different (less so now than in the past).

I'm a big fan of SWT so I would almost always pick it (or RCP) for building a native desktop app. You would not go wrong selecting Swing though. You might even try building a very simple app in both to see which you like better.
Re: How to begin well a Rich Client app (on MS Windows) [message #755615 is a reply to message #755550] Wed, 09 November 2011 01:44 Go to previous messageGo to next message
Virgilio Ravagli is currently offline Virgilio RavagliFriend
Messages: 12
Registered: November 2011
Junior Member
Following your advice (and having seen the video kindly suggested by rjcmln) I decided to use SWT.
So I did the simplest tutorial, HelloWorldSWT.
With a difference: I didn't import the SWT project, I used Help-->Install new software, then opened General purpose tool and selected Swing Designer and the four SWT Designers.
Then I built the Java project and created the class: at this point, there were unresolved classes Design and Shell.
I configured the build path: went into the plugins directory and made "Add external jars" of org.eclipse.swt.win32.win32.x86_3.7.0.v3735b.jar, and the errors were solved.
Then I made a run and all was good.
But here my question: why should I explicitly add the jar in the buildpath ? I've already installed the plugin, the jar is in the plugins directory, Couldn't Eclipse find it without my setting of build path ?
Perhaps it's a silly question, so excuse me in advance.
Good night
Re: How to begin well a Rich Client app (on MS Windows) [message #755861 is a reply to message #755615] Wed, 09 November 2011 20:44 Go to previous messageGo to next message
Virgilio Ravagli is currently offline Virgilio RavagliFriend
Messages: 12
Registered: November 2011
Junior Member
Perhaps I've reached the end of the tunnel (I was a bit warry, because I've found quite tricky to get the tutorial working !).
Yesterday I was able to run the program into Eclipse: Run as --> Java app.
Then I tried to build it by means of an ANT file, but I couldn't do it until I found out that I had to exclude META-INF from org.eclipse.swt.win32.win32.x86_3.7.0.v3735b.jar, that I included by <zipfileset>.
I guess it caused a conflict with my jar's manifest, is it correct ?

So, this is my final build.xml:
<project name="HelloWorldSWT" basedir="." default="main">
<property environment="env" />
<property name="dest.dir" value="build" />
<property name="dest.dir.classes" value="${dest.dir}/classes" />
<property name="plugins.dir" value="${env.ECLIPSE_HOME}/plugins" />
<property name="repository.path" value="C:\ExeJar" />
<path id="build.class.path">
<fileset dir="${plugins.dir}">
<include name="*.jar" />
</fileset>
</path>
<target name="clean">
<delete dir="${dest.dir}" />
</target>
<target name="prepare">
<mkdir dir="${dest.dir}" />
<mkdir dir="${dest.dir.classes}" />
</target>
<target name="main" depends="clean,prepare">
<javac srcdir="src" destdir="${dest.dir.classes}" includes="app/**">
<classpath refid="build.class.path" />
</javac>
<jar manifest="mainClass.txt" duplicate="preserve" destfile="${dest.dir}/HelloWorldSWT.jar">
<zipfileset excludes="META-INF/**/*" src="${plugins.dir}/org.eclipse.swt.win32.win32.x86_3.7.0.v3735b.jar" />
<fileset dir="${dest.dir.classes}"/>
</jar>
<copy file="${dest.dir}/HelloWorldSWT.jar" tofile="${repository.path}/HelloWorldSWT.jar" overwrite="true" />
</target>
</project>

It works, but I ask, is it the right way or is it a devious path ?
I'm not at ease with the inclusion of the plugin jar.

What do you suggest ?
thanks in advance,
Virgilio
Re: How to begin well a Rich Client app (on MS Windows) [message #755886 is a reply to message #755861] Thu, 10 November 2011 01:37 Go to previous messageGo to next message
Eric Clayberg is currently offline Eric ClaybergFriend
Messages: 886
Registered: July 2009
Location: Boston, MA
Senior Member
I would recommend the Eclipse SWT Forum for SWT build and deployment questions.

This forum is focused solely on WindowBuilder specific questions.
Re: How to begin well a Rich Client app (on MS Windows) [message #755927 is a reply to message #755886] Thu, 10 November 2011 08:44 Go to previous message
Virgilio Ravagli is currently offline Virgilio RavagliFriend
Messages: 12
Registered: November 2011
Junior Member
ok thanks Eric, I move my last message there.
Excuse me but I'm new...
Bye
Virgilio
Previous Topic:Where to Report Bugs
Next Topic:Get the latest trunk version of WindowBuilder
Goto Forum:
  


Current Time: Wed Dec 17 23:12:49 GMT 2014

Powered by FUDForum. Page generated in 0.02916 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software