Created
November 4, 2009 09:23
-
-
Save kawaguchi/225908 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
;; cucumber | |
;; http://github.com/michaelklishin/cucumber.el | |
;; 日本語でも色つける | |
(require 'feature-mode) | |
(defconst feature-mode-ja-keywords | |
'("フィーチャ" "機能" "背景" "シナリオ" "シナリオアウトライン" | |
"シナリオテンプレート" "テンプレ" "シナリオテンプレ" | |
"例" "サンプル" "前提" "もし" "ならば" "かつ" "しかし" "但し" "ただし")) | |
(defconst feature-font-lock-ja-keywords | |
(list | |
'("^ *\\(?:フィーチャ\\|機能\\):" (0 font-lock-keyword-face) (".*" nil nil (0 font-lock-type-face t))) | |
'("^ *背景:$" (0 font-lock-keyword-face)) | |
'("^ *\\(?:テンプレ\\|\\(?:シナリオ\\(?:アウトライン\\|テンプレート\\|テンプレ\\)?\\)\\):" (0 font-lock-keyword-face) (".*" nil nil (0 font-lock-function-name-face t))) | |
'("^ *前提" . font-lock-keyword-face) | |
'("^ *もし" . font-lock-keyword-face) | |
'("^ *ならば" . font-lock-keyword-face) | |
'("^ *\\(?:しかし\\|但し\\|ただし\\)" . font-lock-keyword-face) | |
'("^ *かつ" . font-lock-keyword-face) | |
'("^ *\\(?:他の\\)?サンプル:" . font-lock-keyword-face))) | |
(setq feature-mode-keywords | |
(append feature-mode-keywords feature-mode-ja-keywords)) | |
(setq feature-font-lock-keywords | |
(append feature-font-lock-keywords feature-font-lock-ja-keywords)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment