/**
 * Code Syntax Highlighter for Lisp.
 * 2008.11.19, Sanghyuk Suh
 * http://han9kin.doesntexist.com/
 *
 * This library is free software; you can redistribute it and/or modify it under the terms of the GNU Lesser General
 * Public License as published by the Free Software Foundation; either version 2.1 of the License, or (at your option)
 * any later version.
 *
 * This library is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied
 * warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser General Public License for more
 * details.
 *
 * You should have received a copy of the GNU Lesser General Public License along with this library; if not, write to
 * the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
 */

dp.sh.Brushes.Lisp = function()
{
    var keywords =
    'let while when unless cond if lambda defun defvar progn dolist dotimes with-temp-buffer';

    var builtins =
    't nil';

    this.regexList = [
        { regex: dp.sh.RegexLib.DoubleQuotedString,     css: 'string' },
        { regex: new RegExp('&\\w+;', 'g'),         css: 'other' },
        { regex: new RegExp(';.*', 'g'),            css: 'comment' },
        { regex: new RegExp("'(\\w|-)+", 'g'),          css: 'symbol' },
        { regex: new RegExp(this.GetKeywords(keywords), 'gm'),  css: 'keyword' },
        { regex: new RegExp(this.GetKeywords(builtins), 'gm'),  css: 'builtin' }
        ];

    this.CssClass = 'dp-lisp';
    this.Style =    '.dp-lisp .symbol { color: #a70; }' +
            '.dp-lisp .builtin { color: #008284; }'
}

dp.sh.Brushes.Lisp.prototype    = new dp.sh.Highlighter();
dp.sh.Brushes.Lisp.Aliases  = ['lisp'];
