Click to See Complete Forum and Search --> : which GUI-Toolkit for easy app-install
Rüpel
08-20-2002, 04:02 PM
hi all,
i'm a linux-user for some time now and as a professional programmer i want to dive into the secrets of writing GUI-applications for linux. maybe i can convince my boss that i can port our win-apps over to linux.
the problem is, he's kind of enthusiastic about windows-programming and personally seems to dislike linux - so i need good arguments!
the fact he always states is, that there is so much diversity in the linux-world, you don't know what you get on the end-users desktop, which libraries are there, which are not. (qt, gtk+, wxGTK, etc. which version, bla bla). when we release a new version of our windows-software we build the release-exe, put it into an installer-package together with mfc42.dll and the user can simply click "setup.exe"-"yes"-"next"-"next"-"done" and things work.
1. is it possible to write an application, that is as simple to install for everyone's linux?
2. if yes, what are the possibilities?
3. in general, what technique is future-proof? it seems most people use qt/kde but sun will include gtk+/gnome into solaris (if i got it right) and many people use gnome. god knows about all the other windowmanager/widget-libs out there. so which GUI-lib/widget-set should i use? i personally don't care - i'm a programmer, for and while are everywhere ;) - important is the ease of installation for end-users.
hmm. any suggestions or hints?
thx in advance.
Infrastructure
08-20-2002, 05:40 PM
Well, you could check Lokis installers and uninstallers, they are Free Software and can be found here:
http://www.lokigames.com/development/setup.php3
Energon
08-20-2002, 06:34 PM
Be wary of the Qt license. You either GPL the Linux stuff or you pay a fee. You can also use Qt for Windows apps really easily (a 2MB .dll to distribute), but the license is really bad for that if you don't want to pay.
As far as what tookit to use, it doesn't really matter as long as it's not a podunk toolkit that no distro even distributes. Keep in mind, you can always statically link the application and be set.
Rüpel
08-22-2002, 02:08 AM
ok, thx guys.
@infra about loki-setup:
seems to be nice. but i thought loki went bankrupt? is this installer stable or maintained in the future if any new bugs are found?
@ener about static linking:
seems to be a good idea, since we really want the linux-newbie user to be able to use our programs out of the box. anything that has to do something with make-scripts is forbidden in this area. (although advanced users may be able to do that, it can't be the only way to go!) - so how do the executable increase in size if i link the libs statically? i read about wxWindows (wxGTK) keeping them at reasonable 150kB, what about Qt and vanilla-GTK+ apps?
@all
what to choose? Qt ot GTK (in the latter case i think i would go with wxGTK) - would be terrible to stick to a certain toolkit realizing two years later, that i made the wrong decision. any fairminded suggestions?
Energon
08-22-2002, 09:25 AM
Well... that's odd. I can't get it to statically link atm. Someone else may be able to show the size difference if they can get it.
The biggest decided factors that I'd look at if I were you are whether you want to use C or C++ for your project, what kind of licensing you want to use, and whether you want something easily portable between systems. Both APIs (as well as gtkmm, the C++ wrapper for GTK+) are excellent and easy to use, so it comes down mainly to your situational constraints.
bwkaz
08-22-2002, 09:34 PM
Just use Xlib.
Every computer running X11R6 will have the libs for it. It's foolproof!
:D :p
(Just in case you don't know, Xlib is indeed extremely portable, but it's a PAIN to program. If you've ever done GUI stuff using only the Win32 API, you know what I mean.)
Rüpel
08-23-2002, 04:34 AM
*argl* ;)
ok. seems Qt and wxWindows are the finalists - since they are C++ and supported very well.
now there's still one thing i'm not sure about: different versions of one toolkit.
how long does a single implementation with a certain version of a toolkit compile with later versions? what is your experience? i don't want to rewrite the entire application only because of Qt 4.1 is released and everything changed again.
the whole subject is still a riddle to me - there are so many different versions of the same libraries out there, how in hell can someone distribute an executable and be sure that it runs on every linux-platforms. or is it everytime a new version of the same program (one for qt1, one for qt2, one for qt3...) - same for GTK of course...
is the best strategy to have the newest library-version on the developement-system or an older one (hoping, that the resulting executable still runs on system with a newer version)...
is it possible to ship with the required library? but what if the user has already a newer version installed?
what about all that, if i link statically? what is required then? just the Xlib?
hmm. i'm confused.
:confused:
Energon
08-23-2002, 09:13 AM
Welcome to the wonderful world of why source distribution and autoconf/make are far better than binary distributing... ;)
The best thing you can do to guarantee an application will run on every system is to statically link it. That way you've got no external dependancies, but the binary grows and grows and grows. There is no other requirement because every last little bit of code is shoved away in the binary rather than linked to at run-time.
It is not possible to ship with new libraries, as 9 times out of 10, that would require root access. It's best to not mess with the users system other than what is absolutely necessary (ie, having them add your conf files into /etc and such).
Statically linking also lets you use whatever version of the toolkit you feel like using. Newer is almost always better in this regard.
Qt doesn't usually rewrite the book with every version. There are some classes and functions that get deprecated with time, and some get chopped out without warning. It's up to you to watch out for that when you upgrade your version. But with static linkage, you can still use older versions without any worry of what users will do.
But like I said, I couldn't get static linking to work. So someone else will have to help get that going.
Rüpel
08-23-2002, 04:06 PM
@energon:
post number 666 - seems to be evil! ;)
i will try a statically linked wxWindows-app. let's see how it goes and what size it will be...
pro-users should be able to build from source though - i still have to figure that out...
thx brother!
Dun'kalis
08-25-2002, 02:40 AM
GTK+ has GTKmm, pyGTK, and dozens of bindings for every language ever used on computers since the beginning of time (they have a FORTRAN 77 binding...) and doesn't have the licensing terms that Qt has.
Energon
08-25-2002, 12:43 PM
Gtkmm is also nowhere near as nice to work with as both Gtk+ and Qt. So there's definitly a tradeoff to consider.
ariell
02-13-2003, 08:12 PM
I don't get the point here.
Qt is an absolutely reliable "toolkit" (for it is not just a toolkit).
You talked about reliability: As far as I know there's is currently nothing (else) available that is 100% typesafe. Moreover, it is running on Solaris/SPARC or Windows/x86 or any unix system at the same time.
The qt-library is perfectly organized, is "downward compatible", too.
If you want the "hire and fire" I don't get what you're "dwelling of".
I'm in that problem for more than 15y- qt is one of the few "comfortable experiences".
ariell.
Energon
02-14-2003, 10:12 AM
Originally posted by Dun'kalis
and doesn't have the licensing terms that Qt has.
That's why. Qt is great, but it's licensing sucks the big one.