class OoxmlParser::DocxShapeLinePath
Docx Shape
Line Path
Attributes
Public Class Methods
Source
# File lib/ooxml_parser/common_parser/common_data/alternate_content/drawing/graphic/shape/shape_properties/custom_geometry/docx_custom_geometry/docx_shape_line_path.rb, line 9 def initialize(elements = [], parent: nil) @elements = elements super(parent: parent) end
Calls superclass method
Public Instance Methods
Source
# File lib/ooxml_parser/common_parser/common_data/alternate_content/drawing/graphic/shape/shape_properties/custom_geometry/docx_custom_geometry/docx_shape_line_path.rb, line 17 def parse(node) node.attributes.each do |key, value| case key when 'w' @width = value.value.to_f when 'h' @height = value.value.to_f when 'stroke' @stroke = value.value.to_f end end node.xpath('*').each do |node_child| @elements << DocxShapeLineElement.new(parent: self).parse(node_child) end self end
Parse DocxShapeLinePath
object @param node [Nokogiri::XML:Element] node to parse @return [DocxShapeLinePath] result of parsing