Font
class Font extends AbstractFont
Font implementation using the Imagick PHP extension.
Properties
protected string | $file | from AbstractFont | |
protected int | $size | from AbstractFont | |
protected ColorInterface | $color | from AbstractFont |
Methods
string
wrapText(string $string, int $maxWidth, int $angle = 0)
Split a string into multiple lines so that it fits a specific width.
from AbstractFont
getClassFactory()
Get the class factory instance to be used.
from AbstractFont
$this
from AbstractFont
box(string $string, int $angle = 0)
Gets BoxInterface of font size on the image based on string and angle.
Details
at line 33
__construct(Imagick $imagick, string $file, int $size, ColorInterface $color)
in AbstractFont at line 66
final string
getFile()
Gets the fontfile for current font.
in AbstractFont at line 76
final int
getSize()
Gets font's integer point size.
in AbstractFont at line 86
final ColorInterface
getColor()
Gets font's color.
in AbstractFont at line 96
string
wrapText(string $string, int $maxWidth, int $angle = 0)
Split a string into multiple lines so that it fits a specific width.
in AbstractFont at line 135
ClassFactoryInterface
getClassFactory()
Get the class factory instance to be used.
in AbstractFont at line 149
$this
setClassFactory(ClassFactoryInterface $classFactory)
Set the class factory instance to be used.
at line 45
BoxInterface
box(string $string, int $angle = 0)
Gets BoxInterface of font size on the image based on string and angle.