Sha256: 1e032765aba7e3dc2cb0d2a8af420adbee761904ae9d65991c7c6026ee498616
Contents?: true
Size: 890 Bytes
Versions: 7
Compression:
Stored size: 890 Bytes
Contents
module OpenXml module DrawingML module Elements class TailEnd < OpenXml::Docx::Elements::Element namespace :a attribute :length, expects: :valid_end_size, displays_as: :len attribute :type, expects: :valid_end_type attribute :width, expects: :valid_end_size, displays_as: :w private def valid_end_size(value) ok_values = %i(lg med sm) message = "Invalid #{name} (#{value}). Valid values are: #{ok_values.join(", ")}." raise ArgumentError, message unless ok_values.include? value end def valid_end_type(value) ok_values = %i(arrow diamond none oval stealth triangle) message = "Invalid end type (#{value}). Valid values are: #{ok_values.join(", ")}." raise ArgumentError, message unless ok_values.include? value end end end end end
Version data entries
7 entries across 7 versions & 1 rubygems