TkAgg in a Tkinter GUI frame?

Thanks very much, guys!

-Gary

···

----- Original Message -----
From: "Todd Miller" <jmiller@...86...>
To: "John Hunter" <jdhunter@...8...>
Cc: "Gary Pajer" <pajer@...97...>; <matplotlib-users@lists.sourceforge.net>
Sent: Wednesday, March 17, 2004 11:38 AM
Subject: Re: [Matplotlib-users] TkAgg in a Tkinter GUI frame?

On Tue, 2004-03-16 at 07:29, John Hunter wrote:

>
> > I've been poking aroung a bit trying to see if I can locate
> > my plots in a frame in my own Tkinter GUI rather than a
> > stand-alone window.
>
> > It looks like it might be possible if I can, for example,
> > extract the frame instance from a TkAgg plot (or something
> > like that)
>
> > Can anyone comment or suggest a route?
>
> Todd, is this easily doable?

As we all hoped, this was easy and is now in CVS. I refactored
FigureManagerTkAgg and added FigureCanvasTkAgg to support the new
functionality. FigureCanvasTkAgg defines get_tk_widget() to return
whatever tk widget is used to implement it. Currently it returns a Tk
canvas but I thought it would be best not to assume that will always be
the case. Like other Tk widgets, FigureCanvasTkAgg wants to be told
who its parent widget (master) is at construction time.

> Could you write an embedding_in_tk.py
> example along the lines of embedding_in_gtk and embedding_in_wx?

This is also in CVS.

>
Regards,
Todd

>
>
> -------------------------------------------------------
> This SF.Net email is sponsored by: IBM Linux Tutorials
> Free Linux tutorial presented by Daniel Robbins, President and CEO of
> GenToo technologies. Learn everything from fundamentals to system
> administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
> _______________________________________________
> Matplotlib-users mailing list
> Matplotlib-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/matplotlib-users
--
Todd Miller <jmiller@...86...>

Thanks very much, guys!

-Gary

You're welcome! Anyone interested in TkAgg that hasn't updated since I
last announced changes should do so. JDH discovered that the toolbar
was broken and I fixed it about an hour or so ago.

Regards,
Todd

···

On Wed, 2004-03-17 at 15:51, Gary Pajer wrote:

----- Original Message -----
From: "Todd Miller" <jmiller@...86...>
To: "John Hunter" <jdhunter@...8...>
Cc: "Gary Pajer" <pajer@...97...>; <matplotlib-users@lists.sourceforge.net>
Sent: Wednesday, March 17, 2004 11:38 AM
Subject: Re: [Matplotlib-users] TkAgg in a Tkinter GUI frame?

> On Tue, 2004-03-16 at 07:29, John Hunter wrote:

> >
> > > I've been poking aroung a bit trying to see if I can locate
> > > my plots in a frame in my own Tkinter GUI rather than a
> > > stand-alone window.
> >
> > > It looks like it might be possible if I can, for example,
> > > extract the frame instance from a TkAgg plot (or something
> > > like that)
> >
> > > Can anyone comment or suggest a route?
> >
> > Todd, is this easily doable?
>
> As we all hoped, this was easy and is now in CVS. I refactored
> FigureManagerTkAgg and added FigureCanvasTkAgg to support the new
> functionality. FigureCanvasTkAgg defines get_tk_widget() to return
> whatever tk widget is used to implement it. Currently it returns a Tk
> canvas but I thought it would be best not to assume that will always be
> the case. Like other Tk widgets, FigureCanvasTkAgg wants to be told
> who its parent widget (master) is at construction time.
>
> > Could you write an embedding_in_tk.py
> > example along the lines of embedding_in_gtk and embedding_in_wx?
>
> This is also in CVS.
>
> >
> Regards,
> Todd
>
> >
> >
> > -------------------------------------------------------
> > This SF.Net email is sponsored by: IBM Linux Tutorials
> > Free Linux tutorial presented by Daniel Robbins, President and CEO of
> > GenToo technologies. Learn everything from fundamentals to system
> > administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
> > _______________________________________________
> > Matplotlib-users mailing list
> > Matplotlib-users@lists.sourceforge.net
> > https://lists.sourceforge.net/lists/listinfo/matplotlib-users
> --
> Todd Miller <jmiller@...86...>
>

-------------------------------------------------------
This SF.Net email is sponsored by: IBM Linux Tutorials
Free Linux tutorial presented by Daniel Robbins, President and CEO of
GenToo technologies. Learn everything from fundamentals to system
administration.http://ads.osdn.com/?ad_id=1470&alloc_id=3638&op=click
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

--
Todd Miller <jmiller@...86...>