! Syntax Highlighting Patterns for Patrol ! ! This pattern is made for Patrol and it contains two language patterns, one for ! Patrol Script and the other for Patrol KM. ! ------------------------------------------------------------------------------ ! ! In NEdit Version 5.0.1 and beyond, load this pattern by starting nedit with: ! ! nedit -import ! ! Then, check that the patterns were loaded correctly, and choose Save Defaults ! from the Preferences menu. The new patterns will now be incorporated into ! your own .nedit file, so the next time you start NEdit, you will no longer ! need to use -import. ! ! In version 5.0, without -import, you must edit your .nedit file by hand and ! add the contents of each resource below to the corresponding list in your ! .nedit file. Be sure to separate new entries with \n, and continue resource ! strings by escaping all newlines within a resource value with \ (backslash), ! leaving only the last line of the resource value not ending in \. ! ! ------------------------------------------------------------------------------ ! Author : Jon Hamlin ! Date : Sept., 1998 nedit.highlightPatterns: \ Patrol Script:1:0{\n\ comments:"#":"$"::Comment::\n\ double quote strings:"""":"""":"\\n":String::\n\ dq string esc chars:"\\\\(.|\\n)":::String1:double quote strings:\n\ subroutine header:"function[\\t ]+([a-zA-Z0-9_]+)":::Keyword::\n\ subr header coloring:"\\1":""::Flag:subroutine header:C\n\ ignore escaped chars:"\\\\[#""'\\$msytq]":::Plain::\n\ re matching:"<((m|q|qq)?/)[^/]*(/[gimsox]?)>":::String::\n\ re match coloring:"\\1\\3":""::String2:re matching:C\n\ re substitution:"<((s|y|tr)/)[^/]*(/)[^/]*(/[gimsox]?)":::String::\n\ re subs coloring:"\\1\\3\\4":""::String2:re substitution:C\n\ keywords:"<(do|until|exit|export|for|foreach|line|word|if|last|elsif|else|local|next|requires|return|switch|case|default:|while)>":::Keyword::D\n\ library fns:"<(full_discovery|in_transition|proc_exists|process|chan_exists|close|desktop|execute|fopen|get_chan_info|internal|popen|share|system|cond_signal|cond_wait|asctime|convert_date|date|time|debugger|getenv|event_archive|event_catalog_get|event_check|event_query|event_range_manage|event_range_query|event_report|event_schedule|event_trigger|event_trigger2|cat|file|lseek|ftell|chart|log|popup_report|print|printf|read|readln|sprintf|tmpnam|write|write_to_report|destroy_lock|lock|unlock|acos|asin|atan|ceil|cos|cosh|exp|fabs|floor|fmod|int|loge|log10|pow|random|sin|sinh|sqrt|srandom|tan|tanh|blackout|change_state|create|destroy|exists|get|get_vars|is_var|set|unset|annotate|annotate_get|get_ranges|history|history_get_retention|refresh_parameters|set_alarm_ranges|pconfig|console_type|num_consoles|response|response_get_value|atexit|getpid|getpname|kill|PslExecute|PslSetOptions|sleep|trace_psl_process|remote_close|remote_event_query|remote_event_trigger|remote_file_send|remote_open|difference|intersection|sort|subset|union|unique|snmp_agent_config|snmp_agent_start|snmp_agent_stop|snmp_close|snmp_config|_snmp_debug|snmp_get|snmp_get_next|snmp_h_get|snmp_h_get_next|snmp_h_set|snmp_open|snmp_set|snmp_trap_ignore|snmp_trap_listen|snmp_trap_raise_std_trap|snmp_trap_receive|snmp_trap_register_im|snmp_trap_send|snmp_walk|encrypt|grep|index|isnumber|join|length|lines|ntharg|nthargf|nthline|nthlinef|replace|rindex|substr|tail|tolower|toupper|trim|va_arg|va_start)>":::Subroutine::D\n\ braces and parens:"[\\[\\]{}\\(\\)]":::Keyword::\n\ Predefined Constant:"<(ALARM|WARN|OK|OFFLINE|VOID|EOF|true|TRUE|True|yes|YES|Yes|false|FALSE|False|no|NO|No)>":::Character Const::\n\ }\n\ Patrol KM:1:0{\n\ comments:"#":"$"::Comment::\n\ double quote strings:"""":"""":"\\n":String::\n\ dq string esc chars:"\\\\(.|\\n)":::String1:double quote strings:\n\ single quote strings:"'":"'":"\\n":String::\n\ sq string esc chars:"\\\\(.|\\n)":::String1:single quote strings:\n\ subroutine header:"function[\\t ]+([a-zA-Z0-9_]+)":::Keyword::\n\ subr header coloring:"\\1":""::Flag:subroutine header:C\n\ ignore escaped chars:"\\\\[#""'\\$msytq]":::Plain::\n\ re matching:"<((m|q|qq)?/)[^/]*(/[gimsox]?)>":::String::\n\ re match coloring:"\\1\\3":""::String2:re matching:C\n\ re substitution:"<((s|y|tr)/)[^/]*(/)[^/]*(/[gimsox]?)":::String::\n\ re subs coloring:"\\1\\3\\4":""::String2:re substitution:C\n\ keywords:"<(do|until|exit|export|for|foreach|if|last|elsif|else|local|next|requires|return|switch|case|default:|while|VERSION|APPLICATIONS|NAME|ACTIVE|SECURITY|PROPAGATE_STATE|CREATE_ICON|SUSPEND_GLOBAL_PARAMS|SHOWINST|DISCOVERY_TIME|DISCOVERY|DISCOVERY_TEXT|OK_PICTURE|WRONG_PICTURE|INFO_BOX|AVAILABILITY|BASE_COMMAND|COMPUTER_TYPE|COMMAND_TYPE|COMMAND_TEXT|PARAMETERS|PARAM_TYPE|START|POLL_TIME|EXTERNAL_POLLING|TITLE|UNITS|HISTORY_TIME|HISTORY_SPAN|HISTORY_LEVEL|FORMAT|OUTPUT|AUTO_RESCALE|Y_AXIS_MIN|Y_AXIS_MAX|MONITOR|CHECK|RANGES|MINIMUM|MAXIMUM|STATE|ALARM_WHEN|ALARM_WHEN_N|RECOVERY_LIST)>":::Keyword::D\n\ library fns:"<(full_discovery|in_transition|proc_exists|process|chan_exists|close|desktop|execute|fopen|get_chan_info|internal|popen|share|system|cond_signal|cond_wait|asctime|convert_date|date|time|debugger|getenv|event_archive|event_catalog_get|event_check|event_query|event_range_manage|event_range_query|event_report|event_schedule|event_trigger|event_trigger2|cat|file|lseek|ftell|chart|log|popup_report|print|printf|read|readln|sprintf|tmpnam|write|write_to_report|destroy_lock|lock|unlock|acos|asin|atan|ceil|cos|cosh|exp|fabs|floor|fmod|int|loge|log10|pow|random|sin|sinh|sqrt|srandom|tan|tanh|blackout|change_state|create|destroy|exists|get|get_vars|is_var|set|unset|annotate|annotate_get|get_ranges|history|history_get_retention|refresh_parameters|set_alarm_ranges|pconfig|console_type|num_consoles|response|response_get_value|atexit|getpid|getpname|kill|PslExecute|PslSetOptions|sleep|trace_psl_process|remote_close|remote_event_query|remote_event_trigger|remote_file_send|remote_open|difference|intersection|sort|subset|union|unique|snmp_agent_config|snmp_agent_start|snmp_agent_stop|snmp_close|snmp_config|_snmp_debug|snmp_get|snmp_get_next|snmp_h_get|snmp_h_get_next|snmp_h_set|snmp_open|snmp_set|snmp_trap_ignore|snmp_trap_listen|snmp_trap_raise_std_trap|snmp_trap_receive|snmp_trap_register_im|snmp_trap_send|snmp_walk|encrypt|grep|index|isnumber|join|length|lines|ntharg|nthargf|nthline|nthlinef|replace|rindex|substr|tail|tolower|toupper|trim|va_arg|va_start)>":::Subroutine::D\n\ PSL Macros:"%({[^}]*}|[^a-zA-Z0-9_ /\\t\\n\\.,\\\\[\\\\{\\\\(]|[0-9]+|[a-zA-Z_][a-zA-Z0-9_]*)?":::Identifier1::\n\ variables in strings:"[$@%&]({[^}]*}|[^a-zA-Z0-9_ /\\t\\n\\.,\\\\[\\\\{\\\\(]|[0-9]+|[a-zA-Z_][a-zA-Z0-9_]*)?":::Identifier1:double quote strings:\n\ subroutine call:"&[a-zA-Z0-9_]+":::Subroutine::\n\ braces and parens:"[\\[\\]{}\\(\\)]":::Keyword::\n\ Predefined Constant:"<(ALARM|WARN|OK|OFFLINE|VOID|EOF|true|TRUE|True|yes|YES|Yes|false|FALSE|False|no|NO|No)>":::Character Const::\n\ } nedit.languageModes: \ Patrol Script:.psl::::::\n\ Patrol KM:.km::::::