Subject: ns-use-native-fullscreen breaks fullscreen functionality on maverick secondary monitor when old spaces behaviour is selected, plus slow transition

From: Luigi Rocca <[email-masked]>
Date: Wed, 05 Feb 2014 18:42:25 +0100

I am using the following emacs build, from http://emacsformacosx.com/
on an updated Mavericks installation: "GNU Emacs 24.3.50.1 (x86_64-apple-darwin, NS apple-appkit-1038.36) of 2014-01-27 on bob.porkrind.org"

I'm disabling the native fullscreen functionality in my conf file (setq ns-use-native-fullscreen nil) and I have the OSX option "Displays have separate spaces" disabled.

While avoiding the native fullscreen does two very welcome things (the fullscreen window remains on the current space and the other monitor, if attached, is not greyed out) there are two problems:

1) Going fullscreen works only on the primary laptop monitor (I'm using a macbook pro) but not on the secondary monitor on the display port. When the emacs frame is on the secondary monitor, "M-x toggle-frame-fullscreen" has the following results:
- An animation of a small black rectangle goes out of the screen (headed to the lower right part of the screen - please note the secondary monitor is on the upper left wrt the primary one, don't know if this is related or not).
- A brief macosx error sound is played.
- The screen is now empty and emacs is nowhere to be seen, neither primary nor secondary monitor.
- The only way to get the emacs frame back is blindly calling toggle-frame-fullscreen again - the frame then returns to its previous position.

2) Even on the working primary monitor there is still a very slow scaling transition to fullscreen (and back). I find slow animations in Maverick to be annoying and nausea-inducing. Users that are disabling native fullscreen functionality are probably trying to disable the slow transition too (most other open source apps that give the user the option to disable the native fullscreen functionality, such as VLC and iterm2, do exactly this and avoid the slow animation entirely). It seems reasonable to either disable the animation when native fullscreen is disabled or add and additional option to disable it and/or control how fast it is (if I've missed one I'm sorry, please point it out to me).

I've tested one of the several unofficial osx emacs versions that were fullscreen-patched in the past (https://github.com/xajler/emacs24-macosx-lion-fullscreen) and it works as intended on both counts: it goes fullscreen on both monitors and without any animation whatsoever.

If there's anything I can do to help, test etc, please do tell me. I am confortable with building software from source and it is not a problem for me to checkout and build the latest sources if necessary.

Many many thanks for all the amazing work that the emacs developers have done in the past and are still doing on this amazing editor. Keep up the good work!

Cheers,
Luigi Rocca