Re: attribute blocks for definition lists
On Mon, Jul 1, 2013 at 11:33 AM, Matthieu Codron codronm+markd...@gmail.com wrote: the syntax would be term {#id} : definition Python-Markdown already has extensions for Attribute Lists [1] and Definition Lists [2] (both also available as part of Extra [3]). However, due to the restriction that definition list terms can only be on a single line (each line is a separate term), it was impossible to assign attrs to the term. I was already special casing headers (h1-6) for the same reason, so it wasn't too hard to adapt the code to work with dt's also. I just pushed a fix [4] which implements support for this syntax (you can set any kind of attribute supported by the attr_list extension) and it should be available in the next release of Python-Markdown (probably 2.3.2). As always, testing/feedback is welcome. [1]: http://pythonhosted.org/Markdown/extensions/attr_list.html [2]: http://pythonhosted.org/Markdown/extensions/definition_lists.html [3]:http://pythonhosted.org/Markdown/extensions/extra.html [4]:https://github.com/waylan/Python-Markdown/commit/a9ca97325e9039de90eae29fb3d8879bc9f367f6 \X/ /-\ `/ |_ /-\ |\| Waylan Limberg ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: attribute blocks for definition lists
From: Fletcher T. Penney I'm not sure I want to head down that path yet for MultiMarkdown. I'm not ruling it out for all time, but I worry about the cruft vs reward balance. I understand your point of view. But I'd like to avoid future implementation divergences ; so I'd like to hear you about the propoosed syntax : if you were about to implement it in MultiMarkdown, would you adopt this syntax ? I know you cannot give a definitive answer, but at least can you confirm it seems good to you ? Thanks Matthieu ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: attribute blocks for definition lists
On Wed, Jul 3, 2013 at 6:00 PM, Michel Fortin wrote: Le 1-juil.-2013 ? 11:33, Matthieu Codron codronm+markd...@gmail.com a ?crit : Hello, As I am using markdown to write documentation, I am often tempted to make links to terms in definition lists. Since this is not possible for now (at least in php markdown extra), I was wondering if this could be a common addition in major implementation supporting definition lists. the syntax would be term {#id} : definition This syntax tries to follows current convention and use the similarity between titles and terms. I'm planning to add this to the next version of PHP Markdown Extra. I'd love to see this in PHP Markdown Extra, but also in pandoc and MultiMarkdown... John, Fletcher, what do you think about it ? ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: attribute blocks for definition lists
On 2013-07-02 06:20 +0200 sendi...@gmx.net wrote: I would even go further and (gradually) allow setting {#id .class attr=attr} for *any* element. For block elements it would be in the last or following line and for span elements it would directly follow: e.g. *imporant text*{.special_emphasis}. This is already allowed by kramdown, see http://kramdown.rubyforge.org/syntax.html#inline-attribute-lists Best regards, Thomas ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: attribute blocks for definition lists
On Mon, Jul 1, 2013 at 8:51 AM, Andy Lee ag...@mac.com wrote: Out of curiosity, do I understand correctly that term : definition is already in common usage when people write plain text? I was not aware of that, so if so, I may start adopting it in my own emails etc. I do it regularly, but I generally compose in Markdown without thinking about it and I use definition lists with this syntax quite a bit in other systems where it's standard, so it just comes naturally! c -- Chris Lott ch...@chrislott.org ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
attribute blocks for definition lists
Hello, As I am using markdown to write documentation, I am often tempted to make links to terms in definition lists. Since this is not possible for now (at least in php markdown extra), I was wondering if this could be a common addition in major implementation supporting definition lists. the syntax would be term {#id} : definition This syntax tries to follows current convention and use the similarity between titles and terms. Matthieu ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: attribute blocks for definition lists
This strikes me as a sound suggestion. It would allow us to use a definition list where currently we'd be forced to use headings and paragraphs. On 1 July 2013 08:33, Matthieu Codron codronm+markd...@gmail.com wrote: Hello, As I am using markdown to write documentation, I am often tempted to make links to terms in definition lists. Since this is not possible for now (at least in php markdown extra), I was wondering if this could be a common addition in major implementation supporting definition lists. the syntax would be term {#id} : definition This syntax tries to follows current convention and use the similarity between titles and terms. Matthieu ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: attribute blocks for definition lists
I don't know about the {#id} part, but MultiMarkdown recognizes that syntax for definition lists. Out of curiosity, do I understand correctly that term : definition is already in common usage when people write plain text? I was not aware of that, so if so, I may start adopting it in my own emails etc. --Andy On Jul 1, 2013, at 11:33 AM, Matthieu Codron codronm+markd...@gmail.com wrote: Hello, As I am using markdown to write documentation, I am often tempted to make links to terms in definition lists. Since this is not possible for now (at least in php markdown extra), I was wondering if this could be a common addition in major implementation supporting definition lists. the syntax would be term {#id} : definition This syntax tries to follows current convention and use the similarity between titles and terms. Matthieu ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: attribute blocks for definition lists
* Andy Lee ag...@mac.com [2013-07-01 18:55]: Out of curiosity, do I understand correctly that term : definition is already in common usage when people write plain text? I was not aware of that, so if so, I may start adopting it in my own emails etc. I’ve never seen it in email. ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: attribute blocks for definition lists
On Jul 1, 2013, at 8:33 AM, Matthieu Codron codronm+markd...@gmail.com wrote: As I am using markdown to write documentation, I am often tempted to make links to terms in definition lists. Since this is not possible for now (at least in php markdown extra), […] It is. You just have to write your anchors manually. ~ Term a id=my-term/a : Definition ~ On Jul 1, 2013, at 9:51 AM, Andy Lee ag...@mac.com wrote: Out of curiosity, do I understand correctly that term : definition is already in common usage when people write plain text? I was not aware of that, so if so, I may start adopting it in my own emails etc. I have only ever seen it in Markdown source. It’s much more natural to use a trailing colon after the term. Alan ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: attribute blocks for definition lists
I would even go further and (gradually) allow setting {#id .class attr=attr} for *any* element. For block elements it would be in the last or following line and for span elements it would directly follow: e.g. *imporant text*{.special_emphasis}. Am 01.07.2013 um 17:52 schrieb David Chambers d...@davidchambers.me: This strikes me as a sound suggestion. It would allow us to use a definition list where currently we'd be forced to use headings and paragraphs. On 1 July 2013 08:33, Matthieu Codron codronm+markd...@gmail.com wrote: Hello, As I am using markdown to write documentation, I am often tempted to make links to terms in definition lists. Since this is not possible for now (at least in php markdown extra), I was wondering if this could be a common addition in major implementation supporting definition lists. the syntax would be term {#id} : definition This syntax tries to follows current convention and use the similarity between titles and terms. Matthieu ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Link syntax (was: definition lists?)
Tangentially, I notice that this post by Waylan uses a link syntax which doesn't seem to be defined by http://daringfireball.net/projects/markdown/syntax#link but seems to work in some implementations at http://babelmark.bobtfish.net/ - that is, from the git repo [1] instead of from the git repo [1][] or from the [git repo] [1]. The link definition is then [1]: http://gitorious.org/projects/python-markdown/repos/mainline Which of the outputs generated at http://babelmark.bobtfish.net/?markdown=checkout+from+the+git+repo+[1]%0D%0Aat+commit+e968bbf+(on+Nov+6)%2C%0D%0A%0D%0A[1]%3A+http%3A%2F%2Fgitorious.org%2Fprojects%2Fpython-markdown%2Frepos%2Fmainlinesrc=1dest=2 (also available at http://tinyurl.com/6hq7ut in case the full URI gets mashed) is considered 'expected'? IIUC, what I'll refer to Waylan's syntax makes any text enclosed in square brackets into a candidate for a link; the parser then searches for a matching link definition. I'm undecided whether the simplicity of this syntax offsets the risk of breaking existing documents. A link will only be generated if a matching link definition is found, IIUC, so perhaps this risk is acceptably low? Please point me to a previous discussion if available, I couldn't find one in the archives. Regards, Thomas. Waylan Limberg wrote on 2008/11/14 20:37: It's in the works. We had a working solution last week, but then refactored the core this week, so I have to refactor the definition list stuff. If you want it right now, your free to checkout from the git repo [1] at commit e968bbf (on Nov 6), or wait a few more days for me to get the refactor done and have the latest and greatest. One thing is for sure, I will have something included in the next release which I anticipate happening soonish. [1]: http://gitorious.org/projects/python-markdown/repos/mainline On Fri, Nov 14, 2008 at 1:26 PM, Andreas Åkre Solberg [EMAIL PROTECTED] wrote: Any way of writing definition lists? Andreas ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: Link syntax (was: definition lists?)
On Fri, Nov 21, 2008 at 10:43 AM, Thomas Nichols [EMAIL PROTECTED] wrote: Tangentially, I notice that this post by Waylan uses a link syntax which doesn't seem to be defined by http://daringfireball.net/projects/markdown/syntax#link but seems to work in some implementations at http://babelmark.bobtfish.net/ - that is, from the git repo [1] Actually, that syntax is a common shortcut used by many people in various mailing lists I subscribe to. Many of the people on these lists do not use (or perhaps even know) markdown syntax. I see it kind of a cross between ``[git repo] [1]`` and a footnote. I never expect these mailing list discussions to ever be feed through a markdown parser and don't go all out with the formatting. I use just enough to make it clear to the human reader in plain text without cluttering things up. For links, I find ``[1]`` works best in such situations and is the most commonly accepted approach in the circles I find myself in. I have concidered adding the ability to convert that syntax to links in Python-Markdown, but have not as the label would be wrong IMO. In the above example the result would be ... git repo a href=http://...;1/a ... when it should be: ... a href=http://...;git repo/a ... Although, now that I think about it, as the reference is removed by the parser, if the single bracketed text (``[1]``) is left alone in the text, it no longer has any meaning. That's probably worse that a link with a meaningless label. Perhaps Markdown should create the link when a reference for it exists. Although, I'd be more inclined to leave the brackets around the text to give it more meaning in the context: a href=http:...[1]/a or maybe [a href=http://...;1/a] That said, its not really a big deal to me, as I only ever use that syntax when I do *not* expect the text I'm typing (i.e.: mailing list discussions) to be feed through a markdown parser. As long as that's the case, none of the above arguments (for or against) are relevant as I see it. -- Waylan Limberg [EMAIL PROTECTED] ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: Link syntax (was: definition lists?)
On Fri, Nov 21, 2008 at 11:36 AM, Jason Blevins [EMAIL PROTECTED] wrote: I couldn't find any discussion of it on the list, but here's the changelog entry: 1.0.2b2 - 20 Mar 2005 + Experimental support for [this] as a synonym for [this][]. Interestingly, this a completely different use for single-bracketed text than I use and see on a daily basis. As I mentioned before, I see it more as a shortcut footnote type syntax for links only when text is expected to be read in plain text format. -- Waylan Limberg [EMAIL PROTECTED] ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: Link syntax (was: definition lists?)
On Fri, Nov 21, 2008 at 12:26 PM, Jason Blevins [EMAIL PROTECTED] wrote: Waylan Limberg wrote: On Fri, Nov 21, 2008 at 11:36 AM, Jason Blevins [EMAIL PROTECTED] wrote: I couldn't find any discussion of it on the list, but here's the changelog entry: 1.0.2b2 - 20 Mar 2005 + Experimental support for [this] as a synonym for [this][]. Interestingly, this a completely different use for single-bracketed text than I use and see on a daily basis. As I mentioned before, I see it more as a shortcut footnote type syntax for links only when text is expected to be read in plain text format. Thats a good point--I wasn't making the distinction before. Using numbers in brackets like so [1] is definitely a common notation for footnotes. I use it myself in emails but I didn't make the connection. It's also common for math and engineering journals to use that notation for references. Just to be clear, I'm not at all suggesting that markdown should adopt [1] at an alternate syntax for [^1]. I only ever use it for links in emails. I don't believe I said anything diferant than that, and no-one thus far seems to think I was, but I wanted to close that door before anyone opens it. Interestingly, that's how peg-markdown (with extensions via -x) renders footnotes. Instead of the link being a superscript '1', you get '[1]'. I actually like that better for the web I think. Superscripts are nice in print, but there you don't have to click on them. I have seen that before, and I have mixed feeling about it. It's a little easier to see them, but they also detract from reading the main text a little more than a superscript. Of course, they don't bother me in plain text emails, so it's no big deal. -- Waylan Limberg [EMAIL PROTECTED] ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: Link syntax (was: definition lists?)
Le 2008-11-21 à 11:36, Jason Blevins a écrit : On Babelmark Markdown.pl 1.0.2b8 honors this implicit reference syntax but 1.0.1 doesn't. I was aware of this syntax so my expected output is that of the beta version. I haven't used it myself though because I've often wondered how 'standard' it is. It looks like the majority of implementations do support it though. For PHP Markdown and PHP Markdown Extra, I've kept that syntax disabled on purpose, waiting for an non-beta release of Markdown.pl to make it official (at which point it'll be in the Markdown documentation). The problem is that Markdown.pl 1.0.2 doesn't seem like it'll go out of beta one day... -- Michel Fortin [EMAIL PROTECTED] http://michelf.com/ ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: Link syntax (was: definition lists?)
Le 2008-11-21 à 12:26, Jason Blevins a écrit : Superscripts are nice in print, but there you don't have to click on them. With a proper stylesheet you can make them as easy to click as anything else. Look at footnotes on Daring Fireball for instance: http://daringfireball.net/2008/11/google_mobile_uses_private_iphone_apis#fnr1-2008-11-19 The clickable region is big enough. -- Michel Fortin [EMAIL PROTECTED] http://michelf.com/ ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
definition lists?
Any way of writing definition lists? Andreas smime.p7s Description: S/MIME cryptographic signature ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: definition lists?
Andreas Åkre Solberg [EMAIL PROTECTED] 08-11-14 19.26 Any way of writing definition lists? Depends on which implementation you use. There are a few implementation that allows this. jem -- Jan Erik Moström - www.mostrom.pp.se ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
Re: definition lists?
It's in the works. We had a working solution last week, but then refactored the core this week, so I have to refactor the definition list stuff. If you want it right now, your free to checkout from the git repo [1] at commit e968bbf (on Nov 6), or wait a few more days for me to get the refactor done and have the latest and greatest. One thing is for sure, I will have something included in the next release which I anticipate happening soonish. [1]: http://gitorious.org/projects/python-markdown/repos/mainline On Fri, Nov 14, 2008 at 1:26 PM, Andreas Åkre Solberg [EMAIL PROTECTED] wrote: Any way of writing definition lists? Andreas ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss -- Waylan Limberg [EMAIL PROTECTED] ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss
definition lists
I haven't followed the discussion for a while but I seem to remember that there was a discussion of how definition list should look like. Has there been any decision of what syntax to use? (I don't actually need a script for doing the markdown = HTML conversion right now, but I would like to be able to write definitions lists) jem -- Jan Erik Moström, www.mostrom.pp.se ___ Markdown-Discuss mailing list Markdown-Discuss@six.pairlist.net http://six.pairlist.net/mailman/listinfo/markdown-discuss