From 14c897972c3f626b0688cea5fc1f6a3012a5a029 Mon Sep 17 00:00:00 2001 From: Ryan Griffith Date: Mon, 29 Apr 2013 16:53:05 -0400 Subject: [PATCH] Fixed regex for keyword.operator to include <. Adjusted regex for meta.tag due to issue where any < sign is treated as a meta.tag, including conditionals within Velocity. --- lib/ace/mode/velocity_highlight_rules.js | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lib/ace/mode/velocity_highlight_rules.js b/lib/ace/mode/velocity_highlight_rules.js index c675ba7c..b0a6201a 100644 --- a/lib/ace/mode/velocity_highlight_rules.js +++ b/lib/ace/mode/velocity_highlight_rules.js @@ -54,7 +54,7 @@ var VelocityHighlightRules = function() { next : "style" }, { token : "meta.tag", // opening tag - regex : "<\\/?", + regex : "<\\/?(?:[a-z])", next : "tag" }, { token : "comment", @@ -182,7 +182,7 @@ var VelocityHighlightRules = function() { regex : "[a-zA-Z_$][a-zA-Z0-9_$]*\\b" }, { token : "keyword.operator", - regex : "!|&|\\*|\\-|\\+|=|!=|<=|>=<|>|&&|\\|\\|" + regex : "!|&|\\*|\\-|\\+|=|!=|<=|>=|<|>|&&|\\|\\|" }, { token : "lparen", regex : "[[({]"