Commit Graph

618 Commits (78e539d68453fcedb29b31c7a296a9a816c7858e)

Author SHA1 Message Date
Mitchell Hashimoto a6ddf03a2e
remove the macos-background-style config 2025-12-15 10:54:35 -08:00
Mitchell Hashimoto bb23071166
config: change macos-background-style to be enums on background-blur 2025-12-15 10:42:21 -08:00
Justy Null 45aceace72 fix: disable renderer background when macOS effects are enabled 2025-12-15 10:12:11 -08:00
Justy Null d40af61960 refactor: migrate background glass effect to new macos-background-style config 2025-12-15 10:10:51 -08:00
Justy Null a02364cbef feat: add liquid glass background effect support 2025-12-15 10:10:51 -08:00
Mitchell Hashimoto 05ee9ae733
macos: implement goto_window:next/previousu 2025-12-13 14:33:17 -08:00
Mitchell Hashimoto 19e0864688
macos: unintended change 2025-12-12 14:14:15 -08:00
Mitchell Hashimoto 43b4ed5bc0
macos: only show readonly badge on AppKit 2025-12-12 14:12:05 -08:00
Mitchell Hashimoto 22b8809858
macos: add a popover to the readonly badge with info 2025-12-12 14:02:45 -08:00
Mitchell Hashimoto 173d8efd90
macos: add to context menu 2025-12-12 13:55:03 -08:00
Mitchell Hashimoto ceb1b5e587
macos: add a read-only menu item in View 2025-12-12 13:53:08 -08:00
Mitchell Hashimoto ec2638b3c6
macos: readonly badge 2025-12-12 13:46:28 -08:00
Mitchell Hashimoto 6105344c31
macos: add change tab title to right click menu 2025-12-11 16:30:06 -08:00
Mitchell Hashimoto 65cf124e2c
core: change apprt action to enum value instead of a new one 2025-12-11 16:09:45 -08:00
Mitchell Hashimoto e93a4a911f
macos: implement prompt_tab_title 2025-12-11 16:03:30 -08:00
George Papadakis 625d7274bf Add close tabs on the right action 2025-12-10 20:14:27 -08:00
Daniel Wennberg 93d77ae436 Always use overlay scroller, flash when mouse moved 2025-12-10 13:33:18 -08:00
Lars 0c9082eb72
macOS: fix theme reloading
### Background
After #9344, the Ghostty theme won't change after switching systems', and reverting #9344 will bring back the issue it fixed.

The reason these two issues are related is because the scheme change is based on changes of `effectiveAppearance`, which is also affected by setting the window's `appearance` or changing `NSAppearance.currentDrawing()`.

### Changes
Instead of observing `effectiveAppearance`, we now explicitly update the color scheme of surfaces, so that we can control when it happens to avoid callback loops and redundant updates.

### Regression Tests

- [x] #8282
- [x] Reloading with `window-theme = light` should update Ghostty with the default dark theme with a dark window theme (break before [#83104ff](83104ff27a))
- [x] `window-theme = light \n macos-titlebar-style = native` should update Ghostty with the default dark theme with a light window theme
- [x] Reloading from the default config to `theme=light:3024 Day,dark:3024 Night \n window-theme = light`, should update Ghostty with the theme `3024 Day` with a light window theme (break on [#d39cc6d](d39cc6d478))
- [x] Using `theme=light:3024 Day,dark:3024 Night`; Switching the system's appearance should change Ghostty's appearance (break on [#d39cc6d](d39cc6d478))
- [x] Reloading from `theme=light:3024 Day,dark:3024 Night` with a light window theme to the default config, should update Ghostty with the default dark theme with a dark window theme
- [x] Reloading from the default config to `theme=light:3024 Day,dark:3024 Night \n window-theme=dark`, should update Ghostty with the theme `3024 Night` with a dark window theme
- [x] Reloading from `theme=light:3024 Day,dark:3024 Night \n window-theme=dark` to `theme=light:3024 Day,dark:3024 Night` with light system appearance, should update Ghostty from dark to light
- [x] Reload with quick terminal open

# Conflicts:
#	macos/Sources/Features/Terminal/BaseTerminalController.swift
2025-12-07 09:18:45 +01:00
Mitchell Hashimoto 5c1679209d
macos: add hover styles to search buttons, cursor changes 2025-11-27 13:01:51 -08:00
Lukas dc08d057fe
macOS: use ConcentricRectangle on Tahoe 2025-11-26 21:00:14 +01:00
Lukas cbcd52846c
macOS: fix search dragging animation when corner is not changed 2025-11-26 21:00:14 +01:00
Qwerasd 4b01163c79 fix(macos): use strings' utf-8 lengths for libghostty calls
Swift conveniently converts strings to UTF-8 encoded cstrings when
passing them to external functions, however our libghostty functions
also take a length and we were using String.count for that, which
returns the number of _characters_ not the byte length, which caused
searches with multi-byte characters to get truncated.

I went ahead and changed _all_ invocations that pass a string length to
use the utf-8 byte length even if the string is comptime-known and all
ASCII, just so that it's proper and if someone copies one of the calls
in the future for user-inputted data they don't reproduce this bug.

ref:
https://developer.apple.com/documentation/swift/string/count
https://developer.apple.com/documentation/swift/stringprotocol/lengthofbytes(using:)
2025-11-26 12:00:58 -07:00
avarayr f5b923573d
macOS: move search result counter inside text field
Move the search result counter (e.g. "1/30") inside the search text
field using an overlay, preventing layout shift when results appear.

This PR was authored with Claude Code.
2025-11-26 13:04:05 -05:00
Mitchell Hashimoto 5b4394d211
macos: end_search for ending search 2025-11-26 08:57:24 -08:00
Mitchell Hashimoto c51170da9c
add end_search binding 2025-11-26 08:50:06 -08:00
Mitchell Hashimoto f7b14a0142
macos: debounce search requests with length less than 3 2025-11-26 08:50:06 -08:00
Mitchell Hashimoto 339abf97f7
macos: can allow single char searches now 2025-11-26 08:50:06 -08:00
Mitchell Hashimoto 1bb2d4f1c2
macos: only end search if we previously had one 2025-11-26 08:50:05 -08:00
Mitchell Hashimoto 93656fca5a
macos: show progerss correctly for search 2025-11-26 08:50:05 -08:00
Mitchell Hashimoto 0e974f85ed
macos: fix iOS build 2025-11-26 08:50:05 -08:00
Mitchell Hashimoto c20af77f98
macos: handle search progress/total apprt actions 2025-11-26 08:50:05 -08:00
Mitchell Hashimoto d4a2f3db71
macos: search overlay shows search progress 2025-11-26 08:50:05 -08:00
Mitchell Hashimoto 7835ad0ea4
macos: more menu items 2025-11-26 08:50:05 -08:00
Mitchell Hashimoto 3f7cfca4b4
macos: add find menu item 2025-11-26 08:50:05 -08:00
Mitchell Hashimoto 949a8ea53f
macos: dummy search state for iOS 2025-11-26 08:50:05 -08:00
Mitchell Hashimoto cfbc219f5c
macos: enter and shift+enter move the results 2025-11-26 08:50:04 -08:00
Mitchell Hashimoto efc05523e0
macos: enter goes to next result 2025-11-26 08:50:04 -08:00
Mitchell Hashimoto 3ce19a02ba
macos: hook up the next/prev search buttons 2025-11-26 08:50:04 -08:00
Mitchell Hashimoto ad8a6e0642
search thread needs to take an allocated needle 2025-11-26 08:50:04 -08:00
Mitchell Hashimoto 5ee000f58f
macos: search input starts the search up 2025-11-26 08:50:04 -08:00
Mitchell Hashimoto 081d73d850
macos: changes to SearchState trigger calls to internals 2025-11-26 08:50:04 -08:00
Mitchell Hashimoto 56d4a7f58e
macos: start_search refocuses the search input 2025-11-26 08:50:04 -08:00
Mitchell Hashimoto c61d28a3a4
macos: esc returns focus back to surface 2025-11-26 08:50:04 -08:00
Mitchell Hashimoto b7e70ce534
apprt: end_search 2025-11-26 08:50:04 -08:00
Mitchell Hashimoto bc44b187d6
macos: hook up start_search apprt action to open search 2025-11-26 08:50:04 -08:00
Mitchell Hashimoto b87d57f029
macos: search overlay 2025-11-26 08:50:03 -08:00
Lukas 2f1427f529
macOS: match scroller’s appearance with surface’s background 2025-11-17 18:20:24 +01:00
Lukas 011fc77caa
macOS: Fix dictation icon's position while speaking 2025-11-16 12:17:31 +01:00
Daniel Wennberg 49bf73458b don't autohide scrollers 2025-11-14 07:40:51 -08:00
Daniel Wennberg d48f855a48 macOS: set scrollbar size to .small 2025-11-14 07:36:54 -08:00