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

Hi I'm learning perl and putting together a GUI application using TheLoft design package. In my study of both Perl and the GUI package I'm finding that I'm loosing a lot of time researching the basic questions which I don't seem to find in any documentation so far. For example:

1. Loading a .txt file in to a Richtext box

2. reading a value from a textfield

I found my solutions eventually but it took some digging. My question, apart from digging in to the bowls of the Monastry DB, can anyone recommend a good source of knowledge not of Perl but of the essentials for managing various gui controls? I've got all the Perl books I need just hard to find essential GUI references. I've tried ActivateState (I use Komodo) but even then just the basic $win-> tfTextfieldname-> Text line to read a textfield was hard to find referenced anywhere.

Appreciate any feedback.

Replies are listed 'Best First'.
Re: Basic Win32 Essentials
by BrowserUk (Patriarch) on Jun 26, 2007 at 12:01 UTC

    Have you looked at The docs on sourceforge?

    A quick scan of the methods in RichText control turned up the Load(FILENAME, [FORMAT]) method.

    For the Textfield question, you have to look into the Common Methods link where you find

    Text([TEXT])

    Sets or gets the text associated with a window or control. For example, for windows, this is the text in the titlebar of the window. For button controls, it's the text on the button, and so on. Text() and Caption() are synonymous with one another.

    If you have the ActiveState html docset, the same information is available in there. The WIn32::GUI page has a link to Common methods and there are individual links for most of the controls. There is a lot TBDs, but most of it is there.


    Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
    "Science is about questioning the status quo. Questioning authority".
    In the absence of evidence, opinion is indistinguishable from prejudice.
      Thanks for that advice. Seems I did look in the places you suggested but just not hard enough. Will apply greater care and logic next time. Thanks for replying.
        Will apply greater care and logic next time.

        Sorry if I came across as dismissive of your problems. Guis in general and Win32::GUI in particular are complex beasts and difficult to get to grips with. To compound matters, Win32::GUI documentation is incomplete in many areas. (See all the TBDs littered around). It also relies a lot upon you either having Win32 pre-existing knowledge of the Win32 gui apis and structures, or you finding your way to the MS Windowing APIs reference material.

        It does a pretty good job of hiding the complexities of the underlying APIs, but in doing so, can make it quite hard to relate the MS docs back to the WIn32::GUI wrappers and methods. GUIs (in general) are complex and therefore carry a considerable learning curve. It also means that documenting them is equally hard.

        General questions about better documentation are hard to answer (given that it would require someone to a) become expert; b) encapsulate that knowledge in descent prose). However, this place is generally very good at coming up with specific answers to specific questions. Please don't be put off by my inadvertantly dismissive tone. When you have specific questions, please come back and ask them. Even if you don't get direct answers, you will probably get pointers to help you on your way.


        Examine what is said, not who speaks -- Silence betokens consent -- Love the truth but pardon error.
        "Science is about questioning the status quo. Questioning authority".
        In the absence of evidence, opinion is indistinguishable from prejudice.
Re: Basic Win32 Essentials
by Herkum (Parson) on Jun 26, 2007 at 12:51 UTC

    If you are just learning Perl, and programming in general, you are going to have a hard time writing a GUI application. GUI's are a speciality and require specific knowledge about how they work. If you are learning a language, it is going to become even harder as you learn how it works.

    If you want to learn Perl I would learn on a simpler project than a GUI.