A Modest Definition List Proposal
    David E. Wheeler 
    david at kineticode.com
       
    Wed Feb 18 15:36:56 EST 2009
    
    
  
On Feb 18, 2009, at 12:19 PM, Waylan Limberg wrote:
>> Comments? Has this ship already sailed?
>
> You make a convincing argument. And I must admit your proposal is very
> nice to look at/read/write.
Thank you.
> But if it ain't broke, don't fix it.
>
> The current implementation was set before I came along some few years
> ago, and I have never searched through the archives to see how it came
> about or why. But, people have been using it for this long without
> issue and there are already numerous existing documents out there that
> use it, so I see no reason to change it. In fact that last point
> (numerous existing documents) seems to be the de-facto response to any
> suggested changes on this list - and understandably so. No doubt
> that's why you suggested leaving the existing syntax in place, but
> then we would have two ways to define deflists. What happens when an
> author mixes the two? Ack! Yeah, this ship has sailed IMO.
I don't think it's a problem to have two different kinds of bullets  
for definition list items; after all, you can already use +, -, or *  
for unordered lists. And you can mix them without penalty, so the same  
would be true here.
FWIW, the change to MultiMarkdown.pl to make this work would just be  
this:
--- bin/MultiMarkdown.pl.orig	2008-01-18 15:08:43.000000000 -0800
+++ bin/MultiMarkdown.pl	2009-02-18 12:28:47.000000000 -0800
@@ -2559,7 +2559,7 @@
  	
  	my $definition = qr{
  		\n?[ ]{0,$less_than_tab}
-		\:[ \t]+(.*?)\n
+		[:~][ \t]+(.*?)\n
  		((?=\n*[ ]{0,$less_than_tab}\S)|\n\n|\Z)	# Lookahead for non-space  
at line-start,
  		 										# two returns, or end of doc
  	}sx;
Plus documentation, of course. Doesn't get much simpler than that.
Thanks for your reply.
Best,
David
    
    
More information about the Markdown-Discuss
mailing list