Graphics::Primitive::Driver::TextLayout(3pm)

Graphics::Primitive::Driver::TextLayout3pm

Textlayout role

Usage

    package MyLayout;
    use Moose;
    with 'Graphics::Primitive::Driver::TextLayout';
    ...

Overview

Graphics::Primitive::Driver::TextLayout is a role for Driver text layout engines.

Methods

component

Set/Get the component from which to draw layout information.

height

Set/Get this layout's height

slice

Implemented by role consumer. Given an offset and an optional size, returns a TextBox containing lines from this layout that come as close to $size without exceeding it. This method is provided to allow incremental rendering of text. For example, if you have a series of containers 80 units high, you might write code like this:

  for(my $i = 0; $i < 3; $i++) {
      $textbox = $layout->slice($i * 80, 80);
      # render the text
  }
width

Set/Get this layout's width. Defaults to the width of the component supplied.

Releases

8 releases since Debian 6.0 (Squeeze); the text changed 4 times.

  1. 6.0
  2. 7
  3. 8
  4. 9–11
  5. 12–13

Author

Cory Watson, "<[email protected]>"

From libgraphics-primitive-perl 0.67-2 in Debian 13 (Trixie). Parsed by carta from the page's man source.