This release follows the Dahlia Specification v1.0.0.
Added
- Automatic color depth detection (as a consequence,
Dahlia
'sdepth
parameter can now beNone
) - Style-specific reset codes
- The
&_
escape code - The
clean_ansi
function should now handle way more ANSI escape codes - The package can now be executed with
python -m dahlia
to show the current terminal emulator's capabilities - Various performance improvements:
- String conversions are now approximately ~70% faster
- A comprehensive benchmark showed an overall library speedup of 20%
Changed
- The "Blink" style code was changed from
&p
to&k
- The custom color syntax was changed from
&[#ffaff3]
to&#ffaff3;
and now supports shorthand 3-digit codes - The
Dahlia.depth
property now returns aDepth | None
instead of anint
- The full reset code is now
&R
instead of&r
- The "Hide" style code was changed from
&k
to&h
- The
no_reset
parameter and property was renamed toauto_reset
and now defaults toTrue
Fixed
- Type checkers no longer complain about non-lowercase depth strings
Removed
Dahlia.reset
Dahlia.test
- Dahlia's
no_color
parameter - The CLI tool
- The
&g
code - The legacy
dahlia
,dprint
, anddinput
functions - The
quantize_ansi
utility function