able to find fonts with a single command
Go to file
Emil Lerch 31fe824a8b
Generic zig build / build (push) Successful in 1m6s Details
address most memory leaks
2024-05-05 09:16:19 -07:00
.github/workflows update workflow to address gitea notifications 2024-04-30 22:52:46 -07:00
docker-alpine upgrade to zig 0.11 2023-08-04 09:21:03 -07:00
src address most memory leaks 2024-05-05 09:16:19 -07:00
.gitignore add gitignore 2023-07-29 20:11:21 -07:00
Dockerfile upgrade to zig 0.12.0 2024-04-30 19:56:24 -07:00
LICENSE initial source code 2023-07-29 20:10:04 -07:00
README.md upgrade to zig 0.12.0 2024-04-30 19:56:24 -07:00
build.zig upgrade to zig 0.12.0 2024-04-30 19:56:24 -07:00
build.zig.zon upgrade to zig 0.12.0 2024-04-30 19:56:24 -07:00
zig-via-docker initial source code 2023-07-29 20:10:04 -07:00

README.md

fontfinder

Zig program to find fonts to solve my mlterm font configuration problem. See https://github.com/elerch/vcsh_mlterm/blob/master/.mlterm/aafont for more information on this.

See fontfinder -h for usage. For mlterm, you may want to use a different pattern, specifically the default, but without spacing:

-p :regular:normal:slant=0

This was built with Zig 0.11.0-dev.3886+0c1bfe271. The intent is to rebuild with Zig 0.11 when released, but the version above is close enough that it should work at that time.

Building

This is not fully zig build friendly, since it links to system libraries. Specifically, you need to have fontconfig and dependencies installed. The include files are pulled from fontconfig 2.14.1, which is the version in debian bullseye, but he system library still needs to linked.

To help with the build, a Dockerfile exists in this repository that can be used to create a docker image with the appropriate zig version and system libraries. the shell script zig-via-docker will then act as a drop in replacement for installed zig, passing all commands through to the container. That script is set up for podman (same as docker, but allows running without root) and a docker image named fontfinder.

This is a personal project, so happy for others to use it, but if you want things to improve, you will need to file a PR. ;-)