Class: Magick::RVG::Utility::TextAttributes

### Home Classes Methods

### In Files

- lib/rvg/misc.rb

### Parent

Object

### Methods

- ::new
- #affine
- #baseline_shift
- #baseline_shift=
- #glyph_orientation_horizontal
- #glyph_orientation_horizontal=
- #glyph_orientation_vertical
- #glyph_orientation_vertical=
- #letter_spacing
- #letter_spacing=
- #non_default?
- #pop
- #push
- #set_affine
- #text_anchor
- #text_anchor=
- #word_spacing
- #word_spacing=
- #writing_mode
- #writing_mode=

### Files

- 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::SolidFill
- Magick::TextureFill
- Object

No matching classes.

# Magick::RVG::Utility::TextAttributes

### Constants

WRITING_MODE

### Public Class Methods

new() click to toggle source

    # File lib/rvg/misc.rb, line 353
    def initialize()
        @affine = Array.new
        @affine << Magick::AffineMatrix.new(1, 0, 0, 1, 0, 0)
        @baseline_shift = Array.new
        @baseline_shift << :baseline
        @glyph_orientation_horizontal = Array.new
        @glyph_orientation_horizontal << 0
        @glyph_orientation_vertical = Array.new
        @glyph_orientation_vertical << 90
        @letter_spacing = Array.new
        @letter_spacing << 0
        @text_anchor = Array.new
        @text_anchor << :start
        @word_spacing = Array.new
        @word_spacing << 0
        @writing_mode = Array.new
        @writing_mode << 'lr-tb'
    end

### Public Instance Methods

affine() click to toggle source

    # File lib/rvg/misc.rb, line 403
    def affine()
        @affine[-1]
    end

baseline_shift() click to toggle source

    # File lib/rvg/misc.rb, line 407
    def baseline_shift()
        @baseline_shift[-1]
    end

baseline_shift=(value) click to toggle source

    # File lib/rvg/misc.rb, line 411
    def baseline_shift=(value)
        @baseline_shift[-1] = value
    end

glyph_orientation_horizontal() click to toggle source

    # File lib/rvg/misc.rb, line 431
    def glyph_orientation_horizontal()
        @glyph_orientation_horizontal[-1]
    end

glyph_orientation_horizontal=(angle) click to toggle source

    # File lib/rvg/misc.rb, line 435
    def glyph_orientation_horizontal=(angle)
        @glyph_orientation_horizontal[-1] = angle
    end

glyph_orientation_vertical() click to toggle source

    # File lib/rvg/misc.rb, line 423
    def glyph_orientation_vertical()
        @glyph_orientation_vertical[-1]
    end

glyph_orientation_vertical=(angle) click to toggle source

    # File lib/rvg/misc.rb, line 427
    def glyph_orientation_vertical=(angle)
        @glyph_orientation_vertical[-1] = angle
    end

letter_spacing() click to toggle source

    # File lib/rvg/misc.rb, line 439
    def letter_spacing()
        @letter_spacing[-1]
    end

letter_spacing=(value) click to toggle source

    # File lib/rvg/misc.rb, line 443
    def letter_spacing=(value)
        @letter_spacing[-1] = value
    end

non_default?() click to toggle source

    # File lib/rvg/misc.rb, line 447
    def non_default?
        @baseline_shift[-1] != :baseline || @letter_spacing[-1] != 0 ||
        @word_spacing[-1] != 0 || @writing_mode[-1][/\Alr/].nil? ||
        @glyph_orientation_horizontal[-1] != 0
    end

pop() click to toggle source

    # File lib/rvg/misc.rb, line 383
    def pop()
        @affine.pop
        @baseline_shift.pop
        @text_anchor.pop
        @writing_mode.pop
        @glyph_orientation_vertical.pop
        @glyph_orientation_horizontal.pop
        @letter_spacing.pop
        @word_spacing.pop
    end

push() click to toggle source

    # File lib/rvg/misc.rb, line 372
    def push()
        @affine.push(@affine.last.dup)
        @baseline_shift.push(@baseline_shift.last)
        @text_anchor.push(@text_anchor.last)
        @writing_mode.push(@writing_mode.last.dup)
        @glyph_orientation_vertical.push(@glyph_orientation_vertical.last)
        @glyph_orientation_horizontal.push(@glyph_orientation_horizontal.last)
        @letter_spacing.push(@letter_spacing.last)
        @word_spacing.push(@word_spacing.last)
    end

set_affine(sx, rx, ry, sy, tx, ty) click to toggle source

    # File lib/rvg/misc.rb, line 394
    def set_affine(sx, rx, ry, sy, tx, ty)
        @affine[-1].sx = sx
        @affine[-1].rx = rx
        @affine[-1].ry = ry
        @affine[-1].sy = sy
        @affine[-1].tx = tx
        @affine[-1].ty = ty
    end

text_anchor() click to toggle source

    # File lib/rvg/misc.rb, line 415
    def text_anchor()
        @text_anchor[-1]
    end

text_anchor=(anchor) click to toggle source

    # File lib/rvg/misc.rb, line 419
    def text_anchor=(anchor)
        @text_anchor[-1] = anchor
    end

word_spacing() click to toggle source

    # File lib/rvg/misc.rb, line 453
    def word_spacing()
        @word_spacing[-1]
    end

word_spacing=(value) click to toggle source

    # File lib/rvg/misc.rb, line 457
    def word_spacing=(value)
        @word_spacing[-1] = value
    end

writing_mode() click to toggle source

    # File lib/rvg/misc.rb, line 461
    def writing_mode()
        @writing_mode[-1]
    end

writing_mode=(mode) click to toggle source

    # File lib/rvg/misc.rb, line 465
    def writing_mode=(mode)
        @writing_mode[-1] = WRITING_MODE.include?(mode) ? mode : 'lr-tb'
    end

[Validate]

Generated with the Darkfish Rdoc Generator 2.