diff options
author | Nicolas Goaziou <n.goaziou@gmail.com> | 2011-08-06 11:52:26 +0200 |
---|---|---|
committer | Nicolas Goaziou <n.goaziou@gmail.com> | 2011-08-06 11:56:14 +0200 |
commit | 1913f3f50c476f7aeb6129b7c0d340ed80e5d513 (patch) | |
tree | d30d594d4a1c4e1e9669de7d64d85778f194c830 | |
parent | 795b7c5ca0d6c4cc810c891e2ca783ba58bde658 (diff) | |
download | org-mode-1913f3f50c476f7aeb6129b7c0d340ed80e5d513.tar.gz |
org-footnote: allow inserting inlined footnotes at column 0
* lisp/org-footnote.el (org-footnote-new): only forbid non-inlined
footnotes at column 0, as only them can be confused with a footnote
definition.
-rw-r--r-- | lisp/org-footnote.el | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/lisp/org-footnote.el b/lisp/org-footnote.el index b566ef7..93b8829 100644 --- a/lisp/org-footnote.el +++ b/lisp/org-footnote.el @@ -422,7 +422,7 @@ This command prompts for a label. If this is a label referencing an existing label, only insert the label. If the footnote label is empty or new, let the user edit the definition of the footnote." (interactive) - (unless (and (not (bolp)) (org-footnote-in-valid-context-p)) + (unless (org-footnote-in-valid-context-p) (error "Cannot insert a footnote here")) (let* ((lbls (and (not (equal org-footnote-auto-label 'random)) (org-footnote-all-labels))) @@ -441,6 +441,8 @@ or new, let the user edit the definition of the footnote." (mapcar 'list lbls) nil nil (if (eq org-footnote-auto-label 'confirm) propose nil))))))) (cond + ((and label (bolp) (not org-footnote-define-inline)) + (error "Cannot create a non-inlined footnote at left margin")) ((not label) (insert "[fn:: ]") (backward-char 1)) |