<?xml version="1.0" encoding="UTF-8"?>
<!--
 Authors:  Antoine Lucas 09-2009 <lucas@ipgp.fr>
           Timothy Arceri 12-2012

 GtkSourceView 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.

 GtkSourceView 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., 51 Franklin St, Fifth Floor, Boston, MA  02110-1301  USA

-->
<language id="idl-exelis" _name="IDL-Exelis" version="2.0" _section="Scientific">
  <metadata>
    <property name="globs">*.pro</property>
    <property name="line-comment-start">;</property>
  </metadata>

  <styles>
    <style id="comment" _name="Comment" map-to="def:comment"/>
    <style id="type" _name="Data Type" map-to="def:type"/>
    <style id="preprocessor" _name="Preprocessor" map-to="def:preprocessor"/>
    <style id="keyword" _name="Keyword" map-to="def:keyword"/>
    <style id="string" _name="String" map-to="def:string"/>
    <style id="floating-point" _name="Floating point number" map-to="def:floating-point"/>
    <style id="decimal" _name="Decimal number" map-to="def:decimal"/>
    <style id="function" _name="Function" map-to="def:function"/>
  </styles>

  <default-regex-options case-sensitive="false"/>

  <definitions>

    <context id="line-comment" style-ref="comment" end-at-line-end="true">
      <start>;</start>
      <include>
        <context ref="def:escape"/>
        <context ref="def:line-continue"/>
      </include>
    </context>

    <context id="string-doublequote" style-ref="string" end-at-line-end="true">
      <start>"</start>
      <end>"</end>
      <include>
        <context ref="def:line-continue"/>
      </include>
    </context>

   <context id="string-singlequote" style-ref="string" end-at-line-end="true">
      <start>'</start>
      <end>'</end>
      <include>
        <context ref="def:line-continue"/>
      </include>
    </context>

    <context id="sectional" style-ref="preprocessor">
      <start>%\(</start>
      <end>%\)</end>
      <include>
        <context ref="def:escape"/>
        <context ref="def:line-continue"/>
      </include>
    </context>

    <context id="operators" style-ref="keyword">
      <keyword>NOT</keyword>
      <keyword>AND</keyword>
      <keyword>OR</keyword>
      <keyword>XOR</keyword>
      <keyword>EQV</keyword>
      <keyword>NEQV</keyword>
      <keyword>EQ</keyword>
      <keyword>NE</keyword>
      <keyword>GT</keyword>
      <keyword>GE</keyword>
      <keyword>LT</keyword>
      <keyword>LE</keyword>
    </context>

    <context id="keyword" style-ref="keyword">
      <keyword>begin</keyword>
      <keyword>case</keyword>
      <keyword>common</keyword>
      <keyword>compile_opt</keyword>
      <keyword>cycle</keyword>
      <keyword>do</keyword>
      <keyword>elseif</keyword>
      <keyword>else</keyword>
      <keyword>elsewhere</keyword>
      <keyword>enddo</keyword>
      <keyword>endif</keyword>
      <keyword>end</keyword>
      <keyword>endelse</keyword>
      <keyword>endfor</keyword>
      <keyword>endforeach</keyword>
      <keyword>endcase</keyword>
      <keyword>external</keyword>
      <keyword>for</keyword>
      <keyword>foreach</keyword>
      <keyword>function</keyword>
      <keyword>if</keyword>
      <keyword>pro</keyword>
      <keyword>return</keyword>
      <keyword>SELECT</keyword>
      <keyword>stop</keyword>
      <keyword>then</keyword>
      <keyword>type</keyword>
      <keyword>use</keyword>
      <keyword>while</keyword>
    </context>

    <context id="functions" style-ref="function">
      <keyword>a_correlate</keyword>
      <keyword>adapt_hist_equal</keyword>
      <keyword>amoeba</keyword>
      <keyword>annotate</keyword>
      <keyword>array_indices</keyword>
      <keyword>arrow</keyword>
      <keyword>ascii_template</keyword>
      <keyword>bar_plot</keyword>
      <keyword>beta</keyword>
      <keyword>bilinear</keyword>
      <keyword>binary_template</keyword>
      <keyword>bin_date</keyword>
      <keyword>binomial</keyword>
      <keyword>bisect_pdf</keyword>
      <keyword>blk_con</keyword>
      <keyword>box_cursor</keyword>
      <keyword>butterworth</keyword>
      <keyword>caldat</keyword>
      <keyword>calendar</keyword>
      <keyword>canny</keyword>
      <keyword>c_correlate</keyword>
      <keyword>cdf_exists</keyword>
      <keyword>chebyshev</keyword>
      <keyword>chisqr_cvf</keyword>
      <keyword>chisqr_pdf</keyword>
      <keyword>cir_3pnt</keyword>
      <keyword>close</keyword>
      <keyword>cluster</keyword>
      <keyword>cluster_tree</keyword>
      <keyword>clust_wts</keyword>
      <keyword>cmyk_convert</keyword>
      <keyword>color_exchange</keyword>
      <keyword>colorize_sample</keyword>
      <keyword>colormap_applicable</keyword>
      <keyword>colormap_gradient</keyword>
      <keyword>colormap_rotation</keyword>
      <keyword>color_range_map</keyword>
      <keyword>comfit</keyword>
      <keyword>complexround</keyword>
      <keyword>cond</keyword>
      <keyword>congrid</keyword>
      <keyword>coord2to3</keyword>
      <keyword>correlate</keyword>
      <keyword>cramer</keyword>
      <keyword>create_view</keyword>
      <keyword>crossp</keyword>
      <keyword>crvlength</keyword>
      <keyword>cti_test</keyword>
      <keyword>ct_luminance</keyword>
      <keyword>curvefit</keyword>
      <keyword>cv_coord</keyword>
      <keyword>cvttobm</keyword>
      <keyword>cw_animate</keyword>
      <keyword>cw_arcball</keyword>
      <keyword>cw_bgroup</keyword>
      <keyword>cw_clr_index</keyword>
      <keyword>cw_colorsel</keyword>
      <keyword>cw_defroi</keyword>
      <keyword>cw_dice</keyword>
      <keyword>cw_field</keyword>
      <keyword>cw_filesel</keyword>
      <keyword>cw_form</keyword>
      <keyword>cw_fslider</keyword>
      <keyword>cw_light_editor</keyword>
      <keyword>cw_orient</keyword>
      <keyword>cw_palette_editor</keyword>
      <keyword>cw_pdmenu</keyword>
      <keyword>cw_rgbslider</keyword>
      <keyword>cw_tmpl</keyword>
      <keyword>cw_treestructure</keyword>
      <keyword>cw_zoom</keyword>
      <keyword>define_msgblk_from_file</keyword>
      <keyword>defroi</keyword>
      <keyword>dendrogram</keyword>
      <keyword>dendro_plot</keyword>
      <keyword>deriv</keyword>
      <keyword>derivsig</keyword>
      <keyword>determ</keyword>
      <keyword>device</keyword>
      <keyword>dialog_message</keyword>
      <keyword>dialog_read_image</keyword>
      <keyword>dialog_write_image</keyword>
      <keyword>digital_filter</keyword>
      <keyword>dissolve</keyword>
      <keyword>distance_measure</keyword>
      <keyword>dist</keyword>
      <keyword>dl_dos</keyword>
      <keyword>dl_unix</keyword>
      <keyword>doc_library</keyword>
      <keyword>edge_dog</keyword>
      <keyword>efont</keyword>
      <keyword>eigenql</keyword>
      <keyword>eigenvec</keyword>
      <keyword>emboss</keyword>
      <keyword>eos_exists</keyword>
      <keyword>eos_gd_query</keyword>
      <keyword>eos_pt_query</keyword>
      <keyword>eos_query</keyword>
      <keyword>eos_sw_query</keyword>
      <keyword>erase</keyword>
      <keyword>errplot</keyword>
      <keyword>expand</keyword>
      <keyword>extrac</keyword>
      <keyword>extract_slice</keyword>
      <keyword>factorial</keyword>
      <keyword>f_cvf</keyword>
      <keyword>filepath</keyword>
      <keyword>file_basename</keyword>
      <keyword>file_copy</keyword>
      <keyword>file_lines</keyword>
      <keyword>file_search</keyword>
      <keyword>file_test</keyword>
      <keyword>file_which</keyword>
      <keyword>flick</keyword>
      <keyword>flow3</keyword>
      <keyword>free_lun</keyword>
      <keyword>f_pdf</keyword>
      <keyword>funct</keyword>
      <keyword>fv_test</keyword>
      <keyword>fx_root</keyword>
      <keyword>gamma_ct</keyword>
      <keyword>gamma</keyword>
      <keyword>gauss2dfit</keyword>
      <keyword>gauss_cvf</keyword>
      <keyword>gaussfit</keyword>
      <keyword>gauss_pdf</keyword>
      <keyword>get_screen_size</keyword>
      <keyword>goto</keyword>
      <keyword>graphics_times2</keyword>
      <keyword>graphics_times3</keyword>
      <keyword>graphics_times</keyword>
      <keyword>gs_iter</keyword>
      <keyword>h5_browser</keyword>
      <keyword>h5_create</keyword>
      <keyword>h5_parse</keyword>
      <keyword>h5t_enum_get_data</keyword>
      <keyword>h5t_enum_set_data</keyword>
      <keyword>h5t_enum_values_to_names</keyword>
      <keyword>h5t_str_to_vlen</keyword>
      <keyword>h5t_vlen_to_str</keyword>
      <keyword>hanning</keyword>
      <keyword>hdf_exists</keyword>
      <keyword>h_eq_ct</keyword>
      <keyword>h_eq_int</keyword>
      <keyword>hilbert</keyword>
      <keyword>hist_2d</keyword>
      <keyword>hist_equal</keyword>
      <keyword>hls</keyword>
      <keyword>hsv</keyword>
      <keyword>ibeta</keyword>
      <keyword>identity</keyword>
      <keyword>idl_crank</keyword>
      <keyword>idlfflangcat__define</keyword>
      <keyword>idlgrarc__define</keyword>
      <keyword>idlgrcolorbar__define</keyword>
      <keyword>idlgrlegend__define</keyword>
      <keyword>idlgrshaderbytscl__define</keyword>
      <keyword>idlgrshaderconvol3__define</keyword>
      <keyword>idlgrtextedit__define</keyword>
      <keyword>igamma</keyword>
      <keyword>image_cont</keyword>
      <keyword>import_ascii</keyword>
      <keyword>import_binary</keyword>
      <keyword>import_create_varname</keyword>
      <keyword>import_hdf</keyword>
      <keyword>import_image</keyword>
      <keyword>insget</keyword>
      <keyword>insput</keyword>
      <keyword>insvis</keyword>
      <keyword>int_2d</keyword>
      <keyword>int_3d</keyword>
      <keyword>interpol</keyword>
      <keyword>int_tabulated_2d</keyword>
      <keyword>int_tabulated</keyword>
      <keyword>ir_filter</keyword>
      <keyword>julday</keyword>
      <keyword>krig2d</keyword>
      <keyword>kurtosis</keyword>
      <keyword>kw_test</keyword>
      <keyword>label_date</keyword>
      <keyword>la_determ</keyword>
      <keyword>ladfit</keyword>
      <keyword>laguerre</keyword>
      <keyword>la_linear_equation</keyword>
      <keyword>laplacian</keyword>
      <keyword>leefilt</keyword>
      <keyword>linfit</keyword>
      <keyword>ll_arc_distance</keyword>
      <keyword>lmfit</keyword>
      <keyword>lmfunct</keyword>
      <keyword>loadct</keyword>
      <keyword>lu_complex</keyword>
      <keyword>map_2points</keyword>
      <keyword>map_continents</keyword>
      <keyword>map_grid</keyword>
      <keyword>map_horizon</keyword>
      <keyword>map_image</keyword>
      <keyword>map_patch</keyword>
      <keyword>map_point_valid</keyword>
      <keyword>map_proj_image</keyword>
      <keyword>map_proj_info</keyword>
      <keyword>map_proj_init_commonblock</keyword>
      <keyword>map_proj_init_common</keyword>
      <keyword>map_proj_init</keyword>
      <keyword>map_satellite_limit</keyword>
      <keyword>map_set</keyword>
      <keyword>map_struct_append</keyword>
      <keyword>matrix_power</keyword>
      <keyword>m_correlate</keyword>
      <keyword>md_test</keyword>
      <keyword>meanabsdev</keyword>
      <keyword>mean</keyword>
      <keyword>mesh_obj</keyword>
      <keyword>min_curve_surf</keyword>
      <keyword>mk_html_help</keyword>
      <keyword>modifyct</keyword>
      <keyword>moment</keyword>
      <keyword>morph_close</keyword>
      <keyword>morph_gradient</keyword>
      <keyword>morph_hitormiss</keyword>
      <keyword>morph_open</keyword>
      <keyword>morph_thin</keyword>
      <keyword>morph_tophat</keyword>
      <keyword>mpeg_close</keyword>
      <keyword>mpeg_open</keyword>
      <keyword>mpeg_put</keyword>
      <keyword>mpeg_save</keyword>
      <keyword>multi</keyword>
      <keyword>ncdf_exists</keyword>
      <keyword>noise_hurl</keyword>
      <keyword>noise_pick</keyword>
      <keyword>noise_scatter</keyword>
      <keyword>noise_slur</keyword>
      <keyword>norm</keyword>
      <keyword>obj_new</keyword>
      <keyword>online_help_pdf_index</keyword>
      <keyword>online_help_pdf_nd2file</keyword>
      <keyword>openr</keyword>
      <keyword>openw</keyword>
      <keyword>oploterr</keyword>
      <keyword>parse_url</keyword>
      <keyword>path_sep</keyword>
      <keyword>pcomp</keyword>
      <keyword>p_correlate</keyword>
      <keyword>plot_3dbox</keyword>
      <keyword>ploterr</keyword>
      <keyword>plot_field</keyword>
      <keyword>pm</keyword>
      <keyword>pnt_line</keyword>
      <keyword>polar_contour</keyword>
      <keyword>polar_surface</keyword>
      <keyword>poly_area</keyword>
      <keyword>poly_fit</keyword>
      <keyword>poly</keyword>
      <keyword>polywarp</keyword>
      <keyword>popd</keyword>
      <keyword>pref_migrate</keyword>
      <keyword>primes</keyword>
      <keyword>print</keyword>
      <keyword>printd</keyword>
      <keyword>printf</keyword>
      <keyword>profile</keyword>
      <keyword>profiles</keyword>
      <keyword>project_vol</keyword>
      <keyword>psafm</keyword>
      <keyword>pseudo</keyword>
      <keyword>ps_show_fonts</keyword>
      <keyword>ptr_free</keyword>
      <keyword>ptr_new</keyword>
      <keyword>ptr_valid</keyword>
      <keyword>pushd</keyword>
      <keyword>query_ascii</keyword>
      <keyword>query_bmp</keyword>
      <keyword>query_dicom</keyword>
      <keyword>query_gif</keyword>
      <keyword>query_image</keyword>
      <keyword>query_jpeg2000</keyword>
      <keyword>query_pict</keyword>
      <keyword>query_ppm</keyword>
      <keyword>query_srf</keyword>
      <keyword>query_wav</keyword>
      <keyword>ranks</keyword>
      <keyword>rb_routines</keyword>
      <keyword>r_correlate</keyword>
      <keyword>rdpix</keyword>
      <keyword>read_ascii</keyword>
      <keyword>read_binary</keyword>
      <keyword>read_bmp</keyword>
      <keyword>read_dicom</keyword>
      <keyword>readf</keyword>
      <keyword>read_gif</keyword>
      <keyword>read_image</keyword>
      <keyword>read_interfile</keyword>
      <keyword>read_jpeg2000</keyword>
      <keyword>read_pict_item</keyword>
      <keyword>read_pict</keyword>
      <keyword>read_ppm_next_line</keyword>
      <keyword>read_ppm_next_token</keyword>
      <keyword>read_ppm</keyword>
      <keyword>read_spr</keyword>
      <keyword>read_srf</keyword>
      <keyword>read_sylk</keyword>
      <keyword>read_wave</keyword>
      <keyword>read_wav</keyword>
      <keyword>read_x11_bitmap</keyword>
      <keyword>read_xwd</keyword>
      <keyword>real_part</keyword>
      <keyword>recon3</keyword>
      <keyword>reduce_colors</keyword>
      <keyword>region_grow</keyword>
      <keyword>regress</keyword>
      <keyword>replicate</keyword>
      <keyword>resolve_all</keyword>
      <keyword>restore</keyword>
      <keyword>reverse</keyword>
      <keyword>rm</keyword>
      <keyword>round</keyword>
      <keyword>rot</keyword>
      <keyword>rs_test</keyword>
      <keyword>r_test</keyword>
      <keyword>save</keyword>
      <keyword>savgol</keyword>
      <keyword>scale3d</keyword>
      <keyword>scale3</keyword>
      <keyword>search2d</keyword>
      <keyword>search3d</keyword>
      <keyword>sfit</keyword>
      <keyword>shade_surf_irr</keyword>
      <keyword>shift_diff</keyword>
      <keyword>show3</keyword>
      <keyword>showfont</keyword>
      <keyword>showinfo</keyword>
      <keyword>skewness</keyword>
      <keyword>slicer3</keyword>
      <keyword>slide_image</keyword>
      <keyword>sort</keyword>
      <keyword>sph_4pnt</keyword>
      <keyword>spher_harm</keyword>
      <keyword>sph_scat</keyword>
      <keyword>spline_p</keyword>
      <keyword>spline</keyword>
      <keyword>standardize</keyword>
      <keyword>stddev</keyword>
      <keyword>s_test</keyword>
      <keyword>strarr</keyword>
      <keyword>strcompress</keyword>
      <keyword>streamline</keyword>
      <keyword>stretch</keyword>
      <keyword>string</keyword>
      <keyword>strjoin</keyword>
      <keyword>strlen</keyword>
      <keyword>strlowcase</keyword>
      <keyword>strmatch</keyword>
      <keyword>strmid</keyword>
      <keyword>strpos</keyword>
      <keyword>strsplit</keyword>
      <keyword>strtrim</keyword>
      <keyword>strupcase</keyword>
      <keyword>surfr</keyword>
      <keyword>svdfit</keyword>
      <keyword>svdfunct</keyword>
      <keyword>svdleg</keyword>
      <keyword>swap_endian_inplace</keyword>
      <keyword>swap_endian</keyword>
      <keyword>systime</keyword>
      <keyword>t3d</keyword>
      <keyword>t_cvf</keyword>
      <keyword>tek_color</keyword>
      <keyword>testdemo</keyword>
      <keyword>test_hp</keyword>
      <keyword>test_lj</keyword>
      <keyword>test_pcl</keyword>
      <keyword>test_true</keyword>
      <keyword>threed</keyword>
      <keyword>timegen</keyword>
      <keyword>time_test2</keyword>
      <keyword>time_test3</keyword>
      <keyword>time_test</keyword>
      <keyword>time_thread</keyword>
      <keyword>tm_test</keyword>
      <keyword>t_pdf</keyword>
      <keyword>trace</keyword>
      <keyword>trackball__define</keyword>
      <keyword>transpose</keyword>
      <keyword>tri_surf</keyword>
      <keyword>ts_coef</keyword>
      <keyword>ts_diff</keyword>
      <keyword>ts_fcast</keyword>
      <keyword>ts_smooth</keyword>
      <keyword>tvlct</keyword>
      <keyword>tvrd</keyword>
      <keyword>uniq</keyword>
      <keyword>unsharp_mask</keyword>
      <keyword>variance</keyword>
      <keyword>vector_field</keyword>
      <keyword>velovect</keyword>
      <keyword>vel</keyword>
      <keyword>vert_t3d</keyword>
      <keyword>voronoi</keyword>
      <keyword>warp_tri</keyword>
      <keyword>wdelete</keyword>
      <keyword>wf_draw</keyword>
      <keyword>where</keyword>
      <keyword>widget_base</keyword>
      <keyword>widget_button</keyword>
      <keyword>widget_control</keyword>
      <keyword>widget_info</keyword>
      <keyword>widget_text</keyword>
      <keyword>widget_tree_move</keyword>
      <keyword>window</keyword>
      <keyword>write_bmp</keyword>
      <keyword>write_gif</keyword>
      <keyword>write_image</keyword>
      <keyword>write_jpeg2000</keyword>
      <keyword>write_nrif</keyword>
      <keyword>write_pict</keyword>
      <keyword>write_ppm</keyword>
      <keyword>write_spr</keyword>
      <keyword>write_srf</keyword>
      <keyword>write_sylk</keyword>
      <keyword>write_wave</keyword>
      <keyword>write_wav</keyword>
      <keyword>xmanager</keyword>
      <keyword>xmng_tmpl</keyword>
      <keyword>xregistered</keyword>
      <keyword>xsq_test</keyword>
      <keyword>xyouts</keyword>
      <keyword>zoom_24</keyword>
      <keyword>zoom</keyword>
    </context>

    <context id="include-pragma" style-ref="preprocessor" end-at-line-end="true">
      <start>^#[ \t]*(include|pragma)</start>
      <include>
        <context ref="def:escape"/>
        <context ref="def:line-continue"/>
      </include>
    </context>

    <context id="function" style-ref="function">
      <keyword>add</keyword>
      <keyword>draw</keyword>
      <keyword>interpolate</keyword>
      <keyword>min</keyword>
      <keyword>max</keyword>
      <keyword>mean</keyword>
      <keyword>n_elements</keyword>
      <keyword>obj_destroy</keyword>
      <keyword>reform</keyword>
      <keyword>rotate</keyword>
      <keyword>size</keyword>
      <keyword>Xobjview</keyword>
    </context>

    <context id="types" style-ref="type">
      <keyword>float</keyword>
      <keyword>fltarr</keyword>
      <keyword>UINT</keyword>
      <keyword>long</keyword>
      <keyword>fix</keyword>
      <keyword>lonarr</keyword>
    </context>

    <context id="float" style-ref="floating-point">
      <match extended="true">
        (?&lt;![\w\.])
        ([0-9_]+[Ee][-]?[0-9_]+|([0-9_]*\.[0-9_]+|[0-9_]+\.)([Ee][-]?[0-9_]+)?)[fFLi]?
        (?![\w\.])
      </match>
    </context>

    <context id="decimal" style-ref="decimal">
      <match extended="true">
        (?&lt;![\w\.])
        ([1-9][0-9_]*|0)([Uu]([Ll]|LL|ll)?|([Ll]|LL|ll)[Uu]?)?
        (?![\w\.])
      </match>
    </context>

    <context id="idl-exelis">
      <include>
        <context ref="operators"/>
        <context ref="line-comment"/>
        <context ref="sectional"/>
        <context ref="string-singlequote"/>
        <context ref="string-doublequote"/>
        <context ref="include-pragma"/>
        <context ref="keyword"/>
        <context ref="types"/>
        <context ref="float"/>
        <context ref="functions"/>
        <context ref="function"/>
        <context ref="decimal"/>
        <context ref="types"/>
      </include>
    </context>
  </definitions>
</language>
