You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
with custom specifiers:
if specifier is empty then write CSI-sequence bg & fg specifiers for Color type: treat value as background & foreground respectively np: don't write CSI prefix for intelligent updates
As result:
debug.print("{fg} FG red {bg} BG green {} default", { .Red, .Green, .Reset });
The text was updated successfully, but these errors were encountered:
This is of course convenient for enabling applications to have colored terminal output. But I think this library should also be robust and still provide the low-level interfaces like updateStyle in order to minimize the bytes written to the terminal.
Another counter-proposal: I think the most common use case for this high-level printing would be in association with compile-time known styles. This means we can design a function
pubfnred(comptimetext: []constu8) []constu8
and use this for example:
std.debug.print("{}: "++Styled.red("Path {} does not exist"), .{ time(), path });
format
fn forColor
andFontStyle
typesif specifier is empty then write CSI-sequence
bg
&fg
specifiers for Color type: treat value as background & foreground respectivelynp
: don't write CSI prefix for intelligent updatesAs result:
The text was updated successfully, but these errors were encountered: