Kitematic: Option-Click on Mac Should Maximize

Created on 8 Jul 2016  路  13Comments  路  Source: docker/kitematic

Expected behavior

Option-clicking on the green button in the title bar should cause the window to maximize without going fullscreen.

Actual behavior

The window goes into fullscreen mode.

Steps to reproduce the behavior

  1. Option-click on the green button in the titlebar.
exbeginner help wanted mac

Most helpful comment

Looks like the code VSC uses to maximize the window after starting it up is here: https://github.com/Microsoft/vscode/blob/a24a92384048d82dbb387483082ba1cfef4ee2c1/src/vs/code/electron-main/window.ts#L206

Like you said, maybe electron needs to be updated in Kitematic?

All 13 comments

  1. I open Google Chrome on Mac OSX
  2. I click on the green button in the title bar
  3. Google Chrome is now fullscreen mode

This is 馃挴 the behavior that kitematic follows and just about any other app I believe.

missed the OPT+Click didn't even know this existed.
It seems to only maximize vertically?

In chrome it tends to only maximize vertically - it actually depends on the width of the webpage you are on - if it's wider than the current window it will also expand horizontally (though not necessarily to the full width of the screen). OPT+Click restores the pre-fullscreen behavior of windows on Mac. I use it quite a bit as I don't like the fullscreen implementation when using multiple monitors so I often want to just expand the window quickly. Vertical only expansion would be fine for Kitematic I think as I mainly want to be able to see more log lines and it would be consistent with Chrome, although horizontal expansion would be nice.

Is somebody already working on this? I am interested to check this

It's more like a common Electron bug. There are options for maximize and fullscreen window but there seem to be no difference between them https://github.com/electron/electron/blob/master/docs/api/browser-window.md.

I tried adding options maximizable and fullscreenable but this won't change the behaviour. They may be available only with more recent electron version.

Interesting. Visual Studio Code is also based on electron, but it demonstrates the correct behavior. Opt-Click on the green button maximizes the window to fill my screen.

Looks like the code VSC uses to maximize the window after starting it up is here: https://github.com/Microsoft/vscode/blob/a24a92384048d82dbb387483082ba1cfef4ee2c1/src/vs/code/electron-main/window.ts#L206

Like you said, maybe electron needs to be updated in Kitematic?

Oh I get it now, it's because we are using frame: false and implement custom mac window buttons. I will check where I can customize it.

@mikaoelitiana We've discussed re-using the normal frame.
If you want to take a shot at doing this, it may solve a few of the above issues, along with a streamlined look and feel for each OS

@frenchben yes I have tried with normal frame and it works fine. I will then remove current buttons and check it in each platform

I ended up with something like this in Mac:

capture d ecran 2016-07-18 a 09 24 44

I have yet to check in Windows and Linux.

It's working fine in linux as well

virtualbox_ubuntu_18_07_2016_10_26_30

I just opened the PR that fixes this

Was this page helpful?
0 / 5 - 0 ratings

Related issues

cnBruceHong picture cnBruceHong  路  4Comments

EugeneKrapivin picture EugeneKrapivin  路  4Comments

rick02840 picture rick02840  路  3Comments

ClemMakesApps picture ClemMakesApps  路  3Comments

rbq picture rbq  路  4Comments