From: Benjamin Lewis on
I'm trying to copy a figure that's been created by a GUI to the clipboard using print -dmeta. However, whenever I do this, the GUI gets copied to the clipboard instead. For example, if I do:

figure(1)
print -dmeta

I'd expect to get figure one on the clipboard. But I don't. if I gcf, it shows up as 1. Interestingly enough, if I use print -dbitmap, gcf gets changed to the figure handle of the gui, (also, this handle seems to be a non-integer...), and the wrong figure gets copied. Ideas? Is this a bug?

I'm on r2009b for reference.
From: Pekka Kumpulainen on
"Benjamin Lewis" <blewis(a)email.arizona.edu> wrote in message <huhja7$gs5$1(a)fred.mathworks.com>...
> I'm trying to copy a figure that's been created by a GUI to the clipboard using print -dmeta. However, whenever I do this, the GUI gets copied to the clipboard instead. For example, if I do:
>
> figure(1)
> print -dmeta
>
> I'd expect to get figure one on the clipboard. But I don't. if I gcf, it shows up as 1. Interestingly enough, if I use print -dbitmap, gcf gets changed to the figure handle of the gui, (also, this handle seems to be a non-integer...), and the wrong figure gets copied. Ideas? Is this a bug?
>
> I'm on r2009b for reference.

print(1,'-dmeta')
will print figure 1
From: Benjamin Lewis on
"Pekka Kumpulainen" <pekka.nospam.kumpulainen(a)tut.please.fi> wrote in message <huimks$4bp$1(a)fred.mathworks.com>...
> "Benjamin Lewis" <blewis(a)email.arizona.edu> wrote in message <huhja7$gs5$1(a)fred.mathworks.com>...
> > I'm trying to copy a figure that's been created by a GUI to the clipboard using print -dmeta. However, whenever I do this, the GUI gets copied to the clipboard instead. For example, if I do:
> >
> > figure(1)
> > print -dmeta
> >
> > I'd expect to get figure one on the clipboard. But I don't. if I gcf, it shows up as 1. Interestingly enough, if I use print -dbitmap, gcf gets changed to the figure handle of the gui, (also, this handle seems to be a non-integer...), and the wrong figure gets copied. Ideas? Is this a bug?
> >
> > I'm on r2009b for reference.
>
> print(1,'-dmeta')
> will print figure 1

Sure, and that's what I ended up doing, but it's less convenient, and I'd still like to get print -dmeta working the way it's supposed to....