MATLAB Answers

Why does the Simulink Model Window keep losing focus on my Mac Book?

2 views (last 30 days)
Eric
Eric on 14 Feb 2011
I have Matlab/Simulink on my Macbook, and when I create a new model window in Simulink, it'll switch away from that window as soon as I click on it. I'm not sure how else to describe it, but it's like the window deactivates about 1 second after I click on the window. This becomes a nuisance because to do anything, even simply rotating a block (CTRL+R), I have to click on the window and then hurry up and rotate the block before the model window gets deactivated. Is my question clear? It's really annoying and I'm not sure what to do. If someone can please help me, I'd appreciate it. Thanks for your time.

  3 Comments

MarkB
MarkB on 15 Feb 2011
There is similar behavior on KDE in Linux. In that context there is a window manager setting for "focus-stealing prevention". If you lower the threshold (that is, make focus-stealing easier), it seems to fix it. Perhaps there is something similar on Macs?
Jamieson
Jamieson on 16 Feb 2011
Simulink models are X11 windows on the Mac. Can you click on the X11 icon in your dock, select X11 > Preferences from the menu, and then go to the "Windows" tab of "X11 Preferences"? On this tab, what are the values of the options?
I have "Focus on New Windows" checked and "Click-through Inactive Windows" and "Focus Follows Mouse" unchecked and things work well for me on my Mac.
Eric
Eric on 21 Mar 2011
I've played around with checking/unchecking those boxes, and it has no effect. It seems like that should be the issue, though, so I'm not sure why it's not working.

Sign in to comment.

Answers (1)

Seth Popinchalk
Seth Popinchalk on 29 Mar 2011
Simulink models are X11 windows on the Mac. Click on the X11 icon in your dock, select X11 > Preferences from the menu, and then go to the "Windows" tab of "X11 Preferences". On this tab check "Focus on New Windows" and uncheck "Click-through Inactive Windows" and "Focus Follows Mouse".
Some users have reported this works for them.

  0 Comments

Sign in to comment.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by