lib/ezpdf/classes/class.pdf.php
function shadedRectangle( $x1, $y1, $width, $height, $options )
    {
        $this->numObj++;
        $shadingLabel = $this->o_shading( $this->numObj, 'new', $options );

        $this->saveState();

        $this->objects[$this->currentContents]['c'].="\n".sprintf('%.3F',$x1).' '.sprintf('%.3F',$y1).' '.sprintf('%.3F',$width).' '.sprintf('%.3F',$height).' re';

        $this->objects[$this->currentContents]['c'].="\nW n";

        $this->objects[$this->currentContents]['c'].="\n/".$shadingLabel.' sh';

        $this->restoreState();
    }
function shadedRectangle( $x1, $y1, $width, $height, $options )
    {
        $this->numObj++;
        $shadingLabel = $this->o_shading( $this->numObj, 'new', $options );

        $this->saveState();

        $this->objects[$this->currentContents]['c'].="\n".sprintf('%.3F',$x1).' '.sprintf('%.3F',$y1).' '.sprintf('%.3F',$width).' '.sprintf('%.3F',$height).' re';

        $this->objects[$this->currentContents]['c'].="\nW n";

        $this->objects[$this->currentContents]['c'].="\n/".$shadingLabel.' sh';

        $this->restoreState();
    }
function shadedRectangle ( $ x1 , $ y1 , $ width , $ height , $ options ) { $ this -> numObj ++ ; $ shadingLabel = $ this -> o_shading ( $ this -> numObj , 'new' , $ options ) ; $ this -> saveState ( ) ; $ this -> objects [ $ this -> currentContents ] [ 'c' ] .= "\n" . sprintf ( '%.3F' , $ x1 ) . ' ' . sprintf ( '%.3F' , $ y1 ) . ' ' . sprintf ( '%.3F' , $ width ) . ' ' . sprintf ( '%.3F' , $ height ) . ' re' ; $ this -> objects [ $ this -> currentContents ] [ 'c' ] .= "\nW n" ; $ this -> objects [ $ this -> currentContents ] [ 'c' ] .= "\n/" . $ shadingLabel . ' sh' ; $ this -> restoreState ( ) ; }
Create shaded rectangle area

\param x1
\param x2
\param width
\param height
\param options
array ( 'orientation' => <vertical|horizontal ( optianal )>,
'color0' => <CMYK color array>,
'color1' => <CMYK color array> )
Create shaded rectangle area