TkAgg vs. GTKAgg ioff cla behavior

I ran into a difference between the GTKAgg and TkAgg backends that is
confusing me. If I run this set of commands using the two different
backends, I get different results:

t=arange(0,1,0.01)
y=sin(2*pi*t)
figure(1)
plot(t,y)
ioff()
cla()
show()

With the TkAgg backend, after show(), the figure is blank. With the
GTKAgg backend, once I call ioff, it seems to be ignoring me. In
fact, if I run this:

t=arange(0,1,0.01)
y=sin(2*pi*t)
y2=cos(2*pi*t)
figure(1)
plot(t,y)
ioff()
cla()
plot(t,y2)
show()

the GTKAgg backend does not show the plot of y2.

Is this a bug, something wrong on my system, or does it make sense
that the GTKAgg backend ignores everything after ioff()?

Thanks,

Ryan

ioff seems to work o.k. with the GTKAgg backend as long as the figure
hasn't been created yet:

ioff()
figure(2)
plot(t,y)
plot(t,y2)
show()

works fine if figure(2) doesn't exist yet.

Ryan

ยทยทยท

On 3/15/06, Ryan Krauss <ryanlists@...287...> wrote:

I ran into a difference between the GTKAgg and TkAgg backends that is
confusing me. If I run this set of commands using the two different
backends, I get different results:

t=arange(0,1,0.01)
y=sin(2*pi*t)
figure(1)
plot(t,y)
ioff()
cla()
show()

With the TkAgg backend, after show(), the figure is blank. With the
GTKAgg backend, once I call ioff, it seems to be ignoring me. In
fact, if I run this:

t=arange(0,1,0.01)
y=sin(2*pi*t)
y2=cos(2*pi*t)
figure(1)
plot(t,y)
ioff()
cla()
plot(t,y2)
show()

the GTKAgg backend does not show the plot of y2.

Is this a bug, something wrong on my system, or does it make sense
that the GTKAgg backend ignores everything after ioff()?

Thanks,

Ryan