mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-09-29 23:17:49 +00:00
Merge branch 'maint'
This commit is contained in:
commit
69a91ba8bc
|
@ -411,7 +411,7 @@ follows a #+DATE:, #+AUTHOR: or #+EMAIL: keyword."
|
||||||
(defface org-block `((t :inherit shadow
|
(defface org-block `((t :inherit shadow
|
||||||
,@(and (>= emacs-major-version 27) '(:extend t))))
|
,@(and (>= emacs-major-version 27) '(:extend t))))
|
||||||
"Face text in #+begin ... #+end blocks.
|
"Face text in #+begin ... #+end blocks.
|
||||||
For source-blocks `org-src-block-faces' takes precedence."
|
For source-blocks, `org-src-block-faces' takes precedence."
|
||||||
:group 'org-faces
|
:group 'org-faces
|
||||||
:version "26.1")
|
:version "26.1")
|
||||||
|
|
||||||
|
|
15
lisp/org.el
15
lisp/org.el
|
@ -5231,9 +5231,9 @@ by a #."
|
||||||
limit t)
|
limit t)
|
||||||
(let ((beg (match-beginning 0))
|
(let ((beg (match-beginning 0))
|
||||||
(end-of-beginline (match-end 0))
|
(end-of-beginline (match-end 0))
|
||||||
(block-start (match-end 0)) ; includes the \n at end of #+begin line
|
(block-start (match-end 0)) ; Includes the \n at end of #+begin line
|
||||||
(block-end nil) ; will include \n after end of block content
|
(block-end nil) ; will include \n after end of block content
|
||||||
(lang (match-string 7)) ; the language, if it is an src block
|
(lang (match-string 7)) ; the language, if it is an src block.
|
||||||
(bol-after-beginline (line-beginning-position 2))
|
(bol-after-beginline (line-beginning-position 2))
|
||||||
(dc1 (downcase (match-string 2)))
|
(dc1 (downcase (match-string 2)))
|
||||||
(dc3 (downcase (match-string 3)))
|
(dc3 (downcase (match-string 3)))
|
||||||
|
@ -5251,12 +5251,12 @@ by a #."
|
||||||
,(match-string 4)
|
,(match-string 4)
|
||||||
word-end
|
word-end
|
||||||
(zero-or-more any)))))
|
(zero-or-more any)))))
|
||||||
nil t) ;; on purpose, we look further than LIMIT
|
nil t) ; On purpose, we look further than LIMIT.
|
||||||
;; We do have a matching #+end line
|
;; We do have a matching #+end line.
|
||||||
(setq beg-of-endline (match-beginning 0)
|
(setq beg-of-endline (match-beginning 0)
|
||||||
end-of-endline (match-end 0)
|
end-of-endline (match-end 0)
|
||||||
nl-before-endline (1- (match-beginning 0)))
|
nl-before-endline (1- (match-beginning 0)))
|
||||||
(setq block-end (match-beginning 0)) ; includes the final newline.
|
(setq block-end (match-beginning 0)) ; Includes the final newline.
|
||||||
(when quoting
|
(when quoting
|
||||||
(org-remove-flyspell-overlays-in bol-after-beginline nl-before-endline)
|
(org-remove-flyspell-overlays-in bol-after-beginline nl-before-endline)
|
||||||
(remove-text-properties beg end-of-endline
|
(remove-text-properties beg end-of-endline
|
||||||
|
@ -5285,7 +5285,10 @@ by a #."
|
||||||
((string= block-type "verse")
|
((string= block-type "verse")
|
||||||
(add-face-text-property
|
(add-face-text-property
|
||||||
bol-after-beginline beg-of-endline 'org-verse t)))
|
bol-after-beginline beg-of-endline 'org-verse t)))
|
||||||
;; Fontify the #+begin and #+end lines of the blocks
|
;; Use the org-block face for all true blocks.
|
||||||
|
(add-text-properties
|
||||||
|
bol-after-beginline beg-of-endline (list 'face 'org-block))
|
||||||
|
;; Fontify the #+begin and #+end lines of the blocks.
|
||||||
(add-text-properties
|
(add-text-properties
|
||||||
beg (if whole-blockline bol-after-beginline end-of-beginline)
|
beg (if whole-blockline bol-after-beginline end-of-beginline)
|
||||||
'(face org-block-begin-line))
|
'(face org-block-begin-line))
|
||||||
|
|
Loading…
Reference in a new issue