textile / python-textile

A Python port of Textile, A humane web text generator
Other
68 stars 23 forks source link

Table header formatting #7

Closed rcarmo closed 10 years ago

rcarmo commented 10 years ago

Hello there,

I'm having a spot of bother in that column spanning headers (\3_. header for a header that would span three columns) don't render correctly.

This works on an ancient version I have, but not in 2.1.8.

rcarmo commented 10 years ago

Here's a sample snippet of working markup:

h3. Charting and Plotting

table(compact).
|_. Date |_. Link |_. Type |_. Formats |_. Rating |_. Notes |
|\6_. 2014 |
| Jun 26 | "Epoch":http://fastly.github.io/epoch/ | "JavaScript":dev/JavaScript | "SVG":SVG | 5 stars | Real-time charting done sensibly |

...taken from this page, which is rendered with the old version linked above. Textile 2.1.8 simply leaves the \6_. 2014 in a single table cell on that table row and moves on.

ikirudennis commented 10 years ago

I think the textile syntax you're looking for would be: |_\6. 2014 | instead. Does that resolve the issue for you?

rcarmo commented 10 years ago

Hmm. I've been using Textile for well over a decade now, and all my column spanning headers were built that way (pretty sure the PHP renderer I used in 2001 did that too). If that's the actual standard, I'll have to reformat a few hundred pages...

rcarmo commented 10 years ago

So I spent a while looking for the ancient (now extinct) Textile references and testing my old version, and yes, that markup seems to be the correct one. My older module is somewhat lax at validating the presence of an underscore character inside a table format marker, so I'm going to bit the bullet and reformat my old content (vim should make it easy enough to begin with).

rcarmo commented 10 years ago

Oh, it might be a good idea to add that markup to an example/test, just in case. Cheers!