The clinenoise Reference Manual

This is the clinenoise Reference Manual, generated automatically by Declt version 4.0 beta 2 "William Riker" on Wed May 15 04:47:23 2024 GMT+0.

Table of Contents


1 Introduction


2 Systems

The main system appears first, followed by any subsystem dependency.


2.1 clinenoise

A trivial line-input library for VT-like terminals

Author

<>

License

BSD-2

Defsystem Dependency

cffi-grovel (system).

Dependencies
  • cffi (system).
  • alexandria (system).
  • split-sequence (system).
  • cffi-grovel (system).
Source

clinenoise.asd.

Child Components

3 Files

Files are sorted by type and then listed depth-first from the systems components trees.


3.1 Lisp


3.1.1 clinenoise/clinenoise.asd

Source

clinenoise.asd.

Parent Component

clinenoise (system).

ASDF Systems

clinenoise.


3.1.2 clinenoise/package.lisp

Source

clinenoise.asd.

Parent Component

clinenoise (system).

Packages

clinenoise.


3.1.3 clinenoise/termios-grovel.lisp

Dependency

package.lisp (file).

Source

clinenoise.asd.

Parent Component

clinenoise (system).


3.1.4 clinenoise/cwrappers.lisp

Dependency

termios-grovel.lisp (file).

Source

clinenoise.asd.

Parent Component

clinenoise (system).

Internals

3.1.5 clinenoise/clinenoise.lisp

Dependency

cwrappers.lisp (file).

Source

clinenoise.asd.

Parent Component

clinenoise (system).

Public Interface
Internals

4 Packages

Packages are listed by definition order.


4.1 clinenoise

Source

package.lisp.

Use List
  • alexandria.
  • cffi.
  • common-lisp.
  • split-sequence.
Public Interface
Internals

5 Definitions

Definitions are sorted by export status, category, package, and then by lexicographic order.


5.1 Public Interface


5.1.1 Ordinary functions

Function: history-add (line)

Add LINE to the prompt history

Package

clinenoise.

Source

clinenoise.lisp.

Function: history-load (fn)

Load history from pathname FN

Package

clinenoise.

Source

clinenoise.lisp.

Function: history-save (fn)

Save history to pathname FN

Package

clinenoise.

Source

clinenoise.lisp.

Function: linenoise (prompt &optional plen)

Display PROMPT and wait for a line to be entered with basic editing support PLEN can be specified for prompts that have a display width different from their character count (e.g. combining characters, escape codes)

Package

clinenoise.

Source

clinenoise.lisp.


5.2 Internals


5.2.1 Constants

Constant: +linenoise-default-history-max-len+
Package

clinenoise.

Source

clinenoise.lisp.

Constant: +linenoise-max-line+
Package

clinenoise.

Source

clinenoise.lisp.


5.2.2 Special variables

Special Variable: *completion-callback*

Function to call for completions.
Takes the current line as a parameter, and returns a list of possible completions Does not currently indicate the position of the cursor when the completion was requested

Package

clinenoise.

Source

clinenoise.lisp.

Special Variable: *history*
Package

clinenoise.

Source

clinenoise.lisp.

Special Variable: *history-len*
Package

clinenoise.

Source

clinenoise.lisp.

Special Variable: *mlmode*
Package

clinenoise.

Source

clinenoise.lisp.

Special Variable: *unread-char*
Package

clinenoise.

Source

clinenoise.lisp.

Special Variable: +unsupported-term+
Package

clinenoise.

Source

clinenoise.lisp.


5.2.3 Macros

Macro: ioctl (d request &rest varargs0)
Package

clinenoise.

Source

cwrappers.lisp.

Macro: with-raw-mode ((fd) &body b)
Package

clinenoise.

Source

clinenoise.lisp.


5.2.4 Ordinary functions

Function: clear-screen ()
Package

clinenoise.

Source

clinenoise.lisp.

Function: complete-line (ls)
Package

clinenoise.

Source

clinenoise.lisp.

Function: copy-linenoise-state (instance)
Package

clinenoise.

Source

clinenoise.lisp.

Function: cread (fd buf nbyte)
Package

clinenoise.

Source

cwrappers.lisp.

Function: edit (fd prompt plen)
Package

clinenoise.

Source

clinenoise.lisp.

Function: edit-backspace (l)
Package

clinenoise.

Source

clinenoise.lisp.

Function: edit-delete (l)
Package

clinenoise.

Source

clinenoise.lisp.

Function: edit-delete-prev-word (l)
Package

clinenoise.

Source

clinenoise.lisp.

Function: edit-history-next (l dir)
Package

clinenoise.

Source

clinenoise.lisp.

Function: edit-insert (l c)
Package

clinenoise.

Source

clinenoise.lisp.

Function: edit-move-left (l)
Package

clinenoise.

Source

clinenoise.lisp.

Function: edit-move-right (l)
Package

clinenoise.

Source

clinenoise.lisp.

Function: enable-raw-mode (fd)
Package

clinenoise.

Source

clinenoise.lisp.

Function: get-columns ()
Package

clinenoise.

Source

clinenoise.lisp.

Function: getenv (name)
Package

clinenoise.

Source

cwrappers.lisp.

Function: is-unsupported-term ()
Package

clinenoise.

Source

clinenoise.lisp.

Function: isatty (fd)
Package

clinenoise.

Source

cwrappers.lisp.

Function: linenoise-beep ()
Package

clinenoise.

Source

clinenoise.lisp.

Function: linenoise-clear-screen ()
Package

clinenoise.

Source

clinenoise.lisp.

Function: linenoise-raw (prompt plen)
Package

clinenoise.

Source

clinenoise.lisp.

Function: linenoise-set-multiline (ml)
Package

clinenoise.

Source

clinenoise.lisp.

Function: linenoise-state-p (object)
Package

clinenoise.

Source

clinenoise.lisp.

Reader: ls-buf (instance)
Writer: (setf ls-buf) (instance)
Package

clinenoise.

Source

clinenoise.lisp.

Target Slot

buf.

Reader: ls-cols (instance)
Writer: (setf ls-cols) (instance)
Package

clinenoise.

Source

clinenoise.lisp.

Target Slot

cols.

Reader: ls-fd (instance)
Writer: (setf ls-fd) (instance)
Package

clinenoise.

Source

clinenoise.lisp.

Target Slot

fd.

Reader: ls-history-index (instance)
Writer: (setf ls-history-index) (instance)
Package

clinenoise.

Source

clinenoise.lisp.

Target Slot

history-index.

Reader: ls-maxrows (instance)
Writer: (setf ls-maxrows) (instance)
Package

clinenoise.

Source

clinenoise.lisp.

Target Slot

maxrows.

Reader: ls-oldpos (instance)
Writer: (setf ls-oldpos) (instance)
Package

clinenoise.

Source

clinenoise.lisp.

Target Slot

oldpos.

Reader: ls-plen (instance)
Writer: (setf ls-plen) (instance)
Package

clinenoise.

Source

clinenoise.lisp.

Target Slot

plen.

Reader: ls-pos (instance)
Writer: (setf ls-pos) (instance)
Package

clinenoise.

Source

clinenoise.lisp.

Target Slot

pos.

Reader: ls-prompt (instance)
Writer: (setf ls-prompt) (instance)
Package

clinenoise.

Source

clinenoise.lisp.

Target Slot

prompt.

Function: make-linenoise-state (&key fd buf prompt plen pos oldpos cols maxrows history-index)
Package

clinenoise.

Source

clinenoise.lisp.

Function: my-read-char (fd)
Package

clinenoise.

Source

clinenoise.lisp.

Function: my-unread-char (ch fd)
Package

clinenoise.

Source

clinenoise.lisp.

Function: refresh-line (l)
Package

clinenoise.

Source

clinenoise.lisp.

Function: refresh-multi-line (l)
Package

clinenoise.

Source

clinenoise.lisp.

Function: refresh-single-line (l)
Package

clinenoise.

Source

clinenoise.lisp.

Function: restore-tty (fd orig-termios)
Package

clinenoise.

Source

clinenoise.lisp.

Function: set-completion-callback (fn)
Package

clinenoise.

Source

clinenoise.lisp.

Function: tcgetattr (fd termios-p)
Package

clinenoise.

Source

cwrappers.lisp.

Function: tcsetattr (fd optional-actions termios-p)
Package

clinenoise.

Source

cwrappers.lisp.

Function: zero-or-error-from-c (value)
Package

clinenoise.

Source

cwrappers.lisp.


5.2.5 Structures

Structure: linenoise-state
Package

clinenoise.

Source

clinenoise.lisp.

Direct superclasses

structure-object.

Direct slots
Slot: fd
Readers

ls-fd.

Writers

(setf ls-fd).

Slot: buf
Readers

ls-buf.

Writers

(setf ls-buf).

Slot: prompt
Readers

ls-prompt.

Writers

(setf ls-prompt).

Slot: plen
Readers

ls-plen.

Writers

(setf ls-plen).

Slot: pos
Readers

ls-pos.

Writers

(setf ls-pos).

Slot: oldpos
Readers

ls-oldpos.

Writers

(setf ls-oldpos).

Slot: cols
Readers

ls-cols.

Writers

(setf ls-cols).

Slot: maxrows
Readers

ls-maxrows.

Writers

(setf ls-maxrows).

Slot: history-index
Readers

ls-history-index.

Writers

(setf ls-history-index).


Appendix A Indexes


A.1 Concepts


A.2 Functions

Jump to:   (  
C   E   F   G   H   I   L   M   R   S   T   W   Z  
Index Entry  Section

(
(setf ls-buf): Private ordinary functions
(setf ls-cols): Private ordinary functions
(setf ls-fd): Private ordinary functions
(setf ls-history-index): Private ordinary functions
(setf ls-maxrows): Private ordinary functions
(setf ls-oldpos): Private ordinary functions
(setf ls-plen): Private ordinary functions
(setf ls-pos): Private ordinary functions
(setf ls-prompt): Private ordinary functions

C
clear-screen: Private ordinary functions
complete-line: Private ordinary functions
copy-linenoise-state: Private ordinary functions
cread: Private ordinary functions

E
edit: Private ordinary functions
edit-backspace: Private ordinary functions
edit-delete: Private ordinary functions
edit-delete-prev-word: Private ordinary functions
edit-history-next: Private ordinary functions
edit-insert: Private ordinary functions
edit-move-left: Private ordinary functions
edit-move-right: Private ordinary functions
enable-raw-mode: Private ordinary functions

F
Function, (setf ls-buf): Private ordinary functions
Function, (setf ls-cols): Private ordinary functions
Function, (setf ls-fd): Private ordinary functions
Function, (setf ls-history-index): Private ordinary functions
Function, (setf ls-maxrows): Private ordinary functions
Function, (setf ls-oldpos): Private ordinary functions
Function, (setf ls-plen): Private ordinary functions
Function, (setf ls-pos): Private ordinary functions
Function, (setf ls-prompt): Private ordinary functions
Function, clear-screen: Private ordinary functions
Function, complete-line: Private ordinary functions
Function, copy-linenoise-state: Private ordinary functions
Function, cread: Private ordinary functions
Function, edit: Private ordinary functions
Function, edit-backspace: Private ordinary functions
Function, edit-delete: Private ordinary functions
Function, edit-delete-prev-word: Private ordinary functions
Function, edit-history-next: Private ordinary functions
Function, edit-insert: Private ordinary functions
Function, edit-move-left: Private ordinary functions
Function, edit-move-right: Private ordinary functions
Function, enable-raw-mode: Private ordinary functions
Function, get-columns: Private ordinary functions
Function, getenv: Private ordinary functions
Function, history-add: Public ordinary functions
Function, history-load: Public ordinary functions
Function, history-save: Public ordinary functions
Function, is-unsupported-term: Private ordinary functions
Function, isatty: Private ordinary functions
Function, linenoise: Public ordinary functions
Function, linenoise-beep: Private ordinary functions
Function, linenoise-clear-screen: Private ordinary functions
Function, linenoise-raw: Private ordinary functions
Function, linenoise-set-multiline: Private ordinary functions
Function, linenoise-state-p: Private ordinary functions
Function, ls-buf: Private ordinary functions
Function, ls-cols: Private ordinary functions
Function, ls-fd: Private ordinary functions
Function, ls-history-index: Private ordinary functions
Function, ls-maxrows: Private ordinary functions
Function, ls-oldpos: Private ordinary functions
Function, ls-plen: Private ordinary functions
Function, ls-pos: Private ordinary functions
Function, ls-prompt: Private ordinary functions
Function, make-linenoise-state: Private ordinary functions
Function, my-read-char: Private ordinary functions
Function, my-unread-char: Private ordinary functions
Function, refresh-line: Private ordinary functions
Function, refresh-multi-line: Private ordinary functions
Function, refresh-single-line: Private ordinary functions
Function, restore-tty: Private ordinary functions
Function, set-completion-callback: Private ordinary functions
Function, tcgetattr: Private ordinary functions
Function, tcsetattr: Private ordinary functions
Function, zero-or-error-from-c: Private ordinary functions

G
get-columns: Private ordinary functions
getenv: Private ordinary functions

H
history-add: Public ordinary functions
history-load: Public ordinary functions
history-save: Public ordinary functions

I
ioctl: Private macros
is-unsupported-term: Private ordinary functions
isatty: Private ordinary functions

L
linenoise: Public ordinary functions
linenoise-beep: Private ordinary functions
linenoise-clear-screen: Private ordinary functions
linenoise-raw: Private ordinary functions
linenoise-set-multiline: Private ordinary functions
linenoise-state-p: Private ordinary functions
ls-buf: Private ordinary functions
ls-cols: Private ordinary functions
ls-fd: Private ordinary functions
ls-history-index: Private ordinary functions
ls-maxrows: Private ordinary functions
ls-oldpos: Private ordinary functions
ls-plen: Private ordinary functions
ls-pos: Private ordinary functions
ls-prompt: Private ordinary functions

M
Macro, ioctl: Private macros
Macro, with-raw-mode: Private macros
make-linenoise-state: Private ordinary functions
my-read-char: Private ordinary functions
my-unread-char: Private ordinary functions

R
refresh-line: Private ordinary functions
refresh-multi-line: Private ordinary functions
refresh-single-line: Private ordinary functions
restore-tty: Private ordinary functions

S
set-completion-callback: Private ordinary functions

T
tcgetattr: Private ordinary functions
tcsetattr: Private ordinary functions

W
with-raw-mode: Private macros

Z
zero-or-error-from-c: Private ordinary functions


A.3 Variables

Jump to:   *   +  
B   C   F   H   M   O   P   S  
Index Entry  Section

*
*completion-callback*: Private special variables
*history*: Private special variables
*history-len*: Private special variables
*mlmode*: Private special variables
*unread-char*: Private special variables

+
+linenoise-default-history-max-len+: Private constants
+linenoise-max-line+: Private constants
+unsupported-term+: Private special variables

B
buf: Private structures

C
cols: Private structures
Constant, +linenoise-default-history-max-len+: Private constants
Constant, +linenoise-max-line+: Private constants

F
fd: Private structures

H
history-index: Private structures

M
maxrows: Private structures

O
oldpos: Private structures

P
plen: Private structures
pos: Private structures
prompt: Private structures

S
Slot, buf: Private structures
Slot, cols: Private structures
Slot, fd: Private structures
Slot, history-index: Private structures
Slot, maxrows: Private structures
Slot, oldpos: Private structures
Slot, plen: Private structures
Slot, pos: Private structures
Slot, prompt: Private structures
Special Variable, *completion-callback*: Private special variables
Special Variable, *history*: Private special variables
Special Variable, *history-len*: Private special variables
Special Variable, *mlmode*: Private special variables
Special Variable, *unread-char*: Private special variables
Special Variable, +unsupported-term+: Private special variables