Method: RubyPost::Picture#precompile

Defined in:
lib/drawable.rb

#precompileObject

creates the definition of the picture that goes at the start of the file


36
37
38
39
40
41
42
# File 'lib/drawable.rb', line 36

def precompile
  str = "picture " + @name + ";\n"
  @draw_commands.each do |d| 
    str = str + d.compile +  "\n"
  end
  str = str + @name + " := currentpicture; currentpicture := " + @@org_picture + ";\n"
end