diff --git a/src/macosx/MacMiniFB.m b/src/macosx/MacMiniFB.m index 076d2bc..f7b892c 100644 --- a/src/macosx/MacMiniFB.m +++ b/src/macosx/MacMiniFB.m @@ -26,7 +26,8 @@ int mfb_open(const char* name, int width, int height) NSWindowStyleMask styles = NSWindowStyleMaskResizable | NSWindowStyleMaskClosable | NSWindowStyleMaskTitled; NSRect rectangle = NSMakeRect(0, 0, width, height); - window_ = [[OSXWindow alloc] initWithContentRect:rectangle styleMask:styles backing:NSBackingStoreBuffered defer:NO]; + NSRect frameRect = [NSWindow frameRectForContentRect:rectangle styleMask:styles]; + window_ = [[OSXWindow alloc] initWithContentRect:frameRect styleMask:styles backing:NSBackingStoreBuffered defer:NO]; if (!window_) return 0;