From 866658cded5b92ddb2681dead1ebaf111d712fcc Mon Sep 17 00:00:00 2001 From: cassiopc Date: Mon, 6 Aug 2012 11:09:10 +0200 Subject: init --- boca-1.5.0/src/libchart/classes/Primitive.php | 59 +++++++++++++++++++++++++++ 1 file changed, 59 insertions(+) create mode 100644 boca-1.5.0/src/libchart/classes/Primitive.php (limited to 'boca-1.5.0/src/libchart/classes/Primitive.php') diff --git a/boca-1.5.0/src/libchart/classes/Primitive.php b/boca-1.5.0/src/libchart/classes/Primitive.php new file mode 100644 index 0000000..9e5a896 --- /dev/null +++ b/boca-1.5.0/src/libchart/classes/Primitive.php @@ -0,0 +1,59 @@ +img = $img; + } + + /** + * Draws a straight line + * + * @access public + * @param integer line start (X) + * @param integer line start (Y) + * @param integer line end (X) + * @param integer line end (Y) + * @param Color line color + */ + + function line($x1, $y1, $x2, $y2, $color, $width = 1) + { + imagefilledpolygon($this->img, array($x1, $y1 - $width / 2, $x1, $y1 + $width / 2, $x2, $y2 + $width / 2, $x2, $y2 - $width / 2), 4, $color->getColor($this->img)); +// imageline($this->img, $x1, $y1, $x2, $y2, $color->getColor($this->img)); + } + } +?> -- cgit v1.2.3