PHP
downloads | documentation | faq | getting help | mailing lists | reporting bugs | php.net sites | links | conferences | my php.net

search for in the

imagesx> <imagestring
Last updated: Fri, 16 May 2008

view this page in

imagestringup

(PHP 4, PHP 5)

imagestringup — Dessine une chaîne verticale

Description

bool imagestringup ( resource $image , int $font , int $x , int $y , string $string , int $color )

Dessine une chaîne sur une ligne verticale dans l'image image aux coordonnées spécifiées.

Liste de paramètres

image

Une ressource d'image, retourné par une des fonctions de création d'images, comme imagecreatetruecolor().

font

Peut être 1, 2, 3, 4, 5 pour les polices internes d'encodage Latin2 (où les plus grands nombres correspondent aux polices larges) ou n'importe quels identifiants de police de votre choix, enregistrées avec la fonction imageloadfont().

x

X : coordonnée du coin en haut, à gauche

y

Y : coordonnée du coin en haut, à gauche

string

La chaîne de caractères à écrire

color

Un identifiant de couleur créé par la fonction imagecolorallocate()

Valeurs de retour

Cette fonction retourne TRUE en cas de succès, FALSE en cas d'échec.

Voir aussi



add a note add a note User Contributed Notes
imagestringup
13-Dec-2002 05:19
function imagestringdown(&$image, $font, $x, $y, $s, $col)
{
    $width = imagesx($image);
   $height = imagesy($image);
   
    $text_image = imagecreate($width, $height);

   $white = imagecolorallocate ($text_image, 255, 255, 255);
   $black = imagecolorallocate ($text_image, 0, 0, 0); 

    $transparent_colour = $white;
   if ($col == $white)
      $transparent_color = $black;
 
   imagefill($text_image, $width, $height, $transparent_colour);
   imagecolortransparent($text_image, $transparent_colour);
 
   imagestringup($text_image, $font, ($width - $x), ($height - $y), $s, $col);
   imagerotate($text_image, 180.0, $transparent_colour);
 
   imagecopy($image, $text_image, 0, 0, 0, 0, $width, $height);
}

imagesx> <imagestring
Last updated: Fri, 16 May 2008
 
 
show source | credits | stats | sitemap | contact | advertising | mirror sites