[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[nongnu] elpa/jade-mode 109b9850d2 041/128: Created a syntax table for S
From: |
ELPA Syncer |
Subject: |
[nongnu] elpa/jade-mode 109b9850d2 041/128: Created a syntax table for Stylus mode. |
Date: |
Sat, 29 Jan 2022 08:24:45 -0500 (EST) |
branch: elpa/jade-mode
commit 109b9850d2d0ea9f3065b7cf1ad8e962d8542f12
Author: Jaakko Pallari <jkpl@lepovirta.org>
Commit: Jaakko Pallari <jkpl@lepovirta.org>
Created a syntax table for Stylus mode.
Also, threw away kill-all-local-variables. I don't see any point in
having it.
---
stylus-mode.el | 15 +++++++++++----
1 file changed, 11 insertions(+), 4 deletions(-)
diff --git a/stylus-mode.el b/stylus-mode.el
index 87ae474003..63eef0b6d0 100644
--- a/stylus-mode.el
+++ b/stylus-mode.el
@@ -52,6 +52,14 @@
(,"$\\w+" 0 font-lock-variable-name-face)
))
+(defvar stylus-syntax-table
+ (let ((syntable (make-syntax-table)))
+ (modify-syntax-entry ?\/ ". 124b" syntable)
+ (modify-syntax-entry ?* ". 23" syntable)
+ (modify-syntax-entry ?\n "> b" syntable)
+ syntable)
+ "Syntax table for `stylus-mode'.")
+
(defun stylus-region-for-sexp ()
"Selects the current sexp as the region"
(interactive)
@@ -71,19 +79,18 @@
(define-derived-mode stylus-mode sws-mode
"Stylus"
"Major mode for editing stylus node.js templates"
- (kill-all-local-variables)
(setq tab-width 2)
(setq mode-name "Stylus")
(setq major-mode 'stylus-mode)
+ ;; syntax table
+ (set-syntax-table stylus-syntax-table)
+
;; highlight syntax
(setq font-lock-defaults '(stylus-font-lock-keywords))
;; comments
- (modify-syntax-entry ?\/ ". 124b")
- (modify-syntax-entry ?* ". 23")
- (modify-syntax-entry ?\n "> b")
(set (make-local-variable 'comment-start) "//")
(set (make-local-variable 'comment-end) "")
- [nongnu] elpa/jade-mode 932a2fef33 095/128: [#46] start unit test file for highlighting, (continued)
- [nongnu] elpa/jade-mode 932a2fef33 095/128: [#46] start unit test file for highlighting, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 473d29b5c2 091/128: move doctype in rendering order, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 8a25dd6702 024/128: Merge pull request #4 from travisjeffery/master, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 41351ec293 027/128: Add autoload declarations, explicit requires and ELPA package dependencies., ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode c513eded33 045/128: the string doctype now works as a doctype keyword., ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode a1cbadd84d 026/128: add .el file headers to enable automatic packaging - closes gh#6, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 4d2f58abd7 044/128: Merge https://github.com/brianc/jade-mode, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 62c012c8d6 039/128: Improved Stylus comments syntax highlighting., ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 00c789673f 068/128: Closes #26. Fix inline '//' highlight as comment, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 8f61e0dc6a 040/128: Decimal point can be part of a constant., ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 109b9850d2 041/128: Created a syntax table for Stylus mode.,
ELPA Syncer <=
- [nongnu] elpa/jade-mode f540df5ee6 056/128: Merge pull request #16 from tardyp/master, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 275ab149ed 051/128: Merge pull request #11 from jkpl/master, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode d90ad2cc02 036/128: Add syntax table entry for single line comment., ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 05d671fcdb 057/128: Add comment syntax to allow for M-x (un)comment-region., ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 351f756569 083/128: [#37] Highlight string lit. manually - Closes #37, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode a90b512c6e 086/128: [#39] add two functions to hl JS blocks, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 57ab4d6555 085/128: [#39] add JS examples to highlight, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode bbaf2bb3a1 092/128: add a THIRD comment type and use THAT ad default, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 4336ae9cc4 097/128: [#46] ignore .elc files, ELPA Syncer, 2022/01/29
- [nongnu] elpa/jade-mode 42bb8501b4 099/128: fix some compile warnings and sexp-region, ELPA Syncer, 2022/01/29