Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

hi all, ive done a search with google and come up with Tk and Win32::GUI. im a beginning perl user. can someone compair and contrast these or other methods of making graphical user interfaces? i would say i'd need something with tutorials and some documentation.. but im willing to pick the more advanced/less documented choice if its worth it.

Id like something that i can work on in a windows2000 environment, and in a linux enviro (if possible) or at least, code at home(linux) and bring to work(win2000).

Any directions people can point me?

update (broquaint): added formatting and fixed typo in subject (s/compair/compare/)

Title edit by tye

Replies are listed 'Best First'.
Re: compare interfaces for perl
by sri (Vicar) on Jul 14, 2003 at 16:15 UTC
Re: compare interfaces for perl
by traveler (Parson) on Jul 14, 2003 at 16:55 UTC
    Gtk+ has been very popular on *nix platforms. The Gtk2+ ('new' version) perl bindings are pretty stable and Windows support is in "alpha" more or less. If you have a compiler, the instructions are in the archives of the gtk perl list. Gtk has the "advantage" of looking the same on Windows as it does on Linux/Unix. Some other toolkits, e.g. wxWindows use the native GUI of the particular OS (Gtk+ in the case of *nix), so the applications look slightly different under different OSs.

    While, tk, Gtk+ and wxWindows are all great, I have found Gtk-perl very easy to use. I must admit, though, that I have spent far more time with it than with wxWindows. I prefer either of those over Tk, but that is a personal preference and some other monks will likely disagree.

    I suggest you play with each of them, or read code using each of them, and then decide.

    HTH, --traveler

      traveler said Gtk...Windows support is in "alpha" more or less. If you have a compiler, the instructions are in the archives of the gtk perl list.

      I'm not sure this is where a beginning perl programmer should go. Key words in this opinion are 'alpha" and "compiler" (in the Windows world, anyhow. Compliling happens all the time and is free on Linux and other OSS).

      If Activestate has the full Tk stuff for their Win2k build, which it looks like they do from looking at activestate , (though I don't see the overall Tk.pm for the 800 builds), I think that's the way to go, at least over Gtk. I haven't experience with the WxPerl thing, however.

      If you do go with the Tk solution, you'll want a copy of "Mastering Perl/Tk". It has stuff that can be pretty tough to track down otherwise.

      --Bob Niederman, http://bob-n.com
        That is why I included the warning. It will not be long before the Win32 binary is stable, I believe. IIRC, the first try was just created last week. I am hoping for a win32 version RSN. When it is available, the ease of using Gtk vs tk (for at least some tasks, at least) may make Gtk a very serious cross-platform contender.

        --traveler

Re: compare interfaces for perl
by ctilmes (Vicar) on Jul 14, 2003 at 17:33 UTC
    I really like PerlQT. The look/feel is very modern, and you can prototype your interface with Qt Designer which is actually quite nice.

    Be sure to check out the license for QT -- it is quite compatible with Open Source, but if you are going to further restrict/sell what you make with it, they probably want money from you.

Re: compare interfaces for perl
by cfreak (Chaplain) on Jul 14, 2003 at 16:18 UTC
Re: compare interfaces (GUIs) for perl
by hsweet (Pilgrim) on Jul 14, 2003 at 21:42 UTC

    TK would be my first choice if only because it works on more than one OS (and I spend the bucks for the book). One of the reasons I like perl is because it is OS neutral. I've never worked with the Win32::GUI. I never heard of WxPerl.

    I have some simple examples at http://frontiernet.net/~hsweet/programming/TKintro.htm

    Time flies like an arrow, fruit flies like banannas

Re: compare interfaces (GUIs) for perl
by Mr_Person (Hermit) on Jul 14, 2003 at 20:49 UTC