mirror of https://github.com/djcb/mu.git
mu4e: handle foo> citation style
Handle the citation style where the cited part is prefixed with eg. "foo> " instead of the normal ">". Also improve the default color scheme a bit.
This commit is contained in:
parent
fc3b9c19da
commit
1945ab3bce
|
@ -1216,7 +1216,7 @@ used in the view and compose modes."
|
|||
(when (search-forward-regexp "^\n" nil t) ;; search the first empty line
|
||||
(while (re-search-forward mu4e-cited-regexp nil t)
|
||||
(let* ((level (string-width (replace-regexp-in-string
|
||||
" " "" (match-string 1))))
|
||||
"[^>]" "" (match-string 0))))
|
||||
(face (unless (zerop level)
|
||||
(intern-soft (format "mu4e-cited-%d-face" level)))))
|
||||
(when face
|
||||
|
|
|
@ -207,8 +207,10 @@ view buffer."
|
|||
:type 'boolean
|
||||
:group 'mu4e)
|
||||
|
||||
(defcustom mu4e-cited-regexp "^ *\\(\\(>+ ?\\)+\\)"
|
||||
"Regular expression that determines whether a line is a citation."
|
||||
(defcustom mu4e-cited-regexp "^\\(\\([[:alpha:]]+\\)\\|\\( *\\)\\)\\(\\(>+ ?\\)+\\)"
|
||||
"Regular expression that determines whether a line is a
|
||||
citation. This recognizes lines starting with numbers of '>'
|
||||
and spaces as well as citations of the type \"John> ... \"."
|
||||
:type 'string
|
||||
:group 'mu4e)
|
||||
|
||||
|
@ -564,7 +566,7 @@ I.e. a message with the draft flag set."
|
|||
:group 'mu4e-faces)
|
||||
|
||||
(defface mu4e-cited-2-face
|
||||
'((t :inherit font-lock-type-face :bold nil :italic t))
|
||||
'((t :inherit font-lock-preprocessor-face :bold nil :italic t))
|
||||
"Face for cited message parts (level 2)."
|
||||
:group 'mu4e-faces)
|
||||
|
||||
|
@ -589,7 +591,7 @@ I.e. a message with the draft flag set."
|
|||
:group 'mu4e-faces)
|
||||
|
||||
(defface mu4e-cited-7-face
|
||||
'((t :inherit font-lock-preprocessor-face :bold nil :italic t))
|
||||
'((t :inherit font-lock-type-face :bold nil :italic t))
|
||||
"Face for cited message parts (level 7)."
|
||||
:group 'mu4e-faces)
|
||||
|
||||
|
|
Loading…
Reference in New Issue