X-Git-Url: https://pd.if.org/git/?p=pd_readline;a=blobdiff_plain;f=pd_readline.h;fp=pd_readline.h;h=021933e57ed568ce4572c99a5e856ca47f6d18a9;hp=0000000000000000000000000000000000000000;hb=f4117575c853c20d7312cbb8153d9a77340f8849;hpb=36403b46c9eec27a672b0cfbfad9a79c7d153dca diff --git a/pd_readline.h b/pd_readline.h new file mode 100644 index 0000000..021933e --- /dev/null +++ b/pd_readline.h @@ -0,0 +1,40 @@ + + +/* pd_readline.h */ +/* Header file for pd_readline. */ +/* This code is released to the public domain. */ +/* "Share and enjoy...." ;) */ +/* See the UNLICENSE file for details. */ + + +/* Buffer typedef. */ +typedef struct { + int index; + char array[80] ; +} buf; + + + +/* Cursor movement funcs. */ +int up(int i); +int down(int i); +buf left(buf b); +buf right(buf b); +buf delch(buf b); +buf insch(buf b); + +/* Escape-key handling. */ +int esc(int i); + +/* Other funcs. */ +void readhistory(char *fname); +int keyhandler(void); + + + + + + + + +