Thread Subject: imshow moves figure to other monitor

Subject: imshow moves figure to other monitor

From: David Doria

Date: 14 May, 2008 21:11:01

Message: 1 of 6

I have a dual monitor setup. If i do this

figure

then move the figure to the other monitor, then do

imshow(Data)

it moves the figure back to the original monitor

is there any way to prevent this? Is there a way to specify
which monitor figures get created on initially?

Thanks!

Dave

Subject: imshow moves figure to other monitor

From: Erik

Date: 14 May, 2008 21:23:02

Message: 2 of 6

Hi David,

Try to use the Position property of the figure command, so
for example, if i wanted to make a figure that was one
quarter the size of the screen, positioned in the top left
corner, the following would do the trick,

scrsz = get(0,'ScreenSize');
figure('Position',[1 scrsz(4)/2 scrsz(3)/2 scrsz(4)/2])

Cheers,
Erik

"David Doria" <daviddoria@gmail.com> wrote in message
<g0fkh5$8o1$1@fred.mathworks.com>...
> I have a dual monitor setup. If i do this
>
> figure
>
> then move the figure to the other monitor, then do
>
> imshow(Data)
>
> it moves the figure back to the original monitor
>
> is there any way to prevent this? Is there a way to specify
> which monitor figures get created on initially?
>
> Thanks!
>
> Dave

Subject: imshow moves figure to other monitor

From: David Doria

Date: 14 May, 2008 21:40:04

Message: 3 of 6

yea i've used position in the past... but that still doesn't
say WHICH monitor to position it on? or does it treat them
both as 1 long one?

Subject: imshow moves figure to other monitor

From: Erik

Date: 14 May, 2008 22:46:02

Message: 4 of 6

I'm assuming it would treat it as one long monitor. In fact,
when I change the parameters so the window opens outside of
my viewable area, I can see that it gets sent outside my
screen. I'm pretty sure this should work.

Erik

"David Doria" <daviddoria@gmail.com> wrote in message
<g0fm7k$k77$1@fred.mathworks.com>...
> yea i've used position in the past... but that still doesn't
> say WHICH monitor to position it on? or does it treat them
> both as 1 long one?

Subject: imshow moves figure to other monitor

From: Raghuveer Parthasarathy

Date: 24 Jul, 2009 00:19:02

Message: 5 of 6


   I have a similar problem to that posted below: I create a figure and use the 'Position' property to place it on my second monitor. If I display an image in this figure using 'imshow,' it moves the figure to the first monitor. I can then move the figure back to the second monitor using the Position property again, but I'd like to avoid this since it involves jerky flickering of the image position that makes it unusable for my application.

   It looks like 'imshow' gets confused by the figure position being outside the bounds of the primary monitor (as reported e.g. by scrsz = get(0,'ScreenSize'); ). Any thoughts on how to get it to behave more intelligently would be greatly appreciated!

best wishes,

Raghu


Creating a figure and displaying
"David Doria" <daviddoria@gmail.com> wrote in message <g0fkh5$8o1$1@fred.mathworks.com>...
> I have a dual monitor setup. If i do this
>
> figure
>
> then move the figure to the other monitor, then do
>
> imshow(Data)
>
> it moves the figure back to the original monitor
>
> is there any way to prevent this? Is there a way to specify
> which monitor figures get created on initially?
>
> Thanks!
>
> Dave

Subject: imshow moves figure to other monitor

From: Thomas

Date: 25 Mar, 2011 00:57:05

Message: 6 of 6

An old thread, but for the benefit of the next person to search for this (like I did):
If you specify the parent, it seems imshow won't move the figure.
E.g.
  imshow(im, 'parent', gca);
-tb
"David Doria" <daviddoria@gmail.com> wrote in message <g0fkh5$8o1$1@fred.mathworks.com>...
> I have a dual monitor setup. If i do this
>
> figure
>
> then move the figure to the other monitor, then do
>
> imshow(Data)
>
> it moves the figure back to the original monitor
>
> is there any way to prevent this? Is there a way to specify
> which monitor figures get created on initially?
>
> Thanks!
>
> Dave

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
imshow Thomas 24 Mar, 2011 20:59:21
figure Raghuveer Parthasarathy 23 Jul, 2009 20:24:04
imshow Raghuveer Parthasarathy 23 Jul, 2009 20:24:04
rssFeed for this Thread

Contact us at files@mathworks.com