From: Dave P. <dav...@gm...> - 2014-09-08 13:20:33
|
Given input * a *a1 * a *b *b1 I.e. two lists, each having nested children, the output needs 'something' (a para or hr etc) between the two lists, or the html output appears to put p elements inside the 'outer' li elements. Is this just my processing chain or a know 'feature' please? Dave -- Dave Pawson XSLT XSL-FO FAQ. Docbook FAQ. http://www.dpawson.co.uk |
From: Waylan L. <way...@ic...> - 2014-09-09 01:30:31
|
This is definitely not a bug. For some reason newcomers to markdown always try to add extra blank lines to break a list/codeblock/blockquote into two separate blocks. There is simply nothing in the syntax [rules] to support that however. And in fact, the original implementation (markdown.pl) does not support such a concept. This is simply a fact of how Markdown works. Extra blank lines (more than one) have no implied meaning Once you get used to the idea it becomes easy enough to work with. Some people have been known to use HTML comments to get around this. Remember raw HTML is passed through as is. And an HTML comment does not get displayed in the browser. If you want to break one list into two with nothing between, insert a raw HTML comment between them. And as you seem to be confused about why the `<p>` tags are introduced, reread the section of the rules on [lists]. Particularly the part that starts with this line: > If list items are separated by blank lines, Markdown will wrap the items in `<p>` tags in the HTML output. [rules]: http://daringfireball.net/projects/markdown/syntax [lists]: http://daringfireball.net/projects/markdown/syntax#list Waylan Limberg -----Original Message----- From: Dave Pawson [mailto:dav...@gm...] Sent: Monday, September 08, 2014 9:20 AM To: PythonMD list Subject: [Python-markdown-discuss] nested list termination Given input * a *a1 * a *b *b1 I.e. two lists, each having nested children, the output needs 'something' (a para or hr etc) between the two lists, or the html output appears to put p elements inside the 'outer' li elements. Is this just my processing chain or a know 'feature' please? Dave -- Dave Pawson XSLT XSL-FO FAQ. Docbook FAQ. http://www.dpawson.co.uk ---------------------------------------------------------------------------- -- Want excitement? Manually upgrade your production database. When you want reliability, choose Perforce Perforce version control. Predictably reliable. http://pubads.g.doubleclick.net/gampad/clk?id=157508191&iu=/4140/ostg.clktrk _______________________________________________ Python-markdown-discuss mailing list Pyt...@li... https://lists.sourceforge.net/lists/listinfo/python-markdown-discuss |
From: Dave P. <dav...@gm...> - 2014-09-09 06:32:35
|
On 9 September 2014 02:30, Waylan Limberg <way...@ic...> wrote: > This is definitely not a bug. For some reason newcomers to markdown always > try to add extra blank lines to break a list/codeblock/blockquote into two > separate blocks. There is simply nothing in the syntax [rules] to support > that however. And in fact, the original implementation (markdown.pl) does > not support such a concept. This is simply a fact of how Markdown works. So the intention is to copy markdown.pl, bugs and all? > Extra blank lines (more than one) have no implied meaning Once you get used > to the idea it becomes easy enough to work with. a problem to address with a kludge? > > Some people have been known to use HTML comments to get around this. > Remember raw HTML is passed through as is. And an HTML comment does not get > displayed in the browser. If you want to break one list into two with > nothing between, insert a raw HTML comment between them. One kludge. > > And as you seem to be confused about why the `<p>` tags are introduced, > reread the section of the rules on [lists]. Particularly the part that > starts with this line: > >> If list items are separated by blank lines, Markdown will wrap the items > in `<p>` tags in the HTML output. Which to me seems quite illogical. regards -- Dave Pawson XSLT XSL-FO FAQ. Docbook FAQ. http://www.dpawson.co.uk |
From: Waylan L. <way...@ic...> - 2014-09-09 12:28:59
|
Oh, I never said it was logical. But is is not considered a bug. When I said "Extra blank lines (more than one) have no implied meaning" I really meant it. This is a consistent concept throughout Markdown that any expert knows and understands. I, like you, may not agree with the decision made by Markdown's creator, but if I changed the behavior, then it wouldn't be Markdown any more. In fact some people recently tried to make an implementation that made this (among a few other) changes, and they were very clearly informed that what they created could not be called Markdown. Consider the [sane lists] extension. The correct behavior in true Markdown is so illogical to so many people that we created an extension that offers a different behavior. That said, this extension does not -- and will not -- ever adopt your suggestion. As I said, "Extra blank lines (more than one) have no implied meaning". Waylan Limberg [sane lists]: https://pythonhosted.org/Markdown/extensions/sane_lists.html > On Sep 9, 2014, at 2:32 AM, Dave Pawson <dav...@gm...> wrote: > >> On 9 September 2014 02:30, Waylan Limberg <way...@ic...> wrote: >> This is definitely not a bug. For some reason newcomers to markdown always >> try to add extra blank lines to break a list/codeblock/blockquote into two >> separate blocks. There is simply nothing in the syntax [rules] to support >> that however. And in fact, the original implementation (markdown.pl) does >> not support such a concept. This is simply a fact of how Markdown works. > > So the intention is to copy markdown.pl, bugs and all? > > >> Extra blank lines (more than one) have no implied meaning Once you get used >> to the idea it becomes easy enough to work with. > > a problem to address with a kludge? > >> >> Some people have been known to use HTML comments to get around this. >> Remember raw HTML is passed through as is. And an HTML comment does not get >> displayed in the browser. If you want to break one list into two with >> nothing between, insert a raw HTML comment between them. > > One kludge. > >> >> And as you seem to be confused about why the `<p>` tags are introduced, >> reread the section of the rules on [lists]. Particularly the part that >> starts with this line: >> >>> If list items are separated by blank lines, Markdown will wrap the items >> in `<p>` tags in the HTML output. > > Which to me seems quite illogical. > > > regards > > > -- > Dave Pawson > XSLT XSL-FO FAQ. > Docbook FAQ. > http://www.dpawson.co.uk |
From: Dave P. <dav...@gm...> - 2014-09-09 16:10:34
|
On 9 September 2014 13:28, Waylan Limberg <way...@ic...> wrote: > Consider the [sane lists] extension. The correct behavior in true Markdown is so illogical to so many people that we created an extension that offers a different behavior. That said, this extension does not -- and will not -- ever adopt your suggestion. As I said, "Extra blank lines (more than one) have no implied meaning". According to Gruber. He has a lot to answer for. sane lists it is then. Just select the option and they take precedence, is that it please? regards -- Dave Pawson XSLT XSL-FO FAQ. Docbook FAQ. http://www.dpawson.co.uk |