Class | SimplePDF::TextBox
In: | lib/simple_pdf.rb
Parent: | Object

### Methods

new

### Included Modules

DocumentStyles::StyleAlignment DocumentStyles::StyleMargin

### Attributes

font_size | [RW] |
text | [RW] |

### Public Class methods

new(text, font_size=10, options={})

[Source]

        # File lib/simple_pdf.rb, line 9
     9:     def initialize(text, font_size=10, options={})
    10:       @text = text
    11:       @font_size = font_size
    12:
    13:       options.each do |key,val|
    14:         case(key)
    15:         when :top_margin
    16:           self.margin[:top] = val
    17:         when :bottom_margin
    18:           self.margin[:bottom] = val
    19:         when :left_margin
    20:           self.margin[:left] = val
    21:         when :right_margin
    22:           self.margin[:right] = val
    23:         when :align
    24:           self.align = val
    25:         end
    26:       end
    27:     end

[Validate]