3 ms·
I'm a little surprised something like "$(fgcolor red hello)" requires a $(fgcolor end) - if you include arguments shouldn't it be self-closing? Then you get nic
by ianbicking 11y ago
I'm a little surprised something like "$(fgcolor red hello)" requires a $(fgcolor end) - if you include arguments shouldn't it be self-closing? Then you get nice things like "$(fgcolor red " $(hr)")"
$(title "header") could be cool, outputting " header$(br)------"
An alias for \r could be nice, to go with $(br).
- burke 11y agoBut if you've done: "$(fgcolor red)red text$(fgcolor green "green text") what color is this?"... then it would have to model a stack on top of the actual underlying implementation, which does not have any concept of "closing" a sequence to pop the colour back to the previous colour. It could automatically emit the \x1b[0m, but it would be making assumptions about nesting.