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

Hi. I'm new to PerlMonks so I hope I'm in the right place. Using Chart::Gnuplot or Chart::GnuplotIF I can plot my data with ease and output it to a file or it's own window (using terminal => 'wxt'). I like the dynamic zoom capability of the Gnuplot window and want to retain that capability. My question is this: Is there a way to drop the gnuplot window or the corresponding plot into a wxFrame or wxPanel? Thanks in advance.

Replies are listed 'Best First'.
Re: Gnuplot to wxPerl Frame
by Anonymous Monk on Jan 21, 2014 at 22:39 UTC
    sure but not portably ... same trick as Perl/Tk front-end to mplayer you can use with wxwidgts and mplayer

    I wouldn't be surprised if gnuplot supports the same option as mplayer (taking id of native window where to draw )

    other alternative is to wrap (for wxperl) one of the wrappers for wxwidgets for gnuplot (they must exist)

Re: Gnuplot to wxPerl Frame
by zentara (Cardinal) on Jan 22, 2014 at 16:01 UTC
      Does that popup a seperate window for you?
        Does that popup a seperate window for you?

        Short Answer: No. It displays within the Tk window space

        Long answer: I assume you are referring that question to me and the Superformula link I left above.

        If that is the case, the issue with the separate window comes what Gnuplot driver you are using. Read the docs or google for "Gnuplot drivers". You may a default setting in the Gnuplot resource file, to pop a separate window.


        I'm not really a human, but I play one on earth.
        Old Perl Programmer Haiku ................... flash japh