22

How can i get rid of the gap at the bottom of the screen when i maximized a window? The gap is almost imperceptible but at the bottom of a maximized window a few pixel are not filled, there one can see the desktop. If i go into full screen mode with a window, the 5 - 10 pixels get filled.

My os version is OS X 10.9 Mavericks

the maximized window

To better see the issue I enlarged the part at the bottom:

selection

  • This had been driving me mad for years but it seems to be fixed in MacOS 10.13.x (High Sierra). Hooray! Can anyone else confirm? – BlueC Feb 9 '18 at 15:31
9

Those 5 pixels are tied to the Dock. You can position the dock on either the left of right side instead, but the gap stays on the side of the Dock. I think this is something fairly low level with the Dock, as window managers (like Spectacle) will maximize windows and not use the gap.

My $0.02: If you have a lot of screen real estate, as it looks like you do, I say shrink some of your windows to a more appropriate size and/or fullscreen windows instead of maximizing them.

  • 2
    Afaik you can't extend the window yourself to the actual bottom of the screen if the Dock is at the bottom (10.9 & 10.10). What version of OS X are you on? +1 for the rest of the answer though – grg Aug 12 '14 at 17:41
  • @GeorgeGarside Oh shoot, you're right. – Dillon Aug 12 '14 at 17:42
  • 1
    I use BetterSnapTool for organizing my windows in a better way. That still doesn't allow me to use those 5 px as well - yes it has something to do with the Dock. – Mirco Widmer Aug 12 '14 at 17:44
  • The only way to do it yourself is to move the window down 5px then resize the top edge 5px – 0942v8653 Aug 21 '14 at 16:37
  • 1
    @Patience: Actually… I kind of do some work on window managers myself, and there currently isn't a way to do that with the API Apple gives. All you can do is set the top left corner position and the size, much like when you could only resize in the bottom right. See page 20 of this document if you want to see the descriptions. The Accessibility API is a real pain to work with. – 0942v8653 Aug 21 '14 at 20:46
5

Drag the entire window down until it covers up the gap. Then resize the window at the top to cover the gap left at the top of the screen. Then you have no gaps.

  • 3
    Great suggestion. Unfortunately it doesn't stay like that when you open a document again. – Skeleton Bow Feb 8 '17 at 19:34
  • And it doesn't work for me on macOS Sierra 10.12.4. – Emile Bergeron Apr 27 '17 at 22:49
  • It works for me on macOS Sierra 10.12.6 – Skeleton Bow Jul 5 '17 at 15:34
  • it worked for me! – incandescentman Sep 26 '17 at 1:43
4

I've come across a few ways to work around or completely fix this:

1) Minimize the effects with the following settings under System Preferences > Dock:

  • Automatically hide and show the Dock
  • Position on screen: Right (or left)

If you want to achieve that with a script instead, it'd be:

  • defaults write com.apple.dock autohide -bool true
  • defaults write com.apple.Dock orientation -string right

This makes the windows on my primary monitor truly maximized when I alt+shift+click the green window button. The windows on my secondary monitor still have the gap, but it's much less noticeable on the side of the window than the bottom, and I don't look at that monitor as often as my primary one anyway.

2) Override the Dock's gap completely with BetterTouchTool or BetterSnapTool. I haven't tried this personally, but I've read several sites saying that they fix this problem (for example).

2

Either change your desktop wallpaper to black, so you don't notice it; or add a black 5px line to the bottom of your preferred wallpaper.

  • 1
    there are windows with white edges ;) – Srneczek Apr 27 '16 at 13:18
2

I actually hacked the system... based on some of the other answers.

You can temporarily move the docker on the left, expand your window, and then move the docker back to the bottom. The window stays then.

Also note that Chrome is not affected at all by this nasty "bug". In my case, only Emacs is.

EDIT: For crying out loud; when you ALT-TAB the effect is gone.

  • 2
    Not only that, when you quit the app and opened it again, it will go back to its original size ;) – Skeleton Bow Feb 8 '17 at 19:44
1

You may use a program like GeekTool or Übersicht to add a black bar to the bottom of the screen. In this way you can essentially make the gap less visible, especially if your wallpaper stands out.

1

I made an AppleScript to achieve this. Unfortunately, after invoking the AppleScript, you'll notice that there is a gap between the menu bar and the window – you need to manually resize the window upwards to remove it (do not double click it, or else the dock gap will come back). However, after these two steps, there will be no dock gap – just as you had wanted.

on run

    tell application "System Events"
        set FrontMostApp to name of first item of (processes whose frontmost is true)
    end tell

    tell application FrontMostApp
        activate
        set bounds of front window to {0, 26, 1280, 800}
    end tell

end run

One other thing – this is made for 13" MacBooks with a base screen resolution of 1280x800. You may need to change those bounds according to the model of your Mac.

Important: please use your own resolution if your resolution isn't an integer multiple of 1280x800.

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .