update build script, add font message implementation from upstream

This commit is contained in:
Iris Lightshard 2021-06-15 01:21:59 -06:00
parent 1ec33c665f
commit fe2024f43e
Signed by: Iris Lightshard
GPG key ID: 3B7FBC22144E6398
2 changed files with 18 additions and 0 deletions

View file

@ -3,6 +3,7 @@
clang-format -i ./*.c clang-format -i ./*.c
clang-format -i ./mail/*.c clang-format -i ./mail/*.c
mk clean
mk mk
mv o.acme acme mv o.acme acme

17
xfid.c
View file

@ -690,6 +690,23 @@ void xfidctlwrite(Xfid* x, Window* w) {
filemark(w->body.file); filemark(w->body.file);
winsetname(w, r, nr); winsetname(w, r, nr);
m += (q + 1) - pp; m += (q + 1) - pp;
} else if (strncmp(p, "font ", 5) == 0) { /* execute font command */
pp = p + 5;
m = 5;
q = memchr(pp, '\n', e - pp);
if (q == nil || q == pp) {
err = Ebadctl;
break;
}
*q = 0;
nulls = FALSE;
cvttorunes(pp, q - pp, r, &nb, &nr, &nulls);
if (nulls) {
err = "nulls in font string";
break;
}
fontx(&w->body, nil, nil, FALSE, XXX, r, nr);
m += (q + 1) - pp;
} else if (strncmp(p, "dump ", 5) == 0) { /* set dump string */ } else if (strncmp(p, "dump ", 5) == 0) { /* set dump string */
pp = p + 5; pp = p + 5;
m = 5; m = 5;