Hello List, Firstly, I was very impressed when I tried markdown 2.0 recently. Fantastic work all! I have a query about the treatment of emphasis. I realise that the horse has bolted, and changes to currently supported functionality are unlikely to attract support. However, there does seem (at least in my tiny mind) to be a mis-match between the following stated goal and the present implementation of emphasis: Quote (from http://daringfireball.net/projects/markdown/syntax#philosophy): Markdown?s syntax is comprised entirely of punctuation characters, which punctuation characters have been carefully chosen so as to *look like what they mean*. It seems to me that *writers* who are not programmers are thinking in terms of italic, bold, underlined, or stuckout text and so on. A *writer* is not thinking about abstract concepts like <em> or <strong> or any HTML at all. During a process of "marking down" some informally structured text files in order to get them into HTML, I have encountered the following "syntax" : Here is some plain text that looks /italic/. Here is some plain text that looks -s-t-r-u-c-k-o-u-t-. Here is some plain text that looks _underlined_. Here is some plain text that looks *bold*. This issue I see is that stylistic information intended by the author is * lost* by the current implementation. Markdown supports only two flavours of emphasis (<em> and <strong>) while writers can intend at least the four flavours of emphasis mentioned above (bold, italic, underlined, struck out). I.e., information is "lost in translation". Also, there is no guarantee that browsers will render <em> or <strong> in the style intended by the author, because <em> and <strong> have intentionally been abstracted away from the writer's concepts of bold, italic, underlined and so on. I don't see that those abstractions are helpful where readability of the plain text source file, and the goal quoted (above) are the primary concerns. One possible solution to my issue would be something like this: /some text/ --> <font style="italic">some text</font> -s-o-m-e-t-e-x-t- --> <font style="struckout">some text</font> _some text_ --> <font style="underline">some text</font> *some text* --> <font style="bold">some text</font> I anticipate that there probably won't be much appetite for changing the markdown tool, so I intend to have a go at implementing the above for my own "local" markdown (with approximately zero knowledge of Python). However, I would be interested what other list members think about this? Does anyone else see it as an issue or not? Thanks all, and GREAT WORK markdown team! Simon -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://six.pairlist.net/pipermail/markdown-discuss/attachments/20090621/f7335cad/attachment.html>
Markdown 2.0? On Sunday, June 21, 2009, Simon Bull <waysoftheearth at yahoo.com.au> wrote:> Hello List, > > Firstly, I was very impressed when I tried markdown 2.0 recently.? Fantastic work all! > > I have a query about the treatment of emphasis. > > I realise that the horse has bolted, and changes to currently supported functionality are unlikely to attract support.? However, there does seem (at least in my tiny mind) to be a mis-match between the following stated goal and the present implementation of emphasis: > > > Quote (from http://daringfireball.net/projects/markdown/syntax#philosophy): > ??? Markdown?s syntax is comprised entirely of punctuation characters, which punctuation characters have been carefully chosen so as to look like what they mean. > > > It seems to me that *writers* who are not programmers are thinking in terms of italic, bold, underlined, or stuckout text and so on.? A *writer* is not thinking about abstract concepts like <em> or <strong> or any HTML at all. > > During a process of "marking down" some informally structured text files in order to get them into HTML, I have encountered the following "syntax" : > > ??? Here is some plain text that looks /italic/. > ??? Here is some plain text that looks -s-t-r-u-c-k-o-u-t-. > ??? Here is some plain text that looks _underlined_. > ??? Here is some plain text that looks *bold*. > > This issue I see is that stylistic information intended by the author is lost by the current implementation.? Markdown supports only two flavours of emphasis (<em> and <strong>) while writers can intend at least the four flavours of emphasis mentioned above (bold, italic, underlined, struck out).? I.e., information is "lost in translation". > > Also, there is no guarantee that browsers will render <em> or <strong> in the style intended by the author, because <em> and <strong> have intentionally been abstracted away from the writer's concepts of bold, italic, underlined and so on.? I don't see that those abstractions are helpful where readability of the plain text source file, and the goal quoted (above) are the primary concerns. > > One possible solution to my issue would be something like this: > > ??? /some text/???????? -->? <font style="italic">some text</font> > ??? -s-o-m-e-t-e-x-t-?? -->? <font style="struckout">some text</font> > ??? _some text_???????? -->? <font style="underline">some text</font> > ??? *some text*???????? -->? <font style="bold">some text</font> > > I anticipate that there probably won't be much appetite for changing the markdown tool, so I intend to have a go at implementing the above for my own "local" markdown (with approximately zero knowledge of Python).? However, I would be interested what other list members think about this?? Does anyone else see it as an issue or not? > > Thanks all, and GREAT WORK markdown team! > > Simon > > > > > > >-- Joseph Lorenzo Hall ACCURATE Postdoctoral Research Associate UC Berkeley School of Information Princeton Center for Information Technology Policy http://josephhall.org/
My apologies for the ambiguity -- I was referring to the python implementation which seems to be known as markdown2 (see http://pypi.python.org/pypi/markdown2/1.0.1.12). Simon On Sun, Jun 21, 2009 at 9:26 PM, Simon Bull <simonbull at gmail.com> wrote:> My apologies for the ambiguity -- I was referring to the python > implementation which seems to be known as markdown2 (see > http://pypi.python.org/pypi/markdown2/1.0.1.12). > > Simon > > On Sun, Jun 21, 2009 at 8:24 PM, Joseph Lorenzo Hall <joehall at gmail.com>wrote: > >> Markdown 2.0? >> >> >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://six.pairlist.net/pipermail/markdown-discuss/attachments/20090621/cb2a5e41/attachment.htm>
> /some text/ --> <font style="italic">some text</font> > -s-o-m-e-t-e-x-t- --> <font style="struckout">some text</font> > _some text_ --> <font style="underline">some text</font> > *some text* --> <font style="bold">some text</font> > > I anticipate that there probably won't be much appetite for changing the > markdown tool, so I intend to have a go at implementing the above for my own > "local" markdown (with approximately zero knowledge of Python). However, I > would be interested what other list members think about this? Does anyone > else see it as an issue or not? > > Thanks all, and GREAT WORK markdown team! > >If you implement it, keep it simple: <i>some text</i> Or possibly if you want more control <span class="italic">some text</span>? One of the things I don't like about the markdown spec is that while I can do strong or emphasis I can't do strong emphasis. Warning: Written before coffee. -- Sherwood Botsford Sherwood's Forests -- http://Sherwoods-Forests.com [Note: THREE s's in the web link] 780-848-2548 50042 Range Rd 31 Warburg, Alberta T0C 2T0 -------------- next part -------------- An HTML attachment was scrubbed... URL: <http://six.pairlist.net/pipermail/markdown-discuss/attachments/20090621/45db1edf/attachment.html>
On Sun, Jun 21, 2009 at 4:20 AM, Simon Bull<waysoftheearth at yahoo.com.au> wrote:> > One possible solution to my issue would be something like this: > > ??? /some text/???????? -->? <font style="italic">some text</font> > ??? -s-o-m-e-t-e-x-t-?? -->? <font style="struckout">some text</font> > ??? _some text_???????? -->? <font style="underline">some text</font> > ??? *some text*???????? -->? <font style="bold">some text</font> > > I anticipate that there probably won't be much appetite for changing the > markdown tool, so I intend to have a go at implementing the above for my own > "local" markdown (with approximately zero knowledge of Python).Python-Markdown [1] (not Markdown2) recently released version 2.0 in which most of the code has been refactored. The thing about Python-Markdown (as opposed to any other implementation AFAIK) is that it is very easy to alter the syntax to your liking via the extension API. You can find the docs here: http://gitorious.org/python-markdown/mainline/blobs/master/docs/writing_extensions.txt or here (but it looks like the wiki is having some spam issues): http://www.freewisdom.org/projects/python-markdown/Writing_Extensions&version=000011 I'd suggest replacing/adding your own "InlinePatterns" to alter the existing emphasis and strong patterns. If you need any help, feel free to ask. [1]: http://pypi.python.org/pypi/Markdown -- ---- \X/ /-\ `/ |_ /-\ |\| Waylan Limberg
Okay, thanks for the clarification. On Mon, Jun 22, 2009 at 10:55 PM, Waylan Limberg <waylan at gmail.com> wrote:> On Mon, Jun 22, 2009 at 12:02 AM, Simon Bull<waysoftheearth at yahoo.com.au> > wrote: > > Okay, thanks for the pointers -- I will see how far I get. > > > > So what is the relationship (if any) between the Python-Markdown[1] and > the > > Markdown2[2] implementations? > > Other than the fact that they are both markdown implementations and > both are written in python - none. Python Markdown has been around a > lot longer and has an extensive extension api. Markdown2 is intended > to be a direct port markdown.pl and is relatively young. To my > knowledge they do not share any code and are maintained by different > individuals. > > > Is this list primarily oriented toward discussion of one over the other, > or > > open to more general discussion? > > This list was (I believe) originally intended for discussion of the > perl implementation (the first - created by John Gruber) and has > expanded to be a general discussion forum for any and all > implementations. > > If you would like to discuss specifics or code regarding the > Python-Markdown implementation, we have our own list here: > > > http://sourceforge.net/mailarchive/forum.php?forum_name=python-markdown-discuss > > -- > ---- > \X/ /-\ `/ |_ /-\ |\| > Waylan Limberg > _______________________________________________ > Markdown-Discuss mailing list > Markdown-Discuss at six.pairlist.net > http://six.pairlist.net/mailman/listinfo/markdown-discuss >-------------- next part -------------- An HTML attachment was scrubbed... URL: <http://six.pairlist.net/pipermail/markdown-discuss/attachments/20090622/6c678cf6/attachment.html>