Class: RubyPost::CustomDrawable

Inherits:
Drawable show all
Defined in:
lib/drawable.rb

Overview

A custom drawable. Send it a metapost string

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(c = String.new) ⇒ CustomDrawable

Returns a new instance of CustomDrawable.



55
56
57
58
# File 'lib/drawable.rb', line 55

def initialize(c=String.new)
  super()
  @command = c
end

Instance Attribute Details

#command=(value) ⇒ Object (writeonly)

Sets the attribute command

Parameters:

  • value

    the value to set the attribute command to.



53
54
55
# File 'lib/drawable.rb', line 53

def command=(value)
  @command = value
end

Instance Method Details

#compileObject



60
61
62
# File 'lib/drawable.rb', line 60

def compile
  @command.compile
end