Functionality for printing to the console, probably using ANSI coloring.
Functionality for printing to the console, probably using ANSI coloring.
(color-256 fg & [bg])
Ansi control codes for 256 color code, with optional background color
Ansi control codes for 256 color code, with optional background color
(cols)
(cols env)
Returns number of columns in the console
Returns number of columns in the console
(ctrl-code & parts)
Formats an Ansi control code with given parts
Formats an Ansi control code with given parts
(erase-line)
(erase-line n)
Erases part or all of the line.
For values of n
:
0
: from cursor to EOL
1
: from cursor to beginning of line
2
: entire line (default)
Erases part or all of the line. For values of `n`: `0`: from cursor to EOL `1`: from cursor to beginning of line `2`: entire line (default)
(font-code & parts)
Ansi control codes for font formatting
Ansi control codes for font formatting
(overwrite s & args)
Overwrites the previous line with the string
Overwrites the previous line with the string
(print-lines lines)
Prints given sequence of lines
Prints given sequence of lines
(progress-bar {w :width
p :value
f :filled-char
u :unfilled-char
dp :decimal-fill
s :start
:or {f \█ u \space s 0}})
Creates progress bar of given width (chars) with given value filled. If
decimal-fill
is specified, it is used to determine the char when a
place is only partially filled. Returns a string that can be printed
to console.
Creates progress bar of given width (chars) with given value filled. If `decimal-fill` is specified, it is used to determine the char when a place is only partially filled. Returns a string that can be printed to console.
(render-next {:keys [prev renderer state]})
Used in a render loop: renders the next iteration, given the rendering state, which contains the previously rendered lines, the renderer and rendering state. The cursor jumps back to the original printing position, according to the number of lines previously printed.
Used in a render loop: renders the next iteration, given the rendering state, which contains the previously rendered lines, the renderer and rendering state. The cursor jumps back to the original printing position, according to the number of lines previously printed.
(rows)
(rows env)
Returns number of lines in the console
Returns number of lines in the console
cljdoc builds & hosts documentation for Clojure/Script libraries
Ctrl+k | Jump to recent docs |
← | Move to previous article |
→ | Move to next article |
Ctrl+/ | Jump to the search field |