From eaa8ccaccb1091820d0a8d1223996a6dd057347d Mon Sep 17 00:00:00 2001
From: Wu Cheng-Han
Date: Sun, 17 Jan 2016 14:28:04 -0600
Subject: Upgrade CodeMirror to 5.10.1 and now support fullscreen, jump-to-line
in editor
---
public/vendor/codemirror/mode/vhdl/index.html | 95 +++++++++++++
public/vendor/codemirror/mode/vhdl/vhdl.js | 189 ++++++++++++++++++++++++++
2 files changed, 284 insertions(+)
create mode 100644 public/vendor/codemirror/mode/vhdl/index.html
create mode 100644 public/vendor/codemirror/mode/vhdl/vhdl.js
(limited to 'public/vendor/codemirror/mode/vhdl')
diff --git a/public/vendor/codemirror/mode/vhdl/index.html b/public/vendor/codemirror/mode/vhdl/index.html
new file mode 100644
index 00000000..3051bc37
--- /dev/null
+++ b/public/vendor/codemirror/mode/vhdl/index.html
@@ -0,0 +1,95 @@
+
+
+
CodeMirror: VHDL mode
+
+
+
+
+
+
+
+
+
+
+
+VHDL mode
+
+
+
+
+
+
+Syntax highlighting and indentation for the VHDL language.
+
Configuration options:
+
+ - atoms - List of atom words. Default: "null"
+ - hooks - List of meta hooks. Default: ["`", "$"]
+ - multiLineStrings - Whether multi-line strings are accepted. Default: false
+
+
+
+MIME types defined: text/x-vhdl
.
+
diff --git a/public/vendor/codemirror/mode/vhdl/vhdl.js b/public/vendor/codemirror/mode/vhdl/vhdl.js
new file mode 100644
index 00000000..d3b555aa
--- /dev/null
+++ b/public/vendor/codemirror/mode/vhdl/vhdl.js
@@ -0,0 +1,189 @@
+// CodeMirror, copyright (c) by Marijn Haverbeke and others
+// Distributed under an MIT license: http://codemirror.net/LICENSE
+
+// Originally written by Alf Nielsen, re-written by Michael Zhou
+(function(mod) {
+ if (typeof exports == "object" && typeof module == "object") // CommonJS
+ mod(require("../../lib/codemirror"));
+ else if (typeof define == "function" && define.amd) // AMD
+ define(["../../lib/codemirror"], mod);
+ else // Plain browser env
+ mod(CodeMirror);
+})(function(CodeMirror) {
+"use strict";
+
+function words(str) {
+ var obj = {}, words = str.split(",");
+ for (var i = 0; i < words.length; ++i) {
+ var allCaps = words[i].toUpperCase();
+ var firstCap = words[i].charAt(0).toUpperCase() + words[i].slice(1);
+ obj[words[i]] = true;
+ obj[allCaps] = true;
+ obj[firstCap] = true;
+ }
+ return obj;
+}
+
+function metaHook(stream) {
+ stream.eatWhile(/[\w\$_]/);
+ return "meta";
+}
+
+CodeMirror.defineMode("vhdl", function(config, parserConfig) {
+ var indentUnit = config.indentUnit,
+ atoms = parserConfig.atoms || words("null"),
+ hooks = parserConfig.hooks || {"`": metaHook, "$": metaHook},
+ multiLineStrings = parserConfig.multiLineStrings;
+
+ var keywords = words("abs,access,after,alias,all,and,architecture,array,assert,attribute,begin,block," +
+ "body,buffer,bus,case,component,configuration,constant,disconnent,downto,else,elsif,end,end block,end case," +
+ "end component,end for,end generate,end if,end loop,end process,end record,end units,entity,exit,file,for," +
+ "function,generate,generic,generic map,group,guarded,if,impure,in,inertial,inout,is,label,library,linkage," +
+ "literal,loop,map,mod,nand,new,next,nor,null,of,on,open,or,others,out,package,package body,port,port map," +
+ "postponed,procedure,process,pure,range,record,register,reject,rem,report,return,rol,ror,select,severity,signal," +
+ "sla,sll,sra,srl,subtype,then,to,transport,type,unaffected,units,until,use,variable,wait,when,while,with,xnor,xor");
+
+ var blockKeywords = words("architecture,entity,begin,case,port,else,elsif,end,for,function,if");
+
+ var isOperatorChar = /[&|~>