mirror of
https://github.com/ghostty-org/ghostty.git
synced 2025-10-01 23:48:35 +00:00
macos: menu item symbols for Tahoe
This is recommended for macOS Tahoe and all standard menu items now have associated images. This makes our app look more polished and native for macOS Tahoe. For icon choice, I tried to copy other native macOS apps as much as possible, mostly from Xcode. It looks like a lot of apps aren't updated yet. I'm absolutely open to suggestions for better icons but I think these are a good starting point. One menu change is I moved "reset font size" above "increase font size" which better matches other apps (e.g. Terminal.app).
This commit is contained in:
11
macos/Sources/Helpers/Extensions/NSMenuItem+Extension.swift
Normal file
11
macos/Sources/Helpers/Extensions/NSMenuItem+Extension.swift
Normal file
@@ -0,0 +1,11 @@
|
||||
import AppKit
|
||||
|
||||
extension NSMenuItem {
|
||||
/// Sets the image property from a symbol if we want images on our menu items.
|
||||
func setImageIfDesired(systemSymbolName symbol: String) {
|
||||
// We only set on macOS 26 when icons on menu items became the norm.
|
||||
if #available(macOS 26, *) {
|
||||
image = NSImage(systemSymbolName: symbol, accessibilityDescription: title)
|
||||
}
|
||||
}
|
||||
}
|
Reference in New Issue
Block a user