Frage

I created a small utility to print tables in Java which outputs stuff like:

/-----------\
|  header   |
⊢---⊤---⊤---⊣
| A | B | C |
⊢---⊥-⊤-⊥---⊣
| D   | E   |
⊢---⊤-⊥-⊤---⊣
| A | B | C |
∟---⊥---⊥---/

Which is pretty ugly because the lines of the different characters are not aligned, currently I fall back on the + char to have:

⋅-----------⋅
|  header   |
+---+---+---+
| A | B | C |
+---+-+-+---+
| D   | E   |
+---+-+-+---+
| A | B | C |
⋅---+---+---⋅

But I was wondering if this was possible to have cleaner symbols like the T and L but centered in order to join the - and |.

This is Java code so I can easily use any UTF-8 char but did not find anything that suited me in the math character tables. If these characters exist only in other encoding I'm also interested I can find a way to use them.

War es hilfreich?

Lösung

Thanks to valexhome, the UTF8 block "Box Drawing" was indeed was I was looking for, now its wonderful :

┌───────────┐
│  header   │
├───┬───┬───┤
│ A │ B │ C │
├───┴─┬─┴───┤
│ D   │ E   │
├───┬─┴─┬───┤
│ A │ B │ C │
└───┴───┴───┘
Lizenziert unter: CC-BY-SA mit Zuschreibung
Nicht verbunden mit StackOverflow
scroll top