You are here

public function TextimageTextbox::getTranslatedBox in Textimage 7.3

Get a rotated box object.

Parameters

float $angle: rotation angle

array $offset: offset requested before rotation

array $top_left_corner_position: position of top left corner for rotation

File

classes/TextimageTextbox.inc, line 76
Textimage - Font textbox management class.

Class

TextimageTextbox
Textimage - Font textbox management class.

Code

public function getTranslatedBox($angle, $offset = NULL, $top_left_corner_position = NULL) {
  $output = clone $this;
  if ($offset) {
    $output
      ->translateBoxPoints($offset);
  }
  if ($angle) {
    $output
      ->rotateBoxPoints($angle, $top_left_corner_position);
  }
  return $output;
}