class OoxmlParser::DocumentSettings
Class for parsing ‘settings.xml` file
Attributes
@return [OoxmlSize] size of default tab
Public Instance Methods
Source
# File lib/ooxml_parser/docx_parser/document_structure/document_settings.rb, line 11 def parse settings_path = "#{root_object.unpacked_folder}word/settings.xml" return nil unless File.exist?(settings_path) doc = parse_xml(settings_path) doc.xpath('w:settings/*').each do |node_child| case node_child.name when 'defaultTabStop' @default_tab_stop = OoxmlSize.new.parse(node_child) end end self end
Parse Settings object @return [DocumentSettings] result of parsing