4 ms·
Nice work, I love exploiting unicode characters to "draw" in terminal environments. You seem to use '╰', '╮', '╭' and '╯' to approximate non-straight lines, int
by protomikron 8y ago
Nice work, I love exploiting unicode characters to "draw" in terminal environments. You seem to use '╰', '╮', '╭' and '╯' to approximate non-straight lines, interesting idea, I haven't seen this before.
Another approach is to use block characters, like U+259A or U+259E (see https://en.wikipedia.org/wiki/Block_Elements https://en.wikipedia.org/wiki/Block_Elements), but unfortunately it is hard to do when you want to support colors as it doesn't go well with intersections.
//edit: HN does not like block elements, but your 21th century terminal will print them
- noximo 8y agoThank you! Well, the idea wasn't mine, I built it upon another library. But from what I gathered, these symbols are made for drawing, so I'm not really exploiting anything: https://en.wikipedia.org/wiki/Box-drawing_character https://en.wikipedia.org/wiki/Box-drawing_character