4548 Commits

Author SHA1 Message Date
Mitchell Hashimoto
3b5a1fe8f1 Merge pull request #1264 from tristan957/fixes
fix: update code to compile with 0.12.0-dev.2075+f5978181e
2024-01-08 19:03:39 -08:00
Mitchell Hashimoto
522f61ff7d update zig 2024-01-08 18:37:19 -08:00
Tristan Partin
d2813655e5 fix: update code to compile with 0.12.0-dev.2075+f5978181e 2024-01-08 20:08:10 -06:00
Mitchell Hashimoto
cfdf6cf312 Merge pull request #1259 from rockorager/kitty-associated
input: never report associated text on key release
2024-01-08 08:13:30 -08:00
Mitchell Hashimoto
baf8e04287 input: add unit test for no associated text on release 2024-01-08 08:12:54 -08:00
Mitchell Hashimoto
39468757c6 Merge pull request #1260 from mitchellh/font-italic
font: auto-italic should only apply to text presentation
2024-01-08 08:04:33 -08:00
Mitchell Hashimoto
bc80073ffd core: add emoji fallback on macOS after built-in font
This doesn't fix any issues, but it slightly improves performance since
we'll try our text font first which is most likely to hit most input.
2024-01-08 08:01:17 -08:00
Mitchell Hashimoto
ab606c6cfd font: autoitalic should only apply to text presentation
Fixes #1256
2024-01-08 07:57:42 -08:00
Tim Culverhouse
e90a6ee19f input: never report associated text on key release
Associated text should only be reported when it was generated from the
key event. To my knowledge, there are no release events which produce
text. This now matches kitty reporting for release events.
2024-01-08 07:32:18 -06:00
Mitchell Hashimoto
4498bb77f3 Merge pull request #1254 from mitchellh/underflow
font/shaper: prevent underflow in multi-cell lig detection
2024-01-07 22:23:53 -08:00
Mitchell Hashimoto
2082751a65 font/shaper: prevent underflow in multi-cell lig detection
Fixes #1251

See the comment for details.
2024-01-07 22:16:11 -08:00
Mitchell Hashimoto
e63870c094 Merge pull request #1252 from KNnut/typo
readme: fix a typo
2024-01-07 22:00:32 -08:00
KNnut
a2e6c6b86b readme: fix a typo 2024-01-08 10:24:48 +08:00
Mitchell Hashimoto
ba45e4120e Merge pull request #1248 from der-teufel-programming/main
WIP: Update Ghostty to use the new build system API
2024-01-07 15:34:38 -08:00
Mitchell Hashimoto
ad0db1d2ae nix: update hash 2024-01-07 15:30:56 -08:00
Mitchell Hashimoto
fa0d7e963a Merge pull request #1249 from mitchellh/constrain-dingbats
renderer: constrain dingbats unicode block to cell size
2024-01-07 15:06:11 -08:00
Mitchell Hashimoto
62e5234da4 renderer: for constrained cells, offset was being doubled
This helps better preserve the centerline for constrained glyphs
2024-01-07 15:02:56 -08:00
Mitchell Hashimoto
f7c558e733 renderer: constrain dingbats category to cell size
Dingbats are generally symbolic glyphs that frequently overflow the
cell. Their defined codepoint width is "1" so they take one cell but
very often overflow to the next.

This extends the previously created logic for Nerd Font symbols such
that when a dingbat is next to whitespace, we allow it to use the full
size, but when a dingbat is next to an occupied cell we constrain it to
the cell size.
2024-01-07 14:54:15 -08:00
Krzysztof Wolicki
df19a68dd6 Update mach-glfw dependency 2024-01-07 23:38:17 +01:00
Chris Marchesi
477a79087b nix: update nixpkgs-zig-0-12 input, also cache hash
This updates zig_0_12 to be built off of 0.12.0-dev.2059+42389cb9c.

Additionally, we update the cache hash.
2024-01-07 13:56:07 -08:00
Krzysztof Wolicki
b4a08dd5f1 Update mach-glfw dependency 2024-01-07 22:45:59 +01:00
Krzysztof Wolicki
42eed75b64 Update mach-glfw dependency 2024-01-07 21:52:00 +01:00
Krzysztof Wolicki
3c78df70fb Maybe this will help macos 2024-01-07 21:39:53 +01:00
Mitchell Hashimoto
f6e93c8748 ci: release should only run with a main main ref 2024-01-07 12:34:36 -08:00
Mitchell Hashimoto
162ebaa8fa Merge pull request #1246 from rbino/linux-xft-dpi
linux: consider Xft.dpi to scale the content
2024-01-07 12:29:13 -08:00
Mitchell Hashimoto
b62c78b61d apprt/gtk: stylistic changes 2024-01-07 12:25:56 -08:00
Krzysztof Wolicki
46530b572e Merge branch 'main' of github.com:der-teufel-programming/ghostty 2024-01-07 21:22:19 +01:00
Krzysztof Wolicki
b27fc44837 Link frameworks to macos module conditionally 2024-01-07 21:22:09 +01:00
Mitchell Hashimoto
8db0697b5d nix: update hash 2024-01-07 12:18:11 -08:00
Krzysztof Wolicki
2f5bcf2e27 Attempt to fix building on macos 2024-01-07 21:17:17 +01:00
Mitchell Hashimoto
a8a42c8658 fix macos zig build test failures 2024-01-07 12:10:48 -08:00
Mitchell Hashimoto
c1bde28af4 update flake 2024-01-07 12:03:23 -08:00
Krzysztof Wolicki
5698607a1c Clean pkg/fontconfig/build.zig 2024-01-07 20:54:22 +01:00
Krzysztof Wolicki
9964a55d47 Update source for zig-build-macos-sdk for pkg/apple-sdk 2024-01-07 20:48:00 +01:00
Krzysztof Wolicki
12f4210558 Update required zig version to 0.12.0-dev.2063+804cee3b9 2024-01-07 20:42:30 +01:00
Krzysztof Wolicki
54e866d16e Change source of mach_glfw to experimental branch in fork 2024-01-07 19:25:06 +01:00
Krzysztof Wolicki
f917be968d Merge branch 'mitchellh:main' into main 2024-01-07 19:13:06 +01:00
Krzysztof Wolicki
ddebb31b8a Add include paths to more modules in pkg/ 2024-01-07 19:07:16 +01:00
Krzysztof Wolicki
6c7c5eecce Add include paths to freetype module 2024-01-07 18:45:07 +01:00
Krzysztof Wolicki
9e14a7ea62 Add include paths to modules in pkg/ 2024-01-07 17:39:39 +01:00
Krzysztof Wolicki
eb4ede8b6f Update sources for zig-objc and zig-js 2024-01-07 17:37:42 +01:00
Riccardo Binetti
ad503b8c4f linux: consider Xft.dpi to scale the content
Many applications use Xft.dpi to scale their contents (e.g. Chromium,
kitty, alacritty...). This value also gets set by DE setting managers
and can be manually set in ~/.Xresources if using, e.g., i3.

This should make HiDPI on Linux more consistent even when not using
GTK-specific methods (e.g. GDK_SCALE=2).

Note that we still consider GTK scaling, so it's possible to use the two
independently.

Closes #1243
2024-01-07 17:16:16 +01:00
Mitchell Hashimoto
e1a28dcabf Merge pull request #1245 from mitchellh/clear-screen-consume
core: clear_screen binding doesn't consume on alt screen
2024-01-07 08:04:59 -08:00
Mitchell Hashimoto
383b7c5870 core: clear_screen binding doesn't consume on alt screen
The clear_screen binding does nothing on the alternate screen already,
but we were still marking the action as "performed" which caused the
binding to be consumed.

This meant that alt screen applications like neovim, tmux, etc. couldn't
see "cmd+k" (default binding for clear_screen on macOS) without the
Ghostty user unbinding it completely.

We already have other bindings that do not consume only when they do not
perform, such as `previous_tab` and `next_tab`. This extends the
framework we built for that to this action.
2024-01-07 07:54:42 -08:00
Riccardo Binetti
fe0842c2d0 linux: add a function to check if we're running on X11 2024-01-07 16:54:01 +01:00
Krzysztof Wolicki
5bb25536e1 Update source for libxev 2024-01-07 15:00:31 +01:00
Krzysztof Wolicki
5776c54225 Update changed build.zig 2024-01-07 15:00:17 +01:00
Mitchell Hashimoto
76f760c7eb Merge pull request #1241 from mitchellh/monaspace-ligs
font: insert blank cells for multi-cell ligatures for styling
2024-01-06 19:40:47 -08:00
Mitchell Hashimoto
f447e6f9df font: insert blank cells for multi-cell ligatures for styling
Up to this point, every font I've experienced with ligatures has
replaced the codepoints that were replaced for combining with a space.
For example, if a font has a ligature for "!=" to turn it into a glyph,
it'd shape to `[not equal glyph, space]`, so it'd still take up two
cells, allowing us to style both.

Monaspace, however, does not do this. It turns "!=" into `[not equal
glyph]` so styles like backgrounds, underlines, etc. were not extending.

This commit detects multi-cell glyphs and inserts synthetic blank cells
so that styling returns. I decided to do this via synthetic blank cells
instead of introducing a `cell_width` to the shaper result because this
simplifies the renderers to assume each shaper cell is one cell. We can
change this later if we need to.

Annoyingly, this does make the shaper slightly slower for EVERYONE to
accomodate one known font that behaves this way. I haven't benchmarked
it but my belief is that the performance impact will be negligible
because to figure out cell width we're only accessing subsequent cells
so they're likely to be in the CPU cache and also 99% of cells are going
to be width 1.
2024-01-06 19:22:25 -08:00
Mitchell Hashimoto
1403db8835 Merge pull request #1239 from jcollie/nix-fix-build
In some cases, 'self' would not be passed to the package. It's not necessary so remove it.
2024-01-06 15:19:22 -08:00