Which windowing toolkit to use?
Hi all, I intend to start coding the UI of the heap profiling toolkit I'm working on [1] soon. I'd be happy to get some advice on choosing the right windowing toolkit for this task. The main requirements are: - portability and native look & feel if possible - easy to distribute executables under Windows - relatively slow code rot - sane interface that doesn't need wild workarounds even if what I'm doing is not trivial or elementary - trouble-free source installation in case someone wants to contribute As I see, at the moment there's no serious alternative besides GTK and wx, so my question is which do you think is better suited to this task? I have absolutely no development experience with GTK, and while I used a bit of wx in the past (in C++), I'm not really familiar with it either, especially not the Haskell bindings. I noticed that installing the wx binding with user rights doesn't seem to work directly from hackage (doesn't pass --user to ghc-pkg?), but it looks like a problem that can be solved with some hand editing. I'm a bit more afraid of setting up a development environment under Windows; is there any major pain involved with either of these libraries if I use MinGW? And how about their interface? Is there any significant difference? I'd especially like to hear the opinion of someone who's reasonably familiar with both. Thanks, Gergely [1] http://code.google.com/p/hp2any/ -- http://www.fastmail.fm - Or how I learned to stop worrying and love email again
Web - HTML
2009/6/17 Patai Gergely
Hi all,
I intend to start coding the UI of the heap profiling toolkit I'm working on [1] soon. I'd be happy to get some advice on choosing the right windowing toolkit for this task. The main requirements are:
- portability and native look & feel if possible - easy to distribute executables under Windows - relatively slow code rot - sane interface that doesn't need wild workarounds even if what I'm doing is not trivial or elementary - trouble-free source installation in case someone wants to contribute
As I see, at the moment there's no serious alternative besides GTK and wx, so my question is which do you think is better suited to this task? I have absolutely no development experience with GTK, and while I used a bit of wx in the past (in C++), I'm not really familiar with it either, especially not the Haskell bindings. I noticed that installing the wx binding with user rights doesn't seem to work directly from hackage (doesn't pass --user to ghc-pkg?), but it looks like a problem that can be solved with some hand editing. I'm a bit more afraid of setting up a development environment under Windows; is there any major pain involved with either of these libraries if I use MinGW?
And how about their interface? Is there any significant difference? I'd especially like to hear the opinion of someone who's reasonably familiar with both.
Thanks,
Gergely
[1] http://code.google.com/p/hp2any/
-- http://www.fastmail.fm - Or how I learned to stop worrying and love email again
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
2009/6/17 Alberto G. Corona
Web - HTML
I'd agree with that. It would be really nice for X-platform. Maybe it's possible to use JQuery (or Flapjax) to get some nice dynamic/interacitivity? /M -- Magnus Therning (OpenPGP: 0xAB4DFBA4) magnus@therning.org Jabber: magnus@therning.org http://therning.org/magnus identi.ca|twitter: magthe
2009/6/17 Magnus Therning
2009/6/17 Alberto G. Corona
: Web - HTML
I'd agree with that. It would be really nice for X-platform. Maybe it's possible to use JQuery (or Flapjax) to get some nice dynamic/interacitivity?
Does someone know if it possible to make an application which embed webkit with: - webkit used for rendering and running javascript - javascript function calling haskell code ? Cheers, Thu
I use Haskell server pages and HJScript. HJScript includes ajax
capabilities. and embed haskell code in HTML much like ASP and JSP embed VB
and Java.
The client side haskell code is converted to javascript and with ajax you
can call Haskell server code.
2009/6/17 minh thu
2009/6/17 Magnus Therning
: 2009/6/17 Alberto G. Corona
: Web - HTML
I'd agree with that. It would be really nice for X-platform. Maybe it's possible to use JQuery (or Flapjax) to get some nice dynamic/interacitivity?
Does someone know if it possible to make an application which embed webkit with: - webkit used for rendering and running javascript - javascript function calling haskell code ?
Cheers, Thu
Web - HTML
I'd agree with that. It would be really nice for X-platform. Maybe it's possible to use JQuery (or Flapjax) to get some nice dynamic/interacitivity? I'm not sure if a web interface is really a good fit here, but I'll think about it.
Gergely -- http://www.fastmail.fm - Access all of your messages and folders wherever you are
Hi Patai, there is one other alternative to gtk2hs and wxhaskell: .NET Forms It is accessable through Sigbjorn Finne's hs-dotnet package. I am right now *starting* to use it myself, so just consider it an option. Both of the others are quite usable, wxhaskell has very easy to use layouts and looks fine on windows (native look) but lacks any support for MVC, ie. a click on a list will only give you back which position was clicked and it's up to you what "object" that should map to. Gtk2hs also has layouts, IMO not as nice as wxhaskell, does not look as nice on XP, (no true native look and feel), but does have support for mvc. Both (gtk2hs and wxhaskell) have a "multithreading" problem, cause it's not possible to call gui code outside the main gui event loop, and believe me, the wish for that does occur, so it's kinda hard to code a gui that is not sluggish with long computations. With the threading part, .NET Forms can handle that much easier. Günther Patai Gergely schrieb:
Hi all,
I intend to start coding the UI of the heap profiling toolkit I'm working on [1] soon. I'd be happy to get some advice on choosing the right windowing toolkit for this task. The main requirements are:
- portability and native look & feel if possible - easy to distribute executables under Windows - relatively slow code rot - sane interface that doesn't need wild workarounds even if what I'm doing is not trivial or elementary - trouble-free source installation in case someone wants to contribute
As I see, at the moment there's no serious alternative besides GTK and wx, so my question is which do you think is better suited to this task? I have absolutely no development experience with GTK, and while I used a bit of wx in the past (in C++), I'm not really familiar with it either, especially not the Haskell bindings. I noticed that installing the wx binding with user rights doesn't seem to work directly from hackage (doesn't pass --user to ghc-pkg?), but it looks like a problem that can be solved with some hand editing. I'm a bit more afraid of setting up a development environment under Windows; is there any major pain involved with either of these libraries if I use MinGW?
And how about their interface? Is there any significant difference? I'd especially like to hear the opinion of someone who's reasonably familiar with both.
Thanks,
Gergely
Günther Schmidt wrote:
Hi Patai,
there is one other alternative to gtk2hs and wxhaskell: .NET Forms
It is accessable through Sigbjorn Finne's hs-dotnet package.
Is that usable with mono? I certainly hope that something as useful as the heap profiling toolkit's GUI won't be a Windows-only thing. Is the plan to make the heap profiling ship with GHC? In that case it might be ill advised to add a dependency on dot-net/mono. Though it could be argued it's just as ill advised to add a dependency on GTK/WX. /M -- Magnus Therning (OpenPGP: 0xAB4DFBA4) magnus@therning.org Jabber: magnus@therning.org http://therning.org/magnus identi.ca|twitter: magthe
Magnus Therning schrieb:
Günther Schmidt wrote:
Hi Patai,
there is one other alternative to gtk2hs and wxhaskell: .NET Forms
It is accessable through Sigbjorn Finne's hs-dotnet package.
Is that usable with mono?
Sorry Magnus, dunno. The galois guys provide a lot of really really useful code, I surmise they use it themselves quit a lot, but, the instructions are a bit sparse and since they actually make a living writing haskell code they propably just don't have much time for that.
I certainly hope that something as useful as the heap profiling toolkit's GUI won't be a Windows-only thing.
Is the plan to make the heap profiling ship with GHC?
In that case it might be ill advised to add a dependency on dot-net/mono. Though it could be argued it's just as ill advised to add a dependency on GTK/WX.
/M
------------------------------------------------------------------------
_______________________________________________ Haskell-Cafe mailing list Haskell-Cafe@haskell.org http://www.haskell.org/mailman/listinfo/haskell-cafe
Hello Gu?nther, Thursday, June 18, 2009, 12:46:40 AM, you wrote:
there is one other alternative to gtk2hs and wxhaskell: .NET Forms
It is accessable through Sigbjorn Finne's hs-dotnet package.
I am right now *starting* to use it myself, so just consider it an option.
can you please provide code snippets? some starting basis will greatly help to grok this way of GUI -- Best regards, Bulat mailto:Bulat.Ziganshin@gmail.com
Hi Bulat, well, do a cabal install hs-dotnet. Then do a cabal unpack hs-dotnet and look into the examples directory, there are 2 for gui, Forms and FileSelect. If they don't work right away then follow the instructions for aquanting the .dll in the bin directory with the NET framework. The LINQ examples will only work if you have .NET 3.5 installed, the gui examples even with .NET 2.0. Good luck and come back for more if you like :) Günther PS: The galois inc. guys are amazingly practical code contributors, the link to Sigbjorns website is on hackage, the hs-dotnet package. Bulat Ziganshin schrieb:
Hello Gu?nther,
Thursday, June 18, 2009, 12:46:40 AM, you wrote:
there is one other alternative to gtk2hs and wxhaskell: .NET Forms
It is accessable through Sigbjorn Finne's hs-dotnet package.
I am right now *starting* to use it myself, so just consider it an option.
can you please provide code snippets? some starting basis will greatly help to grok this way of GUI
participants (7)
-
Alberto G. Corona -
Bulat Ziganshin -
Guenther Schmidt -
Günther Schmidt -
Magnus Therning -
minh thu -
Patai Gergely