Php/docs/imagickdraw.settextdecoration

提供:Dev Guides
< Php
移動先:案内検索

ImagickDraw::setTextDecoration

(PECL imagick 2, PECL imagick 3)

ImagickDraw::setTextDecoration装飾を指定する


説明

public ImagickDraw::setTextDecoration ( int $decoration ) : bool

警告 この関数は、 現在のところ詳細な情報はありません。引数のリストのみが 記述されています。


テキストによる注記を行う際に適用する装飾を指定します。


パラメータ

decoration
DECORATION_ 定数。


返り値

値を返しません。


例1 ImagickDraw::setTextDecoration()

<?phpfunction setTextDecoration($strokeColor, $fillColor, $backgroundColor, $textDecoration) {    $draw = new \ImagickDraw();    $draw->setStrokeColor($strokeColor);    $draw->setFillColor($fillColor);    $draw->setStrokeWidth(2);    $draw->setFontSize(72);    $draw->setTextDecoration($textDecoration);    $draw->annotation(50, 75, "Lorem Ipsum!");    $imagick = new \Imagick();    $imagick->newImage(500, 200, $backgroundColor);    $imagick->setImageFormat("png");    $imagick->drawImage($draw);    header("Content-Type: image/png");    echo $imagick->getImageBlob();}?>