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

search for in the

SWFShape->setRightFill> <SWFShape->setLeftFill
Last updated: Fri, 20 May 2011

view this page in

SWFShape->setLine

(PHP 4 >= 4.0.5)

SWFShape->setLineEstablece el estilo de línea de la forma

Descripción

void SWFShape::setLine ( SWFShape $shape )
void setLine ( int $width , int $red , int $green , int $blue [, int $a ] )
Warning

Esta función ha sido declarada EXPERIMENTAL. Su comportamiento, su nombre y la documentación que le acompaña puede cambiar sin previo aviso en futuras versiones de PHP. Use esta función bajo su propio riesgo.

swfshape->setline() establece el estilo de línea de la forma. width es el ancho de línea. Si width es 0, es estilo de línea se elimina (entonces se ignoran todos los demás argumentos). Si width > 0, el color de la línea se establece a red, green, blue. El último parámetro, a, es opcional.

De deben declarar todos los estilos de línea antes de usarlos (véase el ejemplo).

Valores devueltos

No devuelve ningún valor.

Ejemplos

Este sencillo ejemplo dibujará un gran "!#%*@" en divertidos colores y estilo elegante.

Example #1 Ejemplo de swfshape->setline()

<?php
$s 
= new SWFShape();
$f1 $s->addFill(0xff00);
$f2 $s->addFill(0xff0x7f0);
$f3 $s->addFill(0xff0xff0);
$f4 $s->addFill(00xff0);
$f5 $s->addFill(000xff);

// error: se deben declarar todos los estilo de línea antes de usarlos
$s->setLine(400x7f00);
$s->setLine(400x7f0x3f0);
$s->setLine(400x7f0x7f0);
$s->setLine(4000x7f0);
$s->setLine(40000x7f);

$f = new SWFFont('Techno.fdb');

$s->setRightFill($f1);
$s->setLine(400x7f00);
$s->drawGlyph($f'!');
$s->movePen($f->getWidth('!'), 0);

$s->setRightFill($f2);
$s->setLine(400x7f0x3f0);
$s->drawGlyph($f'#');
$s->movePen($f->getWidth('#'), 0);

$s->setRightFill($f3);
$s->setLine(400x7f0x7f0);
$s->drawGlyph($f'%');
$s->movePen($f->getWidth('%'), 0);

$s->setRightFill($f4);
$s->setLine(4000x7f0);
$s->drawGlyph($f'*');
$s->movePen($f->getWidth('*'), 0);

$s->setRightFill($f5);
$s->setLine(40000x7f);
$s->drawGlyph($f'@');

$m = new SWFMovie();
$m->setDimension(3000,2000);
$m->setRate(12.0);
$i $m->add($s);
$i->moveTo(1500-$f->getWidth("!#%*@")/21000+$f->getAscent()/2);

header('Content-type: application/x-shockwave-flash');
$m->output();
?>

Valores devueltos

No devuelve ningún valor.



add a note add a note User Contributed Notes SWFShape->setLine
There are no user contributed notes for this page.

 
show source | credits | stats | sitemap | contact | advertising | mirror sites