CoreFiles by mySites.guru
generic.js25 lines, 1,112 bytes, from wordpress-2.8.zip
Raw History Compare with 2.7.1
md5
8ab6d398feb9e9c1c77525143f05ec74
sha1
9c35fa9bb382d0ebd365b075c220069bd79b22e8
sha256
d7e5aa0d4ad23bfc3a25b794998b08e589bc3474ba3759b4307b9f5fedc5c2eb
/*
 * CodePress regular expressions for generic syntax highlighting
 */
 
// generic languages
Language.syntax = [
	{ input : /\"(.*?)(\"|<br>|<\/P>)/g, output : '<s>"$1$2</s>' }, // strings double quote
	{ input : /\'(.*?)(\'|<br>|<\/P>)/g, output : '<s>\'$1$2</s>' }, // strings single quote
	{ input : /\b(abstract|continue|for|new|switch|default|goto|boolean|do|if|private|this|break|double|protected|throw|byte|else|import|public|throws|case|return|catch|extends|int|short|try|char|final|interface|static|void|class|finally|long|const|float|while|function|label)\b/g, output : '<b>$1</b>' }, // reserved words
	{ input : /([\(\){}])/g, output : '<em>$1</em>' }, // special chars;
	{ input : /([^:]|^)\/\/(.*?)(<br|<\/P)/g, output : '$1<i>//$2</i>$3' }, // comments //
	{ input : /\/\*(.*?)\*\//g, output : '<i>/*$1*/</i>' } // comments /* */
]

Language.snippets = []

Language.complete = [
	{ input : '\'', output : '\'$0\'' },
	{ input : '"', output : '"$0"' },
	{ input : '(', output : '\($0\)' },
	{ input : '[', output : '\[$0\]' },
	{ input : '{', output : '{\n\t$0\n}' }		
]

Language.shortcuts = []

The same content is in 25 releases, WordPress 2.8-beta1 to 3.0-beta2. See them all, or every version of this file.