Methods

Class Index [+]

Quicksearch

Magick::RVG::StructureConstructors

Methods that construct container objects within a container

Public Instance Methods

g(&block) click to toggle source

Defines a group.

This method constructs a new Group container object. The styles and transforms specified on this object will be used by objects contained within, unless overridden by an inner container or the contained object itself. Define grouped elements by calling RVG::Embellishable methods within the associated block.

     # File lib/rvg/embellishable.rb, line 378
378:             def g(&block)
379:                 group = Group.new(&block)
380:                 @content << group
381:                 return group
382:             end
rvg(cols, rows, x=0, y=0, &block) click to toggle source

Establishes a new viewport. [x, y] is the coordinate of the upper-left corner within the containing viewport. This is a container method. Styles and transforms specified on this object will be used by objects contained within, unless overridden by an inner container or the contained object itself.

     # File lib/rvg/embellishable.rb, line 356
356:             def rvg(cols, rows, x=0, y=0, &block)
357:                 rvg = Magick::RVG.new(cols, rows, &block)
358:                 begin
359:                     x, y = Float(x), Float(y)
360:                 rescue ArgumentError
361:                     args = [cols, rows, x, y]
362:                     raise ArgumentError, "at least one argument is not convertable to Float (got #{args.collect {|a| a.class}.join(', ')})"
363:                 end
364:                 rvg.corner(x, y)
365:                 @content << rvg
366:                 return rvg
367:             end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.