/**
 * SyntaxHighlighter
 * http://alexgorbatchev.com/
 *
 * SyntaxHighlighter is donationware. If you are using it, please donate.
 * http://alexgorbatchev.com/wiki/SyntaxHighlighter:Donate
 *
 * @version
 * 2.1.364 (October 15 2009)
 * 
 * @copyright
 * Copyright (C) 2004-2009 Alex Gorbatchev.
 *
 * @license
 * This file is part of SyntaxHighlighter.
 * 
 * SyntaxHighlighter 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 3 of the License, or
 * (at your option) any later version.
 * 
 * SyntaxHighlighter 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 General Public License for more details.
 * 
 * You should have received a copy of the GNU General Public License
 * along with SyntaxHighlighter.  If not, see <http://www.gnu.org/copyleft/lesser.html>.
 */
SyntaxHighlighter.brushes.Typoscript = function()
{
	// TYPO3 Typoscript by Felix Nagel @ felixnagel.com
	
	var constants  =  'INCLUDE_TYPOSCRIPT DB FILE FORM FRAME GMENU GMENU_FOLDOUT TCEFORM TCEMAIN TEMPLATE TEXT TMENU TMENU_LAYERS TMENUITEM TSFE TYPO3_CONF_VARS USER USER_INT GMENU_LAYERS GP HMENU JSMENU JSMENUITEM LIT LOAD_REGISTER META MULTIMEDIA OTABLE PAGE PAGE_TARGET PAGE_TSCONFIG_ID PAGE_TSCONFIG_IDLIST PAGE_TSCONFIG_STR PHP_SCRIPT LABEL PHP_SCRIPT_EXT PHP_SCRIPT_INT RECORDS REMOTE_ADDR RESTORE_REGISTER RTE SEARCHRESULT SHARED HRULER HTML IENV IMAGE IFSUB IFSUBRO IMG_RESOURCE IMGMENU IMGMENUITEM IMGTEXT FRAMESET GIFBUILDER DOCUMENT_BODY EDITPANEL EFFECT FE_DATA FE_TABLE _CSS_DEFAULT_STYLE _DEFAULT_PI_VARS _GIFBUILDER _LOCAL_LANG BE_USER CARRAY BOX CASE ACT ACTIFSUB ACTIFSUBRO ACTRO CUR CURIFSUB CURIFSUBRO CURRO CHECK CLEARGIF REQ COMMENT COA COA_INT COBJ_ARRAY COLUMNS CONFIG CONSTANTS CONTENT CTABLE SWORD_PARAMS';
	
	var keywords =	'CType FEData global globalString globalVar includeLibs TCAdefaults userFunc ' +
					'admPanel alt_print auth browser cache content_fallback hideNonTranslated cObj cObject config content copy CSS_inlineStyle cut dataArray dayofmonth dayofweek db_list device dynCSS edit edit_access edit_pageheader fe_admin_dmailsubscrip fe_admin_fe_users folder folderTree foldoutMenu Functions gmenu_foldout gmenu_layers hostname hour imgList imgResource imgText info IP jsmenu JSwindow layout levelmedia lib loginUser marks minute mod module month move_wizard new new_wizard noResultObj numRows options page pageTree paste perms PIDinRootline PIDupinRootline plaintext_content plugin postform postform_newThread preview publish RADIO renderObj RTE_compliant select setup split stat stat_apache stat_apache_logfile stat_apache_niceTitle stat_apache_noHost stat_apache_noRoot stat_apache_notExtended stat_apache_pagenames stat_excludeBEuserHits stat_excludeIPList stat_mysql stat_pageLen stat_titleLen stat_typeNumList subparts system temp template tipafriend_template tmpl treeLevel tsdebug typolink url useragent version view workOnSubpart ' +
					'all arrowACT arrowNO ascii atLeast atMost BE be_groups be_users browse bullets default description directory directReturn div else email end equals external false FE fe_groups fe_users feadmin header html id if ifBlank ifEmpty image inBranch isFalse isGreaterThan isInList isLessThan isPositive isTrue keywords language leveltitle list login mailform media menu multimedia negate NEW NO none pages pages_language_overlay parseFunc_RTE pid required RO rootline script search shortcut sitemap SPC splash sys_dmail sys_domain sys_filemounts sys_note sys_template tabel textpic this top true tt_address tt_board tt_board_list tt_board_tree tt_calender tt_content tt_guest tt_news tt_poll tt_products tt_rating twice tx_automaketemplate_pi1 tx_belog_webinfo tx_browserpagetitle tx_browserpagetitle_browser_title tx_chcforum_pi1 tx_cms_layout tx_cms_webinfo_hits tx_cms_webinfo_lang tx_cms_webinfo_page tx_cssstyledcontent_pi1 tx_dephpot_pi1 tx_extkey tx_extkey_controllers tx_extkey_login tx_extrapagecmoptions tx_funcwizards_webfunc tx_gooffotoboek_pi1 tx_impexp tx_impexp_clickmenu tx_impexp_modfunc1 tx_indexed_search_extparse tx_indexedsearch tx_indexedsearch_indexer tx_indexedsearch_lexer tx_indexedsearch_modfunc1 tx_indexedsearch_modfunc2 tx_indexedsearch_pihook tx_infopagetsconfig_webinfo tx_install tx_lzgallery_pi1 tx_macinasearchbox_pi1 tx_mhajaxsearch_pi1 tx_mhajaxsearch_q tx_mhajaxsearch_result tx_mhajaxsearch_search tx_newloginbox_pi1 tx_newloginbox_pi3 tx_open_printlink tx_pdfgenerator tx_pdfgenerator2 tx_realurl_advanced tx_realurl_enable tx_realurl_pathsegment tx_realurl_pi1 tx_rlmptmplselector tx_rlmptmplselector_pi1 tx_sochat_pi1 tx_srfeuserregister_pi1 tx_sv_auth tx_sv_authbase tx_sysaction tx_templavoila_pi1 tx_terdoc_pi1 tx_ttnews tx_ttnews_catmenu tx_ttnews_itemsProcFunc tx_ttnews_tcemain tx_ttnews_treeview tx_ttproducts_pi1 tx_veguestbook_pi1 tx_version_cm1 tx_vjchat_chat tx_vjchat_pi1 tx_wizardcrpages_webfunc_2 tx_wizardsortpages_webfunc_2 tx_wwwebstats4u_pi1 uid uniqueGlobal uniqueLocal unsetEmpty updated us user_task USERDEF1 USERDEF1RO USERDEF2 USERDEF2RO usergroup USR USRRO web_func web_info web_layout web_list web_ts xhtml_strict xhtml_trans xMOD_alt_doc XY ypMenu ' +
					'_offset absRefPrefix accessibility accessKey addAttributes addExtUrlsAndShortCuts addHeight addItems additionalHeaders additionalParams additionalPreviewLanguages addParams addQueryString addWidth adjustItemsH adjustSubItemsH adminPanelStyles after afterImg afterImgLink afterImgTagParams afterROImg afterWrap age alertPopups align allow allowCaching allowedAttribs allowedClasses allowedCols allowEdit allowedNewTables allowNew allowTags allowTagsOutside allowTVlisting allSaveFunctions allStdWrap allWrap alternateBgColors alternativeSortingField alternativeTempPath altImgResource altLabels altTarget altText altUrl altUrl_noDefaultParams altWrap always alwaysActivePIDlist alwaysLink alwaysShowClickMenuInTopFrame andWhere angle antiAlias appearance append applyTotalH applyTotalW archive archiveTypoLink arrayReturnMode arrowImgParams ATagAfterWrap ATagBeforeWrap ATagParams ATagTitle attribute autoInsertPID autoLevels autonumber autoSizeMax backColor background badMess baseURL before beforeImg beforeImgLink beforeImgTagParams beforeROImg beforeWrap begin beLoginLinkIPList beLoginLinkIPList_login beLoginLinkIPList_logout beUserLogin bgCol bgcolor bgImg blankStrEqFalse blur bm bodyTag bodyTagAdd bodyTagCObject bodyTagMargins bodytext border borderCol bordersWithin borderThick bottomBackColor bottomContent bottomHeight bottomImg bottomImg_mask br brTag bullet bulletlist bytes cache_clearAtMidnight cache_period caption caption_stdWrap captionAlign captionHeader captionSplit case casesensitiveComp cellpadding cellspacing centerImgACT centerImgCUR centerImgNO centerLeftImgACT centerLeftImgCUR centerLeftImgNO centerRightImgACT centerRightImgCUR centerRightImgNO char charcoal charMapConfig check class classesAnchor classesCharacter classesImage classesParagraph classicPageEditMode clear clearCache clearCache_disable clearCache_pageGrandParent clearCache_pageSiblingChildren clearCacheCmd clearCacheLevels clearCacheOfPages clickMenuTimeOut clickTitleMode clipboardNumberPads cMargins cObjNum collapse color color1 color2 color3 color4 colors colour colPos_list colRelations cols colSpace comment_auto commentWrap compensateFieldWidth compX compY condensedMode conf constants content_from_pid_allowOutsideDomain contentCSS contextMenu copyLevels count_HMENU_MENUOBJ count_menuItems count_MENUOBJ create createFoldersInEB crop csConv current curUid cWidth data dataWrap date date_stdWrap datePrefix debug debugData debugFunc debugItemConf debugRenumberedObject defaultAlign defaultCmd defaultFileUploads defaultHeaderType defaultLanguageFlag defaultLanguageLabel defaultOutput defaults defaultType defLangBinding delete denyTags depth DESC dimensions directionLeft directionUp disableAdvanced disableAllHeaderCode disableAltText disableBigButtons disableCacheSelector disableCharsetHeader disableCMlayers disabled disableDelete disableDocModuleInAB disableDocSelector disableHideAtCopy disableIconLinkToContextmenu disableIconToolbar disableImgBorderAttr disableItems disableNewContentElementWizard disableNoMatchingValueElement disablePageExternalUrl disablePathInfo disablePrefixComment disablePrependAtCopy disableSearchBox disableSingleTableView disableTabInTextarea disableTitleHighlight displayActiveOnLoad displayContent displayFieldIcons displayIcons displayMessages displayQueries displayRecord displayTimes distributeX distributeY DIV doctype doctypeSwitch doktype doNotLinkIt doNotShowLink doNotStripHTML dontCheckPid dontConvBRtoParagraph dontFollowMouse dontHideOnMouseUp dontLinkIfSubmenu dontMd5FieldNames dontMountAdminMounts dontShowPalettesOnFocusInAB dontWrapInTable doubleBrTag doublePostCheck dWorkArea edge edit_docModuleUpload edit_RTE edit_showFieldHelp edit_wideDocument editFieldsAtATime editFormsOnPage editIcons editNoPopup editPanel effects elements emailMeAtLogin emailMess emboss enable enableContentLengthHeader encapsLines encapsLinesStdWrap encapsTagList entryHTMLparser_db entryLevel equalH everybody excludeDoktypes excludeUidList expAll expand explode ext externalBlocks extTarget face fe_adminLib fe_user field fieldOrder fieldPrefix fieldRequired fields fieldWrap file file1 file2 file3 file4 file5 filelink filelist firstLabel firstLabelGeneral fixAttrib flip flop foldSpeed foldTimer fontColor fontFile fontOffset fontSize fontSizeMultiplicator fontTag forceDisplayFieldIcons forceDisplayIcons forceNoPopup forceTemplateParsing forceTypeValue foreign_label foreign_selector foreign_unique format formName frame frameReloadIfNotInFrameset frameSet freezeMouseover ftu function gamma gapBgCol gapLineCol gapLineThickness gapWidth get getBorder getLeft getRight getText globalNesting goodMess gr_list gray group groupBy groupid header_layout header_link header_position headerClass headerComment headerData headerSpace headerStyle headTag height helpText hidden hiddenFields hide hideButCreateMap hideButtons hideMenuTimer hideMenuWhenNotOver hidePStyleItems hideRecords hideSubmoduleIcons hideTables highColor history hover hoverStyle HTMLparser HTMLparser_tags htmlSpecialChars htmlTag_dir htmlTag_langKey htmlTag_setParams http icon icon_image_ext_list icon_link iconCObject image_compression image_effects image_frames imageLinkWrap imagePath images imagewidth imageWrapIfAny imgMap imgMapExtras imgMax imgNameNotRandom imgNamePrefix imgObjNum imgParams imgPath imgStart imgtext import inc includeCSS includeJS includeLibrary includeNotInMenu incT3Lib_htmlmail index index_descrLgd index_enable index_externals inline inlineStyle2TempFile innerStdWrap innerStdWrap_all innerWrap innerWrap2 input inputLevels insertClassesFromRTE insertData insertDmailerBoundaries intensity internalizeFontTags intTarget intval invert IProcFunc itemArrayProcFunc itemH items itemsProcFunc iterations join JSWindow JSwindow_params jumpurl jumpurl_enable jumpurl_mailto_disable jumpUrl_transferSession keep keepEntries keepNonMatchedTags key label labelStdWrap labelWrap lang language_alt languageField layer_menu_id layerStyle left leftIcons leftImgACT leftImgCUR leftImgNO leftjoin leftOffset levels leveluid limit line lineColor lineThickness linkPrefix linkTitleToSelf linkToTop linkVars linkWrap listNum listOnlyInSingleTableView lm locale_all localNesting locationData lockFilePath lockPosition lockPosition_addSelf lockPosition_adjust lockToIP longdescURL lowColor lower LR mailto main mainScript makelinks markerWrap mask max max_size maxAge maxAgeDays maxChars maxH maxHeight maxitems maxW maxWidth maxWInText mayNotCreateEditShortcuts meaningfulTempFilePrefix menu_type menuBackColor menuHeight menuName menuOffset menuWidth message_page_is_being_generated message_preview message_preview_workspace meta metaCharset method min minH minitems minW mode moduleMenuCollapsable MP_defaults MP_disableTypolinkClosestMPvalue MP_mapRootPoints name navFrameResizable navFrameWidth nesting netprintApplicationLink neverHideAtCopy newContentWiz newPageWiz newRecordFromTable newRecordInPid newWindow newWizards next niceText no_cache no_search noAttrib noBlur noCache noCols noCreateRecordsLink noLink noLinkUnderline noMatchingValue_label noMenuMode nonCachedSubst nonTypoTagStdWrap nonTypoTagUserFunc nonWrappedTag noOrderBy noPageTitle noRows noScaleUp noStretchAndMarginCells noThumbsInEB noThumbsInRTEimageSelect notification_email_charset notification_email_encoding notification_email_urlmode noTrimWrap noValueInsert noWrapAttr obj offset offsetWrap onlineWorkspaceInfo onlyCurrentPid opacity orderBy outerWrap outline outputLevels override overrideAttribs overrideEdit overrideId overridePageModule overrideWithExtension overruleMode pageFrameObj pageGenScript pageTitleFirst parameter params parseFunc parser password path permissions pid_list pidInList pixelSpaceFontSizeRef plaintextLib plainTextStdWrap postBlanks postCObject postLineBlanks postLineChar postLineLen postUserFunc postUserFuncInt preBlanks preCObject prefix prefixComment prefixLocalAnchors prefixRelPathWith preIfEmptyListNum preLineBlanks preLineChar preLineLen prepend preserveEntities preserveTables preUserFunc prev previewBorder prevnextToSection printheader prioriCalc proc processScript properties protect protectLvar publish_levels QEisDefault quality radio radioWrap range rawUrlEncode recipient recursive recursiveDelete redirect redirectToURL reduceColors register relativeToParentLayer relativeToTriggerItem relPathPrefix remap remapTag removeBadHTML removeDefaultJS removeIfEquals removeIfFalse removeItems removeObjectsOfDummy removePrependedNumbers removeTags removeWrapping renderCharset renderWrap reset resources resultObj returnKey returnLast returnUrl rightImgACT rightImgCUR rightImgNO rightjoin rm rmTagIfNoAttrib RO_chBgColor rotate rows rowSpace rte_enabled RTEfullScreenWidth RTEkeyList rules sample saveClipboard saveDocNew secondRow section section_frame sectionIndex select_key selectFields sendCacheHeaders sendCacheHeaders_onlyWhenLoginDeniedInBranch separator set setContentToCurrent setCurrent setfixed setFixedHeight setFixedWidth setJS_mouseOver setJS_openPic setOnly shadow sharpen shear short shortcut_onEditId_dontSetPageTree shortcut_onEditId_keepExistingExpanded shortcutFrame shortcutGroups shortcutIcon show show_thumbs showAccessRestrictedPages showActive showButtons showClipControlPanelsDespiteOfCMlayers showDomainNameWithTitle showFirst showHiddenPages showHiddenRecords showHistory showIfRTE showPageIdWithTitle showTagFreeClasses simulateDate simulateStaticDocuments simulateStaticDocuments_addTitle simulateStaticDocuments_dontRedirectPathInfoError simulateStaticDocuments_noTypeIfNoTitle simulateStaticDocuments_pEnc simulateStaticDocuments_pEnc_onlyP simulateStaticDocuments_replacementChar simulateUserGroup singlePid site_author site_keywords site_reserved sitetitle siteUrl size slide smallFormFields solarize sorting source space spaceAfter spaceBefore spaceBelowAbove spaceLeft spaceRight spacing spamProtectEmailAddresses spamProtectEmailAddresses_atSubst spamProtectEmailAddresses_lastDotSubst special splitChar splitRendering src startInTaskCenter stayFolded stdheader stdWrap stdWrap2 strftime stripHtml styles stylesheet submenuObjSuffixes subMenuOffset submit subst_elementUid substMarksSeparately substring swirl sword sword_noMixedCase sword_standAlone symmetric_label sys_language_mode sys_language_overlay sys_language_softExclude sys_language_softMergeIfNotBlank sys_language_uid sys_page table tableCellColor tableParams tables tableStdWrap tableStyle tableWidth tags target TCAselectItem TDparams templateContent templateFile text text_align text_color text_face text_properties text_size textarea textMargin textMargin_outOfText textMaxLength textObjNum textPos textStyle thickness thumbnailsByDefault tile time_stdWrap tipafriendLib title titleLen titleTagFunction titleText tm token topOffset totalWidth translateToMessage transparentBackground transparentColor trim tsdebug_tree type typeNum types typolinkCheckRootline typolinkLinkAccessRestrictedPages typolinkLinkAccessRestrictedPages_addParams uidInList uniqueLinkVars unset uploadFieldsInTopOfEB uploads upper useCacheHash useLargestItemX useLargestItemY user userdefined userfunction userid userIdColumn USERNAME_substToken userProc USERUID_substToken value valueArray wave where width wiz wordSpacing workArea wrap wrap1 wrap2 wrap3 wrapAfterTags wrapAlign wrapFieldName wrapItemAndSub wrapNonWrappedLines wraps xhtml_cleaning xhtmlDoctype xmlprologue xPosOffset yPosOffset'
					;

	this.regexList = [
		{ regex: SyntaxHighlighter.regexLib.singleLineCComments,	css: 'comments' },		// one line comments
		{ regex: SyntaxHighlighter.regexLib.multiLineCComments,		css: 'comments' },		// multiline comments
		{ regex: /\#.*/gm ,											css: 'comments' },		// # comments
		{ regex: new RegExp(this.getKeywords(constants), 'gm'),		css: 'constants' },		// constants
		{ regex: new RegExp(this.getKeywords(keywords), 'gm'),		css: 'keyword' },		// keywords
		{ regex: /\[.*\]/gm ,										css: 'functions' },		// if / else / switch statements
		{ regex: /.(?:=|<|>).*/gm ,										css: 'variable' }		// variables
		];
	
	this.forHtmlScript(SyntaxHighlighter.regexLib.scriptScriptTags);
};

SyntaxHighlighter.brushes.Typoscript.prototype	= new SyntaxHighlighter.Highlighter();
SyntaxHighlighter.brushes.Typoscript.aliases	= ['ts','typoscript'];
