org.el: Fix bug about filling message headers and citations
* org.el (org-fill-paragraph): Make a command. Fix bug about filling message headers and citations.
This commit is contained in:
parent
525e96a97e
commit
396e413f6b
|
@ -20830,7 +20830,7 @@ hierarchy of headlines by UP levels before marking the subtree."
|
||||||
(org-move-to-column column)
|
(org-move-to-column column)
|
||||||
(when (and orgstruct-is-++ (eq pos (point)))
|
(when (and orgstruct-is-++ (eq pos (point)))
|
||||||
(org-let org-fb-vars
|
(org-let org-fb-vars
|
||||||
'(indent-according-to-mode)))))
|
(indent-according-to-mode)))))
|
||||||
|
|
||||||
(defun org-indent-drawer ()
|
(defun org-indent-drawer ()
|
||||||
"Indent the drawer at point."
|
"Indent the drawer at point."
|
||||||
|
@ -20983,11 +20983,15 @@ width for filling.
|
||||||
For convenience, when point is at a plain list, an item or
|
For convenience, when point is at a plain list, an item or
|
||||||
a footnote definition, try to fill the first paragraph within."
|
a footnote definition, try to fill the first paragraph within."
|
||||||
;; Falls back on message-fill-paragraph when necessary
|
;; Falls back on message-fill-paragraph when necessary
|
||||||
|
(interactive)
|
||||||
(if (and (derived-mode-p 'message-mode)
|
(if (and (derived-mode-p 'message-mode)
|
||||||
(or (not (message-in-body-p))
|
(or (not (message-in-body-p))
|
||||||
(save-excursion (move-beginning-of-line 1)
|
(save-excursion (move-beginning-of-line 1)
|
||||||
(looking-at "> "))))
|
(looking-at "> "))))
|
||||||
(message-fill-paragraph)
|
(org-let org-fb-vars
|
||||||
|
(or (and (message-point-in-header-p) (message-fill-field))
|
||||||
|
(and (save-excursion (move-beginning-of-line 1) (looking-at "> "))
|
||||||
|
(fill-comment-paragraph))))
|
||||||
(save-excursion
|
(save-excursion
|
||||||
;; Move to end of line in order to get the first paragraph within
|
;; Move to end of line in order to get the first paragraph within
|
||||||
;; a plain list or a footnote definition.
|
;; a plain list or a footnote definition.
|
||||||
|
|
Loading…
Reference in New Issue