<?xml version="1.0" encoding="UTF-8"?>
<commit>
  <added type="array">
    <added>
      <filename>LEGAL</filename>
    </added>
    <added>
      <filename>LICENSE</filename>
    </added>
  </added>
  <modified type="array">
    <modified>
      <diff>@@ -1,26 +1,39 @@
 #!/usr/bin/env ruby
-# Originally based on 
+# rcov Copyright (c) 2004-2006 Mauricio Fernandez &lt;mfp@acm.org&gt;
+#
+# rcov originally based on 
 # module COVERAGE__ originally (c) NAKAMURA Hiroshi
 # module PrettyCoverage originally (c) Simon Strandgaard
 #
 # rewritten &amp; extended by Mauricio Fern&#225;ndez &lt;mfp@acm.org&gt;
 #
-# See LICENSE.txt for additional licensing information.
+# See LEGAL and LICENSE for additional licensing information.
 #
 
 require 'cgi'
 require 'rbconfig'
 require 'optparse'
 require 'ostruct'
-require 'xx-0.1.0-1'
 include Config
+eval DATA.read  # load xx-0.1.0-1
+
+# extend XX
+module XX
+  module XMLish
+    include Markup
+
+    def xmlish_ *a, &amp;b
+      xx_which(XMLish){ xx_with_doc_in_effect(*a, &amp;b)}
+    end
+  end
+end
 
 SCRIPT_LINES__ = {} unless defined? SCRIPT_LINES__
 
 module Rcov
 
-VERSION = &quot;0.1.0&quot;
-RELEASE_DATE = &quot;2006-01-23&quot;
+VERSION = &quot;0.2.0&quot;
+RELEASE_DATE = &quot;2006-02-25&quot;
     
 class CoverageInfo
     def initialize(coverage_array)
@@ -212,7 +225,102 @@ class HTMLCoverage &lt; Formatter
     include XX::XMLish
     require 'fileutils'
 
-    CSS_PROLOG = DATA.read
+    CSS_PROLOG = &lt;&lt;-EOS
+span.marked {
+  background-color: rgb(185, 200, 200);
+  display: block;
+}
+span.inferred {
+  background-color: rgb(170, 185, 185);
+  display: block;
+}
+span.overview {
+  border-bottom: 8px solid black;
+}
+div.overview {
+  border-bottom: 8px solid black;
+}
+body {
+    font-family: verdana, arial, helvetica;
+}
+
+div.footer {
+    font-size: 68%;
+    margin-top: 1.5em;
+}
+
+h1, h2, h3, h4, h5, h6 {
+    margin-bottom: 0.5em;
+}
+
+h5 {
+    margin-top: 0.5em;
+}
+
+.hidden {
+    display: none;
+}
+
+div.separator {
+    height: 10px;
+}
+
+table tr td, table tr th {
+    font-size: 68%;
+}
+
+td.value table tr td {
+    font-size: 11px;
+}
+
+table.percent_graph {
+    height: 12px;
+    border: #808080 1px solid;
+    empty-cells: show;
+}
+
+table.percent_graph td.covered {
+    height: 10px;
+    background: #00f000;
+}
+
+table.percent_graph td.uncovered {
+    height: 10px;
+    background: #e00000;
+}
+
+table.percent_graph td.NA {
+    height: 10px;
+    background: #eaeaea;
+}
+
+table.report {
+    border-collapse: collapse;
+    width: 100%;
+}
+
+table.report td.heading {
+    background: #dcecff;
+    border: #d0d0d0 1px solid;
+    font-weight: bold;
+    text-align: center;
+}
+
+table.report td.heading:hover {
+    background: #c0ffc0;
+}
+
+table.report td.text {
+    border: #d0d0d0 1px solid;
+}
+
+table.report td.value {
+    text-align: right;
+    border: #d0d0d0 1px solid;
+}
+EOS
+
+
     
     DEFAULT_OPTS = {:color, false, :fsr, 30, :textmode, false}
     def initialize(dest_dir = &quot;.&quot;, opts = {})
@@ -738,99 +846,767 @@ until pending_scripts.empty?
     load prog
 end
 
-# CSS styling follows
+# xx-0.1.0-1 follows
 __END__
-span.marked {
-  background-color: rgb(185, 200, 200);
-  display: block;
-}
-span.inferred {
-  background-color: rgb(170, 185, 185);
-  display: block;
-}
-span.overview {
-  border-bottom: 8px solid black;
-}
-div.overview {
-  border-bottom: 8px solid black;
-}
-body {
-    font-family: verdana, arial, helvetica;
-}
+# xx can be redistributed and used under the following conditions
+# (just keep the following copyright notice, list of conditions and disclaimer
+# in order to satisfy rcov's &quot;Ruby license&quot; and xx's license simultaneously).
+# 
+#ePark Labs Public License version 1
+#Copyright (c) 2005, ePark Labs, Inc. and contributors
+#All rights reserved.
+#
+#Redistribution and use in source and binary forms, with or without modification,
+#are permitted provided that the following conditions are met:
+#
+#  1. Redistributions of source code must retain the above copyright notice, this
+#     list of conditions and the following disclaimer.
+#  2. Redistributions in binary form must reproduce the above copyright notice,
+#     this list of conditions and the following disclaimer in the documentation
+#     and/or other materials provided with the distribution.
+#  3. Neither the name of ePark Labs nor the names of its contributors may be
+#     used to endorse or promote products derived from this software without
+#     specific prior written permission.
+#
+#THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS &quot;AS IS&quot; AND
+#ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
+#WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
+#DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE LIABLE FOR
+#ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES
+#(INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES;
+#LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON
+#ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
+#(INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS
+#SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
+
+unless defined? $__xx_rb__
+
+require &quot;rexml/document&quot;
+
+
+module XX
+#--{{{
+  VERSION = &quot;0.1.0&quot;
+
+  %w(
+    CRAZY_LIKE_A_HELL
+    PERMISSIVE
+    STRICT
+    ANY
+  ).each{|c| const_set c, c}
+
+  class Document
+#--{{{
+    attr &quot;doc&quot;
+    attr &quot;stack&quot;
+    attr &quot;size&quot;
+
+    def initialize *a, &amp;b
+#--{{{
+      @doc = ::REXML::Document::new(*a, &amp;b)
+      @stack = [@doc]
+      @size = 0
+#--}}}
+    end
+    def top
+#--{{{
+      @stack.last
+#--}}}
+    end
+    def push element
+#--{{{
+      @stack.push element
+#--}}}
+    end
+    def pop
+#--{{{
+      @stack.pop unless @stack.size == 1
+#--}}}
+    end
+    def tracking_additions
+#--{{{
+      n = @size
+      yield
+      return @size - n
+#--}}}
+    end
+    def to_str port = &quot;&quot;
+#--{{{
+      @doc.write port, indent=-1, transitive=false, ie_hack=true
+      port
+#--}}}
+    end
+    alias_method &quot;to_s&quot;, &quot;to_str&quot;
+    def pretty port = '' 
+#--{{{
+      @doc.write port, indent=2, transitive=false, ie_hack=true
+      port
+#--}}}
+    end
+    def create element
+#--{{{
+      push element
+      begin
+        object = nil
+        additions =
+          tracking_additions do
+            object = yield element if block_given?
+          end
+        if object and additions.zero?
+          self &lt;&lt; object
+        end
+      ensure
+        pop
+      end
+      self &lt;&lt; element
+      element
+#--}}}
+    end
+    def &lt;&lt; object
+#--{{{
+      t, x = top, object
+
+      if x
+        case t
+          when ::REXML::Document
+
+            begin
+              t &lt;&lt;
+                case x
+                  when ::REXML::Document
+                    x.root || ::REXML::Text::new(x.to_s)
+                  when ::REXML::Element
+                    x
+                  when ::REXML::CData
+                    x
+                  when ::REXML::Text
+                    x
+                  else # string
+                    ::REXML::Text::new(x.to_s)
+                end
+            rescue
+              if t.respond_to? &quot;root&quot;
+                t = t.root
+                retry
+              else
+                raise
+              end
+            end
 
-div.footer {
-    font-size: 68%;
-    margin-top: 1.5em;
-}
+          when ::REXML::Element
+            t &lt;&lt;
+              case x
+                when ::REXML::Document
+                  x.root || ::REXML::Text::new(x.to_s)
+                when ::REXML::Element
+                  x
+                when ::REXML::CData
+                  #::REXML::Text::new(x.write(&quot;&quot;))
+                  x
+                when ::REXML::Text
+                  x
+                else # string
+                  ::REXML::Text::new(x.to_s)
+              end
+
+          when ::REXML::Text
+            t &lt;&lt;
+              case x
+                when ::REXML::Document
+                  x.write &quot;&quot;
+                when ::REXML::Element
+                  x.write &quot;&quot;
+                when ::REXML::CData
+                  x.write &quot;&quot;
+                when ::REXML::Text
+                  x.write &quot;&quot;
+                else # string
+                  x.to_s
+              end
+
+          else # other - try anyhow 
+            t &lt;&lt;
+              case x
+                when ::REXML::Document
+                  x.write &quot;&quot;
+                when ::REXML::Element
+                  x.write &quot;&quot;
+                when ::REXML::CData
+                  x.write &quot;&quot;
+                when ::REXML::Text
+                  x.write &quot;&quot;
+                else # string
+                  x.to_s
+              end
+        end
+      end
 
-h1, h2, h3, h4, h5, h6 {
-    margin-bottom: 0.5em;
-}
+      @size += 1
+      self
+#--}}}
+    end
+#--}}}
+  end
+
+  module Markup
+#--{{{
+    class Error &lt; ::StandardError; end
+
+    module InstanceMethods
+#--{{{
+      def method_missing m, *a, &amp;b
+#--{{{
+        m = m.to_s
+
+        tag_method, tag_name = xx_class::xx_tag_method_name m
+
+        c_method_missing = xx_class::xx_config_for &quot;method_missing&quot;, xx_which
+        c_tags = xx_class::xx_config_for &quot;tags&quot;, xx_which
+
+        pat =
+          case c_method_missing
+            when ::XX::CRAZY_LIKE_A_HELL
+              %r/.*/
+            when ::XX::PERMISSIVE
+              %r/_$/o
+            when ::XX::STRICT
+              %r/_$/o
+            else
+              super
+          end
 
-h5 {
-    margin-top: 0.5em;
-}
+        super unless m =~ pat
 
-.hidden {
-    display: none;
-}
+        if c_method_missing == ::XX::STRICT
+          super unless c_tags.include? tag_name
+        end
 
-div.separator {
-    height: 10px;
-}
+        ret, defined = nil
 
-table tr td, table tr th {
-    font-size: 68%;
-}
+        begin
+          xx_class::xx_define_tmp_method tag_method
+          xx_class::xx_define_tag_method tag_method, tag_name
+          ret = send tag_method, *a, &amp;b
+          defined = true
+        ensure
+          xx_class::xx_remove_tag_method tag_method unless defined
+        end
 
-td.value table tr td {
-    font-size: 11px;
-}
+        ret
+#--}}}
+      end
+      def xx_tag_ tag_name, *a, &amp;b
+#--{{{
+        tag_method, tag_name = xx_class::xx_tag_method_name tag_name 
+
+        ret, defined = nil
+
+        begin
+          xx_class::xx_define_tmp_method tag_method
+          xx_class::xx_define_tag_method tag_method, tag_name
+          ret = send tag_method, *a, &amp;b
+          defined = true
+        ensure
+          xx_class::xx_remove_tag_method tag_method unless defined
+        end
 
-table.percent_graph {
-    height: 12px;
-    border: #808080 1px solid;
-    empty-cells: show;
-}
+        ret
+#--}}}
+      end
+      alias_method &quot;g_&quot;, &quot;xx_tag_&quot;
+      def xx_which *argv 
+#--{{{
+        @xx_which = nil unless defined? @xx_which
+        if argv.empty?
+          @xx_which
+        else
+          xx_which = @xx_which
+          begin
+            @xx_which = argv.shift 
+            return yield
+          ensure
+            @xx_which = xx_which
+          end
+        end
+#--}}}
+      end
+      def xx_with_doc_in_effect *a, &amp;b
+#--{{{
+        @xx_docs ||= []
+        doc = ::XX::Document::new(*a)
+        ddoc = doc.doc
+        begin
+          @xx_docs.push doc
+          b.call doc if b
+
+          doctype = xx_config_for &quot;doctype&quot;, xx_which
+          if doctype
+            unless ddoc.doctype
+              doctype = ::REXML::DocType::new doctype unless 
+                ::REXML::DocType === doctype
+              ddoc &lt;&lt; doctype
+            end
+          end
+
+          xmldecl = xx_config_for &quot;xmldecl&quot;, xx_which
+          if xmldecl
+            if ddoc.xml_decl == ::REXML::XMLDecl::default
+              xmldecl = ::REXML::XMLDecl::new xmldecl unless
+                ::REXML::XMLDecl === xmldecl
+              ddoc &lt;&lt; xmldecl
+            end
+          end
 
-table.percent_graph td.covered {
-    height: 10px;
-    background: #00f000;
-}
+          return doc
+        ensure
+          @xx_docs.pop
+        end
+#--}}}
+      end
+      def xx_doc
+#--{{{
+        @xx_docs.last rescue raise &quot;no xx_doc in effect!&quot;
+#--}}}
+      end
+      def xx_text_ *objects, &amp;b
+#--{{{
+        doc = xx_doc
+
+        text =
+          ::REXML::Text::new(&quot;&quot;, 
+            respect_whitespace=true, parent=nil
+          )
+
+        objects.each do |object| 
+          text &lt;&lt; object.to_s if object
+        end
 
-table.percent_graph td.uncovered {
-    height: 10px;
-    background: #e00000;
-}
+        doc.create text, &amp;b
+#--}}}
+      end
+      alias_method &quot;text_&quot;, &quot;xx_text_&quot;
+      alias_method &quot;t_&quot;, &quot;xx_text_&quot;
+      def xx_markup_ *objects, &amp;b
+#--{{{
+        doc = xx_doc
 
-table.percent_graph td.NA {
-    height: 10px;
-    background: #eaeaea;
-}
+        doc2 = ::REXML::Document::new &quot;&quot;
 
-table.report {
-    border-collapse: collapse;
-    width: 100%;
-}
+        objects.each do |object| 
+          (doc2.root ? doc2.root : doc2) &lt;&lt; ::REXML::Document::new(object.to_s)
+        end
 
-table.report td.heading {
-    background: #dcecff;
-    border: #d0d0d0 1px solid;
-    font-weight: bold;
-    text-align: center;
-}
 
-table.report td.heading:hover {
-    background: #c0ffc0;
-}
+        ret = doc.create doc2, &amp;b
+        puts doc2.to_s
+        STDIN.gets
+        ret
+#--}}}
+      end
+      alias_method &quot;x_&quot;, &quot;xx_markup_&quot;
+      def xx_any_ *objects, &amp;b
+#--{{{
+        doc = xx_doc
+        nothing = %r/.^/m
+
+        text =
+          ::REXML::Text::new(&quot;&quot;, 
+            respect_whitespace=true, parent=nil, raw=true, entity_filter=nil, illegal=nothing
+          )
+
+        objects.each do |object| 
+          text &lt;&lt; object.to_s if object
+        end
 
-table.report td.text {
-    border: #d0d0d0 1px solid;
-}
+        doc.create text, &amp;b
+#--}}}
+      end
+      alias_method &quot;h_&quot;, &quot;xx_any_&quot;
+      remove_method &quot;x_&quot; if instance_methods.include? &quot;x_&quot;
+      alias_method &quot;x_&quot;, &quot;xx_any_&quot; # supplant for now
+      def xx_cdata_ *objects, &amp;b
+#--{{{
+        doc = xx_doc
 
-table.report td.value {
-    text-align: right;
-    border: #d0d0d0 1px solid;
-}
+        cdata = ::REXML::CData::new &quot;&quot;
+
+        objects.each do |object| 
+          cdata &lt;&lt; object.to_s if object
+        end
+
+        doc.create cdata, &amp;b
+#--}}}
+      end
+      alias_method &quot;c_&quot;, &quot;xx_cdata_&quot;
+      def xx_parse_attributes string
+#--{{{
+        string = string.to_s
+        tokens = string.split %r/,/o
+        tokens.map{|t| t.sub!(%r/[^=]+=/){|key_eq| key_eq.chop &lt;&lt; &quot; : &quot;}}
+        xx_parse_yaml_attributes(tokens.join(','))
+#--}}}
+      end
+      alias_method &quot;att_&quot;, &quot;xx_parse_attributes&quot;
+      def xx_parse_yaml_attributes string
+#--{{{
+        require &quot;yaml&quot;
+        string = string.to_s
+        string = &quot;{&quot; &lt;&lt; string unless string =~ %r/^\s*[{]/o
+        string = string &lt;&lt; &quot;}&quot; unless string =~ %r/[}]\s*$/o
+        obj = ::YAML::load string
+        raise ArgumentError, &quot;&lt;#{ obj.class }&gt; not Hash!&quot; unless Hash === obj
+        obj
+#--}}}
+      end
+      alias_method &quot;at_&quot;, &quot;xx_parse_yaml_attributes&quot;
+      alias_method &quot;yat_&quot;, &quot;xx_parse_yaml_attributes&quot;
+      def xx_class
+#--{{{
+        @xx_class ||= self.class
+#--}}}
+      end
+      def xx_tag_method_name *a, &amp;b 
+#--{{{
+        xx_class.xx_tag_method_name(*a, &amp;b)
+#--}}}
+      end
+      def xx_define_tmp_method *a, &amp;b 
+#--{{{
+        xx_class.xx_define_tmp_methodr(*a, &amp;b)
+#--}}}
+      end
+      def xx_define_tag_method *a, &amp;b 
+#--{{{
+        xx_class.xx_define_tag_method(*a, &amp;b)
+#--}}}
+      end
+      def xx_remove_tag_method *a, &amp;b 
+#--{{{
+        xx_class.xx_tag_remove_method(*a, &amp;b)
+#--}}}
+      end
+      def xx_ancestors
+#--{{{
+        raise Error, &quot;no xx_which in effect&quot; unless xx_which
+        xx_class.xx_ancestors xx_which
+#--}}}
+      end
+      def xx_config
+#--{{{
+        xx_class.xx_config
+#--}}}
+      end
+      def xx_config_for *a, &amp;b
+#--{{{
+        xx_class.xx_config_for(*a, &amp;b)
+#--}}}
+      end
+      def xx_configure *a, &amp;b
+#--{{{
+        xx_class.xx_configure(*a, &amp;b)
+#--}}}
+      end
+#--}}}
+    end
+
+    module ClassMethods
+#--{{{
+      def xx_tag_method_name m
+#--{{{
+        m = m.to_s
+        tag_method, tag_name = m, m.gsub(%r/_+$/, &quot;&quot;)
+        [ tag_method, tag_name ]
+#--}}}
+      end
+      def xx_define_tmp_method m 
+#--{{{
+        define_method(m){ raise NotImplementedError, m.to_s }
+#--}}}
+      end
+      def xx_define_tag_method tag_method, tag_name = nil
+#--{{{
+        tag_method = tag_method.to_s
+        tag_name ||= tag_method.gsub %r/_+$/, &quot;&quot;
+
+        remove_method tag_method if instance_methods.include? tag_method
+        module_eval &lt;&lt;-code, __FILE__, __LINE__+1
+          def #{ tag_method } *a, &amp;b
+            hashes, nothashes = a.partition{|x| Hash === x}
+
+            doc = xx_doc
+            element = ::REXML::Element::new '#{ tag_name }'
+
+            hashes.each{|h| h.each{|k,v| element.add_attribute k.to_s, v}}
+            nothashes.each{|nh| element &lt;&lt; ::REXML::Text::new(nh.to_s)}
+
+            doc.create element, &amp;b
+          end
+        code
+        tag_method
+#--}}}
+      end
+      def xx_remove_tag_method tag_method
+#--{{{
+        remove_method tag_method rescue nil
+#--}}}
+      end
+      def xx_ancestors xx_which = self
+#--{{{
+        list = []
+        ancestors.each do |a|
+          list &lt;&lt; a if a &lt; xx_which
+        end
+        xx_which.ancestors.each do |a|
+          list &lt;&lt; a if a &lt;= Markup
+        end
+        list
+#--}}}
+      end
+      def xx_config
+#--{{{
+        @@xx_config ||= Hash::new{|h,k| h[k] = {}}
+#--}}}
+      end
+      def xx_config_for key, xx_which = nil 
+#--{{{
+        key = key.to_s 
+        xx_which ||= self
+        xx_ancestors(xx_which).each do |a|
+          if xx_config[a].has_key? key
+            return xx_config[a][key]
+          end
+        end
+        nil
+#--}}}
+      end
+      def xx_configure key, value, xx_which = nil 
+#--{{{
+        key = key.to_s
+        xx_which ||= self
+        xx_config[xx_which][key] = value
+#--}}}
+      end
+#--}}}
+    end
+
+    extend ClassMethods
+    include InstanceMethods
+
+    def self::included other, *a, &amp;b
+#--{{{
+      ret = super
+      other.module_eval do
+        include Markup::InstanceMethods
+        extend Markup::ClassMethods
+        class &lt;&lt; self
+          define_method(&quot;included&quot;, Markup::XX_MARKUP_RECURSIVE_INCLUSION_PROC)
+        end
+      end
+      ret
+#--}}}
+    end
+    XX_MARKUP_RECURSIVE_INCLUSION_PROC = method(&quot;included&quot;).to_proc
+
+    xx_configure &quot;method_missing&quot;, XX::PERMISSIVE
+    xx_configure &quot;tags&quot;, []
+    xx_configure &quot;doctype&quot;, nil
+    xx_configure &quot;xmldecl&quot;, nil
+#--}}}
+  end
+
+  module XHTML
+#--{{{
+    include Markup
+    xx_configure &quot;doctype&quot;, %(html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&quot;)
+
+    def xhtml_ which = XHTML, *a, &amp;b
+#--{{{
+      xx_which(which) do
+        doc = xx_with_doc_in_effect(*a, &amp;b)
+        ddoc = doc.doc
+        root = ddoc.root
+        if root and root.name and root.name =~ %r/^html$/i 
+          if root.attribute(&quot;lang&quot;,nil).nil? or root.attribute(&quot;lang&quot;,nil).to_s.empty?
+            root.add_attribute &quot;lang&quot;, &quot;en&quot;
+          end
+          if root.attribute(&quot;xml:lang&quot;).nil? or root.attribute(&quot;xml:lang&quot;).to_s.empty?
+            root.add_attribute &quot;xml:lang&quot;, &quot;en&quot;
+          end
+          if root.namespace.nil? or root.namespace.to_s.empty?
+            root.add_namespace &quot;http://www.w3.org/1999/xhtml&quot;
+          end
+        end
+        doc
+      end
+#--}}}
+    end
+
+    module Strict
+#--{{{
+      include XHTML
+      xx_configure &quot;doctype&quot;, %(html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Strict//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd&quot;)
+      xx_configure &quot;tags&quot;, %w(
+        html head body div span DOCTYPE title link meta style p
+        h1 h2 h3 h4 h5 h6 strong em abbr acronym address bdo blockquote cite q code
+        ins del dfn kbd pre samp var br a base img
+        area map object param ul ol li dl dt dd table
+        tr td th tbody thead tfoot col colgroup caption form input
+        textarea select option optgroup button label fieldset legend script noscript b
+        i tt sub sup big small hr
+      )
+      xx_configure &quot;method_missing&quot;, ::XX::STRICT
+
+      def xhtml_ which = XHTML::Strict, *a, &amp;b
+#--{{{
+        super(which, *a, &amp;b)
+#--}}}
+      end
+#--}}}
+    end
+
+    module Transitional
+#--{{{
+      include XHTML
+      xx_configure &quot;doctype&quot;, %(html PUBLIC &quot;-//W3C//DTD XHTML 1.0 Transitional//EN&quot; &quot;http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd&quot;)
+      def xhtml_ which = XHTML::Transitional, *a, &amp;b
+#--{{{
+        super(which, *a, &amp;b)
+#--}}}
+      end
+#--}}}
+    end
+#--}}}
+  end
+
+  module HTML4
+#--{{{
+    include Markup
+    xx_configure &quot;doctype&quot;, %(html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;)
+ 
+    def html4_ which = HTML4, *a, &amp;b
+#--{{{
+      xx_which(which){ xx_with_doc_in_effect(*a, &amp;b) }
+#--}}}
+    end
+
+    module Strict
+#--{{{
+      include HTML4
+      xx_configure &quot;doctype&quot;, %(html PUBLIC &quot;-//W3C//DTD HTML 4.01 Strict//EN&quot;)
+      xx_configure &quot;tags&quot;, %w(
+        html head body div span DOCTYPE title link meta style p
+        h1 h2 h3 h4 h5 h6 strong em abbr acronym address bdo blockquote cite q code
+        ins del dfn kbd pre samp var br a base img
+        area map object param ul ol li dl dt dd table
+        tr td th tbody thead tfoot col colgroup caption form input
+        textarea select option optgroup button label fieldset legend script noscript b
+        i tt sub sup big small hr
+      )
+      xx_configure &quot;method_missing&quot;, ::XX::STRICT
+      def html4_ which = HTML4::Strict, *a, &amp;b
+#--{{{
+        super(which, *a, &amp;b)
+#--}}}
+      end
+#--}}}
+    end
+
+    module Transitional
+#--{{{
+      include HTML4
+      xx_configure &quot;doctype&quot;, %(html PUBLIC &quot;-//W3C//DTD HTML 4.01 Transitional//EN&quot;)
+      def html4_ which = HTML4::Transitional, *a, &amp;b
+#--{{{
+        super(which, *a, &amp;b)
+#--}}}
+      end
+#--}}}
+    end
+#--}}}
+  end
+  HTML = HTML4
+
+  module XML
+#--{{{
+    include Markup
+    xx_configure &quot;xmldecl&quot;, ::REXML::XMLDecl::new
+
+    def xml_ *a, &amp;b
+#--{{{
+      xx_which(XML){ xx_with_doc_in_effect(*a, &amp;b)}
+#--}}}
+    end
+#--}}}
+  end
+#--}}}
+end
 
-/* vi: set sw=4: */
+$__xx_rb__ = __FILE__
+end
+
+
+
+
+
+
+
+
+
+
+#
+# simple examples - see samples/ dir for more complete examples
+#
+
+if __FILE__ == $0
+
+  class Table &lt; ::Array
+    include XX::XHTML::Strict
+    include XX::HTML4::Strict
+    include XX::XML
+
+    def doc 
+      html_{
+        head_{ title_{ &quot;xhtml/html4/xml demo&quot; } }
+
+        div_{
+          h_{ &quot;&lt; malformed html &amp; un-escaped symbols&quot; }
+        }
+
+        t_{ &quot;escaped &amp; text &gt; &lt;&quot; }
+
+        x_{ &quot;&lt;any_valid&gt; xml &lt;/any_valid&gt;&quot; }
+
+        div_(:style =&gt; :sweet){ 
+          em_ &quot;this is a table&quot;
+
+          table_(:width =&gt; 42, :height =&gt; 42){
+            each{|row| tr_{ row.each{|cell| td_ cell } } }
+          }
+        }
+
+        script_(:type =&gt; :dangerous){ cdata_{ &quot;javascript&quot; } }
+      }
+    end
+    def to_xhtml
+      xhtml_{ doc }
+    end
+    def to_html4
+      html4_{ doc }
+    end
+    def to_xml
+      xml_{ doc }
+    end
+  end
+
+  table = Table[ %w( 0 1 2 ), %w( a b c ) ]
+  
+  methods = %w( to_xhtml to_html4 to_xml )
+
+  methods.each do |method|
+    2.times{ puts &quot;-&quot; * 42 }
+    puts(table.send(method).pretty)
+    puts
+  end
+
+end
+# vi: set sw=4: </diff>
      <filename>bin/rcov</filename>
    </modified>
  </modified>
  <removed type="array">
    <removed>
      <filename>LICENSE.txt</filename>
    </removed>
    <removed>
      <filename>lib/xx-0.1.0-1.rb</filename>
    </removed>
  </removed>
  <parents type="array">
    <parent>
      <id>1319b33e3d9f0dbe1758d1252135af258b1797b5</id>
    </parent>
  </parents>
  <author>
    <name>Mauricio Fernandez</name>
    <email>mfp@acm.org</email>
  </author>
  <url>http://github.com/spicycode/rcov/commit/55975a72647e039a7ce094ec921db63589ea3d7f</url>
  <id>55975a72647e039a7ce094ec921db63589ea3d7f</id>
  <committed-date>2006-02-25T01:42:52-08:00</committed-date>
  <authored-date>2006-02-25T01:42:52-08:00</authored-date>
  <message>bin/rcov: Moved xx to rcov's DATA area. Updated legal info.

darcs-hash:20060225094252-0786a-e1014227b38ef043788975a148a9cf2d5ca8aca7.gz</message>
  <tree>22dd2471b1a88e9b80775bfbf44d1831ed6e5919</tree>
  <committer>
    <name>Mauricio Fernandez</name>
    <email>mfp@acm.org</email>
  </committer>
</commit>
