Class Image_Graph_Fill_Common

Description

Base class for a fill-element (e.g. a "solid" fill or a "gradient" fill)

This class provides a basic implementation that is used and extended in all derived fill-elements. Fill-elements can be used at various places in Image_Graph. E.g. you can use it for filling a data-element (Image_Graph_Data_Common and derived classes) or a grid-element (Image_Graph_Grid).

Located in /Graph/Fill/Common.php (line 58)


	
			
Direct descendents
Class Description
 class Image_Graph_Fill_Solid Solid fill-element
 class Image_Graph_Fill_Gradient Gradient fill-element
Method Summary
 Image_Graph_Fill_Common Image_Graph_Fill_Common ([array $attributes = array()])
 void drawGDBox (resource &$img, array $pos)
 void drawGDPolygon (resource &$img, array $pos)
 void setColor (mixed $color)
Methods
Constructor Image_Graph_Fill_Common (line 82)

Constructor

  • access: public
Image_Graph_Fill_Common Image_Graph_Fill_Common ([array $attributes = array()])
  • array $attributes: attributes like color
drawGDBox (line 114)

Draws fill element, shape: box

  • access: public
void drawGDBox (resource &$img, array $pos)
  • resource &$img: image-resource to draw to
  • array $pos: of array of int absolute position for upper left and lower right edge

Redefined in descendants as:
drawGDPolygon (line 126)

Draws fill element, shape: polygon

  • access: public
void drawGDPolygon (resource &$img, array $pos)
  • resource &$img: image-resource to draw to
  • array $pos: of array of int absolute positions of polygon-coordinates

Redefined in descendants as:
setColor (line 102)

Set color

Please note that derived classes which might need more than one color (e.g. for a gradient fill) might overwrite this function and demand that $color is not one color but an array of colors.

void setColor (mixed $color)
  • mixed $color: any color representation supported by Image_Graph_Color::color2RGB()

Redefined in descendants as:

Documentation generated on Sat, 21 Feb 2004 23:28:01 +0100 by phpDocumentor 1.3.0RC2