forked from mirrors/org-mode
HTML export: Do not allow protected lines into the TOC
Daniel Clemente writesL > Hi, I found an HTML export bug with org-mode 6.34c-140-g44c8 and > older. I used: > > -------------------------------------------------------- > * only one section > #+BEGIN_EXAMPLE: > > We need: > ,* pears > ,* lettuce > ,* watermelons > > Very important! > #+END_EXAMPLE: > -------------------------------------------------------- > > And the outputed table of contents had this code: > > -------------------------------------------------------- > <div id="text-table-of-contents"> > <ul> > <li><a href="#sec-1">1 only one section </a></li> > <li><a href="#sec-2">2 pears</a></li> > <li><a href="#sec-3">3 lettuce</a></li> > <li><a href="#sec-4">4 watermelons</a></li> > </ul> > </div> > -------------------------------------------------------- > > This is wrong because the asterisks inside the example don't > represent headers. There should be only one header.
This commit is contained in:
parent
7a9a998c01
commit
cff060f3ac
|
@ -1,5 +1,8 @@
|
|||
2010-03-03 Carsten Dominik <carsten.dominik@gmail.com>
|
||||
|
||||
* org-html.el (org-export-as-html): Do not allow protected lines
|
||||
into the table of contents.
|
||||
|
||||
* org-latex.el (org-export-latex-special-chars): Find subsequent
|
||||
occurrences of special characters.
|
||||
(org-export-latex-tables): Do not convert table-like stuff that is
|
||||
|
|
|
@ -809,7 +809,8 @@ lang=\"%s\" xml:lang=\"%s\">
|
|||
(push "<ul>\n<li>" thetoc)
|
||||
(setq lines
|
||||
(mapcar '(lambda (line)
|
||||
(if (string-match org-todo-line-regexp line)
|
||||
(if (and (string-match org-todo-line-regexp line)
|
||||
(not (get-text-property 0 'org-protected line)))
|
||||
;; This is a headline
|
||||
(progn
|
||||
(setq have-headings t)
|
||||
|
|
Loading…
Reference in New Issue