diff options
author | marty hiatt <martianhiatus [a t] riseup [d o t] net> | 2022-11-17 09:49:46 +0100 |
---|---|---|
committer | marty hiatt <martianhiatus [a t] riseup [d o t] net> | 2022-11-17 09:50:40 +0100 |
commit | 302f4828703313057823dfcc39d01ae00eb21e86 (patch) | |
tree | 6ddcea6943a4540a396034b99c62930997087976 /lisp | |
parent | 1100d49cdd111de00bbd58292c30a2707a7dfb99 (diff) |
prop tags/handles - tweak regex for spacing
Diffstat (limited to 'lisp')
-rw-r--r-- | lisp/mastodon-toot.el | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/lisp/mastodon-toot.el b/lisp/mastodon-toot.el index 438e887..3c4c7aa 100644 --- a/lisp/mastodon-toot.el +++ b/lisp/mastodon-toot.el @@ -1262,10 +1262,10 @@ Added to `after-change-functions'." ;; stops all text after a handle or mention being propertized: (set-text-properties (cdr header-region) (point-max) nil) ;; TODO: confirm allowed hashtag/handle characters: - (mastodon-toot--propertize-item "[\n\t ]\\(?2:#[1-9a-zA-Z_]+\\)[\n\t ]" + (mastodon-toot--propertize-item "\\([\n\t ]\\|^\\)\\(?2:#[1-9a-zA-Z_]+\\)\\b" 'success (cdr header-region)) - (mastodon-toot--propertize-item "[\n\t ]\\(?2:@[1-9a-zA-Z._-]+\\)[\n\t ]" + (mastodon-toot--propertize-item "\\([\n\t ]\\|^\\)\\(?2:@[1-9a-zA-Z._-]+\\)\\b" 'mastodon-display-name-face (cdr header-region))))) |