0

I have following table in asciidoc, for which I want the very first cell to be split diagonally (or by some other means more readable) in the sense that it is clear that the top row is the "to", the first column is the "from" one:

[cols=","]
|===
a|
To →

From ↓

|Hans
|Karl
|Secret gift
|===

Please note that if I change to [cols=",",options="header"] the spaces of the first cell are removed, making it even harder to understand the table semantics.

See also How can a split diagonally a table header cell? for similar question explaining the requirement in HTML

DaHoC
  • 314
  • 1
  • 4
  • 14

1 Answers1

1

You would need custom CSS, and possibly a background image, to perform the diagonal split that you seek.

However, built-in roles might suffice:

[cols="a,"]
|===
h|
[.right]#to →#

From ↓

|Hans
|Karl
|Secret gift
|===

This makes the "to/from" cell a header, and uses the default theme's .right style to move the "to" to the right edge of the cell.

If you do need to apply custom styles, see the section on Docinfo Files.

The answers to this question might provide an appropriate solution for you.

eskwayrd
  • 3,691
  • 18
  • 23