Libchart

Simple PHP chart drawing library
  • Introduction
  • Download
  • Sample Code
  • Reference API
  • Links
  • Main Page
  • Classes
  • Directories
  • Class List
  • Class Members

Primitive Class Reference

List of all members.

Public Member Functions

 Primitive ($img)
 line ($x1, $y1, $x2, $y2, $color, $width=1)
 outlinedBox ($x1, $y1, $x2, $y2, $color0, $color1)

Detailed Description

Graphic primitives, extends GD with chart related primitives.

Author:
Jean-Marc Trémeaux (jm.tremeaux at gmail.com)


Member Function Documentation

Primitive::Primitive ( $  img  ) 

Creates a new primitive object

Parameters:
resource GD image resource

Primitive::line ( $  x1,
$  y1,
$  x2,
$  y2,
$  color,
$  width = 1 
)

Draws a straight line.

Parameters:
integer line start (X)
integer line start (Y)
integer line end (X)
integer line end (Y)
Color line color

Primitive::outlinedBox ( $  x1,
$  y1,
$  x2,
$  y2,
$  color0,
$  color1 
)

Draw a filled gray box with thick borders and darker corners.

Parameters:
integer top left coordinate (x)
integer top left coordinate (y)
integer bottom right coordinate (x)
integer bottom right coordinate (y)
Color edge color
Color corner color


The documentation for this class was generated from the following file:
  • Primitive.php

Site last modified August 13th, 2007 by Jean-Marc Trémeaux