org-ruby 0.8.1 → 0.8.2
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.
- data/History.txt +8 -0
- data/lib/org-ruby.rb +1 -1
- data/lib/org-ruby/headline.rb +4 -0
- data/lib/org-ruby/html_output_buffer.rb +7 -2
- data/lib/org-ruby/html_symbol_replace.rb +343 -343
- data/lib/org-ruby/line.rb +31 -1
- data/lib/org-ruby/output_buffer.rb +6 -1
- data/lib/org-ruby/parser.rb +97 -4
- data/lib/org-ruby/textile_output_buffer.rb +1 -2
- data/lib/org-ruby/textile_symbol_replace.rb +343 -343
- metadata +6 -5
    
        data/History.txt
    CHANGED
    
    | @@ -1,3 +1,11 @@ | |
| 1 | 
            +
            == 0.8.2 / 2013-11-09
         | 
| 2 | 
            +
             | 
| 3 | 
            +
            * Manage the #+INCLUDE tag in org files (contribution by pierre-lecocq)
         | 
| 4 | 
            +
            * #+INCLUDE is disabled by default. Needs either ORG_RUBY_INCLUDE_ROOT or 
         | 
| 5 | 
            +
              ORG_RUBY_ENABLE_INCLUDE_FILES environment variables in order to be enabled.
         | 
| 6 | 
            +
            * Link abbreviations with #+LINK tag are supported (by pierre-lecocq too, thanks!)
         | 
| 7 | 
            +
            * Strip prepended commas added by Emacs Org mode to src/example blocks
         | 
| 8 | 
            +
             | 
| 1 9 | 
             
            == 0.8.1 / 2013-02-17
         | 
| 2 10 |  | 
| 3 11 | 
             
            * Fix for html escaping when code is inline
         | 
    
        data/lib/org-ruby.rb
    CHANGED
    
    
    
        data/lib/org-ruby/headline.rb
    CHANGED
    
    | @@ -28,6 +28,9 @@ module Orgmode | |
| 28 28 | 
             
                # The export state of this headline. See +ValidExportStates+.
         | 
| 29 29 | 
             
                attr_accessor :export_state
         | 
| 30 30 |  | 
| 31 | 
            +
                # Include the property drawer items found for the headline
         | 
| 32 | 
            +
                attr_accessor :property_drawer
         | 
| 33 | 
            +
             | 
| 31 34 | 
             
                # This is the regex that matches a line
         | 
| 32 35 | 
             
                LineRegexp = /^\*+\s+/
         | 
| 33 36 |  | 
| @@ -47,6 +50,7 @@ module Orgmode | |
| 47 50 | 
             
                  @body_lines = []
         | 
| 48 51 | 
             
                  @tags = []
         | 
| 49 52 | 
             
                  @export_state = :exclude
         | 
| 53 | 
            +
                  @property_drawer = { }
         | 
| 50 54 | 
             
                  if (@line =~ LineRegexp) then
         | 
| 51 55 | 
             
                    @level = $&.strip.length + offset
         | 
| 52 56 | 
             
                    @headline_text = $'.strip
         | 
| @@ -58,8 +58,7 @@ module Orgmode | |
| 58 58 | 
             
                # write out one of the block tags in the HtmlBlockTag constant to
         | 
| 59 59 | 
             
                # put this information in the HTML stream.
         | 
| 60 60 | 
             
                def push_mode(mode, indent)
         | 
| 61 | 
            -
                  super(mode)
         | 
| 62 | 
            -
                  @list_indent_stack.push(indent)
         | 
| 61 | 
            +
                  super(mode, indent)
         | 
| 63 62 |  | 
| 64 63 | 
             
                  if HtmlBlockTag[mode]
         | 
| 65 64 | 
             
                    unless ((mode_is_table?(mode) and skip_tables?) or
         | 
| @@ -306,6 +305,7 @@ module Orgmode | |
| 306 305 | 
             
                    end
         | 
| 307 306 |  | 
| 308 307 | 
             
                    if defi
         | 
| 308 | 
            +
                      link = @options[:link_abbrevs][link] if @options[:link_abbrevs].has_key? link
         | 
| 309 309 | 
             
                      "@<a href=\"#{link}\">#{defi}@</a>"
         | 
| 310 310 | 
             
                    else
         | 
| 311 311 | 
             
                      "@<img src=\"#{link}\" alt=\"#{link}\" />"
         | 
| @@ -359,6 +359,11 @@ module Orgmode | |
| 359 359 | 
             
                  strip_regexp = Regexp.new("^" + " " * @code_block_indent)
         | 
| 360 360 | 
             
                  @buffer.gsub!(strip_regexp, "")
         | 
| 361 361 | 
             
                  @code_block_indent = nil
         | 
| 362 | 
            +
             | 
| 363 | 
            +
                  # Strip proctective commas generated by Org mode (C-c ')
         | 
| 364 | 
            +
                  @buffer.gsub! /^\s*(,)(\s*)([*]|#\+)/ do |match|
         | 
| 365 | 
            +
                    "#{$2}#{$3}"
         | 
| 366 | 
            +
                  end
         | 
| 362 367 | 
             
                end
         | 
| 363 368 | 
             
              end                           # class HtmlOutputBuffer
         | 
| 364 369 | 
             
            end                             # module Orgmode
         | 
| @@ -2,351 +2,351 @@ | |
| 2 2 |  | 
| 3 3 | 
             
            module Orgmode
         | 
| 4 4 | 
             
              HtmlEntities = {
         | 
| 5 | 
            -
                "Agrave" | 
| 6 | 
            -
                "agrave" | 
| 7 | 
            -
                "Aacute" | 
| 8 | 
            -
                "aacute" | 
| 9 | 
            -
                "Acirc" | 
| 10 | 
            -
                "acirc" | 
| 11 | 
            -
                "Atilde" | 
| 12 | 
            -
                "atilde" | 
| 13 | 
            -
                "Auml" | 
| 14 | 
            -
                "auml" | 
| 15 | 
            -
                "Aring" | 
| 16 | 
            -
                "AA" | 
| 17 | 
            -
                "aring" | 
| 18 | 
            -
                "AElig" | 
| 19 | 
            -
                "aelig" | 
| 20 | 
            -
                "Ccedil" | 
| 21 | 
            -
                "ccedil" | 
| 22 | 
            -
                "Egrave" | 
| 23 | 
            -
                "egrave" | 
| 24 | 
            -
                "Eacute" | 
| 25 | 
            -
                "eacute" | 
| 26 | 
            -
                "Ecirc" | 
| 27 | 
            -
                "ecirc" | 
| 28 | 
            -
                "Euml" | 
| 29 | 
            -
                "euml" | 
| 30 | 
            -
                "Igrave" | 
| 31 | 
            -
                "igrave" | 
| 32 | 
            -
                "Iacute" | 
| 33 | 
            -
                "iacute" | 
| 34 | 
            -
                "Icirc" | 
| 35 | 
            -
                "icirc" | 
| 36 | 
            -
                "Iuml" | 
| 37 | 
            -
                "iuml" | 
| 38 | 
            -
                "Ntilde" | 
| 39 | 
            -
                "ntilde" | 
| 40 | 
            -
                "Ograve" | 
| 41 | 
            -
                "ograve" | 
| 42 | 
            -
                "Oacute" | 
| 43 | 
            -
                "oacute" | 
| 44 | 
            -
                "Ocirc" | 
| 45 | 
            -
                "ocirc" | 
| 46 | 
            -
                "Otilde" | 
| 47 | 
            -
                "otilde" | 
| 48 | 
            -
                "Ouml" | 
| 49 | 
            -
                "ouml" | 
| 50 | 
            -
                "Oslash" | 
| 51 | 
            -
                "oslash" | 
| 52 | 
            -
                "OElig" | 
| 53 | 
            -
                "oelig" | 
| 54 | 
            -
                "Scaron" | 
| 55 | 
            -
                "scaron" | 
| 56 | 
            -
                "szlig" | 
| 57 | 
            -
                "Ugrave" | 
| 58 | 
            -
                "ugrave" | 
| 59 | 
            -
                "Uacute" | 
| 60 | 
            -
                "uacute" | 
| 61 | 
            -
                "Ucirc" | 
| 62 | 
            -
                "ucirc" | 
| 63 | 
            -
                "Uuml" | 
| 64 | 
            -
                "uuml" | 
| 65 | 
            -
                "Yacute" | 
| 66 | 
            -
                "yacute" | 
| 67 | 
            -
                "Yuml" | 
| 68 | 
            -
                "yuml" | 
| 69 | 
            -
                "fnof" | 
| 70 | 
            -
                "real" | 
| 71 | 
            -
                "image" | 
| 72 | 
            -
                "weierp" | 
| 73 | 
            -
                "Alpha" | 
| 74 | 
            -
                "alpha" | 
| 75 | 
            -
                "Beta" | 
| 76 | 
            -
                "beta" | 
| 77 | 
            -
                "Gamma" | 
| 78 | 
            -
                "gamma" | 
| 79 | 
            -
                "Delta" | 
| 80 | 
            -
                "delta" | 
| 81 | 
            -
                "Epsilon" | 
| 82 | 
            -
                "epsilon" | 
| 83 | 
            -
                "varepsilon" | 
| 84 | 
            -
                "Zeta" | 
| 85 | 
            -
                "zeta" | 
| 86 | 
            -
                "Eta" | 
| 87 | 
            -
                "eta" | 
| 88 | 
            -
                "Theta" | 
| 89 | 
            -
                "theta" | 
| 90 | 
            -
                "thetasym" | 
| 91 | 
            -
                "vartheta" | 
| 92 | 
            -
                "Iota" | 
| 93 | 
            -
                "iota" | 
| 94 | 
            -
                "Kappa" | 
| 95 | 
            -
                "kappa" | 
| 96 | 
            -
                "Lambda" | 
| 97 | 
            -
                "lambda" | 
| 98 | 
            -
                "Mu" | 
| 99 | 
            -
                "mu" | 
| 100 | 
            -
                "nu" | 
| 101 | 
            -
                "Nu" | 
| 102 | 
            -
                "Xi" | 
| 103 | 
            -
                "xi" | 
| 104 | 
            -
                "Omicron" | 
| 105 | 
            -
                "omicron" | 
| 106 | 
            -
                "Pi" | 
| 107 | 
            -
                "pi" | 
| 108 | 
            -
                "Rho" | 
| 109 | 
            -
                "rho" | 
| 110 | 
            -
                "Sigma" | 
| 111 | 
            -
                "sigma" | 
| 112 | 
            -
                "sigmaf" | 
| 113 | 
            -
                "varsigma" | 
| 114 | 
            -
                "Tau" | 
| 115 | 
            -
                "Upsilon" | 
| 116 | 
            -
                "upsih" | 
| 117 | 
            -
                "upsilon" | 
| 118 | 
            -
                "Phi" | 
| 119 | 
            -
                "phi" | 
| 120 | 
            -
                "Chi" | 
| 121 | 
            -
                "chi" | 
| 122 | 
            -
                "acutex" | 
| 123 | 
            -
                "Psi" | 
| 124 | 
            -
                "psi" | 
| 125 | 
            -
                "tau" | 
| 126 | 
            -
                "Omega" | 
| 127 | 
            -
                "omega" | 
| 128 | 
            -
                "piv" | 
| 129 | 
            -
                "partial" | 
| 130 | 
            -
                "alefsym" | 
| 131 | 
            -
                "ETH" | 
| 132 | 
            -
                "eth" | 
| 133 | 
            -
                "THORN" | 
| 134 | 
            -
                "thorn" | 
| 135 | 
            -
                "dots" | 
| 136 | 
            -
                "hellip" | 
| 137 | 
            -
                "middot" | 
| 138 | 
            -
                "iexcl" | 
| 139 | 
            -
                "iquest" | 
| 140 | 
            -
                "shy" | 
| 141 | 
            -
                "ndash" | 
| 142 | 
            -
                "mdash" | 
| 143 | 
            -
                "quot" | 
| 144 | 
            -
                "acute" | 
| 145 | 
            -
                "ldquo" | 
| 146 | 
            -
                "rdquo" | 
| 147 | 
            -
                "bdquo" | 
| 148 | 
            -
                "lsquo" | 
| 149 | 
            -
                "rsquo" | 
| 150 | 
            -
                "sbquo" | 
| 151 | 
            -
                "laquo" | 
| 152 | 
            -
                "raquo" | 
| 153 | 
            -
                "lsaquo" | 
| 154 | 
            -
                "rsaquo" | 
| 155 | 
            -
                "circ" | 
| 156 | 
            -
                "vert" | 
| 157 | 
            -
                "brvbar" | 
| 158 | 
            -
                "sect" | 
| 159 | 
            -
                "amp" | 
| 160 | 
            -
                "lt" | 
| 161 | 
            -
                "gt" | 
| 162 | 
            -
                "tilde" | 
| 163 | 
            -
                "slash" | 
| 164 | 
            -
                "plus" | 
| 165 | 
            -
                "under" | 
| 166 | 
            -
                "equal" | 
| 167 | 
            -
                "asciicirc" | 
| 168 | 
            -
                "dagger" | 
| 169 | 
            -
                "Dagger" | 
| 170 | 
            -
                "nbsp" | 
| 171 | 
            -
                "ensp" | 
| 172 | 
            -
                "emsp" | 
| 173 | 
            -
                "thinsp" | 
| 174 | 
            -
                "curren" | 
| 175 | 
            -
                "cent" | 
| 176 | 
            -
                "pound" | 
| 177 | 
            -
                "yen" | 
| 178 | 
            -
                "euro" | 
| 179 | 
            -
                "EUR" | 
| 180 | 
            -
                "EURdig" | 
| 181 | 
            -
                "EURhv" | 
| 182 | 
            -
                "EURcr" | 
| 183 | 
            -
                "EURtm" | 
| 184 | 
            -
                "copy" | 
| 185 | 
            -
                "reg" | 
| 186 | 
            -
                "trade" | 
| 187 | 
            -
                "minus" | 
| 188 | 
            -
                "pm" | 
| 189 | 
            -
                "plusmn" | 
| 190 | 
            -
                "times" | 
| 191 | 
            -
                "frasl" | 
| 192 | 
            -
                "div" | 
| 193 | 
            -
                "frac12" | 
| 194 | 
            -
                "frac14" | 
| 195 | 
            -
                "frac34" | 
| 196 | 
            -
                "permil" | 
| 197 | 
            -
                "sup1" | 
| 198 | 
            -
                "sup2" | 
| 199 | 
            -
                "sup3" | 
| 200 | 
            -
                "radic" | 
| 201 | 
            -
                "sum" | 
| 202 | 
            -
                "prod" | 
| 203 | 
            -
                "micro" | 
| 204 | 
            -
                "macr" | 
| 205 | 
            -
                "deg" | 
| 206 | 
            -
                "prime" | 
| 207 | 
            -
                "Prime" | 
| 208 | 
            -
                "infin" | 
| 209 | 
            -
                "infty" | 
| 210 | 
            -
                "prop" | 
| 211 | 
            -
                "proptp" | 
| 212 | 
            -
                "not" | 
| 213 | 
            -
                "neg" | 
| 214 | 
            -
                "land" | 
| 215 | 
            -
                "wedge" | 
| 216 | 
            -
                "lor" | 
| 217 | 
            -
                "vee" | 
| 218 | 
            -
                "cap" | 
| 219 | 
            -
                "cup" | 
| 220 | 
            -
                "int" | 
| 221 | 
            -
                "there4" | 
| 222 | 
            -
                "sim" | 
| 223 | 
            -
                "cong" | 
| 224 | 
            -
                "simeq" | 
| 225 | 
            -
                "asymp" | 
| 226 | 
            -
                "approx" | 
| 227 | 
            -
                "ne" | 
| 228 | 
            -
                "neq" | 
| 229 | 
            -
                "equiv" | 
| 230 | 
            -
                "le" | 
| 231 | 
            -
                "ge" | 
| 232 | 
            -
                "sub" | 
| 233 | 
            -
                "subset" | 
| 234 | 
            -
                "sup" | 
| 235 | 
            -
                "supset" | 
| 236 | 
            -
                "nsub" | 
| 237 | 
            -
                "sube" | 
| 238 | 
            -
                "nsup" | 
| 239 | 
            -
                "supe" | 
| 240 | 
            -
                "forall" | 
| 241 | 
            -
                "exist" | 
| 242 | 
            -
                "exists" | 
| 243 | 
            -
                "empty" | 
| 244 | 
            -
                "emptyset" | 
| 245 | 
            -
                "isin" | 
| 246 | 
            -
                "in" | 
| 247 | 
            -
                "notin" | 
| 248 | 
            -
                "ni" | 
| 249 | 
            -
                "nabla" | 
| 250 | 
            -
                "ang" | 
| 251 | 
            -
                "angle" | 
| 252 | 
            -
                "perp" | 
| 253 | 
            -
                "sdot" | 
| 254 | 
            -
                "cdot" | 
| 255 | 
            -
                "lceil" | 
| 256 | 
            -
                "rceil" | 
| 257 | 
            -
                "lfloor" | 
| 258 | 
            -
                "rfloor" | 
| 259 | 
            -
                "lang" | 
| 260 | 
            -
                "rang" | 
| 261 | 
            -
                "larr" | 
| 262 | 
            -
                "leftarrow" | 
| 263 | 
            -
                "gets" | 
| 264 | 
            -
                "lArr" | 
| 265 | 
            -
                "Leftarrow" | 
| 266 | 
            -
                "uarr" | 
| 267 | 
            -
                "uparrow" | 
| 268 | 
            -
                "uArr" | 
| 269 | 
            -
                "Uparrow" | 
| 270 | 
            -
                "rarr" | 
| 271 | 
            -
                "to" | 
| 272 | 
            -
                "rightarrow" | 
| 273 | 
            -
                "rArr" | 
| 274 | 
            -
                "Rightarrow" | 
| 275 | 
            -
                "darr" | 
| 276 | 
            -
                "downarrow" | 
| 277 | 
            -
                "dArr" | 
| 278 | 
            -
                "Downarrow" | 
| 279 | 
            -
                "harr" | 
| 5 | 
            +
                "Agrave"         => "À",
         | 
| 6 | 
            +
                "agrave"         => "à",
         | 
| 7 | 
            +
                "Aacute"         => "Á",
         | 
| 8 | 
            +
                "aacute"         => "á",
         | 
| 9 | 
            +
                "Acirc"          => "Â",
         | 
| 10 | 
            +
                "acirc"          => "â",
         | 
| 11 | 
            +
                "Atilde"         => "Ã",
         | 
| 12 | 
            +
                "atilde"         => "ã",
         | 
| 13 | 
            +
                "Auml"           => "Ä",
         | 
| 14 | 
            +
                "auml"           => "ä",
         | 
| 15 | 
            +
                "Aring"          => "Å",
         | 
| 16 | 
            +
                "AA"             => "Å",
         | 
| 17 | 
            +
                "aring"          => "å",
         | 
| 18 | 
            +
                "AElig"          => "Æ",
         | 
| 19 | 
            +
                "aelig"          => "æ",
         | 
| 20 | 
            +
                "Ccedil"         => "Ç",
         | 
| 21 | 
            +
                "ccedil"         => "ç",
         | 
| 22 | 
            +
                "Egrave"         => "È",
         | 
| 23 | 
            +
                "egrave"         => "è",
         | 
| 24 | 
            +
                "Eacute"         => "É",
         | 
| 25 | 
            +
                "eacute"         => "é",
         | 
| 26 | 
            +
                "Ecirc"          => "Ê",
         | 
| 27 | 
            +
                "ecirc"          => "ê",
         | 
| 28 | 
            +
                "Euml"           => "Ë",
         | 
| 29 | 
            +
                "euml"           => "ë",
         | 
| 30 | 
            +
                "Igrave"         => "Ì",
         | 
| 31 | 
            +
                "igrave"         => "ì",
         | 
| 32 | 
            +
                "Iacute"         => "Í",
         | 
| 33 | 
            +
                "iacute"         => "í",
         | 
| 34 | 
            +
                "Icirc"          => "Î",
         | 
| 35 | 
            +
                "icirc"          => "î",
         | 
| 36 | 
            +
                "Iuml"           => "Ï",
         | 
| 37 | 
            +
                "iuml"           => "ï",
         | 
| 38 | 
            +
                "Ntilde"         => "Ñ",
         | 
| 39 | 
            +
                "ntilde"         => "ñ",
         | 
| 40 | 
            +
                "Ograve"         => "Ò",
         | 
| 41 | 
            +
                "ograve"         => "ò",
         | 
| 42 | 
            +
                "Oacute"         => "Ó",
         | 
| 43 | 
            +
                "oacute"         => "ó",
         | 
| 44 | 
            +
                "Ocirc"          => "Ô",
         | 
| 45 | 
            +
                "ocirc"          => "ô",
         | 
| 46 | 
            +
                "Otilde"         => "Õ",
         | 
| 47 | 
            +
                "otilde"         => "õ",
         | 
| 48 | 
            +
                "Ouml"           => "Ö",
         | 
| 49 | 
            +
                "ouml"           => "ö",
         | 
| 50 | 
            +
                "Oslash"         => "Ø",
         | 
| 51 | 
            +
                "oslash"         => "ø",
         | 
| 52 | 
            +
                "OElig"          => "Œ",
         | 
| 53 | 
            +
                "oelig"          => "œ",
         | 
| 54 | 
            +
                "Scaron"         => "Š",
         | 
| 55 | 
            +
                "scaron"         => "š",
         | 
| 56 | 
            +
                "szlig"          => "ß",
         | 
| 57 | 
            +
                "Ugrave"         => "Ù",
         | 
| 58 | 
            +
                "ugrave"         => "ù",
         | 
| 59 | 
            +
                "Uacute"         => "Ú",
         | 
| 60 | 
            +
                "uacute"         => "ú",
         | 
| 61 | 
            +
                "Ucirc"          => "Û",
         | 
| 62 | 
            +
                "ucirc"          => "û",
         | 
| 63 | 
            +
                "Uuml"           => "Ü",
         | 
| 64 | 
            +
                "uuml"           => "ü",
         | 
| 65 | 
            +
                "Yacute"         => "Ý",
         | 
| 66 | 
            +
                "yacute"         => "ý",
         | 
| 67 | 
            +
                "Yuml"           => "Ÿ",
         | 
| 68 | 
            +
                "yuml"           => "ÿ",
         | 
| 69 | 
            +
                "fnof"           => "ƒ",
         | 
| 70 | 
            +
                "real"           => "ℜ",
         | 
| 71 | 
            +
                "image"          => "ℑ",
         | 
| 72 | 
            +
                "weierp"         => "℘",
         | 
| 73 | 
            +
                "Alpha"          => "Α",
         | 
| 74 | 
            +
                "alpha"          => "α",
         | 
| 75 | 
            +
                "Beta"           => "Β",
         | 
| 76 | 
            +
                "beta"           => "β",
         | 
| 77 | 
            +
                "Gamma"          => "Γ",
         | 
| 78 | 
            +
                "gamma"          => "γ",
         | 
| 79 | 
            +
                "Delta"          => "Δ",
         | 
| 80 | 
            +
                "delta"          => "δ",
         | 
| 81 | 
            +
                "Epsilon"        => "Ε",
         | 
| 82 | 
            +
                "epsilon"        => "ε",
         | 
| 83 | 
            +
                "varepsilon"     => "ε",
         | 
| 84 | 
            +
                "Zeta"           => "Ζ",
         | 
| 85 | 
            +
                "zeta"           => "ζ",
         | 
| 86 | 
            +
                "Eta"            => "Η",
         | 
| 87 | 
            +
                "eta"            => "η",
         | 
| 88 | 
            +
                "Theta"          => "Θ",
         | 
| 89 | 
            +
                "theta"          => "θ",
         | 
| 90 | 
            +
                "thetasym"       => "ϑ",
         | 
| 91 | 
            +
                "vartheta"       => "ϑ",
         | 
| 92 | 
            +
                "Iota"           => "Ι",
         | 
| 93 | 
            +
                "iota"           => "ι",
         | 
| 94 | 
            +
                "Kappa"          => "Κ",
         | 
| 95 | 
            +
                "kappa"          => "κ",
         | 
| 96 | 
            +
                "Lambda"         => "Λ",
         | 
| 97 | 
            +
                "lambda"         => "λ",
         | 
| 98 | 
            +
                "Mu"             => "Μ",
         | 
| 99 | 
            +
                "mu"             => "μ",
         | 
| 100 | 
            +
                "nu"             => "ν",
         | 
| 101 | 
            +
                "Nu"             => "Ν",
         | 
| 102 | 
            +
                "Xi"             => "Ξ",
         | 
| 103 | 
            +
                "xi"             => "ξ",
         | 
| 104 | 
            +
                "Omicron"        => "Ο",
         | 
| 105 | 
            +
                "omicron"        => "ο",
         | 
| 106 | 
            +
                "Pi"             => "Π",
         | 
| 107 | 
            +
                "pi"             => "π",
         | 
| 108 | 
            +
                "Rho"            => "Ρ",
         | 
| 109 | 
            +
                "rho"            => "ρ",
         | 
| 110 | 
            +
                "Sigma"          => "Σ",
         | 
| 111 | 
            +
                "sigma"          => "σ",
         | 
| 112 | 
            +
                "sigmaf"         => "ς",
         | 
| 113 | 
            +
                "varsigma"       => "ς",
         | 
| 114 | 
            +
                "Tau"            => "Τ",
         | 
| 115 | 
            +
                "Upsilon"        => "Υ",
         | 
| 116 | 
            +
                "upsih"          => "ϒ",
         | 
| 117 | 
            +
                "upsilon"        => "υ",
         | 
| 118 | 
            +
                "Phi"            => "Φ",
         | 
| 119 | 
            +
                "phi"            => "φ",
         | 
| 120 | 
            +
                "Chi"            => "Χ",
         | 
| 121 | 
            +
                "chi"            => "χ",
         | 
| 122 | 
            +
                "acutex"         => "´x",
         | 
| 123 | 
            +
                "Psi"            => "Ψ",
         | 
| 124 | 
            +
                "psi"            => "ψ",
         | 
| 125 | 
            +
                "tau"            => "τ",
         | 
| 126 | 
            +
                "Omega"          => "Ω",
         | 
| 127 | 
            +
                "omega"          => "ω",
         | 
| 128 | 
            +
                "piv"            => "ϖ",
         | 
| 129 | 
            +
                "partial"        => "∂",
         | 
| 130 | 
            +
                "alefsym"        => "ℵ",
         | 
| 131 | 
            +
                "ETH"            => "Ð",
         | 
| 132 | 
            +
                "eth"            => "ð",
         | 
| 133 | 
            +
                "THORN"          => "Þ",
         | 
| 134 | 
            +
                "thorn"          => "þ",
         | 
| 135 | 
            +
                "dots"           => "…",
         | 
| 136 | 
            +
                "hellip"         => "…",
         | 
| 137 | 
            +
                "middot"         => "·",
         | 
| 138 | 
            +
                "iexcl"          => "¡",
         | 
| 139 | 
            +
                "iquest"         => "¿",
         | 
| 140 | 
            +
                "shy"            => "­",
         | 
| 141 | 
            +
                "ndash"          => "–",
         | 
| 142 | 
            +
                "mdash"          => "—",
         | 
| 143 | 
            +
                "quot"           => """,
         | 
| 144 | 
            +
                "acute"          => "´",
         | 
| 145 | 
            +
                "ldquo"          => "“",
         | 
| 146 | 
            +
                "rdquo"          => "”",
         | 
| 147 | 
            +
                "bdquo"          => "„",
         | 
| 148 | 
            +
                "lsquo"          => "‘",
         | 
| 149 | 
            +
                "rsquo"          => "’",
         | 
| 150 | 
            +
                "sbquo"          => "‚",
         | 
| 151 | 
            +
                "laquo"          => "«",
         | 
| 152 | 
            +
                "raquo"          => "»",
         | 
| 153 | 
            +
                "lsaquo"         => "‹",
         | 
| 154 | 
            +
                "rsaquo"         => "›",
         | 
| 155 | 
            +
                "circ"           => "ˆ",
         | 
| 156 | 
            +
                "vert"           => "|",
         | 
| 157 | 
            +
                "brvbar"         => "¦",
         | 
| 158 | 
            +
                "sect"           => "§",
         | 
| 159 | 
            +
                "amp"            => "&",
         | 
| 160 | 
            +
                "lt"             => "<",
         | 
| 161 | 
            +
                "gt"             => ">",
         | 
| 162 | 
            +
                "tilde"          => "˜",
         | 
| 163 | 
            +
                "slash"          => "/",
         | 
| 164 | 
            +
                "plus"           => "+",
         | 
| 165 | 
            +
                "under"          => "_",
         | 
| 166 | 
            +
                "equal"          => "=",
         | 
| 167 | 
            +
                "asciicirc"      => "^",
         | 
| 168 | 
            +
                "dagger"         => "†",
         | 
| 169 | 
            +
                "Dagger"         => "‡",
         | 
| 170 | 
            +
                "nbsp"           => " ",
         | 
| 171 | 
            +
                "ensp"           => " ",
         | 
| 172 | 
            +
                "emsp"           => " ",
         | 
| 173 | 
            +
                "thinsp"         => " ",
         | 
| 174 | 
            +
                "curren"         => "¤",
         | 
| 175 | 
            +
                "cent"           => "¢",
         | 
| 176 | 
            +
                "pound"          => "£",
         | 
| 177 | 
            +
                "yen"            => "¥",
         | 
| 178 | 
            +
                "euro"           => "€",
         | 
| 179 | 
            +
                "EUR"            => "€",
         | 
| 180 | 
            +
                "EURdig"         => "€",
         | 
| 181 | 
            +
                "EURhv"          => "€",
         | 
| 182 | 
            +
                "EURcr"          => "€",
         | 
| 183 | 
            +
                "EURtm"          => "€",
         | 
| 184 | 
            +
                "copy"           => "©",
         | 
| 185 | 
            +
                "reg"            => "®",
         | 
| 186 | 
            +
                "trade"          => "™",
         | 
| 187 | 
            +
                "minus"          => "−",
         | 
| 188 | 
            +
                "pm"             => "±",
         | 
| 189 | 
            +
                "plusmn"         => "±",
         | 
| 190 | 
            +
                "times"          => "×",
         | 
| 191 | 
            +
                "frasl"          => "⁄",
         | 
| 192 | 
            +
                "div"            => "÷",
         | 
| 193 | 
            +
                "frac12"         => "½",
         | 
| 194 | 
            +
                "frac14"         => "¼",
         | 
| 195 | 
            +
                "frac34"         => "¾",
         | 
| 196 | 
            +
                "permil"         => "‰",
         | 
| 197 | 
            +
                "sup1"           => "¹",
         | 
| 198 | 
            +
                "sup2"           => "²",
         | 
| 199 | 
            +
                "sup3"           => "³",
         | 
| 200 | 
            +
                "radic"          => "√",
         | 
| 201 | 
            +
                "sum"            => "∑",
         | 
| 202 | 
            +
                "prod"           => "∏",
         | 
| 203 | 
            +
                "micro"          => "µ",
         | 
| 204 | 
            +
                "macr"           => "¯",
         | 
| 205 | 
            +
                "deg"            => "°",
         | 
| 206 | 
            +
                "prime"          => "′",
         | 
| 207 | 
            +
                "Prime"          => "″",
         | 
| 208 | 
            +
                "infin"          => "∞",
         | 
| 209 | 
            +
                "infty"          => "∞",
         | 
| 210 | 
            +
                "prop"           => "∝",
         | 
| 211 | 
            +
                "proptp"         => "∝",
         | 
| 212 | 
            +
                "not"            => "¬",
         | 
| 213 | 
            +
                "neg"            => "¬",
         | 
| 214 | 
            +
                "land"           => "∧",
         | 
| 215 | 
            +
                "wedge"          => "∧",
         | 
| 216 | 
            +
                "lor"            => "∨",
         | 
| 217 | 
            +
                "vee"            => "∨",
         | 
| 218 | 
            +
                "cap"            => "∩",
         | 
| 219 | 
            +
                "cup"            => "∪",
         | 
| 220 | 
            +
                "int"            => "∫",
         | 
| 221 | 
            +
                "there4"         => "∴",
         | 
| 222 | 
            +
                "sim"            => "∼",
         | 
| 223 | 
            +
                "cong"           => "≅",
         | 
| 224 | 
            +
                "simeq"          => "≅",
         | 
| 225 | 
            +
                "asymp"          => "≈",
         | 
| 226 | 
            +
                "approx"         => "≈",
         | 
| 227 | 
            +
                "ne"             => "≠",
         | 
| 228 | 
            +
                "neq"            => "≠",
         | 
| 229 | 
            +
                "equiv"          => "≡",
         | 
| 230 | 
            +
                "le"             => "≤",
         | 
| 231 | 
            +
                "ge"             => "≥",
         | 
| 232 | 
            +
                "sub"            => "⊂",
         | 
| 233 | 
            +
                "subset"         => "⊂",
         | 
| 234 | 
            +
                "sup"            => "⊃",
         | 
| 235 | 
            +
                "supset"         => "⊃",
         | 
| 236 | 
            +
                "nsub"           => "⊄",
         | 
| 237 | 
            +
                "sube"           => "⊆",
         | 
| 238 | 
            +
                "nsup"           => "⊅",
         | 
| 239 | 
            +
                "supe"           => "⊇",
         | 
| 240 | 
            +
                "forall"         => "∀",
         | 
| 241 | 
            +
                "exist"          => "∃",
         | 
| 242 | 
            +
                "exists"         => "∃",
         | 
| 243 | 
            +
                "empty"          => "∅",
         | 
| 244 | 
            +
                "emptyset"       => "∅",
         | 
| 245 | 
            +
                "isin"           => "∈",
         | 
| 246 | 
            +
                "in"             => "∈",
         | 
| 247 | 
            +
                "notin"          => "∉",
         | 
| 248 | 
            +
                "ni"             => "∋",
         | 
| 249 | 
            +
                "nabla"          => "∇",
         | 
| 250 | 
            +
                "ang"            => "∠",
         | 
| 251 | 
            +
                "angle"          => "∠",
         | 
| 252 | 
            +
                "perp"           => "⊥",
         | 
| 253 | 
            +
                "sdot"           => "⋅",
         | 
| 254 | 
            +
                "cdot"           => "⋅",
         | 
| 255 | 
            +
                "lceil"          => "⌈",
         | 
| 256 | 
            +
                "rceil"          => "⌉",
         | 
| 257 | 
            +
                "lfloor"         => "⌊",
         | 
| 258 | 
            +
                "rfloor"         => "⌋",
         | 
| 259 | 
            +
                "lang"           => "⟨",
         | 
| 260 | 
            +
                "rang"           => "⟩",
         | 
| 261 | 
            +
                "larr"           => "←",
         | 
| 262 | 
            +
                "leftarrow"      => "←",
         | 
| 263 | 
            +
                "gets"           => "←",
         | 
| 264 | 
            +
                "lArr"           => "⇐",
         | 
| 265 | 
            +
                "Leftarrow"      => "⇐",
         | 
| 266 | 
            +
                "uarr"           => "↑",
         | 
| 267 | 
            +
                "uparrow"        => "↑",
         | 
| 268 | 
            +
                "uArr"           => "⇑",
         | 
| 269 | 
            +
                "Uparrow"        => "⇑",
         | 
| 270 | 
            +
                "rarr"           => "→",
         | 
| 271 | 
            +
                "to"             => "→",
         | 
| 272 | 
            +
                "rightarrow"     => "→",
         | 
| 273 | 
            +
                "rArr"           => "⇒",
         | 
| 274 | 
            +
                "Rightarrow"     => "⇒",
         | 
| 275 | 
            +
                "darr"           => "↓",
         | 
| 276 | 
            +
                "downarrow"      => "↓",
         | 
| 277 | 
            +
                "dArr"           => "⇓",
         | 
| 278 | 
            +
                "Downarrow"      => "⇓",
         | 
| 279 | 
            +
                "harr"           => "↔",
         | 
| 280 280 | 
             
                "leftrightarrow" => "↔",
         | 
| 281 | 
            -
                "hArr" | 
| 281 | 
            +
                "hArr"           => "⇔",
         | 
| 282 282 | 
             
                "Leftrightarrow" => "⇔",
         | 
| 283 | 
            -
                "crarr" | 
| 284 | 
            -
                "hookleftarrow" | 
| 285 | 
            -
                "arccos" | 
| 286 | 
            -
                "arcsin" | 
| 287 | 
            -
                "arctan" | 
| 288 | 
            -
                "arg" | 
| 289 | 
            -
                "cos" | 
| 290 | 
            -
                "cosh" | 
| 291 | 
            -
                "cot" | 
| 292 | 
            -
                "coth" | 
| 293 | 
            -
                "csc" | 
| 294 | 
            -
                "deg" | 
| 295 | 
            -
                "det" | 
| 296 | 
            -
                "dim" | 
| 297 | 
            -
                "exp" | 
| 298 | 
            -
                "gcd" | 
| 299 | 
            -
                "hom" | 
| 300 | 
            -
                "inf" | 
| 301 | 
            -
                "ker" | 
| 302 | 
            -
                "lg" | 
| 303 | 
            -
                "lim" | 
| 304 | 
            -
                "liminf" | 
| 305 | 
            -
                "limsup" | 
| 306 | 
            -
                "ln" | 
| 307 | 
            -
                "log" | 
| 308 | 
            -
                "max" | 
| 309 | 
            -
                "min" | 
| 310 | 
            -
                "Pr" | 
| 311 | 
            -
                "sec" | 
| 312 | 
            -
                "sin" | 
| 313 | 
            -
                "sinh" | 
| 314 | 
            -
                "sup" | 
| 315 | 
            -
                "tan" | 
| 316 | 
            -
                "tanh" | 
| 317 | 
            -
                "bull" | 
| 318 | 
            -
                "bullet" | 
| 319 | 
            -
                "star" | 
| 320 | 
            -
                "lowast" | 
| 321 | 
            -
                "ast" | 
| 322 | 
            -
                "odot" | 
| 323 | 
            -
                "oplus" | 
| 324 | 
            -
                "otimes" | 
| 325 | 
            -
                "checkmark" | 
| 326 | 
            -
                "para" | 
| 327 | 
            -
                "ordf" | 
| 328 | 
            -
                "ordm" | 
| 329 | 
            -
                "cedil" | 
| 330 | 
            -
                "oline" | 
| 331 | 
            -
                "uml" | 
| 332 | 
            -
                "zwnj" | 
| 333 | 
            -
                "zwj" | 
| 334 | 
            -
                "lrm" | 
| 335 | 
            -
                "rlm" | 
| 336 | 
            -
                "smile" | 
| 337 | 
            -
                "smiley" | 
| 338 | 
            -
                "blacksmile" | 
| 339 | 
            -
                "sad" | 
| 340 | 
            -
                "clubs" | 
| 341 | 
            -
                "clubsuit" | 
| 342 | 
            -
                "spades" | 
| 343 | 
            -
                "spadesuit" | 
| 344 | 
            -
                "hearts" | 
| 345 | 
            -
                "heartsuit" | 
| 346 | 
            -
                "diams" | 
| 347 | 
            -
                "diamondsuit" | 
| 348 | 
            -
                "Diamond" | 
| 349 | 
            -
                "loz" | 
| 283 | 
            +
                "crarr"          => "↵",
         | 
| 284 | 
            +
                "hookleftarrow"  => "↵",
         | 
| 285 | 
            +
                "arccos"         => "arccos",
         | 
| 286 | 
            +
                "arcsin"         => "arcsin",
         | 
| 287 | 
            +
                "arctan"         => "arctan",
         | 
| 288 | 
            +
                "arg"            => "arg",
         | 
| 289 | 
            +
                "cos"            => "cos",
         | 
| 290 | 
            +
                "cosh"           => "cosh",
         | 
| 291 | 
            +
                "cot"            => "cot",
         | 
| 292 | 
            +
                "coth"           => "coth",
         | 
| 293 | 
            +
                "csc"            => "csc",
         | 
| 294 | 
            +
                "deg"            => "°",
         | 
| 295 | 
            +
                "det"            => "det",
         | 
| 296 | 
            +
                "dim"            => "dim",
         | 
| 297 | 
            +
                "exp"            => "exp",
         | 
| 298 | 
            +
                "gcd"            => "gcd",
         | 
| 299 | 
            +
                "hom"            => "hom",
         | 
| 300 | 
            +
                "inf"            => "inf",
         | 
| 301 | 
            +
                "ker"            => "ker",
         | 
| 302 | 
            +
                "lg"             => "lg",
         | 
| 303 | 
            +
                "lim"            => "lim",
         | 
| 304 | 
            +
                "liminf"         => "liminf",
         | 
| 305 | 
            +
                "limsup"         => "limsup",
         | 
| 306 | 
            +
                "ln"             => "ln",
         | 
| 307 | 
            +
                "log"            => "log",
         | 
| 308 | 
            +
                "max"            => "max",
         | 
| 309 | 
            +
                "min"            => "min",
         | 
| 310 | 
            +
                "Pr"             => "Pr",
         | 
| 311 | 
            +
                "sec"            => "sec",
         | 
| 312 | 
            +
                "sin"            => "sin",
         | 
| 313 | 
            +
                "sinh"           => "sinh",
         | 
| 314 | 
            +
                "sup"            => "⊃",
         | 
| 315 | 
            +
                "tan"            => "tan",
         | 
| 316 | 
            +
                "tanh"           => "tanh",
         | 
| 317 | 
            +
                "bull"           => "•",
         | 
| 318 | 
            +
                "bullet"         => "•",
         | 
| 319 | 
            +
                "star"           => "*",
         | 
| 320 | 
            +
                "lowast"         => "∗",
         | 
| 321 | 
            +
                "ast"            => "∗",
         | 
| 322 | 
            +
                "odot"           => "o",
         | 
| 323 | 
            +
                "oplus"          => "⊕",
         | 
| 324 | 
            +
                "otimes"         => "⊗",
         | 
| 325 | 
            +
                "checkmark"      => "✓",
         | 
| 326 | 
            +
                "para"           => "¶",
         | 
| 327 | 
            +
                "ordf"           => "ª",
         | 
| 328 | 
            +
                "ordm"           => "º",
         | 
| 329 | 
            +
                "cedil"          => "¸",
         | 
| 330 | 
            +
                "oline"          => "‾",
         | 
| 331 | 
            +
                "uml"            => "¨",
         | 
| 332 | 
            +
                "zwnj"           => "‌",
         | 
| 333 | 
            +
                "zwj"            => "‍",
         | 
| 334 | 
            +
                "lrm"            => "‎",
         | 
| 335 | 
            +
                "rlm"            => "‏",
         | 
| 336 | 
            +
                "smile"          => "☺",
         | 
| 337 | 
            +
                "smiley"         => "☺",
         | 
| 338 | 
            +
                "blacksmile"     => "☻",
         | 
| 339 | 
            +
                "sad"            => "☹",
         | 
| 340 | 
            +
                "clubs"          => "♣",
         | 
| 341 | 
            +
                "clubsuit"       => "♣",
         | 
| 342 | 
            +
                "spades"         => "♠",
         | 
| 343 | 
            +
                "spadesuit"      => "♠",
         | 
| 344 | 
            +
                "hearts"         => "♥",
         | 
| 345 | 
            +
                "heartsuit"      => "♥",
         | 
| 346 | 
            +
                "diams"          => "♦",
         | 
| 347 | 
            +
                "diamondsuit"    => "♦",
         | 
| 348 | 
            +
                "Diamond"        => "⋄",
         | 
| 349 | 
            +
                "loz"            => "◊"
         | 
| 350 350 | 
             
              }
         | 
| 351 351 | 
             
              @org_entities_regexp = /\\(there4|sup[123]|frac[13][24]|[a-zA-Z]+)($|\{\}|[^a-zA-Z])/
         | 
| 352 352 |  |