(index ("parley" 0) ("terminal-supported?" 189) ("history-to-file" 514) ("history-from-file" 691) ("add-key-binding!" 878) ("make-parley-port" 1144) ("history-max-lines" 1400) ("mark-more-input?" 1584) ("refresh-line" 1874) ("beep?" 2092) ("completion-choices" 2243) ("completion-list" 2689) ("print-completions" 2913) ("word-class" 3188))
(def (sig (procedure "(parley STRING)" (id parley))) (p "Prompts the user with prompt STRING and reads a whole line. This uses non-blocking I/O and returns a string or " (tt "#eof!") "."))
(def (sig (procedure "(terminal-supported? PORT STRING)" (id terminal-supported?))) (p "Checks if the terminal connected on PORT with name STRING is supported. If not " (tt "parley") " will resort back to a dumb (non-blocking) readline implementation. Unsupported terminals will not trigger any user defined key-bindings."))
(def (sig (procedure "(history-to-file STRING)" (id history-to-file))) (p "Dumps the current history to a file named in STRING. The file is overwritten if it already exists."))
(def (sig (procedure "(history-from-file STRING)" (id history-from-file))) (p "Reads a previously saved history into memory. Note that currently " (tt "parley") "'s history is global."))
(def (sig (procedure "(add-key-binding! CHAR PROC #!key (esc-sequence #f))" (id add-key-binding!))) (p "Register's PROC to be executed when CHAR is entered. If " (tt "esc-sequence") " is " (tt "#t") ", PROC will be called upon the sequence " (tt "#\\1b[CHAR") "."))
(def (sig (procedure "(make-parley-port PORT #!key (prompt #f) (prompt2 #f) (history-file #f))" (id make-parley-port))) (p "Creates a scheme port that reads from PORT and writes to " (tt "(current-output-port)") ". See below for a usage example in CSI."))
(def (sig (parameter "(history-max-lines NUMBER)" (id history-max-lines))) (p "Number of lines the history will hold. If this maximum is exceeded the oldest line will be discarded."))
(def (sig (parameter "(mark-more-input? STRING)" (id mark-more-input?))) (p "If not set to " (i "#f") " the string will be printed over the left and right edges, when there is more input hidden on either side of the screen. Defaults to \"…\" and is effective in single line mode only."))
(def (sig (parameter "(refresh-line REFRESH-PROCEDURE)" (id refresh-line))) (p "This parameter sets the editing mode for parley. It is either " (i "singleline-refresh") " the default or " (i "multiline-refresh") "."))
(def (sig (parameter "(beep? #t)" (id beep?))) (p "If #t (the default) a alarm character is sent when there are more than one possible completions."))
(def (sig (parameter "(completion-choices (lambda (input position last-word) '()))" (id completion-choices))) (p "A parameter holding the selection procedure. The procedure is called to actually return a list of possible completions depending on the whole " (b "input") " line, the current cursor " (b "position") " and the detected " (b "last-word") ". Should return either the empty list if no completions can be found or a list of strings."))
(def (sig (procedure "(completion-list list-of-strings)" (id completion-list))) (p "Convenience procedure to provide a simple string list to look for possible completions. Sets the " (b "completion-choices") " parameter."))
(def (sig (parameter "(print-completions (lambda (completions) ...))" (id print-completions))) (p "Handles how the completions are handled. By default it prints the number of completions a newline and each completion separated by a space character, ending with a newline."))
(def (sig (parameter "(word-class '($ (+ (~ whitespace))))" (id word-class))) (p "This defines how the last word in the input string is found. " (b "word-class") " takes any " (b "irregex") " expression."))
