Função PHP Imagick getFont()

| | | | | | | | |
Sintaxe:
int Imagick::getFont (void)
Parâmetros:Esta função leva sem parâmetros.Valor de retorno:Esta função retorna uma string contendo o endereço do arquivo de fonte em caso de sucesso. O programa abaixo ilustra a função Imagick::getFont()em PHP: Programa 1:
// Cria um novo objeto imagick$imagick = new Imagick();
// Instale a fonte - certifique-se de que
// arquivo .ttf correspondente está disponível em
// mesma pasta.$imagick -> setFont ( ` Windsong.ttf` );
// Obter a fonte$font = $imagick -> getFont(); echo $font (); ?>
Saída:
/home/username/php/Windsong.ttf
Programa 2:
// Criar um novo objeto imagick $imagick = new Imagick();
// Instale a fonte - certifique-se
// O arquivo .ttf está disponível na
// mesma pasta.$imagick -> setFont ( `FFF_Tusj .ttf` );
// Obter a fonte$font = $imagick -> getFont(); echo $font (); ?>
Saída:
/home/username/php/FFF_Tusj.ttf
Link: https://www.php.net/manual/en/imagick.getfont.php