Merge pull request #2489 from hackrmomo/fix/aerospace-resizing-quick-terminal

Fix: aerospace no longer resizes quick terminal and instead treats it as float
This commit is contained in:
Mitchell Hashimoto
2024-10-25 15:12:58 -07:00
committed by GitHub

View File

@ -12,6 +12,14 @@ class QuickTerminalWindow: NSWindow {
// Note: almost all of this stuff can be done in the nib/xib directly
// but I prefer to do it programmatically because the properties we
// care about are less hidden.
// Add a custom identifier so third party apps can use the Accessibility
// API to apply special rules to the quick terminal.
self.identifier = .init(rawValue: "com.mitchellh.ghostty.quickTerminal")
// Set the correct AXSubrole of kAXFloatingWindowSubrole (allows
// AeroSpace to treat the Quick Terminal as a floating window)
self.setAccessibilitySubrole(.floatingWindow)
// Remove the title completely. This will make the window square. One
// downside is it also hides the cursor indications of resize but the