Class: Magick::RVG::Use

### Home Classes Methods

### In Files

- lib/rvg/container.rb

### Parent

Object

### Methods

- ::new

### Included Modules

- Magick::RVG::Stylable
- Magick::RVG::Transformable
- Magick::RVG::Duplicatable

### Files

- MANIFEST
- Makefile

### Class/Module Index

Quicksearch

- Magick
- Magick::DestroyedImageError
- Magick::Draw
- Magick::Enum
- Magick::FatalImageMagickError
- Magick::Geometry
- Magick::GeometryValue
- Magick::GradientFill
- Magick::HatchFill
- Magick::IPTC
- Magick::IPTC::Application
- Magick::IPTC::Envelope
- Magick::IPTC::ObjectData
- Magick::IPTC::Post_ObjectData_Descriptor
- Magick::IPTC::Pre_ObjectData_Descriptor
- Magick::Image
- Magick::Image::DrawOptions
- Magick::Image::Info
- Magick::Image::PolaroidOptions
- Magick::Image::View
- Magick::Image::View::Pixels
- Magick::Image::View::Rows
- Magick::ImageList
- Magick::ImageList::Montage
- Magick::ImageMagickError
- Magick::OptionalMethodArguments
- Magick::Pixel
- Magick::RVG
- Magick::RVG::Circle
- Magick::RVG::ClipPath
- Magick::RVG::Describable
- Magick::RVG::Duplicatable
- Magick::RVG::Ellipse
- Magick::RVG::Embellishable
- Magick::RVG::Group
- Magick::RVG::Image
- Magick::RVG::ImageConstructors
- Magick::RVG::Line
- Magick::RVG::Path
- Magick::RVG::PathData
- Magick::RVG::Pattern
- Magick::RVG::PolyShape
- Magick::RVG::Polygon
- Magick::RVG::Polyline
- Magick::RVG::PreserveAspectRatio
- Magick::RVG::Rect
- Magick::RVG::ShapeConstructors
- Magick::RVG::Stretchable
- Magick::RVG::StructureConstructors
- Magick::RVG::Stylable
- Magick::RVG::Text
- Magick::RVG::TextBase
- Magick::RVG::TextConstructors
- Magick::RVG::Transformable
- Magick::RVG::Use
- Magick::RVG::UseConstructors
- Magick::RVG::Utility
- Magick::RVG::Utility::DefaultTextStrategy
- Magick::RVG::Utility::GraphicContext
- Magick::RVG::Utility::LRTextStrategy
- Magick::RVG::Utility::RLTextStrategy
- Magick::RVG::Utility::TBTextStrategy
- Magick::RVG::Utility::TextAttributes
- Magick::RVG::Utility::TextStrategy
- Magick::TextureFill
- Object

No matching classes.

# Magick::RVG::Use

A Use object allows the re-use of RVG and RVG::Group objects within a container. Create a Use object with the RVG::UseConstructors#use method.

### Public Class Methods

new(element, x=0, y=0, width=nil, height=nil) click to toggle source

In a container, Use objects are created indirectly via the RVG::UseConstructors#use method. The `x` and `y` arguments can be used to specify an additional translation for the group. The `width` and `height` arguments specify a width and height for referenced RVG objects.

    # File lib/rvg/container.rb, line 104
    def initialize(element, x=0, y=0, width=nil, height=nil)
        super()

        # If the element is not a group, defs, symbol, or rvg,
        # wrap a group around it so it can get a transform and
        # possibly a new viewport.
        if ! element.respond_to?(:ref)
            @element = Group.new
            @element << element.deep_copy
        else
            @element = element.deep_copy
        end
        @element.ref(x, y, width, height)
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.