Method: Axlsx::VmlShape#initialize
- Defined in:
- lib/axlsx/drawing/vml_shape.rb
#initialize(options = {}) {|_self| ... } ⇒ VmlShape
Creates a new VmlShape
55 56 57 58 59 60 61 62 63 64 65 66 |
# File 'lib/axlsx/drawing/vml_shape.rb', line 55 def initialize(={}) @row = @column = @left_column = @top_row = @right_column = @bottom_row = 0 @left_offset = 15 @top_offset = 2 @right_offset = 50 @bottom_offset = 5 @id = (0...8).map{65.+(rand(25)).chr}.join .each do |o| self.send("#{o[0]}=", o[1]) if self.respond_to? "#{o[0]}=" end yield self if block_given? end |