Despite some of the criticisms mentioned here, and including my own frustrations, my opinion is that Perl/Tk is still worth learning. I've tinkered a bit with some others and with the possible exception of Prima it seems to be the most Perlish. Once you get the hang of it, Perl/Tk is not very difficult at all. OTOH I really want to like Wx, but trying to learn it gives me fits and leaves me cross-eyed with a headache.
The collective Perl/Tk docs actually contain sufficient information scattered about to get you going, but its a bit difficult to sort through. The following PODs should cover most of what you need to get started. Also, there should be a lot of example code somewhere under @INC at Tk/demos/.
- Tk::UserGuide - This gives the basics and general overview. It also contains a list of standard widgets you should familiarize yourself with. Complex widgets are generally built with some combination of these.
- Tk::option - Basic introduction to widget options database & methods
- Tk::options - The standard widget options.
- Tk::Widget - Generic methods for widgets.
- Tk::pack - The most common and easiest geometry manager, its best to start with this one. There are also grid and place and form geometry managers.
- To build complex/custom widgets or subclass existing widgets:
- Events, callbacks & binding:
Update: Here's a pdf Perl Tk reference designed to be printed & folded into a booklet. Its for an older version, but may be helpful to you.
Posts are HTML formatted. Put <p> </p> tags around your paragraphs. Put <code> </code> tags around your code and data!
Read Where should I post X? if you're not absolutely sure you're posting in the right place.
Please read these before you post! —
Posts may use any of the Perl Monks Approved HTML tags:
You may need to use entities for some characters, as follows. (Exception: Within code tags, you can put the characters literally.)
- a, abbr, b, big, blockquote, br, caption, center, col, colgroup, dd, del, div, dl, dt, em, font, h1, h2, h3, h4, h5, h6, hr, i, ins, li, ol, p, pre, readmore, small, span, spoiler, strike, strong, sub, sup, table, tbody, td, tfoot, th, thead, tr, tt, u, ul, wbr
Link using PerlMonks shortcuts! What shortcuts can I use for linking?
See Writeup Formatting Tips and other pages linked from there for more info.
| & || & |
| < || < |
| > || > |
| [ || [ |
| ] || ] ||