You are not logged in. You can browse but not post. Login or Register by clicking 'Login or Register' at the top-right of this page. For more information on Statalist, see the FAQ.
Stata 17 in Mac OS 12.1 does not have close button
Hi there
I have a very unnormal question. This is my first time to install the Stata 17 in my MacBook Pro m1 but I found there is not have a close button in it. I've never met before.
Stata/SE 17.0 for Mac (Intel 64-bit)
Revision 17 Jan 2022
on macOS Monterey 12.1.
All the subsidiary windows (Viewer, Do-file Editor, etc.) have the close button, but not the main window. Never noticed this before, I don't use the close button for Stata. I find that if I quit Stata through any means other than Quit Stata (command-Q) on the Stata menu, the chances are good that if I have unsaved data or unsaved Do-files, Stata will fail to quit properly and will hang, and have to be force-quit to exit. This is particularly annoying, it is the only app on my system that typically fails to quit when Shut Down from the Apple menu. But in general there are a number of user interface issues with non-Mac-like behavior that I've just become accustomed to.
Added in edit: I note that in the Getting Started with Stata for Mac PDF in my Stata 17 installation, pages 24 and 25 have screen shots that show that the close button is not available. So this qualifies as a documented, if inexplicable, feature.
Stata/SE 17.0 for Mac (Intel 64-bit)
Revision 17 Jan 2022
on macOS Monterey 12.1.
All the subsidiary windows (Viewer, Do-file Editor, etc.) have the close button, but not the main window. Never noticed this before, I don't use the close button for Stata. I find that if I quit Stata through any means other than Quit Stata (command-Q) on the Stata menu, the chances are good that if I have unsaved data or unsaved Do-files, Stata will fail to quit properly and will hang, and have to be force-quit to exit. This is particularly annoying, it is the only app on my system that typically fails to quit when Shut Down from the Apple menu. But in general there are a number of user interface issues with non-Mac-like behavior that I've just become accustomed to.
Added in edit: I note that in the Getting Started with Stata for Mac PDF in my Stata 17 installation, pages 24 and 25 have screen shots that show that the close button is not available. So this qualifies as a documented, if inexplicable, feature.
Thank you for your reply. This at least lets me know I am not the only one who has this question. Should we need to respond to this question to statat llc?
StataNow/MP 18.5 for Mac (Apple Silicon)
Revision 18 Dec 2024
I wouldn't be surprised if it's been true for many previous versions of Stata on many previous versions of macOS too. I just don't use the close button on most applications, so that's why I probably never noticed.
But it is the 'close window' functionality that is missing, not merely the button. The keyboard alternative to the close button, that is ⌘W, also does not work.* As suggested in #2, I think this is not a bug, but an intended feature in Mac versions of Stata.
* if I press ⌘W while the Results or Variables window is in focus, it switches focus to the Command window. If I do it when the Properties window is in focus, it gives me an error beep. If I do it while the Command window is in focus, nothing appears to happen. But no window closes in any scenario.
It's funny how often this comes up. In most applications, clicking the close button closes the document. In other applications, clicking the close button closes the application. As a long time Mac user, I've always used cmd-Q to quit an application. What are you expecting to happen if you click the close button on the main Stata window? Close the window or close the application? From what I can see from apps that ship with macOS, clicking the close button on the main window will quit the app only in apps that don't prompt you about unsaved documents. For apps that may prompt you, they simply close the document window. In Stata 15 and earlier, we simply closed (hid) the main Stata window instead of quitting the application.
Regardless, here's why there's no close button in the main Stata window in modern Stata's. The majority of Stata for Mac users use laptops where screen real estate is limited. We wanted a way to allow as many of Stata's windows to be tabbed together as possible and recent versions of macOS have native tabbed window support that allows you to easily do that (but it's a little inflexible). You can actually tab Viewer windows, Do-file Editor windows, the Data Editor window, and graph windows to the main Stata window (you have to set a preference for each window type first). Here's where the problem comes in. If you have multiple windows tabbed to the main Stata window, clicking the close button on the main Stata window will also close every window tabbed to it. You'll still get prompted for unsaved documents but the whole experience of all the windows closing is really surprising if you thought clicking the close button would simply hide the Stata window. Well why couldn't we simply close just the main Stata window in that case and leave all the other windows up? Here's where the inflexibility comes in. We're never told by macOS that's going to happen, all the windows are just simply closed. So the easiest solution was to just not allow closing of the main Stata window.
Comment