public function __construct($name, $size) { parent::__construct($name, $size); if ($this->getExtension() === NULL) { $this->setExtension('ttf'); } }
public function __construct($name, $size) { parent::__construct($name, $size); $this->extension = 'fdb'; }
private function getGDAverageWidth(awFileFont $font) { $text = "azertyuiopqsdfghjklmmmmmmmwxcvbbbn,;:!?."; $box = imagettfbbox($font->size, 0, $font->font . '.' . $font->getExtension(), $text); if ($box === FALSE) { awImage::drawError("Class FileFontDriver: Unable to get font average width."); } list(, , $x2, $y2, , , $x1, $y1) = $box; return abs($x2 - $x1) / strlen($text); }
function awTTFFont($name, $size) { parent::awFileFont($name, $size); if ($this->getExtension() === NULL) { $this->setExtension('ttf'); } }