diff options
| author | Jens Schweikhardt <schweikh@schweikhardt.net> | 2025-08-31 11:19:44 +0200 |
|---|---|---|
| committer | Jens Schweikhardt <schweikh@schweikhardt.net> | 2025-08-31 11:19:44 +0200 |
| commit | 1ba7b3a044045ea2aa91dd46acc3a1b4531a8bc1 (patch) | |
| tree | f09f7fbc3f8d1c600ca03e7350aeea445c51b3e4 /lscp.c | |
| parent | 1abec752a5f4d50ff1e77c870a63a2a194ab8374 (diff) | |
Replace renumber.pl with hextosrc.c. Improved TTF.
* Introduce VERSION and HASH for utility programs.
* Fontlint complained about the + in BDF U+1234 character names, so
I changed them to U1234.
Diffstat (limited to 'lscp.c')
| -rw-r--r-- | lscp.c | 10 |
1 files changed, 10 insertions, 0 deletions
@@ -27,6 +27,13 @@ #include <wchar.h> #include <errno.h> +#ifndef HASH +#define HASH "(undefined)" +#endif +#ifndef VERSION +#define VERSION "(undefined)" +#endif + /* FreeBSD: devel/libunistring */ #include <uniname.h> @@ -36,9 +43,11 @@ int main(int aArgc, char **aArgv) { exit(EXIT_FAILURE); } if (aArgc != 3) { + fprintf(stderr, "%s version %s, hash %s\n", aArgv[0], VERSION, HASH); fprintf(stderr, "usage: %s start end\n", aArgv[0]); exit(EXIT_FAILURE); } + errno = 0; unsigned long start = strtoul(aArgv[1], NULL, 0); unsigned long end = strtoul(aArgv[2], NULL, 0); @@ -46,6 +55,7 @@ int main(int aArgc, char **aArgv) { fprintf(stderr, "could not convert arguments to integers\n"); exit(EXIT_FAILURE); } + for (unsigned long i = start; i < end; ++i) { char name[UNINAME_MAX + 1]; const char *const p = unicode_character_name((ucs4_t)i, name); |
