32 lines
1.2 KiB
C
32 lines
1.2 KiB
C
#ifndef COSMOPOLITAN_THIRD_PARTY_LINENOISE_LINENOISE_H_
|
|
#define COSMOPOLITAN_THIRD_PARTY_LINENOISE_LINENOISE_H_
|
|
#if !(__ASSEMBLER__ + __LINKER__ + 0)
|
|
COSMOPOLITAN_C_START_
|
|
|
|
typedef struct linenoiseCompletions {
|
|
size_t len;
|
|
char **cvec;
|
|
} linenoiseCompletions;
|
|
|
|
typedef void(linenoiseCompletionCallback)(const char *, linenoiseCompletions *);
|
|
typedef char *(linenoiseHintsCallback)(const char *, int *color, int *bold);
|
|
typedef void(linenoiseFreeHintsCallback)(void *);
|
|
void linenoiseSetCompletionCallback(linenoiseCompletionCallback *);
|
|
void linenoiseSetHintsCallback(linenoiseHintsCallback *);
|
|
void linenoiseSetFreeHintsCallback(linenoiseFreeHintsCallback *);
|
|
void linenoiseAddCompletion(linenoiseCompletions *, const char *);
|
|
|
|
char *linenoise(const char *prompt);
|
|
void linenoiseFree(void *ptr);
|
|
int linenoiseHistoryAdd(const char *line);
|
|
int linenoiseHistorySetMaxLen(int len);
|
|
int linenoiseHistorySave(const char *filename);
|
|
int linenoiseHistoryLoad(const char *filename);
|
|
void linenoiseClearScreen(void);
|
|
void linenoiseSetMultiLine(int ml);
|
|
void linenoisePrintKeyCodes(void);
|
|
|
|
COSMOPOLITAN_C_END_
|
|
#endif /* !(__ASSEMBLER__ + __LINKER__ + 0) */
|
|
#endif /* COSMOPOLITAN_THIRD_PARTY_LINENOISE_LINENOISE_H_ */
|