Commit Graph

14477 Commits

Author SHA1 Message Date
Mitchell Hashimoto
fded0e97cb terminal: clean up LAB methods, add tests, comments 2026-02-17 09:36:28 -08:00
Mitchell Hashimoto
50698c5c72 fmt 2026-02-17 09:18:03 -08:00
Jake Stewart
44d2ea25d0 explain mask 2026-02-17 09:17:54 -08:00
Jake Stewart
e268ff9a8b rename param 2026-02-17 09:17:54 -08:00
Jake Stewart
7729714935 refactor 256 color gen 2026-02-17 09:17:54 -08:00
Jake Stewart
5f89228a7a refactor lab colors 2026-02-17 09:17:54 -08:00
Jake Stewart
fad72e0ed1 generate 256 palette 2026-02-17 09:17:54 -08:00
ghostty-vouch[bot]
fa216edacc Update VOUCHED list (#10798)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10782) from
@mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-17 17:16:21 +00:00
ghostty-vouch[bot]
e67a8b2da4 Update VOUCHED list (#10797)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10784) from
@mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-17 17:14:50 +00:00
ghostty-vouch[bot]
34637b843e Update VOUCHED list (#10796)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10785) from
@mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-17 17:14:22 +00:00
ghostty-vouch[bot]
3e92aa2c3a Update VOUCHED list (#10795)
Triggered by
[comment](https://github.com/ghostty-org/ghostty/issues/10794#issuecomment-3915601262)
from @trag1c.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-17 16:09:06 +00:00
ghostty-vouch[bot]
5c8d977304 Update VOUCHED list (#10793)
Triggered by
[comment](https://github.com/ghostty-org/ghostty/issues/10792#issuecomment-3915522813)
from @trag1c.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-17 15:54:21 +00:00
Kat
f07b92a022 Update zh_TW Traditional Chinese locale, cc #10632 (#10788)
GitHub Copilot pull request summary:

> This pull request updates the Traditional Chinese (zh_TW) translations
for the "Change Tab Title" strings in the application. These updates
provide accurate translations for UI elements related to changing tab
titles.
> 
> **Translation updates:**
> 
> * Added the Traditional Chinese translation for the "Change Tab
Title…" menu item in `po/zh_TW.UTF-8.po`
> * Added the Traditional Chinese translation for the "Change Tab Title"
dialog label in `po/zh_TW.UTF-8.po`
2026-02-17 15:33:30 +00:00
ghostty-vouch[bot]
0aa88e0dac Update VOUCHED list (#10790)
Triggered by
[comment](https://github.com/ghostty-org/ghostty/issues/10788#issuecomment-3915336424)
from @00-kat.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-17 15:20:52 +00:00
Peter Dave Hello
ebdf38999b Update zh_TW Traditional Chinese locale, cc #10632 2026-02-17 23:13:31 +08:00
Mitchell Hashimoto
b6dbd445d0 ci: update create-github-app-token 2026-02-16 21:02:44 -08:00
ghostty-vouch[bot]
a3dd93ae75 Update VOUCHED list (#10781)
Triggered by
[comment](https://github.com/ghostty-org/ghostty/issues/10379#issuecomment-3912263144)
from @mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-17 04:49:58 +00:00
ghostty-vouch[bot]
f1277737ff Update VOUCHED list (#10780)
Triggered by
[comment](https://github.com/ghostty-org/ghostty/issues/10379#issuecomment-3912261301)
from @mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-17 04:49:08 +00:00
Mitchell Hashimoto
39a10ecc0c ci: vouch uses the Ghostty Vouch GitHub app to bypass merge restrictions (#10779) 2026-02-16 20:48:25 -08:00
Mitchell Hashimoto
b5bb87161b renderer: drop opaque background for preedit cells (#10774)
Discussed in https://github.com/ghostty-org/ghostty/discussions/10739

## Summary

Remove the hardcoded opaque background (alpha=255) from IME preedit
cells so they respect `background-opacity` like all other cells.

When `background-opacity` is less than 1, preedit (composition) text was
rendered with a fully opaque background, causing the text to appear
highlighted and hard to read. This change removes the explicit per-cell
background from `addPreeditCell`, letting preedit cells fall through to
the global background. The underline indicator is preserved to mark the
preedit region.

---

`background-opacity` が 1
未満のとき、IME入力中(preedit)のセルが完全不透明な背景で描画され、ハイライトされたように見えて読みづらくなる問題を修正しました。

`addPreeditCell` のセル背景描画を削除し、グローバル背景に委ねることで通常セルと同じ透過表示になります。
preedit領域のアンダーラインは維持されます。

## Test plan

- Set `background-opacity` to a value less than 1 (e.g. 0.5)
- Type Japanese (or other IME input) to trigger preedit
- Verify preedit text no longer appears highlighted
- Verify the underline indicator is still drawn under preedit text

AI disclosure: I used Claude Code to investigate the source code and
generate code changes in this PR.
2026-02-16 19:55:34 -08:00
Shunya Yamashita
b1dce5f942 renderer: drop opaque background for preedit cells 2026-02-17 10:29:09 +09:00
Mitchell Hashimoto
cdcfac4e4a renderer: only compute and draw preedit cells if they change (#10772)
Fixes #10424
Replaces #10431

The issue is that when the row where preedit was wasn't dirty, we were
layering more preedit cells (identical ones) on top, so it'd appear to
get "thicker".
2026-02-16 14:28:06 -08:00
Jeffrey C. Ollie
6b6be837de gtk: Change tab title (#9904)
Closes #9880. 



https://github.com/user-attachments/assets/7110fae1-a7ca-42b6-8956-833b8bdd5d98

> [!NOTE]
>
> Used AI to get to explain to me some of the APIs and functionality
between `windows` and `tabs` and their connections. But the code itself,
I implemented everything, just used it for help with explaining some
things


## If you feel like reading more:
- I feel there is a lot of duplication now with the `prompt surface
title` functionality. For the dialog creation, i basically copied-pasted
the `surface_title_dialog`, and some of the `titleOverride` and the
`TabDialogSet` functionality is identical to that of the
`prompt_surface_title`

- I would think about abstracting it out, but first I think Id be nice
to think what the maintainers think about this approach before doing
anything else.
2026-02-16 16:24:47 -06:00
Mitchell Hashimoto
3c074b5aec renderer: only compute and draw preedit cells if they change
Fixes #10424
Replaces #10431

The issue is that when the row where preedit was wasn't dirty, we were
layering more preedit cells (identical ones) on top, so it'd appear to
get "thicker".
2026-02-16 14:23:44 -08:00
github-actions[bot]
bdcee2b05a Update VOUCHED list (#10770)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10769) from
@jcollie.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-16 22:13:22 +00:00
David Matos
7e31078882 Update translations 2026-02-16 23:11:19 +01:00
Mitchell Hashimoto
7895bf1d02 shell-integration: respect cursor-style-blink (#10643)
The `cursor` shell feature always used a blinking bar (beam), often to
the surprise of users who set `cursor-style-blink = false`.

This change extends our GHOSTTY_SHELL_FEATURES format to include either
`cursor:blink` (default) or `cursor:steady` based on cursor-style-blink
when the `cursor` feature is enabled, and all shell integrations have
been updated to use that additional information to choose the DECSCUSR
cursor value (5=blinking bar, 6=steady bar).

I also considered passing a DECSCUSR value in GHOSTTY_SHELL_FEATURES
(e.g. `cursor:5`). This mostly worked well, but zsh also needs the blink
state on its own for its block cursor. We also don't support any other
shell feature cursor configurability (e.g. the shape), so this was an
over generalization.

This does change the behavior for users who like the blinking bar in the
shell but have `cursor-blink-style = false` for other reasons. We could
provide additional `cursor` shell feature configurability (e.g.
`cursor:blink` in `shell-integration-features`), but I'll propose that
as its own change.

See: #2812
Closes: #8681

---

**AI Disclosure:** I did a lot of rubber ducking with Claude Code while
trying out various ideas. It was particularly useful for this kind of
feature because I could try out one thing and have it evaluate the
impact on all of the shell integration scripts at once.
2026-02-16 14:08:23 -08:00
Mitchell Hashimoto
f79906c7b8 osc: parse OSC 5522 - Kitty clipboard protocol (#10560)
This PR only adds support for parsing the OSCs. No support has been
added to DECRQM/DECRPM/DECSET/DECRST for mode 5522.

Related to #10549
2026-02-16 14:06:43 -08:00
David Matos
c067f2b911 Merge branch 'main' into gtk-prompt-tab-title 2026-02-16 23:06:04 +01:00
Mitchell Hashimoto
65c9208c08 zsh: update PS1 substitution to include 'cl=line' (#10768)
Our PS1 cleanup code (where we remove any markers we added) was still
looking for the previous 133;A form. Update it to include 'cl=line',
which was added in 8595558.
2026-02-16 13:59:59 -08:00
Jon Parise
e5e063c89d zsh: update PS1 substitution to include 'cl=line'
Our PS1 cleanup code (where we remove any markers we added) was still
looking for the previous 133;A form. Update it to include 'cl=line',
which was added in 8595558.
2026-02-16 16:49:03 -05:00
Mitchell Hashimoto
b358705b65 macos: rename shellQuoted() to Ghostty.Shell.quote() (#10765)
We already had an established Ghostty.Shell namespace (previously a
struct; now a more idiomatic enum), and locating these functions next to
each other makes it clearer how they relate to one another.
2026-02-16 12:40:13 -08:00
Mitchell Hashimoto
d1774e1423 macos: sort INFOPLIST_KEY_ names (#10764)
Xcode wants these to be sorted and will update this list when the
project file is saved so proactively make this change before it gets
mixed up in other work.
2026-02-16 12:31:33 -08:00
Jon Parise
df6feba417 macos: rename shellQuoted() to Ghostty.Shell.quote()
We already had an established Ghostty.Shell namespace (previously a
struct; now a more idiomatic enum), and locating these functions next to
each other makes it clearer how they relate to one another.
2026-02-16 15:27:57 -05:00
Jon Parise
d49ac65b16 macos: sort INFOPLIST_KEY_ names
Xcode wants these to be sorted and will update this list when the
project file is saved so proactively make this change before it gets
mixed up in other work.
2026-02-16 15:25:53 -05:00
Mitchell Hashimoto
dc3a25c2a3 ci: update vouch to 1.3.1
For GH API retries
2026-02-16 12:13:47 -08:00
github-actions[bot]
534f1190af Update VOUCHED list (#10763)
Triggered by
[comment](https://github.com/ghostty-org/ghostty/issues/10694#issuecomment-3910186875)
from @jcollie.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-16 19:16:57 +00:00
Mitchell Hashimoto
99e342717b fix: copy_title_to_clipboard respects user-overridden title (#10694)
## Summary
- Fixes #10345 — `copy_title_to_clipboard` now copies the user-set
custom title instead of the raw terminal title
- Adds a new `copy_title` apprt action as [suggested by
@mitchellh](https://github.com/ghostty-org/ghostty/issues/10345#issuecomment-2601002974)
- Each platform (GTK + macOS) resolves the effective title (user
override → terminal title fallback) before copying to clipboard

## Changes
- **`src/apprt/action.zig`** — New `copy_title` void action
- **`include/ghostty.h`** — C ABI enum entry
- **`src/Surface.zig`** — Binding handler now dispatches apprt action
instead of inline logic
- **`src/apprt/gtk/class/surface.zig`** — `getEffectiveTitle()` helper
(returns `title_override orelse title`)
- **`src/apprt/gtk/class/application.zig`** — GTK action handler
- **`macos/.../Ghostty.App.swift`** — macOS handler using
`surfaceView.title` + `NSPasteboard`

*Note*: This PR was *AI* assisted.
2026-02-16 11:10:17 -08:00
github-actions[bot]
39c4a406f7 Update VOUCHED list (#10761)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10599) from
@mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-16 18:59:50 +00:00
github-actions[bot]
c8edac93eb Update VOUCHED list (#10759)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10600) from
@mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-16 18:58:20 +00:00
github-actions[bot]
bc4314b882 Update VOUCHED list (#10757)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10606) from
@mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-16 18:56:37 +00:00
Mitchell Hashimoto
d993c700af bash: remove redundant out-of-band OSC 133;A (#10747)
The printf was part of the original script (9d6121245), and at the time,
this was the only place we'd emit the 133;A mark.

A PS1-based 133;P;k=i mark was introduced in 2bf1f80f7, and then it
become a full 133;A mark in aa47047a6, making the original printf line
redundant (because bash will also redraw PS1 on SIGWINCH).

The PS1-based 133;A was only missing the aid= option, and with that
added, it handles all of our cases (prompts, initial draw, and resizes).
2026-02-16 10:50:50 -08:00
Mitchell Hashimoto
0e68c6edb3 Update VOUCHED list (#10752)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10620) from
@mitchellh.
2026-02-16 10:49:21 -08:00
Mitchell Hashimoto
802516dc00 Update VOUCHED list (#10754)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10616) from
@mitchellh.
2026-02-16 10:49:10 -08:00
github-actions[bot]
76ec24fc66 Update VOUCHED list (#10755)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10616) from
@mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-16 18:48:37 +00:00
github-actions[bot]
515d28f05d Update VOUCHED list
https://github.com/ghostty-org/ghostty/discussions/10616#discussioncomment-DC_kwDOHFhdAs4A8YDu
2026-02-16 18:47:40 +00:00
Jon Parise
897b918f67 bash: remove redundant out-of-band OSC 133;A
The printf was part of the original script (9d6121245), and at the time,
this was the only place we'd emit the 133;A mark.

A PS1-based 133;P;k=i mark was introduced in 2bf1f80f7, and then it
become a full 133;A mark in aa47047a6, making the original printf line
redundant (because bash will also redraw PS1 on SIGWINCH).

The PS1-based 133;A was only missing the aid= option, and with that
added, it handles all of our cases (prompts, initial draw, and resizes).
2026-02-16 13:46:55 -05:00
github-actions[bot]
60298e9ca5 Update VOUCHED list (#10753)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10620) from
@mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-16 18:46:10 +00:00
github-actions[bot]
f46e335b15 Update VOUCHED list
https://github.com/ghostty-org/ghostty/discussions/10620#discussioncomment-DC_kwDOHFhdAs4A8YDa
2026-02-16 18:45:03 +00:00
github-actions[bot]
565abf5621 Update VOUCHED list (#10748)
Triggered by [discussion
comment](https://github.com/ghostty-org/ghostty/discussions/10663) from
@mitchellh.

Co-authored-by: github-actions[bot] <41898282+github-actions[bot]@users.noreply.github.com>
2026-02-16 18:39:30 +00:00