lib/rvg/rvg.rb
# Construct a canvas or reuse an existing canvas.
# Execute drawing commands. Return the canvas.
Construct a canvas or reuse an existing canvas.
Execute drawing commands. Return the canvas.
Construct a canvas or reuse an existing canvas . Execute drawing commands . Return the canvas .
def draw
      raise StandardError, 'draw not permitted in nested RVG objects' if @nested
      @canvas ||= new_canvas 
      gc = Utility::GraphicContext.new
      add_outermost_primitives(gc)
      pp(self) if ENV['debug_rvg']
      print_gc(gc) if ENV['debug_prim']
      gc.draw(@canvas)
      @canvas
    end
def draw raise StandardError , 'draw not permitted in nested RVG objects' if @nested @canvas ||= new_canvas gc = Utility :: GraphicContext . new add_outermost_primitives ( gc ) pp ( self ) if ENV [ 'debug_rvg' ] print_gc ( gc ) if ENV [ 'debug_prim' ] gc . draw ( @canvas ) @canvas end
Construct a canvas or reuse an existing canvas.
Construct a canvas or reuse an existing canvas .
# allow drawing over existing canvas