Open kovidgoyal opened 5 days ago
I have an issue building on Arch Linux:
> ./dev.sh build
[32/32] Compiling kitty/window_logo.c ... done
Compiling kitty/keys.c ...
gcc -MMD -DNDEBUG -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include -Wextra -Wfloat-conversion -Wno-missing-field-initializers -Wall -Wstrict-prototypes -std=c11 -pedantic-errors -Werror -O3 -fwrapv -fstack-protector-strong -pipe -fvisibility=hidden -fno-plt -fPIC -D_FORTIFY_SOURCE=2 -flto -fcf-protection=full -march=native -mtune=native -pthread -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include/libpng16 -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include/freetype2 -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include/libpng16 -I/usr/include/uuid -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include/harfbuzz -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include/freetype2 -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include/libpng16 -I/home/cjv/pkgs/kitty/dependencies/linux-amd64/include/python3.11 -c kitty/keys.c -o build/fast_data_types-kitty-keys.c.o
kitty/keys.c: In function ‘is_no_action_key’:
kitty/keys.c:55:14: error: ‘XKB_KEY_XF86Fn’ undeclared (first use in this function); did you mean ‘XKB_KEY_XF86Go’?
55 | case XKB_KEY_XF86Fn:
| ^~~~~~~~~~~~~~
| XKB_KEY_XF86Go
kitty/keys.c:55:14: note: each undeclared identifier is reported only once for each function it appears in
The following build command failed: /home/cjv/pkgs/kitty/dependencies/linux-amd64/bin/python setup.py develop
exit status 1
I have an issue building on Arch Linux
Nevermind. My bad. ./dev.sh deps
fixed it.
After pressing enter on the initial font selection screen I get this:
$ kitten choose-fonts
Traceback (most recent call last):
File "<frozen runpy>", line 198, in _run_module_as_main
File "<frozen runpy>", line 88, in _run_code
File "/home/cjv/pkgs/kitty/__main__.py", line 7, in <module>
main()
File "/home/cjv/pkgs/kitty/kitty/entry_points.py", line 192, in main
namespaced(['+', first_arg[1:]] + sys.argv[2:])
File "/home/cjv/pkgs/kitty/kitty/entry_points.py", line 146, in namespaced
func(args[1:])
File "/home/cjv/pkgs/kitty/kitty/entry_points.py", line 24, in runpy
exec(args[1])
File "<string>", line 1, in <module>
File "/home/cjv/pkgs/kitty/kittens/choose_fonts/backend.py", line 217, in main
opts, family_key, dpi_x, dpi_y = opts_from_cmd(cmd)
^^^^^^^^^^^^^^^^^^
File "/home/cjv/pkgs/kitty/kittens/choose_fonts/backend.py", line 75, in opts_from_cmd
opts.foreground = to_color(ts['foreground'])
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/cjv/pkgs/kitty/kitty/conf/utils.py", line 60, in to_color
ans = as_color(x, validate=True)
^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/cjv/pkgs/kitty/kitty/rgb.py", line 73, in to_color
raise ValueError(f'Invalid color name: {raw}')
ValueError: Invalid color name:
Error: exit status 1
Are you running kitten choose-fonts inside an instance of kitty built from source as well?
You are right. I was somehow getting my kitty versions mixed up. I deinstalled the arch version of kitty and restarted all my kitty sessions and now it works.
I get segfault when trying to select any Monaspace's font from the list. kittly nightly build
$ kitten choose-fonts
Error: signal: segmentation fault
Works for me with both Monaspace Argon Var and Monaspace Neon. Post the actual backtrace. What OS are you running on? And exactly what steps dd you take leading to the segfault.
What OS are you running on?
MacOS 12.7.1.
Post the actual backtrace
The only output I get is Error: signal: segmentation fault
. Is there a log file with more details?
And exactly what steps dd you take leading to the segfault
I just installed the nightly build. Previously I was on latest stable.
kitten choose-fonts
There is something going on with ligatures in the font preview, parts of them are invisible. You can see in the first screenshot below that part of the <=>
and |}
ligatures are missing.
Preview of JetBrains Mono, looks wrong:
Preview of JetBrains Mono NL (same font without ligatures), looks correct:
The same characters printed normally in the terminal with JetBrains Mono (with ligatures), looks correct:
The font is installed from the ttf-jetbrains-mono package in Arch Linux, version 2.304-1. Running kitty commit 190048080.
On Mon, Jun 24, 2024 at 09:09:07AM -0700, Jorge Villalobos wrote:
What OS are you running on?
MacOS 12.7.1.
Post the actual backtrace
The only output I get is
Error: signal: segmentation fault
. Is there a log file with more details?
There should be a crash report available via Console.app
And exactly what steps dd you take leading to the segfault
I just installed the nightly build. Previously I was on latest stable.
- run
kitten choose-fonts
- Kitten loads. I can see a list of font families.
- I change current selection with arrows keys ↑ ↓
- If I move into any of Monaspace's (just selecting it in the left list, not choosing it pressing enter), the process exits and I get the output mentioned above.
Doesnt repro for me on macOS, however, I can only get the Monaspace Var fonts to show up not the non variable ones. Are you using up to date monaspace fonts and where exactly did you get them from?
On Mon, Jun 24, 2024 at 09:24:38AM -0700, Trygve Aaberge wrote:
There is something going on with ligatures in the font preview, parts of them are invisible. You can see in the first screenshot below that part of the
<=>
and|}
ligatures are missing.
https://github.com/kovidgoyal/kitty/commit/a8daf067377c8a5214d7bb246288280cbeb8161c
There should be a crash report available via Console.app
Doesnt repro for me on macOS, however, I can only get the Monaspace Var fonts to show up not the non variable ones.
Likewise, only var fonts show up.
Are you using up to date monaspace fonts and where exactly did you get them from?
Yes V1.101. Followed install instructions as specified at monaspace's README.md
$ git clone https://github.com/githubnext/monaspace.git
$ cd monaspace
$ ./util/install_macos.sh
Hmm, that backtrace has no kitty code in it. Could indicate memory corruption. Can you build kitty with sanitizers as described here: https://sw.kovidgoyal.net/kitty/build/#building-in-debug-mode
might give a more useful backtrace.
Also does the crash happen if you run
kitty --config=NONE kitten choose-fonts
and try to select the monaspace fonts.
Hi all,
I have added support to kitty for OpenType variable fonts. This means that, for fonts that support it, you can precisely control the weight, spacing, italic angle, etc. There is also a new UI in the form of the choose-fonts kitten to make selecting fonts and setting their features and variable values easier. Run it with:
See the docs for the this kitten
Some screenshots of the kitten:
The code works on both Linux and macOS. Note that this required extensive re-writing of font selection internals so there could be regressions.
I would appreciate some testing from those of you in a position to do so, as there are two platforms and dozens of fonts and settings and thousands of lines of code involved, it's hard for me to cover everything.
You can use the kitty nightly build or build kitty from source.
Note that the existing font_features setting in kitty.conf still works, but is obsoleted by the new choose fonts kitten. It should only be used for fallback fonts. The main fonts should have their features configured via choose-fonts.
Thanks, and enjoy.