in reply to Has anyone used wxGlade or wxDesigner to generate code

I tried wxGlade briefly, but to me it was more annoying than just coding what I wanted by hand -- especially since in Perl it's easy to throw together a bunch of small classes that wrap the base Wx libraries and give you a nice interface that does what you want.

For working examples, consider checking out Wx::Demo. It gives you running examples of every class in wxPerl, and the source code is just a click away.

For documentation, all you really need to look at is the C++ Wx reference. Once you learn the few conventions for converting the C++ to Perl you're all set, and when there are any Perl-specific quirks they're noted right in the same reference.

-- David Irving
  • Comment on Re: Has anyone used wxGlade or wxDesigner to generate code

Replies are listed 'Best First'.
Re^2: Has anyone used wxGlade or wxDesigner to generate code
by hangon (Deacon) on Mar 07, 2009 at 18:29 UTC
    Once you learn the few conventions for converting the C++ to Perl you're all set ...

    And therein lies my problem. Being fairly familiar with Perl Tk, I find the Wx Perl examples awkward (especially the new package declaration for each widget - arrrgh). I want to like Wx, I even bought the book, but whenever I try to learn it my brain fogs up, my eyes glaze over, and I go back to Tk.

    The Wx Perl documentation says, as you do, to use C++ documentation and convert to Perl. However, there are no further details and my feeble brain has not been able to get a handle on this conversion. Would you (or anyone) be so kind as to elaborate on the conversion conventions you mentioned?

        Hi guys, thanks for all the discussion. I too have bought the book but sor far only used it as a reference for parameters and descriptions, but not really to interpret (with a small I), the C++ code. I'd vaguely twigged the wx.Frame vs wx::Frame connection, but not to use in earnest. I'd also tried to download the API documentation you refered to, but without success (the compiled HTML windows help did not work and I didn't know what TeX was) so, freshly inspired, I thought I'd try again, this time I downloaded the uncompiled HTML into my intpub directory and browsed it from LOCALHOST and IIS. SHOWTIME! as it says on my rather colloquial router.

        I've been using wxGlade to help me with the syntax for functions. And I probably agree it's easier to code myself - when you know the syntax! But actually, I've knocked up several screens very quickly now, and it's a great prototyping tool to agree screen layouts with users.

        Thanks for your input.
Re^2: Has anyone used wxGlade or wxDesigner to generate code
by Anonymous Monk on Dec 30, 2010 at 18:17 UTC
    I easily installed Wx::Demo on Windows XP. Surprisingly, the documentation does not say how to actually run or invoke the demo. I would have expected at least a code snippet shown. Even better, I would have liked something like PerlWxDemo.exe to have been created. Exactly how does one "run" Wx::Demo?
      run 'wxperl_demo.pl'; under Mac OS X you will need to run 'wxPerl -S wxperl_demo.pl'.
      $ wxperl_demo --help Version: 0.11 Usage: C:\perl\5.10.1\bin/wxperl_demo.bat --help this help --show ??? showing the particular Demo --list list all available modules
        Wow!!!! This is fabulous.
        C:\Perl\site\bin\wxperl_demo.bat
        runs C:\Perl\site\bin\wxperl_demo.pl
        and is so much more than I expected.
        Thanks.