metanorma-iec 1.3.0 → 1.3.5
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
 - data/.github/workflows/rake.yml +12 -11
 - data/.hound.yml +3 -1
 - data/.rubocop.yml +4 -8
 - data/lib/asciidoctor/iec/biblio.rng +1 -0
 - data/lib/asciidoctor/iec/front.rb +11 -5
 - data/lib/asciidoctor/iec/iec.rng +4 -0
 - data/lib/asciidoctor/iec/iec_intro_en.xml +1 -1
 - data/lib/asciidoctor/iec/isodoc.rng +191 -3
 - data/lib/asciidoctor/iec/isostandard.rng +12 -0
 - data/lib/isodoc/iec/base_convert.rb +20 -14
 - data/lib/isodoc/iec/html_convert.rb +6 -6
 - data/lib/isodoc/iec/iec.international-standard.xsl +533 -67
 - data/lib/isodoc/iec/metadata.rb +1 -1
 - data/lib/isodoc/iec/pdf_convert.rb +1 -1
 - data/lib/isodoc/iec/presentation_xml_convert.rb +17 -17
 - data/lib/isodoc/iec/word_convert.rb +69 -19
 - data/lib/metanorma/iec/version.rb +1 -1
 - data/metanorma-iec.gemspec +1 -1
 - data/spec/asciidoctor/base_spec.rb +818 -801
 - data/spec/asciidoctor/blocks_spec.rb +212 -154
 - data/spec/asciidoctor/section_spec.rb +0 -38
 - data/spec/isodoc/blocks_spec.rb +2 -2
 - data/spec/isodoc/i18n_spec.rb +346 -432
 - data/spec/isodoc/iev_spec.rb +508 -519
 - data/spec/isodoc/inline_spec.rb +2 -2
 - data/spec/isodoc/ref_spec.rb +6 -6
 - data/spec/isodoc/section_spec.rb +334 -339
 - data/spec/isodoc/terms_spec.rb +1 -1
 - metadata +3 -3
 
| 
         @@ -80,25 +80,6 @@ end 
     | 
|
| 
       80 
80 
     | 
    
         
             
                   </terms>
         
     | 
| 
       81 
81 
     | 
    
         
             
                   <clause id="_" obligation="normative"><title>Terms, definitions, symbols and abbreviated terms</title><terms id="_" obligation="normative">
         
     | 
| 
       82 
82 
     | 
    
         
             
                     <title>Normal Terms</title>
         
     | 
| 
       83 
     | 
    
         
            -
                         <p id='_'>For the purposes of this document, the following terms and definitions apply.</p>
         
     | 
| 
       84 
     | 
    
         
            -
                <p id='_'>
         
     | 
| 
       85 
     | 
    
         
            -
                  ISO and IEC maintain terminological databases for use in
         
     | 
| 
       86 
     | 
    
         
            -
                  standardization at the following addresses:
         
     | 
| 
       87 
     | 
    
         
            -
                </p>
         
     | 
| 
       88 
     | 
    
         
            -
                <ul id='_'>
         
     | 
| 
       89 
     | 
    
         
            -
                  <li>
         
     | 
| 
       90 
     | 
    
         
            -
                    <p id='_'>
         
     | 
| 
       91 
     | 
    
         
            -
                      IEC Electropedia: available at
         
     | 
| 
       92 
     | 
    
         
            -
                      <link target='http://www.electropedia.org'/>
         
     | 
| 
       93 
     | 
    
         
            -
                    </p>
         
     | 
| 
       94 
     | 
    
         
            -
                  </li>
         
     | 
| 
       95 
     | 
    
         
            -
                  <li>
         
     | 
| 
       96 
     | 
    
         
            -
                    <p id='_'>
         
     | 
| 
       97 
     | 
    
         
            -
                      ISO Online browsing platform: available at
         
     | 
| 
       98 
     | 
    
         
            -
                      <link target='http://www.iso.org/obp'/>
         
     | 
| 
       99 
     | 
    
         
            -
                    </p>
         
     | 
| 
       100 
     | 
    
         
            -
                  </li>
         
     | 
| 
       101 
     | 
    
         
            -
                </ul>
         
     | 
| 
       102 
83 
     | 
    
         
             
                     <term id="term-term2">
         
     | 
| 
       103 
84 
     | 
    
         
             
                     <preferred>Term2</preferred>
         
     | 
| 
       104 
85 
     | 
    
         
             
                   </term>
         
     | 
| 
         @@ -223,25 +204,6 @@ end 
     | 
|
| 
       223 
204 
     | 
    
         
             
                         <title>Terms, definitions, symbols and abbreviated terms</title>
         
     | 
| 
       224 
205 
     | 
    
         
             
                         <terms id='_' obligation='normative'>
         
     | 
| 
       225 
206 
     | 
    
         
             
                           <title>Normal Terms</title>
         
     | 
| 
       226 
     | 
    
         
            -
                            <p id='_'>For the purposes of this document, the following terms and definitions apply.</p>
         
     | 
| 
       227 
     | 
    
         
            -
             <p id='_'>
         
     | 
| 
       228 
     | 
    
         
            -
               ISO and IEC maintain terminological databases for use in
         
     | 
| 
       229 
     | 
    
         
            -
               standardization at the following addresses:
         
     | 
| 
       230 
     | 
    
         
            -
             </p>
         
     | 
| 
       231 
     | 
    
         
            -
             <ul id='_'>
         
     | 
| 
       232 
     | 
    
         
            -
               <li>
         
     | 
| 
       233 
     | 
    
         
            -
                 <p id='_'>
         
     | 
| 
       234 
     | 
    
         
            -
                   IEC Electropedia: available at
         
     | 
| 
       235 
     | 
    
         
            -
                   <link target='http://www.electropedia.org'/>
         
     | 
| 
       236 
     | 
    
         
            -
                 </p>
         
     | 
| 
       237 
     | 
    
         
            -
               </li>
         
     | 
| 
       238 
     | 
    
         
            -
               <li>
         
     | 
| 
       239 
     | 
    
         
            -
                 <p id='_'>
         
     | 
| 
       240 
     | 
    
         
            -
                   ISO Online browsing platform: available at
         
     | 
| 
       241 
     | 
    
         
            -
                   <link target='http://www.iso.org/obp'/>
         
     | 
| 
       242 
     | 
    
         
            -
                 </p>
         
     | 
| 
       243 
     | 
    
         
            -
               </li>
         
     | 
| 
       244 
     | 
    
         
            -
             </ul>
         
     | 
| 
       245 
207 
     | 
    
         
             
                           <term id='term-term2'>
         
     | 
| 
       246 
208 
     | 
    
         
             
                             <preferred>Term2</preferred>
         
     | 
| 
       247 
209 
     | 
    
         
             
                           </term>
         
     | 
    
        data/spec/isodoc/blocks_spec.rb
    CHANGED
    
    | 
         @@ -179,7 +179,7 @@ RSpec.describe IsoDoc::Iec do 
     | 
|
| 
       179 
179 
     | 
    
         
             
                INPUT
         
     | 
| 
       180 
180 
     | 
    
         
             
                <iso-standard xmlns='http://riboseinc.com/isoxml' type="presentation">
         
     | 
| 
       181 
181 
     | 
    
         
             
                     <preface>
         
     | 
| 
       182 
     | 
    
         
            -
                       <foreword>
         
     | 
| 
      
 182 
     | 
    
         
            +
                       <foreword displayorder="1">
         
     | 
| 
       183 
183 
     | 
    
         
             
                         <p>
         
     | 
| 
       184 
184 
     | 
    
         
             
                           <xref target='N1'>Clause 1, Equation (1)</xref>
         
     | 
| 
       185 
185 
     | 
    
         
             
                           <xref target='N2'>1.1, Inequality (2)</xref>
         
     | 
| 
         @@ -187,7 +187,7 @@ RSpec.describe IsoDoc::Iec do 
     | 
|
| 
       187 
187 
     | 
    
         
             
                       </foreword>
         
     | 
| 
       188 
188 
     | 
    
         
             
                     </preface>
         
     | 
| 
       189 
189 
     | 
    
         
             
                     <sections>
         
     | 
| 
       190 
     | 
    
         
            -
                       <clause id='intro'>
         
     | 
| 
      
 190 
     | 
    
         
            +
                       <clause id='intro' displayorder="2">
         
     | 
| 
       191 
191 
     | 
    
         
             
                         <title depth='1'>
         
     | 
| 
       192 
192 
     | 
    
         
             
                           1
         
     | 
| 
       193 
193 
     | 
    
         
             
                           <tab/>
         
     | 
    
        data/spec/isodoc/i18n_spec.rb
    CHANGED
    
    | 
         @@ -75,164 +75,156 @@ RSpec.describe IsoDoc do 
     | 
|
| 
       75 
75 
     | 
    
         
             
                   </clause>
         
     | 
| 
       76 
76 
     | 
    
         
             
                   </bibliography>
         
     | 
| 
       77 
77 
     | 
    
         
             
                   </iso-standard>
         
     | 
| 
       78 
     | 
    
         
            -
             
     | 
| 
      
 78 
     | 
    
         
            +
                INPUT
         
     | 
| 
       79 
79 
     | 
    
         | 
| 
       80 
     | 
    
         
            -
             
     | 
| 
       81 
     | 
    
         
            -
             
     | 
| 
       82 
     | 
    
         
            -
             
     | 
| 
       83 
     | 
    
         
            -
             
     | 
| 
       84 
     | 
    
         
            -
             
     | 
| 
       85 
     | 
    
         
            -
             
     | 
| 
       86 
     | 
    
         
            -
             
     | 
| 
       87 
     | 
    
         
            -
             
     | 
| 
       88 
     | 
    
         
            -
             
     | 
| 
       89 
     | 
    
         
            -
             
     | 
| 
       90 
     | 
    
         
            -
             
     | 
| 
       91 
     | 
    
         
            -
            < 
     | 
| 
       92 
     | 
    
         
            -
            < 
     | 
| 
       93 
     | 
    
         
            -
            < 
     | 
| 
       94 
     | 
    
         
            -
            < 
     | 
| 
       95 
     | 
    
         
            -
            </ 
     | 
| 
       96 
     | 
    
         
            -
             
     | 
| 
       97 
     | 
    
         
            -
             
     | 
| 
       98 
     | 
    
         
            -
                    
     | 
| 
       99 
     | 
    
         
            -
             
     | 
| 
       100 
     | 
    
         
            -
             
     | 
| 
       101 
     | 
    
         
            -
             
     | 
| 
       102 
     | 
    
         
            -
                     < 
     | 
| 
       103 
     | 
    
         
            -
             
     | 
| 
       104 
     | 
    
         
            -
             
     | 
| 
       105 
     | 
    
         
            -
             
     | 
| 
       106 
     | 
    
         
            -
             
     | 
| 
       107 
     | 
    
         
            -
             
     | 
| 
       108 
     | 
    
         
            -
             
     | 
| 
       109 
     | 
    
         
            -
             
     | 
| 
       110 
     | 
    
         
            -
             
     | 
| 
       111 
     | 
    
         
            -
             
     | 
| 
       112 
     | 
    
         
            -
             
     | 
| 
       113 
     | 
    
         
            -
             
     | 
| 
       114 
     | 
    
         
            -
             
     | 
| 
       115 
     | 
    
         
            -
             
     | 
| 
       116 
     | 
    
         
            -
             
     | 
| 
       117 
     | 
    
         
            -
             
     | 
| 
       118 
     | 
    
         
            -
             
     | 
| 
       119 
     | 
    
         
            -
             
     | 
| 
       120 
     | 
    
         
            -
             
     | 
| 
       121 
     | 
    
         
            -
             
     | 
| 
       122 
     | 
    
         
            -
             
     | 
| 
       123 
     | 
    
         
            -
             
     | 
| 
       124 
     | 
    
         
            -
             
     | 
| 
       125 
     | 
    
         
            -
             
     | 
| 
       126 
     | 
    
         
            -
             
     | 
| 
       127 
     | 
    
         
            -
             
     | 
| 
       128 
     | 
    
         
            -
             
     | 
| 
       129 
     | 
    
         
            -
             
     | 
| 
       130 
     | 
    
         
            -
             
     | 
| 
       131 
     | 
    
         
            -
             
     | 
| 
       132 
     | 
    
         
            -
             
     | 
| 
       133 
     | 
    
         
            -
             
     | 
| 
       134 
     | 
    
         
            -
             
     | 
| 
       135 
     | 
    
         
            -
             
     | 
| 
       136 
     | 
    
         
            -
             
     | 
| 
       137 
     | 
    
         
            -
             
     | 
| 
       138 
     | 
    
         
            -
             
     | 
| 
       139 
     | 
    
         
            -
             
     | 
| 
       140 
     | 
    
         
            -
             
     | 
| 
       141 
     | 
    
         
            -
             
     | 
| 
       142 
     | 
    
         
            -
             
     | 
| 
       143 
     | 
    
         
            -
             
     | 
| 
       144 
     | 
    
         
            -
             
     | 
| 
       145 
     | 
    
         
            -
             
     | 
| 
       146 
     | 
    
         
            -
             
     | 
| 
       147 
     | 
    
         
            -
             
     | 
| 
       148 
     | 
    
         
            -
             
     | 
| 
       149 
     | 
    
         
            -
             
     | 
| 
       150 
     | 
    
         
            -
             
     | 
| 
       151 
     | 
    
         
            -
             
     | 
| 
       152 
     | 
    
         
            -
                      <title depth="1">Bibliography</title>
         
     | 
| 
       153 
     | 
    
         
            -
                      <references id="T" obligation="informative" normative="false">
         
     | 
| 
       154 
     | 
    
         
            -
                      <title depth="2">Bibliography Subsection</title>
         
     | 
| 
       155 
     | 
    
         
            -
                    </references>
         
     | 
| 
       156 
     | 
    
         
            -
                    </clause>
         
     | 
| 
       157 
     | 
    
         
            -
                    </bibliography>
         
     | 
| 
       158 
     | 
    
         
            -
                    </iso-standard>
         
     | 
| 
       159 
     | 
    
         
            -
                    OUTPUT
         
     | 
| 
       160 
     | 
    
         
            -
             
     | 
| 
       161 
     | 
    
         
            -
                    html = <<~OUTPUT
         
     | 
| 
       162 
     | 
    
         
            -
                    #{HTML_HDR}
         
     | 
| 
       163 
     | 
    
         
            -
                         <div>
         
     | 
| 
       164 
     | 
    
         
            -
                           <h1 class="ForewordTitle">FOREWORD</h1>
         
     | 
| 
       165 
     | 
    
         
            -
                           <div class="boilerplate_legal"/>
         
     | 
| 
       166 
     | 
    
         
            -
                           <p id="A">This is a preamble</p>
         
     | 
| 
       167 
     | 
    
         
            -
                         </div>
         
     | 
| 
       168 
     | 
    
         
            -
                         <br/>
         
     | 
| 
       169 
     | 
    
         
            -
                         <div class="Section3" id="B">
         
     | 
| 
       170 
     | 
    
         
            -
                           <h1 class="IntroTitle">0  Introduction</h1>
         
     | 
| 
       171 
     | 
    
         
            -
                           <div id="C"><h2>0.1  Introduction Subsection</h2>
         
     | 
| 
       172 
     | 
    
         
            -
             
     | 
| 
       173 
     | 
    
         
            -
                    </div>
         
     | 
| 
       174 
     | 
    
         
            -
                           <p>This is patent boilerplate</p>
         
     | 
| 
       175 
     | 
    
         
            -
                         </div>
         
     | 
| 
       176 
     | 
    
         
            -
                         #{IEC_TITLE1}
         
     | 
| 
       177 
     | 
    
         
            -
                         <div id="D">
         
     | 
| 
       178 
     | 
    
         
            -
                           <h1>1  Scope</h1>
         
     | 
| 
       179 
     | 
    
         
            -
                           <p id="E">Text</p>
         
     | 
| 
       180 
     | 
    
         
            -
                         </div>
         
     | 
| 
       181 
     | 
    
         
            -
                         <div>
         
     | 
| 
       182 
     | 
    
         
            -
                           <h1>2  Normative References</h1>
         
     | 
| 
       183 
     | 
    
         
            -
                         </div>
         
     | 
| 
       184 
     | 
    
         
            -
                         <div id="H"><h1>3  Terms, definitions, symbols and abbreviated terms</h1>
         
     | 
| 
       185 
     | 
    
         
            -
                   <div id="I"><h2>3.1  Normal Terms</h2>
         
     | 
| 
       186 
     | 
    
         
            -
             
     | 
| 
       187 
     | 
    
         
            -
                      <p class="TermNum" id="J">3.1.1</p>
         
     | 
| 
       188 
     | 
    
         
            -
                      <p class="Terms" style="text-align:left;">Term2</p>
         
     | 
| 
       189 
     | 
    
         
            -
             
     | 
| 
       190 
     | 
    
         
            -
                    </div><div id="K"><h2>3.2</h2>
         
     | 
| 
       191 
     | 
    
         
            -
                      <dl><dt><p>Symbol</p></dt><dd>Definition</dd></dl>
         
     | 
| 
       192 
     | 
    
         
            -
                    </div></div>
         
     | 
| 
       193 
     | 
    
         
            -
                         <div id="L" class="Symbols">
         
     | 
| 
       194 
     | 
    
         
            -
                           <h1>4</h1>
         
     | 
| 
       195 
     | 
    
         
            -
                           <dl>
         
     | 
| 
       196 
     | 
    
         
            -
                             <dt>
         
     | 
| 
       197 
     | 
    
         
            -
                               <p>Symbol</p>
         
     | 
| 
       198 
     | 
    
         
            -
                             </dt>
         
     | 
| 
       199 
     | 
    
         
            -
                             <dd>Definition</dd>
         
     | 
| 
       200 
     | 
    
         
            -
                           </dl>
         
     | 
| 
       201 
     | 
    
         
            -
                         </div>
         
     | 
| 
       202 
     | 
    
         
            -
                         <div id="M">
         
     | 
| 
       203 
     | 
    
         
            -
                           <h1>5  Clause 4</h1>
         
     | 
| 
       204 
     | 
    
         
            -
                           <div id="N"><h2>5.1  Introduction</h2>
         
     | 
| 
       205 
     | 
    
         
            -
             
     | 
| 
       206 
     | 
    
         
            -
                    </div>
         
     | 
| 
       207 
     | 
    
         
            -
                           <div id="O"><h2>5.2  Clause 4.2</h2>
         
     | 
| 
       208 
     | 
    
         
            -
             
     | 
| 
       209 
     | 
    
         
            -
                    </div>
         
     | 
| 
       210 
     | 
    
         
            -
                         </div>
         
     | 
| 
       211 
     | 
    
         
            -
                         <br/>
         
     | 
| 
       212 
     | 
    
         
            -
                         <div id="P" class="Section3">
         
     | 
| 
       213 
     | 
    
         
            -
                           <h1 class="Annex"><b>Annex A</b><br/>(normative)<br/><br/><b>Annex</b></h1>
         
     | 
| 
       214 
     | 
    
         
            -
                           <div id="Q"><h2>A.1  Annex A.1</h2>
         
     | 
| 
       215 
     | 
    
         
            -
             
     | 
| 
       216 
     | 
    
         
            -
                      <div id="Q1"><h3>A.1.1  Annex A.1a</h3>
         
     | 
| 
      
 80 
     | 
    
         
            +
                presxml = <<~OUTPUT
         
     | 
| 
      
 81 
     | 
    
         
            +
                  <iso-standard xmlns="http://riboseinc.com/isoxml" type="presentation">
         
     | 
| 
      
 82 
     | 
    
         
            +
                  <bibdata>
         
     | 
| 
      
 83 
     | 
    
         
            +
                  <docnumber>1</docnumber>
         
     | 
| 
      
 84 
     | 
    
         
            +
                  <language current="true">en</language>
         
     | 
| 
      
 85 
     | 
    
         
            +
                  <ext>
         
     | 
| 
      
 86 
     | 
    
         
            +
                  <doctype language="">international-standard</doctype><doctype language="fr">Norme international</doctype><doctype language="en">International Standard</doctype>
         
     | 
| 
      
 87 
     | 
    
         
            +
                  <horizontal language="">true</horizontal><horizontal language="fr">Norme horizontale</horizontal><horizontal language="en">Horizontal Standard</horizontal>
         
     | 
| 
      
 88 
     | 
    
         
            +
                  <function language="">emc</function><function language="fr">Publication fondamentale en CEM</function><function language="en">Basic EMC Publication</function>
         
     | 
| 
      
 89 
     | 
    
         
            +
                  </ext>
         
     | 
| 
      
 90 
     | 
    
         
            +
                  </bibdata>
         
     | 
| 
      
 91 
     | 
    
         
            +
                  <preface>
         
     | 
| 
      
 92 
     | 
    
         
            +
                  <foreword obligation="informative" displayorder="1">
         
     | 
| 
      
 93 
     | 
    
         
            +
                     <title>Foreword</title>
         
     | 
| 
      
 94 
     | 
    
         
            +
                     <p id="A">This is a preamble</p>
         
     | 
| 
      
 95 
     | 
    
         
            +
                   </foreword>
         
     | 
| 
      
 96 
     | 
    
         
            +
                    <introduction id="B" obligation="informative" displayorder="2"><title depth="1">0<tab/>Introduction</title><clause id="C" inline-header="false" obligation="informative">
         
     | 
| 
      
 97 
     | 
    
         
            +
                     <title depth="2">0.1<tab/>Introduction Subsection</title>
         
     | 
| 
      
 98 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 99 
     | 
    
         
            +
                   <p>This is patent boilerplate</p>
         
     | 
| 
      
 100 
     | 
    
         
            +
                   </introduction></preface><sections>
         
     | 
| 
      
 101 
     | 
    
         
            +
                   <clause id="D" obligation="normative" type="scope" displayorder="3">
         
     | 
| 
      
 102 
     | 
    
         
            +
                     <title depth="1">1<tab/>Scope</title>
         
     | 
| 
      
 103 
     | 
    
         
            +
                     <p id="E">Text</p>
         
     | 
| 
      
 104 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 105 
     | 
    
         
            +
                   <clause id="H" obligation="normative" displayorder="5"><title depth="1">3<tab/>Terms, definitions, symbols and abbreviated terms</title><terms id="I" obligation="normative">
         
     | 
| 
      
 106 
     | 
    
         
            +
                     <title depth="2">3.1<tab/>Normal Terms</title>
         
     | 
| 
      
 107 
     | 
    
         
            +
                     <term id="J"><name>3.1.1</name>
         
     | 
| 
      
 108 
     | 
    
         
            +
                     <preferred>Term2</preferred>
         
     | 
| 
      
 109 
     | 
    
         
            +
                   </term>
         
     | 
| 
      
 110 
     | 
    
         
            +
                   </terms>
         
     | 
| 
      
 111 
     | 
    
         
            +
                   <definitions id="K"><title>3.2</title>
         
     | 
| 
      
 112 
     | 
    
         
            +
                     <dl>
         
     | 
| 
      
 113 
     | 
    
         
            +
                     <dt>Symbol</dt>
         
     | 
| 
      
 114 
     | 
    
         
            +
                     <dd>Definition</dd>
         
     | 
| 
      
 115 
     | 
    
         
            +
                     </dl>
         
     | 
| 
      
 116 
     | 
    
         
            +
                   </definitions>
         
     | 
| 
      
 117 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 118 
     | 
    
         
            +
                   <definitions id="L" displayorder="6"><title>4</title>
         
     | 
| 
      
 119 
     | 
    
         
            +
                     <dl>
         
     | 
| 
      
 120 
     | 
    
         
            +
                     <dt>Symbol</dt>
         
     | 
| 
      
 121 
     | 
    
         
            +
                     <dd>Definition</dd>
         
     | 
| 
      
 122 
     | 
    
         
            +
                     </dl>
         
     | 
| 
      
 123 
     | 
    
         
            +
                   </definitions>
         
     | 
| 
      
 124 
     | 
    
         
            +
                   <clause id="M" inline-header="false" obligation="normative" displayorder="7"><title depth="1">5<tab/>Clause 4</title><clause id="N" inline-header="false" obligation="normative">
         
     | 
| 
      
 125 
     | 
    
         
            +
                     <title depth="2">5.1<tab/>Introduction</title>
         
     | 
| 
      
 126 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 127 
     | 
    
         
            +
                   <clause id="O" inline-header="false" obligation="normative">
         
     | 
| 
      
 128 
     | 
    
         
            +
                     <title depth="2">5.2<tab/>Clause 4.2</title>
         
     | 
| 
      
 129 
     | 
    
         
            +
                   </clause></clause>
         
     | 
| 
      
 130 
     | 
    
         
            +
                   </sections><annex id="P" inline-header="false" obligation="normative" displayorder="8">
         
     | 
| 
      
 131 
     | 
    
         
            +
                     <title><strong>Annex A</strong><br/>(normative)<br/><br/><strong>Annex</strong></title>
         
     | 
| 
      
 132 
     | 
    
         
            +
                     <clause id="Q" inline-header="false" obligation="normative">
         
     | 
| 
      
 133 
     | 
    
         
            +
                     <title depth="2">A.1<tab/>Annex A.1</title>
         
     | 
| 
      
 134 
     | 
    
         
            +
                     <clause id="Q1" inline-header="false" obligation="normative">
         
     | 
| 
      
 135 
     | 
    
         
            +
                     <title depth="3">A.1.1<tab/>Annex A.1a</title>
         
     | 
| 
      
 136 
     | 
    
         
            +
                     </clause>
         
     | 
| 
      
 137 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 138 
     | 
    
         
            +
                   <appendix id="Q2" inline-header="false" obligation="normative">
         
     | 
| 
      
 139 
     | 
    
         
            +
                     <title depth="2">Appendix 1<tab/>An Appendix</title>
         
     | 
| 
      
 140 
     | 
    
         
            +
                   </appendix>
         
     | 
| 
      
 141 
     | 
    
         
            +
                   </annex><bibliography><references id="R" obligation="informative" normative="true" displayorder="4">
         
     | 
| 
      
 142 
     | 
    
         
            +
                     <title depth="1">2<tab/>Normative References</title>
         
     | 
| 
      
 143 
     | 
    
         
            +
                   </references><clause id="S" obligation="informative" displayorder="9">
         
     | 
| 
      
 144 
     | 
    
         
            +
                     <title depth="1">Bibliography</title>
         
     | 
| 
      
 145 
     | 
    
         
            +
                     <references id="T" obligation="informative" normative="false">
         
     | 
| 
      
 146 
     | 
    
         
            +
                     <title depth="2">Bibliography Subsection</title>
         
     | 
| 
      
 147 
     | 
    
         
            +
                   </references>
         
     | 
| 
      
 148 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 149 
     | 
    
         
            +
                   </bibliography>
         
     | 
| 
      
 150 
     | 
    
         
            +
                   </iso-standard>
         
     | 
| 
      
 151 
     | 
    
         
            +
                OUTPUT
         
     | 
| 
       217 
152 
     | 
    
         | 
| 
      
 153 
     | 
    
         
            +
                html = <<~OUTPUT
         
     | 
| 
      
 154 
     | 
    
         
            +
                   #{HTML_HDR}
         
     | 
| 
      
 155 
     | 
    
         
            +
                        <div>
         
     | 
| 
      
 156 
     | 
    
         
            +
                          <h1 class="ForewordTitle">FOREWORD</h1>
         
     | 
| 
      
 157 
     | 
    
         
            +
                          <div class="boilerplate_legal"/>
         
     | 
| 
      
 158 
     | 
    
         
            +
                          <p id="A">This is a preamble</p>
         
     | 
| 
      
 159 
     | 
    
         
            +
                        </div>
         
     | 
| 
      
 160 
     | 
    
         
            +
                        <br/>
         
     | 
| 
      
 161 
     | 
    
         
            +
                        <div class="Section3" id="B">
         
     | 
| 
      
 162 
     | 
    
         
            +
                          <h1 class="IntroTitle">0  Introduction</h1>
         
     | 
| 
      
 163 
     | 
    
         
            +
                          <div id="C"><h2>0.1  Introduction Subsection</h2>
         
     | 
| 
      
 164 
     | 
    
         
            +
             
     | 
| 
      
 165 
     | 
    
         
            +
                   </div>
         
     | 
| 
      
 166 
     | 
    
         
            +
                          <p>This is patent boilerplate</p>
         
     | 
| 
      
 167 
     | 
    
         
            +
                        </div>
         
     | 
| 
      
 168 
     | 
    
         
            +
                        #{IEC_TITLE1}
         
     | 
| 
      
 169 
     | 
    
         
            +
                        <div id="D">
         
     | 
| 
      
 170 
     | 
    
         
            +
                          <h1>1  Scope</h1>
         
     | 
| 
      
 171 
     | 
    
         
            +
                          <p id="E">Text</p>
         
     | 
| 
      
 172 
     | 
    
         
            +
                        </div>
         
     | 
| 
      
 173 
     | 
    
         
            +
                        <div>
         
     | 
| 
      
 174 
     | 
    
         
            +
                          <h1>2  Normative References</h1>
         
     | 
| 
      
 175 
     | 
    
         
            +
                        </div>
         
     | 
| 
      
 176 
     | 
    
         
            +
                        <div id="H"><h1>3  Terms, definitions, symbols and abbreviated terms</h1>
         
     | 
| 
      
 177 
     | 
    
         
            +
                  <div id="I"><h2>3.1  Normal Terms</h2>
         
     | 
| 
      
 178 
     | 
    
         
            +
             
     | 
| 
      
 179 
     | 
    
         
            +
                     <p class="TermNum" id="J">3.1.1</p>
         
     | 
| 
      
 180 
     | 
    
         
            +
                     <p class="Terms" style="text-align:left;">Term2</p>
         
     | 
| 
      
 181 
     | 
    
         
            +
             
     | 
| 
      
 182 
     | 
    
         
            +
                   </div><div id="K"><h2>3.2</h2>
         
     | 
| 
      
 183 
     | 
    
         
            +
                     <dl><dt><p>Symbol</p></dt><dd>Definition</dd></dl>
         
     | 
| 
      
 184 
     | 
    
         
            +
                   </div></div>
         
     | 
| 
      
 185 
     | 
    
         
            +
                        <div id="L" class="Symbols">
         
     | 
| 
      
 186 
     | 
    
         
            +
                          <h1>4</h1>
         
     | 
| 
      
 187 
     | 
    
         
            +
                          <dl>
         
     | 
| 
      
 188 
     | 
    
         
            +
                            <dt>
         
     | 
| 
      
 189 
     | 
    
         
            +
                              <p>Symbol</p>
         
     | 
| 
      
 190 
     | 
    
         
            +
                            </dt>
         
     | 
| 
      
 191 
     | 
    
         
            +
                            <dd>Definition</dd>
         
     | 
| 
      
 192 
     | 
    
         
            +
                          </dl>
         
     | 
| 
      
 193 
     | 
    
         
            +
                        </div>
         
     | 
| 
      
 194 
     | 
    
         
            +
                        <div id="M">
         
     | 
| 
      
 195 
     | 
    
         
            +
                          <h1>5  Clause 4</h1>
         
     | 
| 
      
 196 
     | 
    
         
            +
                          <div id="N"><h2>5.1  Introduction</h2>
         
     | 
| 
      
 197 
     | 
    
         
            +
             
     | 
| 
      
 198 
     | 
    
         
            +
                   </div>
         
     | 
| 
      
 199 
     | 
    
         
            +
                          <div id="O"><h2>5.2  Clause 4.2</h2>
         
     | 
| 
      
 200 
     | 
    
         
            +
             
     | 
| 
      
 201 
     | 
    
         
            +
                   </div>
         
     | 
| 
      
 202 
     | 
    
         
            +
                        </div>
         
     | 
| 
      
 203 
     | 
    
         
            +
                        <br/>
         
     | 
| 
      
 204 
     | 
    
         
            +
                        <div id="P" class="Section3">
         
     | 
| 
      
 205 
     | 
    
         
            +
                          <h1 class="Annex"><b>Annex A</b><br/>(normative)<br/><br/><b>Annex</b></h1>
         
     | 
| 
      
 206 
     | 
    
         
            +
                          <div id="Q"><h2>A.1  Annex A.1</h2>
         
     | 
| 
      
 207 
     | 
    
         
            +
             
     | 
| 
      
 208 
     | 
    
         
            +
                     <div id="Q1"><h3>A.1.1  Annex A.1a</h3>
         
     | 
| 
      
 209 
     | 
    
         
            +
             
     | 
| 
      
 210 
     | 
    
         
            +
                     </div>
         
     | 
| 
      
 211 
     | 
    
         
            +
                   </div>
         
     | 
| 
      
 212 
     | 
    
         
            +
                          <div id="Q2"><h2>Appendix 1  An Appendix</h2>
         
     | 
| 
      
 213 
     | 
    
         
            +
             
     | 
| 
      
 214 
     | 
    
         
            +
                   </div>
         
     | 
| 
      
 215 
     | 
    
         
            +
                        </div>
         
     | 
| 
      
 216 
     | 
    
         
            +
                        <br/>
         
     | 
| 
      
 217 
     | 
    
         
            +
                        <div>
         
     | 
| 
      
 218 
     | 
    
         
            +
                          <h1 class="Section3">Bibliography</h1>
         
     | 
| 
      
 219 
     | 
    
         
            +
                          <div>
         
     | 
| 
      
 220 
     | 
    
         
            +
                            <h2 class="Section3">Bibliography Subsection</h2>
         
     | 
| 
      
 221 
     | 
    
         
            +
                          </div>
         
     | 
| 
      
 222 
     | 
    
         
            +
                        </div>
         
     | 
| 
       218 
223 
     | 
    
         
             
                      </div>
         
     | 
| 
       219 
     | 
    
         
            -
                    </ 
     | 
| 
       220 
     | 
    
         
            -
             
     | 
| 
       221 
     | 
    
         
            -
             
     | 
| 
       222 
     | 
    
         
            -
                    </div>
         
     | 
| 
       223 
     | 
    
         
            -
                         </div>
         
     | 
| 
       224 
     | 
    
         
            -
                         <br/>
         
     | 
| 
       225 
     | 
    
         
            -
                         <div>
         
     | 
| 
       226 
     | 
    
         
            -
                           <h1 class="Section3">Bibliography</h1>
         
     | 
| 
       227 
     | 
    
         
            -
                           <div>
         
     | 
| 
       228 
     | 
    
         
            -
                             <h2 class="Section3">Bibliography Subsection</h2>
         
     | 
| 
       229 
     | 
    
         
            -
                           </div>
         
     | 
| 
       230 
     | 
    
         
            -
                         </div>
         
     | 
| 
       231 
     | 
    
         
            -
                       </div>
         
     | 
| 
       232 
     | 
    
         
            -
                     </body>
         
     | 
| 
       233 
     | 
    
         
            -
                   </html>
         
     | 
| 
      
 224 
     | 
    
         
            +
                    </body>
         
     | 
| 
      
 225 
     | 
    
         
            +
                  </html>
         
     | 
| 
       234 
226 
     | 
    
         
             
                OUTPUT
         
     | 
| 
       235 
     | 
    
         
            -
             
     | 
| 
      
 227 
     | 
    
         
            +
                expect((IsoDoc::Iec::PresentationXMLConvert.new({}).convert("test", input, true).sub(%r{<localized-strings>.*</localized-strings>}m, ""))).to be_equivalent_to xmlpp(presxml)
         
     | 
| 
       236 
228 
     | 
    
         
             
                expect(xmlpp(IsoDoc::Iec::HtmlConvert.new({}).convert("test", presxml, true))).to be_equivalent_to xmlpp(html)
         
     | 
| 
       237 
229 
     | 
    
         
             
              end
         
     | 
| 
       238 
230 
     | 
    
         | 
| 
         @@ -304,141 +296,70 @@ RSpec.describe IsoDoc do 
     | 
|
| 
       304 
296 
     | 
    
         
             
                   </clause>
         
     | 
| 
       305 
297 
     | 
    
         
             
                   </bibliography>
         
     | 
| 
       306 
298 
     | 
    
         
             
                   </iso-standard>
         
     | 
| 
       307 
     | 
    
         
            -
             
     | 
| 
       308 
     | 
    
         
            -
             
     | 
| 
       309 
     | 
    
         
            -
             
     | 
| 
       310 
     | 
    
         
            -
             
     | 
| 
       311 
     | 
    
         
            -
             
     | 
| 
       312 
     | 
    
         
            -
             
     | 
| 
       313 
     | 
    
         
            -
             
     | 
| 
       314 
     | 
    
         
            -
             
     | 
| 
       315 
     | 
    
         
            -
             
     | 
| 
       316 
     | 
    
         
            -
             
     | 
| 
       317 
     | 
    
         
            -
             
     | 
| 
       318 
     | 
    
         
            -
             
     | 
| 
       319 
     | 
    
         
            -
             
     | 
| 
       320 
     | 
    
         
            -
             
     | 
| 
       321 
     | 
    
         
            -
             
     | 
| 
       322 
     | 
    
         
            -
             
     | 
| 
       323 
     | 
    
         
            -
             
     | 
| 
       324 
     | 
    
         
            -
             
     | 
| 
       325 
     | 
    
         
            -
             
     | 
| 
       326 
     | 
    
         
            -
             
     | 
| 
       327 
     | 
    
         
            -
             
     | 
| 
       328 
     | 
    
         
            -
             
     | 
| 
       329 
     | 
    
         
            -
             
     | 
| 
       330 
     | 
    
         
            -
             
     | 
| 
       331 
     | 
    
         
            -
             
     | 
| 
       332 
     | 
    
         
            -
             
     | 
| 
       333 
     | 
    
         
            -
                     < 
     | 
| 
       334 
     | 
    
         
            -
             
     | 
| 
       335 
     | 
    
         
            -
             
     | 
| 
       336 
     | 
    
         
            -
             
     | 
| 
       337 
     | 
    
         
            -
             
     | 
| 
       338 
     | 
    
         
            -
             
     | 
| 
       339 
     | 
    
         
            -
             
     | 
| 
       340 
     | 
    
         
            -
             
     | 
| 
       341 
     | 
    
         
            -
             
     | 
| 
       342 
     | 
    
         
            -
             
     | 
| 
       343 
     | 
    
         
            -
             
     | 
| 
       344 
     | 
    
         
            -
             
     | 
| 
       345 
     | 
    
         
            -
             
     | 
| 
       346 
     | 
    
         
            -
             
     | 
| 
       347 
     | 
    
         
            -
             
     | 
| 
       348 
     | 
    
         
            -
             
     | 
| 
       349 
     | 
    
         
            -
             
     | 
| 
       350 
     | 
    
         
            -
             
     | 
| 
       351 
     | 
    
         
            -
             
     | 
| 
       352 
     | 
    
         
            -
             
     | 
| 
       353 
     | 
    
         
            -
             
     | 
| 
       354 
     | 
    
         
            -
             
     | 
| 
       355 
     | 
    
         
            -
             
     | 
| 
       356 
     | 
    
         
            -
             
     | 
| 
       357 
     | 
    
         
            -
             
     | 
| 
       358 
     | 
    
         
            -
             
     | 
| 
       359 
     | 
    
         
            -
             
     | 
| 
       360 
     | 
    
         
            -
             
     | 
| 
       361 
     | 
    
         
            -
             
     | 
| 
       362 
     | 
    
         
            -
             
     | 
| 
       363 
     | 
    
         
            -
             
     | 
| 
       364 
     | 
    
         
            -
             
     | 
| 
       365 
     | 
    
         
            -
             
     | 
| 
       366 
     | 
    
         
            -
             
     | 
| 
       367 
     | 
    
         
            -
             
     | 
| 
       368 
     | 
    
         
            -
             
     | 
| 
       369 
     | 
    
         
            -
             
     | 
| 
       370 
     | 
    
         
            -
             
     | 
| 
       371 
     | 
    
         
            -
                           <dd>Definition</dd>
         
     | 
| 
       372 
     | 
    
         
            -
                         </dl>
         
     | 
| 
       373 
     | 
    
         
            -
                       </definitions>
         
     | 
| 
       374 
     | 
    
         
            -
                       <clause id='M' inline-header='false' obligation='normative'>
         
     | 
| 
       375 
     | 
    
         
            -
                         <title depth='1'>
         
     | 
| 
       376 
     | 
    
         
            -
                           5
         
     | 
| 
       377 
     | 
    
         
            -
                           <tab/>
         
     | 
| 
       378 
     | 
    
         
            -
                           Clause 4
         
     | 
| 
       379 
     | 
    
         
            -
                         </title>
         
     | 
| 
       380 
     | 
    
         
            -
                         <clause id='N' inline-header='false' obligation='normative'>
         
     | 
| 
       381 
     | 
    
         
            -
                           <title depth='2'>
         
     | 
| 
       382 
     | 
    
         
            -
                             5.1
         
     | 
| 
       383 
     | 
    
         
            -
                             <tab/>
         
     | 
| 
       384 
     | 
    
         
            -
                             Introduction
         
     | 
| 
       385 
     | 
    
         
            -
                           </title>
         
     | 
| 
       386 
     | 
    
         
            -
                         </clause>
         
     | 
| 
       387 
     | 
    
         
            -
                         <clause id='O' inline-header='false' obligation='normative'>
         
     | 
| 
       388 
     | 
    
         
            -
                           <title depth='2'>
         
     | 
| 
       389 
     | 
    
         
            -
                             5.2
         
     | 
| 
       390 
     | 
    
         
            -
                             <tab/>
         
     | 
| 
       391 
     | 
    
         
            -
                             Clause 4.2
         
     | 
| 
       392 
     | 
    
         
            -
                           </title>
         
     | 
| 
       393 
     | 
    
         
            -
                         </clause>
         
     | 
| 
       394 
     | 
    
         
            -
                       </clause>
         
     | 
| 
       395 
     | 
    
         
            -
                     </sections>
         
     | 
| 
       396 
     | 
    
         
            -
                     <annex id='P' inline-header='false' obligation='normative'>
         
     | 
| 
       397 
     | 
    
         
            -
                       <title>
         
     | 
| 
       398 
     | 
    
         
            -
                         <strong>Annex A</strong>
         
     | 
| 
       399 
     | 
    
         
            -
                         <br/>
         
     | 
| 
       400 
     | 
    
         
            -
                         (normative)
         
     | 
| 
       401 
     | 
    
         
            -
                         <br/>
         
     | 
| 
       402 
     | 
    
         
            -
                         <br/>
         
     | 
| 
       403 
     | 
    
         
            -
                         <strong>Annex</strong>
         
     | 
| 
       404 
     | 
    
         
            -
                       </title>
         
     | 
| 
       405 
     | 
    
         
            -
                       <clause id='Q' inline-header='false' obligation='normative'>
         
     | 
| 
       406 
     | 
    
         
            -
                         <title depth='2'>
         
     | 
| 
       407 
     | 
    
         
            -
                           A.1
         
     | 
| 
       408 
     | 
    
         
            -
                           <tab/>
         
     | 
| 
       409 
     | 
    
         
            -
                           Annex A.1
         
     | 
| 
       410 
     | 
    
         
            -
                         </title>
         
     | 
| 
       411 
     | 
    
         
            -
                         <clause id='Q1' inline-header='false' obligation='normative'>
         
     | 
| 
       412 
     | 
    
         
            -
                           <title depth='3'>
         
     | 
| 
       413 
     | 
    
         
            -
                             A.1.1
         
     | 
| 
       414 
     | 
    
         
            -
                             <tab/>
         
     | 
| 
       415 
     | 
    
         
            -
                             Annex A.1a
         
     | 
| 
       416 
     | 
    
         
            -
                           </title>
         
     | 
| 
       417 
     | 
    
         
            -
                         </clause>
         
     | 
| 
       418 
     | 
    
         
            -
                       </clause>
         
     | 
| 
       419 
     | 
    
         
            -
                       <appendix id='Q2' inline-header='false' obligation='normative'>
         
     | 
| 
       420 
     | 
    
         
            -
                         <title depth='2'>
         
     | 
| 
       421 
     | 
    
         
            -
                           Appendix 1
         
     | 
| 
       422 
     | 
    
         
            -
                           <tab/>
         
     | 
| 
       423 
     | 
    
         
            -
                           An Appendix
         
     | 
| 
       424 
     | 
    
         
            -
                         </title>
         
     | 
| 
       425 
     | 
    
         
            -
                       </appendix>
         
     | 
| 
       426 
     | 
    
         
            -
                     </annex>
         
     | 
| 
       427 
     | 
    
         
            -
                     <bibliography>
         
     | 
| 
       428 
     | 
    
         
            -
                       <references id='R' obligation='informative' normative='true'>
         
     | 
| 
       429 
     | 
    
         
            -
                         <title depth='1'>
         
     | 
| 
       430 
     | 
    
         
            -
                           2
         
     | 
| 
       431 
     | 
    
         
            -
                           <tab/>
         
     | 
| 
       432 
     | 
    
         
            -
                           Normative References
         
     | 
| 
       433 
     | 
    
         
            -
                         </title>
         
     | 
| 
       434 
     | 
    
         
            -
                       </references>
         
     | 
| 
       435 
     | 
    
         
            -
                       <clause id='S' obligation='informative'>
         
     | 
| 
       436 
     | 
    
         
            -
                         <title depth='1'>Bibliography</title>
         
     | 
| 
       437 
     | 
    
         
            -
                         <references id='T' obligation='informative' normative='false'>
         
     | 
| 
       438 
     | 
    
         
            -
                           <title depth='2'>Bibliography Subsection</title>
         
     | 
| 
       439 
     | 
    
         
            -
                         </references>
         
     | 
| 
       440 
     | 
    
         
            -
                       </clause>
         
     | 
| 
       441 
     | 
    
         
            -
                     </bibliography>
         
     | 
| 
      
 299 
     | 
    
         
            +
                INPUT
         
     | 
| 
      
 300 
     | 
    
         
            +
                  <iso-standard xmlns="http://riboseinc.com/isoxml" type="presentation">
         
     | 
| 
      
 301 
     | 
    
         
            +
                  <bibdata>
         
     | 
| 
      
 302 
     | 
    
         
            +
                  <language current="true">tlh</language>
         
     | 
| 
      
 303 
     | 
    
         
            +
                  </bibdata>
         
     | 
| 
      
 304 
     | 
    
         
            +
                  <preface>
         
     | 
| 
      
 305 
     | 
    
         
            +
                  <foreword obligation="informative" displayorder="1">
         
     | 
| 
      
 306 
     | 
    
         
            +
                     <title>Foreword</title>
         
     | 
| 
      
 307 
     | 
    
         
            +
                     <p id="A">This is a preamble</p>
         
     | 
| 
      
 308 
     | 
    
         
            +
                   </foreword>
         
     | 
| 
      
 309 
     | 
    
         
            +
                    <introduction id="B" obligation="informative" displayorder="2"><title depth="1">0<tab/>Introduction</title><clause id="C" inline-header="false" obligation="informative">
         
     | 
| 
      
 310 
     | 
    
         
            +
                     <title depth="2">0.1<tab/>Introduction Subsection</title>
         
     | 
| 
      
 311 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 312 
     | 
    
         
            +
                   <p>This is patent boilerplate</p>
         
     | 
| 
      
 313 
     | 
    
         
            +
                   </introduction></preface><sections>
         
     | 
| 
      
 314 
     | 
    
         
            +
                   <clause id="D" obligation="normative" type="scope" displayorder="3">
         
     | 
| 
      
 315 
     | 
    
         
            +
                     <title depth="1">1<tab/>Scope</title>
         
     | 
| 
      
 316 
     | 
    
         
            +
                     <p id="E">Text</p>
         
     | 
| 
      
 317 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 318 
     | 
    
         
            +
                   <clause id="H" obligation="normative" displayorder="5"><title depth="1">3<tab/>Terms, definitions, symbols and abbreviated terms</title><terms id="I" obligation="normative">
         
     | 
| 
      
 319 
     | 
    
         
            +
                     <title depth="2">3.1<tab/>Normal Terms</title>
         
     | 
| 
      
 320 
     | 
    
         
            +
                     <term id="J"><name>3.1.1</name>
         
     | 
| 
      
 321 
     | 
    
         
            +
                     <preferred>Term2</preferred>
         
     | 
| 
      
 322 
     | 
    
         
            +
                   </term>
         
     | 
| 
      
 323 
     | 
    
         
            +
                   </terms>
         
     | 
| 
      
 324 
     | 
    
         
            +
                   <definitions id="K"><title>3.2</title>
         
     | 
| 
      
 325 
     | 
    
         
            +
                     <dl>
         
     | 
| 
      
 326 
     | 
    
         
            +
                     <dt>Symbol</dt>
         
     | 
| 
      
 327 
     | 
    
         
            +
                     <dd>Definition</dd>
         
     | 
| 
      
 328 
     | 
    
         
            +
                     </dl>
         
     | 
| 
      
 329 
     | 
    
         
            +
                   </definitions>
         
     | 
| 
      
 330 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 331 
     | 
    
         
            +
                   <definitions id="L" displayorder="6"><title>4</title>
         
     | 
| 
      
 332 
     | 
    
         
            +
                     <dl>
         
     | 
| 
      
 333 
     | 
    
         
            +
                     <dt>Symbol</dt>
         
     | 
| 
      
 334 
     | 
    
         
            +
                     <dd>Definition</dd>
         
     | 
| 
      
 335 
     | 
    
         
            +
                     </dl>
         
     | 
| 
      
 336 
     | 
    
         
            +
                   </definitions>
         
     | 
| 
      
 337 
     | 
    
         
            +
                   <clause id="M" inline-header="false" obligation="normative" displayorder="7"><title depth="1">5<tab/>Clause 4</title><clause id="N" inline-header="false" obligation="normative">
         
     | 
| 
      
 338 
     | 
    
         
            +
                     <title depth="2">5.1<tab/>Introduction</title>
         
     | 
| 
      
 339 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 340 
     | 
    
         
            +
                   <clause id="O" inline-header="false" obligation="normative">
         
     | 
| 
      
 341 
     | 
    
         
            +
                     <title depth="2">5.2<tab/>Clause 4.2</title>
         
     | 
| 
      
 342 
     | 
    
         
            +
                   </clause></clause>
         
     | 
| 
      
 343 
     | 
    
         
            +
                   </sections><annex id="P" inline-header="false" obligation="normative" displayorder="8">
         
     | 
| 
      
 344 
     | 
    
         
            +
                     <title><strong>Annex A</strong><br/>(normative)<br/><br/><strong>Annex</strong></title>
         
     | 
| 
      
 345 
     | 
    
         
            +
                     <clause id="Q" inline-header="false" obligation="normative">
         
     | 
| 
      
 346 
     | 
    
         
            +
                     <title depth="2">A.1<tab/>Annex A.1</title>
         
     | 
| 
      
 347 
     | 
    
         
            +
                     <clause id="Q1" inline-header="false" obligation="normative">
         
     | 
| 
      
 348 
     | 
    
         
            +
                     <title depth="3">A.1.1<tab/>Annex A.1a</title>
         
     | 
| 
      
 349 
     | 
    
         
            +
                     </clause>
         
     | 
| 
      
 350 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 351 
     | 
    
         
            +
                          <appendix id="Q2" inline-header="false" obligation="normative">
         
     | 
| 
      
 352 
     | 
    
         
            +
                     <title depth="2">Appendix 1<tab/>An Appendix</title>
         
     | 
| 
      
 353 
     | 
    
         
            +
                   </appendix>
         
     | 
| 
      
 354 
     | 
    
         
            +
                   </annex><bibliography><references id="R" obligation="informative" normative="true" displayorder="4">
         
     | 
| 
      
 355 
     | 
    
         
            +
                     <title depth="1">2<tab/>Normative References</title>
         
     | 
| 
      
 356 
     | 
    
         
            +
                   </references><clause id="S" obligation="informative" displayorder="9">
         
     | 
| 
      
 357 
     | 
    
         
            +
                     <title depth="1">Bibliography</title>
         
     | 
| 
      
 358 
     | 
    
         
            +
                     <references id="T" obligation="informative" normative="false">
         
     | 
| 
      
 359 
     | 
    
         
            +
                     <title depth="2">Bibliography Subsection</title>
         
     | 
| 
      
 360 
     | 
    
         
            +
                   </references>
         
     | 
| 
      
 361 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 362 
     | 
    
         
            +
                   </bibliography>
         
     | 
| 
       442 
363 
     | 
    
         
             
                   </iso-standard>
         
     | 
| 
       443 
364 
     | 
    
         
             
                OUTPUT
         
     | 
| 
       444 
365 
     | 
    
         
             
              end
         
     | 
| 
         @@ -516,163 +437,156 @@ RSpec.describe IsoDoc do 
     | 
|
| 
       516 
437 
     | 
    
         
             
                   </clause>
         
     | 
| 
       517 
438 
     | 
    
         
             
                   </bibliography>
         
     | 
| 
       518 
439 
     | 
    
         
             
                   </iso-standard>
         
     | 
| 
       519 
     | 
    
         
            -
             
     | 
| 
       520 
     | 
    
         
            -
             
     | 
| 
       521 
     | 
    
         
            -
                    presxml = <<~OUTPUT
         
     | 
| 
       522 
     | 
    
         
            -
            <iso-standard xmlns="http://riboseinc.com/isoxml" type="presentation">
         
     | 
| 
       523 
     | 
    
         
            -
                   <bibdata>
         
     | 
| 
       524 
     | 
    
         
            -
                   <language current="true">fr</language>
         
     | 
| 
       525 
     | 
    
         
            -
                   <ext>
         
     | 
| 
       526 
     | 
    
         
            -
              <doctype language=''>international-standard</doctype>
         
     | 
| 
       527 
     | 
    
         
            -
              <doctype language='fr'>Norme international</doctype>
         
     | 
| 
       528 
     | 
    
         
            -
              <doctype language='en'>International Standard</doctype>
         
     | 
| 
       529 
     | 
    
         
            -
              <horizontal language=''>false</horizontal>
         
     | 
| 
       530 
     | 
    
         
            -
              <function language=''>emc</function>
         
     | 
| 
       531 
     | 
    
         
            -
              <function language='fr'>Publication fondamentale en CEM</function>
         
     | 
| 
       532 
     | 
    
         
            -
              <function language='en'>Basic EMC Publication</function>
         
     | 
| 
       533 
     | 
    
         
            -
            </ext>
         
     | 
| 
       534 
     | 
    
         
            -
                   </bibdata>
         
     | 
| 
       535 
     | 
    
         
            -
                   <preface>
         
     | 
| 
       536 
     | 
    
         
            -
                   <foreword obligation="informative">
         
     | 
| 
       537 
     | 
    
         
            -
                      <title>Foreword</title>
         
     | 
| 
       538 
     | 
    
         
            -
                      <p id="A">This is a preamble</p>
         
     | 
| 
       539 
     | 
    
         
            -
                    </foreword>
         
     | 
| 
       540 
     | 
    
         
            -
                     <introduction id="B" obligation="informative"><title depth="1">0<tab/>Introduction</title><clause id="C" inline-header="false" obligation="informative">
         
     | 
| 
       541 
     | 
    
         
            -
                      <title depth="2">0.1<tab/>Introduction Subsection</title>
         
     | 
| 
       542 
     | 
    
         
            -
                    </clause>
         
     | 
| 
       543 
     | 
    
         
            -
                    <p>This is patent boilerplate</p>
         
     | 
| 
       544 
     | 
    
         
            -
                    </introduction></preface><sections>
         
     | 
| 
       545 
     | 
    
         
            -
                    <clause id="D" obligation="normative" type="scope">
         
     | 
| 
       546 
     | 
    
         
            -
                      <title depth="1">1<tab/>Scope</title>
         
     | 
| 
       547 
     | 
    
         
            -
                      <p id="E">Text</p>
         
     | 
| 
       548 
     | 
    
         
            -
                    </clause>
         
     | 
| 
       549 
     | 
    
         
            -
                 
         
     | 
| 
       550 
     | 
    
         
            -
                    <clause id="H" obligation="normative"><title depth="1">3<tab/>Terms, definitions, symbols and abbreviated terms</title><terms id="I" obligation="normative">
         
     | 
| 
       551 
     | 
    
         
            -
                      <title depth="2">3.1<tab/>Normal Terms</title>
         
     | 
| 
       552 
     | 
    
         
            -
                      <term id="J"><name>3.1.1</name>
         
     | 
| 
       553 
     | 
    
         
            -
                      <preferred>Term2</preferred>
         
     | 
| 
       554 
     | 
    
         
            -
                    </term>
         
     | 
| 
       555 
     | 
    
         
            -
                    </terms>
         
     | 
| 
       556 
     | 
    
         
            -
                    <definitions id="K"><title>3.2</title>
         
     | 
| 
       557 
     | 
    
         
            -
                      <dl>
         
     | 
| 
       558 
     | 
    
         
            -
                      <dt>Symbol</dt>
         
     | 
| 
       559 
     | 
    
         
            -
                      <dd>Definition</dd>
         
     | 
| 
       560 
     | 
    
         
            -
                      </dl>
         
     | 
| 
       561 
     | 
    
         
            -
                    </definitions>
         
     | 
| 
       562 
     | 
    
         
            -
                    </clause>
         
     | 
| 
       563 
     | 
    
         
            -
                    <definitions id="L"><title>4</title>
         
     | 
| 
       564 
     | 
    
         
            -
                      <dl>
         
     | 
| 
       565 
     | 
    
         
            -
                      <dt>Symbol</dt>
         
     | 
| 
       566 
     | 
    
         
            -
                      <dd>Definition</dd>
         
     | 
| 
       567 
     | 
    
         
            -
                      </dl>
         
     | 
| 
       568 
     | 
    
         
            -
                    </definitions>
         
     | 
| 
       569 
     | 
    
         
            -
                    <clause id="M" inline-header="false" obligation="normative"><title depth="1">5<tab/>Clause 4</title><clause id="N" inline-header="false" obligation="normative">
         
     | 
| 
       570 
     | 
    
         
            -
                      <title depth="2">5.1<tab/>Introduction</title>
         
     | 
| 
       571 
     | 
    
         
            -
                    </clause>
         
     | 
| 
       572 
     | 
    
         
            -
                    <clause id="O" inline-header="false" obligation="normative">
         
     | 
| 
       573 
     | 
    
         
            -
                      <title depth="2">5.2<tab/>Clause 4.2</title>
         
     | 
| 
       574 
     | 
    
         
            -
                    </clause></clause>
         
     | 
| 
       575 
     | 
    
         
            -
                 
         
     | 
| 
       576 
     | 
    
         
            -
                    </sections><annex id="P" inline-header="false" obligation="normative">
         
     | 
| 
       577 
     | 
    
         
            -
                      <title><strong>Annexe A</strong><br/>(normative)<br/><br/><strong>Annex</strong></title>
         
     | 
| 
       578 
     | 
    
         
            -
                      <clause id="Q" inline-header="false" obligation="normative">
         
     | 
| 
       579 
     | 
    
         
            -
                      <title depth="2">A.1<tab/>Annex A.1</title>
         
     | 
| 
       580 
     | 
    
         
            -
                      <clause id="Q1" inline-header="false" obligation="normative">
         
     | 
| 
       581 
     | 
    
         
            -
                      <title depth="3">A.1.1<tab/>Annex A.1a</title>
         
     | 
| 
       582 
     | 
    
         
            -
                      </clause>
         
     | 
| 
       583 
     | 
    
         
            -
                    </clause>
         
     | 
| 
       584 
     | 
    
         
            -
                           <appendix id="Q2" inline-header="false" obligation="normative">
         
     | 
| 
       585 
     | 
    
         
            -
                      <title depth="2">Appendice 1<tab/>An Appendix</title>
         
     | 
| 
       586 
     | 
    
         
            -
                    </appendix>
         
     | 
| 
       587 
     | 
    
         
            -
                    </annex><bibliography><references id="R" obligation="informative" normative="true">
         
     | 
| 
       588 
     | 
    
         
            -
                      <title depth="1">2<tab/>Normative References</title>
         
     | 
| 
       589 
     | 
    
         
            -
                    </references><clause id="S" obligation="informative">
         
     | 
| 
       590 
     | 
    
         
            -
                      <title depth="1">Bibliography</title>
         
     | 
| 
       591 
     | 
    
         
            -
                      <references id="T" obligation="informative" normative="false">
         
     | 
| 
       592 
     | 
    
         
            -
                      <title depth="2">Bibliography Subsection</title>
         
     | 
| 
       593 
     | 
    
         
            -
                    </references>
         
     | 
| 
       594 
     | 
    
         
            -
                    </clause>
         
     | 
| 
       595 
     | 
    
         
            -
                    </bibliography>
         
     | 
| 
       596 
     | 
    
         
            -
                    </iso-standard>
         
     | 
| 
       597 
     | 
    
         
            -
                    OUTPUT
         
     | 
| 
       598 
     | 
    
         
            -
             
     | 
| 
       599 
     | 
    
         
            -
                    html = <<~OUTPUT
         
     | 
| 
       600 
     | 
    
         
            -
                #{HTML_HDR.sub(/INTERNATIONAL ELECTROTECHNICAL COMMISSION/, "COMMISSION ELECTROTECHNIQUE INTERNATIONALE").
         
     | 
| 
       601 
     | 
    
         
            -
                gsub(/"en"/, '"fr"')}
         
     | 
| 
       602 
     | 
    
         
            -
                         <div>
         
     | 
| 
       603 
     | 
    
         
            -
                           <h1 class="ForewordTitle">AVANT-PROPOS</h1>
         
     | 
| 
       604 
     | 
    
         
            -
                           <div class="boilerplate_legal"/>
         
     | 
| 
       605 
     | 
    
         
            -
                           <p id="A">This is a preamble</p>
         
     | 
| 
       606 
     | 
    
         
            -
                         </div>
         
     | 
| 
       607 
     | 
    
         
            -
                         <br/>
         
     | 
| 
       608 
     | 
    
         
            -
                         <div class="Section3" id="B">
         
     | 
| 
       609 
     | 
    
         
            -
                           <h1 class="IntroTitle">0  Introduction</h1>
         
     | 
| 
       610 
     | 
    
         
            -
                           <div id="C"><h2>0.1  Introduction Subsection</h2>
         
     | 
| 
      
 440 
     | 
    
         
            +
                INPUT
         
     | 
| 
       611 
441 
     | 
    
         | 
| 
       612 
     | 
    
         
            -
             
     | 
| 
       613 
     | 
    
         
            -
             
     | 
| 
       614 
     | 
    
         
            -
             
     | 
| 
       615 
     | 
    
         
            -
             
     | 
| 
       616 
     | 
    
         
            -
             
     | 
| 
       617 
     | 
    
         
            -
             
     | 
| 
       618 
     | 
    
         
            -
             
     | 
| 
       619 
     | 
    
         
            -
             
     | 
| 
       620 
     | 
    
         
            -
             
     | 
| 
       621 
     | 
    
         
            -
             
     | 
| 
       622 
     | 
    
         
            -
             
     | 
| 
       623 
     | 
    
         
            -
             
     | 
| 
       624 
     | 
    
         
            -
             
     | 
| 
      
 442 
     | 
    
         
            +
                presxml = <<~OUTPUT
         
     | 
| 
      
 443 
     | 
    
         
            +
                  <iso-standard xmlns="http://riboseinc.com/isoxml" type="presentation">
         
     | 
| 
      
 444 
     | 
    
         
            +
                  <bibdata>
         
     | 
| 
      
 445 
     | 
    
         
            +
                  <language current="true">fr</language>
         
     | 
| 
      
 446 
     | 
    
         
            +
                  <ext>
         
     | 
| 
      
 447 
     | 
    
         
            +
                  <doctype language="">international-standard</doctype><doctype language="fr">Norme international</doctype><doctype language="en">International Standard</doctype>
         
     | 
| 
      
 448 
     | 
    
         
            +
                  <horizontal language="">false</horizontal>
         
     | 
| 
      
 449 
     | 
    
         
            +
                  <function language="">emc</function><function language="fr">Publication fondamentale en CEM</function><function language="en">Basic EMC Publication</function>
         
     | 
| 
      
 450 
     | 
    
         
            +
                  </ext>
         
     | 
| 
      
 451 
     | 
    
         
            +
                  </bibdata>
         
     | 
| 
      
 452 
     | 
    
         
            +
                  <preface>
         
     | 
| 
      
 453 
     | 
    
         
            +
                  <foreword obligation="informative" displayorder="1">
         
     | 
| 
      
 454 
     | 
    
         
            +
                     <title>Foreword</title>
         
     | 
| 
      
 455 
     | 
    
         
            +
                     <p id="A">This is a preamble</p>
         
     | 
| 
      
 456 
     | 
    
         
            +
                   </foreword>
         
     | 
| 
      
 457 
     | 
    
         
            +
                    <introduction id="B" obligation="informative" displayorder="2"><title depth="1">0<tab/>Introduction</title><clause id="C" inline-header="false" obligation="informative">
         
     | 
| 
      
 458 
     | 
    
         
            +
                     <title depth="2">0.1<tab/>Introduction Subsection</title>
         
     | 
| 
      
 459 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 460 
     | 
    
         
            +
                   <p>This is patent boilerplate</p>
         
     | 
| 
      
 461 
     | 
    
         
            +
                   </introduction></preface><sections>
         
     | 
| 
      
 462 
     | 
    
         
            +
                   <clause id="D" obligation="normative" type="scope" displayorder="3">
         
     | 
| 
      
 463 
     | 
    
         
            +
                     <title depth="1">1<tab/>Scope</title>
         
     | 
| 
      
 464 
     | 
    
         
            +
                     <p id="E">Text</p>
         
     | 
| 
      
 465 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 466 
     | 
    
         
            +
                   <clause id="H" obligation="normative" displayorder="5"><title depth="1">3<tab/>Terms, definitions, symbols and abbreviated terms</title><terms id="I" obligation="normative">
         
     | 
| 
      
 467 
     | 
    
         
            +
                     <title depth="2">3.1<tab/>Normal Terms</title>
         
     | 
| 
      
 468 
     | 
    
         
            +
                     <term id="J"><name>3.1.1</name>
         
     | 
| 
      
 469 
     | 
    
         
            +
                     <preferred>Term2</preferred>
         
     | 
| 
      
 470 
     | 
    
         
            +
                   </term>
         
     | 
| 
      
 471 
     | 
    
         
            +
                   </terms>
         
     | 
| 
      
 472 
     | 
    
         
            +
                   <definitions id="K"><title>3.2</title>
         
     | 
| 
      
 473 
     | 
    
         
            +
                     <dl>
         
     | 
| 
      
 474 
     | 
    
         
            +
                     <dt>Symbol</dt>
         
     | 
| 
      
 475 
     | 
    
         
            +
                     <dd>Definition</dd>
         
     | 
| 
      
 476 
     | 
    
         
            +
                     </dl>
         
     | 
| 
      
 477 
     | 
    
         
            +
                   </definitions>
         
     | 
| 
      
 478 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 479 
     | 
    
         
            +
                   <definitions id="L" displayorder="6"><title>4</title>
         
     | 
| 
      
 480 
     | 
    
         
            +
                     <dl>
         
     | 
| 
      
 481 
     | 
    
         
            +
                     <dt>Symbol</dt>
         
     | 
| 
      
 482 
     | 
    
         
            +
                     <dd>Definition</dd>
         
     | 
| 
      
 483 
     | 
    
         
            +
                     </dl>
         
     | 
| 
      
 484 
     | 
    
         
            +
                   </definitions>
         
     | 
| 
      
 485 
     | 
    
         
            +
                   <clause id="M" inline-header="false" obligation="normative" displayorder="7"><title depth="1">5<tab/>Clause 4</title><clause id="N" inline-header="false" obligation="normative">
         
     | 
| 
      
 486 
     | 
    
         
            +
                     <title depth="2">5.1<tab/>Introduction</title>
         
     | 
| 
      
 487 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 488 
     | 
    
         
            +
                   <clause id="O" inline-header="false" obligation="normative">
         
     | 
| 
      
 489 
     | 
    
         
            +
                     <title depth="2">5.2<tab/>Clause 4.2</title>
         
     | 
| 
      
 490 
     | 
    
         
            +
                   </clause></clause>
         
     | 
| 
      
 491 
     | 
    
         
            +
                   </sections><annex id="P" inline-header="false" obligation="normative" displayorder="8">
         
     | 
| 
      
 492 
     | 
    
         
            +
                     <title><strong>Annexe A</strong><br/>(normative)<br/><br/><strong>Annex</strong></title>
         
     | 
| 
      
 493 
     | 
    
         
            +
                     <clause id="Q" inline-header="false" obligation="normative">
         
     | 
| 
      
 494 
     | 
    
         
            +
                     <title depth="2">A.1<tab/>Annex A.1</title>
         
     | 
| 
      
 495 
     | 
    
         
            +
                     <clause id="Q1" inline-header="false" obligation="normative">
         
     | 
| 
      
 496 
     | 
    
         
            +
                     <title depth="3">A.1.1<tab/>Annex A.1a</title>
         
     | 
| 
      
 497 
     | 
    
         
            +
                     </clause>
         
     | 
| 
      
 498 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 499 
     | 
    
         
            +
                          <appendix id="Q2" inline-header="false" obligation="normative">
         
     | 
| 
      
 500 
     | 
    
         
            +
                     <title depth="2">Appendice 1<tab/>An Appendix</title>
         
     | 
| 
      
 501 
     | 
    
         
            +
                   </appendix>
         
     | 
| 
      
 502 
     | 
    
         
            +
                   </annex><bibliography><references id="R" obligation="informative" normative="true" displayorder="4">
         
     | 
| 
      
 503 
     | 
    
         
            +
                     <title depth="1">2<tab/>Normative References</title>
         
     | 
| 
      
 504 
     | 
    
         
            +
                   </references><clause id="S" obligation="informative" displayorder="9">
         
     | 
| 
      
 505 
     | 
    
         
            +
                     <title depth="1">Bibliography</title>
         
     | 
| 
      
 506 
     | 
    
         
            +
                     <references id="T" obligation="informative" normative="false">
         
     | 
| 
      
 507 
     | 
    
         
            +
                     <title depth="2">Bibliography Subsection</title>
         
     | 
| 
      
 508 
     | 
    
         
            +
                   </references>
         
     | 
| 
      
 509 
     | 
    
         
            +
                   </clause>
         
     | 
| 
      
 510 
     | 
    
         
            +
                   </bibliography>
         
     | 
| 
      
 511 
     | 
    
         
            +
                   </iso-standard>
         
     | 
| 
      
 512 
     | 
    
         
            +
                OUTPUT
         
     | 
| 
       625 
513 
     | 
    
         | 
| 
       626 
     | 
    
         
            -
             
     | 
| 
       627 
     | 
    
         
            -
             
     | 
| 
      
 514 
     | 
    
         
            +
                html = <<~OUTPUT
         
     | 
| 
      
 515 
     | 
    
         
            +
                  #{HTML_HDR.sub(/INTERNATIONAL ELECTROTECHNICAL COMMISSION/, 'COMMISSION ELECTROTECHNIQUE INTERNATIONALE')
         
     | 
| 
      
 516 
     | 
    
         
            +
                  .gsub(/"en"/, '"fr"')}
         
     | 
| 
      
 517 
     | 
    
         
            +
                           <div>
         
     | 
| 
      
 518 
     | 
    
         
            +
                             <h1 class="ForewordTitle">AVANT-PROPOS</h1>
         
     | 
| 
      
 519 
     | 
    
         
            +
                             <div class="boilerplate_legal"/>
         
     | 
| 
      
 520 
     | 
    
         
            +
                             <p id="A">This is a preamble</p>
         
     | 
| 
      
 521 
     | 
    
         
            +
                           </div>
         
     | 
| 
      
 522 
     | 
    
         
            +
                           <br/>
         
     | 
| 
      
 523 
     | 
    
         
            +
                           <div class="Section3" id="B">
         
     | 
| 
      
 524 
     | 
    
         
            +
                             <h1 class="IntroTitle">0  Introduction</h1>
         
     | 
| 
      
 525 
     | 
    
         
            +
                             <div id="C"><h2>0.1  Introduction Subsection</h2>
         
     | 
| 
       628 
526 
     | 
    
         | 
| 
       629 
     | 
    
         
            -
             
     | 
| 
       630 
     | 
    
         
            -
             
     | 
| 
       631 
     | 
    
         
            -
             
     | 
| 
       632 
     | 
    
         
            -
             
     | 
| 
       633 
     | 
    
         
            -
                           < 
     | 
| 
       634 
     | 
    
         
            -
             
     | 
| 
       635 
     | 
    
         
            -
                             < 
     | 
| 
       636 
     | 
    
         
            -
             
     | 
| 
       637 
     | 
    
         
            -
             
     | 
| 
       638 
     | 
    
         
            -
                             < 
     | 
| 
       639 
     | 
    
         
            -
                           </ 
     | 
| 
       640 
     | 
    
         
            -
             
     | 
| 
       641 
     | 
    
         
            -
             
     | 
| 
       642 
     | 
    
         
            -
             
     | 
| 
       643 
     | 
    
         
            -
             
     | 
| 
      
 527 
     | 
    
         
            +
                      </div>
         
     | 
| 
      
 528 
     | 
    
         
            +
                             <p>This is patent boilerplate</p>
         
     | 
| 
      
 529 
     | 
    
         
            +
                           </div>
         
     | 
| 
      
 530 
     | 
    
         
            +
                           #{IEC_TITLE1}
         
     | 
| 
      
 531 
     | 
    
         
            +
                           <div id="D">
         
     | 
| 
      
 532 
     | 
    
         
            +
                             <h1>1  Scope</h1>
         
     | 
| 
      
 533 
     | 
    
         
            +
                             <p id="E">Text</p>
         
     | 
| 
      
 534 
     | 
    
         
            +
                           </div>
         
     | 
| 
      
 535 
     | 
    
         
            +
                           <div>
         
     | 
| 
      
 536 
     | 
    
         
            +
                             <h1>2  Normative References</h1>
         
     | 
| 
      
 537 
     | 
    
         
            +
                           </div>
         
     | 
| 
      
 538 
     | 
    
         
            +
                           <div id="H"><h1>3  Terms, definitions, symbols and abbreviated terms</h1>
         
     | 
| 
      
 539 
     | 
    
         
            +
                     <div id="I"><h2>3.1  Normal Terms</h2>
         
     | 
| 
      
 540 
     | 
    
         
            +
             
     | 
| 
      
 541 
     | 
    
         
            +
                        <p class="TermNum" id="J">3.1.1</p>
         
     | 
| 
      
 542 
     | 
    
         
            +
                        <p class="Terms" style="text-align:left;">Term2</p>
         
     | 
| 
      
 543 
     | 
    
         
            +
             
     | 
| 
      
 544 
     | 
    
         
            +
                      </div><div id="K"><h2>3.2</h2>
         
     | 
| 
      
 545 
     | 
    
         
            +
                        <dl><dt><p>Symbol</p></dt><dd>Definition</dd></dl>
         
     | 
| 
      
 546 
     | 
    
         
            +
                      </div></div>
         
     | 
| 
      
 547 
     | 
    
         
            +
                           <div id="L" class="Symbols">
         
     | 
| 
      
 548 
     | 
    
         
            +
                             <h1>4</h1>
         
     | 
| 
      
 549 
     | 
    
         
            +
                             <dl>
         
     | 
| 
      
 550 
     | 
    
         
            +
                               <dt>
         
     | 
| 
      
 551 
     | 
    
         
            +
                                 <p>Symbol</p>
         
     | 
| 
      
 552 
     | 
    
         
            +
                               </dt>
         
     | 
| 
      
 553 
     | 
    
         
            +
                               <dd>Definition</dd>
         
     | 
| 
      
 554 
     | 
    
         
            +
                             </dl>
         
     | 
| 
      
 555 
     | 
    
         
            +
                           </div>
         
     | 
| 
      
 556 
     | 
    
         
            +
                           <div id="M">
         
     | 
| 
      
 557 
     | 
    
         
            +
                             <h1>5  Clause 4</h1>
         
     | 
| 
      
 558 
     | 
    
         
            +
                             <div id="N"><h2>5.1  Introduction</h2>
         
     | 
| 
       644 
559 
     | 
    
         | 
| 
       645 
     | 
    
         
            -
             
     | 
| 
       646 
     | 
    
         
            -
             
     | 
| 
      
 560 
     | 
    
         
            +
                      </div>
         
     | 
| 
      
 561 
     | 
    
         
            +
                             <div id="O"><h2>5.2  Clause 4.2</h2>
         
     | 
| 
       647 
562 
     | 
    
         | 
| 
       648 
     | 
    
         
            -
             
     | 
| 
       649 
     | 
    
         
            -
             
     | 
| 
       650 
     | 
    
         
            -
             
     | 
| 
       651 
     | 
    
         
            -
             
     | 
| 
       652 
     | 
    
         
            -
             
     | 
| 
       653 
     | 
    
         
            -
             
     | 
| 
      
 563 
     | 
    
         
            +
                      </div>
         
     | 
| 
      
 564 
     | 
    
         
            +
                           </div>
         
     | 
| 
      
 565 
     | 
    
         
            +
                           <br/>
         
     | 
| 
      
 566 
     | 
    
         
            +
                           <div id="P" class="Section3">
         
     | 
| 
      
 567 
     | 
    
         
            +
                             <h1 class="Annex"><b>Annexe A</b><br/>(normative)<br/><br/><b>Annex</b></h1>
         
     | 
| 
      
 568 
     | 
    
         
            +
                             <div id="Q"><h2>A.1  Annex A.1</h2>
         
     | 
| 
       654 
569 
     | 
    
         | 
| 
       655 
     | 
    
         
            -
             
     | 
| 
      
 570 
     | 
    
         
            +
                        <div id="Q1"><h3>A.1.1  Annex A.1a</h3>
         
     | 
| 
       656 
571 
     | 
    
         | 
| 
      
 572 
     | 
    
         
            +
                        </div>
         
     | 
| 
       657 
573 
     | 
    
         
             
                      </div>
         
     | 
| 
       658 
     | 
    
         
            -
             
     | 
| 
       659 
     | 
    
         
            -
                           <div id="Q2"><h2>Appendice 1  An Appendix</h2>
         
     | 
| 
      
 574 
     | 
    
         
            +
                             <div id="Q2"><h2>Appendice 1  An Appendix</h2>
         
     | 
| 
       660 
575 
     | 
    
         | 
| 
       661 
     | 
    
         
            -
             
     | 
| 
       662 
     | 
    
         
            -
             
     | 
| 
       663 
     | 
    
         
            -
             
     | 
| 
       664 
     | 
    
         
            -
                         <div>
         
     | 
| 
       665 
     | 
    
         
            -
                           <h1 class="Section3">Bibliography</h1>
         
     | 
| 
      
 576 
     | 
    
         
            +
                      </div>
         
     | 
| 
      
 577 
     | 
    
         
            +
                           </div>
         
     | 
| 
      
 578 
     | 
    
         
            +
                           <br/>
         
     | 
| 
       666 
579 
     | 
    
         
             
                           <div>
         
     | 
| 
       667 
     | 
    
         
            -
                             < 
     | 
| 
      
 580 
     | 
    
         
            +
                             <h1 class="Section3">Bibliography</h1>
         
     | 
| 
      
 581 
     | 
    
         
            +
                             <div>
         
     | 
| 
      
 582 
     | 
    
         
            +
                               <h2 class="Section3">Bibliography Subsection</h2>
         
     | 
| 
      
 583 
     | 
    
         
            +
                             </div>
         
     | 
| 
       668 
584 
     | 
    
         
             
                           </div>
         
     | 
| 
       669 
585 
     | 
    
         
             
                         </div>
         
     | 
| 
       670 
     | 
    
         
            -
                       </ 
     | 
| 
       671 
     | 
    
         
            -
                     </ 
     | 
| 
       672 
     | 
    
         
            -
                   </html>
         
     | 
| 
      
 586 
     | 
    
         
            +
                       </body>
         
     | 
| 
      
 587 
     | 
    
         
            +
                     </html>
         
     | 
| 
       673 
588 
     | 
    
         
             
                OUTPUT
         
     | 
| 
       674 
589 
     | 
    
         
             
                expect(xmlpp(IsoDoc::Iec::PresentationXMLConvert.new({}).convert("test", input, true).sub(%r{<localized-strings>.*</localized-strings>}m, ""))).to be_equivalent_to xmlpp(presxml)
         
     | 
| 
       675 
590 
     | 
    
         
             
                expect(xmlpp(IsoDoc::Iec::HtmlConvert.new({}).convert("test", presxml, true))).to be_equivalent_to xmlpp(html)
         
     | 
| 
       676 
591 
     | 
    
         
             
              end
         
     | 
| 
       677 
     | 
    
         
            -
             
     | 
| 
       678 
592 
     | 
    
         
             
            end
         
     |