SWT is slow, Was: D : Not for me anymore

John Reimer terminal.node at gmail.com
Mon Oct 23 12:49:07 PDT 2006


On Thu, 19 Oct 2006 13:59:08 -0700, Jari-Matti Mäkelä  
<jmjmak at utu.fi.invalid> wrote:

>
> There was at least some discussion in Slashdot over two years ago:
>
> http://developers.slashdot.org/comments.pl?sid=92172&threshold=1&commentsort=0&mode=thread&cid=7929925
>
> "First off, SWT only performes well on windows, and stack on top of that
> that the principal native abstractions are taylored to a win32
> environment. Based off of that it is easy to see how SWT performes quite
> nicely on Windows.
>
> Elsewhere it sucks. MacOS, GTK, photon, Motif. Even porrly writeen swing
> programs outperform on those platforms."
>
>


Again, your quote refers to Java SWT: perhaps there might be an element of  
truth there, yet it looks more to me like prejudice since I've not  
experienced the speed deficit issue (although, I agree that it's big and  
slow to load, however).  DWT performs quite spritely from what I've seen  
in a couple of projects.  The size of the code is more alarming to me than  
anything else (the executables grow to a couple megabytes).


> IMO it's a bit sad to see that SWT has sucked on everything else but
> Windows for a very long time now. I personally do not want to support
> anything related to GTK or SWT because they're technically very low
> quality. I know many companies embrace SWT because the license is quite
> liberal, but still it's a sign of apathetic 'Eat shit' attitude to force
> clients to use stuff that makes their computers vomit in order to save a
> few hundreds of bucks in licensing costs.


The SWT running on GTK 2 seems to work quite well, so I don't really  
understand you here either.  I don't consider GTK 2 to be a low quality  
library, although it is in C and horribly ugly to look at or program in.   
But I don't like most of the frameworks out there anyway, C++-based ones  
included.  At least GTK is very accessible from D precisely because of its  
C interface.  What I don't like about GTK (or SWT) is the size... I prefer  
lightweight and perhaps that it's my biggest grudge against many of these  
libraries.  From a pragmatic perspective, however, GTK performs quite  
well, and I can see a GTK-based SWT working adequately with D,  
performance-wise.  DUIT has been a proof of concept of this fact.   
After-all, GTK is moving towards Cairo and glitz (OpenGL) based surfaces:  
SWT is on top of all that.  This certainly looks more hopeful for any D  
port of SWT.


> Maybe in the future they'll release SWT under EPL and QT will be
> available under GPL 3.0 (huge maybe) - then it might become possible to
> use QT as a backend for SWT and DWT. IANAL, these licensing things are
> hard to understand.
>
> For the time being Harmonia is IMHO the best alternative as an official
> GUI library. I will start using it immediately after it is ported to  
> Linux.


Harmonia is beautiful and small... a good example of what I like also. But  
it's programming interface is yet a litte unusual and unfamiliar.   
Furthermore, it's still hasn't been ported to other platforms, although  
doing so shouldn't be that difficult.
Harmonia could do well with the right support and initiative from more  
people than jsut the maintainers (precisely, I'm sure, what they are  
looking for); however support has been something that's been lacking from  
almost every GUI project put to the forefront.

-JJR




More information about the Digitalmars-d mailing list