I wonder if it's possible to open a program in Lion fullscreen mode via the Terminal. I want to write a short script which starts a bunch of programs in fullscreen mode, so that I only have to click once to start my working environment.
Here it is:
Here it is in a clearer form (but you can't run it this way):
And this is it as formatted AppleScript:
It works by first opening a Safari window if one is not currently open. Then it simulates the Control ⌃-Command ⌘-F keystroke which tells the Safari window to become full screen.
If you want to make the window the max-size it can be without becoming full screen (i.e. taking up all the space below the menu bar at the top):
Which would become this in Terminal:
For Chrome, do this:
So it would be this in Terminal:
Hope this helps!
|show 3 more comments|
This won't work with applications that don't use native full screen windows, but should work with some that don't use the standard shortcut for entering full screen. A few applications have different process names and application names.
Here's instructions for Google Chrome. (This will open an Incognito window to full-screen.)
Now, every time you launch Google Chrome it will launch full screen in Incognito mode. I use Incognito mode, but if you don't want that, just delete the