ref: d7a085bcf19f164fbd667db398ad698a9fca3ec4
parent: ac8c056bcad38af1a18ab22d2c8a30dcbd2410f9
author: Eli Cohen <echoline@gmail.com>
date: Tue Feb 1 20:01:52 EST 2022
resize better, install mk target
--- a/mkfile
+++ b/mkfile
@@ -2,8 +2,12 @@
TARG=`{ls *.c | sed 's,\.c$,,'}
PROGS=${TARG:%=%}
+BINDIR=$home/bin/$objtype/
all:V: $PROGS
+
+install: $PROGS
+ cp $PROGS $BINDIR
%: %.$O
$O^l -o $target $stem.$O
--- a/monome.c
+++ b/monome.c
@@ -126,6 +126,8 @@
Point xy;
int key;
+ resize();
+
if(initdraw(0, 0, "monome") < 0)
sysfatal("initdraw: %r");
@@ -137,7 +139,7 @@
for(j = 0; j < 16; j++)
buttons[i][j] = insetrect(Rect(i*40, j*40, (i+1)*40, (j+1)*40), 3);
}
- eresized(0);
+
einit(Emouse|Ekeyboard);
pipe(redrawfds);
estart(0, redrawfds[0], 1);