# tablepress/3.4/libraries/vendor/PhpSpreadsheet/Chart/AxisText.php

TablePress – Tables in WordPress made easy, version 3.4. 64 lines.

- Page: https://pluginprobe.com/plugins/tablepress/3.4/code/libraries/vendor/PhpSpreadsheet/Chart/AxisText.php
- Raw: https://pluginprobe.com/plugins/tablepress/3.4/raw/libraries/vendor/PhpSpreadsheet/Chart/AxisText.php
- Modified: 2025-01-08T09:25:54+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/tablepress/3.4/code/libraries/vendor/PhpSpreadsheet/Chart/AxisText.php#L10-L20`.

```php
<?php

namespace TablePress\PhpOffice\PhpSpreadsheet\Chart;

use TablePress\PhpOffice\PhpSpreadsheet\Style\Font;

class AxisText extends Properties
{
	private ?int $rotation = null;

	private Font $font;

	public function __construct()
	{
		parent::__construct();
		$this->font = new Font();
		$this->font->setSize(null, true);
	}

	public function setRotation(?int $rotation): self
	{
		$this->rotation = $rotation;

		return $this;
	}

	public function getRotation(): ?int
	{
		return $this->rotation;
	}

	public function getFillColorObject(): ChartColor
	{
		$fillColor = $this->font->getChartColor();
		if ($fillColor === null) {
			$fillColor = new ChartColor();
			$this->font->setChartColorFromObject($fillColor);
		}

		return $fillColor;
	}

	public function getFont(): Font
	{
		return $this->font;
	}

	public function setFont(Font $font): self
	{
		$this->font = $font;

		return $this;
	}

	/**
	 * Implement PHP __clone to create a deep clone, not just a shallow copy.
	 */
	public function __clone()
	{
		parent::__clone();
		$this->font = clone $this->font;
	}
}

```
