function HtmlGrammar() {
		return {
			"scopeName": "source.html",
			"uuid": "3B5C76FB-EBB5-D930-F40C-047D082CE99B",
			"patterns": [
				{
					"begin": "<!(doctype|DOCTYPE)",
					"end": ">",
					"contentName": "entity.name.tag.doctype.html",
					"beginCaptures": {
						"0": { "name": "entity.name.tag.doctype.html" }
					},
					"endCaptures": {
						"0": { "name": "entity.name.tag.doctype.html" }
					}
				},
				{
					"begin": "<!--",
					"end": "-->",
					"beginCaptures": {
						"0": { "name": "punctuation.definition.comment.html" }
					},
					"endCaptures": {
						"0": { "name": "punctuation.definition.comment.html" }
					},
					"patterns": [
						{
							"match": "--",
							"name": "invalid.illegal.badcomment.html"
						}
					],
					"contentName": "comment.block.html"
				},
				{ // startDelimiter + tagName
					"match": "<[A-Za-z0-9_\\-:]+(?= ?)",
					"name": "entity.name.tag.html"
				},
				{ "include": "#attrName" },
				{ "include": "#qString" },
				{ "include": "#qqString" },
				{ "include": "#entity" },
				// TODO attrName, qString, qqString should be applied first while inside a tag
				{ // startDelimiter + slash + tagName + endDelimiter
					"match": "</[A-Za-z0-9_\\-:]+>",
					"name": "entity.name.tag.html"
				},
				{ // end delimiter of open tag
					"match": ">", 
					"name": "entity.name.tag.html"
				} ],
			"repository": {
				"attrName": { // attribute name
					"match": "[A-Za-z\\-:]+(?=\\s*=\\s*['\"])",
					"name": "entity.other.attribute.name.html"
				},
				"qqString": { // double quoted string
					"match": "(\")[^\"]+(\")",
					"name": "string.quoted.double.html"
				},
				"qString": { // single quoted string
					"match": "(')[^']+(\')",
					"name": "string.quoted.single.html"
				},
				"entity": {
					"match": "&[A-Za-z0-9]+;",
					"name": "constant.character.entity.html"
				}
			}
		};
	}
/**
	 * Provides a grammar that can do some very rough syntax highlighting for HTML.
	 * @class orion.syntax.HtmlGrammar
	 */
Provides a grammar that can do some very rough syntax highlighting for HTML.
Provides a grammar that can do some very rough syntax highlighting for HTML .
function HtmlGrammar() {
		return {
			"scopeName": "source.html",
			"uuid": "3B5C76FB-EBB5-D930-F40C-047D082CE99B",
			"patterns": [
				{
					"begin": "<!(doctype|DOCTYPE)",
					"end": ">",
					"contentName": "entity.name.tag.doctype.html",
					"beginCaptures": {
						"0": { "name": "entity.name.tag.doctype.html" }
					},
					"endCaptures": {
						"0": { "name": "entity.name.tag.doctype.html" }
					}
				},
				{
					"begin": "<!--",
					"end": "-->",
					"beginCaptures": {
						"0": { "name": "punctuation.definition.comment.html" }
					},
					"endCaptures": {
						"0": { "name": "punctuation.definition.comment.html" }
					},
					"patterns": [
						{
							"match": "--",
							"name": "invalid.illegal.badcomment.html"
						}
					],
					"contentName": "comment.block.html"
				},
				{ 
					"match": "<[A-Za-z0-9_\\-:]+(?= ?)",
					"name": "entity.name.tag.html"
				},
				{ "include": "#attrName" },
				{ "include": "#qString" },
				{ "include": "#qqString" },
				{ "include": "#entity" },
				{ 
					"match": "</[A-Za-z0-9_\\-:]+>",
					"name": "entity.name.tag.html"
				},
				{ 
					"match": ">", 
					"name": "entity.name.tag.html"
				} ],
			"repository": {
				"attrName": { 
					"match": "[A-Za-z\\-:]+(?=\\s*=\\s*['\"])",
					"name": "entity.other.attribute.name.html"
				},
				"qqString": { 
					"match": "(\")[^\"]+(\")",
					"name": "string.quoted.double.html"
				},
				"qString": { 
					"match": "(')[^']+(\')",
					"name": "string.quoted.single.html"
				},
				"entity": {
					"match": "&[A-Za-z0-9]+;",
					"name": "constant.character.entity.html"
				}
			}
		};
	}
function HtmlGrammar ( ) { return { "scopeName" : "source.html" , "uuid" : "3B5C76FB-EBB5-D930-F40C-047D082CE99B" , "patterns" : [ { "begin" : "<!(doctype|DOCTYPE)" , "end" : ">" , "contentName" : "entity.name.tag.doctype.html" , "beginCaptures" : { "0" : { "name" : "entity.name.tag.doctype.html" } } , "endCaptures" : { "0" : { "name" : "entity.name.tag.doctype.html" } } } , { "begin" : "<!--" , "end" : "-->" , "beginCaptures" : { "0" : { "name" : "punctuation.definition.comment.html" } } , "endCaptures" : { "0" : { "name" : "punctuation.definition.comment.html" } } , "patterns" : [ { "match" : "--" , "name" : "invalid.illegal.badcomment.html" } ] , "contentName" : "comment.block.html" } , { "match" : "<[A-Za-z0-9_\\-:]+(?= ?)" , "name" : "entity.name.tag.html" } , { "include" : "#attrName" } , { "include" : "#qString" } , { "include" : "#qqString" } , { "include" : "#entity" } , { "match" : "</[A-Za-z0-9_\\-:]+>" , "name" : "entity.name.tag.html" } , { "match" : ">" , "name" : "entity.name.tag.html" } ] , "repository" : { "attrName" : { "match" : "[A-Za-z\\-:]+(?=\\s*=\\s*['\"])" , "name" : "entity.other.attribute.name.html" } , "qqString" : { "match" : "(\")[^\"]+(\")" , "name" : "string.quoted.double.html" } , "qString" : { "match" : "(')[^']+(\')" , "name" : "string.quoted.single.html" } , "entity" : { "match" : "&[A-Za-z0-9]+;" , "name" : "constant.character.entity.html" } } } ; }
Provides a grammar that can do some very rough syntax highlighting for HTML.
Provides a grammar that can do some very rough syntax highlighting for HTML .
// startDelimiter + tagName // TODO attrName, qString, qqString should be applied first while inside a tag // startDelimiter + slash + tagName + endDelimiter // end delimiter of open tag // attribute name // double quoted string // single quoted string