progress.ansi

Handy ANSI related functionality. Note: requiring this namespace has the side effect of enabling JANSI.

apply-attributes

(apply-attributes attributes s)
Applies all of provided attributes (a seq) to s (a string).

apply-colour

(apply-colour fg? colour-key s)
Applies an 'enhanced' colour keyword (which may include the prefix 'bright-') to either the foreground or background of body.

apply-colours-and-attrs

(apply-colours-and-attrs fg-colour bg-colour attrs s)
Applies the foreground colour, background colour, and attributes (a seq) to s (a string).

debug-print

(debug-print & args)
Send debug output to the upper left corner of the screen, where (hopefully) it minimises interference with everything else.

debug-print-at

(debug-print-at x y & args)
Send debug output to the specified screen location (note: ANSI screen coordinates are 1-based).

print-at

(print-at x y & msgs)
Send text output to the specified screen locations (note: ANSI screen coordinates are 1-based). msgs may include jansi formatting.

restore-cursor!

(restore-cursor!)
Issues both SCO and DEC restore-cursor ANSI codes, for maximum compatibility.

save-cursor!

(save-cursor!)
Issues both SCO and DEC save-cursor ANSI codes, for maximum compatibility.