All indented lines starting with "#+" to be comments

This commit is contained in:
Carsten Dominik 2009-09-24 10:27:30 +01:00
parent c950e4b3ac
commit 6867751efe
3 changed files with 10 additions and 2 deletions

View File

@ -8471,7 +8471,8 @@ exported as a horizontal line (@samp{<hr/>} in HTML).
@cindex #+BEGIN_COMMENT
Lines starting with @samp{#} in column zero are treated as comments and will
never be exported. Also entire subtrees starting with the word
never be exported. If you want an indented line to be treated as a comment,
start it with @samp{#+ }. Also entire subtrees starting with the word
@samp{COMMENT} will never be exported. Finally, regions surrounded by
@samp{#+BEGIN_COMMENT} ... @samp{#+END_COMMENT} will not be exported.

View File

@ -1,5 +1,8 @@
2009-09-24 Carsten Dominik <carsten.dominik@gmail.com>
* org.el (org-fontify-meta-lines-and-blocks): Treat lines with a
space after #+ as comments.
* org-latex.el (org-export-latex-emph-format): Use better commands
to insert special characters in verbatim snippets.

View File

@ -4334,7 +4334,7 @@ will be prompted for."
"Fontify #+ lines and blocks, in the correct ways."
(let ((case-fold-search t))
(if (re-search-forward
"^\\([ \t]*#\\+\\(\\([a-zA-Z]+:?\\)\\(_\\([a-zA-Z]+\\)\\)?\\)\\(.*\\)\\)"
"^\\([ \t]*#\\+\\(\\([a-zA-Z]+:?\\| \\|$\\)\\(_\\([a-zA-Z]+\\)\\)?\\)\\(.*\\)\\)"
limit t)
(let ((beg (match-beginning 0))
(beg1 (line-beginning-position 2))
@ -4384,6 +4384,10 @@ will be prompted for."
beg (match-end 0)
'(font-lock-fontified t face org-meta-line))
t)
((member dc3 '(" " ""))
(add-text-properties
beg (match-end 0)
'(font-lock-fontified t face font-lock-comment-face)))
(t nil))))))
(defun org-activate-angle-links (limit)