Class: Html2Doc

Inherits:
Object
  • Object
show all
Defined in:
lib/html2doc/xml.rb,
lib/html2doc/base.rb,
lib/html2doc/math.rb,
lib/html2doc/mime.rb,
lib/html2doc/lists.rb,
lib/html2doc/notes.rb,
lib/html2doc/version.rb

Constant Summary collapse

NOKOHEAD =
<<~HERE.freeze
  <!DOCTYPE html SYSTEM
  "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
  <html xmlns="http://www.w3.org/1999/xhtml">
  <head> <title></title> <meta charset="UTF-8" /> </head>
  <body> </body> </html>
HERE
DOCTYPE =
<<~DOCTYPE.freeze
  <!DOCTYPE html SYSTEM "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
DOCTYPE
<<~XML.freeze

  <xml>
  <w:WordDocument>
  <w:View>Print</w:View>
  <w:Zoom>100</w:Zoom>
  <w:DoNotOptimizeForBrowser/>
  </w:WordDocument>
  </xml>
  <meta http-equiv='Content-Type' content="text/html; charset=utf-8"/>
XML
MATHML_NS =
"http://www.w3.org/1998/Math/MathML".freeze
HTML_NS =
'xmlns="http://www.w3.org/1999/xhtml"'.freeze
OOXML_NS =
"http://schemas.openxmlformats.org/officeDocument/2006/math".freeze
STYLE_BEARING_NODE =
%w(p div td th li).map { |x| ".//ancestor::#{x}" }.join(" | ").freeze
IMAGE_PATH =
"//*[local-name() = 'img' or local-name() = 'imagedata']".freeze
IMAGE_IMAGEDATA =
".//*[local-name() = 'img' or local-name() = 'imagedata']".freeze
TOPLIST =
"[not(ancestor::ul) and not(ancestor::ol)]".freeze
FN =
"<span class='MsoFootnoteReference'>"\
"<span style='mso-special-character:footnote'/></span>".freeze
VERSION =
"1.12.0".freeze

Instance Method Summary collapse