Release 0.13.0 adds a new rendering decoration system for reporting. It also includes a bug fix.
New features
In #387 @urisinger changed diagnostic emitting to be based on a new writer trait WriteStyle
. This addition allows more flexibility in the output of emitting diagnostics. For example the default terminal ANSI style can be swapped out for SVG tag generation (see example). The change includes std::term::config::styles::StylesWriter
and std::term::config::styles::Styles
for customisation of colours and other decoration during emit.
This feature is backwards compatible with original termcolor
writers.
Bug fixes and user changes
The 0.12.0 version of codespan included ![no_std]
support thanks to PR #374. Unfortunately, there were a few issues with it that were not caught by CI and went under the radar such as tests not passing under --no-default-features
#399.
Another issue included complications with std::io::Write
vs core::fmt::Write
. This meant that String
would work under --no-default-features
but break with --feature std
.
PR #400 adds checks for tests across feature configurations and adds different emit
functions for different types of writers used. This includes a emit_to_string
function that should work across feature configuration.
There still needs to be improvements in this area but I have not landed on anything simple.
WIP: It also adds a check to dependants of the library to check whether changes are compatible.
If you find any issues or have a feature suggestion, leave them in the issues.
Full Changelog: release/codespan-0.12.0...release/codespan-0.13.0