Screens open off monitor
21 views (last 30 days)
Show older comments
I've spent the last hour or two trying to solve this from other's posts, but they don't seem to resolve the issue.
I'm ssh'ing into a remote unix server, which I am not the admin on, and other users use the same matlab install. I've tried both ssh -X and ssh -Y (I don't have the following issue with anything but matlab so..)
I'm using a dual screen setup, one vertical, one horizontal.
When I run matlab, I get : Attempted to access monitors(1,:); index out of bounds...
I've tracked this (supposedly) to the hgrc file.
However, I do not have write access to this.
The problem I'm facing is that ANY matlab window piece might open up off screen, and incorrectly sized. Such as the "open file" interface, or editors, or the main cmd window, etc.
I've tried correcting the default figure position, but that does not seem to resolve the issue.
I think I've seen a solution posted here that worked a while ago, but for the life of me can not find it again.
0 Comments
Answers (1)
Daniel Shub
on 23 Nov 2011
It seems like you have two issues. First, MATLAB doesn't handle dual monitors all that well. It handles dual monitors with different sizes (orientations) or odd spatial configurations even worse. I do not know of a work around for this. Most of the dialogs set their own positions and do not rely on the default figure position. Depending on your OS/window manager you might be able to capture the windows and put the figures where you want them. Resizing them is harder since some dialogs cannot be resized.
As for the monitors(1,:) access, I think this means
get(0, 'MonitorPositions')
is returning something strange. I don't think there is a work around.
Have you tried running MATLAB without a desktop (matlab -nodesktop)?
0 Comments
See Also
Categories
Find more on Startup and Shutdown in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!