Tables
    Daniel Winterstein 
    daniel.winterstein at gmail.com
       
    Thu Feb 19 04:16:10 EST 2009
    
    
  
@John: Thank you for pointing me to those table syntax ideas. They are
all sensible, but look like hard work for the user.
Since there is no standard, I'd like to suggest a couple of
possibilities and get people's comments.
Design goals:
 - A table should look like a table in plain text
 - It must be easy to create
 - It must be flexible about how much text can go in a cell
 - It shouldn't force you to use a fixed-width font
Suggestion 1:
 - A table begins with a header row where columns are separated by |s.
It ends with a blank line.
 - It can optionally include lines of -----s, which are ignored when
generating html
 - Within a table, columns are separated by either a tab or 3 or more
spaces. Actual alignment of text is up to the user. Alignment varies
of course depending on font. In my examples below, I have aligned the
columns _for my email editor_.
 - If you want more control over a particular cell or row, you can use
an html cell or row
 - If you need more control than that, use an html table
Example:
| Wine			       | Tasting notes		
--------------------------------------------------------
Black Stump Bordeaux 	peppermint flavoured Burgundy
Sydney Syrup 		        ranks among the world's best sugary wines
Château Blue		        lingering afterburn
Old Smokey 1968		compares favourably to a Welsh claret
1970 Coq du Rod Laver	recommended by the Australian Wino Society
Melbourne Old-and-Yellow	a good fighting wine is, which is
particularly heavy and best suited for hand-to-hand combat.
<td colspan='2' class='caption'>Table: Lesser Australian wines</td>
Idea 2: Use a table tag to mark a table block. If the contents are not
html, then convert them
<table class='my-table-css'>
Wine			                Tasting notes		
Château Chunder		a fine wine which really opens up the sluices at both ends.
Sydney Syrup 		        ranks among the world's best sugary wines
Château Blue		        lingering afterburn
Old Smokey 1968		compares favourably to a Welsh claret
1970 Coq du Rod Laver	recommended by the Australian Wino Society
Melbourne Old-and-Yellow	a good fighting wine is, which is
particularly heavy and best suited for hand-to-hand combat.
</table>
Pros: can provide class information and border settings.
Idea 3: Use a caption at the end of the table to mark a table block,
with empty captions being allowed.
Example:
Wine			                Tasting notes		
Black Stump Bordeaux 	peppermint flavoured Burgundy
Sydney Syrup 		        ranks among the world's best sugary wines
Château Blue		        lingering afterburn.
Old Smokey 1968		compares favourably to a Welsh claret
1970 Coq du Rod Laver	recommended by the Australian Wino Society
Melbourne Old-and-Yellow	a good fighting wine is, which is
particularly heavy and best suited for hand-to-hand combat.
Table: Lesser Australian wines
What do you think?
Regards,
Daniel
    
    
More information about the Markdown-Discuss
mailing list