<?xml version="1.0" encoding="Windows-1251"?>
<!--
    Atlantis 1.5 Syntax by Vladimir Fonarev <vol@quorum.ru>
                                            [2:5020/2160]
-->

<hrc version="take5">
  
  <type name="dii" access="public">

    <region name="diiString"  parent="def:String"/>
    <region name="diiComment" parent="def:Comment"/>
    <region name="diiNumb"    parent="def:Number"/>
    <region name="diiWord"    parent="def:Keyword"/>
    <region name="tdiiWord"   parent="def:TypeKeyword"/>
    <region name="TblOutline" parent="def:Outlined"/>

    <scheme name="dii">
<!-- linear comments -->
      <regexp match="/(^!.*$)/" region0="diiComment"/>
      <block start="/\/\//" end="/$/" scheme="def:Comment" region="diiComment"/>
      <block start="/\/\*/" end="/\*\//" scheme="def:Comment" region="diiComment" region00="def:PairStart" region10="def:PairEnd"/>
      <block start="/\(\*/" end="/\*\)/" scheme="def:Comment" region="diiComment" region00="def:PairStart" region10="def:PairEnd"/>
<!-- strings -->
      <regexp match='/(".*?")/' region0="diiString"/>
      <regexp match="/\#\d+?\b/" region0="diiString"/>
      <regexp match="/\#\$[\dA-Fa-f]+?\b/" region0="diiString"/>
<!-- Numbers -->
      <regexp match="/\c(\$[\da-fA-F]+)\b/" region0="diiNumb"/>
      <inherit scheme="def:FloatNumber"/>
      <inherit scheme="def:DecNumber"/>
      <regexp match="/\c(\$[\da-fA-F]*?([^\s\W\da-fA-F]).*?)\b/" region0="def:ErrorText"/>
<!-- objects -->
      <regexp match="/^\M\s*(create\s+(table|dictionary)\s+)(?{TblOutline}.*)$/ix"/>
<!-- parencies -->
      <block start="/(\()/" end="/(\))/" scheme="dii" region00="def:Symbol" region01="def:PairStart" region10="def:Symbol" region11="def:PairEnd"/>
      <regexp match="/\b(str\d+)\b/i" region0="tdiiWord"/>
<!--Это просмотр назад: "ORC FLAT" должно подсвечиваться-->
      <regexp match="/(\bORC\b)?#3(\s+\bFLAT\b)/i" region2="diiWord"/>
<!--Это просмотр вперед: "ORC RS" должно подсвечиваться-->
      <regexp match="/(\bORC\b\s+\bRS\b)?=/i" region1="diiWord"/>
      <regexp match="/(\bARRAY\b)\s*\[\s*(\d+)\.{2}(\d+)\s*\]\s*(\bOF\b)/i" region1="diiWord" region2="diiNumb" region3="diiNumb" region4="diiWord"/>
      <keywords ignorecase="yes" region="diiWord">
        <word name="create"/>
        <word name="dictionary"/>
        <word name="using"/>
        <word name="with"/>
        <word name="replace"/>
        <word name="table"/>
        <word name="number"/>
        <word name="dbserver"/>
        <word name="bt"/>
        <word name="orc"/>
        <word name="cachelevel"/>
        <word name="cacheerror"/>
        <word name="index"/>
        <word name="in"/>
        <word name="mod"/>
        <word name="nomod"/>
        <word name="duplic"/>
        <word name="unique"/>
        <word name="upcase"/>
        <word name="noupcase"/>
        <word name="seg"/>
        <word name="null"/>
        <word name="autoinc"/>
        <word name="asc"/>
        <word name="sup"/>
        <word name="desc"/>
        <word name="handle"/>
        <word name="offset"/>
        <word name="length"/>
        <word name="type"/>
        <word name="locase"/>
      </keywords>
      <keywords ignorecase="yes" region="tdiiWord">
        <word name="date"/>
        <word name="longint"/>
        <word name="string"/>
        <word name="double"/>
        <word name="word"/>
        <word name="byte"/>
        <word name="boolean"/>
        <word name="integer"/>
        <word name="extended"/>
        <word name="time"/>
        <word name="lvar"/>
        <word name="astring"/>
        <word name="single"/>
        <word name="char"/>
      </keywords>
      <inherit scheme="atl:qrmPrePro">
        <virtual scheme="atl:qrmPrePro" subst-scheme="dii"/>
      </inherit>

    </scheme>

  </type>

</hrc>
