pull/11325/merge
Dmitry Zhlobo 2026-06-03 00:29:02 -04:00 committed by GitHub
commit 281cecb054
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
2 changed files with 14 additions and 2 deletions

View File

@ -471,9 +471,14 @@ class TerminalWindow: NSWindow {
guard isVisible else { return }
defer { updateColorSchemeForSurfaceTree() }
// Basic properties
appearance = surfaceConfig.windowAppearance
hasShadow = surfaceConfig.macosWindowShadow
// In non-native fullscreen we force shadow off to avoid the 1px gray window border on macOS 26.
if let fs = terminalController?.fullscreenStyle, fs.isFullscreen, !styleMask.contains(.fullScreen) {
hasShadow = false
} else {
hasShadow = surfaceConfig.macosWindowShadow
}
// Window transparency only takes effect if our window is not native fullscreen.
// In native fullscreen we disable transparency/opacity because the background

View File

@ -227,6 +227,10 @@ class NonNativeFullscreen: FullscreenBase, FullscreenStyle {
// from the edges.
window.styleMask.remove(.resizable)
// We don't need shadow in fullscreen and shadow causes macOS 26 to
// draw a tiny 1px gray border around the window so we disable it.
window.hasShadow = false
// Focus window
window.makeKeyAndOrderFront(nil)
@ -267,6 +271,7 @@ class NonNativeFullscreen: FullscreenBase, FullscreenStyle {
// Restore our saved state
window.styleMask = savedState.styleMask
window.hasShadow = savedState.hasShadow
window.setFrame(window.frameRect(forContentRect: savedState.contentFrame), display: true)
// Removing the "titled" style also derefs all our accessory view controllers
@ -397,6 +402,7 @@ class NonNativeFullscreen: FullscreenBase, FullscreenStyle {
let styleMask: NSWindow.StyleMask
let toolbar: NSToolbar?
let toolbarStyle: NSWindow.ToolbarStyle
let hasShadow: Bool
let titlebarAccessoryViewControllers: [NSTitlebarAccessoryViewController]
let dock: Bool
let menu: Bool
@ -411,6 +417,7 @@ class NonNativeFullscreen: FullscreenBase, FullscreenStyle {
self.styleMask = window.styleMask
self.toolbar = window.toolbar
self.toolbarStyle = window.toolbarStyle
self.hasShadow = window.hasShadow
self.dock = window.screen?.hasDock ?? false
self.titlebarAccessoryViewControllers = if window.hasTitleBar {