If I have already started Google Chrome, then start it again, the window is not maximized; I have to click to maximize it.
Are there any hidden parameters to set Google Chrome to always start in a maximized window? (not full screen - F11)
Super User is a question and answer site for computer enthusiasts and power users. It only takes a minute to sign up.Sign up to join this community
Extending the solution said by Yab as follows:
Rename the first instance to something else e.g. wmctrl -r "New Tab - Google Chrome" -T "test"
Now maximize the second instance as:
wmctrl -r "New Tab - Google Chrome" -b add,maximized_vert,maximized_horz
These two commands will maximize the second instance of Google Chrome.
If you want, you can put this in a script to call the second instance.
Edit: It has been pointed out that the following parameter is no longer supported by current versions of Chrome. I'll see if I can find some time to revisit this shortly.
Google Chrome accepts the command-line parameter
--start-maximized, which will force Chrome to start in a maximized state.
Simply modify the shortcut you use to launch Chrome to include this flag, or simply alias
chrome --start-maximized. I've tested this in both Chrome and Chromium under Windows and Linux, and it seems to work just fine.
Sometimes the window state fails to save your last setting due to lack of permissions and therefore keeps opening in the non-maximized mode. You can perform the following to change the owner:group back to yourself for the files:
sudo chown youracct:youracct ~/.config/google-chrome/Local\ State sudo chown youracct:youracct ~/.config/google-chrome/Default/Preferences
By default, Chrome chooses to apply its own window decorations rather than the window manager ones, and accept responsibility for implementing various pieces of logic. It tends to work well enough in Gnome and KDE environments and less well the further you stray from those.
If you right-click in the title-bar area, there's an option to turn on using the system window manager controls. If you do that, Chrome might inter-operate better with your regular window manager and more reliably implement full-screen. Or, it might get worse — it's unfortunately one of those "suck it and see" changes, the success of which varies wildly across both window manager and version of Chrome. I've had it make some things better and some things worse, when I was using
xfwm4, with a later release of Chrome working better with its own window decorations than with the system ones, for my setup.
--start-maximize switch will work if you use a windows manager. X session itself is unaware of window's maximization.
In case you want to save some resources using no windows manager, you could employ xdotool:
xdotool search --onlyvisible --class browser windowsize 100% 100%
Adding an answer for variety, because this thread helped me write a script just now.
Open a google-chrome window. Get it's window id based on window title substring match. (move it to screen 0). Make it fullscreen.
#!/bin/bash google-chrome --new-window --app=https://fragginwithfriends.gameme.com/ sleep 2s wid=$(xdotool search --onlyvisible --name "gameME Stats") xdotool windowmove $wid 0 1080 wmctrl -ir $wid -b add,fullscreen
I think I may have your solution. I was having the same problem and this is how I fixed it. The problem I had was not with Chrome but with Windows 7. The browser was not opening full due to a windows "padding" setting. (it reminded me of a CSS issue)
Try this... I use a tweaker called "ultimate windows tweaker" found here link for examples and DL
But you can change your padding here manually. Instructions
How ever you change it is up to you.
Now make sure you change the padding to "0"
Once that is done you will need to re-make your apps.
Now Try going to GMAIL(or whatever), then tools, create application shortcut, apply to desktop. When you are done there it is the same as before... properties>RUN>Maximized
Good luck I hope this clears up the issue. -Mike