fix: disable renderer background when macOS effects are enabled

This commit is contained in:
Justy Null
2025-09-20 16:05:05 -07:00
committed by Mitchell Hashimoto
parent d40af61960
commit 45aceace72
5 changed files with 27 additions and 18 deletions

View File

@@ -480,7 +480,7 @@ class TerminalWindow: NSWindow {
backgroundColor = .white.withAlphaComponent(0.001)
// Add liquid glass behind terminal content
if #available(macOS 26.0, *), derivedConfig.macosBackgroundStyle != .blur {
if #available(macOS 26.0, *), derivedConfig.macosBackgroundStyle != .defaultStyle {
setupGlassLayer()
} else if let appDelegate = NSApp.delegate as? AppDelegate {
ghostty_set_window_background_blur(
@@ -633,7 +633,7 @@ class TerminalWindow: NSWindow {
self.backgroundColor = NSColor.windowBackgroundColor
self.backgroundOpacity = 1
self.macosWindowButtons = .visible
self.macosBackgroundStyle = .blur
self.macosBackgroundStyle = .defaultStyle
self.windowCornerRadius = 16
}

View File

@@ -262,7 +262,7 @@ extension Ghostty {
}
var macosBackgroundStyle: MacBackgroundStyle {
let defaultValue = MacBackgroundStyle.blur
let defaultValue = MacBackgroundStyle.defaultStyle
guard let config = self.config else { return defaultValue }
var v: UnsafePointer<Int8>? = nil
let key = "macos-background-style"

View File

@@ -354,7 +354,7 @@ extension Ghostty {
/// Enum for the macos-background-style config option
enum MacBackgroundStyle: String {
case blur
case defaultStyle = "default"
case regularGlass = "regular-glass"
case clearGlass = "clear-glass"
}