6822 Commits

Author SHA1 Message Date
Mitchell Hashimoto
64c267a8c7 Merge pull request #2052 from rockorager/pretty-print
cli/list-keybinds: add pretty printing
2024-08-06 14:53:15 -07:00
Mitchell Hashimoto
d00ab8130a cli: note --plain 2024-08-06 14:53:00 -07:00
karei
85f19bcd12 cli/list-keybinds: align actions at the same column 2024-08-06 14:16:17 -05:00
Tim Culverhouse
8b834c1588 cli/list-keybinds: set default winsize for windows
When on windows, set some default terminal size. The actual size is not
very important to our use case here, but we do need one
2024-08-06 13:41:41 -05:00
Tim Culverhouse
e2a59ba77c cli/list-keybinds: set vaxis measurement state 2024-08-06 13:39:20 -05:00
Tim Culverhouse
b0ac75d5bc cli/list-keybinds: restore terminal after exit
Deinit the tty and vaxis to restore the terminal upon exiting the
command
2024-08-06 13:28:25 -05:00
Tim Culverhouse
1e91efbbe5 cli/list-keybinds: prevent ios, tvos, and watchos from pretty printing
These oses don't supply a tty layer, which prevents us from using the
libvaxis tty. Eventually we can add in using stdout as a writer. For
now, we just don't pretty print there.
2024-08-06 12:40:36 -05:00
Mitchell Hashimoto
389cc95394 renderer/metal: powerline enum value used wrong value 2024-08-06 10:22:08 -07:00
Tim Culverhouse
59e226154c cli/list-keybinds: add pretty printing
Add pretty printing to the +list-keybinds command. This is done by
bringing in a dependency on libvaxis to handle the styling. Pretty
printing happens automatically when printing to a tty, and can be
disabled either by redirecting output or using the flag `--plain`
2024-08-06 12:19:39 -05:00
Mitchell Hashimoto
0f8ed39766 Merge pull request #2049 from pluiedev/fix/exempt-powerline-from-minimum-contrast
renderer: exempt Powerline cells from minimum contrast requirements
2024-08-06 10:12:14 -07:00
Mitchell Hashimoto
247d5e4411 renderer/opengl: comptime assertion to verify 2024-08-06 10:07:08 -07:00
Mitchell Hashimoto
5be3098963 comment 2024-08-06 10:04:56 -07:00
Mitchell Hashimoto
3aee26207a Merge pull request #2050 from Pangoraw/fix_unfocused_opacity
gtk: One's complement the opacity of overlay for unfocused splits
2024-08-06 09:52:50 -07:00
Paul
c461d58519 gtk: One's complement the opacity of overlay for unfocused splits
The case where the split if fully opaque (`unfocused-split-opacity = 1.0`) should result in the overlay being fully transparent (`opacity: 0.0`).
This would be consistent with how this is implemented in the macos app:

dcc492f19b/macos/Sources/Ghostty/Ghostty.Config.swift (L302)
2024-08-06 09:58:23 +02:00
Leah Amelia Chen
503dfae6ff renderer: exempt Powerline cells from minimum contrast requirements
With a minimum contrast set, the colored glyphs that Powerline uses
would sometimes be set to white or black while the surrounding background
colors remain unchanged, breaking up contiguous colors on segments of
the Powerline.

This no longer happens with this patch as Powerline glyphs are now
special-cased and exempt from the minimum contrast adjustment.
2024-08-06 15:28:50 +08:00
Mitchell Hashimoto
dcc492f19b Merge pull request #2047 from i-am-linja/patch-1
Remove Erroneous Config Note
2024-08-05 18:52:26 -07:00
Eleanor Bartle
bb4b6b5782 Remove Erroneous Config Note 2024-08-06 11:48:30 +10:00
Mitchell Hashimoto
1e7672deba Merge pull request #2034 from jcollie/asymmetric-window-padding
Implement asymmetric window padding.
2024-08-05 15:56:15 -07:00
Mitchell Hashimoto
c2778ab3a6 config: window-padding-x/y take two values for uneven padding 2024-08-05 15:51:42 -07:00
Mitchell Hashimoto
5f2c6b7574 Merge pull request #2044 from nihaals/github-actions-committer
Use standard GitHub Actions committer info
2024-08-05 15:09:19 -07:00
Mitchell Hashimoto
c5d2f352d3 Merge pull request #2045 from nihaals/font-family-all
Document not every font-family needs to be set
2024-08-05 10:28:52 -07:00
Mitchell Hashimoto
978110ec24 config: update docs 2024-08-05 10:28:38 -07:00
Mitchell Hashimoto
7b84840951 Merge pull request #2043 from hauleth/chore/clean-up-typos
chore: clean up typos
2024-08-05 10:20:15 -07:00
Nihaal Sangha
538f6033ea Document not every font-family needs to be set 2024-08-05 17:26:33 +01:00
Nihaal Sangha
fae848da00 Use standard GitHub Actions committer info 2024-08-05 16:40:47 +01:00
Łukasz Niemier
f9be02a20f chore: clean up typos 2024-08-05 13:56:57 +02:00
Mitchell Hashimoto
1b386faee9 Merge pull request #2041 from jcollie/quit-delay-fix
Fix quit-after-last-window-closed=true, quit-after-last-window-closed-delay=null
2024-08-04 19:12:03 -07:00
Mitchell Hashimoto
656c720866 apprt/gtk: can manually expire our quit timer instead of 0 second timer 2024-08-04 19:06:17 -07:00
Jeffrey C. Ollie
4657f30f7f Fix quit-after-last-window-closed=true, quit-after-last-window-closed-delay=null
The case when `quit-after-last-window-closed=true` and
`quit-after-last-window-closed-delay=null` was broken because control
gets stuck inside `g_main_context_iteration` and never returns to our
code. In that case add a 0ms timer that will return control flow from
GLib back to our code so that we can quit.

Fixes #2039
2024-08-04 14:47:58 -05:00
Mitchell Hashimoto
5f0371c189 change window padding color to background by default
While we work out the bugs…
2024-08-03 22:27:19 -07:00
Mitchell Hashimoto
f09a45704a config: typo in window-padding-color docs 2024-08-03 22:04:35 -07:00
Mitchell Hashimoto
edc399813b Merge pull request #2037 from ghostty-org/extend
renderer: disable window-padding-color=extend in certain scenarios
2024-08-03 22:01:36 -07:00
Mitchell Hashimoto
ea551990eb renderer: disable window-padding-color=extend in certain scenarios
There are scenarios where this configuration looks bad. This commit
introduces some heuristics to prevent it. Here are the heuristics:

  * Extension is always enabled on alt screen.
  * Extension is disabled if a row contains any default bg color. The
    thinking is that in this scenario, using the default bg color looks
    just fine.
  * Extension is disabled if a row is marked as a prompt (using semantic
    prompt sequences). The thinking here is that prompts often contain
    perfect fit glyphs such as Powerline glyphs and those look bad when
    extended.

This introduces some CPU cost to the extension feature but it should be
minimal and respects dirty tracking. This is unfortunate but the feature
makes many terminal scenarios look much better and the performance cost
is minimal so I believe it is worth it.

Further heuristics are likely warranted but this should be a good
starting set.
2024-08-03 21:56:19 -07:00
Mitchell Hashimoto
2d418171df Merge pull request #2036 from ghostty-org/padding-extend
`window-padding-color = extend` to extend nearest cell bg color to padding
2024-08-03 18:39:02 -07:00
Mitchell Hashimoto
1cc5a69c43 Revert "renderer/metal: can access grid metrics directly on font grid"
This reverts commit 172179bbff7d3f0df73ba1c29c6906b69ead2619.
2024-08-03 18:37:42 -07:00
Mitchell Hashimoto
172179bbff renderer/metal: can access grid metrics directly on font grid
Its never recalculated so we don't need a lock.
2024-08-03 18:37:15 -07:00
Mitchell Hashimoto
56b3aa0b5e renderer/metal: font grid change should run all screen size logic 2024-08-03 18:33:53 -07:00
Mitchell Hashimoto
ed1c163c7b renderer/opengl: support window-padding-color=extend 2024-08-03 16:29:17 -07:00
Mitchell Hashimoto
55e8c421b5 config: add window-padding-color 2024-08-03 16:14:14 -07:00
Mitchell Hashimoto
9214db3c5f renderer/metal: handle top/left 2024-08-03 16:03:42 -07:00
Mitchell Hashimoto
5309f4d080 renderer/metal: extend background color of grid border into padding 2024-08-03 15:39:02 -07:00
Mitchell Hashimoto
c554b607b7 terminal: eraseDisplay should allow kitty erase through
Fixes #1994
2024-08-03 14:05:28 -07:00
Jeffrey C. Ollie
0f27fc2a0d Implement asymmetric window padding.
Add `window-padding-top`, `window-padding-bottom`,
`window-padding-left`, and `window-padding-right` options. The
`window-padding-x` and `window-padding-y` options will override the
individual options.
2024-08-03 14:42:28 -05:00
Mitchell Hashimoto
288a1fe549 Merge pull request #2021 from jcollie/background
gtk: allow running in the background
2024-08-03 10:08:45 -07:00
Mitchell Hashimoto
224f2d0491 apprt/gtk: use tagged union for quit timer 2024-08-03 10:05:31 -07:00
Mitchell Hashimoto
c5e2889369 config: clarify comment 2024-08-03 09:50:39 -07:00
Mitchell Hashimoto
e62bdbf8b7 config: duration prevents overflow, added tests 2024-08-03 09:48:40 -07:00
Jeffrey C. Ollie
b87667c950 document behavior when no initial window is created and a quit delay is set 2024-08-02 16:17:10 -05:00
Jeffrey C. Ollie
0e533af21a add a warning if quit delay too short 2024-08-02 15:43:40 -05:00
Jeffrey C. Ollie
d243ad6616 add a standard zig formatter to Duration and more testing 2024-08-02 15:43:37 -05:00