1 #pragma src "/sys/src/libscribble" 2 #pragma lib "libscribble.a" 3 4 typedef struct Scribble Scribble; 5 typedef struct graffiti Graffiti; 6 7 typedef struct pen_point { 8 Point; 9 long chaincode; 10 } pen_point; 11 12 typedef struct Stroke { 13 uint npts; /*Number of pen_point in array.*/ 14 pen_point* pts; /*Array of points.*/ 15 } Stroke; 16 17 #define CS_LETTERS 0 18 #define CS_DIGITS 1 19 #define CS_PUNCTUATION 2 20 21 struct Scribble { 22 /* private state */ 23 Point *pt; 24 int ppasize; 25 Stroke ps; 26 Graffiti *graf; 27 int capsLock; 28 int puncShift; 29 int tmpShift; 30 int ctrlShift; 31 int curCharSet; 32 }; 33 34 Rune recognize(Scribble *); 35 Scribble * scribblealloc(void); 36 37 extern int ScribbleDebug; 38