---
name: "Graphics::Primitive::TextBox"
section: "3pm"
platform: "linux"
package: "libgraphics-primitive-perl"
version: "0.67-2"
release: "Debian 13 (Trixie)"
platforms: ["linux"]
url: "https://new.carta.tech/Graphics::Primitive::TextBox"
---

# Graphics::Primitive::TextBox(3pm)

Text component

## NAME

Graphics::Primitive::TextBox - Text component

## DESCRIPTION

Graphics::Primitive::TextBox is a Component with text.

## SYNOPSIS

```
  use Graphics::Primitive::Font;
  use Graphics::Primitive::TextBox;
  my $tx = Graphics::Primitive::TextBox->new(
      font => Graphics::Primitive::Font->new(
          face => 'Myriad Pro',
          size => 12
      ),
      text => 'I am a textbox!'
  );
```

## WARNING

This component is likely to change drastically.  Here be dragons.

## METHODS

### Constructor

- *new*

  Creates a new Graphics::Primitive::TextBox.

### Instance Methods

- *angle*

  The angle this text will be rotated.

- *font*

  Set this textbox's font

- *horizontal\_alignment*

  Horizontal alignment.  See Graphics::Primitive::Aligned.

- *text*

  Set this textbox's text.

- *vertical\_alignment*

  Vertical alignment.  See Graphics::Primitive::Aligned.

## AUTHOR

Cory Watson, `"<gphat@cpan.org>"`

## COPYRIGHT & LICENSE

Copyright 2008-2010 by Cory G Watson.

This program is free software; you can redistribute it and/or modify it under the same terms as Perl itself.
