Browse Source

first commit after a long while

master
chris 3 months ago
parent
commit
997b373ece
  1. 50
      tiddler-mode.el

50
tiddler-mode.el

@ -102,31 +102,31 @@ @@ -102,31 +102,31 @@
;; TODO
;; is it possible to replace <<< , ```, etc like what happens in markdown-mode?
(setq tiddlermode-highlights '(
;("code:hide\\(.\\|\n\\)*?code:end" . (0 font-lock-comment-face t))
("''.*?''" . (0 strong-bold t))
("\\[\\[.*?\\]\\]" . (0 wikilink t))
("http.*?\s" . (0 wikilink t))
;("https:.*?\n" . (0 wikilink t))
;("^\\[.*?\\]\\]?" . (0 sub-title t))
("`.*?`" . (0 tiddler-code t))
;; code blocks, including new lines
;; https://stackoverflow.com/questions/320590/regexps-in-elisp-to-include-newlines
( "\\(\`\\{3\\}\\(.*\n?\\)*?\`\\{3\\}\\)" . (0 tiddler-code t))
( "\\(<\\{3\\}\\(.*\n?\\)*?<\\{3\\}\\)" . (0 tiddler-quoteblock t))
;("\*.*?" . (0 code t))
("!.*?\n" . (0 tiddler-highlight t))
;; frontmatter
("^created:.*$" . (0 tiddler-comment t))
("^modified:.*$" . (0 tiddler-comment t))
("^rating:.*$" . (0 tiddler-comment t))
("^tags:.*$" . (0 tiddler-comment t))
("^leaf_collected:.*$" . (0 tiddler-comment t))
("^latinname:.*$" . (0 tiddler-comment t))
("^source:.*$" . (0 tiddler-comment t))
("^source:.*$" . (0 tiddler-comment t))
("^title:.*$" . (0 tiddler-title t))
("^type:.*$" . (0 tiddler-comment t))
)
;("code:hide\\(.\\|\n\\)*?code:end" . (0 font-lock-comment-face t))
("''.*?''" . (0 strong-bold t))
("\\[\\[.*?\\]\\]" . (0 wikilink t))
("http.*?\s" . (0 wikilink t))
;("https:.*?\n" . (0 wikilink t))
;("^\\[.*?\\]\\]?" . (0 sub-title t))
("`.*?`" . (0 tiddler-code t))
;; code blocks, including new lines
;; https://stackoverflow.com/questions/320590/regexps-in-elisp-to-include-newlines
( "\\(\`\\{3\\}\\(.*\n?\\)*?\`\\{3\\}\\)" . (0 tiddler-code t))
( "\\(<\\{3\\}\\(.*\n?\\)*?<\\{3\\}\\)" . (0 tiddler-quoteblock t))
;("\*.*?" . (0 code t))
("!.*?\n" . (0 tiddler-highlight t))
;; frontmatter
("^created:.*$" . (0 tiddler-comment t))
("^modified:.*$" . (0 tiddler-comment t))
("^rating:.*$" . (0 tiddler-comment t))
("^tags:.*$" . (0 tiddler-comment t))
("^leaf_collected:.*$" . (0 tiddler-comment t))
("^latinname:.*$" . (0 tiddler-comment t))
("^source:.*$" . (0 tiddler-comment t))
("^source:.*$" . (0 tiddler-comment t))
("^title:.*$" . (0 tiddler-title t))
("^type:.*$" . (0 tiddler-comment t))
)
)
(setq font-lock-defaults '(tiddlermode-highlights))
(message "deriving mode tiddlermode")

Loading…
Cancel
Save