Tell me more ×
Programmers Stack Exchange is a question and answer site for professional programmers interested in conceptual questions about software development. It's 100% free, no registration required.

I'm going to develop a GUI application which will process xml data via forms. I have selected two options: Java (swing or swt) or Qt.

I've already try a basic tutorial with both Qt (Qt designer) and Java (Eclipse). And I must admit that both will fill my needs.

The last question I have to solve is how painful will be the deployment?

The end user is a non-tech, so the installation and update process have to be easy.

Java has the Java Web Start, with easy updating; Qt may be more "packaged" without the JVM need.

What do you think? What are the pros and cons?

share|improve this question

5 Answers

If sending full packages is an acceptable way of updating, i'd say go for Qt.

The problem with Java is that not only you have to check for and install the JRE, but you are messing with your client's configuration. The JRE will also want to update, show popups, etc.

A monolithic application, that only uses disk space when not running gives a far better user experience.

Of course, if you want the easiest updating possible, it's hard to beat JWS.

share|improve this answer
Yes, I'm aware of the worse user experience with the JRE. But I have limited ressources (me), and I guess that auto-update implementation is easier with java than qt c++. – user777466 Jul 21 '11 at 8:06

If ease of deployment is your only parameter for the choice, and deployment has to be manual, I would say that Qt is the easiest of the two: You just need to copy the files in a folder. When you need to update, you just overwrite them.

On the other hand, if you are going to use an installer to automate installation, I think deployment would be very easy for the end user anyway.

One big difference that I see between the two solutions is that Qt would use much less memory and start faster. I don't know if that's a concern for you, though.

share|improve this answer
My application is going to be a simple forms app, so I'm not worried about speed at runtime. But is there a real difference of speed at startup ? – user777466 Jul 22 '11 at 8:25
In my experience, yes, there is pretty big difference in startup time, because java needs to load and start the JVM, while the native environment is already there. Once the JVM is loaded, the speed difference can be hardly noticeable, depending on the application. – danmaz74 Jul 22 '11 at 21:56
Thank you, I'm going to put some more weight on this speed point, since response time will increase the please of use. Btw, I was thinking of how rare are the Java desktop applications ! – user777466 Jul 25 '11 at 13:41
@user777466: One important reason why there are few Java desktop applications is that swing and swt look out of place in any system and thus give worse user experience. – Jan Hudec Jan 24 '12 at 6:55

By using Java you have to wrangle with the user having a JVM on their computer. If they don't, it can be a hassle and as you said, your users are non-technical, which makes adding any extra steps to the situation a pain. JWS beats out Qt when it comes to ease in new deployments. If you were planning on deploying the Java application is a traditional application (i.e. a runnable JAR) then you would have the same problems updating as with Qt.

That said, Qt allows you the benefit of native execution. Less resources used and no problems with external requisites*. Deployment of a new version is not very hard, just have an updating application that runs first to check for updates, if there is on, download the update and replace the old version of the application.


*Unless you statically compile your application, you likely will have to deal with people accidentally deleting or moving DLLs (or whatever you call them). That can be a pain when a use is not technically inclined.

share|improve this answer
Can you give me a link/name of the "updating application that runs first to check for updates" you mentionned ? Tx – user777466 Jul 22 '11 at 8:27
I mean there isn't a application that I can think off of the top of my head. However writing one isn't all that hard. Have some way of checking for updates on your server which is as simple as a text file. Have it point to the new files to download as well. – Glenn Nelson Jul 22 '11 at 11:21

I would recommend Java for this kind of situation.

Java Web Start is a great technology for deployment and fairly easy to set up. It makes your deployment pretty painless and automated from your perspective: all you need to do is maintain a web server with the right .jar files and appropriate JNLP descriptor (a short XML file).

From the user's perspective it is pretty much as simple as "click on web link to run app" (you might also get a click-through security notice depending on OS / browser / security setup but most users can handle these :-) ).

A big advantage of Java is bytecode portability which means that you don't need to recompile for different platforms if you stick to pure Java / Swing. This is massive advantage for deployment if you are deploying to a heterogeneous set of platforms (e.g. several versions of Mac + Windows + Linux)

Java clearly requires the user to have a JRE (or be willing to install one) but this problem is overstated - most users already have a JRE nowadays, and Java Web Start includes the ability to install a JRE on demand in modern browsers. Furthermore, the users who both don't have and can't obtain a JRE are either a) on ancient technology anyway and unlikely to be your customrs or b) in a heavily locked-down environment where you probably won't be allowed to download and run native C++ Qt code either.

share|improve this answer

I say, go for Qt and C++, it will make the whole thing smaller and more efficient. There are several libraries to do the upgrade job, so you don't have to implement much (e.g. Luau).

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.