summaryrefslogtreecommitdiffstats
path: root/notFinishedCode/pChart2.1.2/examples
diff options
context:
space:
mode:
Diffstat (limited to 'notFinishedCode/pChart2.1.2/examples')
-rw-r--r--notFinishedCode/pChart2.1.2/examples/BTSCont.pngbin0 -> 3173 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/buildAll.cmd52
-rw-r--r--notFinishedCode/pChart2.1.2/examples/delayedLoader/delayedLoading.js228
-rw-r--r--notFinishedCode/pChart2.1.2/examples/delayedLoader/draw.php34
-rw-r--r--notFinishedCode/pChart2.1.2/examples/delayedLoader/index.php91
-rw-r--r--notFinishedCode/pChart2.1.2/examples/delayedLoader/wait.gifbin0 -> 2545 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.Combo.php65
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.Mixed.classes.php87
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.addRandomValues.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.barcode.php77
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.barcode128.php48
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.barcode39.php48
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.basic.php32
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.cache.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.draw2DPie.labels.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.draw2DPie.php68
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.draw2DRing.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.draw2DRingValues.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.draw3DPie.labels.php53
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.draw3DPie.php73
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.draw3DPie.transparent.php40
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.draw3DRing.php55
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.draw3DRingValues.php55
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawAnscombeQuartet.php106
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawAntialiasPixel.php35
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.php66
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.simple.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.threshold.php60
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawArrow.php40
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawArrowLabel.php48
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBarChart.borders.php52
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBarChart.can.php41
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBarChart.floating.php45
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBarChart.palette.php49
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBarChart.php65
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBarChart.poll.php42
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBarChart.shaded.php40
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBarChart.simple.php50
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBarChart.spacing.php52
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBarChart.vertical.php40
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBestfit.php55
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBezier.php40
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBubbleChart.php79
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawBubbleChart.simple.php58
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawCircle.php54
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawContour.php61
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawDerivative.php61
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawDerivative.simple.php47
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawFilledCircle.php54
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawFilledRectangle.php57
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawFilledSplineChart.php74
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawFilledSplineChart.threshold.php76
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawFilledStepChart.php65
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawFromGIF.php47
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawFromJPG.php47
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawFromPNG.php47
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawGeometricMean.php59
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawGradientArea.php53
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawHarmonicMean.php59
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawIndicator.php66
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawLabel.barchart.php71
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawLabel.bubble.php87
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawLabel.caption.php67
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawLabel.php70
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawLabel.scatter.php87
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawLabel.vertical.php51
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawLegend.php76
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawLine.php42
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawLineChart.php66
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawLineChart.simple.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawMedian.php55
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawPieLegend.php67
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.icon.php69
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.php64
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.simple.php52
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawPolygon.php55
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawProgress.php65
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawRectangle.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawRoundedFilledRectangle.php62
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawRoundedRectangle.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScale.color.php69
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScale.dates.php55
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScale.floating.php52
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScale.manual.php54
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScale.multiple.php63
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScale.php53
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScale.reverse.php48
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScatter.shape.php69
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScatter.simple.php67
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScatterBestFit.php81
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScatterLineChart.php80
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScatterLineChart.trigo.php75
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScatterPlotChart.php80
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScatterScale.manual.php61
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScatterScale.php62
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawScatterSplineChart.php81
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawSimple.php42
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawSpline.php42
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawSplineChart.php66
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawSplineChart.simple.php59
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStackedAreaChart.normalized.php43
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStackedAreaChart.php63
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.border.php39
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.can.php42
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.php65
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.rounded.php53
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.shaded.php42
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStandardDeviation.php79
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStepChart.php65
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStepChart.simple.php44
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStockChart.median.php50
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStockChart.php65
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawStockChart.simple.php49
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawSurface.palette.php63
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawSurface.php57
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawSurface.simple.php58
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawText.php55
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawThreshold.labels.php53
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawThreshold.php69
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawThresholdArea.php58
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawZoneChart.php61
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.drawingObjects.php50
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.normalize.php42
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.pData.php46
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.polar.php65
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.polar.values.php51
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.radar.labels.php50
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.radar.php67
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.radar.values.php50
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.setFontProperties.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.setShadow.php44
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.singlebarcode128.php30
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.singlebarcode39.php30
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.split.php62
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.spring.complex.php66
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.spring.labels.php67
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.spring.php65
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.spring.relations.php70
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.text.alignment.php67
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.transparent.background.php36
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.writeBounds.php67
-rw-r--r--notFinishedCode/pChart2.1.2/examples/example.writeBounds.php.backup46
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/imagemap.js256
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/index.php209
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/2DPie.php58
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/2DRing.php58
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/3DPie.php55
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/3DRing.php55
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/BarChart.php67
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/BubbleChart.php76
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/LineChart.php74
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/PlotChart.php69
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/PolarChart.php56
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/RadarChart.php57
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterLineChart.php89
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterPlotChart.php89
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterSplineChart.php90
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/Shapes.php91
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/SplineChart.php74
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StackedBarChart.php67
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StepChart.php71
-rw-r--r--notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StockChart.php59
-rw-r--r--notFinishedCode/pChart2.1.2/examples/index.php360
-rw-r--r--notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK.pngbin0 -> 5045 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK1.pngbin0 -> 4891 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK.pngbin0 -> 5047 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK1.pngbin0 -> 4975 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/accept.pngbin0 -> 781 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/application_view_list.pngbin0 -> 473 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/application_view_tile.pngbin0 -> 465 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/blocnote.pngbin0 -> 21012 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/chart_bar.pngbin0 -> 541 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/chart_line.pngbin0 -> 526 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/computer.gifbin0 -> 5172 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-blank.pngbin0 -> 156 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-last.pngbin0 -> 183 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-noleaf.pngbin0 -> 174 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/dash-explorer.pngbin0 -> 185 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/dash.pngbin0 -> 294 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/dataset.txt25
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/folder.pngbin0 -> 537 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/hologram.pngbin0 -> 25951 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/landscape1.jpgbin0 -> 8204 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/landscape2.jpgbin0 -> 9199 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/palette.txt6
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/serie1.pngbin0 -> 741 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/serie2.pngbin0 -> 753 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/resources/wait.gifbin0 -> 2545 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/accept.pngbin0 -> 781 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/application_form.pngbin0 -> 467 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/background.console.pngbin0 -> 183 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar.pngbin0 -> 541 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar_edit.pngbin0 -> 754 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_curve.pngbin0 -> 710 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_line.pngbin0 -> 526 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/cog.pngbin0 -> 512 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/color_swatch.pngbin0 -> 209 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/comment.pngbin0 -> 413 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/database_table.pngbin0 -> 726 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/layout_edit.pngbin0 -> 716 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/page_edit.pngbin0 -> 807 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/paintcan.pngbin0 -> 707 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/shape_flip_vertical.pngbin0 -> 418 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/tab.pngbin0 -> 323 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/vector.pngbin0 -> 481 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wait.gifbin0 -> 2545 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wand.pngbin0 -> 570 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wrench.pngbin0 -> 610 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/arrow.gifbin0 -> 66 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/constants.txt61
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/cross.gifbin0 -> 83 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/functions.js656
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/hs.pngbin0 -> 2684 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/hv.pngbin0 -> 2865 bytes
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/jscolor.js841
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/includes/rounded_corners_lite.inc.js285
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/index.php707
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/script/render.php891
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/script/session.php24
-rw-r--r--notFinishedCode/pChart2.1.2/examples/sandbox/style.css89
-rw-r--r--notFinishedCode/pChart2.1.2/examples/server.pngbin0 -> 13589 bytes
-rwxr-xr-xnotFinishedCode/pChart2.1.2/examples/telephone.pngbin0 -> 6666 bytes
222 files changed, 13930 insertions, 0 deletions
diff --git a/notFinishedCode/pChart2.1.2/examples/BTSCont.png b/notFinishedCode/pChart2.1.2/examples/BTSCont.png
new file mode 100644
index 0000000..ef91ea6
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/BTSCont.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/buildAll.cmd b/notFinishedCode/pChart2.1.2/examples/buildAll.cmd
new file mode 100644
index 0000000..8518c72
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/buildAll.cmd
@@ -0,0 +1,52 @@
+ECHO OFF
+setlocal ENABLEDELAYEDEXPANSION
+
+CLS
+ECHO.
+ECHO ÉÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍ»
+ECHO º º
+ECHO º Processing all examples (this may takes 1-2 minutes) º
+ECHO º º
+ECHO ÈÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍÍͼ
+ECHO.
+
+php -v 1>NUL 2>NUL
+IF %ERRORLEVEL% == 0 GOTO getVersion
+GOTO noPHP
+
+:getVersion
+FOR /F "tokens=1,2 delims= " %%G IN ('php -v') DO (
+ IF %%G==PHP SET PHPVersion=%%H
+ )
+
+:render
+ECHO The PHP binaries (%PHPVersion%) have been located in your system PATH
+ECHO.
+ECHO Processing examples : >resources\errors.log
+
+REM SET /P Var=" Progress : "<NUL
+
+FOR %%f IN (*.*) DO (
+ set t=%%f
+ if !t:~-3! == php (
+ SET /P Var=þ<NUL
+ ECHO %%f >>resources\errors.log
+ php -q "%~dp0%%f" 1>NUL 2>>resources\errors.log
+ )
+)
+
+ECHO.
+ECHO.
+ECHO All the example have been rendered in the following folder :
+ECHO.
+ECHO %~dp0pictures\
+GOTO end
+
+:noPHP
+
+ECHO The PHP binaries can't be found. We strongly advise you to put it in
+ECHO the system path variable.
+ECHO.
+ECHO Examples rendering has been aborded.
+:end
+PAUSE >NUL \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/delayedLoader/delayedLoading.js b/notFinishedCode/pChart2.1.2/examples/delayedLoader/delayedLoading.js
new file mode 100644
index 0000000..b76bbe3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/delayedLoader/delayedLoading.js
@@ -0,0 +1,228 @@
+ /*
+ delayedLoader - JS to delay out of sight pictures rendering
+
+ Version : 2.0.2
+ Made by : Jean-Damien POGOLOTTI
+ Last Update : 10/12/10
+
+ This file can be distributed under the license you can find at :
+
+ http://www.pchart.net/license
+
+ You can find the whole class documentation on the pChart web site.
+ */
+
+ var PictureCache = new Array();
+ var PictureCount = 0;
+ var WaitPicture = "wait.gif";
+ var DivClassName = "pChart";
+ var DefaultWidth = 70;
+ var DefaultHeight = 230;
+ var DefaultAlt = "pChart rendered picture";
+
+
+ /* Do the DOM document processing */
+ function loaderInit()
+ {
+ WindowSize = getWindowSize();
+ WindowHeight = WindowSize[1];
+ Offset = getScrollXY();
+ HeightOffset = Offset[1];
+
+ /* Enumerate the tags */
+ Links = document.getElementsByTagName("a");
+ for (i = 0; i < Links.length; i++)
+ {
+ className = Links[i].className;
+
+ if ( className == DivClassName )
+ {
+ ObjectWidth = Links[i].getAttribute("data-pchart-width");
+ ObjectHeight = Links[i].getAttribute("data-pchart-height");
+ ObjectID = Links[i].id;
+ ObjectTop = Links[i].offsetTop;
+ ObjectURL = Links[i].href;
+ ObjectAlt = Links[i].getAttribute("data-pchart-alt");
+
+ if ( ObjectWidth == null ) { ObjectWidth = DefaultWidth; }
+ if ( ObjectHeight == null ) { ObjectHeight = DefaultHeight; }
+ if ( ObjectAlt == null ) { ObjectAlt = DefaultAlt; }
+
+ if (ObjectID == "") { ObjectID = "pChart-"+i; Links[i].id = ObjectID; }
+
+ PictureCache[PictureCount] = new Array();
+ PictureCache[PictureCount][0] = ObjectID;
+ PictureCache[PictureCount][1] = ObjectTop;
+ PictureCache[PictureCount][2] = ObjectURL;
+ PictureCache[PictureCount][3] = ObjectAlt;
+ PictureCache[PictureCount][4] = ObjectWidth;
+ PictureCache[PictureCount][5] = ObjectHeight;
+
+ PictureCount++;
+ }
+ }
+
+ /* Replace the <A> tags by <DIV> ones and attach the loader */
+ for(i=0;i<PictureCount;i++)
+ {
+ ATag = document.getElementById(PictureCache[i][0]);
+ DivTag = document.createElement("div");
+ DivID = "pChart-Div"+i; PictureCache[i][0] = DivID;
+
+ DivTag.setAttribute("id", DivID);
+ DivTag.style.width = PictureCache[i][4];
+ DivTag.style.height = PictureCache[i][5];
+ DivTag.style.backgroundColor = "#E0E0E0";
+
+ DivTag2 = ATag.parentNode.replaceChild(DivTag, ATag);
+
+ DivTop = DivTag.offsetTop;
+ PictureCache[i][1] = DivTop;
+
+ changeOpac(50, i);
+ changeContent("<img src='"+WaitPicture+"' width=24 height=24 alt=''/>",i);
+
+ if ( HeightOffset + WindowHeight > PictureCache[i][1] ) { triggerVisible(i); }
+ }
+ }
+
+ /* Replace the contents of the delayed loading DIV */
+ function changeContent(html, id)
+ { DivID = PictureCache[id][0]; document.getElementById(DivID).innerHTML = html; }
+
+ /* Trigger the picture rendering when the pChart DIV became visible */
+ function triggerVisible(PictureID)
+ {
+ if ( !PictureCache[PictureID][6] == true )
+ {
+ PictureCache[PictureID][6] = true;
+ ajaxRender(PictureCache[PictureID][2],PictureID);
+ }
+ }
+
+ /* Catch the navigator window scrolling event */
+ function scrollEvent()
+ {
+ WindowSize = getWindowSize();
+ WindowHeight = WindowSize[1];
+ Offset = getScrollXY();
+ HeightOffset = Offset[1];
+
+ for(i=0;i<=PictureCount-1;i++) { if ( HeightOffset + WindowHeight > PictureCache[i][1] ) { triggerVisible(i); } }
+ }
+
+ /* Cross browser X/Y window offset gatherer */
+ function getScrollXY()
+ {
+ var scrOfX = 0, scrOfY = 0;
+
+ if( typeof( window.pageYOffset ) == 'number' )
+ { scrOfY = window.pageYOffset; scrOfX = window.pageXOffset; }
+ else if( document.body && ( document.body.scrollLeft || document.body.scrollTop ) )
+ { scrOfY = document.body.scrollTop; scrOfX = document.body.scrollLeft; }
+ else if( document.documentElement && ( document.documentElement.scrollLeft || document.documentElement.scrollTop ) )
+ { scrOfY = document.documentElement.scrollTop; scrOfX = document.documentElement.scrollLeft; }
+
+ return [ scrOfX, scrOfY ];
+ }
+
+ /* Cross browser X/Y window size gatherer */
+ function getWindowSize()
+ {
+ var myWidth = 0, myHeight = 0;
+
+ if( typeof( window.innerWidth ) == 'number' )
+ { myWidth = window.innerWidth; myHeight = window.innerHeight; }
+ else if( document.documentElement && ( document.documentElement.clientWidth || document.documentElement.clientHeight ) )
+ { myWidth = document.documentElement.clientWidth; myHeight = document.documentElement.clientHeight; }
+ else if( document.body && ( document.body.clientWidth || document.body.clientHeight ) )
+ { myWidth = document.body.clientWidth; myHeight = document.body.clientHeight; }
+
+ return [ myWidth, myHeight ];
+ }
+
+ /* Cross browser alpha transparency changer */
+ function changeOpac(opacity, id)
+ {
+ DivID = PictureCache[id][0];
+
+ var object = document.getElementById(DivID).style;
+ object.opacity = (opacity / 100);
+ object.MozOpacity = (opacity / 100);
+ object.KhtmlOpacity = (opacity / 100);
+ object.filter = "alpha(opacity=" + opacity + ")";
+ }
+
+ /* Shade in-out function */
+ function opacity(id, opacStart, opacEnd, millisec)
+ {
+ var speed = Math.round(millisec / 100);
+ var timer = 0;
+
+ if(opacStart > opacEnd)
+ {
+ for(i = opacStart; i >= opacEnd; i--)
+ {
+ setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed));
+ timer++;
+ }
+ }
+ else if(opacStart < opacEnd)
+ {
+ for(i = opacStart; i <= opacEnd; i++)
+ {
+ setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed));
+ timer++;
+ }
+ }
+ }
+
+ /* Start the loader */
+ function StartFade(PictureID)
+ {
+ Loader = new Image();
+ URL = PictureCache[PictureID][2];
+ Loader.src = URL;
+ setTimeout("CheckLoadingStatus("+PictureID+")", 200);
+ }
+
+ /* check the picture loading status */
+ function CheckLoadingStatus(PictureID)
+ {
+ DivID = PictureCache[PictureID][0];
+ URL = PictureCache[PictureID][2];
+ Alt = PictureCache[PictureID][3];
+
+ if ( Loader.complete == true )
+ {
+ changeOpac(0, PictureID);
+ HTMLResult = "<center><img src='" + URL + "' alt='"+Alt+"'/></center>";
+ document.getElementById(DivID).innerHTML = HTMLResult;
+
+ opacity(PictureID,0,100,100);
+ }
+ else
+ setTimeout("CheckLoadingStatus("+PictureID+")", 200);
+ }
+
+ /* Compute the pChart picture in background */
+ function ajaxRender(URL,PictureID)
+ {
+ var xmlhttp=false;
+ /*@cc_on @*/
+ /*@if (@_jscript_version >= 5)
+ try { xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { xmlhttp = false; } }
+ @end @*/
+
+ if (!xmlhttp && typeof XMLHttpRequest!='undefined')
+ { try { xmlhttp = new XMLHttpRequest(); } catch (e) { xmlhttp=false; } }
+
+ if (!xmlhttp && window.createRequest)
+ { try { xmlhttp = window.createRequest(); } catch (e) { xmlhttp=false; } }
+
+ xmlhttp.open("GET", URL,true);
+
+ xmlhttp.onreadystatechange=function()
+ { if (xmlhttp.readyState==4) { StartFade(PictureID); } }
+ xmlhttp.send(null)
+ }
diff --git a/notFinishedCode/pChart2.1.2/examples/delayedLoader/draw.php b/notFinishedCode/pChart2.1.2/examples/delayedLoader/draw.php
new file mode 100644
index 0000000..c5b3c2f
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/delayedLoader/draw.php
@@ -0,0 +1,34 @@
+<?php
+ if ( !isset($_GET["Seed"]) )
+ { $Seed = "Unknown"; }
+ else
+ { $Seed = $_GET["Seed"]; }
+
+ /* pChart library inclusions */
+ include("../../class/pDraw.class.php");
+ include("../../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>220,"StartG"=>220,"StartB"=>220,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>220,"StartG"=>220,"StartB"=>220,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>50));
+ $RectangleSettings = array("R"=>180,"G"=>180,"B"=>180,"Alpha"=>100);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>150,"G"=>150,"B"=>150));
+
+ /* Write the title */
+ $myPicture->setFontProperties(array("FontName"=>"../../fonts/advent_light.ttf","FontSize"=>40));
+ $myPicture->drawText(130,130,"Delayed loading script",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the seed # */
+ $myPicture->setFontProperties(array("FontName"=>"../../fonts/advent_light.ttf","FontSize"=>10));
+ $myPicture->drawText(130,140,"Seed # : ".$Seed,array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Draw a bezier curve */
+ $BezierSettings = array("R"=>255,"G"=>255,"B"=>255,"Ticks"=>4,"DrawArrow"=>TRUE,"ArrowTwoHeads"=>TRUE);
+ $myPicture->drawBezier(360,170,670,120,430,100,560,190,$BezierSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("draw.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/delayedLoader/index.php b/notFinishedCode/pChart2.1.2/examples/delayedLoader/index.php
new file mode 100644
index 0000000..10e3db0
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/delayedLoader/index.php
@@ -0,0 +1,91 @@
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <script src='delayedLoading.js' type="text/javascript"></script>
+ <title>pChart 2.x - Delayed loading</title>
+ <meta http-equiv='Content-Type' content='text/html; charset=utf-8'/>
+ <style>
+ html { height: 100%; }
+ body { background-color: #F0F0F0; font-family: tahoma; font-size: 14px; height: 100%;}
+ td { font-family: tahoma; font-size: 11px; }
+ div.txt { font-family: tahoma; font-size: 11px; width: 660px; padding: 15px; }
+ a.smallLink:link { text-decoration: none; color: #6A6A6A; }
+ a.smallLink:visited { text-decoration: none; color: #6A6A6A; }
+ a.smallLink:hover { text-decoration: underline; color: #6A6A6A; }
+ a.pChart { text-decoration: none; color: #6A6A6A; }
+ </style>
+</head>
+<body onscroll="scrollEvent();" onload="loaderInit();">
+
+ <table style='border: 2px solid #FFFFFF;'><tr><td>
+ <div style='font-size: 11px; padding: 2px; color: #FFFFFF; background-color: #666666; border-bottom: 3px solid #484848;'>&nbsp;Navigation</div>
+ <table style='padding: 1px; background-color: #E0E0E0; border: 1px solid #D0D0D0; border-top: 1px solid #FFFFFF;'><tr>
+ <td width=16><img src='../resources/application_view_tile.png' width=16 height=16 alt=''/></td>
+ <td width=95>&nbsp;<a class=smallLink href='../'>Examples</a></td>
+ <td width=16><img src='../resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td width=95>&nbsp;<a class=smallLink href='../sandbox/'>Sandbox</a></td>
+ <td width=16><img src='../resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td width=95>&nbsp;<b>Delayed loader</b></td>
+ <td width=16><img src='../resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td width=100>&nbsp;<a class=smallLink href='../imageMap/'>Image Map</a></td>
+ </tr></table>
+ </td></tr></table>
+
+ <br/>
+
+ <div class=txt>
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna
+ aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
+ Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
+ occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
+ </div>
+ <a class='pChart' href='draw.php?Seed=1' data-pchart-alt='Picture1' data-pchart-width='700' data-pchart-height='230'>Picture 1</a>
+ <div class=txt>
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna
+ aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
+ Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
+ occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
+ </div>
+ <a class='pChart' href='draw.php?Seed=2' data-pchart-alt='Picture2'>Picture 2</a>
+ <div class=txt>
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna
+ aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
+ Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
+ occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
+ </div>
+ <a class='pChart' href='draw.php?Seed=3' data-pchart-alt='Picture3'>Picture 3</a>
+ <div class=txt>
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna
+ aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
+ Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
+ occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
+ </div>
+ <a class='pChart' href='draw.php?Seed=4' data-pchart-alt='Picture4'>Picture 4</a>
+ <div class=txt>
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna
+ aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
+ Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
+ occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
+ </div>
+ <a class='pChart' href='draw.php?Seed=5' data-pchart-alt='Picture5'>Picture 5</a>
+ <div class=txt>
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna
+ aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
+ Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
+ occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
+ </div>
+ <a class='pChart' href='draw.php?Seed=6' data-pchart-alt='Picture6'>Picture 6</a>
+ <div class=txt>
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna
+ aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
+ Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
+ occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
+ </div>
+ <a class='pChart' href='draw.php?Seed=7' data-pchart-alt='Picture7'>Picture 7</a>
+ <div class=txt>
+ Lorem ipsum dolor sit amet, consectetur adipisicing elit, sed do eiusmod tempor incididunt ut labore et dolore magna
+ aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.
+ Duis aute irure dolor in reprehenderit in voluptate velit esse cillum dolore eu fugiat nulla pariatur. Excepteur sint
+ occaecat cupidatat non proident, sunt in culpa qui officia deserunt mollit anim id est laborum.
+ </div>
+</body>
+</html> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/delayedLoader/wait.gif b/notFinishedCode/pChart2.1.2/examples/delayedLoader/wait.gif
new file mode 100644
index 0000000..1c72ebb
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/delayedLoader/wait.gif
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/example.Combo.php b/notFinishedCode/pChart2.1.2/examples/example.Combo.php
new file mode 100644
index 0000000..c1175d8
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.Combo.php
@@ -0,0 +1,65 @@
+<?php
+ /* CAT:Combo */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pData object with some random values*/
+ $MyData = new pData();
+ $MyData->addPoints(array(30,24,32),"This year");
+ $MyData->addPoints(array(28,20,27),"Last year");
+ $MyData->addPoints(array("Year","Month","Day"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Create a solid background */
+ $Settings = array("R"=>179, "G"=>217, "B"=>91, "Dash"=>1, "DashR"=>199, "DashG"=>237, "DashB"=>111);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Do a gradient overlay */
+ $Settings = array("StartR"=>194, "StartG"=>231, "StartB"=>44, "EndR"=>43, "EndG"=>107, "EndB"=>58, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"Chart title",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Draw the scale */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->setGraphArea(50,60,670,190);
+ $myPicture->drawFilledRectangle(50,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("CycleBackground"=>TRUE));
+
+ /* Graph title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawText(50,52,"Chart subtitle",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMLEFT));
+
+ /* Draw the bar chart chart */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $MyData->setSerieDrawable("Last year",FALSE);
+ $myPicture->drawBarChart();
+
+ /* Draw the line and plot chart */
+ $MyData->setSerieDrawable("Last year",TRUE);
+ $MyData->setSerieDrawable("This year",FALSE);
+ $myPicture->drawSplineChart();
+ $myPicture->drawPlotChart();
+
+ /* Make sure all series are drawable before writing the scale */
+ $MyData->drawAll();
+
+ /* Write the legend */
+ $myPicture->drawLegend(580,35,array("Style"=>LEGEND_ROUND,"Alpha"=>20,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.combo.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.Mixed.classes.php b/notFinishedCode/pChart2.1.2/examples/example.Mixed.classes.php
new file mode 100644
index 0000000..06c708e
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.Mixed.classes.php
@@ -0,0 +1,87 @@
+<?php
+ /* CAT:Combo */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pIndicator.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ for($i=0;$i<=80;$i++) { $MyData->addPoints(($i/10)*($i/10),"Statistical probability"); }
+ $MyData->setAxisName(0,"Probability");
+ $MyData->setAxisUnit(0,"%");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,350,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,350,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,220,DIRECTION_VERTICAL,$Settings);
+ $Settings = array("StartR"=>1, "StartG"=>138, "StartB"=>68, "EndR"=>219, "EndG"=>231, "EndB"=>239, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,222,700,350,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,349,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"LabelSkip"=>4,"GridR"=>220,"GridG"=>220,"GridB"=>220,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw the line of best fit */
+ $myPicture->drawBestFit(array("Ticks"=>4,"Alpha"=>50,"R"=>0,"G"=>0,"B"=>0));
+
+ /* Draw the line chart */
+ $myPicture->drawLineChart();
+
+ /* Draw the series derivative graph */
+ $myPicture->drawDerivative(array("ShadedSlopeBox"=>TRUE,"CaptionLine"=>TRUE));
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(570,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Set the default font & shadow settings */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Probability of heart disease",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE,"R"=>255,"G"=>255,"B"=>255));
+
+ /* Write a label over the chart */
+ $LabelSettings = array("DrawVerticalLine"=>TRUE,"TitleMode"=>LABEL_TITLE_BACKGROUND,"TitleR"=>255,"TitleG"=>255,"TitleB"=>255);
+ $myPicture->writeLabel("Statistical probability",35,$LabelSettings);
+
+ /* Create the pIndicator object */
+ $Indicator = new pIndicator($myPicture);
+
+ /* Define the indicator sections */
+ $IndicatorSections = "";
+ $IndicatorSections[] = array("Start"=>0,"End"=>29,"Caption"=>"Low","R"=>0,"G"=>142,"B"=>176);
+ $IndicatorSections[] = array("Start"=>30,"End"=>49,"Caption"=>"Moderate","R"=>108,"G"=>157,"B"=>49);
+ $IndicatorSections[] = array("Start"=>50,"End"=>80,"Caption"=>"High","R"=>226,"G"=>74,"B"=>14);
+
+ /* Draw the 2nd indicator */
+ $IndicatorSettings = array("Values"=>35,"Unit"=>"%","CaptionPosition"=>INDICATOR_CAPTION_BOTTOM,"CaptionR"=>0,"CaptionG"=>0,"CaptionB"=>0,"DrawLeftHead"=>FALSE,"ValueDisplay"=>INDICATOR_VALUE_LABEL,"ValueFontName"=>"../fonts/Forgotte.ttf","ValueFontSize"=>15,"IndicatorSections"=>$IndicatorSections);
+ $Indicator->draw(60,275,580,30,$IndicatorSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.mixed.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.addRandomValues.php b/notFinishedCode/pChart2.1.2/examples/example.addRandomValues.php
new file mode 100644
index 0000000..5ada884
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.addRandomValues.php
@@ -0,0 +1,56 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pData object with some random values*/
+ $MyData = new pData();
+ $MyData->addRandomValues("Probe 1",array("Values"=>30,"Min"=>0,"Max"=>4));
+ $MyData->addRandomValues("Probe 2",array("Values"=>30,"Min"=>6,"Max"=>10));
+ $MyData->addRandomValues("Probe 3",array("Values"=>30,"Min"=>12,"Max"=>16));
+ $MyData->addRandomValues("Probe 4",array("Values"=>30,"Min"=>18,"Max"=>22));
+ $MyData->setAxisName(0,"Probes");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Create a solid background */
+ $Settings = array("R"=>179, "G"=>217, "B"=>91, "Dash"=>1, "DashR"=>199, "DashG"=>237, "DashB"=>111);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Do a gradient overlay */
+ $Settings = array("StartR"=>194, "StartG"=>231, "StartB"=>44, "EndR"=>43, "EndG"=>107, "EndB"=>58, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"addRandomValues() :: assess your scales",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Draw the scale */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->setGraphArea(50,60,670,190);
+ $myPicture->drawFilledRectangle(50,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("CycleBackground"=>TRUE,"LabelSkip"=>4,"DrawSubTicks"=>TRUE));
+
+ /* Graph title */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawText(50,52,"Magnetic noise",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMLEFT));
+
+ /* Draw the data series */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawSplineChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the legend */
+ $myPicture->drawLegend(475,50,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.addRandomValues.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.barcode.php b/notFinishedCode/pChart2.1.2/examples/example.barcode.php
new file mode 100644
index 0000000..e4b8d66
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.barcode.php
@@ -0,0 +1,77 @@
+<?php
+ /* CAT:Barcode */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pBarcode39.class.php");
+ include("../class/pBarcode128.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(600,310,NULL,TRUE);
+
+ /* Draw the rounded box */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>30));
+ $Settings = array("R"=>255,"G"=>255,"B"=>255,"BorderR"=>0,"BorderG"=>0,"BorderB"=>0);
+ $myPicture->drawRoundedFilledRectangle(10,10,590,300,10,$Settings);
+
+ /* Draw the cell divisions */
+ $myPicture->setShadow(FALSE);
+ $Settings = array("R"=>0,"G"=>0,"B"=>0);
+ $myPicture->drawLine(10,110,590,110,$Settings);
+ $myPicture->drawLine(200,10,200,110,$Settings);
+ $myPicture->drawLine(400,10,400,110,$Settings);
+ $myPicture->drawLine(10,160,590,160,$Settings);
+ $myPicture->drawLine(220,160,220,200,$Settings);
+ $myPicture->drawLine(320,160,320,200,$Settings);
+ $myPicture->drawLine(10,200,590,200,$Settings);
+ $myPicture->drawLine(400,220,400,300,$Settings);
+
+ /* Write the fields labels */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10));
+ $Settings = array("R"=>0,"G"=>0,"B"=>0,"Align"=>TEXT_ALIGN_TOPLEFT);
+ $myPicture->drawText(20,20,"FROM",$Settings);
+ $myPicture->drawText(210,20,"TO",$Settings);
+ $myPicture->drawText(20,120,"ACCT.\r\nNUMBER",$Settings);
+ $myPicture->drawText(20,166,"QUANTITY",$Settings);
+ $myPicture->drawText(230,166,"SHIPMENT CODE",$Settings);
+ $myPicture->drawText(330,166,"SENDER CODE",$Settings);
+ $myPicture->drawText(410,220,"MFG DATE",$Settings);
+ $myPicture->drawText(410,260,"NET WEIGTH",$Settings);
+
+ /* Filling the fields values */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>16));
+ $myPicture->drawText(70,20,"BEBEER INC\r\n342, MAIN STREET\r\n33000 BORDEAUX\r\nFRANCE",$Settings);
+ $myPicture->drawText(250,20,"MUSTAFA'S BAR\r\n18, CAPITOL STREET\r\n31000 TOULOUSE\r\nFRANCE",$Settings);
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>35));
+ $myPicture->drawText(100,120,"2342355552340",$Settings);
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>20));
+ $Settings = array("R"=>0,"G"=>0,"B"=>0,"Align"=>TEXT_ALIGN_TOPRIGHT);
+ $myPicture->drawText(210,180,"75 CANS",$Settings);
+ $myPicture->drawText(310,180,"TLSE",$Settings);
+ $myPicture->drawText(580,180,"WAREHOUSE#SLOT#B15",$Settings);
+
+ $Settings = array("R"=>0,"G"=>0,"B"=>0,"Align"=>TEXT_ALIGN_TOPLEFT);
+ $myPicture->drawText(410,236,"06/06/2010",$Settings);
+ $myPicture->drawText(410,276,"12.340 Kg",$Settings);
+
+ /* Create the barcode 39 object */
+ $Barcode39 = new pBarcode39("../");
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $Settings = array("ShowLegend"=>TRUE,"Height"=>55,"DrawArea"=>TRUE,"DrawArea"=>FALSE);
+ $Barcode39->draw($myPicture,"12250000234502",30,220,$Settings);
+
+ $Settings = array("ShowLegend"=>TRUE,"Height"=>14,"DrawArea"=>TRUE,"DrawArea"=>FALSE);
+ $Barcode39->draw($myPicture,"75 cans",260,220,$Settings);
+ $Barcode39->draw($myPicture,"06062010",260,260,$Settings);
+
+ /* Create the barcode 128 object */
+ $Barcode128 = new pBarcode128("../");
+ $Settings = array("ShowLegend"=>TRUE,"Height"=>65,"DrawArea"=>TRUE,"DrawArea"=>FALSE);
+ $Barcode128->draw($myPicture,"TLSE",450,25,$Settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.barcode.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.barcode128.php b/notFinishedCode/pChart2.1.2/examples/example.barcode128.php
new file mode 100644
index 0000000..e9629e6
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.barcode128.php
@@ -0,0 +1,48 @@
+<?php
+ /* CAT:Barcode */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pBarcode128.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Draw the border */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"Barcode 128 - Add barcode to your pictures",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Create the barcode 128 object */
+ $Barcode = new pBarcode128("../");
+
+ /* Draw a simple barcode */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $Settings = array("ShowLegend"=>TRUE,"DrawArea"=>TRUE);
+ $Barcode->draw($myPicture,"pChart Rocks!",50,50,$Settings);
+
+ /* Draw a rotated barcode */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>12));
+ $Settings = array("ShowLegend"=>TRUE,"DrawArea"=>TRUE,"Angle"=>90);
+ $Barcode->draw($myPicture,"Turn me on",650,50,$Settings);
+
+ /* Draw a rotated barcode */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>12));
+ $Settings = array("R"=>255,"G"=>255,"B"=>255,"AreaR"=>150,"AreaG"=>30,"AreaB"=>27,"ShowLegend"=>TRUE,"DrawArea"=>TRUE,"Angle"=>350,"AreaBorderR"=>70,"AreaBorderG"=>20,"AreaBorderB"=>20);
+ $Barcode->draw($myPicture,"Do what you want !",290,140,$Settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawbarcode128.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.barcode39.php b/notFinishedCode/pChart2.1.2/examples/example.barcode39.php
new file mode 100644
index 0000000..8442d1e
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.barcode39.php
@@ -0,0 +1,48 @@
+<?php
+ /* CAT:Barcode */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pBarcode39.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Draw the picture border */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"Barcode 39 - Add barcode to your pictures",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Create the barcode 39 object */
+ $Barcode = new pBarcode39("../");
+
+ /* Draw a simple barcode */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $Settings = array("ShowLegend"=>TRUE,"DrawArea"=>TRUE);
+ $Barcode->draw($myPicture,"pChart Rocks!",50,50,$Settings);
+
+ /* Draw a rotated barcode */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>12));
+ $Settings = array("ShowLegend"=>TRUE,"DrawArea"=>TRUE,"Angle"=>90);
+ $Barcode->draw($myPicture,"Turn me on",650,50,$Settings);
+
+ /* Draw a rotated barcode */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>12));
+ $Settings = array("R"=>255,"G"=>255,"B"=>255,"AreaR"=>150,"AreaG"=>30,"AreaB"=>27,"ShowLegend"=>TRUE,"DrawArea"=>TRUE,"Angle"=>350,"AreaBorderR"=>70,"AreaBorderG"=>20,"AreaBorderB"=>20);
+ $Barcode->draw($myPicture,"Do what you want !",290,140,$Settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.barcode39.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.basic.php b/notFinishedCode/pChart2.1.2/examples/example.basic.php
new file mode 100644
index 0000000..288bb97
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.basic.php
@@ -0,0 +1,32 @@
+<?php
+ /* CAT:Misc */
+
+ /* Include all the classes */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pData.class.php");
+
+ /* Create your dataset object */
+ $myData = new pData();
+
+ /* Add data in your dataset */
+ $myData->addPoints(array(1,3,4,3,5));
+
+ /* Create a pChart object and associate your dataset */
+ $myPicture = new pImage(700,230,$myData);
+
+ /* Choose a nice font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Define the boundaries of the graph area */
+ $myPicture->setGraphArea(60,40,670,190);
+
+ /* Draw the scale, keep everything automatic */
+ $myPicture->drawScale();
+
+ /* Draw the scale, keep everything automatic */
+ $myPicture->drawSplineChart();
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.basic.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.cache.php b/notFinishedCode/pChart2.1.2/examples/example.cache.php
new file mode 100644
index 0000000..fd8303a
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.cache.php
@@ -0,0 +1,56 @@
+<?php
+ /* CAT:Misc */
+
+ /* Include all the classes */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pData.class.php");
+ include("../class/pCache.class.php");
+
+ /* Create your dataset object */
+ $myData = new pData();
+
+ /* Add data in your dataset */
+ $myData->addPoints(array(1,3,4,3,5));
+
+ /* Create the cache object */
+ $myCache = new pCache(array("CacheFolder"=>"../cache"));
+
+ /* Compute the hash linked to the chart data */
+ $ChartHash = $myCache->getHash($myData);
+
+ /* Test if we got this hash in our cache already */
+ if ( $myCache->isInCache($ChartHash))
+ {
+ /* If we have it, get the picture from the cache! */
+ $myCache->autoOutput($ChartHash,"pictures/example.cache.png");
+ }
+ else
+ {
+ /* Create a pChart object and associate your dataset */
+ $myPicture = new pImage(700,230,$myData);
+
+ /* Choose a nice font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Define the boundaries of the graph area */
+ $myPicture->setGraphArea(60,40,670,190);
+
+ /* Draw the scale, keep everything automatic */
+ $myPicture->drawScale();
+
+ /* Draw the scale, keep everything automatic */
+ $myPicture->drawSplineChart();
+
+ /* Do some cosmetics */
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"Test of the pCache class",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Push the rendered picture to the cache */
+ $myCache->writeToCache($ChartHash,$myPicture);
+
+ /* Render the picture */
+ $myPicture->autoOutput("pictures/example.cache.png");
+ }
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.draw2DPie.labels.php b/notFinishedCode/pChart2.1.2/examples/example.draw2DPie.labels.php
new file mode 100644
index 0000000..17be018
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.draw2DPie.labels.php
@@ -0,0 +1,56 @@
+<?php
+ /* CAT:Pie charts */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pPie.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(50,2,3,4,7,10,25,48,41,10),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("A0","B1","C2","D3","E4","F5","G6","H7","I8","J9"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,260,$MyData);
+
+ /* Draw a solid background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,260,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,300,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,259,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pPie - Draw 2D pie charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>50));
+
+ /* Create the pPie object */
+ $PieChart = new pPie($myPicture,$MyData);
+
+ /* Draw an AA pie chart */
+ $PieChart->draw2DPie(160,140,array("DrawLabels"=>TRUE,"LabelStacked"=>TRUE,"Border"=>TRUE));
+
+ /* Write the legend box */
+ $myPicture->setShadow(FALSE);
+ $PieChart->drawPieLegend(15,40,array("Alpha"=>20));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.draw2DPie.labels.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.draw2DPie.php b/notFinishedCode/pChart2.1.2/examples/example.draw2DPie.php
new file mode 100644
index 0000000..b6b9355
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.draw2DPie.php
@@ -0,0 +1,68 @@
+<?php
+ /* CAT:Pie charts */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pPie.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(40,60,15,10,6,4),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("<10","10<>20","20<>40","40<>60","60<>80",">80"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw a solid background */
+ $Settings = array("R"=>173, "G"=>152, "B"=>217, "Dash"=>1, "DashR"=>193, "DashG"=>172, "DashB"=>237);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Draw a gradient overlay */
+ $Settings = array("StartR"=>209, "StartG"=>150, "StartB"=>231, "EndR"=>111, "EndG"=>3, "EndB"=>138, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pPie - Draw 2D pie charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>50));
+
+ /* Create the pPie object */
+ $PieChart = new pPie($myPicture,$MyData);
+
+ /* Draw a simple pie chart */
+ $PieChart->draw2DPie(120,125,array("SecondPass"=>FALSE));
+
+ /* Draw an AA pie chart */
+ $PieChart->draw2DPie(340,125,array("DrawLabels"=>TRUE,"LabelStacked"=>TRUE,"Border"=>TRUE));
+
+ /* Draw a splitted pie chart */
+ $PieChart->draw2DPie(560,125,array("WriteValues"=>PIE_VALUE_PERCENTAGE,"DataGapAngle"=>10,"DataGapRadius"=>6,"Border"=>TRUE,"BorderR"=>255,"BorderG"=>255,"BorderB"=>255));
+
+ /* Write the legend */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+ $myPicture->drawText(120,200,"Single AA pass",array("DrawBox"=>TRUE,"BoxRounded"=>TRUE,"R"=>0,"G"=>0,"B"=>0,"Align"=>TEXT_ALIGN_TOPMIDDLE));
+ $myPicture->drawText(440,200,"Extended AA pass / Splitted",array("DrawBox"=>TRUE,"BoxRounded"=>TRUE,"R"=>0,"G"=>0,"B"=>0,"Align"=>TEXT_ALIGN_TOPMIDDLE));
+
+ /* Write the legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6,"R"=>255,"G"=>255,"B"=>255));
+ $PieChart->drawPieLegend(380,8,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.draw2DPie.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.draw2DRing.php b/notFinishedCode/pChart2.1.2/examples/example.draw2DRing.php
new file mode 100644
index 0000000..c02ffb4
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.draw2DRing.php
@@ -0,0 +1,56 @@
+<?php
+ /* CAT:Pie charts */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pPie.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(50,2,3,4,7,10,25,48,41,10),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("A0","B1","C2","D3","E4","F5","G6","H7","I8","J9"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,260,$MyData);
+
+ /* Draw a solid background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,260,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,300,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,259,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pPie - Draw 2D ring charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>50));
+
+ /* Create the pPie object */
+ $PieChart = new pPie($myPicture,$MyData);
+
+ /* Draw an AA pie chart */
+ $PieChart->draw2DRing(160,140,array("DrawLabels"=>TRUE,"LabelStacked"=>TRUE,"Border"=>TRUE));
+
+ /* Write the legend box */
+ $myPicture->setShadow(FALSE);
+ $PieChart->drawPieLegend(15,40,array("Alpha"=>20));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.draw2DRing.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.draw2DRingValues.php b/notFinishedCode/pChart2.1.2/examples/example.draw2DRingValues.php
new file mode 100644
index 0000000..cc2fcc8
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.draw2DRingValues.php
@@ -0,0 +1,56 @@
+<?php
+ /* CAT:Pie charts */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pPie.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(50,2,3,4,7,10,25,48,41,10),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("A0","B1","C2","D3","E4","F5","G6","H7","I8","J9"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,260,$MyData);
+
+ /* Draw a solid background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,260,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,300,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,259,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pPie - Draw 2D ring charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>50));
+
+ /* Create the pPie object */
+ $PieChart = new pPie($myPicture,$MyData);
+
+ /* Draw an AA pie chart */
+ $PieChart->draw2DRing(160,140,array("WriteValues"=>TRUE,"ValueR"=>255,"ValueG"=>255,"ValueB"=>255,"Border"=>TRUE));
+
+ /* Write the legend box */
+ $myPicture->setShadow(FALSE);
+ $PieChart->drawPieLegend(15,40,array("Alpha"=>20));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.draw2DRingValue.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.draw3DPie.labels.php b/notFinishedCode/pChart2.1.2/examples/example.draw3DPie.labels.php
new file mode 100644
index 0000000..6f13632
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.draw3DPie.labels.php
@@ -0,0 +1,53 @@
+<?php
+ /* CAT:Pie charts */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pPie.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(50,2,3,4,7,10,25,48,41,10),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("A0","B1","C2","D3","E4","F5","G6","H7","I8","J9"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,260,$MyData);
+
+ /* Draw a solid background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,260,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,300,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,259,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pPie - Draw 2D pie charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Create the pPie object */
+ $PieChart = new pPie($myPicture,$MyData);
+
+ /* Draw an AA pie chart */
+ $PieChart->draw3DPie(160,140,array("Radius"=>70,"DrawLabels"=>TRUE,"LabelStacked"=>TRUE,"Border"=>TRUE));
+
+ /* Write the legend box */
+ $myPicture->setShadow(FALSE);
+ $PieChart->drawPieLegend(15,40,array("Alpha"=>20));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.draw3DPie.labels.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.draw3DPie.php b/notFinishedCode/pChart2.1.2/examples/example.draw3DPie.php
new file mode 100644
index 0000000..141c48c
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.draw3DPie.php
@@ -0,0 +1,73 @@
+<?php
+ /* CAT:Pie charts */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pPie.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(40,30,20),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("A","B","C"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData,TRUE);
+
+ /* Draw a solid background */
+ $Settings = array("R"=>173, "G"=>152, "B"=>217, "Dash"=>1, "DashR"=>193, "DashG"=>172, "DashB"=>237);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Draw a gradient overlay */
+ $Settings = array("StartR"=>209, "StartG"=>150, "StartB"=>231, "EndR"=>111, "EndG"=>3, "EndB"=>138, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pPie - Draw 3D pie charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Create the pPie object */
+ $PieChart = new pPie($myPicture,$MyData);
+
+ /* Define the slice color */
+ $PieChart->setSliceColor(0,array("R"=>143,"G"=>197,"B"=>0));
+ $PieChart->setSliceColor(1,array("R"=>97,"G"=>77,"B"=>63));
+ $PieChart->setSliceColor(2,array("R"=>97,"G"=>113,"B"=>63));
+
+ /* Draw a simple pie chart */
+ $PieChart->draw3DPie(120,125,array("SecondPass"=>FALSE));
+
+ /* Draw an AA pie chart */
+ $PieChart->draw3DPie(340,125,array("DrawLabels"=>TRUE,"Border"=>TRUE));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>3,"Y"=>3,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw a splitted pie chart */
+ $PieChart->draw3DPie(560,125,array("WriteValues"=>TRUE,"DataGapAngle"=>10,"DataGapRadius"=>6,"Border"=>TRUE));
+
+ /* Write the legend */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+ $myPicture->drawText(120,200,"Single AA pass",array("DrawBox"=>TRUE,"BoxRounded"=>TRUE,"R"=>0,"G"=>0,"B"=>0,"Align"=>TEXT_ALIGN_TOPMIDDLE));
+ $myPicture->drawText(440,200,"Extended AA pass / Splitted",array("DrawBox"=>TRUE,"BoxRounded"=>TRUE,"R"=>0,"G"=>0,"B"=>0,"Align"=>TEXT_ALIGN_TOPMIDDLE));
+
+ /* Write the legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6,"R"=>255,"G"=>255,"B"=>255));
+ $PieChart->drawPieLegend(600,8,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.draw3DPie.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.draw3DPie.transparent.php b/notFinishedCode/pChart2.1.2/examples/example.draw3DPie.transparent.php
new file mode 100644
index 0000000..b96f8f6
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.draw3DPie.transparent.php
@@ -0,0 +1,40 @@
+<?php
+ /* CAT:Pie charts */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pPie.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(40,30,20),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("A","B","C"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(240,180,$MyData,TRUE);
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Create the pPie object */
+ $PieChart = new pPie($myPicture,$MyData);
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>3,"Y"=>3,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw a splitted pie chart */
+ $PieChart->draw3DPie(120,90,array("Radius"=>100,"DataGapAngle"=>12,"DataGapRadius"=>10,"Border"=>TRUE));
+
+ /* Write the legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6,"R"=>0,"G"=>0,"B"=>0));
+ $PieChart->drawPieLegend(140,160,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.draw3DPie.transparent.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.draw3DRing.php b/notFinishedCode/pChart2.1.2/examples/example.draw3DRing.php
new file mode 100644
index 0000000..e0ec7af
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.draw3DRing.php
@@ -0,0 +1,55 @@
+<?php
+ /* CAT:Pie charts */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pPie.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(50,2,3,4,7,10,25,48,41,10),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("A0","B1","C2","D3","E4","F5","G6","H7","I8","J9"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$MyData);
+
+ /* Draw a solid background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pPie - Draw 3D ring charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>50));
+
+ /* Create the pPie object */
+ $PieChart = new pPie($myPicture,$MyData);
+
+ /* Draw an AA pie chart */
+ $PieChart->draw3DRing(200,200,array("DrawLabels"=>TRUE,"LabelStacked"=>TRUE,"Border"=>TRUE));
+
+ /* Write the legend box */
+ $PieChart->drawPieLegend(80,360,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER,"Alpha"=>20));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.draw3DRing.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.draw3DRingValues.php b/notFinishedCode/pChart2.1.2/examples/example.draw3DRingValues.php
new file mode 100644
index 0000000..1139701
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.draw3DRingValues.php
@@ -0,0 +1,55 @@
+<?php
+ /* CAT:Pie charts */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pPie.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(50,2,3,4,7,10,25,48,41,10),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("A0","B1","C2","D3","E4","F5","G6","H7","I8","J9"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$MyData);
+
+ /* Draw a solid background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pPie - Draw 3D ring charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>50));
+
+ /* Create the pPie object */
+ $PieChart = new pPie($myPicture,$MyData);
+
+ /* Draw an AA pie chart */
+ $PieChart->draw3DRing(200,200,array("WriteValues"=>TRUE,"Border"=>TRUE));
+
+ /* Write the legend box */
+ $PieChart->drawPieLegend(80,360,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER,"Alpha"=>20));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.draw3DRingValues.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawAnscombeQuartet.php b/notFinishedCode/pChart2.1.2/examples/example.drawAnscombeQuartet.php
new file mode 100644
index 0000000..cf26c45
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawAnscombeQuartet.php
@@ -0,0 +1,106 @@
+<?php
+ /* CAT:Mathematical */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Define all the data series */
+ $myData->addPoints(array(10,8,13,9,11,14,6,4,12,7,5),"X1");
+ $myData->addPoints(array(8.04,6.95,7.58,8.81,8.33,9.96,7.24,4.26,10.84,4.82,5.68),"Y1");
+ $myData->addPoints(array(10,8,13,9,11,14,6,4,12,7,5),"X2");
+ $myData->addPoints(array(9.14,8.14,8.74,8.77,9.26,8.1,6.13,3.1,9.13,7.26,4.74),"Y2");
+ $myData->addPoints(array(10,8,13,9,11,14,6,4,12,7,5),"X3");
+ $myData->addPoints(array(7.46,6.77,12.74,7.11,7.81,8.84,6.08,5.39,8.15,6.42,5.73),"Y3");
+ $myData->addPoints(array(8,8,8,8,8,8,8,19,8,8,8),"X4");
+ $myData->addPoints(array(6.58,5.76,7.71,8.84,8.47,7.04,5.25,12.5,5.56,7.91,6.89),"Y4");
+
+ /* Create the X axis */
+ $myData->setAxisName(0,"X");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis */
+ $myData->setSerieOnAxis("Y1",1);
+ $myData->setSerieOnAxis("Y2",1);
+ $myData->setSerieOnAxis("Y3",1);
+ $myData->setSerieOnAxis("Y4",1);
+ $myData->setAxisName(1,"Y");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisPosition(1,AXIS_POSITION_LEFT);
+
+ /* Create the scatter chart binding */
+ $myData->setScatterSerie("X1","Y1",0);
+ $myData->setScatterSerie("X2","Y2",1);
+ $myData->setScatterSerie("X3","Y3",2);
+ $myData->setScatterSerie("X4","Y4",3);
+ $myData->setScatterSerieDrawable(1,FALSE);
+ $myData->setScatterSerieDrawable(2,FALSE);
+ $myData->setScatterSerieDrawable(3,FALSE);
+
+ /* Create the pChart object */
+ $myPicture = new pImage(800,582,$myData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,800,582,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,800,582,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,799,581,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>23));
+ $myPicture->drawText(55,50,"Anscombe's Quartet drawing example",array("R"=>255,"G"=>255,"B"=>255));
+ $myPicture->drawText(55,65,"This example demonstrate the importance of graphing data before analysing it. (The line of best fit is the same for all datasets)",array("FontSize"=>12,"R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the 1st chart */
+ $myPicture->setGraphArea(56,90,380,285);
+ $myScatter->drawScatterScale(array("XMargin"=>5,"YMargin"=>5,"Floating"=>TRUE,"DrawSubTicks"=>TRUE));
+ $myScatter->drawScatterPlotChart();
+ $myScatter->drawScatterBestFit();
+
+ /* Draw the 2nt chart */
+ $myData->setScatterSerieDrawable(0,FALSE);
+ $myData->setScatterSerieDrawable(1,TRUE);
+ $myPicture->setGraphArea(436,90,760,285);
+ $myScatter->drawScatterScale(array("XMargin"=>5,"YMargin"=>5,"Floating"=>TRUE,"DrawSubTicks"=>TRUE));
+ $myScatter->drawScatterPlotChart();
+ $myScatter->drawScatterBestFit();
+
+ /* Draw the 3rd chart */
+ $myData->setScatterSerieDrawable(1,FALSE);
+ $myData->setScatterSerieDrawable(2,TRUE);
+ $myPicture->setGraphArea(56,342,380,535);
+ $myScatter->drawScatterScale(array("XMargin"=>5,"YMargin"=>5,"Floating"=>TRUE,"DrawSubTicks"=>TRUE));
+ $myScatter->drawScatterPlotChart();
+ $myScatter->drawScatterBestFit();
+
+ /* Draw the 4th chart */
+ $myData->setScatterSerieDrawable(2,FALSE);
+ $myData->setScatterSerieDrawable(3,TRUE);
+ $myPicture->setGraphArea(436,342,760,535);
+ $myScatter->drawScatterScale(array("XMargin"=>5,"YMargin"=>5,"Floating"=>TRUE,"DrawSubTicks"=>TRUE));
+ $myScatter->drawScatterPlotChart();
+ $myScatter->drawScatterBestFit();
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawAnscombeQuartet.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawAntialiasPixel.php b/notFinishedCode/pChart2.1.2/examples/example.drawAntialiasPixel.php
new file mode 100644
index 0000000..8b0cbe3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawAntialiasPixel.php
@@ -0,0 +1,35 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>180,"StartG"=>193,"StartB"=>91,"EndR"=>120,"EndG"=>137,"EndB"=>72,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>180,"StartG"=>193,"StartB"=>91,"EndR"=>120,"EndG"=>137,"EndB"=>72,"Alpha"=>20));
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawAntialiasPixel() - Drawing antialiased pixel with transparency",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Draw some alpha pixels */
+ for($X=0;$X<=160;$X++)
+ {
+ for($Y=0;$Y<=160;$Y++)
+ {
+ $PixelSettings = array("R"=>128,"G"=>255-$Y,"B"=>$X,"Alpha"=>cos(deg2rad($X*2))*50+50);
+
+ $myPicture->drawAntialiasPixel($X*2+20.4,$Y+45,$PixelSettings);
+ $myPicture->drawAntialiasPixel($X+400,$Y+45,$PixelSettings);
+ }
+ }
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawantialiaspixel.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.php
new file mode 100644
index 0000000..d547e6a
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.php
@@ -0,0 +1,66 @@
+<?php
+ /* CAT:Area Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawAreaChart() - draw an area chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawAreaChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO));
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the scale and the 2nd chart */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawAreaChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(510,205,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawAreaChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.simple.php
new file mode 100644
index 0000000..bf0aac3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.simple.php
@@ -0,0 +1,56 @@
+<?php
+ /* CAT:Area Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(4,2,10,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,15,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(540,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw the area chart */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ $myPicture->drawAreaChart();
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawAreaChart.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.threshold.php b/notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.threshold.php
new file mode 100644
index 0000000..79caf77
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawAreaChart.threshold.php
@@ -0,0 +1,60 @@
+<?php
+ /* CAT:Area Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ for($i=0;$i<=30;$i++) { $MyData->addPoints(rand(1,15),"Probe 1"); }
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setAxisName(0,"Temperatures");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(600,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the area chart */
+ $Threshold = "";
+ $Threshold[] = array("Min"=>0,"Max"=>5,"R"=>207,"G"=>240,"B"=>20,"Alpha"=>70);
+ $Threshold[] = array("Min"=>5,"Max"=>10,"R"=>240,"G"=>232,"B"=>20,"Alpha"=>70);
+ $Threshold[] = array("Min"=>10,"Max"=>20,"R"=>240,"G"=>191,"B"=>20,"Alpha"=>70);
+ $myPicture->drawAreaChart(array("Threshold"=>$Threshold));
+
+ /* Write the thresholds */
+ $myPicture->drawThreshold(5,array("WriteCaption"=>TRUE,"Caption"=>"Warn Zone","Alpha"=>70,"Ticks"=>2,"R"=>0,"G"=>0,"B"=>255));
+ $myPicture->drawThreshold(10,array("WriteCaption"=>TRUE,"Caption"=>"Error Zone","Alpha"=>70,"Ticks"=>2,"R"=>0,"G"=>0,"B"=>255));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawAreaChart.threshold.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawArrow.php b/notFinishedCode/pChart2.1.2/examples/example.drawArrow.php
new file mode 100644
index 0000000..2b74ad1
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawArrow.php
@@ -0,0 +1,40 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawArrow() - Arrows on your charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw some arrows */
+ for($i=1;$i<=100;$i=$i+8)
+ {
+ $arrowSettings = array("FillR"=>$i*2.5,"FillG"=>$i*2.5,"FillB"=>$i*2.5,"Ticks"=>$i % 5);
+
+ $myPicture->drawArrow($i+5,215,$i*7+5,30,$arrowSettings);
+ }
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawArrow.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawArrowLabel.php b/notFinishedCode/pChart2.1.2/examples/example.drawArrowLabel.php
new file mode 100644
index 0000000..b3ddc95
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawArrowLabel.php
@@ -0,0 +1,48 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawArrowLabel() - Adaptative label positionning",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw an arrow with a 45 degree angle */
+ $ArrowSettings = array("FillR"=>37,"FillG"=>78,"FillB"=>117,"Length"=>40,"Angle"=>45);
+ $myPicture->drawArrowLabel(348,113,"Blue",$ArrowSettings);
+
+ /* Draw an arrow with a 135 degree angle */
+ $ArrowSettings = array("FillR"=>188,"FillG"=>49,"FillB"=>42,"Length"=>40,"Angle"=>135,"Position"=>POSITION_BOTTOM,"Ticks"=>2);
+ $myPicture->drawArrowLabel(348,117,"Red",$ArrowSettings);
+
+ /* Draw an arrow with a 225 degree angle */
+ $ArrowSettings = array("FillR"=>51,"FillG"=>119,"FillB"=>35,"Length"=>40,"Angle"=>225,"Position"=>POSITION_BOTTOM,"Ticks"=>3);
+ $myPicture->drawArrowLabel(352,117,"Green",$ArrowSettings);
+
+ /* Draw an arrow with a 315 degree angle */
+ $ArrowSettings = array("FillR"=>239,"FillG"=>231,"FillB"=>97,"Length"=>40,"Angle"=>315,"Ticks"=>4);
+ $myPicture->drawArrowLabel(352,113,"Yellow",$ArrowSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawArrowLabel.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.borders.php b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.borders.php
new file mode 100644
index 0000000..a310165
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.borders.php
@@ -0,0 +1,52 @@
+<?php
+ /* CAT:Bar Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(150,220,300,-250,-420,-200,300,200,100),"Server A");
+ $MyData->addPoints(array(140,0,340,-300,-320,-300,200,100,50),"Server B");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("January","February","March","April","May","Juin","July","August","September"),"Months");
+ $MyData->setSerieDescription("Months","Month");
+ $MyData->setAbscissa("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,12,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the chart */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $settings = array("Surrounding"=>-30,"InnerSurrounding"=>30);
+ $myPicture->drawBarChart($settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.can.php b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.can.php
new file mode 100644
index 0000000..901f102
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.can.php
@@ -0,0 +1,41 @@
+<?php
+ /* CAT:Bar Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->loadPalette("../palettes/light.color",TRUE);
+ $MyData->addPoints(array(150,220,300,-250,-420,-200,300,200,100),"Server A");
+ $MyData->addPoints(array(140,0,340,-300,-320,-300,200,100,50),"Server B");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("January","February","March","April","May","Juin","July","August","September"),"Months");
+ $MyData->setSerieDescription("Months","Month");
+ $MyData->setAbscissa("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale */
+ $myPicture->setGraphArea(50,30,680,200);
+ $myPicture->drawScale(array("CycleBackground"=>TRUE,"DrawSubTicks"=>TRUE,"GridR"=>0,"GridG"=>0,"GridB"=>0,"GridAlpha"=>10));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the chart */
+ $settings = array("Gradient"=>TRUE,"GradientMode"=>GRADIENT_EFFECT_CAN,"DisplayPos"=>LABEL_POS_INSIDE,"DisplayValues"=>TRUE,"DisplayR"=>255,"DisplayG"=>255,"DisplayB"=>255,"DisplayShadow"=>TRUE,"Surrounding"=>10);
+ $myPicture->drawBarChart($settings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,12,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.can.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.floating.php b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.floating.php
new file mode 100644
index 0000000..0a38bbb
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.floating.php
@@ -0,0 +1,45 @@
+<?php
+ /* CAT:Bar Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->loadPalette("../palettes/blind.color",TRUE);
+ $MyData->addPoints(array(150,220,300,250,420,200,300,200,100),"Server A");
+ $MyData->addPoints(array(140,0,340,300,320,300,200,100,50),"Server B");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("January","February","March","April","May","Juin","July","August","September"),"Months");
+ $MyData->setSerieDescription("Months","Month");
+ $MyData->setAbscissa("Months");
+
+ /* Create the floating 0 data serie */
+ $MyData->addPoints(array(60,80,20,40,0,50,90,30,100),"Floating 0");
+ $MyData->setSerieDrawable("Floating 0",FALSE);
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale */
+ $myPicture->setGraphArea(50,30,680,200);
+ $myPicture->drawScale(array("CycleBackground"=>TRUE,"DrawSubTicks"=>TRUE,"GridR"=>0,"GridG"=>0,"GridB"=>0,"GridAlpha"=>10));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the chart */
+ $settings = array("Floating0Serie"=>"Floating 0","Draw0Line"=>TRUE,"Gradient"=>TRUE,"DisplayPos"=>LABEL_POS_INSIDE,"DisplayValues"=>TRUE,"DisplayR"=>255,"DisplayG"=>255,"DisplayB"=>255,"DisplayShadow"=>TRUE,"Surrounding"=>10);
+ $myPicture->drawBarChart($settings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,12,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.floating.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.palette.php b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.palette.php
new file mode 100644
index 0000000..9f51eef
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.palette.php
@@ -0,0 +1,49 @@
+<?php
+ /* CAT:Bar Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(13251,4118,3087,1460,1248,156,26,9,8),"Hits");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("Firefox","Chrome","Internet Explorer","Opera","Safari","Mozilla","SeaMonkey","Camino","Lunascape"),"Browsers");
+ $MyData->setSerieDescription("Browsers","Browsers");
+ $MyData->setAbscissa("Browsers");
+ $MyData->setAbscissaName("Browsers");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(500,500,$MyData);
+ $myPicture->drawGradientArea(0,0,500,500,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,500,500,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the chart scale */
+ $myPicture->setGraphArea(100,30,480,480);
+ $myPicture->drawScale(array("CycleBackground"=>TRUE,"DrawSubTicks"=>TRUE,"GridR"=>0,"GridG"=>0,"GridB"=>0,"GridAlpha"=>10,"Pos"=>SCALE_POS_TOPBOTTOM)); //
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the per bar palette */
+ $Palette = array("0"=>array("R"=>188,"G"=>224,"B"=>46,"Alpha"=>100),
+ "1"=>array("R"=>224,"G"=>100,"B"=>46,"Alpha"=>100),
+ "2"=>array("R"=>224,"G"=>214,"B"=>46,"Alpha"=>100),
+ "3"=>array("R"=>46,"G"=>151,"B"=>224,"Alpha"=>100),
+ "4"=>array("R"=>176,"G"=>46,"B"=>224,"Alpha"=>100),
+ "5"=>array("R"=>224,"G"=>46,"B"=>117,"Alpha"=>100),
+ "6"=>array("R"=>92,"G"=>224,"B"=>46,"Alpha"=>100),
+ "7"=>array("R"=>224,"G"=>176,"B"=>46,"Alpha"=>100));
+
+ /* Draw the chart */
+ $myPicture->drawBarChart(array("DisplayPos"=>LABEL_POS_INSIDE,"DisplayValues"=>TRUE,"Rounded"=>TRUE,"Surrounding"=>30,"OverrideColors"=>$Palette));
+
+ /* Write the legend */
+ $myPicture->drawLegend(570,215,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.palette.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.php
new file mode 100644
index 0000000..721a5b8
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.php
@@ -0,0 +1,65 @@
+<?php
+ /* CAT:Bar Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,0,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawBarChart() - draw a bar chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawBarChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO,"Rounded"=>TRUE,"Surrounding"=>30));
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the scale and the 2nd chart */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawBarChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(510,205,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.poll.php b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.poll.php
new file mode 100644
index 0000000..6c94792
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.poll.php
@@ -0,0 +1,42 @@
+<?php
+ /* CAT:Bar Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(60,30,10),"Answers");
+ $MyData->setAxisName(0,"Answers (%)");
+ $MyData->addPoints(array("I do agree ","I disagree ","No opinion "),"Options");
+ $MyData->setAbscissa("Options");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(500,220,$MyData);
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>15));
+ $myPicture->drawText(20,34,"Q: Flexibility is a key point of this library",array("FontSize"=>20));
+
+ /* Define the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(70,60,480,200);
+ $myPicture->drawGradientArea(70,60,480,200,DIRECTION_HORIZONTAL,array("StartR"=>200,"StartG"=>200,"StartB"=>200,"EndR"=>240,"EndG"=>240,"EndB"=>240,"Alpha"=>30));
+
+ /* Draw the chart scale */
+ $scaleSettings = array("DrawXLines"=>FALSE,"Mode"=>SCALE_MODE_START0,"GridR"=>0,"GridG"=>0,"GridB"=>0,"GridAlpha"=>10,"Pos"=>SCALE_POS_TOPBOTTOM);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the chart */
+ $myPicture->drawBarChart(array("Rounded"=>TRUE,"Surrounding"=>30));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.poll.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.shaded.php b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.shaded.php
new file mode 100644
index 0000000..163089f
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.shaded.php
@@ -0,0 +1,40 @@
+<?php
+ /* CAT:Bar Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(150,220,300,-250,-420,-200,300,200,100),"Server A");
+ $MyData->addPoints(array(140,0,340,-300,-320,-300,200,100,50),"Server B");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("January","February","March","April","May","Juin","July","August","September"),"Months");
+ $MyData->setSerieDescription("Months","Month");
+ $MyData->setAbscissa("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale */
+ $myPicture->setGraphArea(50,30,680,200);
+ $myPicture->drawScale(array("CycleBackground"=>TRUE,"DrawSubTicks"=>TRUE,"GridR"=>0,"GridG"=>0,"GridB"=>0,"GridAlpha"=>10));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the chart */
+ $settings = array("Gradient"=>TRUE,"DisplayPos"=>LABEL_POS_INSIDE,"DisplayValues"=>TRUE,"DisplayR"=>255,"DisplayG"=>255,"DisplayB"=>255,"DisplayShadow"=>TRUE,"Surrounding"=>10);
+ $myPicture->drawBarChart($settings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,12,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.shaded.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.simple.php
new file mode 100644
index 0000000..cacdccb
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.simple.php
@@ -0,0 +1,50 @@
+<?php
+ /* CAT:Bar Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(150,220,300,-250,-420,-200,300,200,100),"Server A");
+ $MyData->addPoints(array(140,0,340,-300,-320,-300,200,100,50),"Server B");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("January","February","March","April","May","Juin","July","August","September"),"Months");
+ $MyData->setSerieDescription("Months","Month");
+ $MyData->setAbscissa("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,12,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the chart */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $settings = array("Gradient"=>TRUE,"GradientMode"=>GRADIENT_EFFECT_CAN,"DisplayPos"=>LABEL_POS_INSIDE,"DisplayValues"=>TRUE,"DisplayR"=>255,"DisplayG"=>255,"DisplayB"=>255,"DisplayShadow"=>TRUE,"Surrounding"=>10);
+ $myPicture->drawBarChart();
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.spacing.php b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.spacing.php
new file mode 100644
index 0000000..94d311d
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.spacing.php
@@ -0,0 +1,52 @@
+<?php
+ /* CAT:Bar Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(150,220,300,250,420,200,300,200,100),"Server A");
+ $MyData->addPoints(array(140,0,340,300,320,300,200,100,50),"Server B");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("January","February","March","April","May","Juin","July","August","September"),"Months");
+ $MyData->setSerieDescription("Months","Month");
+ $MyData->setAbscissa("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,12,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the chart */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $settings = array("Surrounding"=>-30,"InnerSurrounding"=>30,"Interleave"=>0);
+ $myPicture->drawBarChart($settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.spacing.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.vertical.php b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.vertical.php
new file mode 100644
index 0000000..f1c68ab
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBarChart.vertical.php
@@ -0,0 +1,40 @@
+<?php
+ /* CAT:Bar Chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(13251,4118,3087,1460,1248,156,26,9,8),"Hits");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("Firefox","Chrome","Internet Explorer","Opera","Safari","Mozilla","SeaMonkey","Camino","Lunascape"),"Browsers");
+ $MyData->setSerieDescription("Browsers","Browsers");
+ $MyData->setAbscissa("Browsers");
+ $MyData->setAbscissaName("Browsers");
+ $MyData->setAxisDisplay(0,AXIS_FORMAT_METRIC,1);
+
+ /* Create the pChart object */
+ $myPicture = new pImage(500,500,$MyData);
+ $myPicture->drawGradientArea(0,0,500,500,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,500,500,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the chart scale */
+ $myPicture->setGraphArea(100,30,480,480);
+ $myPicture->drawScale(array("CycleBackground"=>TRUE,"DrawSubTicks"=>TRUE,"GridR"=>0,"GridG"=>0,"GridB"=>0,"GridAlpha"=>10,"Pos"=>SCALE_POS_TOPBOTTOM)); //
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the chart */
+ $myPicture->drawBarChart(array("DisplayPos"=>LABEL_POS_INSIDE,"DisplayValues"=>TRUE,"Rounded"=>TRUE,"Surrounding"=>30));
+
+ /* Write the legend */
+ $myPicture->drawLegend(570,215,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.vertical.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBestfit.php b/notFinishedCode/pChart2.1.2/examples/example.drawBestfit.php
new file mode 100644
index 0000000..37273c8
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBestfit.php
@@ -0,0 +1,55 @@
+<?php
+ /* CAT:Mathematical */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ for($i=0;$i<=20;$i++) { $MyData->addPoints(rand(10,30)+$i,"Probe 1"); }
+ for($i=0;$i<=20;$i++) { $MyData->addPoints(rand(0,10)+$i,"Probe 2"); }
+ $MyData->setAxisName(0,"Temperatures");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw the line of best fit */
+ $myPicture->drawBestFit();
+
+ /* Turn on shadows */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the line chart */
+ $myPicture->drawPlotChart();
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBestFit.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBezier.php b/notFinishedCode/pChart2.1.2/examples/example.drawBezier.php
new file mode 100644
index 0000000..cb5a482
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBezier.php
@@ -0,0 +1,40 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawBezier() - some cubic curves",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw one bezier curve */
+ $BezierSettings = array("R"=>255,"G"=>255,"B"=>255,"ShowControl"=>TRUE);
+ $myPicture->drawBezier(20,40,280,170,130,160,160,60,$BezierSettings);
+
+ /* Draw one bezier curve */
+ $BezierSettings = array("R"=>255,"G"=>255,"B"=>255,"ShowControl"=>TRUE,"Ticks"=>4,"DrawArrow"=>TRUE,"ArrowTwoHeads"=>TRUE);
+ $myPicture->drawBezier(360,120,630,120,430,50,560,190,$BezierSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBezier.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBubbleChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawBubbleChart.php
new file mode 100644
index 0000000..5346df4
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBubbleChart.php
@@ -0,0 +1,79 @@
+<?php
+ /* CAT:Bubble chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pBubble.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->loadPalette("../palettes/summer.color",TRUE);
+ $MyData->addPoints(array(34,55,15,62,38,42),"Probe1");
+ $MyData->addPoints(array(5,10,8,9,15,10),"Probe1Weight");
+ $MyData->addPoints(array(5,10,-5,-1,0,-10),"Probe2");
+ $MyData->addPoints(array(6,10,14,10,14,6),"Probe2Weight");
+ $MyData->setSerieDescription("Probe1","This year");
+ $MyData->setSerieDescription("Probe2","Last year");
+ $MyData->setAxisName(0,"Current stock");
+ $MyData->addPoints(array("Apple","Banana","Orange","Lemon","Peach","Strawberry"),"Product");
+ $MyData->setAbscissa("Product");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawBubbleChart() - draw a linear bubble chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(40,55,"Current Stock / Needs chart",array("FontSize"=>14,"Align"=>TEXT_ALIGN_BOTTOMLEFT));
+
+ /* Change the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Create the Bubble chart object and scale up */
+ $myBubbleChart = new pBubble($myPicture,$MyData);
+
+ /* Scale up for the bubble chart */
+ $bubbleDataSeries = array("Probe1","Probe2");
+ $bubbleWeightSeries = array("Probe1Weight","Probe2Weight");
+ $myBubbleChart->bubbleScale($bubbleDataSeries,$bubbleWeightSeries);
+
+ /* Draw the 1st chart */
+ $myPicture->setGraphArea(40,60,430,190);
+ $myPicture->drawFilledRectangle(40,60,430,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-50,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>30));
+ $myBubbleChart->drawBubbleChart($bubbleDataSeries,$bubbleWeightSeries);
+
+ /* Draw the 2nd scale */
+ $myPicture->setShadow(FALSE);
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+
+ /* Draw the 2nd stock chart */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>30));
+ $myBubbleChart->drawbubbleChart($bubbleDataSeries,$bubbleWeightSeries,array("DrawBorder"=>TRUE,"Surrounding"=>60,"BorderAlpha"=>100));
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(550,215,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBubbleChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawBubbleChart.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawBubbleChart.simple.php
new file mode 100644
index 0000000..a0fe8de
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawBubbleChart.simple.php
@@ -0,0 +1,58 @@
+<?php
+ /* CAT:Bubble chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pBubble.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(34,55,15,62,38,42),"Probe1");
+ $MyData->addPoints(array(5,30,20,9,15,10),"Probe1Weight");
+ $MyData->addPoints(array(5,10,-5,-1,0,-10),"Probe2");
+ $MyData->addPoints(array(6,10,14,10,14,6),"Probe2Weight");
+ $MyData->setSerieDescription("Probe1","This year");
+ $MyData->setSerieDescription("Probe2","Last year");
+ $MyData->setAxisName(0,"Current stock");
+ $MyData->addPoints(array("Apple","Banana","Orange","Lemon","Peach","Strawberry"),"Product");
+ $MyData->setAbscissa("Product");
+ $MyData->setAbscissaName("Selected Products");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of AAliasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the border */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,30,650,190);
+
+ /* Draw the scale */
+ $scaleSettings = array("GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Create the Bubble chart object and scale up */
+ $myPicture->Antialias = TRUE;
+ $myBubbleChart = new pBubble($myPicture,$MyData);
+
+ /* Scale up for the bubble chart */
+ $bubbleDataSeries = array("Probe1","Probe2");
+ $bubbleWeightSeries = array("Probe1Weight","Probe2Weight");
+ $myBubbleChart->bubbleScale($bubbleDataSeries,$bubbleWeightSeries);
+
+ /* Draw the bubble chart */
+ $myBubbleChart->drawBubbleChart($bubbleDataSeries,$bubbleWeightSeries,array("ForceAlpha"=>50));
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(570,13,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBubbleChart.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawCircle.php b/notFinishedCode/pChart2.1.2/examples/example.drawCircle.php
new file mode 100644
index 0000000..dfd9c5c
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawCircle.php
@@ -0,0 +1,54 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawCircle() - Transparency & colors",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Draw some circles */
+ $myPicture->drawCircle(100,125,50,50,array("R"=>213,"G"=>226,"B"=>0,"Alpha"=>100));
+ $myPicture->drawCircle(140,125,50,50,array("R"=>213,"G"=>226,"B"=>0,"Alpha"=>70));
+ $myPicture->drawCircle(180,125,50,50,array("R"=>213,"G"=>226,"B"=>0,"Alpha"=>40));
+ $myPicture->drawCircle(220,125,50,50,array("R"=>213,"G"=>226,"B"=>0,"Alpha"=>20));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a customized circles */
+ $CircleSettings = array("R"=>209,"G"=>31,"B"=>27,"Alpha"=>100);
+ $myPicture->drawCircle(480,60,20,20,$CircleSettings);
+
+ /* Draw a customized circles */
+ $CircleSettings = array("R"=>209,"G"=>125,"B"=>27,"Alpha"=>100);
+ $myPicture->drawCircle(480,100,30,20,$CircleSettings);
+
+ /* Draw a customized circles */
+ $CircleSettings = array("R"=>209,"G"=>198,"B"=>27,"Alpha"=>100,"Ticks"=>4);
+ $myPicture->drawCircle(480,140,40,20,$CircleSettings);
+
+ /* Draw a customized circles */
+ $CircleSettings = array("R"=>134,"G"=>209,"B"=>27,"Alpha"=>100,"Ticks"=>4);
+ $myPicture->drawCircle(480,180,50,20,$CircleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawCircle.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawContour.php b/notFinishedCode/pChart2.1.2/examples/example.drawContour.php
new file mode 100644
index 0000000..cd8e8b6
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawContour.php
@@ -0,0 +1,61 @@
+<?php
+ /* CAT:Surface chart*/
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pSurface.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400);
+
+ /* Create a solid background */
+ $Settings = array("R"=>179, "G"=>217, "B"=>91, "Dash"=>1, "DashR"=>199, "DashG"=>237, "DashB"=>111);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Do a gradient overlay */
+ $Settings = array("StartR"=>194, "StartG"=>231, "StartB"=>44, "EndR"=>43, "EndG"=>107, "EndB"=>58, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pSurface() :: 2D surface charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Define the charting area */
+ $myPicture->setGraphArea(20,40,380,380);
+ $myPicture->drawFilledRectangle(20,40,380,380,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>20));
+
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1));
+
+ /* Create the surface object */
+ $mySurface = new pSurface($myPicture);
+
+ /* Set the grid size */
+ $mySurface->setGrid(20,20);
+
+ /* Write the axis labels */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $mySurface->writeXLabels(array("Position"=>LABEL_POSITION_BOTTOM));
+ $mySurface->writeYLabels();
+
+ /* Add random values */
+ for($i=0; $i<=50; $i++) { $mySurface->addPoint(rand(0,20),rand(0,20),rand(0,100)); }
+
+ /* Compute the missing points */
+ $mySurface->computeMissing();
+
+ /* Draw the surface chart */
+ $mySurface->drawSurface(array("Border"=>TRUE,"Surrounding"=>40));
+
+ /* Draw the contour with a threshold of 50 */
+ $mySurface->drawContour(50,array("R"=>0,"G"=>0,"B"=>0));
+
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.surface.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawDerivative.php b/notFinishedCode/pChart2.1.2/examples/example.drawDerivative.php
new file mode 100644
index 0000000..ffab09f
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawDerivative.php
@@ -0,0 +1,61 @@
+<?php
+ /* CAT:Mathematical */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3,4,5,0,4,6,10),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5,5,-5,-3,4,5,10),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22,10,2,6,10,5,6),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setSerieWeight("Probe 3",2);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+ $MyData->setAbscissaName("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawDerivative() - draw the series slope",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,40,680,150);
+ $myPicture->drawFilledRectangle(60,40,680,150,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawLineChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO));
+
+ /* Draw the series derivative graph */
+ $myPicture->drawDerivative(array("ShadedSlopeBox"=>TRUE,"CaptionLine"=>TRUE));
+
+ /* Write the chart legend */
+ $myPicture->setFontProperties(array("R"=>255,"G"=>255,"B"=>255));
+ $myPicture->drawLegend(560,8,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawDerivative.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawDerivative.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawDerivative.simple.php
new file mode 100644
index 0000000..593b8fe
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawDerivative.simple.php
@@ -0,0 +1,47 @@
+<?php
+ /* CAT:Mathematical */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(3,12,15,8,5,-5,5,-5,-3,4,5,10),"Probe");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+ $MyData->setAbscissaName("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of AAliasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("R"=>0,"G"=>0,"B"=>0,"FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(50,40,680,170);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"DrawSubTicks"=>TRUE,"GridR"=>100,"GridG"=>100,"GridB"=>100,"GridAlpha"=>15);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Draw the chart */
+ $myPicture->Antialias = TRUE;
+ $myPicture->drawSplineChart();
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the series derivative graph */
+ $myPicture->drawDerivative(array("Caption"=>FALSE));
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(640,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawDerivative.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawFilledCircle.php b/notFinishedCode/pChart2.1.2/examples/example.drawFilledCircle.php
new file mode 100644
index 0000000..525b67e
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawFilledCircle.php
@@ -0,0 +1,54 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawCircle() - Transparency & colors",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Draw some filled circles */
+ $myPicture->drawFilledCircle(100,125,50,array("R"=>213,"G"=>226,"B"=>0,"Alpha"=>100));
+ $myPicture->drawFilledCircle(140,125,50,array("R"=>213,"G"=>226,"B"=>0,"Alpha"=>70));
+ $myPicture->drawFilledCircle(180,125,50,array("R"=>213,"G"=>226,"B"=>0,"Alpha"=>40));
+ $myPicture->drawFilledCircle(220,125,50,array("R"=>213,"G"=>226,"B"=>0,"Alpha"=>20));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a customized filled circles */
+ $CircleSettings = array("R"=>209,"G"=>31,"B"=>27,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawFilledCircle(480,60,19,$CircleSettings);
+
+ /* Draw a customized filled circles */
+ $CircleSettings = array("R"=>209,"G"=>125,"B"=>27,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawFilledCircle(480,100,19,$CircleSettings);
+
+ /* Draw a customized filled circles */
+ $CircleSettings = array("R"=>209,"G"=>198,"B"=>27,"Alpha"=>100,"Surrounding"=>30,"Ticks"=>4);
+ $myPicture->drawFilledCircle(480,140,19,$CircleSettings);
+
+ /* Draw a customized filled circles */
+ $CircleSettings = array("R"=>134,"G"=>209,"B"=>27,"Alpha"=>100,"Surrounding"=>30,"Ticks"=>4);
+ $myPicture->drawFilledCircle(480,180,19,$CircleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawFilledCircle.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawFilledRectangle.php b/notFinishedCode/pChart2.1.2/examples/example.drawFilledRectangle.php
new file mode 100644
index 0000000..65d90e3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawFilledRectangle.php
@@ -0,0 +1,57 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawFilledRectangle() - Transparency & colors",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>150,"G"=>200,"B"=>170,"Dash"=>TRUE,"DashR"=>170,"DashG"=>220,"DashB"=>190,"BorderR"=>255,"BorderG"=>255,"BorderB"=>255);
+ $myPicture->drawFilledRectangle(20,60,400,170,$RectangleSettings);
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>134,"B"=>27,"Alpha"=>30);
+ $myPicture->drawFilledRectangle(30,30,200,200,$RectangleSettings);
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>31,"B"=>27,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawFilledRectangle(480,50,650,80,$RectangleSettings);
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>125,"B"=>27,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawFilledRectangle(480,90,650,120,$RectangleSettings);
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>198,"B"=>27,"Alpha"=>100,"Surrounding"=>30,"Ticks"=>2);
+ $myPicture->drawFilledRectangle(480,130,650,160,$RectangleSettings);
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>134,"G"=>209,"B"=>27,"Alpha"=>100,"Surrounding"=>30,"Ticks"=>2);
+ $myPicture->drawFilledRectangle(480,170,650,200,$RectangleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawFilledRectangle.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawFilledSplineChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawFilledSplineChart.php
new file mode 100644
index 0000000..4ea49a0
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawFilledSplineChart.php
@@ -0,0 +1,74 @@
+<?php
+ /* CAT:Spline chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->setAxisName(0,"Strength");
+ for($i=0;$i<=720;$i=$i+20)
+ {
+ $MyData->addPoints(cos(deg2rad($i))*100,"Probe 1");
+ $MyData->addPoints(cos(deg2rad($i+90))*60,"Probe 2");
+ }
+
+ /* Create the pChart object */
+ $myPicture = new pImage(847,304,$MyData);
+ $myPicture->drawGradientArea(0,0,847,304,DIRECTION_VERTICAL,array("StartR"=>47,"StartG"=>47,"StartB"=>47,"EndR"=>17,"EndG"=>17,"EndB"=>17,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,250,847,304,DIRECTION_VERTICAL,array("StartR"=>47,"StartG"=>47,"StartB"=>47,"EndR"=>27,"EndG"=>27,"EndB"=>27,"Alpha"=>100));
+ $myPicture->drawLine(0,249,847,249,array("R"=>0,"G"=>0,"B"=>0));
+ $myPicture->drawLine(0,250,847,250,array("R"=>70,"G"=>70,"B"=>70));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,846,303,array("R"=>204,"G"=>204,"B"=>204));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawText(423,14,"Cyclic magnetic field strength",array("R"=>255,"G"=>255,"B"=>255,"Align"=>TEXT_ALIGN_MIDDLEMIDDLE));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(58,27,816,228);
+
+ /* Draw a rectangle */
+ $myPicture->drawFilledRectangle(58,27,816,228,array("R"=>0,"G"=>0,"B"=>0,"Dash"=>TRUE,"DashR"=>0,"DashG"=>51,"DashB"=>51,"BorderR"=>0,"BorderG"=>0,"BorderB"=>0));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw the scale */
+ $myPicture->setFontProperties(array("R"=>255,"G"=>255,"B"=>255));
+ $ScaleSettings = array("XMargin"=>4,"DrawSubTicks"=>TRUE,"GridR"=>255,"GridG"=>255,"GridB"=>255,"AxisR"=>255,"AxisG"=>255,"AxisB"=>255,"GridAlpha"=>30,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($ScaleSettings);
+
+ /* Draw the spline chart */
+ $myPicture->drawFilledSplineChart();
+
+ /* Write the chart boundaries */
+ $BoundsSettings = array("MaxDisplayR"=>237,"MaxDisplayG"=>23,"MaxDisplayB"=>48,"MinDisplayR"=>23,"MinDisplayG"=>144,"MinDisplayB"=>237);
+ $myPicture->writeBounds(BOUND_BOTH,$BoundsSettings);
+
+ /* Write the 0 line */
+ $myPicture->drawThreshold(0,array("WriteCaption"=>TRUE));
+
+ /* Write the chart legend */
+ $myPicture->setFontProperties(array("R"=>255,"G"=>255,"B"=>255));
+ $myPicture->drawLegend(560,266,array("Style"=>LEGEND_NOBORDER));
+
+ /* Write the 1st data series statistics */
+ $Settings = array("R"=>188,"G"=>224,"B"=>46,"Align"=>TEXT_ALIGN_BOTTOMLEFT);
+ $myPicture->drawText(620,270,"Max : ".ceil($MyData->getMax("Probe 1")),$Settings);
+ $myPicture->drawText(680,270,"Min : ".ceil($MyData->getMin("Probe 1")),$Settings);
+ $myPicture->drawText(740,270,"Avg : ".ceil($MyData->getSerieAverage("Probe 1")),$Settings);
+
+ /* Write the 2nd data series statistics */
+ $Settings = array("R"=>224,"G"=>100,"B"=>46,"Align"=>TEXT_ALIGN_BOTTOMLEFT);
+ $myPicture->drawText(620,283,"Max : ".ceil($MyData->getMax("Probe 2")),$Settings);
+ $myPicture->drawText(680,283,"Min : ".ceil($MyData->getMin("Probe 2")),$Settings);
+ $myPicture->drawText(740,283,"Avg : ".ceil($MyData->getSerieAverage("Probe 2")),$Settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawFilledSplineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawFilledSplineChart.threshold.php b/notFinishedCode/pChart2.1.2/examples/example.drawFilledSplineChart.threshold.php
new file mode 100644
index 0000000..802d3fe
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawFilledSplineChart.threshold.php
@@ -0,0 +1,76 @@
+<?php
+ /* CAT:Spline chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->setAxisName(0,"Strength");
+ for($i=0;$i<=720;$i=$i+20) { $MyData->addPoints(cos(deg2rad($i))*100,"Probe 1"); }
+
+ /* Create the pChart object */
+ $myPicture = new pImage(847,304,$MyData);
+ $myPicture->drawGradientArea(0,0,847,304,DIRECTION_VERTICAL,array("StartR"=>47,"StartG"=>47,"StartB"=>47,"EndR"=>17,"EndG"=>17,"EndB"=>17,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,250,847,304,DIRECTION_VERTICAL,array("StartR"=>47,"StartG"=>47,"StartB"=>47,"EndR"=>27,"EndG"=>27,"EndB"=>27,"Alpha"=>100));
+ $myPicture->drawLine(0,249,847,249,array("R"=>0,"G"=>0,"B"=>0));
+ $myPicture->drawLine(0,250,847,250,array("R"=>70,"G"=>70,"B"=>70));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,846,303,array("R"=>204,"G"=>204,"B"=>204));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawText(423,14,"Cyclic magnetic field strength",array("R"=>255,"G"=>255,"B"=>255,"Align"=>TEXT_ALIGN_MIDDLEMIDDLE));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(58,27,816,228);
+
+ /* Draw a rectangle */
+ $myPicture->drawFilledRectangle(58,27,816,228,array("R"=>0,"G"=>0,"B"=>0,"Dash"=>TRUE,"DashR"=>0,"DashG"=>51,"DashB"=>51,"BorderR"=>0,"BorderG"=>0,"BorderB"=>0));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw the scale */
+ $myPicture->setFontProperties(array("R"=>255,"G"=>255,"B"=>255));
+ $ScaleSettings = array("XMargin"=>4,"DrawSubTicks"=>TRUE,"GridR"=>255,"GridG"=>255,"GridB"=>255,"AxisR"=>255,"AxisG"=>255,"AxisB"=>255,"GridAlpha"=>30,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($ScaleSettings);
+
+ /* Define the visual thresholds */
+ $Threshold = "";
+ $Threshold[] = array("Min"=>-100,"Max"=>-35,"R"=>117,"G"=>140,"B"=>240,"Alpha"=>40);
+ $Threshold[] = array("Min"=>-35,"Max"=>35,"R"=>240,"G"=>232,"B"=>20,"Alpha"=>60);
+ $Threshold[] = array("Min"=>35,"Max"=>100,"R"=>240,"G"=>121,"B"=>20,"Alpha"=>80);
+
+ /* Draw the spline chart */
+ $myPicture->drawFilledSplineChart(array("Threshold"=>$Threshold));
+
+ /* Write the chart boundaries */
+ $BoundsSettings = array("MaxDisplayR"=>237,"MaxDisplayG"=>23,"MaxDisplayB"=>48,"MinDisplayR"=>23,"MinDisplayG"=>144,"MinDisplayB"=>237);
+ $myPicture->writeBounds(BOUND_BOTH,$BoundsSettings);
+
+ /* Write the 0 line */
+ $myPicture->drawThreshold(0,array("WriteCaption"=>TRUE));
+
+ /* Write the chart legend */
+ $myPicture->setFontProperties(array("R"=>255,"G"=>255,"B"=>255));
+ $myPicture->drawLegend(560,266,array("Style"=>LEGEND_NOBORDER));
+
+ /* Write the 1st data series statistics */
+ $Settings = array("R"=>188,"G"=>224,"B"=>46,"Align"=>TEXT_ALIGN_BOTTOMLEFT);
+ $myPicture->drawText(620,270,"Max : ".ceil($MyData->getMax("Probe 1")),$Settings);
+ $myPicture->drawText(680,270,"Min : ".ceil($MyData->getMin("Probe 1")),$Settings);
+ $myPicture->drawText(740,270,"Avg : ".ceil($MyData->getSerieAverage("Probe 1")),$Settings);
+
+ /* Write the 2nd data series statistics */
+ $Settings = array("R"=>224,"G"=>100,"B"=>46,"Align"=>TEXT_ALIGN_BOTTOMLEFT);
+ $myPicture->drawText(620,283,"Max : ".ceil($MyData->getMax("Probe 2")),$Settings);
+ $myPicture->drawText(680,283,"Min : ".ceil($MyData->getMin("Probe 2")),$Settings);
+ $myPicture->drawText(740,283,"Avg : ".ceil($MyData->getSerieAverage("Probe 2")),$Settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawFilledSplineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawFilledStepChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawFilledStepChart.php
new file mode 100644
index 0000000..b07fa1b
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawFilledStepChart.php
@@ -0,0 +1,65 @@
+<?php
+ /* CAT:Step chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,2,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawFilledStepChart() - draw a filled step chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawFilledStepChart(array("ForceTransparency"=>40,"DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO));
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the scale and the 2nd chart */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>-1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawFilledStepChart(array("ForceTransparency"=>40));
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(510,205,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawFilledStepChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawFromGIF.php b/notFinishedCode/pChart2.1.2/examples/example.drawFromGIF.php
new file mode 100644
index 0000000..289ac9e
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawFromGIF.php
@@ -0,0 +1,47 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawFromGIF() - add pictures to your charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Turn off shadow computing */
+ $myPicture->setShadow(FALSE);
+
+ /* Draw a GIF object */
+ $myPicture->drawFromGIF(180,50,"resources/computer.gif");
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a GIF object */
+ $myPicture->drawFromGIF(400,50,"resources/computer.gif");
+
+ /* Write the legend */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+ $TextSettings = array("R"=>255,"G"=>255,"B"=>255,"FontSize"=>10,"FontName"=>"../fonts/calibri.ttf","Align"=>TEXT_ALIGN_BOTTOMMIDDLE);
+ $myPicture->drawText(240,200,"Without shadow",$TextSettings);
+ $myPicture->drawText(460,200,"With enhanced shadow",$TextSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawFromGIF.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawFromJPG.php b/notFinishedCode/pChart2.1.2/examples/example.drawFromJPG.php
new file mode 100644
index 0000000..5cef941
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawFromJPG.php
@@ -0,0 +1,47 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawFromJPG() - add pictures to your charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Turn off shadow computing */
+ $myPicture->setShadow(FALSE);
+
+ /* Draw a JPG object */
+ $myPicture->drawFromJPG(100,45,"resources/landscape1.jpg");
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a JPG object */
+ $myPicture->drawFromJPG(380,45,"resources/landscape2.jpg");
+
+ /* Write the legend */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+ $TextSettings = array("R"=>255,"G"=>255,"B"=>255,"FontSize"=>10,"FontName"=>"../fonts/calibri.ttf","Align"=>TEXT_ALIGN_BOTTOMMIDDLE);
+ $myPicture->drawText(220,210,"Without shadow",$TextSettings);
+ $myPicture->drawText(490,210,"With enhanced shadow",$TextSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawFromJPG.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawFromPNG.php b/notFinishedCode/pChart2.1.2/examples/example.drawFromPNG.php
new file mode 100644
index 0000000..eb59df3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawFromPNG.php
@@ -0,0 +1,47 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawFromPNG() - add pictures to your charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Turn off shadow computing */
+ $myPicture->setShadow(FALSE);
+
+ /* Draw a PNG object */
+ $myPicture->drawFromPNG(180,50,"resources/hologram.png");
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a PNG object */
+ $myPicture->drawFromPNG(400,50,"resources/blocnote.png");
+
+ /* Write the legend */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+ $TextSettings = array("R"=>255,"G"=>255,"B"=>255,"FontSize"=>10,"FontName"=>"../fonts/calibri.ttf","Align"=>TEXT_ALIGN_BOTTOMMIDDLE);
+ $myPicture->drawText(240,190," Without shadow\r\n(only PNG alpha channels)",$TextSettings);
+ $myPicture->drawText(460,200,"With enhanced shadow",$TextSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawFromPNG.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawGeometricMean.php b/notFinishedCode/pChart2.1.2/examples/example.drawGeometricMean.php
new file mode 100644
index 0000000..b97d9f7
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawGeometricMean.php
@@ -0,0 +1,59 @@
+<?php
+ /* CAT:Mathematical */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ for($i=0;$i<=20;$i++) { $MyData->addPoints(rand(10,30)+$i,"Probe 1"); }
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->setAbscissaName("Samples");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,680,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Turn on shadows */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the line chart */
+ $myPicture->drawPlotChart();
+
+ /* Draw the standard mean and the geometric one */
+ $Mean = $MyData->getSerieAverage("Probe 1");
+ $GeometricMean = $MyData->getGeometricMean("Probe 1");
+ $myPicture->drawThreshold($GeometricMean,array("WriteCaption"=>TRUE,"Caption"=>"Geometric mean"));
+ $myPicture->drawThreshold($Mean,array("WriteCaption"=>TRUE,"Caption"=>"Mean","CaptionAlign"=>CAPTION_RIGHT_BOTTOM));
+
+ /* Write the computed values */
+ $myPicture->drawText(550,20,"Arithmetic average : ".round($Mean,2));
+ $myPicture->drawText(550,30,"Geometric Mean : ".round($GeometricMean,2));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.geometricMean.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawGradientArea.php b/notFinishedCode/pChart2.1.2/examples/example.drawGradientArea.php
new file mode 100644
index 0000000..d0c31ae
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawGradientArea.php
@@ -0,0 +1,53 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawGradientArea() - Transparency & colors",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Draw a gradient area */
+ $GradientSettings = array("StartR"=>181,"StartG"=>209,"StartB"=>27,"Alpha"=>100,"Levels"=>-50);
+ $myPicture->drawGradientArea(20,60,400,170,DIRECTION_HORIZONTAL,$GradientSettings);
+
+ /* Draw a gradient area */
+ $GradientSettings = array("StartR"=>209,"StartG"=>134,"StartB"=>27,"Alpha"=>30,"Levels"=>-50);
+ $myPicture->drawGradientArea(30,30,200,200,DIRECTION_VERTICAL,$GradientSettings);
+
+ /* Draw a gradient area */
+ $GradientSettings = array("StartR"=>209,"StartG"=>31,"StartB"=>27,"Alpha"=>100,"Levels"=>50);
+ $myPicture->drawGradientArea(480,50,650,80,DIRECTION_HORIZONTAL,$GradientSettings);
+
+ /* Draw a gradient area */
+ $GradientSettings = array("StartR"=>209,"StartG"=>125,"StartB"=>27,"Alpha"=>100,"Levels"=>50);
+ $myPicture->drawGradientArea(480,90,650,120,DIRECTION_VERTICAL,$GradientSettings);
+
+ /* Draw a gradient area */
+ $GradientSettings = array("StartR"=>209,"StartG"=>198,"StartB"=>27,"Alpha"=>100,"Levels"=>50);
+ $myPicture->drawGradientArea(480,130,650,160,DIRECTION_HORIZONTAL,$GradientSettings);
+
+ /* Draw a gradient area */
+ $GradientSettings = array("StartR"=>134,"StartG"=>209,"StartB"=>27,"Alpha"=>100,"Levels"=>50);
+ $myPicture->drawGradientArea(480,170,650,200,DIRECTION_HORIZONTAL,$GradientSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawGradientArea.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawHarmonicMean.php b/notFinishedCode/pChart2.1.2/examples/example.drawHarmonicMean.php
new file mode 100644
index 0000000..0c33d7f
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawHarmonicMean.php
@@ -0,0 +1,59 @@
+<?php
+ /* CAT:Mathematical */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ for($i=0;$i<=20;$i++) { $MyData->addPoints(rand(10,30)+$i,"Probe 1"); }
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->setAbscissaName("Samples");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,680,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Turn on shadows */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the line chart */
+ $myPicture->drawPlotChart();
+
+ /* Draw the standard mean and the harmonic one */
+ $Mean = $MyData->getSerieAverage("Probe 1");
+ $HarmonicMean = $MyData->getHarmonicMean("Probe 1");
+ $myPicture->drawThreshold($HarmonicMean,array("WriteCaption"=>TRUE,"Caption"=>"Harmonic mean"));
+ $myPicture->drawThreshold($Mean,array("WriteCaption"=>TRUE,"Caption"=>"Mean","CaptionAlign"=>CAPTION_RIGHT_BOTTOM));
+
+ /* Write the computed values */
+ $myPicture->drawText(550,20,"Arithmetic average : ".round($Mean,2));
+ $myPicture->drawText(550,30,"Harmonic Mean : ".round($HarmonicMean,2));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.harmonicMean.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawIndicator.php b/notFinishedCode/pChart2.1.2/examples/example.drawIndicator.php
new file mode 100644
index 0000000..5f28bba
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawIndicator.php
@@ -0,0 +1,66 @@
+<?php
+ /* CAT:Labels */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pIndicator.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(4,12,15,8,5,-5),"Probe 1");
+ $MyData->addPoints(array(7,2,4,14,8,3),"Probe 2");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->setAxisUnit(0,"°C");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawIndicator() - Create nice looking indicators",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Create the pIndicator object */
+ $Indicator = new pIndicator($myPicture);
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the indicator sections */
+ $IndicatorSections = "";
+ $IndicatorSections[] = array("Start"=>0,"End"=>199,"Caption"=>"Low","R"=>0,"G"=>142,"B"=>176);
+ $IndicatorSections[] = array("Start"=>200,"End"=>239,"Caption"=>"Moderate","R"=>108,"G"=>157,"B"=>49);
+ $IndicatorSections[] = array("Start"=>240,"End"=>300,"Caption"=>"High","R"=>157,"G"=>140,"B"=>49);
+
+ /* Draw the 1st indicator */
+ $IndicatorSettings = array("Values"=>array(20,230),"ValueFontName"=>"../fonts/Forgotte.ttf","ValueFontSize"=>15,"IndicatorSections"=>$IndicatorSections,"SubCaptionColorFactor"=>-40);
+ $Indicator->draw(80,50,550,50,$IndicatorSettings);
+
+ /* Define the indicator sections */
+ $IndicatorSections = "";
+ $IndicatorSections[] = array("Start"=>0,"End"=>99,"Caption"=>"Low","R"=>135,"G"=>49,"B"=>15);
+ $IndicatorSections[] = array("Start"=>100,"End"=>119,"Caption"=>"Borderline","R"=>183,"G"=>62,"B"=>15);
+ $IndicatorSections[] = array("Start"=>120,"End"=>220,"Caption"=>"High","R"=>226,"G"=>74,"B"=>14);
+
+ /* Draw the 2nd indicator */
+ $IndicatorSettings = array("Values"=>array(100,201),"CaptionPosition"=>INDICATOR_CAPTION_BOTTOM,"CaptionR"=>0,"CaptionG"=>0,"CaptionB"=>0,"DrawLeftHead"=>FALSE,"ValueDisplay"=>INDICATOR_VALUE_LABEL,"ValueFontName"=>"../fonts/Forgotte.ttf","ValueFontSize"=>15,"IndicatorSections"=>$IndicatorSections);
+ $Indicator->draw(80,160,550,30,$IndicatorSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawIndicator.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawLabel.barchart.php b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.barchart.php
new file mode 100644
index 0000000..7e772da
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.barchart.php
@@ -0,0 +1,71 @@
+<?php
+ /* CAT:Labels */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->loadPalette("../palettes/autumn.color",TRUE);
+ $MyData->addPoints(array(4,12,15,8,5,-5),"Probe 1");
+ $MyData->addPoints(array(7,2,4,14,8,3),"Probe 2");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->setAxisUnit(0,"°C");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawLabel() - Write labels over your charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(155,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,670,190);
+ $myPicture->drawFilledRectangle(60,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawBarChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(600,210,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write a label over the chart */
+ $myPicture->writeLabel("Probe 1",0);
+
+ /* Write a label over the chart */
+ $LabelSettings = array("TitleMode"=>LABEL_TITLE_BACKGROUND,"DrawSerieColor"=>FALSE,"TitleR"=>255,"TitleG"=>255,"TitleB"=>255);
+ $myPicture->writeLabel("Probe 1",5,$LabelSettings);
+
+ /* Write a label over the chart */
+ $LabelSettings = array("OverrideTitle"=>"Multiple series","DrawVerticalLine"=>TRUE,"TitleMode"=>LABEL_TITLE_BACKGROUND,"TitleR"=>255,"TitleG"=>255,"TitleB"=>255);
+ $myPicture->writeLabel(array("Probe 1","Probe 2"),4,$LabelSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawLabel.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawLabel.bubble.php b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.bubble.php
new file mode 100644
index 0000000..c708c4e
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.bubble.php
@@ -0,0 +1,87 @@
+<?php
+ /* CAT:Labels */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pBubble.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->loadPalette("../palettes/blind.color",TRUE);
+ $MyData->addPoints(array(34,55,15,62,38,42),"Probe1");
+ $MyData->addPoints(array(5,10,8,9,15,10),"Probe1Weight");
+ $MyData->addPoints(array(5,10,-5,-1,0,-10),"Probe2");
+ $MyData->addPoints(array(6,10,14,10,14,6),"Probe2Weight");
+ $MyData->setSerieDescription("Probe1","This year");
+ $MyData->setSerieDescription("Probe2","Last year");
+ $MyData->setAxisName(0,"Current stock");
+ $MyData->addPoints(array("Apple","Banana","Orange","Lemon","Peach","Strawberry"),"Product");
+ $MyData->setAbscissa("Product");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawBubbleChart() - draw a linear bubble chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(40,55,"Current Stock / Needs chart",array("FontSize"=>14,"Align"=>TEXT_ALIGN_BOTTOMLEFT));
+
+ /* Change the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Create the Bubble chart object and scale up */
+ $myBubbleChart = new pBubble($myPicture,$MyData);
+
+ /* Scale up for the bubble chart */
+ $bubbleDataSeries = array("Probe1","Probe2");
+ $bubbleWeightSeries = array("Probe1Weight","Probe2Weight");
+ $myBubbleChart->bubbleScale($bubbleDataSeries,$bubbleWeightSeries);
+
+ /* Draw the 1st chart */
+ $myPicture->setGraphArea(40,60,430,190);
+ $myPicture->drawFilledRectangle(40,60,430,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-50,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>30));
+ $myBubbleChart->drawBubbleChart($bubbleDataSeries,$bubbleWeightSeries);
+
+ /* Write a label over the chart */
+ $LabelSettings = array("TitleMode"=>LABEL_TITLE_BACKGROUND,"VerticalMargin"=>4,"HorizontalMargin"=>6,"DrawSerieColor"=>FALSE,"TitleR"=>255,"TitleG"=>255,"TitleB"=>255);
+ $myBubbleChart->writeBubbleLabel("Probe1","Probe1Weight",3,$LabelSettings);
+ $myBubbleChart->writeBubbleLabel("Probe2","Probe2Weight",4,$LabelSettings);
+
+ /* Draw the 2nd scale */
+ $myPicture->setShadow(FALSE);
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+
+ /* Draw the 2nd bubble chart */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>30));
+ $myBubbleChart->drawbubbleChart($bubbleDataSeries,$bubbleWeightSeries,array("DrawBorder"=>TRUE,"Surrounding"=>60,"BorderAlpha"=>100));
+
+ /* Write a label over the chart */
+ $myBubbleChart->writeBubbleLabel("Probe1","Probe1Weight",4,$LabelSettings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(550,215,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawLabel.bubble.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawLabel.caption.php b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.caption.php
new file mode 100644
index 0000000..af2c672
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.caption.php
@@ -0,0 +1,67 @@
+<?php
+ /* CAT:Labels */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(4,12,15,8,5,-5),"Probe 1");
+ $MyData->addPoints(array(7,2,4,14,8,3),"Probe 2");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->setAxisUnit(0,"°C");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawLabel() - Write labels over your charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(155,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,670,190);
+ $myPicture->drawFilledRectangle(60,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawSplineChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(600,210,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Write a label over the chart */
+ $LabelSettings = array("TitleR"=>255,"TitleG"=>255,"TitleB"=>255,"DrawSerieColor"=>FALSE,"TitleMode"=>LABEL_TITLE_BACKGROUND,"OverrideTitle"=>"Information","ForceLabels"=>array("Issue with the recording device","New recording device"),"GradientEndR"=>220,"GradientEndG"=>255,"GradientEndB"=>220,"TitleBackgroundG"=>155);
+ $myPicture->writeLabel(array("Probe 2"),array(1,3),$LabelSettings);
+
+ /* Write a label over the chart */
+ $LabelSettings = array("NoTitle"=>TRUE,"GradientEndR"=>255,"GradientEndG"=>200,"GradientEndB"=>200);
+ $myPicture->writeLabel(array("Probe 1"),5,$LabelSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawLabel.caption.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawLabel.php b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.php
new file mode 100644
index 0000000..8ebf364
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.php
@@ -0,0 +1,70 @@
+<?php
+ /* CAT:Labels */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(4,12,15,8,5,-5),"Probe 1");
+ $MyData->addPoints(array(7,2,4,14,8,3),"Probe 2");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->setAxisUnit(0,"°C");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawLabel() - Write labels over your charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(155,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,670,190);
+ $myPicture->drawFilledRectangle(60,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawSplineChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(600,210,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write a label over the chart */
+ $myPicture->writeLabel("Probe 1",0);
+
+ /* Write a label over the chart */
+ $LabelSettings = array("TitleMode"=>LABEL_TITLE_BACKGROUND,"DrawSerieColor"=>FALSE,"TitleR"=>255,"TitleG"=>255,"TitleB"=>255);
+ $myPicture->writeLabel("Probe 1",5,$LabelSettings);
+
+ /* Write a label over the chart */
+ $LabelSettings = array("OverrideTitle"=>"Multiple series","DrawVerticalLine"=>TRUE,"TitleMode"=>LABEL_TITLE_BACKGROUND,"TitleR"=>255,"TitleG"=>255,"TitleB"=>255);
+ $myPicture->writeLabel(array("Probe 1","Probe 2"),4,$LabelSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawLabel.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawLabel.scatter.php b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.scatter.php
new file mode 100644
index 0000000..02068a4
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.scatter.php
@@ -0,0 +1,87 @@
+<?php
+ /* CAT:Labels */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(cos(deg2rad($i))*20,"Probe 1"); }
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(sin(deg2rad($i))*20,"Probe 2"); }
+ $myData->setAxisName(0,"Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints($i,"Probe 3"); }
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Degree");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisUnit(1,"°");
+ $myData->setAxisPosition(1,AXIS_POSITION_RIGHT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 3",0);
+ $myData->setScatterSerieDescription(0,"This year");
+ $myData->setScatterSerieTicks(0,4);
+ $myData->setScatterSerieColor(0,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Create the 2nd scatter chart binding */
+ $myData->setScatterSerie("Probe 2","Probe 3",1);
+ $myData->setScatterSerieDescription(1,"Last Year");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScatterLineChart() - Draw a scatter line chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,50,350,350);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $myScatter->drawScatterScale();
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw a scatter plot chart */
+ $myScatter->drawScatterLineChart();
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(280,380,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write a label over the chart */
+ $LabelSettings = array("Decimals"=>1,"TitleMode"=>LABEL_TITLE_BACKGROUND,"TitleR"=>255,"TitleG"=>255,"TitleB"=>255);
+ $myScatter->writeScatterLabel(1,17,$LabelSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawLabel.scatter.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawLabel.vertical.php b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.vertical.php
new file mode 100644
index 0000000..5dd7a0c
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawLabel.vertical.php
@@ -0,0 +1,51 @@
+<?php
+ /* CAT:Labels */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(13251,4118,3087,1460,1248,156,26,9,8),"Hits");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("Firefox","Chrome","Internet Explorer","Opera","Safari","Mozilla","SeaMonkey","Camino","Lunascape"),"Browsers");
+ $MyData->setSerieDescription("Browsers","Browsers");
+ $MyData->setAbscissa("Browsers");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(500,500,$MyData);
+ $myPicture->drawGradientArea(0,0,500,500,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,500,500,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the chart scale */
+ $myPicture->setGraphArea(100,30,480,480);
+ $myPicture->drawScale(array("CycleBackground"=>TRUE,"DrawSubTicks"=>TRUE,"GridR"=>0,"GridG"=>0,"GridB"=>0,"GridAlpha"=>10,"Pos"=>SCALE_POS_TOPBOTTOM));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the per bar palette */
+ $Palette = array("0"=>array("R"=>188,"G"=>224,"B"=>46,"Alpha"=>100),
+ "1"=>array("R"=>224,"G"=>100,"B"=>46,"Alpha"=>100),
+ "2"=>array("R"=>224,"G"=>214,"B"=>46,"Alpha"=>100),
+ "3"=>array("R"=>46,"G"=>151,"B"=>224,"Alpha"=>100),
+ "4"=>array("R"=>176,"G"=>46,"B"=>224,"Alpha"=>100),
+ "5"=>array("R"=>224,"G"=>46,"B"=>117,"Alpha"=>100),
+ "6"=>array("R"=>92,"G"=>224,"B"=>46,"Alpha"=>100),
+ "7"=>array("R"=>224,"G"=>176,"B"=>46,"Alpha"=>100));
+
+ /* Draw the chart */
+ $myPicture->drawBarChart(array("DisplayPos"=>LABEL_POS_INSIDE,"DisplayValues"=>TRUE,"Rounded"=>TRUE,"Surrounding"=>30,"OverrideColors"=>$Palette));
+
+ /* Write the legend */
+ $myPicture->drawLegend(570,215,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Write a label over the chart */
+ $myPicture->writeLabel("Hits",array(1,4));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawBarChart.vertical.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawLegend.php b/notFinishedCode/pChart2.1.2/examples/example.drawLegend.php
new file mode 100644
index 0000000..7ea3d61
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawLegend.php
@@ -0,0 +1,76 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(24,25,26,25,25),"My Serie 1");
+ $MyData->addPoints(array(80,85,84,81,82),"My Serie 2");
+ $MyData->addPoints(array(17,16,18,18,15),"My Serie 3");
+ $MyData->setSerieTicks("My Serie 1",4);
+ $MyData->setSerieWeight("My Serie 2",2);
+ $MyData->setSerieDescription("My Serie 1","Temperature");
+ $MyData->setSerieDescription("My Serie 2","Humidity\n(in percentage)");
+ $MyData->setSerieDescription("My Serie 3","Pressure");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Draw the picture border */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawLegend() - Write your chart legend",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write a legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawLegend(70,60);
+
+ /* Write a legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/MankSans.ttf","FontSize"=>10,"R"=>30,"G"=>30,"B"=>30));
+ $myPicture->drawLegend(230,60,array("BoxSize"=>4,"R"=>173,"G"=>163,"B"=>83,"Surrounding"=>20,"Family"=>LEGEND_FAMILY_CIRCLE));
+
+ /* Write a legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>9,"R"=>80,"G"=>80,"B"=>80));
+ $myPicture->drawLegend(400,60,array("Style"=>LEGEND_BOX,"BoxSize"=>4,"R"=>200,"G"=>200,"B"=>200,"Surrounding"=>20,"Alpha"=>30));
+
+ /* Write a legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawLegend(70,150,array("Mode"=>LEGEND_HORIZONTAL, "Family"=>LEGEND_FAMILY_CIRCLE));
+
+ /* Write a legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawLegend(400,150,array("Style"=>LEGEND_BOX,"Mode"=>LEGEND_HORIZONTAL, "BoxWidth"=>30,"Family"=>LEGEND_FAMILY_LINE));
+
+ /* Write a legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawFilledRectangle(1,200,698,228,array("Alpha"=>30,"R"=>255,"G"=>255,"B"=>255));
+ $myPicture->drawLegend(10,208,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Define series icons */
+ $MyData->setSeriePicture("My Serie 1","resources/application_view_list.png");
+ $MyData->setSeriePicture("My Serie 2","resources/application_view_tile.png");
+ $MyData->setSeriePicture("My Serie 3","resources/chart_bar.png");
+
+ /* Write a legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawLegend(540,50,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_VERTICAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawLegend.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawLine.php b/notFinishedCode/pChart2.1.2/examples/example.drawLine.php
new file mode 100644
index 0000000..f1b26d3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawLine.php
@@ -0,0 +1,42 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Draw the picture border */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawLine() - Basis",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw some lines */
+ for($i=1;$i<=100;$i=$i+4)
+ $myPicture->drawLine($i+5,215,$i*7+5,30,array("R"=>rand(0,255),"G"=>rand(0,255),"B"=>rand(0,255),"Ticks"=>rand(0,4)));
+
+ /* Draw an horizontal dashed line with extra weight */
+ $myPicture->drawLine(370,160,650,160,array("R"=>0,"G"=>0,"B"=>0,"Ticks"=>4,"Weight"=>3));
+
+ /* Another example of extra weight */
+ $myPicture->drawLine(370,180,650,200,array("R"=>255,"G"=>255,"B"=>255,"Ticks"=>15,"Weight"=>1));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawLine.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawLineChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawLineChart.php
new file mode 100644
index 0000000..1b3bcc2
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawLineChart.php
@@ -0,0 +1,66 @@
+<?php
+ /* CAT:Line chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setSerieWeight("Probe 3",2);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawPlotChart() - draw a plot chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawLineChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO));
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the scale and the 2nd chart */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>-1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawLineChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(510,205,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawLineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawLineChart.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawLineChart.simple.php
new file mode 100644
index 0000000..f8fb2f4
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawLineChart.simple.php
@@ -0,0 +1,56 @@
+<?php
+ /* CAT:Line chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setSerieWeight("Probe 3",2);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw the line chart */
+ $myPicture->drawLineChart();
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(540,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawLineChart.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawMedian.php b/notFinishedCode/pChart2.1.2/examples/example.drawMedian.php
new file mode 100644
index 0000000..68d5632
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawMedian.php
@@ -0,0 +1,55 @@
+<?php
+ /* CAT:Mathematical */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ for($i=0;$i<=20;$i++) { $MyData->addPoints(rand(10,30)+$i,"Probe 1"); }
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->setAbscissaName("Samples");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw the line of best fit */
+ $myPicture->drawThreshold($MyData->getSerieMedian("Probe 1"),array("WriteCaption"=>TRUE,"Caption"=>"Median value"));
+
+ /* Turn on shadows */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the line chart */
+ $myPicture->drawPlotChart();
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.median.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawPieLegend.php b/notFinishedCode/pChart2.1.2/examples/example.drawPieLegend.php
new file mode 100644
index 0000000..062b1f1
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawPieLegend.php
@@ -0,0 +1,67 @@
+<?php
+ /* CAT:Pie charts */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pPie.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(40,60,15,10,6,4),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("<10","10<>20","20<>40","40<>60","60<>80",">80"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawPieLegend - Draw pie charts legend",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>150,"G"=>150,"B"=>150,"Alpha"=>100));
+
+ /* Create the pPie object */
+ $PieChart = new pPie($myPicture,$MyData);
+
+ /* Draw two AA pie chart */
+ $PieChart->draw2DPie(200,100,array("Border"=>TRUE));
+ $PieChart->draw2DPie(440,115,array("Border"=>TRUE));
+
+ /* Write down the legend next to the 2nd chart*/
+ $PieChart->drawPieLegend(550,70);
+
+ /* Write a legend box under the 1st chart */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $PieChart->drawPieLegend(90,176,array("Style"=>LEGEND_BOX,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Write the bottom legend box */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawGradientArea(1,200,698,228,DIRECTION_VERTICAL,array("StartR"=>247,"StartG"=>247,"StartB"=>247,"EndR"=>217,"EndG"=>217,"EndB"=>217,"Alpha"=>20));
+ $myPicture->drawLine(1,199,698,199,array("R"=>100,"G"=>100,"B"=>100,"Alpha"=>20));
+ $myPicture->drawLine(1,200,698,200,array("R"=>255,"G"=>255,"B"=>255,"Alpha"=>20));
+ $PieChart->drawPieLegend(10,210,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawPieLegend.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.icon.php b/notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.icon.php
new file mode 100644
index 0000000..d79a8a5
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.icon.php
@@ -0,0 +1,69 @@
+<?php
+ /* CAT:Plot chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(3,4,7,4,2,5),"User");
+ $MyData->addPoints(array(12,17,15,18,19,22),"Group");
+ $MyData->setSeriePicture("User","resources/serie1.png");
+ $MyData->setSeriePicture("Group","resources/serie2.png");
+ $MyData->setSerieWeight("Group",1);
+ $MyData->setSerieTicks("Group",4);
+
+ $MyData->setAxisName(0,"Hours");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawPlotChart() - draw a plot chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"Average time spent on projects",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawSplineChart();
+ $myPicture->drawPlotChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO));
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the scale and the 2nd chart */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawPlotChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(590,205,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawPlotChart.icon.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.php
new file mode 100644
index 0000000..cbc94bb
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.php
@@ -0,0 +1,64 @@
+<?php
+ /* CAT:Plot chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,4,2,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawPlotChart() - draw a plot chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawPlotChart(array("BorderSize"=>1,"Surrounding"=>40,"BorderAlpha"=>100,"PlotSize"=>2,"PlotBorder"=>TRUE,"DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO));
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the scale and the 2nd chart */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawPlotChart(array("PlotSize"=>1,"PlotBorder"=>TRUE,"BorderSize"=>1));
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(510,205,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawPlotChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.simple.php
new file mode 100644
index 0000000..82c3901
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawPlotChart.simple.php
@@ -0,0 +1,52 @@
+<?php
+ /* CAT:Plot chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ for($i=0;$i<=20;$i++) { $MyData->addPoints(rand(0,20),"Probe 1"); }
+ for($i=0;$i<=20;$i++) { $MyData->addPoints(rand(0,20),"Probe 2"); }
+ $MyData->setSerieShape("Probe 1",SERIE_SHAPE_FILLEDTRIANGLE);
+ $MyData->setSerieShape("Probe 2",SERIE_SHAPE_FILLEDSQUARE);
+ $MyData->setAxisName(0,"Temperatures");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the line chart */
+ $myPicture->drawPlotChart();
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawPlotChart.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawPolygon.php b/notFinishedCode/pChart2.1.2/examples/example.drawPolygon.php
new file mode 100644
index 0000000..1becd9c
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawPolygon.php
@@ -0,0 +1,55 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawPolygon - Draw polygons",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create some filling thresholds */
+ $Threshold = "";
+ $Threshold[] = array("MinX"=>100,"MaxX"=>60,"R"=>200,"G"=>200,"B"=>200,"Alpha"=>50);
+ $Threshold[] = array("MinX"=>140,"MaxX"=>100,"R"=>220,"G"=>220,"B"=>220,"Alpha"=>50);
+ $Threshold[] = array("MinX"=>180,"MaxX"=>140,"R"=>240,"G"=>240,"B"=>240,"Alpha"=>50);
+
+ /* Draw some polygons */
+ $Step = 8;
+ $White = array("Threshold"=>$Threshold,"R"=>255,"G"=>255,"B"=>255,"Alpha"=>100,"BorderR"=>0,"BorderG"=>0,"BorderB"=>0,"BorderAlpha"=>100);
+
+ for($i=1;$i<=4;$i++)
+ {
+ $Points = "";
+ for($j=0;$j<=360;$j=$j+(360/$Step))
+ {
+ $Points[] = cos(deg2rad($j))*50+($i*140);
+ $Points[] = sin(deg2rad($j))*50+120;
+ }
+ $myPicture->drawPolygon($Points,$White);
+ $Step = $Step * 2;
+ }
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawPolygon.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawProgress.php b/notFinishedCode/pChart2.1.2/examples/example.drawProgress.php
new file mode 100644
index 0000000..1f51814
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawProgress.php
@@ -0,0 +1,65 @@
+<?php
+ /* CAT:Progress bars */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0, "G"=>0, "B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf", "FontSize"=>6));
+ $myPicture->drawText(10,13, "drawProgress() - Simple progress bars",array("R"=>255, "G"=>255, "B"=>255));
+
+ /* Set the font & shadow options */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf", "FontSize"=>10));
+ $myPicture->setShadow(TRUE,array("X"=>1, "Y"=>1, "R"=>0, "G"=>0, "B"=>0, "Alpha"=>20));
+
+ /* Draw a progress bar */
+ $progressOptions = array("R"=>209, "G"=>31, "B"=>27, "Surrounding"=>20, "BoxBorderR"=>0, "BoxBorderG"=>0, "BoxBorderB"=>0, "BoxBackR"=>255, "BoxBackG"=>255, "BoxBackB"=>255, "RFade"=>206, "GFade"=>133, "BFade"=>30, "ShowLabel"=>TRUE);
+ $myPicture->drawProgress(40,60,77,$progressOptions);
+
+ /* Draw a progress bar */
+ $progressOptions = array("Width"=>165, "R"=>209, "G"=>125, "B"=>27, "Surrounding"=>20, "BoxBorderR"=>0, "BoxBorderG"=>0, "BoxBorderB"=>0, "BoxBackR"=>255, "BoxBackG"=>255, "BoxBackB"=>255,"NoAngle"=>TRUE, "ShowLabel"=>TRUE, "LabelPos"=>LABEL_POS_RIGHT);
+ $myPicture->drawProgress(40,100,50,$progressOptions);
+
+ /* Draw a progress bar */
+ $progressOptions = array("Width"=>165, "R"=>209, "G"=>198, "B"=>27, "Surrounding"=>20, "BoxBorderR"=>0, "BoxBorderG"=>0, "BoxBorderB"=>0, "BoxBackR"=>255, "BoxBackG"=>255, "BoxBackB"=>255, "ShowLabel"=>TRUE, "LabelPos"=>LABEL_POS_LEFT);
+ $myPicture->drawProgress(75,140,25,$progressOptions);
+
+ /* Draw a progress bar */
+ $progressOptions = array("Width"=>400, "R"=>134, "G"=>209, "B"=>27, "Surrounding"=>20, "BoxBorderR"=>0, "BoxBorderG"=>0, "BoxBorderB"=>0, "BoxBackR"=>255, "BoxBackG"=>255, "BoxBackB"=>255, "RFade"=>206, "GFade"=>133, "BFade"=>30, "ShowLabel"=>TRUE, "LabelPos"=>LABEL_POS_CENTER);
+ $myPicture->drawProgress(40,180,80,$progressOptions);
+
+ /* Draw a progress bar */
+ $progressOptions = array("Width"=>20, "Height"=>150, "R"=>209, "G"=>31, "B"=>27, "Surrounding"=>20, "BoxBorderR"=>0, "BoxBorderG"=>0, "BoxBorderB"=>0, "BoxBackR"=>255, "BoxBackG"=>255, "BoxBackB"=>255, "RFade"=>206, "GFade"=>133, "BFade"=>30, "ShowLabel"=>TRUE, "Orientation"=>ORIENTATION_VERTICAL, "LabelPos"=>LABEL_POS_BOTTOM);
+ $myPicture->drawProgress(500,200,77,$progressOptions);
+
+ /* Draw a progress bar */
+ $progressOptions = array("Width"=>20, "Height"=>150, "R"=>209, "G"=>125, "B"=>27, "Surrounding"=>20, "BoxBorderR"=>0, "BoxBorderG"=>0, "BoxBorderB"=>0, "BoxBackR"=>255, "BoxBackG"=>255, "BoxBackB"=>255,"NoAngle"=>TRUE, "ShowLabel"=>TRUE, "Orientation"=>ORIENTATION_VERTICAL, "LabelPos"=>LABEL_POS_TOP);
+ $myPicture->drawProgress(540,200,50,$progressOptions);
+
+ /* Draw a progress bar */
+ $progressOptions = array("Width"=>20, "Height"=>150, "R"=>209, "G"=>198, "B"=>27, "Surrounding"=>20, "BoxBorderR"=>0, "BoxBorderG"=>0, "BoxBorderB"=>0, "BoxBackR"=>255, "BoxBackG"=>255, "BoxBackB"=>255, "ShowLabel"=>TRUE, "Orientation"=>ORIENTATION_VERTICAL, "LabelPos"=>LABEL_POS_INSIDE);
+ $myPicture->drawProgress(580,200,25,$progressOptions);
+
+ /* Draw a progress bar */
+ $progressOptions = array("Width"=>20, "Height"=>150, "R"=>134, "G"=>209, "B"=>27, "Surrounding"=>20, "BoxBorderR"=>0, "BoxBorderG"=>0, "BoxBorderB"=>0, "BoxBackR"=>255, "BoxBackG"=>255, "BoxBackB"=>255, "RFade"=>206, "GFade"=>133, "BFade"=>30, "ShowLabel"=>TRUE, "Orientation"=>ORIENTATION_VERTICAL, "LabelPos"=>LABEL_POS_CENTER);
+ $myPicture->drawProgress(620,200,80,$progressOptions);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawProgress.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawRectangle.php b/notFinishedCode/pChart2.1.2/examples/example.drawRectangle.php
new file mode 100644
index 0000000..70fa2cd
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawRectangle.php
@@ -0,0 +1,56 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawRectangle() - Transparency & colors",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a rectangle */
+ $RectangleSettings = array("R"=>181,"G"=>209,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRectangle(20,60,400,170,$RectangleSettings);
+
+ /* Draw a rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>134,"B"=>27,"Alpha"=>30);
+ $myPicture->drawRectangle(30,30,200,200,$RectangleSettings);
+
+ /* Draw a rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>31,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRectangle(480,50,650,80,$RectangleSettings);
+
+ /* Draw a rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>125,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRectangle(480,90,650,120,$RectangleSettings);
+
+ /* Draw a rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>198,"B"=>27,"Alpha"=>100,"Ticks"=>2);
+ $myPicture->drawRectangle(480,130,650,160,$RectangleSettings);
+
+ /* Draw a rectangle */
+ $RectangleSettings = array("R"=>134,"G"=>209,"B"=>27,"Alpha"=>100,"Ticks"=>2);
+ $myPicture->drawRectangle(480,170,650,200,$RectangleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawRectangle.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawRoundedFilledRectangle.php b/notFinishedCode/pChart2.1.2/examples/example.drawRoundedFilledRectangle.php
new file mode 100644
index 0000000..7d78ad1
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawRoundedFilledRectangle.php
@@ -0,0 +1,62 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawRoundedFilledRectangle() - Transparency & colors",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>181,"G"=>209,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRoundedFilledRectangle(20,60,400,170,10,$RectangleSettings);
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(FALSE);
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>134,"B"=>27,"Alpha"=>30);
+ $myPicture->drawRoundedFilledRectangle(30,30,200,200,10,$RectangleSettings);
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>31,"B"=>27,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawRoundedFilledRectangle(480,50,650,80,5,$RectangleSettings);
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>125,"B"=>27,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawRoundedFilledRectangle(480,90,650,120,5,$RectangleSettings);
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>198,"B"=>27,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawRoundedFilledRectangle(480,130,650,160,5,$RectangleSettings);
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>134,"G"=>209,"B"=>27,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawRoundedFilledRectangle(480,170,650,200,5,$RectangleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawRoundedFilledRectangle.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawRoundedRectangle.php b/notFinishedCode/pChart2.1.2/examples/example.drawRoundedRectangle.php
new file mode 100644
index 0000000..dd04cdb
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawRoundedRectangle.php
@@ -0,0 +1,56 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawRoundedRectangle() - Transparency & colors",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a rounded rectangle */
+ $RectangleSettings = array("R"=>181,"G"=>209,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRoundedRectangle(20,60,400,170,10,$RectangleSettings);
+
+ /* Draw a rounded rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>134,"B"=>27,"Alpha"=>30);
+ $myPicture->drawRoundedRectangle(30,30,200,200,10,$RectangleSettings);
+
+ /* Draw a rounded rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>31,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRoundedRectangle(480,50,650,80,5,$RectangleSettings);
+
+ /* Draw a rounded rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>125,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRoundedRectangle(480,90,650,120,5,$RectangleSettings);
+
+ /* Draw a rounded rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>198,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRoundedRectangle(480,130,650,160,5,$RectangleSettings);
+
+ /* Draw a rounded rectangle */
+ $RectangleSettings = array("R"=>134,"G"=>209,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRoundedRectangle(480,170,650,200,5,$RectangleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawRoundedRectangle.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScale.color.php b/notFinishedCode/pChart2.1.2/examples/example.drawScale.color.php
new file mode 100644
index 0000000..2023caa
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScale.color.php
@@ -0,0 +1,69 @@
+<?php
+ /* CAT:Scaling */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(24,-25,26,25,25),"Temperature");
+ $MyData->addPoints(array(1,2,VOID,9,10),"Humidity 1");
+ $MyData->addPoints(array(1,VOID,7,-9,0),"Humidity 2");
+ $MyData->addPoints(array(-1,-1,-1,-1,-1),"Humidity 3");
+ $MyData->addPoints(array(0,0,0,0,0),"Vide");
+ $MyData->setSerieOnAxis("Temperature",0);
+ $MyData->setSerieOnAxis("Humidity 1",1);
+ $MyData->setSerieOnAxis("Humidity 2",1);
+ $MyData->setSerieOnAxis("Humidity 3",1);
+ $MyData->setSerieOnAxis("Vide",2);
+ $MyData->setAxisPosition(2,AXIS_POSITION_RIGHT);
+ $MyData->setAxisName(0,"Temperature");
+ $MyData->setAxisName(1,"Humidity");
+ $MyData->setAxisName(2,"Empty value");
+
+ /* Associate a color to each axis */
+ $MyData->setAxisColor(0,array("R"=>102,"G"=>129,"B"=>63));
+ $MyData->setAxisColor(1,array("R"=>129,"G"=>72,"B"=>63));
+ $MyData->setAxisColor(2,array("R"=>63,"G"=>89,"B"=>129));
+
+ /* Create the abscissa serie */
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","My labels");
+ $MyData->setAbscissa("Labels");
+ $MyData->setAbscissaName("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScale() - draw the X-Y scales",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write the chart title */
+ $myPicture->setGraphArea(90,60,660,190);
+ $myPicture->drawText(350,55,"My chart title",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+ $myPicture->drawFilledRectangle(90,60,660,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+
+ /* Draw the scale */
+ $myPicture->drawScale(array("LabelSkip"=>1,"DrawYLines"=>array(0),"Pos"=>SCALE_POS_LEFTRIGHT));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScale.color.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScale.dates.php b/notFinishedCode/pChart2.1.2/examples/example.drawScale.dates.php
new file mode 100644
index 0000000..58bdc94
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScale.dates.php
@@ -0,0 +1,55 @@
+<?php
+ /* CAT:Scaling */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(1700,2500,7800,4500,3150),"Distance");
+ $MyData->setAxisName(0,"Maximum distance");
+ $MyData->setAxisUnit(0,"m");
+ $MyData->setAxisDisplay(0,AXIS_FORMAT_METRIC);
+
+ /* Create the abscissa serie */
+ $MyData->addPoints(array(1230768000,1233446400,1235865600,1238544000,1241136000,1243814400),"Timestamp");
+ $MyData->setSerieDescription("Timestamp","Sampled Dates");
+ $MyData->setAbscissa("Timestamp");
+ $MyData->setAbscissaName("Dates");
+ $MyData->setXAxisDisplay(AXIS_FORMAT_DATE);
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScale() - draw the X-Y scales",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write the chart title */
+ $myPicture->setGraphArea(60,60,660,190);
+ $myPicture->drawText(350,55,"My chart title",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+ $myPicture->drawFilledRectangle(60,60,660,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+
+ /* Draw the scale */
+ $myPicture->drawScale();
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScale.dates.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScale.floating.php b/notFinishedCode/pChart2.1.2/examples/example.drawScale.floating.php
new file mode 100644
index 0000000..cd46b68
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScale.floating.php
@@ -0,0 +1,52 @@
+<?php
+ /* CAT:Scaling */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(8,10,24,25,25,24,23,22,20,12,10),"Temperature");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScale() - draw the X-Y scales",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write the chart title */
+ $myPicture->setGraphArea(60,50,660,200);
+ $myPicture->drawText(350,55,"My chart title",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>15,"YMargin"=>15,"Floating"=>TRUE,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScale.floating.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScale.manual.php b/notFinishedCode/pChart2.1.2/examples/example.drawScale.manual.php
new file mode 100644
index 0000000..bce8a46
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScale.manual.php
@@ -0,0 +1,54 @@
+<?php
+ /* CAT:Scaling */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(24,-25,26,25,25),"Temperature");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScale() - draw the X-Y scales",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write the chart title */
+ $myPicture->setGraphArea(60,60,660,190);
+ $myPicture->drawText(350,55,"My chart title",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+ $myPicture->drawFilledRectangle(60,60,660,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale */
+ $AxisBoundaries = array(0=>array("Min"=>0,"Max"=>100));
+ $ScaleSettings = array("Mode"=>SCALE_MODE_MANUAL,"ManualScale"=>$AxisBoundaries,"DrawSubTicks"=>TRUE,"DrawArrows"=>TRUE,"ArrowSize"=>6);
+ $myPicture->drawScale($ScaleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScale.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScale.multiple.php b/notFinishedCode/pChart2.1.2/examples/example.drawScale.multiple.php
new file mode 100644
index 0000000..ebbf8a3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScale.multiple.php
@@ -0,0 +1,63 @@
+<?php
+ /* CAT:Scaling */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(24,-25,26,25,25),"Temperature");
+ $MyData->addPoints(array(1,2,VOID,9,10),"Humidity 1");
+ $MyData->addPoints(array(1,VOID,7,-9,0),"Humidity 2");
+ $MyData->addPoints(array(-1,-1,-1,-1,-1),"Humidity 3");
+ $MyData->addPoints(array(0,0,0,0,0),"Vide");
+ $MyData->setSerieOnAxis("Temperature",0);
+ $MyData->setSerieOnAxis("Humidity 1",1);
+ $MyData->setSerieOnAxis("Humidity 2",1);
+ $MyData->setSerieOnAxis("Humidity 3",1);
+ $MyData->setSerieOnAxis("Vide",2);
+ $MyData->setAxisPosition(2,AXIS_POSITION_RIGHT);
+ $MyData->setAxisName(0,"Temperature");
+ $MyData->setAxisName(1,"Humidity");
+ $MyData->setAxisName(2,"Empty value");
+
+ /* Create the abscissa serie */
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","My labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScale() - draw the X-Y scales",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write the chart title */
+ $myPicture->setGraphArea(90,60,660,190);
+ $myPicture->drawText(350,55,"My chart title",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+ $myPicture->drawFilledRectangle(90,60,660,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+
+ /* Draw the scale */
+ $myPicture->drawScale(array("DrawYLines"=>array(0),"Pos"=>SCALE_POS_LEFTRIGHT));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScale.multiple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScale.php b/notFinishedCode/pChart2.1.2/examples/example.drawScale.php
new file mode 100644
index 0000000..a89c0ba
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScale.php
@@ -0,0 +1,53 @@
+<?php
+ /* CAT:Scaling */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(24,-25,26,25,25),"Temperature");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+ $MyData->setAbscissaName("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScale() - draw the X-Y scales",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write the chart title */
+ $myPicture->setGraphArea(60,60,660,190);
+ $myPicture->drawText(350,55,"My chart title",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+ $myPicture->drawFilledRectangle(60,60,660,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale */
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE,"DrawArrows"=>TRUE,"ArrowSize"=>6));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScale.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScale.reverse.php b/notFinishedCode/pChart2.1.2/examples/example.drawScale.reverse.php
new file mode 100644
index 0000000..0838bc2
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScale.reverse.php
@@ -0,0 +1,48 @@
+<?php
+ /* CAT:Scaling */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(24,13,14),"Temperature");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Sample #1","Sample #2","Sample #3"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScale() - draw the X-Y scales",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+
+ /* Write the chart title */
+ $myPicture->setGraphArea(60,90,660,210);
+ $myPicture->drawText(360,55,"My chart title",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+ $myPicture->drawFilledRectangle(60,90,660,210,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+
+ /* Draw the scale */
+ $myPicture->drawScale(array("AutoAxisLabels"=>FALSE,"Pos"=>SCALE_POS_TOPBOTTOM));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScale.reverse.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScatter.shape.php b/notFinishedCode/pChart2.1.2/examples/example.drawScatter.shape.php
new file mode 100644
index 0000000..25d1e29
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScatter.shape.php
@@ -0,0 +1,69 @@
+<?php
+ /* CAT:Scatter chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=10;$i=$i+1) { $myData->addPoints(rand(1,20),"Probe 1"); }
+ for ($i=0;$i<=10;$i=$i+1) { $myData->addPoints(rand(1,20),"Probe 2"); }
+ $myData->setAxisName(0,"X-Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_TOP);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=10;$i=$i+1) { $myData->addPoints(rand(1,20),"Probe 3"); }
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Y-Index");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisPosition(1,AXIS_POSITION_LEFT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 3",0);
+ $myData->setScatterSerieDescription(0,"This year");
+ $myData->setScatterSerieColor(0,array("R"=>0,"G"=>0,"B"=>0));
+ $myData->setScatterSerieShape(0,SERIE_SHAPE_TRIANGLE);
+
+ /* Create the 2nd scatter chart binding */
+ $myData->setScatterSerie("Probe 2","Probe 3",1);
+ $myData->setScatterSerieDescription(1,"Last Year");
+ $myData->setScatterSerieShape(1,SERIE_SHAPE_FILLEDTRIANGLE);
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Turn of Anti-aliasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(40,40,370,370);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>15,"YMargin"=>15,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myScatter->drawScatterScale($scaleSettings);
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(280,380,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Draw a scatter plot chart */
+ $myPicture->Antialias = TRUE;
+ $myScatter->drawScatterPlotChart();
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.example.drawScatterShape.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScatter.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawScatter.simple.php
new file mode 100644
index 0000000..915823b
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScatter.simple.php
@@ -0,0 +1,67 @@
+<?php
+ /* CAT:Scatter chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=10;$i=$i+1) { $myData->addPoints(rand(1,20),"Probe 1"); }
+ for ($i=0;$i<=10;$i=$i+1) { $myData->addPoints(rand(1,20),"Probe 2"); }
+ $myData->setAxisName(0,"X-Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_TOP);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=10;$i=$i+1) { $myData->addPoints(rand(1,20),"Probe 3"); }
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Y-Index");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisPosition(1,AXIS_POSITION_LEFT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 3",0);
+ $myData->setScatterSerieDescription(0,"This year");
+ $myData->setScatterSerieColor(0,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Create the 2nd scatter chart binding */
+ $myData->setScatterSerie("Probe 2","Probe 3",1);
+ $myData->setScatterSerieDescription(1,"Last Year");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Turn of Anti-aliasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(40,40,370,370);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>15,"YMargin"=>15,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myScatter->drawScatterScale($scaleSettings);
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(280,380,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Draw a scatter plot chart */
+ $myPicture->Antialias = TRUE;
+ $myScatter->drawScatterPlotChart();
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.example.drawScatterBestFit.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScatterBestFit.php b/notFinishedCode/pChart2.1.2/examples/example.drawScatterBestFit.php
new file mode 100644
index 0000000..dec2905
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScatterBestFit.php
@@ -0,0 +1,81 @@
+<?php
+ /* CAT:Mathematical */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(rand(1,20)*10+rand(0,$i),"Probe 1"); }
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(rand(1,2)*10+rand(0,$i),"Probe 2"); }
+ $myData->setAxisName(0,"X-Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_TOP);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints($i,"Probe 3"); }
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Y-Index");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisPosition(1,AXIS_POSITION_LEFT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 3",0);
+ $myData->setScatterSerieDescription(0,"This year");
+ $myData->setScatterSerieColor(0,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Create the 2nd scatter chart binding */
+ $myData->setScatterSerie("Probe 2","Probe 3",1);
+ $myData->setScatterSerieDescription(1,"Last Year");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScatterBestFit() - Linear regression",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,60,350,360);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $myScatter->drawScatterScale();
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw a scatter plot chart */
+ $myScatter->drawScatterPlotChart();
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(280,380,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Draw the line of best fit */
+ $myScatter->drawScatterBestFit();
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScatterBestFit.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScatterLineChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawScatterLineChart.php
new file mode 100644
index 0000000..7c8a3ab
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScatterLineChart.php
@@ -0,0 +1,80 @@
+<?php
+ /* CAT:Scatter chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(cos(deg2rad($i))*20,"Probe 1"); }
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(sin(deg2rad($i))*20,"Probe 2"); }
+ $myData->setAxisName(0,"Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints($i,"Probe 3"); }
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Degree");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisUnit(1,"°");
+ $myData->setAxisPosition(1,AXIS_POSITION_RIGHT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 3",0);
+ $myData->setScatterSerieDescription(0,"This year");
+ $myData->setScatterSerieTicks(0,4);
+ $myData->setScatterSerieColor(0,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Create the 2nd scatter chart binding */
+ $myData->setScatterSerie("Probe 2","Probe 3",1);
+ $myData->setScatterSerieDescription(1,"Last Year");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScatterLineChart() - Draw a scatter line chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,50,350,350);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $myScatter->drawScatterScale();
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw a scatter plot chart */
+ $myScatter->drawScatterLineChart();
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(280,380,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScatterLineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScatterLineChart.trigo.php b/notFinishedCode/pChart2.1.2/examples/example.drawScatterLineChart.trigo.php
new file mode 100644
index 0000000..155a516
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScatterLineChart.trigo.php
@@ -0,0 +1,75 @@
+<?php
+ /* CAT:Scatter chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(cos(deg2rad($i))*20,"Probe 1"); }
+ $myData->setAxisName(0,"X-Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(sin(deg2rad(30-$i))*20,"Probe 2"); }
+ $myData->setSerieOnAxis("Probe 2",1);
+ $myData->setAxisName(1,"Y-Index");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisPosition(1,AXIS_POSITION_RIGHT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 2",0);
+ $myData->setScatterSerieDescription(0,"Trigonometric function");
+ $myData->setScatterSerieTicks(0,4);
+ $myData->setScatterSerieColor(0,array("R"=>180,"G"=>0,"B"=>0));
+ $myData->setScatterSeriePicture(0,"resources/chart_line.png");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScatterLineChart() - Draw a scatter line chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,50,350,350);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $myScatter->drawScatterScale();
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw a scatter plot chart */
+ $myScatter->drawScatterLineChart();
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(270,375,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScatterLineChart.trigo.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScatterPlotChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawScatterPlotChart.php
new file mode 100644
index 0000000..39b7b4b
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScatterPlotChart.php
@@ -0,0 +1,80 @@
+<?php
+ /* CAT:Scatter chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(cos(deg2rad($i))*20,"Probe 1"); }
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(sin(deg2rad($i))*20,"Probe 2"); }
+ $myData->setAxisName(0,"Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints($i,"Probe 3"); }
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Degree");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisUnit(1,"°");
+ $myData->setAxisPosition(1,AXIS_POSITION_RIGHT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 3",0);
+ $myData->setScatterSerieDescription(0,"This year");
+ $myData->setScatterSerieColor(0,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Create the 2nd scatter chart binding */
+ $myData->setScatterSerie("Probe 2","Probe 3",1);
+ $myData->setScatterSerieDescription(1,"Last Year");
+ $myData->setScatterSeriePicture(1,"resources/accept.png");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScatterPlotChart() - Draw a scatter plot chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,50,350,350);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $myScatter->drawScatterScale();
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw a scatter plot chart */
+ $myScatter->drawScatterPlotChart();
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(260,375,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScatterPlotChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScatterScale.manual.php b/notFinishedCode/pChart2.1.2/examples/example.drawScatterScale.manual.php
new file mode 100644
index 0000000..77f1136
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScatterScale.manual.php
@@ -0,0 +1,61 @@
+<?php
+ /* CAT:Scatter chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ $myData->addPoints(array(3,12,15,8,5,-5),"X Values");
+ $myData->setAxisName(0,"X Values");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisDisplay(0,AXIS_FORMAT_TIME,"i:s");
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis and the binded series */
+ $myData->addPoints(array(2,7,5,18,19,22),"Y Values");
+ $myData->setSerieOnAxis("Y Values",1);
+ $myData->setAxisName(1,"Y Values");
+ $myData->setAxisXY(1,AXIS_Y);
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScatterScale() - Draw the scatter chart scale",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,50,350,350);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $AxisBoundaries = array(0=>array("Min"=>0,"Max"=>3600,"Rows"=>12,"RowHeight"=>300),1=>array("Min"=>0,"Max"=>100));
+ $ScaleSettings = array("Mode"=>SCALE_MODE_MANUAL,"ManualScale"=>$AxisBoundaries,"DrawSubTicks"=>TRUE);
+ $myScatter->drawScatterScale($ScaleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScatterScale.manual.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScatterScale.php b/notFinishedCode/pChart2.1.2/examples/example.drawScatterScale.php
new file mode 100644
index 0000000..82e5bfe
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScatterScale.php
@@ -0,0 +1,62 @@
+<?php
+ /* CAT:Scatter chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ $myData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $myData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $myData->setAxisName(0,"Temperatures");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisUnit(0,"°C");
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis and the binded series */
+ $myData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Humidity");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisUnit(1,"%");
+ $myData->setAxisPosition(1,AXIS_POSITION_RIGHT);
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScatterScale() - Draw the scatter chart scale",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,50,350,350);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $myScatter->drawScatterScale();
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScatterScale.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawScatterSplineChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawScatterSplineChart.php
new file mode 100644
index 0000000..620fbfb
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawScatterSplineChart.php
@@ -0,0 +1,81 @@
+<?php
+ /* CAT:Scatter chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+90) { $myData->addPoints(rand(1,30),"Probe 1"); }
+ for ($i=0;$i<=360;$i=$i+90) { $myData->addPoints(rand(1,30),"Probe 2"); }
+ $myData->setAxisName(0,"Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+90) { $myData->addPoints($i,"Probe 3"); }
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Degree");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisUnit(1,"°");
+ $myData->setAxisPosition(1,AXIS_POSITION_RIGHT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 3",0);
+ $myData->setScatterSerieDescription(0,"This year");
+ $myData->setScatterSerieTicks(0,4);
+ $myData->setScatterSerieColor(0,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Create the 2nd scatter chart binding */
+ $myData->setScatterSerie("Probe 2","Probe 3",1);
+ $myData->setScatterSerieDescription(1,"Last Year");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawScatterSplineChart() - Draw a scatter spline chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,50,350,350);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $myScatter->drawScatterScale();
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw a scatter plot chart */
+ $myScatter->drawScatterSplineChart();
+ $myScatter->drawScatterPlotChart();
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(280,380,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawScatterSplineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawSimple.php b/notFinishedCode/pChart2.1.2/examples/example.drawSimple.php
new file mode 100644
index 0000000..7a4f566
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawSimple.php
@@ -0,0 +1,42 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(2,7,5,18,19,22,23,25,22,12,10,10),"DEFCA");
+ $MyData->setAxisName(0,"$ Incomes");
+ $MyData->setAxisDisplay(0,AXIS_FORMAT_CURRENCY);
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun","Jul","Aou","Sep","Oct","Nov","Dec"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+ $MyData->setPalette("DEFCA",array("R"=>55,"G"=>91,"B"=>127));
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>220,"StartG"=>220,"StartB"=>220,"EndR"=>255,"EndG"=>255,"EndB"=>255,"Alpha"=>100));
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>200,"G"=>200,"B"=>200));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(60,35,"2k9 Average Incomes",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMLEFT));
+
+ /* Do some cosmetic and draw the chart */
+ $myPicture->setGraphArea(60,40,670,190);
+ $myPicture->drawFilledRectangle(60,40,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("GridR"=>180,"GridG"=>180,"GridB"=>180));
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawSplineChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(643,210,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawSimple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawSpline.php b/notFinishedCode/pChart2.1.2/examples/example.drawSpline.php
new file mode 100644
index 0000000..8b88d04
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawSpline.php
@@ -0,0 +1,42 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawSpline() - for smooth line drawing",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a spline */
+ $SplineSettings = array("R"=>255,"G"=>255,"B"=>255,"ShowControl"=>TRUE);
+ $Coordinates = array(array(40,80),array(280,60),array(340,166),array(590,120));
+ $myPicture->drawSpline($Coordinates,$SplineSettings);
+
+ /* Draw a spline */
+ $SplineSettings = array("R"=>255,"G"=>255,"B"=>255,"ShowControl"=>TRUE,"Ticks"=>4);
+ $Coordinates = array(array(250,50),array(250,180),array(350,180),array(350,50));
+ $myPicture->drawSpline($Coordinates,$SplineSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawSpline.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawSplineChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawSplineChart.php
new file mode 100644
index 0000000..f0a8eb5
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawSplineChart.php
@@ -0,0 +1,66 @@
+<?php
+ /* CAT:Spline chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->setAxisUnit(0,"°C");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawSplineChart() - draw a spline chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawSplineChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO));
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the scale and the 2nd chart */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawSplineChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(510,205,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawSplineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawSplineChart.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawSplineChart.simple.php
new file mode 100644
index 0000000..60005d7
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawSplineChart.simple.php
@@ -0,0 +1,59 @@
+<?php
+ /* CAT:Spline chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setSerieWeight("Probe 3",2);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw a background */
+ $Settings = array("R"=>190, "G"=>213, "B"=>107, "Dash"=>1, "DashR"=>210, "DashG"=>223, "DashB"=>127);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw the line chart */
+ $myPicture->drawSplineChart();
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(540,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawSplineChart.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStackedAreaChart.normalized.php b/notFinishedCode/pChart2.1.2/examples/example.drawStackedAreaChart.normalized.php
new file mode 100644
index 0000000..ba3fd67
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStackedAreaChart.normalized.php
@@ -0,0 +1,43 @@
+<?php
+ /* CAT:Stacked chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(4,0,0,12,8,3,0,12,8),"Frontend #1");
+ $MyData->addPoints(array(3,12,15,8,5,5,12,15,8),"Frontend #2");
+ $MyData->addPoints(array(2,7,5,18,19,22,7,5,18),"Frontend #3");
+ $MyData->setAxisName(0,"Average Usage");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun","Jui","Aug","Sep"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Normalize the data series to 100% */
+ $MyData->normalize(100,"%");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale and the chart */
+ $myPicture->setGraphArea(60,20,680,190);
+ $myPicture->drawScale(array("XMargin"=>2,"DrawSubTicks"=>TRUE,"Mode"=>SCALE_MODE_ADDALL));
+ $myPicture->drawStackedAreaChart(array("Surrounding"=>60));
+
+ /* Turn on shadow processing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(480,210,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStackedAreaChart.normalized.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStackedAreaChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawStackedAreaChart.php
new file mode 100644
index 0000000..da9a681
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStackedAreaChart.php
@@ -0,0 +1,63 @@
+<?php
+ /* CAT:Stacked chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(1,-2,-1,2,1,0),"Probe 1");
+ $MyData->addPoints(array(1,-2,-3,2,1,8),"Probe 2");
+ $MyData->addPoints(array(2,4,2,0,4,2),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawStackedAreaChart() - draw a stacked area chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE,"Mode"=>SCALE_MODE_ADDALL));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->setShadow(FALSE);
+ $myPicture->drawStackedAreaChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO,"Surrounding"=>20));
+
+ /* Draw the scale and the 2nd chart */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"Mode"=>SCALE_MODE_ADDALL,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(FALSE);
+ $myPicture->drawStackedAreaChart(array("Surrounding"=>10));
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(510,205,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStackedAreaChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.border.php b/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.border.php
new file mode 100644
index 0000000..6fb9e6c
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.border.php
@@ -0,0 +1,39 @@
+<?php
+ /* CAT:Stacked chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(4,VOID,VOID,12,8,3),"Frontend #1");
+ $MyData->addPoints(array(3,12,15,8,5,5),"Frontend #2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Frontend #3");
+ $MyData->setAxisName(0,"Average Usage");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale and the chart */
+ $myPicture->setGraphArea(60,20,680,190);
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE,"Mode"=>SCALE_MODE_ADDALL_START0));
+ $myPicture->setShadow(FALSE);
+ $myPicture->drawStackedBarChart(array("Surrounding"=>-15,"InnerSurrounding"=>15));
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(480,210,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStackedBarChart.shaded.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.can.php b/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.can.php
new file mode 100644
index 0000000..527f4f4
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.can.php
@@ -0,0 +1,42 @@
+<?php
+ /* CAT:Stacked chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Frontend #1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Frontend #2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Frontend #3");
+ $MyData->setAxisName(0,"Average Usage");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Normalize all the data series to 100% */
+ $MyData->normalize(100,"%");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale and the chart */
+ $myPicture->setGraphArea(60,20,680,190);
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE,"Mode"=>SCALE_MODE_ADDALL));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawStackedBarChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO,"Gradient"=>TRUE,"GradientMode"=>GRADIENT_EFFECT_CAN,"Surrounding"=>30));
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(480,210,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStackedBarChart.can.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.php
new file mode 100644
index 0000000..4826fbe
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.php
@@ -0,0 +1,65 @@
+<?php
+ /* CAT:Stacked chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawStackedBarChart() - draw a stacked bar chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE,"Mode"=>SCALE_MODE_ADDALL));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawStackedBarChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO,"Rounded"=>TRUE,"Surrounding"=>60));
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the scale and the 2nd chart */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"Mode"=>SCALE_MODE_ADDALL,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawStackedBarChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(510,205,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStackedBarChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.rounded.php b/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.rounded.php
new file mode 100644
index 0000000..a6c0340
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.rounded.php
@@ -0,0 +1,53 @@
+<?php
+ /* CAT:Stacked chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-7,-8,-15,-20,-18,-12,8,-19,9,16,-20,8,10,-10,-14,-20,8,-9,-19),"Probe 3");
+ $MyData->addPoints(array(19,0,-8,8,-8,12,-19,-10,5,12,-20,-8,10,-11,-12,8,-17,-14,0),"Probe 4");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array(4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22),"Time");
+ $MyData->setSerieDescription("Time","Hour of the day");
+ $MyData->setAbscissa("Time");
+ $MyData->setXAxisUnit("h");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale */
+ $myPicture->setGraphArea(60,30,650,190);
+ $myPicture->drawScale(array("CycleBackground"=>TRUE,"DrawSubTicks"=>TRUE,"GridR"=>0,"GridG"=>0,"GridB"=>0,"GridAlpha"=>10,"Mode"=>SCALE_MODE_ADDALL));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw some thresholds */
+ $myPicture->setShadow(FALSE);
+ $myPicture->drawThreshold(-40,array("WriteCaption"=>TRUE,"R"=>0,"G"=>0,"B"=>0,"Ticks"=>4));
+ $myPicture->drawThreshold(28,array("WriteCaption"=>TRUE,"R"=>0,"G"=>0,"B"=>0,"Ticks"=>4));
+
+ /* Draw the chart */
+ $myPicture->drawStackedBarChart(array("Rounded"=>TRUE,"DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO,"DisplaySize"=>6,"BorderR"=>255,"BorderG"=>255,"BorderB"=>255));
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(570,212,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStackedBarChart.rounded.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.shaded.php b/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.shaded.php
new file mode 100644
index 0000000..55bc221
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStackedBarChart.shaded.php
@@ -0,0 +1,42 @@
+<?php
+ /* CAT:Stacked chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Frontend #1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Frontend #2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Frontend #3");
+ $MyData->setAxisName(0,"Average Usage");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Normalize all the data series to 100% */
+ $MyData->normalize(100,"%");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale and the chart */
+ $myPicture->setGraphArea(60,20,680,190);
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE,"Mode"=>SCALE_MODE_ADDALL));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawStackedBarChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO,"Gradient"=>TRUE,"Surrounding"=>30));
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(480,210,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStackedBarChart.shaded.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStandardDeviation.php b/notFinishedCode/pChart2.1.2/examples/example.drawStandardDeviation.php
new file mode 100644
index 0000000..3a93257
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStandardDeviation.php
@@ -0,0 +1,79 @@
+<?php
+ /* CAT:Mathematical */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ for($i=0;$i<=100;$i++) { $MyData->addPoints(rand(0,20),"Probe 1"); }
+ $MyData->setAxisName(0,"Temperatures");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(160,35,"Measured temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+ $myPicture->drawText(340,30,"(and associated standard deviation)",array("FontSize"=>10,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,50,670,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("LabelSkip"=>9,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the line chart */
+ $myPicture->drawPlotChart(array("PlotSize"=>2));
+
+ /* Compute the serie average and standard deviation */
+ $Average = $MyData->getSerieAverage("Probe 1");
+
+ /* Compute the serie standard deviation */
+ $StandardDeviation = $MyData->getStandardDeviation("Probe 1");
+
+ /* Draw a threshold area */
+ $myPicture->setShadow(FALSE);
+ $myPicture->drawThresholdArea($Average-$StandardDeviation,$Average+$StandardDeviation,array("R"=>100,"G"=>100,"B"=>200,"Alpha"=>10));
+ $myPicture->setShadow(TRUE);
+
+ /* Draw the serie average */
+ $myPicture->drawThreshold($Average,array("WriteCaption"=>TRUE,"Caption"=>"Average value","AxisID"=>0));
+
+ /* Draw the standard deviation boundaries */
+ $ThresholdSettings = array("WriteCaption"=>TRUE,"CaptionAlign"=>CAPTION_RIGHT_BOTTOM ,"Caption"=>"SD","AxisID"=>0,"R"=>0,"G"=>0,"B"=>0);
+ $myPicture->drawThreshold($Average+$StandardDeviation,$ThresholdSettings);
+ $myPicture->drawThreshold($Average-$StandardDeviation,$ThresholdSettings);
+
+ /* Write the coefficient of variation */
+ $CoefficientOfVariation = round($MyData->getCoefficientOfVariation("Probe 1"),1);
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawText(610,46,"coefficient of variation : ".$CoefficientOfVariation,array("Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStandardDeviation.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStepChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawStepChart.php
new file mode 100644
index 0000000..7df3a6c
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStepChart.php
@@ -0,0 +1,65 @@
+<?php
+ /* CAT:Step chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawStepChart() - draw a step chart",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and the 1st chart */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawStepChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO));
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the scale and the 2nd chart */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>-1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawStepChart();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(510,205,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStepChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStepChart.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawStepChart.simple.php
new file mode 100644
index 0000000..80f7a85
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStepChart.simple.php
@@ -0,0 +1,44 @@
+<?php
+ /* CAT:Step chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(VOID,VOID,VOID,2,6,3),"Probe 1");
+ $MyData->addPoints(array(13,12,15,18,15,10),"Probe 2");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of AAliasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the border */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,30,650,190);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Draw the step chart */
+ $myPicture->drawStepChart();
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(590,17,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStepChart.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStockChart.median.php b/notFinishedCode/pChart2.1.2/examples/example.drawStockChart.median.php
new file mode 100644
index 0000000..d7505bb
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStockChart.median.php
@@ -0,0 +1,50 @@
+<?php
+ /* CAT:Stock chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pStock.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(35,28,17,27,12,12,20,15,20,28),"Open");
+ $MyData->addPoints(array(20,17,25,20,25,23,16,29,26,17),"Close");
+ $MyData->addPoints(array(10,11,14,11,9,4,3,7,9,5),"Min");
+ $MyData->addPoints(array(37,32,33,29,29,25,22,34,29,31),"Max");
+ $MyData->addPoints(array(30,20,21,24,22,18,18,24,22,24),"Median");
+ $MyData->setAxisDisplay(0,AXIS_FORMAT_CURRENCY,"$");
+
+ $MyData->addPoints(array("Dec 13","Dec 14","Dec 15","Dec 16","Dec 17", "Dec 20","Dec 21","Dec 22","Dec 23","Dec 24"),"Time");
+ $MyData->setAbscissa("Time");
+ $MyData->setAbscissaName("Time");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of AAliasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the border */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,30,650,190);
+
+ /* Draw the scale */
+ $scaleSettings = array("GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Create the pStock object */
+ $mystockChart = new pStock($myPicture,$MyData);
+
+ /* Draw the stock chart */
+ $stockSettings = array("BoxUpR"=>255,"BoxUpG"=>255,"BoxUpB"=>255,"BoxDownR"=>0,"BoxDownG"=>0,"BoxDownB"=>0,"SerieMedian"=>"Median");
+ $mystockChart->drawStockChart($stockSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStockChart.median.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStockChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawStockChart.php
new file mode 100644
index 0000000..003b7a4
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStockChart.php
@@ -0,0 +1,65 @@
+<?php
+ /* CAT:Stock chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pStock.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(34,55,15,62,38,42),"Open");
+ $MyData->addPoints(array(42,25,40,38,49,36),"Close");
+ $MyData->addPoints(array(27,14,12,25,32,32),"Min");
+ $MyData->addPoints(array(45,59,47,65,64,48),"Max");
+ $MyData->setAxisDisplay(0,AXIS_FORMAT_CURRENCY,"$");
+
+ $MyData->addPoints(array("8h","10h","12h","14h","16h","18h"),"Time");
+ $MyData->setAbscissa("Time");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+
+ /* Draw the border */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(60,45,"Stock price",array("FontSize"=>28,"Align"=>TEXT_ALIGN_BOTTOMLEFT));
+
+ /* Draw the 1st scale */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE));
+
+ /* Draw the 1st stock chart */
+ $mystockChart = new pStock($myPicture,$MyData);
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>30));
+ $mystockChart->drawStockChart();
+
+ /* Reset the display mode because of the graph small size */
+ $MyData->setAxisDisplay(0,AXIS_FORMAT_DEFAULT);
+
+ /* Draw the 2nd scale */
+ $myPicture->setShadow(FALSE);
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+
+ /* Draw the 2nd stock chart */
+ $mystockChart = new pStock($myPicture,$MyData);
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>30));
+ $mystockChart->drawStockChart();
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStockChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawStockChart.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawStockChart.simple.php
new file mode 100644
index 0000000..c47457a
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawStockChart.simple.php
@@ -0,0 +1,49 @@
+<?php
+ /* CAT:Stock chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pStock.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(35,28,17,27,12,12,20,15,20,28),"Open");
+ $MyData->addPoints(array(20,17,25,20,25,23,16,29,26,17),"Close");
+ $MyData->addPoints(array(10,11,14,11,9,4,3,7,9,5),"Min");
+ $MyData->addPoints(array(37,32,33,29,29,25,22,34,29,31),"Max");
+ $MyData->setAxisDisplay(0,AXIS_FORMAT_CURRENCY,"$");
+
+ $MyData->addPoints(array("Dec 13","Dec 14","Dec 15","Dec 16","Dec 17", "Dec 20","Dec 21","Dec 22","Dec 23","Dec 24"),"Time");
+ $MyData->setAbscissa("Time");
+ $MyData->setAbscissaName("Time");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of AAliasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the border */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,30,650,190);
+
+ /* Draw the scale */
+ $scaleSettings = array("GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Create the pStock object */
+ $mystockChart = new pStock($myPicture,$MyData);
+
+ /* Draw the stock chart */
+ $stockSettings = array("BoxUpR"=>255,"BoxUpG"=>255,"BoxUpB"=>255,"BoxDownR"=>0,"BoxDownG"=>0,"BoxDownB"=>0);
+ $mystockChart->drawStockChart($stockSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawStockChart.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawSurface.palette.php b/notFinishedCode/pChart2.1.2/examples/example.drawSurface.palette.php
new file mode 100644
index 0000000..beba562
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawSurface.palette.php
@@ -0,0 +1,63 @@
+<?php
+ /* CAT:Surface chart*/
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pSurface.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,220);
+
+ /* Create a solid background */
+ $Settings = array("R"=>50, "G"=>70, "B"=>0,"Dash"=>1, "DashR"=>30, "DashG"=>50, "DashB"=>0);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Do a gradient overlay */
+ $Settings = array("StartR"=>194, "StartG"=>131, "StartB"=>44, "EndR"=>43, "EndG"=>7, "EndB"=>58, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pSurface() :: 2D surface charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1));
+
+ /* Create the surface object */
+ $mySurface = new pSurface($myPicture);
+
+ /* Set the grid size */
+ $mySurface->setGrid(200,0);
+
+ /* Write the axis labels */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6,"R"=>255,"G"=>255,"B"=>255));
+
+ /* Draw the surface chart */
+ $Palette = array(0=>array("R"=>0,"G"=>0,"B"=>0),
+ 1=>array("R"=>29,"G"=>243,"B"=>119),
+ 2=>array("R"=>238,"G"=>216,"B"=>78),
+ 3=>array("R"=>246,"G"=>45,"B"=>53));
+
+ $myPicture->setGraphArea(40,40,380,80);
+ $mySurface->writeYLabels(array("Labels"=>"1st Seq"));
+ for($i=0; $i<=200; $i++) { $mySurface->addPoint($i,0,rand(0,3)); }
+ $mySurface->drawSurface(array("Padding"=>0,"Palette"=>$Palette));
+
+ $myPicture->setGraphArea(40,100,380,140);
+ $mySurface->writeYLabels(array("Labels"=>"2nd Seq"));
+ for($i=0; $i<=200; $i++) { $mySurface->addPoint($i,0,rand(0,3)); }
+ $mySurface->drawSurface(array("Padding"=>0,"Palette"=>$Palette));
+
+ $myPicture->setGraphArea(40,160,380,200);
+ $mySurface->writeYLabels(array("Labels"=>"3rd Seq"));
+ for($i=0; $i<=200; $i++) { $mySurface->addPoint($i,0,rand(0,3)); }
+ $mySurface->drawSurface(array("Padding"=>0,"Palette"=>$Palette));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.surface.palette.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawSurface.php b/notFinishedCode/pChart2.1.2/examples/example.drawSurface.php
new file mode 100644
index 0000000..85f8916
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawSurface.php
@@ -0,0 +1,57 @@
+<?php
+ /* CAT:Surface chart*/
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pSurface.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400);
+
+ /* Create a solid background */
+ $Settings = array("R"=>179, "G"=>217, "B"=>91, "Dash"=>1, "DashR"=>199, "DashG"=>237, "DashB"=>111);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Do a gradient overlay */
+ $Settings = array("StartR"=>194, "StartG"=>231, "StartB"=>44, "EndR"=>43, "EndG"=>107, "EndB"=>58, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,400,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pSurface() :: 2D surface charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Define the charting area */
+ $myPicture->setGraphArea(20,40,380,380);
+ $myPicture->drawFilledRectangle(20,40,380,380,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>20));
+
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1));
+
+ /* Create the surface object */
+ $mySurface = new pSurface($myPicture);
+
+ /* Set the grid size */
+ $mySurface->setGrid(20,20);
+
+ /* Write the axis labels */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $mySurface->writeXLabels();
+ $mySurface->writeYLabels();
+
+ /* Add random values */
+ for($i=0; $i<=50; $i++) { $mySurface->addPoint(rand(0,20),rand(0,20),rand(0,100)); }
+
+ /* Compute the missing points */
+ $mySurface->computeMissing();
+
+ /* Draw the surface chart */
+ $mySurface->drawSurface(array("Border"=>TRUE,"Surrounding"=>40));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.surface.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawSurface.simple.php b/notFinishedCode/pChart2.1.2/examples/example.drawSurface.simple.php
new file mode 100644
index 0000000..4b74e77
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawSurface.simple.php
@@ -0,0 +1,58 @@
+<?php
+ /* CAT:Surface chart*/
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+ include("../class/pSurface.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(210,100);
+
+ /* Create a solid background */
+ $Settings = array("R"=>179, "G"=>217, "B"=>91, "Dash"=>1, "DashR"=>199, "DashG"=>237, "DashB"=>111);
+ $myPicture->drawFilledRectangle(0,0,210,100,$Settings);
+
+ /* Do a gradient overlay */
+ $Settings = array("StartR"=>194, "StartG"=>231, "StartB"=>44, "EndR"=>43, "EndG"=>107, "EndB"=>58, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,210,100,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,210,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,209,99,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pSurface() :: Surface charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Define the charting area */
+ $myPicture->setGraphArea(50,60,180,80);
+ $myPicture->drawFilledRectangle(50,60,180,80,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>20));
+
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1));
+
+ /* Create the surface object */
+ $mySurface = new pSurface($myPicture);
+
+ /* Set the grid size */
+ $mySurface->setGrid(9,1);
+
+ /* Write the axis labels */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Bedizen.ttf","FontSize"=>7));
+
+
+ $mySurface->writeXLabels(array("Angle"=>45,"Labels"=>array("Run 1","Run 2","Run 3","Run 4","Run 5","Run 6","Run 7","Run 8","Run 9","Run 10")));
+ $mySurface->writeYLabels(array("Labels"=>array("Probe 1","Probe 2")));
+
+ /* Add random values */
+ for($i=0; $i<=10; $i++) { $mySurface->addPoint($i,rand(0,1),rand(0,100)); }
+
+ /* Draw the surface chart */
+ $mySurface->drawSurface(array("Border"=>TRUE,"Surrounding"=>40));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.surface.simple.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawText.php b/notFinishedCode/pChart2.1.2/examples/example.drawText.php
new file mode 100644
index 0000000..06bf0b9
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawText.php
@@ -0,0 +1,55 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawText() - add some text to your charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Write some text */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/advent_light.ttf","FontSize"=>20));
+ $TextSettings = array("R"=>255,"G"=>255,"B"=>255,"Angle"=>10);
+ $myPicture->drawText(60,115,"10 degree text",$TextSettings);
+
+ /* Write some text */
+ $TextSettings = array("R"=>0,"G"=>0,"B"=>0,"Angle"=>0,"FontSize"=>40);
+ $myPicture->drawText(220,130,"Simple text",$TextSettings);
+
+ /* Write some text */
+ $TextSettings = array("R"=>200,"G"=>100,"B"=>0,"Angle"=>90,"FontSize"=>14);
+ $myPicture->drawText(500,170,"Vertical Text",$TextSettings);
+
+ /* Write some text */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Bedizen.ttf","FontSize"=>6));
+ $TextSettings = array("DrawBox"=>TRUE,"BoxRounded"=>TRUE,"R"=>0,"G"=>0,"B"=>0,"Angle"=>0,"FontSize"=>10);
+ $myPicture->drawText(220,160,"Encapsulated text",$TextSettings);
+
+ /* Write some text */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>6));
+ $TextSettings = array("DrawBox"=>TRUE,"R"=>0,"G"=>0,"B"=>0,"Angle"=>0,"FontSize"=>10);
+ $myPicture->drawText(220,195,"Text in a box",$TextSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawText.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawThreshold.labels.php b/notFinishedCode/pChart2.1.2/examples/example.drawThreshold.labels.php
new file mode 100644
index 0000000..39f4aad
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawThreshold.labels.php
@@ -0,0 +1,53 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(2,7,5,18,VOID,12,10,15,8,5,6,9),"Help Desk");
+ $MyData->setAxisName(0,"Incidents");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun","Jui","Aou","Sep","Oct","Nov","Dec"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>100,"StartG"=>100,"StartB"=>100,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>100,"StartG"=>100,"StartB"=>100,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>20));
+ $myPicture->drawGradientArea(0,0,60,230,DIRECTION_HORIZONTAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Do some cosmetics */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawLine(60,0,60,230,array("R"=>70,"G"=>70,"B"=>70));
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(35,115,"Recorded cases",array("R"=>255,"G"=>255,"B"=>255,"FontSize"=>20,"Angle"=>90,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Prepare the chart area */
+ $myPicture->setGraphArea(100,30,680,190);
+ $myPicture->drawFilledRectangle(100,30,680,190,array("R"=>255,"G"=>255,"B"=>255,"Alpha"=>20));
+ $myPicture->setFontProperties(array("R"=>255,"G"=>255,"B"=>255,"FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawScale(array("AxisR"=>255,"AxisG"=>255,"AxisB"=>255,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE));
+
+ /* Write two thresholds over the chart */
+ $myPicture->drawThreshold(10,array("WriteCaption"=>TRUE,"Caption"=>"Agreed SLA"));
+ $myPicture->drawThreshold(15,array("WriteCaption"=>TRUE,"Caption"=>"Best effort"));
+
+ /* Draw the chart */
+ $myPicture->drawSplineChart();
+ $myPicture->drawPlotChart();
+
+
+ /* Write the data bounds */
+ $myPicture->writeBounds();
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(630,215,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawThreshold.labels.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawThreshold.php b/notFinishedCode/pChart2.1.2/examples/example.drawThreshold.php
new file mode 100644
index 0000000..00d8491
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawThreshold.php
@@ -0,0 +1,69 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(24,-25,26,25,25),"Temperature");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawThreshold() - draw a treshold in the charting area",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"My chart title",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and do some cosmetics */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw one static threshold */
+ $myPicture->drawThreshold(5,array("Alpha"=>70,"Ticks"=>1));
+
+ /* Draw one static threshold */
+ $myPicture->drawThreshold(15,array("Alpha"=>70,"Ticks"=>2,"R"=>0,"G"=>0,"B"=>255));
+
+ /* Disable shadow computing */
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the scale and do some cosmetics */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw one static threshold */
+ $myPicture->drawThreshold(5,array("Alpha"=>70,"Ticks"=>1));
+
+ /* Draw one static threshold */
+ $myPicture->drawThreshold(15,array("Alpha"=>70,"Ticks"=>2,"R"=>0,"G"=>0,"B"=>255));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawThreshold.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawThresholdArea.php b/notFinishedCode/pChart2.1.2/examples/example.drawThresholdArea.php
new file mode 100644
index 0000000..eb6ea5d
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawThresholdArea.php
@@ -0,0 +1,58 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(24,-25,26,25,25),"Temperature");
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawThresholdArea() - draw treshold areas in the charting area",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(250,55,"My chart title",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw the scale and do some cosmetics */
+ $myPicture->setGraphArea(60,60,450,190);
+ $myPicture->drawFilledRectangle(60,60,450,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE));
+
+ /* Draw one static threshold area */
+ $myPicture->drawThresholdArea(5,15,array("R"=>226,"G"=>194,"B"=>54,"Alpha"=>40));
+
+ /* Draw the scale and do some cosmetics */
+ $myPicture->setGraphArea(500,60,670,190);
+ $myPicture->drawFilledRectangle(500,60,670,190,array("R"=>255,"G"=>255,"B"=>255,"Surrounding"=>-200,"Alpha"=>10));
+ $myPicture->drawScale(array("Pos"=>SCALE_POS_TOPBOTTOM,"DrawSubTicks"=>TRUE));
+
+ /* Draw one static threshold area */
+ $myPicture->drawThresholdArea(5,15,array("R"=>206,"G"=>231,"B"=>64,"Alpha"=>20));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawThresholdArea.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawZoneChart.php b/notFinishedCode/pChart2.1.2/examples/example.drawZoneChart.php
new file mode 100644
index 0000000..c1e82b0
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawZoneChart.php
@@ -0,0 +1,61 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ for($i=0; $i<=10;$i=$i+.2)
+ {
+ $MyData->addPoints(log($i+1)*10,"Bounds 1");
+ $MyData->addPoints(log($i+3)*10+rand(0,2)-1,"Probe");
+ $MyData->addPoints(log($i+6)*10,"Bounds 2");
+ $MyData->addPoints($i*10,"Labels");
+ }
+ $MyData->setAxisName(0,"Size (cm)");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+ $MyData->setAbscissaName("Time (years)");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Size by time generations",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(40,40,680,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("LabelSkip"=>4,"XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw the line chart */
+ $myPicture->drawZoneChart("Bounds 1","Bounds 2");
+ $MyData->setSerieDrawable(array("Bounds 1","Bounds 2"),FALSE);
+
+ /* Draw the line chart */
+ $myPicture->drawStepChart();
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(640,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawZoneChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.drawingObjects.php b/notFinishedCode/pChart2.1.2/examples/example.drawingObjects.php
new file mode 100644
index 0000000..158362a
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.drawingObjects.php
@@ -0,0 +1,50 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Define default font settings */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>14));
+
+ /* Create the background */
+ $myPicture->drawGradientArea(0,0,500,230,DIRECTION_HORIZONTAL,array("StartR"=>217,"StartG"=>250,"StartB"=>116,"EndR"=>181,"EndG"=>209,"EndB"=>27,"Alpha"=>100));
+ $RectangleSettings = array("R"=>181,"G"=>209,"B"=>27,"Alpha"=>100);
+ $myPicture->drawFilledRectangle(500,0,700,230,$RectangleSettings);
+
+ /* Enable shadow computing on a (+1,+1) basis */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw the left area */
+ $RectangleSettings = array("R"=>181,"G"=>209,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRoundedFilledRectangle(-5,0,20,240,10,$RectangleSettings);
+ $TextSettings = array("R"=>255,"G"=>255,"B"=>255,"Angle"=>90,"Align"=>TEXT_ALIGN_MIDDLELEFT);
+ $myPicture->drawText(10,220,"My first chart",$TextSettings);
+
+ /* Draw the right area */
+ $RectangleSettings = array("R"=>191,"G"=>219,"B"=>37,"Alpha"=>100,"Surrounding"=>20,"Ticks"=>2);
+ $myPicture->drawFilledRectangle(510,10,689,219,$RectangleSettings);
+
+ /* Write the legend */
+ $TextSettings = array("R"=>255,"G"=>255,"B"=>255,"Align"=>TEXT_ALIGN_MIDDLEMIDDLE);
+ $myPicture->drawText(600,30,"Weather data",$TextSettings);
+ $TextSettings = array("R"=>106,"G"=>125,"B"=>3,"Align"=>TEXT_ALIGN_TOPLEFT,"FontSize"=>11);
+ $myPicture->drawText(520,45,"The data shown here has been",$TextSettings);
+ $myPicture->drawText(520,60,"collected from European locations",$TextSettings);
+ $myPicture->drawText(520,75,"by the French NAVI system.",$TextSettings);
+ $myPicture->drawFromPNG(540,90,"resources/blocnote.png");
+
+ /* Disable shadow computing */
+ $myPicture->setShadow(FALSE);
+
+ /* Draw the picture border */
+ $RectangleSettings = array("R"=>181,"G"=>209,"B"=>27,"Alpha"=>100);
+ $myPicture->drawRectangle(0,0,699,229,$RectangleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.drawingObjects.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.normalize.php b/notFinishedCode/pChart2.1.2/examples/example.normalize.php
new file mode 100644
index 0000000..3ea8908
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.normalize.php
@@ -0,0 +1,42 @@
+<?php
+ /* CAT:Mathematical */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Frontend #1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Frontend #2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Frontend #3");
+ $MyData->setAxisName(0,"Average Usage");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Normalize the data series to 100% */
+ $MyData->normalize(100,"%");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>240,"StartG"=>240,"StartB"=>240,"EndR"=>180,"EndG"=>180,"EndB"=>180,"Alpha"=>20));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Draw the scale and the chart */
+ $myPicture->setGraphArea(60,20,680,190);
+ $myPicture->drawScale(array("DrawSubTicks"=>TRUE,"Mode"=>SCALE_MODE_ADDALL));
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawStackedBarChart(array("DisplayValues"=>TRUE,"DisplayColor"=>DISPLAY_AUTO,"Rounded"=>FALSE,"Surrounding"=>60));
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(480,210,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.normalize.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.pData.php b/notFinishedCode/pChart2.1.2/examples/example.pData.php
new file mode 100644
index 0000000..a4560e4
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.pData.php
@@ -0,0 +1,46 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(24,25,26,25,25),"My Serie 1");
+ $MyData->addPoints(array(12,13,14,16,18),"My Serie 2");
+ $MyData->addPoints(array(80,76,73,71,33),"My Serie 3");
+ $MyData->addPoints(array(47,67,78,76,54),"My Serie 4");
+
+ /* Define the series name */
+ $MyData->setSerieDescription("My Serie 1","Temperature");
+ $MyData->setSerieDescription("My Serie 2","Humidity");
+
+ /* Dispatche the series on different axis */
+ $MyData->setSerieOnAxis("My Serie 1",1);
+ $MyData->setSerieOnAxis("My Serie 2",1);
+ $MyData->setSerieOnAxis("My Serie 3",2);
+ $MyData->setSerieOnAxis("My Serie 4",2);
+
+ /* Set the format of the axis */
+ $MyData->setAxisDisplay(1,AXIS_FORMAT_DEFAULT);
+ $MyData->setAxisDisplay(2,AXIS_FORMAT_DEFAULT);
+ $MyData->setAxisDisplay(1,AXIS_FORMAT_TIME,"H:i");
+
+ /* Set the unit of the axis */
+ $MyData->setAxisUnit(1,"°C");
+ $MyData->setAxisUnit(2,"%");
+
+ /* Set the name of the axis */
+ $MyData->setAxisName(1,"Temperature");
+ $MyData->setAxisName(2,"Humidity");
+
+ /* Change the color of one serie */
+ $serieSettings = array("R"=>229,"G"=>11,"B"=>11,"Alpha"=>80);
+ $MyData->setPalette("My Serie 4",$serieSettings);
+
+ /* Load a palette file */
+ $MyData->loadPalette("resources/palette.txt",FALSE);
+
+ /* Output the data structure */
+ print_r($MyData->getData());
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.polar.php b/notFinishedCode/pChart2.1.2/examples/example.polar.php
new file mode 100644
index 0000000..c56a7e4
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.polar.php
@@ -0,0 +1,65 @@
+<?php
+ /* CAT:Polar and radars */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pRadar.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(10,20,30,40,50,60,70,80,90),"ScoreA");
+ $MyData->addPoints(array(20,40,50,12,10,30,40,50,60),"ScoreB");
+ $MyData->setSerieDescription("ScoreA","Coverage A");
+ $MyData->setSerieDescription("ScoreB","Coverage B");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array(40,80,120,160,200,240,280,320,360),"Coord");
+ $MyData->setAbscissa("Coord");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw a solid background */
+ $Settings = array("R"=>179, "G"=>217, "B"=>91, "Dash"=>1, "DashR"=>199, "DashG"=>237, "DashB"=>111);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay some gradient areas */
+ $Settings = array("StartR"=>194, "StartG"=>231, "StartB"=>44, "EndR"=>43, "EndG"=>107, "EndB"=>58, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pRadar - Draw polar charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pRadar object */
+ $SplitChart = new pRadar();
+
+ /* Draw a polar chart */
+ $myPicture->setGraphArea(10,25,340,225);
+ $Options = array("BackgroundGradient"=>array("StartR"=>255,"StartG"=>255,"StartB"=>255,"StartAlpha"=>100,"EndR"=>207,"EndG"=>227,"EndB"=>125,"EndAlpha"=>50), "FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6);
+ $SplitChart->drawPolar($myPicture,$MyData,$Options);
+
+ /* Draw a polar chart */
+ $myPicture->setGraphArea(350,25,690,225);
+ $Options = array("LabelPos"=>RADAR_LABELS_HORIZONTAL,"BackgroundGradient"=>array("StartR"=>255,"StartG"=>255,"StartB"=>255,"StartAlpha"=>50,"EndR"=>32,"EndG"=>109,"EndB"=>174,"EndAlpha"=>30),"AxisRotation"=>0,"DrawPoly"=>TRUE,"PolyAlpha"=>50, "FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6);
+ $SplitChart->drawPolar($myPicture,$MyData,$Options);
+
+ /* Write the chart legend */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawLegend(270,205,array("Style"=>LEGEND_BOX,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.polar.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.polar.values.php b/notFinishedCode/pChart2.1.2/examples/example.polar.values.php
new file mode 100644
index 0000000..92c393b
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.polar.values.php
@@ -0,0 +1,51 @@
+<?php
+ /* CAT:Polar and radars */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pRadar.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(10,20,30,40,50,60,70,80,90),"ScoreA");
+ $MyData->addPoints(array(20,40,50,30,10,30,40,50,60),"ScoreB");
+ $MyData->setSerieDescription("ScoreA","Coverage A");
+ $MyData->setSerieDescription("ScoreB","Coverage B");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array(40,80,120,160,200,240,280,320,360),"Coord");
+ $MyData->setAbscissa("Coord");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,300,$MyData);
+ $myPicture->drawGradientArea(0,0,300,300,DIRECTION_VERTICAL,array("StartR"=>200,"StartG"=>200,"StartB"=>200,"EndR"=>240,"EndG"=>240,"EndB"=>240,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,300,20,DIRECTION_HORIZONTAL,array("StartR"=>30,"StartG"=>30,"StartB"=>30,"EndR"=>100,"EndG"=>100,"EndB"=>100,"Alpha"=>100));
+ $myPicture->drawLine(0,20,300,20,array("R"=>255,"G"=>255,"B"=>255));
+ $RectangleSettings = array("R"=>180,"G"=>180,"B"=>180,"Alpha"=>100);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,299,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pRadar - Draw radar charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(FALSE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pRadar object */
+ $SplitChart = new pRadar();
+
+ /* Draw a radar chart */
+ $myPicture->setGraphArea(10,25,290,290);
+ $Options = array("DrawPoly"=>TRUE,"WriteValues"=>TRUE,"ValueFontSize"=>8,"Layout"=>RADAR_LAYOUT_CIRCLE,"BackgroundGradient"=>array("StartR"=>255,"StartG"=>255,"StartB"=>255,"StartAlpha"=>100,"EndR"=>207,"EndG"=>227,"EndB"=>125,"EndAlpha"=>50));
+ $SplitChart->drawPolar($myPicture,$MyData,$Options);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.polar.values.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.radar.labels.php b/notFinishedCode/pChart2.1.2/examples/example.radar.labels.php
new file mode 100644
index 0000000..c20a8f1
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.radar.labels.php
@@ -0,0 +1,50 @@
+<?php
+ /* CAT:Polar and radars */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pRadar.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(4,4,10,10,4,4,15,15,4,4,10,10,4,4,15,15,4,4,10,10,4,4,15,15),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+ $MyData->setPalette("ScoreA",array("R"=>150,"G"=>5,"B"=>217));
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array(1,2,3,4,5,6,7,8,9,10,11,12,13,14,15,16,17,18,19,20,21,22,23,24),"Time");
+ $MyData->setAbscissa("Time");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,300,$MyData);
+ $myPicture->drawGradientArea(0,0,300,300,DIRECTION_VERTICAL,array("StartR"=>200,"StartG"=>200,"StartB"=>200,"EndR"=>240,"EndG"=>240,"EndB"=>240,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,300,20,DIRECTION_HORIZONTAL,array("StartR"=>30,"StartG"=>30,"StartB"=>30,"EndR"=>100,"EndG"=>100,"EndB"=>100,"Alpha"=>100));
+ $myPicture->drawLine(0,20,300,20,array("R"=>255,"G"=>255,"B"=>255));
+ $RectangleSettings = array("R"=>180,"G"=>180,"B"=>180,"Alpha"=>100);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,299,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pRadar - Draw radar charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pRadar object */
+ $SplitChart = new pRadar();
+
+ /* Draw a radar chart */
+ $myPicture->setGraphArea(10,25,290,290);
+ $Options = array("SkipLabels"=>3,"LabelMiddle"=>TRUE,"Layout"=>RADAR_LAYOUT_STAR,"BackgroundGradient"=>array("StartR"=>255,"StartG"=>255,"StartB"=>255,"StartAlpha"=>100,"EndR"=>207,"EndG"=>227,"EndB"=>125,"EndAlpha"=>50));
+ $SplitChart->drawRadar($myPicture,$MyData,$Options);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.radar.labels.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.radar.php b/notFinishedCode/pChart2.1.2/examples/example.radar.php
new file mode 100644
index 0000000..c7bd194
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.radar.php
@@ -0,0 +1,67 @@
+<?php
+ /* CAT:Polar and radars */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pRadar.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(40,20,15,10,8,4),"ScoreA");
+ $MyData->addPoints(array(8,10,12,20,30,15),"ScoreB");
+ $MyData->addPoints(array(4,8,16,32,16,8),"ScoreC");
+ $MyData->setSerieDescription("ScoreA","Application A");
+ $MyData->setSerieDescription("ScoreB","Application B");
+ $MyData->setSerieDescription("ScoreC","Application C");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("Size","Speed","Reliability","Functionalities","Ease of use","Weight"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Draw a solid background */
+ $Settings = array("R"=>179, "G"=>217, "B"=>91, "Dash"=>1, "DashR"=>199, "DashG"=>237, "DashB"=>111);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay some gradient areas */
+ $Settings = array("StartR"=>194, "StartG"=>231, "StartB"=>44, "EndR"=>43, "EndG"=>107, "EndB"=>58, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pRadar - Draw radar charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pRadar object */
+ $SplitChart = new pRadar();
+
+ /* Draw a radar chart */
+ $myPicture->setGraphArea(10,25,300,225);
+ $Options = array("Layout"=>RADAR_LAYOUT_STAR,"BackgroundGradient"=>array("StartR"=>255,"StartG"=>255,"StartB"=>255,"StartAlpha"=>100,"EndR"=>207,"EndG"=>227,"EndB"=>125,"EndAlpha"=>50), "FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6);
+ $SplitChart->drawRadar($myPicture,$MyData,$Options);
+
+ /* Draw a radar chart */
+ $myPicture->setGraphArea(390,25,690,225);
+ $Options = array("Layout"=>RADAR_LAYOUT_CIRCLE,"LabelPos"=>RADAR_LABELS_HORIZONTAL,"BackgroundGradient"=>array("StartR"=>255,"StartG"=>255,"StartB"=>255,"StartAlpha"=>50,"EndR"=>32,"EndG"=>109,"EndB"=>174,"EndAlpha"=>30), "FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6);
+ $SplitChart->drawRadar($myPicture,$MyData,$Options);
+
+ /* Write the chart legend */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawLegend(235,205,array("Style"=>LEGEND_BOX,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.radar.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.radar.values.php b/notFinishedCode/pChart2.1.2/examples/example.radar.values.php
new file mode 100644
index 0000000..bd00592
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.radar.values.php
@@ -0,0 +1,50 @@
+<?php
+ /* CAT:Polar and radars */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pRadar.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(8,4,6,4,2,7),"Score");
+ $MyData->setSerieDescription("Score","Application A");
+ $MyData->setPalette("Score",array("R"=>157,"G"=>196,"B"=>22));
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("Speed","Weight","Cost","Size","Ease","Utility"),"Families");
+ $MyData->setAbscissa("Families");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,300,$MyData);
+ $myPicture->drawGradientArea(0,0,300,300,DIRECTION_VERTICAL,array("StartR"=>200,"StartG"=>200,"StartB"=>200,"EndR"=>240,"EndG"=>240,"EndB"=>240,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,300,20,DIRECTION_HORIZONTAL,array("StartR"=>30,"StartG"=>30,"StartB"=>30,"EndR"=>100,"EndG"=>100,"EndB"=>100,"Alpha"=>100));
+ $myPicture->drawLine(0,20,300,20,array("R"=>255,"G"=>255,"B"=>255));
+ $RectangleSettings = array("R"=>180,"G"=>180,"B"=>180,"Alpha"=>100);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,299,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pRadar - Draw radar charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pRadar object */
+ $SplitChart = new pRadar();
+
+ /* Draw a radar chart */
+ $myPicture->setGraphArea(10,25,290,290);
+ $Options = array("DrawPoly"=>TRUE,"WriteValues"=>TRUE,"ValueFontSize"=>8,"Layout"=>RADAR_LAYOUT_CIRCLE,"BackgroundGradient"=>array("StartR"=>255,"StartG"=>255,"StartB"=>255,"StartAlpha"=>100,"EndR"=>207,"EndG"=>227,"EndB"=>125,"EndAlpha"=>50));
+ $SplitChart->drawRadar($myPicture,$MyData,$Options);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.radar.values.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.setFontProperties.php b/notFinishedCode/pChart2.1.2/examples/example.setFontProperties.php
new file mode 100644
index 0000000..31464f0
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.setFontProperties.php
@@ -0,0 +1,56 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"setFontProperties() - set default font properties",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Write some text */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/advent_light.ttf","FontSize"=>20));
+ $myPicture->drawText(60,115,"10 degree text",array("Angle"=>10));
+
+ /* Write some text */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/calibri.ttf","FontSize"=>20));
+ $myPicture->drawText(75,130,"10 degree text",array("Angle"=>10));
+
+ /* Write some text */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/GeosansLight.ttf","FontSize"=>20));
+ $myPicture->drawText(90,145,"10 degree text",array("Angle"=>10));
+
+ /* Write some text */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/MankSans.ttf","FontSize"=>20));
+ $myPicture->drawText(105,160,"10 degree text",array("Angle"=>10));
+
+ /* Write some text */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/MankSans.ttf","FontSize"=>30,"R"=>231,"G"=>50,"B"=>36));
+ $myPicture->drawText(340,90,"Some big red text");
+
+ /* Write some text */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6,"R"=>29,"G"=>70,"B"=>111));
+ $myPicture->drawText(340,100,"Some blue text");
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.setFontProperties.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.setShadow.php b/notFinishedCode/pChart2.1.2/examples/example.setShadow.php
new file mode 100644
index 0000000..80dd726
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.setShadow.php
@@ -0,0 +1,44 @@
+<?php
+ /* CAT:Drawing */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"setShadow() - Add shadows",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a filled circle */
+ $formSettings = array("R"=>201,"G"=>230,"B"=>40,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawFilledCircle(90,120,30,$formSettings);
+
+ /* Draw a filled rectangle */
+ $formSettings = array("R"=>231,"G"=>197,"B"=>40,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawFilledRectangle(160,90,280,150,$formSettings);
+
+ /* Draw a filled rounded rectangle */
+ $formSettings = array("R"=>231,"G"=>102,"B"=>40,"Alpha"=>100,"Surrounding"=>70);
+ $myPicture->drawRoundedFilledRectangle(320,90,440,150,5,$formSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.setShadow.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.singlebarcode128.php b/notFinishedCode/pChart2.1.2/examples/example.singlebarcode128.php
new file mode 100644
index 0000000..658e0bc
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.singlebarcode128.php
@@ -0,0 +1,30 @@
+<?php
+ /* CAT:Barcode */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pBarcode128.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the barcode 128 object */
+ $Barcode = new pBarcode128("../");
+
+ /* String to be written on the barcode */
+ $String = "This is a test";
+
+ /* Retrieve the barcode projected size */
+ $Settings = array("ShowLegend"=>TRUE,"DrawArea"=>TRUE);
+ $Size = $Barcode->getSize($String,$Settings);
+
+ /* Create the pChart object */
+ $myPicture = new pImage($Size["Width"],$Size["Height"]);
+
+ /* Set the font to use */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/GeosansLight.ttf"));
+
+ /* Render the barcode */
+ $Barcode->draw($myPicture,$String,10,10,$Settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.singlebarcode128.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.singlebarcode39.php b/notFinishedCode/pChart2.1.2/examples/example.singlebarcode39.php
new file mode 100644
index 0000000..9ced3a3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.singlebarcode39.php
@@ -0,0 +1,30 @@
+<?php
+ /* CAT:Barcode */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pBarcode39.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the barcode 39 object */
+ $Barcode = new pBarcode39("../");
+
+ /* String to be written on the barcode */
+ $String = "This is a test";
+
+ /* Retrieve the barcode projected size */
+ $Settings = array("ShowLegend"=>TRUE,"DrawArea"=>TRUE);
+ $Size = $Barcode->getSize($String,$Settings);
+
+ /* Create the pChart object */
+ $myPicture = new pImage($Size["Width"],$Size["Height"]);
+
+ /* Set the font to use */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/GeosansLight.ttf"));
+
+ /* Render the barcode */
+ $Barcode->draw($myPicture,$String,10,10,$Settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.singlebarcode39.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.split.php b/notFinishedCode/pChart2.1.2/examples/example.split.php
new file mode 100644
index 0000000..2d4a770
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.split.php
@@ -0,0 +1,62 @@
+<?php
+ /* CAT:Split chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pSplit.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pSplit - Draw splitted path charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(30,20,15,10,8,4),"Score");
+ $MyData->addPoints(array("End of visit","Home Page","Product Page","Sales","Statistics","Prints"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pSplit object */
+ $SplitChart = new pSplit();
+
+ /* Draw the split chart */
+ $Settings = array("TextPos"=>TEXT_POS_RIGHT,"TextPadding"=>10,"Spacing"=>20,"Surrounding"=>40);
+ $myPicture->setGraphArea(10,20,340,230);
+ $SplitChart->drawSplitPath($myPicture,$MyData,$Settings);
+
+ /* Create and populate the pData object */
+ $MyData2 = new pData();
+ $MyData2->addPoints(array(30,20,15),"Score");
+ $MyData2->addPoints(array("UK","FR","ES"),"Labels");
+ $MyData2->setAbscissa("Labels");
+
+ /* Draw the split chart */
+ $Settings = array("TextPadding"=>4,"Spacing"=>30,"Surrounding"=>20);
+ $myPicture->setGraphArea(350,50,690,200);
+ $SplitChart->drawSplitPath($myPicture,$MyData2,$Settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.split.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.spring.complex.php b/notFinishedCode/pChart2.1.2/examples/example.spring.complex.php
new file mode 100644
index 0000000..ac38ae8
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.spring.complex.php
@@ -0,0 +1,66 @@
+<?php
+ /* CAT:Spring chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pSpring.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(600,600);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,600,600,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,600,600,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,600,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>100,"EndG"=>100,"EndB"=>100,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,599,599,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pSpring - Draw spring charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the graph area boundaries*/
+ $myPicture->setGraphArea(20,20,580,580);
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>9,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pSpring object */
+ $SpringChart = new pSpring();
+
+ /* Set the default parameters for newly added nodes */
+ $SpringChart->setNodeDefaults(array("FreeZone"=>70));
+
+ /* Create 11 random nodes */
+ for($i=0;$i<=10;$i++)
+ {
+ $Connections = ""; $RdCx = rand(0,1);
+ for($j=0;$j<=$RdCx;$j++)
+ {
+ $RandCx = rand(0,10);
+ if ( $RandCx != $j )
+ { $Connections[] = $RandCx; }
+ }
+
+ $SpringChart->addNode($i,array("Name"=>"Node ".$i,"Connections"=>$Connections));
+ }
+
+ /* Draw the spring chart */
+ $Result = $SpringChart->drawSpring($myPicture,array("DrawQuietZone"=>TRUE,"Algorithm"=>ALGORITHM_CIRCULAR,"RingSize"=>100)); //WEIGHTED
+
+ /* Output the statistics */
+ // print_r($Result);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.spring.complex.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.spring.labels.php b/notFinishedCode/pChart2.1.2/examples/example.spring.labels.php
new file mode 100644
index 0000000..2e9bad6
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.spring.labels.php
@@ -0,0 +1,67 @@
+<?php
+ /* CAT:Spring chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pSpring.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,300);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,300,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,300,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>100,"EndG"=>100,"EndB"=>100,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,299,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pSpring - Draw spring charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the graph area boundaries*/
+ $myPicture->setGraphArea(20,20,280,280);
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>9,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pSpring object */
+ $SpringChart = new pSpring();
+
+ /* Set the default parameters for newly added nodes */
+ $SpringChart->setNodeDefaults(array("FreeZone"=>100));
+
+ /* Create some nodes */
+ $SpringChart->addNode(0,array("Shape"=>NODE_SHAPE_TRIANGLE,"FreeZone"=>60,"Size"=>20,"NodeType"=>NODE_TYPE_CENTRAL));
+ $SpringChart->addNode(1,array("Connections"=>"0"));
+ $SpringChart->addNode(2,array("Connections"=>"0"));
+ $SpringChart->addNode(3,array("Connections"=>"2"));
+
+ /* Set the nodes color */
+ $SpringChart->setNodesColor(0,array("R"=>215,"G"=>163,"B"=>121,"BorderR"=>166,"BorderG"=>115,"BorderB"=>74));
+ $SpringChart->setNodesColor(array(1,2,3),array("R"=>150,"G"=>215,"B"=>121,"Surrounding"=>-30));
+
+ /* Set the link properties */
+ $SpringChart->linkProperties(0,1,array("Name"=>"Synchronous","R"=>255,"G"=>0,"B"=>0));
+ $SpringChart->linkProperties(0,2,array("Name"=>"Asynchronous","R"=>255,"G"=>0,"B"=>0,"Ticks"=>2));
+ $SpringChart->linkProperties(3,2,array("Name"=>"Mixed","Ticks"=>4));
+
+ /* Draw the spring chart */
+ $Result = $SpringChart->drawSpring($myPicture);
+
+ /* Output the statistics */
+ // print_r($Result);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.spring.labels.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.spring.php b/notFinishedCode/pChart2.1.2/examples/example.spring.php
new file mode 100644
index 0000000..c48f3ba
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.spring.php
@@ -0,0 +1,65 @@
+<?php
+ /* CAT:Spring chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pSpring.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,300);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,300,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,300,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>100,"EndG"=>100,"EndB"=>100,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,299,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pSpring - Draw spring charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the graph area boundaries*/
+ $myPicture->setGraphArea(20,20,280,280);
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>9,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pSpring object */
+ $SpringChart = new pSpring();
+
+ /* Create some nodes */
+ $SpringChart->addNode("0",array("Name"=>"","Shape"=>NODE_SHAPE_SQUARE,"FreeZone"=>60,"Size"=>20,"NodeType"=>NODE_TYPE_CENTRAL));
+ $SpringChart->addNode("1",array("Name"=>"Johanna","Connections"=>array("0")));
+ $SpringChart->addNode("2",array("Name"=>"Martin","Connections"=>array("0")));
+ $SpringChart->addNode("3",array("Name"=>"Kevin","Connections"=>array("1")));
+ $SpringChart->addNode("4",array("Name"=>"Alex","Connections"=>array("1")));
+ $SpringChart->addNode("5",array("Name"=>"Julia","Connections"=>array("1")));
+ $SpringChart->addNode("6",array("Name"=>"Lena","Connections"=>array("2")));
+ $SpringChart->addNode("7",array("Name"=>"Elisa","Connections"=>array("2")));
+ $SpringChart->addNode("8",array("Name"=>"Omar","Connections"=>array("2")));
+
+ /* Set the nodes color */
+ $SpringChart->setNodesColor(array(0),array("R"=>215,"G"=>163,"B"=>121,"BorderR"=>166,"BorderG"=>115,"BorderB"=>74));
+ $SpringChart->setNodesColor(array(1,5,6,7),array("R"=>245,"G"=>183,"B"=>241,"Surrounding"=>-30));
+ $SpringChart->setNodesColor(array(2,3,4,8),array("R"=>183,"G"=>224,"B"=>245,"Surrounding"=>-30));
+
+ /* Draw the spring chart */
+ $Result = $SpringChart->drawSpring($myPicture,array("DrawQuietZone"=>TRUE));
+
+ /* Output the statistics */
+ // print_r($Result);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.spring.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.spring.relations.php b/notFinishedCode/pChart2.1.2/examples/example.spring.relations.php
new file mode 100644
index 0000000..655fe67
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.spring.relations.php
@@ -0,0 +1,70 @@
+<?php
+ /* CAT:Spring chart */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pSpring.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,300);
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,300,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,300,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>100,"EndG"=>100,"EndB"=>100,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,299,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"pSpring - Draw spring charts",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Set the graph area boundaries*/
+ $myPicture->setGraphArea(20,20,280,280);
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>9,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pSpring object */
+ $SpringChart = new pSpring();
+
+ /* Create some nodes */
+ $SpringChart->addNode(0,array("Shape"=>NODE_SHAPE_SQUARE,"FreeZone"=>60,"Size"=>20,"NodeType"=>NODE_TYPE_CENTRAL));
+ $SpringChart->addNode(1,array("Connections"=>"0"));
+ $SpringChart->addNode(2,array("Connections"=>"0"));
+ $SpringChart->addNode(3,array("Shape"=>NODE_SHAPE_TRIANGLE,"Connections"=>"1"));
+ $SpringChart->addNode(4,array("Shape"=>NODE_SHAPE_TRIANGLE,"Connections"=>"1"));
+ $SpringChart->addNode(5,array("Shape"=>NODE_SHAPE_TRIANGLE,"Connections"=>"1"));
+ $SpringChart->addNode(6,array("Connections"=>"2"));
+ $SpringChart->addNode(7,array("Connections"=>"2"));
+ $SpringChart->addNode(8,array("Connections"=>"2"));
+
+ /* Set the nodes color */
+ $SpringChart->setNodesColor(0,array("R"=>215,"G"=>163,"B"=>121,"BorderR"=>166,"BorderG"=>115,"BorderB"=>74));
+ $SpringChart->setNodesColor(array(1,2),array("R"=>150,"G"=>215,"B"=>121,"Surrounding"=>-30));
+ $SpringChart->setNodesColor(array(3,4,5),array("R"=>216,"G"=>166,"B"=>14,"Surrounding"=>-30));
+ $SpringChart->setNodesColor(array(6,7,8),array("R"=>179,"G"=>121,"B"=>215,"Surrounding"=>-30));
+
+ /* Set the link properties */
+ $SpringChart->linkProperties(0,1,array("R"=>255,"G"=>0,"B"=>0,"Ticks"=>2));
+ $SpringChart->linkProperties(0,2,array("R"=>255,"G"=>0,"B"=>0,"Ticks"=>2));
+
+ /* Draw the spring chart */
+ $Result = $SpringChart->drawSpring($myPicture);
+
+ /* Output the statistics */
+ // print_r($Result);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.spring.relations.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.text.alignment.php b/notFinishedCode/pChart2.1.2/examples/example.text.alignment.php
new file mode 100644
index 0000000..2cdd7d8
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.text.alignment.php
@@ -0,0 +1,67 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(550,175);
+
+ /* Create a solid background */
+ $Settings = array("R"=>183, "G"=>161, "B"=>71, "Dash"=>1, "DashR"=>203, "DashG"=>181, "DashB"=>91);
+ $myPicture->drawFilledRectangle(0,0,550,175,$Settings);
+
+ /* Do a gradient overlay */
+ $Settings = array("StartR"=>231, "StartG"=>228, "StartB"=>155, "EndR"=>138, "EndG"=>91, "EndB"=>10, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,550,175,DIRECTION_VERTICAL,$Settings);
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/calibri.ttf","FontSize"=>20));
+
+ /* Draw the text box */
+ $myPicture->setShadow(FALSE);
+ $myPicture->drawFilledRectangle(141,77,393,126,array("Alpha"=>20,"R"=>230,"G"=>230,"B"=>230));
+ $myPicture->drawRectangle(141,77,393,126,array("R"=>50,"G"=>50,"B"=>50));
+
+ /* Write the text */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+ $TextSettings = array("R"=>201,"G"=>230,"B"=>40,"FontSize"=>40);
+ $myPicture->drawText(144,125,"My text box",$TextSettings);
+
+ /* Prepare and draw the markers */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+ $MyMarkerSettings = array("R"=>255,"G"=>0,"B"=>0,"BorderR"=>0,"BorderB"=>0,"BorderG"=>0,"Size"=>4);
+
+ $myPicture->drawRectangleMarker(141,77,$MyMarkerSettings);
+ $myPicture->drawRectangleMarker(141,101,$MyMarkerSettings);
+ $myPicture->drawRectangleMarker(141,126,$MyMarkerSettings);
+
+ $myPicture->drawRectangleMarker(260,77,$MyMarkerSettings);
+ $myPicture->drawRectangleMarker(260,101,$MyMarkerSettings);
+ $myPicture->drawRectangleMarker(260,126,$MyMarkerSettings);
+
+ $myPicture->drawRectangleMarker(393,77,$MyMarkerSettings);
+ $myPicture->drawRectangleMarker(393,101,$MyMarkerSettings);
+ $myPicture->drawRectangleMarker(393,126,$MyMarkerSettings);
+
+ /* Change the font settings */
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/calibri.ttf","FontSize"=>7));
+ $myPicture->setShadow(FALSE);
+
+ /* Write the arrows */
+ $myPicture->drawArrowLabel(139,75,"TEXT_ALIGN_TOPLEFT",array("Length"=>20,"Angle"=>45,"RoundPos"=>TRUE));
+ $myPicture->drawArrowLabel(139,101,"TEXT_ALIGN_MIDDLELEFT",array("Length"=>20,"Angle"=>90,"RoundPos"=>TRUE));
+ $myPicture->drawArrowLabel(139,128,"TEXT_ALIGN_BOTTOMLEFT",array("Length"=>20,"Angle"=>135,"RoundPos"=>TRUE));
+
+ $myPicture->drawArrowLabel(260,75,"TEXT_ALIGN_TOPMIDDLE",array("Length"=>20,"Angle"=>45,"RoundPos"=>TRUE));
+ $myPicture->drawArrowLabel(260,101,"TEXT_ALIGN_MIDDLEMIDDLE",array("Length"=>90,"Angle"=>315,"RoundPos"=>TRUE));
+ $myPicture->drawArrowLabel(260,128,"TEXT_ALIGN_BOTTOMMIDDLE",array("Length"=>20,"Angle"=>225,"RoundPos"=>TRUE));
+
+ $myPicture->drawArrowLabel(395,75,"TEXT_ALIGN_TOPRIGHT",array("Length"=>20,"Angle"=>315,"RoundPos"=>TRUE));
+ $myPicture->drawArrowLabel(395,101,"TEXT_ALIGN_MIDDLERIGHT",array("Length"=>20,"Angle"=>270,"RoundPos"=>TRUE));
+ $myPicture->drawArrowLabel(395,128,"TEXT_ALIGN_BOTTOMRIGHT",array("Length"=>20,"Angle"=>225,"RoundPos"=>TRUE));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.spring.relations.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.transparent.background.php b/notFinishedCode/pChart2.1.2/examples/example.transparent.background.php
new file mode 100644
index 0000000..3d261b4
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.transparent.background.php
@@ -0,0 +1,36 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,NULL,TRUE);
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>31,"B"=>27,"Alpha"=>50,"Surrounding"=>30);
+ $myPicture->drawRoundedFilledRectangle(10,25,70,55,5,$RectangleSettings);
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>125,"B"=>27,"Alpha"=>50,"Surrounding"=>30);
+ $myPicture->drawRoundedFilledRectangle(10,85,70,115,5,$RectangleSettings);
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>198,"B"=>27,"Alpha"=>50,"Surrounding"=>30);
+ $myPicture->drawRoundedFilledRectangle(10,135,70,165,5,$RectangleSettings);
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>134,"G"=>209,"B"=>27,"Alpha"=>50,"Surrounding"=>30);
+ $myPicture->drawRoundedFilledRectangle(10,185,70,215,5,$RectangleSettings);
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Draw a rounded filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>198,"B"=>27,"Alpha"=>100,"Surrounding"=>30,"Radius"=>20);
+ $myPicture->drawRoundedFilledRectangle(100,20,680,210,20,$RectangleSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.transparent.background.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/example.writeBounds.php b/notFinishedCode/pChart2.1.2/examples/example.writeBounds.php
new file mode 100644
index 0000000..5e831a0
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.writeBounds.php
@@ -0,0 +1,67 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(800,630); //result image size
+ $myPicture->drawGradientArea(0,0,800,630,DIRECTION_VERTICAL,array("StartR"=>100,"StartG"=>100,"StartB"=>100,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));//make gradient
+ $myPicture->drawGradientArea(0,0,800,630,DIRECTION_HORIZONTAL,array("StartR"=>100,"StartG"=>100,"StartB"=>100,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>20));//make gradient
+ $myPicture->drawGradientArea(0,0,60,630,DIRECTION_HORIZONTAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));//black gradient field on left
+
+ /* Do some cosmetics, add the black outlining and the name of the picture on left side*/
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawLine(60,0,60,230,array("R"=>70,"G"=>70,"B"=>70));
+ $myPicture->drawRectangle(0,0,799,629,array("R"=>0,"G"=>0,"B"=>0));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(30,400,"Network test results - UNIVERSITY OF FREIBURG",array("R"=>255,"G"=>255,"B"=>255,"FontSize"=>20,"Angle"=>90,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ // add some picture somewhere :)
+ /* Draw a PNG object */
+ // x1, y1, x2, y2
+ //line to landline
+ $myPicture->drawLine(430, 390,430,560,array("R"=>0,"G"=>255,"B"=>0,"Ticks"=>8,"Weight"=>1));
+ $myPicture->drawFromPNG(400,550,"telephone.png");
+
+
+ //BTS1
+ $myPicture->drawLine(180, 70,420,330,array("R"=>0,"G"=>255,"B"=>0,"Ticks"=>8,"Weight"=>1));
+ $myPicture->drawFromPNG(160,60,"BTSCont.png");
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>6));
+ $TextSettings = array("DrawBox"=>TRUE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10);
+ $myPicture->drawText(70,140,"BTS1 STATUS: OK",$TextSettings);
+
+
+ //BTS2
+ $myPicture->drawLine(190, 320, 420,350,array("R"=>0,"G"=>255,"B"=>0,"Ticks"=>8,"Weight"=>1));
+ $myPicture->drawFromPNG(160,280,"BTSCont.png");
+ $myPicture->drawFromPNG(110,300,"newIcons/BTSNOK1.png");
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>6));
+ $TextSettings = array("DrawBox"=>TRUE,"R"=>255,"G"=>0,"B"=>0,"Angle"=>0,"FontSize"=>10);
+ $myPicture->drawText(70,360,"BTS2 STATUS: NOT OK",$TextSettings);
+
+
+ //BTS3
+ $myPicture->drawLine(200, 550,420,380,array("R"=>0,"G"=>255,"B"=>0,"Ticks"=>8,"Weight"=>1));
+ $myPicture->drawFromPNG(160,500,"BTSCont.png");
+
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/verdana.ttf","FontSize"=>6));
+ $TextSettings = array("DrawBox"=>TRUE,"R"=>255,"G"=>255,"B"=>255,"Angle"=>0,"FontSize"=>10);
+ $myPicture->drawText(70,580,"BTS3 STATUS: OK",$TextSettings);
+
+
+
+
+
+ $myPicture->drawFromPNG(380,280,"server.png");
+ //$myPicture->writeLabel("Testing",0);
+
+
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.writeBounds.png");
+?>
diff --git a/notFinishedCode/pChart2.1.2/examples/example.writeBounds.php.backup b/notFinishedCode/pChart2.1.2/examples/example.writeBounds.php.backup
new file mode 100644
index 0000000..c56480b
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/example.writeBounds.php.backup
@@ -0,0 +1,46 @@
+<?php
+ /* CAT:Misc */
+
+ /* pChart library inclusions */
+ include("../class/pData.class.php");
+ include("../class/pDraw.class.php");
+ include("../class/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(2,7,5,18,VOID,12,10,15,8,5,6,9),"Help Desk");
+ $MyData->setAxisName(0,"Incidents");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun","Jui","Aou","Sep","Oct","Nov","Dec"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,array("StartR"=>100,"StartG"=>100,"StartB"=>100,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_HORIZONTAL,array("StartR"=>100,"StartG"=>100,"StartB"=>100,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>20));
+ $myPicture->drawGradientArea(0,0,60,230,DIRECTION_HORIZONTAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>100));
+
+ /* Do some cosmetics */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $myPicture->drawLine(60,0,60,230,array("R"=>70,"G"=>70,"B"=>70));
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+ $myPicture->setFontProperties(array("FontName"=>"../fonts/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(35,115,"Recorded cases",array("R"=>255,"G"=>255,"B"=>255,"FontSize"=>20,"Angle"=>90,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Draw a spline chart */
+ $myPicture->setGraphArea(100,30,680,190);
+ $myPicture->drawFilledRectangle(100,30,680,190,array("R"=>255,"G"=>255,"B"=>255,"Alpha"=>20));
+ $myPicture->setFontProperties(array("R"=>255,"G"=>255,"B"=>255,"FontName"=>"../fonts/pf_arma_five.ttf","FontSize"=>6));
+ $myPicture->drawScale(array("AxisR"=>255,"AxisG"=>255,"AxisB"=>255,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE));
+ $myPicture->drawSplineChart();
+
+ /* Write the data bounds */
+ $myPicture->writeBounds();
+ $myPicture->setShadow(FALSE);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(630,215,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("pictures/example.writeBounds.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/imagemap.js b/notFinishedCode/pChart2.1.2/examples/imageMap/imagemap.js
new file mode 100644
index 0000000..860899d
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/imagemap.js
@@ -0,0 +1,256 @@
+ /*
+ imageMap - JS to handle image maps over pChart graphix
+
+ Version : 2.1.2
+ Made by : Jean-Damien POGOLOTTI
+ Last Update : 08/04/11
+
+ This file can be distributed under the license you can find at :
+
+ http://www.pchart.net/license
+
+ You can find the whole class documentation on the pChart web site.
+ */
+
+ var cX = 0;
+ var cY = 0;
+ var LastcX = null;
+ var LastcY = null;
+ var rX = 0;
+ var rY = 0;
+ var currentStatus = false;
+ var initialized = false;
+ var currentTooltipDivID = "";
+ var currentTitle = "";
+ var currentMessage = "";
+ var currentAlpha = 0;
+ var timerID = null;
+ var timerInterval = 10;
+ var timerStep = 5;
+ var currentTimerMode = 0;
+ var timerLock = false;
+ var SmoothMove = false;
+ var SmoothMoveFactor = 5;
+
+ /* Create an image map */
+ function createMap(imageMapID)
+ {
+ var testMAP = document.getElementById(imageMapID);
+ if ( testMAP != null ) { testMAP.parentNode.removeChild(testMAP); }
+
+ var element = document.createElement("MAP");
+
+ element.id = imageMapID;
+ element.name = imageMapID;
+ document.body.appendChild(element);
+ }
+
+ /* Create the tooltip div */
+ function createTooltipDiv(TooltipDivID)
+ {
+ var testDiv = document.getElementById(TooltipDivID);
+ if ( testDiv != null ) { return(0); }
+
+ var element = document.createElement("DIV");
+
+ element.id = TooltipDivID;
+ element.innerHTML = "";
+ element.style.display = "inline-block";
+ element.style.position = "absolute";
+ element.style.opacity = 0;
+ element.style.filter = "alpha(opacity=0)";
+
+ document.body.appendChild(element);
+ }
+
+ /* Hide the tooltip */
+ function hideDiv(TooltipDivID)
+ {
+ var element = document.getElementById(TooltipDivID);
+
+ fadeOut(TooltipDivID);
+ }
+
+ /* Show the tooltip */
+ function showDiv(TooltipDivID,Color,Title,Message)
+ {
+ var element = document.getElementById(TooltipDivID);
+
+ if ( currentTooltipDivID != TooltipDivID || currentTitle != Title || currentMessage != Message)
+ { createToolTip(TooltipDivID,Color,Title,Message); }
+
+ if ( !initialized ) { moveDiv(TooltipDivID); initialized = true; }
+
+ fadeIn(TooltipDivID);
+
+ currentTooltipDivID = TooltipDivID;
+ currentTitle = Title;
+ currentMessage = Message;
+ }
+
+ /* Move the div to the mouse location */
+ function moveDiv(TooltipDivID)
+ {
+ var element = document.getElementById(TooltipDivID);
+
+
+if(self.pageYOffset)
+ { rX = self.pageXOffset; rY = self.pageYOffset; }
+
+else if(document.documentElement && document.documentElement.scrollTop)
+ { rX = document.documentElement.scrollLeft; rY = document.documentElement.scrollTop; }
+
+else if(document.body)
+ { rX = document.body.scrollLeft; rY = document.body.scrollTop; }
+
+if(document.all)
+ {
+ cX += rX; cY += rY;
+ }
+
+ if ( SmoothMove && LastcX != null )
+ { cX = LastcX - (LastcX-cX)/4; cY = LastcY - (LastcY-cY)/SmoothMoveFactor; }
+
+ element.style.left = (cX+10) + "px";
+
+ element.style.top = (cY+10) + "px";
+
+ LastcX = cX; LastcY = cY;
+ }
+
+ /* Compute the tooltip HTML code */
+ function createToolTip(TooltipDivID,Color,Title,Message)
+ {
+ var element = document.getElementById(TooltipDivID);
+
+ var HTML = "<div style='border:2px solid #606060'><div style='background-color: #000000; font-family: tahoma; font-size: 11px; color: #ffffff; padding: 4px;'><b>"+Title+" &nbsp;</b></div>";
+ HTML += "<div style='background-color: #808080; border-top: 2px solid #606060; font-family: tahoma; font-size: 10px; color: #ffffff; padding: 2px;'>";
+ HTML += "<table style='border: 0px; padding: 0px; margin: 0px;'><tr valign='top'><td style='padding-top: 4px;'><table style='background-color: "+Color+"; border: 1px solid #000000; width: 9px; height: 9px; padding: 0px; margin: 0px; margin-right: 2px;'><tr><td></td></tr></table></td><td>"+Message+"</td></tr></table>";
+ HTML += "</div></div>";
+
+ element.innerHTML = HTML;
+ }
+
+ /* Bind an image map to a picture */
+ function bindMap(imageID,imageMapID)
+ {
+ var image = document.getElementById(imageID);
+ image.useMap = "#"+imageMapID;
+ }
+
+ /* Add an area to the specified image map */
+ function addArea(imageMapID,shapeType,coordsList,actionOver,actionOut)
+ {
+ var maps = document.getElementById(imageMapID);
+ var element = document.createElement("AREA");
+
+ element.shape = shapeType;
+ element.coords = coordsList;
+ element.onmouseover = function() { eval(actionOver); };
+ element.onmouseout = function() { eval(actionOut); };
+ maps.appendChild(element);
+ }
+
+ /* Retrieve the current cursor position Mozilla */
+ function UpdateCursorPosition(e)
+ {
+ cX = e.pageX; cY = e.pageY;
+ if ( currentStatus || timerID != null ) { moveDiv(currentTooltipDivID); }
+ }
+
+
+ /* Retrieve the current cursor position IE */
+ function UpdateCursorPositionDocAll(e)
+ {
+ cX = event.clientX; cY = event.clientY;
+ if ( currentStatus || timerID != null ) { moveDiv(currentTooltipDivID); }
+ }
+
+ /* Fade general functions */
+ function fadeIn(TooltipDivID) { currentTimerMode = 1; initialiseTimer(TooltipDivID); } function fadeOut(TooltipDivID) { currentTimerMode = 2; initialiseTimer(TooltipDivID); } function initialiseTimer(TooltipDivID)
+ { if ( timerID == null ) { timerID = setInterval("fade('"+TooltipDivID+"')",timerInterval); } }
+
+
+
+ /* Handle fading */
+ function fade(TooltipDivID)
+ {
+ var element = document.getElementById(TooltipDivID);
+
+ currentStatus = true;
+ if ( currentTimerMode == 1 ) /* Fade in */
+ {
+ currentAlpha = currentAlpha + timerStep;
+ if ( currentAlpha >= 100 ) { currentAlpha = 100; clearInterval(timerID); timerID = null; }
+ }
+ else if ( currentTimerMode == 2 ) /* Fade out */
+ {
+ currentAlpha = currentAlpha - timerStep;
+ if ( currentAlpha <= 0 ) { currentStatus = false; currentAlpha = 0; clearInterval(timerID); timerID = null; }
+ }
+
+ element.style.opacity = currentAlpha * .01;
+ element.style.filter = 'alpha(opacity=' +currentAlpha + ')';
+ }
+
+ /* Add a picture element that need ImageMap parsing */
+ function addImage(PictureID,ImageMapID,ImageMapURL)
+ {
+ createTooltipDiv('testDiv');
+ createMap(ImageMapID);
+ bindMap(PictureID,ImageMapID);
+
+ setTimeout("checkLoadingStatus('"+PictureID+"','"+ImageMapID+"','"+ImageMapURL+"')", 200);
+ }
+
+ /* Check the loading status of the image */
+ function checkLoadingStatus(PictureID,ImageMapID,ImageMapURL)
+ {
+ var element = document.getElementById(PictureID);
+
+ if ( element.complete == true )
+ downloadImageMap(PictureID,ImageMapID,ImageMapURL);
+ else
+ setTimeout("checkLoadingStatus('"+PictureID+"','"+ImageMapID+"','"+ImageMapURL+"')", 200);
+ }
+
+ /* Download the image map when the picture is loaded */
+ function downloadImageMap(PictureID,ImageMapID,ImageMapURL)
+ {
+ var xmlhttp=false;
+ /*@cc_on @*/
+ /*@if (@_jscript_version >= 5)
+ try { xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { xmlhttp = false; } }
+ @end @*/
+
+ if (!xmlhttp && typeof XMLHttpRequest!='undefined')
+ { try { xmlhttp = new XMLHttpRequest(); } catch (e) { xmlhttp=false; } }
+
+ if (!xmlhttp && window.createRequest)
+ { try { xmlhttp = window.createRequest(); } catch (e) { xmlhttp=false; } }
+
+ xmlhttp.open("GET", ImageMapURL,true);
+
+ xmlhttp.onreadystatechange=function()
+ { if (xmlhttp.readyState==4) { parseZones(ImageMapID,xmlhttp.responseText); } }
+ xmlhttp.send(null)
+ }
+
+ /* Process the image map & create the zones */
+ function parseZones(ImageMapID,SerializedZones)
+ {
+ var Zones = SerializedZones.split("\r\n");
+
+ for(i=0;i<=Zones.length-2;i++)
+ {
+ var Options = Zones[i].split(";");
+ addArea(ImageMapID,Options[0],Options[1],'showDiv("testDiv","'+Options[2]+'","'+Options[3]+'","'+Options[4].replace('"','')+'");','hideDiv("testDiv");');
+ }
+ }
+
+ /* Attach the onMouseMove() event to the document body */
+ if(document.all)
+ { document.onmousemove = UpdateCursorPositionDocAll; }
+
+ else
+ { document.onmousemove = UpdateCursorPosition; }
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/index.php b/notFinishedCode/pChart2.1.2/examples/imageMap/index.php
new file mode 100644
index 0000000..21f2e70
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/index.php
@@ -0,0 +1,209 @@
+<?php if ( isset($_GET["Action"]) && $_GET["Action"] == "ViewPHP") { $Script = $_GET["Script"]; highlight_file($Script); exit(); } ?>
+<?php if ( isset($_GET["Action"]) && $_GET["Action"] == "ViewHTML") { $Script = $_GET["Script"]; writeHTML($Script); exit(); } ?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <script src='imagemap.js' type="text/javascript"></script>
+ <title>pChart 2.x - Image map</title>
+ <meta http-equiv='Content-Type' content='text/html; charset=utf-8'/>
+ <style>
+ body { background-color: #F0F0F0; font-family: tahoma; font-size: 14px;}
+ td { font-family: tahoma; font-size: 11px; }
+ div.txt { font-family: tahoma; font-size: 11px; width: 660px; padding: 15px; }
+ div.folder { cursor: hand; cursor: pointer; }
+ a.smallLink:link { text-decoration: none; color: #6A6A6A; }
+ a.smallLink:visited { text-decoration: none; color: #6A6A6A; }
+ a.smallLink:hover { text-decoration: underline; color: #6A6A6A; }
+ a.smallLinkGrey:link { text-decoration: none; color: #6A6A6A; }
+ a.smallLinkGrey:visited { text-decoration: none; color: #6A6A6A; }
+ a.smallLinkGrey:hover { text-decoration: underline; color: #6A6A6A; }
+ a.smallLinkBlack:link { text-decoration: none; color: #000000; }
+ a.smallLinkBlack:visited { text-decoration: none; color: #000000; }
+ a.smallLinkBlack:hover { text-decoration: underline; color: #000000; }
+ a.pChart { text-decoration: none; color: #6A6A6A; }
+ a img, img { border: none; }
+ </style>
+</head>
+<body>
+<?php
+ /* Files that we don't want to see in the tree */
+ $Exclusion = array(".","..");
+
+ /* Determine the current package version */
+ $FileHandle = fopen("../../readme.txt", "r");
+ for ($i=0; $i<=5; $i++) { $buffer = fgets($FileHandle, 4096); }
+ fclose($FileHandle);
+ $Values = preg_split("/:/",$buffer);
+ $Values = preg_split("/ /",$Values[1]);
+ $Version = strip_tags($Values[1]);
+
+ /* Build a list of the examples & categories */
+ $DirectoryHandle = opendir("scripts");
+ {
+ $Tree = "";
+ while (($FileName = readdir($DirectoryHandle)) !== false)
+ {
+ if ( !in_array($FileName,$Exclusion))
+ $Tree[] = str_replace(".php","",$FileName);
+ }
+ }
+?>
+
+ <table style='border: 2px solid #FFFFFF;'><tr><td>
+ <div style='font-size: 11px; padding: 2px; color: #FFFFFF; background-color: #666666; border-bottom: 3px solid #484848;'>&nbsp;Navigation</div>
+ <table style='padding: 1px; background-color: #E0E0E0; border: 1px solid #D0D0D0; border-top: 1px solid #FFFFFF;'><tr>
+ <td width=16><img src='../resources/application_view_tile.png' width=16 height=16 alt=''/></td>
+ <td width=100>&nbsp;<a class=smallLinkGrey href='../'>Examples</a></td>
+ <td width=16><img src='../resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td width=100>&nbsp;<a class=smallLinkGrey href='../sandbox/'>Sandbox</a></td>
+ <td width=16><img src='../resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td width=100>&nbsp;<a class=smallLinkGrey href='../delayedLoader/'>Delayed loader</a></td>
+ <td width=16><img src='../resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td width=100>&nbsp;<b>Image Map</b></td>
+ </tr></table>
+ </td></tr></table>
+
+ <br/>
+
+ <table><tr><td valign='top'>
+ <table style='border: 2px solid #FFFFFF;'><tr><td>
+ <div style='font-size: 11px; padding: 2px; color: #FFFFFF; background-color: #666666; border-bottom: 3px solid #484848; width: 222px;'>&nbsp;Release <?php echo $Version; ?></div>
+ <div style='border: 3px solid #D0D0D0; border-top: 1px solid #FFFFFF; background-color: #FAFAFA; width: 220px; overflow: auto'>
+ <div style='padding: 1px; padding-bottom: 3px; color: #000000; background-color:#D0D0D0;'>
+ <table><tr>
+ <td><img src='../resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td>&nbsp;Examples folder contents</td>
+ </tr></table>
+ </div>
+<?php
+ foreach($Tree as $Key => $Element)
+ {
+ if ( $Key == count($Tree)-1 ) { $Icon = "../resources/dash-explorer-last.png"; } else { $Icon = "../resources/dash-explorer.png"; }
+
+ echo "<table noborder cellpadding=0 cellspacing=0>\r\n";
+ echo " <tr valign=middle>\r\n";
+ echo " <td><img src='".$Icon."' width=16 height=20 alt=''/></td>\r\n";
+ echo " <td><img src='../resources/application_view_tile.png' width=16 height=16 alt=''/></td>\r\n";
+ echo " <td><div class=folder onclick='showExample(".chr(34).$Element.chr(34).");'>&nbsp;".$Element."</div></td>\r\n";
+ echo " </tr>\r\n";
+ echo "</table>\r\n";
+ }
+?>
+
+ </div>
+ </td></tr></table>
+ </td><td width=20></td><td valign='top' style='padding-top: 5px; font-size: 12px;'>
+ <table><tr>
+ <td><img src='../resources/chart_bar.png' width=16 height=16 alt=''/></td>
+ <td>&nbsp;Rendering area</td>
+ </tr></table>
+
+ <div style='display:table-cell; padding: 10px; border: 2px solid #FFFFFF; vertical-align: middle; overflow: auto; background-image: url("resources/dash.png");'>
+ <div style='font-size: 10px;' id=render>
+ <table><tr><td><img src='../resources/accept.png' width=16 height=16 alt=""/></td><td>Click on an example to render it!</td></tr></table>
+ </div>
+ </div>
+
+ <br/><br/>
+
+ <table><tr>
+ <td><img src='../resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td>&nbsp;HTML Source area</td>
+ </tr></table>
+
+ <div style='display:table-cell; padding: 10px; border: 2px solid #FFFFFF; vertical-align: middle; overflow: auto; background-image: url("resources/dash.png");'>
+ <div id=htmlsource style='width: 700px; font-size: 13px; font-family: Lucida Console'>
+
+ &lt;html&gt;<br/>
+ &lt;head&gt;<br/>
+ &nbsp;&nbsp; &lt;style&gt;<br/>
+ &nbsp;&nbsp;&nbsp;&nbsp; div.pChartPicture { border: 0px; }<br/>
+ &nbsp;&nbsp; &lt;/style&gt;<br/>
+ &lt;/head&gt;<br/>
+ &lt;body&gt;<br/>
+ &nbsp;&nbsp; &lt;script src="imagemap.js" type="text/javascript"&gt;&lt;/script&gt;<br/>
+ &nbsp;&nbsp; &lt;img src="draw.php" id="testPicture" alt="" class="pChartPicture"/&gt;<br/>
+ &lt;/body&gt;<br/>
+ &lt;script&gt;<br/>
+ &nbsp;&nbsp; addImage("testPicture","pictureMap","draw.php?ImageMap=get");<br/>
+ &lt;/script&gt;<br/>
+
+ </div>
+ </div>
+
+ <br/><br/>
+
+ <table><tr>
+ <td><img src='../resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td>&nbsp;PHP Source area</td>
+ </tr></table>
+
+ <div style='display:table-cell; padding: 10px; border: 2px solid #FFFFFF; vertical-align: middle; overflow: auto; background-image: url("resources/dash.png");'>
+ <div style='font-size: 10px;' id=source style='width: 700px;'>
+ <table><tr><td><img src='../resources/accept.png' width=16 height=16 alt=""/></td><td>Click on an example to get its source!</td></tr></table>
+ </div>
+ </div>
+
+</td></tr></table>
+</body>
+</html>
+<script>
+ function showExample(FileName)
+ {
+ document.getElementById("render").innerHTML = "<img src='scripts/"+FileName+".php?Seed="+Math.random(100)+"' id='testPicture' alt='' class='pChartPicture'/>";
+ viewPHP("scripts/"+FileName+".php");
+ // viewHTML("scripts/"+FileName+".php");
+
+ addImage('testPicture','pictureMap','scripts/'+FileName+'.php?ImageMap=get');
+ }
+
+ function viewPHP(URL)
+ {
+ var xmlhttp=false;
+ /*@cc_on @*/
+ /*@if (@_jscript_version >= 5)
+ try { xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { xmlhttp = false; } }
+ @end @*/
+
+ URL = "index.php?Action=ViewPHP&Script=" + URL;
+
+ if (!xmlhttp && typeof XMLHttpRequest!='undefined')
+ { try { xmlhttp = new XMLHttpRequest(); } catch (e) { xmlhttp=false; } }
+
+ if (!xmlhttp && window.createRequest)
+ { try { xmlhttp = window.createRequest(); } catch (e) { xmlhttp=false; } }
+
+ xmlhttp.open("GET", URL,true);
+
+ xmlhttp.onreadystatechange=function() { if (xmlhttp.readyState==4) { Result = xmlhttp.responseText; document.getElementById("source").innerHTML = Result.replace("/\<BR\>/"); } }
+ xmlhttp.send(null)
+ }
+
+ function viewHTML(URL)
+ {
+ var xmlhttp=false;
+ /*@cc_on @*/
+ /*@if (@_jscript_version >= 5)
+ try { xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { xmlhttp = false; } }
+ @end @*/
+
+ URL = "index.php?Action=ViewHTML&Script=" + URL;
+
+ if (!xmlhttp && typeof XMLHttpRequest!='undefined')
+ { try { xmlhttp = new XMLHttpRequest(); } catch (e) { xmlhttp=false; } }
+
+ if (!xmlhttp && window.createRequest)
+ { try { xmlhttp = window.createRequest(); } catch (e) { xmlhttp=false; } }
+
+ xmlhttp.open("GET", URL,true);
+
+ xmlhttp.onreadystatechange=function() { if (xmlhttp.readyState==4) { Result = xmlhttp.responseText; document.getElementById("htmlsource").innerHTML = Result.replace("/\<BR\>/"); } }
+ xmlhttp.send(null)
+ }
+</script>
+<?php
+ function writeHTML($Script)
+ {
+ echo $Script;
+ }
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/2DPie.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/2DPie.php
new file mode 100644
index 0000000..affabc8
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/2DPie.php
@@ -0,0 +1,58 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pPie.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(40,60,15,10,6,4),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("<10","10<>20","20<>40","40<>60","60<>80",">80"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,260,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMap2DPieChart",IMAGE_MAP_STORAGE_FILE,"2DPieChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMap2DPieChart",IMAGE_MAP_STORAGE_FILE,"2DPieChart","../tmp");
+
+ /* Draw a solid background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,260,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,259,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>50));
+
+ /* Create the pPie object */
+ $Settings = array("RecordImageMap"=>TRUE);
+ $PieChart = new pPie($myPicture,$MyData,$Settings);
+
+ /* Draw an AA pie chart */
+ $PieSettings = array("DrawLabels"=>TRUE,"LabelStacked"=>TRUE,"Border"=>TRUE,"RecordImageMap"=>TRUE);
+ $PieChart->draw2DPie(160,125,$PieSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/2DPieChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/2DRing.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/2DRing.php
new file mode 100644
index 0000000..fad3d96
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/2DRing.php
@@ -0,0 +1,58 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pPie.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(40,60,15,10,6,4),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("<10","10<>20","20<>40","40<>60","60<>80",">80"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,260,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMap2DRingChart",IMAGE_MAP_STORAGE_FILE,"2DRingChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMap2DRingChart",IMAGE_MAP_STORAGE_FILE,"2DRingChart","../tmp");
+
+ /* Draw a solid background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,260,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,259,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>50));
+
+ /* Create the pPie object */
+ $Settings = array("RecordImageMap"=>TRUE);
+ $PieChart = new pPie($myPicture,$MyData,$Settings);
+
+ /* Draw an AA pie chart */
+ $PieSettings = array("DrawLabels"=>TRUE,"LabelStacked"=>TRUE,"Border"=>TRUE,"RecordImageMap"=>TRUE);
+ $PieChart->draw2DRing(160,125,$PieSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/2DRingChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/3DPie.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/3DPie.php
new file mode 100644
index 0000000..695ce20
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/3DPie.php
@@ -0,0 +1,55 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pPie.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(40,60,15,10,6,4),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("<10","10<>20","20<>40","40<>60","60<>80",">80"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,260,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMap3DPieChart",IMAGE_MAP_STORAGE_FILE,"3DPieChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMap3DPieChart",IMAGE_MAP_STORAGE_FILE,"3DPieChart","../tmp");
+
+ /* Draw a solid background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,260,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,259,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Create the pPie object */
+ $Settings = array("RecordImageMap"=>TRUE);
+ $PieChart = new pPie($myPicture,$MyData,$Settings);
+
+ /* Draw an AA pie chart */
+ $PieSettings = array("DrawLabels"=>TRUE,"LabelStacked"=>TRUE,"Border"=>TRUE,"RecordImageMap"=>TRUE);
+ $PieChart->draw3DPie(160,150,$PieSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/3DPieChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/3DRing.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/3DRing.php
new file mode 100644
index 0000000..5a255e3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/3DRing.php
@@ -0,0 +1,55 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pPie.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(40,60,15,10,6,4),"ScoreA");
+ $MyData->setSerieDescription("ScoreA","Application A");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("<10","10<>20","20<>40","40<>60","60<>80",">80"),"Labels");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,260,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMap3DRingChart",IMAGE_MAP_STORAGE_FILE,"3DRingChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMap3DRingChart",IMAGE_MAP_STORAGE_FILE,"3DRingChart","../tmp");
+
+ /* Draw a solid background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,300,300,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,300,260,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,299,259,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Create the pPie object */
+ $Settings = array("RecordImageMap"=>TRUE);
+ $PieChart = new pPie($myPicture,$MyData,$Settings);
+
+ /* Draw an AA pie chart */
+ $PieSettings = array("InnerRadius"=>30,"OuterRadius"=>80,"DrawLabels"=>TRUE,"Border"=>TRUE,"RecordImageMap"=>TRUE);
+ $PieChart->draw3DRing(160,150,$PieSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/3DRingChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/BarChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/BarChart.php
new file mode 100644
index 0000000..11104ec
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/BarChart.php
@@ -0,0 +1,67 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(150,220,300,-250,-420,-200,300,200,100),"Server A");
+ $MyData->addPoints(array(140,0,340,-300,-320,-300,200,100,50),"Server B");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("January","February","March","April","May","Juin","July","August","September"),"Months");
+ $MyData->setSerieDescription("Months","Month");
+ $MyData->setAbscissa("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapBarChart",IMAGE_MAP_STORAGE_FILE,"BarChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapBarChart",IMAGE_MAP_STORAGE_FILE,"BarChart","../tmp");
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,12,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the chart */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $Settings = array("RecordImageMap"=>TRUE);
+ $myPicture->drawBarChart($Settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/BarChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/BubbleChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/BubbleChart.php
new file mode 100644
index 0000000..c7e18a2
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/BubbleChart.php
@@ -0,0 +1,76 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pBubble.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(34,55,15,62,38,42),"Probe1");
+ $MyData->addPoints(array(5,30,20,9,15,10),"Probe1Weight");
+ $MyData->addPoints(array(5,10,-5,-1,0,-10),"Probe2");
+ $MyData->addPoints(array(6,10,14,10,14,6),"Probe2Weight");
+ $MyData->setSerieDescription("Probe1","This year");
+ $MyData->setSerieDescription("Probe2","Last year");
+ $MyData->setAxisName(0,"Current stock");
+ $MyData->addPoints(array("Apple","Banana","Orange","Lemon","Peach","Strawberry"),"Product");
+ $MyData->setAbscissa("Product");
+ $MyData->setAbscissaName("Selected Products");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapBarChart",IMAGE_MAP_STORAGE_FILE,"BarChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapBarChart",IMAGE_MAP_STORAGE_FILE,"BarChart","../tmp");
+
+ /* Turn of AAliasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,30,650,190);
+
+ /* Draw the scale */
+ $scaleSettings = array("GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Create the Bubble chart object and scale up */
+ $myPicture->Antialias = TRUE;
+ $myBubbleChart = new pBubble($myPicture,$MyData);
+
+ /* Scale up for the bubble chart */
+ $bubbleDataSeries = array("Probe1","Probe2");
+ $bubbleWeightSeries = array("Probe1Weight","Probe2Weight");
+ $myBubbleChart->bubbleScale($bubbleDataSeries,$bubbleWeightSeries);
+
+ /* Draw the bubble chart */
+ $Settings = array("RecordImageMap"=>TRUE,"ForceAlpha"=>50);
+ $myBubbleChart->drawBubbleChart($bubbleDataSeries,$bubbleWeightSeries,$Settings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(570,13,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/Bubble Chart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/LineChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/LineChart.php
new file mode 100644
index 0000000..bce48eb
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/LineChart.php
@@ -0,0 +1,74 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setSerieWeight("Probe 3",2);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapLineChart",IMAGE_MAP_STORAGE_FILE,"LineChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapLineChart",IMAGE_MAP_STORAGE_FILE,"LineChart","../tmp");
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw the line chart */
+ $Settings = array("RecordImageMap"=>TRUE);
+ $myPicture->drawLineChart($Settings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(540,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/LineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/PlotChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/PlotChart.php
new file mode 100644
index 0000000..7bbecd5
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/PlotChart.php
@@ -0,0 +1,69 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ for($i=0;$i<=20;$i++) { $MyData->addPoints(rand(0,20),"Probe 1"); }
+ for($i=0;$i<=20;$i++) { $MyData->addPoints(rand(0,20),"Probe 2"); }
+ $MyData->setSerieShape("Probe 1",SERIE_SHAPE_FILLEDTRIANGLE);
+ $MyData->setSerieShape("Probe 2",SERIE_SHAPE_FILLEDSQUARE);
+ $MyData->setAxisName(0,"Temperatures");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMap1",IMAGE_MAP_STORAGE_FILE,"PlotChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMap1",IMAGE_MAP_STORAGE_FILE,"PlotChart","../tmp");
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the line chart */
+ $myPicture->drawPlotChart(array("RecordImageMap"=>TRUE));
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/PlotChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/PolarChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/PolarChart.php
new file mode 100644
index 0000000..d015900
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/PolarChart.php
@@ -0,0 +1,56 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pRadar.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(10,20,30,40,50,60,70,80,90),"ScoreA");
+ $MyData->addPoints(array(20,40,50,12,10,30,40,50,60),"ScoreB");
+ $MyData->setSerieDescription("ScoreA","Coverage A");
+ $MyData->setSerieDescription("ScoreB","Coverage B");
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array(40,80,120,160,200,240,280,320,360),"Coord");
+ $MyData->setAbscissa("Coord");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,300,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapPolarChart",IMAGE_MAP_STORAGE_FILE,"PolarChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapPolarChart",IMAGE_MAP_STORAGE_FILE,"PolarChart","../tmp");
+
+ /* Draw the background */
+ $myPicture->drawGradientArea(0,0,300,300,DIRECTION_VERTICAL,array("StartR"=>200,"StartG"=>200,"StartB"=>200,"EndR"=>240,"EndG"=>240,"EndB"=>240,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $RectangleSettings = array("R"=>180,"G"=>180,"B"=>180,"Alpha"=>100);
+ $myPicture->drawRectangle(0,0,299,299,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pRadar object */
+ $SplitChart = new pRadar();
+
+ /* Draw a radar chart */
+ $myPicture->setGraphArea(10,10,290,290);
+ $Options = array("RecordImageMap"=>TRUE,"LabelPos"=>RADAR_LABELS_HORIZONTAL,"BackgroundGradient"=>array("StartR"=>255,"StartG"=>255,"StartB"=>255,"StartAlpha"=>50,"EndR"=>32,"EndG"=>109,"EndB"=>174,"EndAlpha"=>30),"AxisRotation"=>0,"DrawPoly"=>TRUE,"PolyAlpha"=>50, "FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6);
+ $SplitChart->drawPolar($myPicture,$MyData,$Options);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/PolarChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/RadarChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/RadarChart.php
new file mode 100644
index 0000000..96bc44c
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/RadarChart.php
@@ -0,0 +1,57 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pRadar.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(8,4,6,4,2,7),"ScoreA");
+ $MyData->addPoints(array(2,7,3,3,1,3),"ScoreB");
+ $MyData->setSerieDescription("ScoreA","Application A");
+ $MyData->setSerieDescription("ScoreB","Application B");
+ $MyData->setPalette("ScoreA",array("R"=>157,"G"=>196,"B"=>22));
+
+ /* Define the absissa serie */
+ $MyData->addPoints(array("Speed","Weight","Cost","Size","Ease","Utility"),"Families");
+ $MyData->setAbscissa("Families");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(300,300,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapRadarChart",IMAGE_MAP_STORAGE_FILE,"RadarChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapRadarChart",IMAGE_MAP_STORAGE_FILE,"RadarChart","../tmp");
+
+ /* Draw the background */
+ $myPicture->drawGradientArea(0,0,300,300,DIRECTION_VERTICAL,array("StartR"=>200,"StartG"=>200,"StartB"=>200,"EndR"=>240,"EndG"=>240,"EndB"=>240,"Alpha"=>100));
+
+ /* Add a border to the picture */
+ $RectangleSettings = array("R"=>180,"G"=>180,"B"=>180,"Alpha"=>100);
+ $myPicture->drawRectangle(0,0,299,299,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font properties */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Forgotte.ttf","FontSize"=>10,"R"=>80,"G"=>80,"B"=>80));
+
+ /* Enable shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>2,"Y"=>2,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Create the pRadar object */
+ $SplitChart = new pRadar();
+
+ /* Draw a radar chart */
+ $myPicture->setGraphArea(10,10,290,290);
+ $Options = array("RecordImageMap"=>TRUE,"DrawPoly"=>TRUE,"WriteValues"=>TRUE,"ValueFontSize"=>8,"Layout"=>RADAR_LAYOUT_CIRCLE,"BackgroundGradient"=>array("StartR"=>255,"StartG"=>255,"StartB"=>255,"StartAlpha"=>100,"EndR"=>207,"EndG"=>227,"EndB"=>125,"EndAlpha"=>50));
+ $SplitChart->drawRadar($myPicture,$MyData,$Options);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/RadarChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterLineChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterLineChart.php
new file mode 100644
index 0000000..46adcb5
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterLineChart.php
@@ -0,0 +1,89 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(cos(deg2rad($i))*20,"Probe 1"); }
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(sin(deg2rad($i))*20,"Probe 2"); }
+ $myData->setAxisName(0,"Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints($i,"Probe 3"); }
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Degree");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisUnit(1,"°");
+ $myData->setAxisPosition(1,AXIS_POSITION_RIGHT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 3",0);
+ $myData->setScatterSerieDescription(0,"This year");
+ $myData->setScatterSerieColor(0,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Create the 2nd scatter chart binding */
+ $myData->setScatterSerie("Probe 2","Probe 3",1);
+ $myData->setScatterSerieDescription(1,"Last Year");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapScatterLineChart",IMAGE_MAP_STORAGE_FILE,"ScatterLineChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapScatterLineChart",IMAGE_MAP_STORAGE_FILE,"ScatterLineChart","../tmp");
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,30,350,330);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $myScatter->drawScatterScale();
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw a scatter plot chart */
+ $myScatter->drawScatterLineChart(array("RecordImageMap"=>TRUE));
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(260,375,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/ScatterLineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterPlotChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterPlotChart.php
new file mode 100644
index 0000000..3722608
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterPlotChart.php
@@ -0,0 +1,89 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(cos(deg2rad($i))*20,"Probe 1"); }
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints(sin(deg2rad($i))*20,"Probe 2"); }
+ $myData->setAxisName(0,"Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+10) { $myData->addPoints($i,"Probe 3"); }
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Degree");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisUnit(1,"°");
+ $myData->setAxisPosition(1,AXIS_POSITION_RIGHT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 3",0);
+ $myData->setScatterSerieDescription(0,"This year");
+ $myData->setScatterSerieColor(0,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Create the 2nd scatter chart binding */
+ $myData->setScatterSerie("Probe 2","Probe 3",1);
+ $myData->setScatterSerieDescription(1,"Last Year");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapScatterPlotChart",IMAGE_MAP_STORAGE_FILE,"ScatterPlotChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapScatterPlotChart",IMAGE_MAP_STORAGE_FILE,"ScatterPlotChart","../tmp");
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,30,350,330);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $myScatter->drawScatterScale();
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw a scatter plot chart */
+ $myScatter->drawScatterPlotChart(array("RecordImageMap"=>TRUE));
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(260,375,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/ScatterPlotChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterSplineChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterSplineChart.php
new file mode 100644
index 0000000..b47a8dc
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/ScatterSplineChart.php
@@ -0,0 +1,90 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pScatter.class.php");
+
+ /* Create the pData object */
+ $myData = new pData();
+
+ /* Create the X axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+90) { $myData->addPoints(rand(1,30),"Probe 1"); }
+ for ($i=0;$i<=360;$i=$i+90) { $myData->addPoints(rand(1,30),"Probe 2"); }
+ $myData->setAxisName(0,"Index");
+ $myData->setAxisXY(0,AXIS_X);
+ $myData->setAxisPosition(0,AXIS_POSITION_BOTTOM);
+
+ /* Create the Y axis and the binded series */
+ for ($i=0;$i<=360;$i=$i+90) { $myData->addPoints($i,"Probe 3"); }
+ $myData->setSerieOnAxis("Probe 3",1);
+ $myData->setAxisName(1,"Degree");
+ $myData->setAxisXY(1,AXIS_Y);
+ $myData->setAxisUnit(1,"°");
+ $myData->setAxisPosition(1,AXIS_POSITION_RIGHT);
+
+ /* Create the 1st scatter chart binding */
+ $myData->setScatterSerie("Probe 1","Probe 3",0);
+ $myData->setScatterSerieDescription(0,"This year");
+ $myData->setScatterSerieColor(0,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Create the 2nd scatter chart binding */
+ $myData->setScatterSerie("Probe 2","Probe 3",1);
+ $myData->setScatterSerieDescription(1,"Last Year");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(400,400,$myData);
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapScatterSplineChart",IMAGE_MAP_STORAGE_FILE,"ScatterSplineChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapScatterSplineChart",IMAGE_MAP_STORAGE_FILE,"ScatterSplineChart","../tmp");
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,400,400,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,400,400,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,399,399,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Set the graph area */
+ $myPicture->setGraphArea(50,30,350,330);
+
+ /* Create the Scatter chart object */
+ $myScatter = new pScatter($myPicture,$myData);
+
+ /* Draw the scale */
+ $myScatter->drawScatterScale();
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw a scatter plot chart */
+ $myScatter->drawScatterSplineChart(array("RecordImageMap"=>TRUE));
+ $myScatter->drawScatterPlotChart();
+
+ /* Draw the legend */
+ $myScatter->drawScatterLegend(260,375,array("Mode"=>LEGEND_HORIZONTAL,"Style"=>LEGEND_NOBORDER));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/ScatterSplineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/Shapes.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/Shapes.php
new file mode 100644
index 0000000..4254070
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/Shapes.php
@@ -0,0 +1,91 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMap1",IMAGE_MAP_STORAGE_FILE,"Shapes","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMap1",IMAGE_MAP_STORAGE_FILE,"Shapes","../tmp");
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+ $myPicture->drawGradientArea(0,0,700,20,DIRECTION_VERTICAL,array("StartR"=>0,"StartG"=>0,"StartB"=>0,"EndR"=>50,"EndG"=>50,"EndB"=>50,"Alpha"=>80));
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the picture title */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Silkscreen.ttf","FontSize"=>6));
+ $myPicture->drawText(10,13,"drawFilledRectangle() - Transparency & colors",array("R"=>255,"G"=>255,"B"=>255));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>20));
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw a customized filled circle */
+ $CircleSettings = array("R"=>267,"G"=>165,"B"=>169,"Dash"=>TRUE,"BorderR"=>255,"BorderG"=>255,"BorderB"=>255);
+ $myPicture->drawFilledCircle(300,120,50,$CircleSettings);
+ $myPicture->addToImageMap("CIRCLE","300,120,50",$myPicture->toHTMLColor(267,165,169),"Circle","My Message");
+
+ /* Draw a customized polygon */
+ $Plots = array(402,62,460,80,420,190,360,168);
+ $PolygonSettings = array("R"=>71,"G"=>87,"B"=>145,"Dash"=>TRUE,"BorderR"=>255,"BorderG"=>255,"BorderB"=>255);
+ $myPicture->drawPolygon_0($Plots,$PolygonSettings);
+ $myPicture->addToImageMap("POLY","402,62,460,80,420,190,360,168",$myPicture->toHTMLColor(71,87,145),"Polygon","My Message");
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>150,"G"=>200,"B"=>170,"Dash"=>TRUE,"DashR"=>170,"DashG"=>220,"DashB"=>190,"BorderR"=>255,"BorderG"=>255,"BorderB"=>255);
+ $myPicture->drawFilledRectangle(20,60,210,170,$RectangleSettings);
+ $myPicture->addToImageMap("RECT","20,60,210,170",$myPicture->toHTMLColor(150,200,170),"Box 1","Message 1");
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>134,"B"=>27,"Alpha"=>30);
+ $myPicture->drawFilledRectangle(30,30,200,200,$RectangleSettings);
+ $myPicture->addToImageMap("RECT","30,30,200,200",$myPicture->toHTMLColor(209,134,27),"Box 2","Message 2");
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>31,"B"=>27,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawFilledRectangle(480,50,650,80,$RectangleSettings);
+ $myPicture->addToImageMap("RECT","480,50,650,80",$myPicture->toHTMLColor(209,31,27),"Box 3","Message 3");
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>125,"B"=>27,"Alpha"=>100,"Surrounding"=>30);
+ $myPicture->drawFilledRectangle(480,90,650,120,$RectangleSettings);
+ $myPicture->addToImageMap("RECT","480,90,650,120",$myPicture->toHTMLColor(209,125,27),"Box 4","Message 4");
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>209,"G"=>198,"B"=>27,"Alpha"=>100,"Surrounding"=>30,"Ticks"=>2);
+ $myPicture->drawFilledRectangle(480,130,650,160,$RectangleSettings);
+ $myPicture->addToImageMap("RECT","480,130,650,160",$myPicture->toHTMLColor(209,198,27),"Box 5","Message 5");
+
+ /* Draw a customized filled rectangle */
+ $RectangleSettings = array("R"=>134,"G"=>209,"B"=>27,"Alpha"=>100,"Surrounding"=>30,"Ticks"=>2);
+ $myPicture->drawFilledRectangle(480,170,650,200,$RectangleSettings);
+ $myPicture->addToImageMap("RECT","480,170,650,200",$myPicture->toHTMLColor(134,209,27),"Box 6","Message 6");
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/Shapes.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/SplineChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/SplineChart.php
new file mode 100644
index 0000000..359beae
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/SplineChart.php
@@ -0,0 +1,74 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(-4,VOID,VOID,12,8,3),"Probe 1");
+ $MyData->addPoints(array(3,12,15,8,5,-5),"Probe 2");
+ $MyData->addPoints(array(2,7,5,18,19,22),"Probe 3");
+ $MyData->setSerieTicks("Probe 2",4);
+ $MyData->setSerieWeight("Probe 3",2);
+ $MyData->setAxisName(0,"Temperatures");
+ $MyData->addPoints(array("Jan","Feb","Mar","Apr","May","Jun"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapSplineChart",IMAGE_MAP_STORAGE_FILE,"SplineChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapSplineChart",IMAGE_MAP_STORAGE_FILE,"SplineChart","../tmp");
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Average temperature",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw the line chart */
+ $Settings = array("RecordImageMap"=>TRUE);
+ $myPicture->drawSplineChart($Settings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(540,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/SplineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StackedBarChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StackedBarChart.php
new file mode 100644
index 0000000..fd86ca7
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StackedBarChart.php
@@ -0,0 +1,67 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(150,220,300,-250,-420,-200,300,200,100),"Server A");
+ $MyData->addPoints(array(140,0,340,-300,-320,-300,200,100,50),"Server B");
+ $MyData->setAxisName(0,"Hits");
+ $MyData->addPoints(array("January","February","March","April","May","Juin","July","August","September"),"Months");
+ $MyData->setSerieDescription("Months","Month");
+ $MyData->setAbscissa("Months");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapStackedBarChart",IMAGE_MAP_STORAGE_FILE,"StackedBarChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapStackedBarChart",IMAGE_MAP_STORAGE_FILE,"StackedBarChart","../tmp");
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("Mode"=>SCALE_MODE_ADDALL,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(580,12,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Turn on shadow computing */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+
+ /* Draw the chart */
+ $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>0,"G"=>0,"B"=>0,"Alpha"=>10));
+ $Settings = array("RecordImageMap"=>TRUE);
+ $myPicture->drawStackedBarChart($Settings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/StackedBarChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StepChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StepChart.php
new file mode 100644
index 0000000..eadb4df
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StepChart.php
@@ -0,0 +1,71 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(1,2,1,2,1,2,1,2,1,2),"Probe 1");
+ $MyData->addPoints(array(-1,-1,0,0,-1,-1,0,0,-1,-1),"Probe 2");
+ $MyData->addPoints(array(5,3,5,3,5,3,5,3,5,3),"Probe 3");
+ $MyData->setAxisName(0,"Value peak");
+ $MyData->addPoints(array("#1","#2","#3","#4","#5","#5","#7","#8","#9","#10"),"Labels");
+ $MyData->setSerieDescription("Labels","Months");
+ $MyData->setAbscissa("Labels");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapStepChart",IMAGE_MAP_STORAGE_FILE,"StepChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapStepChart",IMAGE_MAP_STORAGE_FILE,"StepChart","../tmp");
+
+ /* Turn of Antialiasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the background */
+ $Settings = array("R"=>170, "G"=>183, "B"=>87, "Dash"=>1, "DashR"=>190, "DashG"=>203, "DashB"=>107);
+ $myPicture->drawFilledRectangle(0,0,700,230,$Settings);
+
+ /* Overlay with a gradient */
+ $Settings = array("StartR"=>219, "StartG"=>231, "StartB"=>139, "EndR"=>1, "EndG"=>138, "EndB"=>68, "Alpha"=>50);
+ $myPicture->drawGradientArea(0,0,700,230,DIRECTION_VERTICAL,$Settings);
+
+ /* Add a border to the picture */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ /* Write the chart title */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/Forgotte.ttf","FontSize"=>11));
+ $myPicture->drawText(150,35,"Measured values",array("FontSize"=>20,"Align"=>TEXT_ALIGN_BOTTOMMIDDLE));
+
+ /* Set the default font */
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,40,650,200);
+
+ /* Draw the scale */
+ $scaleSettings = array("XMargin"=>10,"YMargin"=>10,"Floating"=>TRUE,"GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Turn on Antialiasing */
+ $myPicture->Antialias = TRUE;
+
+ /* Draw the line chart */
+ $Settings = array("RecordImageMap"=>TRUE);
+ $myPicture->drawStepChart($Settings);
+
+ /* Write the chart legend */
+ $myPicture->drawLegend(540,20,array("Style"=>LEGEND_NOBORDER,"Mode"=>LEGEND_HORIZONTAL));
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/LineChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StockChart.php b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StockChart.php
new file mode 100644
index 0000000..10379fa
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/imageMap/scripts/StockChart.php
@@ -0,0 +1,59 @@
+<?php
+ /* Library settings */
+ define("CLASS_PATH", "../../../class");
+ define("FONT_PATH", "../../../fonts");
+
+ /* pChart library inclusions */
+ include(CLASS_PATH."/pData.class.php");
+ include(CLASS_PATH."/pDraw.class.php");
+ include(CLASS_PATH."/pImage.class.php");
+ include(CLASS_PATH."/pStock.class.php");
+
+ /* Create and populate the pData object */
+ $MyData = new pData();
+ $MyData->addPoints(array(35,28,17,27,12,12,20,15,20,28),"Open");
+ $MyData->addPoints(array(20,17,25,20,25,23,16,29,26,17),"Close");
+ $MyData->addPoints(array(10,11,14,11,9,4,3,7,9,5),"Min");
+ $MyData->addPoints(array(37,32,33,29,29,25,22,34,29,31),"Max");
+ $MyData->addPoints(array(30,20,21,24,22,18,18,24,22,24),"Median");
+ $MyData->setAxisDisplay(0,AXIS_FORMAT_CURRENCY,"$");
+
+ $MyData->addPoints(array("Dec 13","Dec 14","Dec 15","Dec 16","Dec 17", "Dec 20","Dec 21","Dec 22","Dec 23","Dec 24"),"Time");
+ $MyData->setAbscissa("Time");
+ $MyData->setAbscissaName("Time");
+
+ /* Create the pChart object */
+ $myPicture = new pImage(700,230,$MyData);
+
+ /* Retrieve the image map */
+ if (isset($_GET["ImageMap"]) || isset($_POST["ImageMap"]))
+ $myPicture->dumpImageMap("ImageMapStockChart",IMAGE_MAP_STORAGE_FILE,"StockChart","../tmp");
+
+ /* Set the image map name */
+ $myPicture->initialiseImageMap("ImageMapStockChart",IMAGE_MAP_STORAGE_FILE,"StockChart","../tmp");
+
+ /* Turn of AAliasing */
+ $myPicture->Antialias = FALSE;
+
+ /* Draw the border */
+ $myPicture->drawRectangle(0,0,699,229,array("R"=>0,"G"=>0,"B"=>0));
+
+ $myPicture->setFontProperties(array("FontName"=>FONT_PATH."/pf_arma_five.ttf","FontSize"=>6));
+
+ /* Define the chart area */
+ $myPicture->setGraphArea(60,30,650,190);
+
+ /* Draw the scale */
+ $scaleSettings = array("GridR"=>200,"GridG"=>200,"GridB"=>200,"DrawSubTicks"=>TRUE,"CycleBackground"=>TRUE);
+ $myPicture->drawScale($scaleSettings);
+
+ /* Create the pStock object */
+ $mystockChart = new pStock($myPicture,$MyData);
+
+ /* Draw the stock chart */
+ $stockSettings = array("RecordImageMap"=>TRUE,"BoxUpR"=>255,"BoxUpG"=>255,"BoxUpB"=>255,"BoxDownR"=>0,"BoxDownG"=>0,"BoxDownB"=>0,"SerieMedian"=>"Median");
+ $mystockChart->drawStockChart($stockSettings);
+
+ /* Render the picture (choose the best way) */
+ $myPicture->autoOutput("../tmp/StockChart.png");
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/index.php b/notFinishedCode/pChart2.1.2/examples/index.php
new file mode 100644
index 0000000..445d8b9
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/index.php
@@ -0,0 +1,360 @@
+<?php if ( isset($_GET["Action"])) { $Script = $_GET["Script"]; highlight_file($Script); exit(); } ?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <title>pChart 2.x - examples rendering</title>
+ <meta http-equiv='Content-Type' content='text/html; charset=utf-8'/>
+ <style>
+ body { background-color: #F0F0F0; font-family: tahoma; font-size: 14px; height: 100%; overflow: auto;}
+ table { margin: 0px; padding: 0px; border: 0px; }
+ tr { margin: 0px; padding: 0px; border: 0px; }
+ td { font-family: tahoma; font-size: 11px; margin: 0px; padding: 0px; border: 0px; }
+ div.folder { cursor: hand; cursor: pointer; }
+ a.smallLinkGrey:link { text-decoration: none; color: #6A6A6A; }
+ a.smallLinkGrey:visited { text-decoration: none; color: #6A6A6A; }
+ a.smallLinkGrey:hover { text-decoration: underline; color: #6A6A6A; }
+ a.smallLinkBlack:link { text-decoration: none; color: #000000; }
+ a.smallLinkBlack:visited { text-decoration: none; color: #000000; }
+ a.smallLinkBlack:hover { text-decoration: underline; color: #000000; }
+ </style>
+</head>
+<?php checkPHPVersion(); ?>
+<body>
+
+<?php
+ /* Files that we don't want to see in the tree */
+ $Exclusion = array(".","..","index.php","buildAll.cmd","pictures","resources","delayedLoader","sandbox","imageMap");
+
+ /* Determine the current package version */
+ $FileHandle = fopen("../readme.txt", "r");
+ for ($i=0; $i<=5; $i++) { $buffer = fgets($FileHandle, 4096); }
+ fclose($FileHandle);
+ $Values = preg_split("/:/",$buffer);
+ $Values = preg_split("/ /",$Values[1]);
+ $Version = strip_tags($Values[1]);
+
+ /* Build a list of the examples & categories */
+ $DirectoryHandle = opendir(".");
+ {
+ $Tree = "";
+ while (($FileName = readdir($DirectoryHandle)) !== false)
+ {
+ if ( !in_array($FileName,$Exclusion))
+ {
+ $FileHandle = fopen($FileName, "r");
+ $buffer = fgets($FileHandle, 4096);
+ $buffer = fgets($FileHandle, 4096);
+ fclose($FileHandle);
+
+ if ( preg_match("/CAT:/",$buffer) )
+ {
+ $Categorie = str_replace(" /* CAT:","",$buffer);
+ $Categorie = str_replace("*/","",$Categorie);
+ $Categorie = trim($Categorie);
+ }
+ else
+ { $Categorie = "z_root"; }
+
+ $FileShortName = str_replace("example.","",$FileName);
+ $FileShortName = str_replace(".php","",$FileShortName);
+ $FileShortName = trim($FileShortName);
+
+ $Tree[$Categorie][]=array("FileName"=>$FileName,"FileShortName"=>$FileShortName);
+ }
+ }
+ closedir($DirectoryHandle);
+
+ ksort($Tree);
+?>
+
+<table style='border: 2px solid #FFFFFF;'><tr><td>
+<div style='font-size: 11px; padding: 2px; color: #FFFFFF; background-color: #666666; border-bottom: 3px solid #484848;'>&nbsp;Navigation</div>
+<table style='padding: 1px; background-color: #E0E0E0; border: 1px solid #D0D0D0; border-top: 1px solid #FFFFFF;'><tr>
+ <td width=16><img src='resources/application_view_tile.png' width=16 height=16 alt=''/></td>
+ <td width=100>&nbsp;<b>Examples</b></td>
+ <td width=16><img src='resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td width=100>&nbsp;<a class=smallLinkGrey href='sandbox/'>Sandbox</a></td>
+ <td width=16><img src='resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td width=100>&nbsp;<a class=smallLinkGrey href='delayedLoader/'>Delayed loader</a></td>
+ <td width=16><img src='resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td width=100>&nbsp;<a class=smallLinkGrey href='imageMap/'>Image Map</a></td>
+</tr></table>
+</td></tr></table>
+
+<br/>
+<table><tr><td valign='top'>
+
+<table style='border: 2px solid #FFFFFF;'><tr><td>
+<div style='font-size: 11px; padding: 2px; color: #FFFFFF; background-color: #666666; border-bottom: 3px solid #484848; width: 222px;'>&nbsp;Release <?php echo $Version; ?></div>
+<div style='border: 3px solid #D0D0D0; border-top: 1px solid #FFFFFF; background-color: #FAFAFA; width: 220px; overflow: auto'>
+<div style='padding: 1px; padding-bottom: 3px; color: #000000; background-color:#D0D0D0;'>
+ <table><tr>
+ <td><img src='resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td>&nbsp;Examples folder contents</td>
+ </tr></table>
+</div>
+<?php
+ $ID = 1; if ( isset($Tree["z_root"]) ) { $ID = 2; }
+ foreach($Tree as $Key => $Elements)
+ {
+ if ( $ID == count($Tree) ) { $Icon = "dash-explorer-last.png"; $SubIcon = "dash-explorer-blank.png"; } else { $Icon = "dash-explorer.png"; $SubIcon = "dash-explorer-noleaf.png"; }
+ if ( $Key != "z_root" )
+ {
+ echo "<table noborder cellpadding=0 cellspacing=0>\r\n";
+ echo " <tr valign=middle>\r\n";
+ echo " <td><img src='resources/".$Icon."' width=16 height=20 alt=''/></td>\r\n";
+ echo " <td><img src='resources/folder.png' width=16 height=16 alt=''/></td>\r\n";
+ echo " <td><div class=folder id='".$Key."_main' onclick='showHideMenu(".chr(34).$Key.chr(34).");'>&nbsp;".$Key."</div></td>\r\n";
+ echo " </tr>\r\n";
+ echo "</table>\r\n";
+
+ echo "<table id='".$Key."' style='display: none;' noborder cellpadding=0 cellspacing=0><tr>\r\n";
+ foreach($Elements as $SubKey => $Element)
+ {
+ $FileName = $Element["FileName"];
+ $FileShortName = $Element["FileShortName"];
+
+ if ( $SubKey == count($Elements)-1 ) { $Icon = "dash-explorer-last.png"; } else { $Icon = "dash-explorer.png"; }
+
+ echo " <tr valign=middle>\r\n";
+ echo " <td><img src='resources/".$SubIcon."' width=16 height=20 alt=''/></td>\r\n";
+ echo " <td><img src='resources/".$Icon."' width=16 height=20 alt=''/></td>\r\n";
+ echo " <td><img src='resources/application_view_tile.png' width=16 height=16 alt=''/></td>\r\n";
+ echo " <td>&nbsp;<a class=smallLinkGrey href='#' onclick='render(".chr(34).$FileName.chr(34).");'>".$FileShortName."</a></td>\r\n";
+ echo " </tr>\r\n";
+ }
+ echo "</table>\r\n";
+
+ }
+ $ID++;
+ }
+ }
+?>
+</div>
+</td></tr></table>
+
+</td><td width=20></td><td valign='top' style='padding-top: 5px; font-size: 12px;'>
+
+<table><tr>
+ <td><img src='resources/chart_bar.png' width=16 height=16 alt=''/></td>
+ <td>&nbsp;Rendering area</td>
+</tr></table>
+
+<div style='display:table-cell; padding: 10px; border: 2px solid #FFFFFF; vertical-align: middle; overflow: auto; background-image: url("resources/dash.png");'>
+ <div style='font-size: 10px;' id=render>
+ <table><tr><td><img src='resources/accept.png' width=16 height=16 alt=""/></td><td>Click on an example to render it!</td></tr></table>
+ </div>
+</div>
+
+<br/><br/>
+
+<table><tr>
+ <td><img src='resources/application_view_list.png' width=16 height=16 alt=''/></td>
+ <td>&nbsp;Source area</td>
+</tr></table>
+
+<div style='display:table-cell; padding: 10px; border: 2px solid #FFFFFF; vertical-align: middle; overflow: auto; background-image: url("resources/dash.png");'>
+ <div style='font-size: 10px;' id=source style='width: 700px;'>
+ <table><tr><td><img src='resources/accept.png' width=16 height=16 alt=""/></td><td>Click on an example to get its source!</td></tr></table>
+ </div>
+</div>
+
+</td></tr></table>
+</body>
+<script>
+ URL = "";
+ SourceURL = "";
+ LastOpened = "";
+
+ function showHideMenu(Element)
+ {
+ status = document.getElementById(Element).style.display;
+ if ( status == "none" )
+ {
+ if ( LastOpened != "" && LastOpened != Element ) { showHideMenu(LastOpened); }
+
+ document.getElementById(Element).style.display = "inline";
+ document.getElementById(Element+"_main").style.fontWeight = "bold";
+ LastOpened = Element;
+ }
+ else
+ {
+ document.getElementById(Element).style.display = "none";
+ document.getElementById(Element+"_main").style.fontWeight = "normal";
+ LastOpened = "";
+ }
+ }
+
+ function render(PictureName)
+ {
+ opacity("render",100,0,100);
+
+ RandomKey = Math.random(100);
+ URL = PictureName + "?Seed=" + RandomKey;
+ SourceURL = PictureName;
+
+ ajaxRender(URL);
+ }
+
+ function StartFade()
+ {
+ Loader = new Image();
+ Loader.src = URL;
+ setTimeout("CheckLoadingStatus()", 200);
+ }
+
+ function CheckLoadingStatus()
+ {
+ if ( Loader.complete == true )
+ {
+ changeOpac(0, "render");
+ HTMLResult = "<center><img src='" + URL + "' alt=''/></center>";
+ document.getElementById("render").innerHTML = HTMLResult;
+
+ opacity("render",0,100,100);
+ view(SourceURL);
+ }
+ else
+ setTimeout("CheckLoadingStatus()", 200);
+ }
+
+ function changeOpac(opacity, id)
+ {
+ var object = document.getElementById(id).style;
+ object.opacity = (opacity / 100);
+ object.MozOpacity = (opacity / 100);
+ object.KhtmlOpacity = (opacity / 100);
+ object.filter = "alpha(opacity=" + opacity + ")";
+ }
+
+ function wait()
+ {
+ HTMLResult = "<center><img src='resources/wait.gif' width=24 height=24 alt=''/><br>Rendering</center>";
+ document.getElementById("render").innerHTML = HTMLResult;
+ changeOpac(20, "render");
+ }
+
+ function opacity(id, opacStart, opacEnd, millisec)
+ {
+ var speed = Math.round(millisec / 100);
+ var timer = 0;
+
+ if(opacStart > opacEnd)
+ {
+ for(i = opacStart; i >= opacEnd; i--)
+ {
+ setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed));
+ timer++;
+ }
+ setTimeout("wait()",(timer * speed));
+ }
+ else if(opacStart < opacEnd)
+ {
+ for(i = opacStart; i <= opacEnd; i++)
+ {
+ setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed));
+ timer++;
+ }
+ }
+ }
+
+ function ajaxRender(URL)
+ {
+ var xmlhttp=false;
+ /*@cc_on @*/
+ /*@if (@_jscript_version >= 5)
+ try { xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { xmlhttp = false; } }
+ @end @*/
+
+ if (!xmlhttp && typeof XMLHttpRequest!='undefined')
+ { try { xmlhttp = new XMLHttpRequest(); } catch (e) { xmlhttp=false; } }
+
+ if (!xmlhttp && window.createRequest)
+ { try { xmlhttp = window.createRequest(); } catch (e) { xmlhttp=false; } }
+
+ xmlhttp.open("GET", URL,true);
+
+ xmlhttp.onreadystatechange=function() { if (xmlhttp.readyState==4) { StartFade(); } }
+ xmlhttp.send(null)
+ }
+
+ function view(URL)
+ {
+ var xmlhttp=false;
+ /*@cc_on @*/
+ /*@if (@_jscript_version >= 5)
+ try { xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { xmlhttp = false; } }
+ @end @*/
+
+ URL = "index.php?Action=View&Script=" + URL;
+
+ if (!xmlhttp && typeof XMLHttpRequest!='undefined')
+ { try { xmlhttp = new XMLHttpRequest(); } catch (e) { xmlhttp=false; } }
+
+ if (!xmlhttp && window.createRequest)
+ { try { xmlhttp = window.createRequest(); } catch (e) { xmlhttp=false; } }
+
+ xmlhttp.open("GET", URL,true);
+
+ xmlhttp.onreadystatechange=function() { if (xmlhttp.readyState==4) { Result = xmlhttp.responseText; document.getElementById("source").innerHTML = Result.replace("/\<BR\>/"); } }
+ xmlhttp.send(null)
+ }
+</script>
+</html>
+<?php
+ function checkPHPVersion()
+ {
+ $PHPVersion = phpversion();
+ $Values = preg_split("/\./",$PHPVersion);
+ $PHPMajor = $Values[0];
+ $PHPMinor = $Values[1];
+
+ $GDVersion = NULL;
+ if (extension_loaded('gd'))
+ {
+ if (function_exists('gd_info'))
+ {
+ $GDVersionInfo = gd_info();
+ preg_match('/\d/', $GDVersionInfo['GD Version'], $Match);
+ $GDVersion = $Match[0];
+ }
+ }
+
+ if ( $PHPMajor < 4 || $GDVersion < 2 )
+ {
+?>
+<body>
+ <div style='width: 300px; background-color: #FB8B8E; border: 1px solid #CB5B5E; margin: 10px; font-family: tahoma;'>
+ <div style='background-color: #CB5B5E; color: #FFFFFF; padding: 4px; font-family: tahoma; font-size: 11px;'>
+ <B>Warning</B>
+ </div>
+ <div style='padding: 4px; font-family: tahoma; font-size: 11px;' align='justify'>
+ It seems that you're not meeting the pChart minimal server requirements:
+ <br><br>
+ &nbsp;&nbsp;-&nbsp;PHP must be at least <b>4.x</b><br/>
+ &nbsp;&nbsp;-&nbsp;GD version <b>2.x</b><br/>
+ </div>
+ </div>
+</body>
+<html>
+<?php
+ exit();
+ }
+ }
+
+ function size($Value)
+ {
+ if ( $Value < 1024 ) { return($Value." o."); }
+ if ( $Value >= 1024 && $Value < 1024000 ) { return(floor($Value/1024)." ko."); }
+ return(floor($Value/1024000))." mo.";
+ }
+
+ function left($value,$NbChar)
+ { return substr($value,0,$NbChar); }
+
+ function right($value,$NbChar)
+ { return substr($value,strlen($value)-$NbChar,$NbChar); }
+
+ function mid($value,$Depart,$NbChar)
+ { return substr($value,$Depart-1,$NbChar); }
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK.png b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK.png
new file mode 100644
index 0000000..e153c02
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK1.png b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK1.png
new file mode 100644
index 0000000..6063c62
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSNOK1.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK.png b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK.png
new file mode 100644
index 0000000..de4c7ea
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK1.png b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK1.png
new file mode 100644
index 0000000..cd449b2
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/newIcons/BTSOK1.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/accept.png b/notFinishedCode/pChart2.1.2/examples/resources/accept.png
new file mode 100644
index 0000000..89c8129
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/accept.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/application_view_list.png b/notFinishedCode/pChart2.1.2/examples/resources/application_view_list.png
new file mode 100644
index 0000000..acc30b8
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/application_view_list.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/application_view_tile.png b/notFinishedCode/pChart2.1.2/examples/resources/application_view_tile.png
new file mode 100644
index 0000000..3bc0bd3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/application_view_tile.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/blocnote.png b/notFinishedCode/pChart2.1.2/examples/resources/blocnote.png
new file mode 100644
index 0000000..3ed75d6
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/blocnote.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/chart_bar.png b/notFinishedCode/pChart2.1.2/examples/resources/chart_bar.png
new file mode 100644
index 0000000..9051fbc
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/chart_bar.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/chart_line.png b/notFinishedCode/pChart2.1.2/examples/resources/chart_line.png
new file mode 100644
index 0000000..85020f3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/chart_line.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/computer.gif b/notFinishedCode/pChart2.1.2/examples/resources/computer.gif
new file mode 100644
index 0000000..197f090
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/computer.gif
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-blank.png b/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-blank.png
new file mode 100644
index 0000000..602da46
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-blank.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-last.png b/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-last.png
new file mode 100644
index 0000000..5226fbd
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-last.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-noleaf.png b/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-noleaf.png
new file mode 100644
index 0000000..159ca3c
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer-noleaf.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer.png b/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer.png
new file mode 100644
index 0000000..a3986d3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/dash-explorer.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/dash.png b/notFinishedCode/pChart2.1.2/examples/resources/dash.png
new file mode 100644
index 0000000..81cb49c
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/dash.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/dataset.txt b/notFinishedCode/pChart2.1.2/examples/resources/dataset.txt
new file mode 100644
index 0000000..6c0bb8f
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/dataset.txt
@@ -0,0 +1,25 @@
+Hour,Temperature,Humidity
+0,10,40
+1,9,41
+2,8,44
+3,8,42
+4,9,40
+5,9,38
+6,10,39
+7,11,35
+8,12,33
+9,14,32
+10,16,30
+11,18,30
+12,20,30
+13,21,31
+14,22,33
+15,23,34
+16,22,36
+17,20,37
+18,16,38
+19,14,38
+20,12,39
+21,11,40
+22,11,44
+23,10,40 \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/folder.png b/notFinishedCode/pChart2.1.2/examples/resources/folder.png
new file mode 100644
index 0000000..784e8fa
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/folder.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/hologram.png b/notFinishedCode/pChart2.1.2/examples/resources/hologram.png
new file mode 100644
index 0000000..2a962d3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/hologram.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/landscape1.jpg b/notFinishedCode/pChart2.1.2/examples/resources/landscape1.jpg
new file mode 100644
index 0000000..2166d3f
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/landscape1.jpg
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/landscape2.jpg b/notFinishedCode/pChart2.1.2/examples/resources/landscape2.jpg
new file mode 100644
index 0000000..5d416ef
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/landscape2.jpg
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/palette.txt b/notFinishedCode/pChart2.1.2/examples/resources/palette.txt
new file mode 100644
index 0000000..9081819
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/palette.txt
@@ -0,0 +1,6 @@
+239,210,121,100
+149,203,233,100
+2,71,105,100
+175,215,117,100
+44,87,0,100
+222,157,127,100
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/serie1.png b/notFinishedCode/pChart2.1.2/examples/resources/serie1.png
new file mode 100644
index 0000000..79f35cc
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/serie1.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/serie2.png b/notFinishedCode/pChart2.1.2/examples/resources/serie2.png
new file mode 100644
index 0000000..7fb4e1f
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/serie2.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/resources/wait.gif b/notFinishedCode/pChart2.1.2/examples/resources/wait.gif
new file mode 100644
index 0000000..1c72ebb
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/resources/wait.gif
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/accept.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/accept.png
new file mode 100644
index 0000000..89c8129
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/accept.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/application_form.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/application_form.png
new file mode 100644
index 0000000..807b862
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/application_form.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/background.console.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/background.console.png
new file mode 100644
index 0000000..b084354
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/background.console.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar.png
new file mode 100644
index 0000000..9051fbc
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar_edit.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar_edit.png
new file mode 100644
index 0000000..df64d97
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_bar_edit.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_curve.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_curve.png
new file mode 100644
index 0000000..01e933a
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_curve.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_line.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_line.png
new file mode 100644
index 0000000..85020f3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/chart_line.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/cog.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/cog.png
new file mode 100644
index 0000000..67de2c6
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/cog.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/color_swatch.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/color_swatch.png
new file mode 100644
index 0000000..6e6e852
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/color_swatch.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/comment.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/comment.png
new file mode 100644
index 0000000..7bc9233
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/comment.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/database_table.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/database_table.png
new file mode 100644
index 0000000..693709c
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/database_table.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/layout_edit.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/layout_edit.png
new file mode 100644
index 0000000..ab3100b
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/layout_edit.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/page_edit.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/page_edit.png
new file mode 100644
index 0000000..046811e
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/page_edit.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/paintcan.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/paintcan.png
new file mode 100644
index 0000000..f82a886
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/paintcan.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/shape_flip_vertical.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/shape_flip_vertical.png
new file mode 100644
index 0000000..0bd66d1
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/shape_flip_vertical.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/tab.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/tab.png
new file mode 100644
index 0000000..3d8207f
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/tab.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/vector.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/vector.png
new file mode 100644
index 0000000..a1291c2
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/vector.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wait.gif b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wait.gif
new file mode 100644
index 0000000..1c72ebb
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wait.gif
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wand.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wand.png
new file mode 100644
index 0000000..44ccbf8
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wand.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wrench.png b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wrench.png
new file mode 100644
index 0000000..5c8213f
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/graphix/wrench.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/arrow.gif b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/arrow.gif
new file mode 100644
index 0000000..246478a
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/arrow.gif
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/constants.txt b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/constants.txt
new file mode 100644
index 0000000..e1451a2
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/constants.txt
@@ -0,0 +1,61 @@
+0.12345,VOID
+680001,AXIS_FORMAT_DEFAULT
+680002,AXIS_FORMAT_TIME
+680003,AXIS_FORMAT_DATE
+680004,AXIS_FORMAT_METRIC
+680005,AXIS_FORMAT_CURRENCY
+681001,AXIS_POSITION_LEFT
+681002,AXIS_POSITION_RIGHT
+682001,AXIS_X
+682002,AXIS_Y
+690001,DIRECTION_VERTICAL
+690002,DIRECTION_HORIZONTAL
+690101,SCALE_POS_LEFTRIGHT
+690102,SCALE_POS_TOPBOTTOM
+690201,SCALE_MODE_FLOATING
+690202,SCALE_MODE_START0
+690203,SCALE_MODE_ADDALL
+690204,SCALE_MODE_ADDALL_START0
+690301,SCALE_SKIP_NONE
+690302,SCALE_SKIP_SAME
+690303,SCALE_SKIP_NUMBERS
+690401,TEXT_ALIGN_TOPLEFT
+690402,TEXT_ALIGN_TOPMIDDLE
+690403,TEXT_ALIGN_TOPRIGHT
+690404,TEXT_ALIGN_MIDDLELEFT
+690405,TEXT_ALIGN_MIDDLEMIDDLE
+690406,TEXT_ALIGN_MIDDLERIGHT
+690407,TEXT_ALIGN_BOTTOMLEFT
+690408,TEXT_ALIGN_BOTTOMMIDDLE
+690409,TEXT_ALIGN_BOTTOMRIGHT
+690501,POSITION_TOP
+690502,POSITION_BOTTOM
+690601,LABEL_POS_LEFT
+690602,LABEL_POS_CENTER
+690603,LABEL_POS_RIGHT
+690604,LABEL_POS_TOP
+690605,LABEL_POS_BOTTOM
+690606,LABEL_POS_INSIDE
+690607,LABEL_POS_OUTSIDE
+690701,ORIENTATION_HORIZONTAL
+690702,ORIENTATION_VERTICAL
+690800,LEGEND_NOBORDER
+690801,LEGEND_BOX
+690802,LEGEND_ROUND
+690901,LEGEND_VERTICAL
+690902,LEGEND_HORIZONTAL
+691051,LEGEND_FAMILY_BOX
+691052,LEGEND_FAMILY_CIRCLE
+691053,LEGEND_FAMILY_LINE
+691001,DISPLAY_AUTO
+691002,DISPLAY_MANUAL
+691011,LABELING_ALL
+691012,LABELING_DIFFERENT
+691021,BOUND_MIN
+691022,BOUND_MAX
+691023,BOUND_BOTH
+691031,BOUND_LABEL_POS_TOP
+691032,BOUND_LABEL_POS_BOTTOM
+691033,BOUND_LABEL_POS_AUTO
+691041,CAPTION_LEFT_TOP
+691042,CAPTION_RIGHT_BOTTOM \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/cross.gif b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/cross.gif
new file mode 100644
index 0000000..0ee9c7a
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/cross.gif
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/functions.js b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/functions.js
new file mode 100644
index 0000000..5eaf763
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/functions.js
@@ -0,0 +1,656 @@
+ /*
+ functions.js - Sandbox JS
+
+ Version : 1.1.0
+ Made by : Jean-Damien POGOLOTTI
+ Last Update : 18/01/11
+
+ This file can be distributed under the license you can find at :
+
+ http://www.pchart.net/license
+
+ You can find the whole class documentation on the pChart web site.
+ */
+
+ Action = "Render";
+
+ function toggleAuto()
+ {
+ if ( document.getElementById("g_autopos").checked ) { Automatic = true; } else { Automatic = false; }
+ }
+
+ function doLayout()
+ {
+ if ( !Automatic ) { return(0); }
+
+ g_width = document.getElementById("g_width").value;
+ g_height = document.getElementById("g_height").value;
+
+ document.getElementById("g_title_x").value = g_width/2;
+
+ checkEnabledAxis();
+ }
+
+ /* Apply curvy corners */
+ function applyCorners()
+ {
+ settings = {tl: { radius: 10 },tr: { radius: 10 },bl: { radius: 10 },br: { radius: 10 },antiAlias: true,autoPad: true,validTags: ["div"]}
+ var myBoxObject = new curvyCorners(settings, "roundedCorner");
+ myBoxObject.applyCornersToAll();
+ }
+
+ /* Set or remove the focus */
+ function setFocus(Object,Mode)
+ {
+ if (Mode == true)
+ { Object.style.borderColor = "#808080"; }
+ else
+ { Object.style.borderColor = "#D0D0D0"; }
+ }
+
+ function highlightDIV(ID)
+ {
+ if ( ID == CurrentDiv ) { return(0); }
+ document.getElementById("menu"+ID).style.backgroundColor = "#F4F4F4";
+ }
+
+ function clearDIV(ID)
+ {
+ if ( ID == CurrentDiv ) { return(0); }
+ document.getElementById("menu"+ID).style.backgroundColor = "#EAEAEA";
+ }
+
+ function toggleDIV(ID)
+ {
+ /* reset the tab styles */
+ for (i=1;i<=6;i++)
+ { if ( i != ID ) { document.getElementById("menu"+i).style.backgroundColor = "#EAEAEA"; document.getElementById("menu"+i).style.borderColor = "#FEFEFE"; } }
+
+ /* hide the curently displayed tab */
+ if ( CurrentDiv != ID ) { document.getElementById("tab"+CurrentDiv).style.display = "none"; }
+
+ document.getElementById("tab"+ID).style.display = "block";
+
+ CurrentDiv = ID;
+ document.getElementById("menu"+ID).style.backgroundColor = "#D0D0D0";
+ document.getElementById("menu"+ID).style.borderColor = "#B0B0B0";
+ }
+
+ function render()
+ {
+ Action = "Render";
+ saveToSession();
+ }
+
+ function code()
+ {
+ Action = "Code";
+ saveToSession();
+ }
+
+ function saveToSession()
+ {
+ saveGeneral();
+ }
+
+ function saveGeneral()
+ {
+ document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Saving configuration (General)";
+
+ g_width = document.getElementById("g_width").value;
+ g_height = document.getElementById("g_height").value;
+ g_border = document.getElementById("g_border").checked;
+ g_aa = document.getElementById("g_aa").checked;
+ g_shadow = document.getElementById("g_shadow").checked;
+ g_transparent = document.getElementById("g_transparent").checked;
+ g_autopos = document.getElementById("g_autopos").checked;
+
+ g_title_enabled = document.getElementById("g_title_enabled").checked;
+ g_title = document.getElementById("g_title").value;
+ g_title_align = document.getElementById("g_title_align").options[document.getElementById("g_title_align").selectedIndex].value;
+ g_title_x = document.getElementById("g_title_x").value;
+ g_title_y = document.getElementById("g_title_y").value;
+ g_title_color = document.getElementById("g_title_color").value;
+ g_title_font = document.getElementById("g_title_font").options[document.getElementById("g_title_font").selectedIndex].value;
+ g_title_font_size = document.getElementById("g_title_font_size").value;
+ g_title_box = document.getElementById("g_title_box").checked;
+
+ g_solid_enabled = document.getElementById("g_solid_enabled").checked;
+ g_solid_color = document.getElementById("g_solid_color").value;
+ g_solid_dashed = document.getElementById("g_solid_dashed").checked;
+
+ g_gradient_enabled = document.getElementById("g_gradient_enabled").checked;
+ g_gradient_start = document.getElementById("g_gradient_start").value;
+ g_gradient_end = document.getElementById("g_gradient_end").value;
+ g_gradient_direction = document.getElementById("g_gradient_direction").options[document.getElementById("g_gradient_direction").selectedIndex].value;
+ g_gradient_alpha = document.getElementById("g_gradient_alpha").value;
+
+ var reg=new RegExp("(#)", "g");
+ g_title_color = g_title_color.replace(reg,"");
+ g_solid_color = g_solid_color.replace(reg,"");
+ g_gradient_start = g_gradient_start.replace(reg,"");
+ g_gradient_end = g_gradient_end.replace(reg,"");
+
+ URL = "script/session.php?g_width="+g_width+"&g_height="+g_height+"&g_border="+g_border+"&g_aa="+g_aa+"&g_shadow="+g_shadow+"&g_autopos="+g_autopos
+ +"&g_title_enabled="+g_title_enabled+"&g_title="+g_title+"&g_title_align="+g_title_align+"&g_title_x="+g_title_x
+ +"&g_title_y="+g_title_y+"&g_title_color="+g_title_color+"&g_title_font="+g_title_font+"&g_title_font_size="+g_title_font_size+"&g_title_box="+g_title_box
+ +"&g_solid_enabled="+g_solid_enabled+"&g_solid_color="+g_solid_color+"&g_solid_dashed="+g_solid_dashed
+ +"&g_gradient_enabled="+g_gradient_enabled+"&g_gradient_start="+g_gradient_start+"&g_gradient_end="+g_gradient_end
+ +"&g_gradient_direction="+g_gradient_direction+"&g_gradient_alpha="+g_gradient_alpha+"&g_transparent="+g_transparent
+ +"&Seed="+Math.random(100);
+
+ push(URL,1);
+ }
+
+ function saveData()
+ {
+ document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Saving configuration (Data)";
+
+ d_serie1_enabled = document.getElementById("d_serie1_enabled").checked;
+ d_serie2_enabled = document.getElementById("d_serie2_enabled").checked;
+ d_serie3_enabled = document.getElementById("d_serie3_enabled").checked;
+ d_absissa_enabled = document.getElementById("d_absissa_enabled").checked;
+
+ d_serie1_name = document.getElementById("d_serie1_name").value;
+ d_serie2_name = document.getElementById("d_serie2_name").value;
+ d_serie3_name = document.getElementById("d_serie3_name").value;
+
+ d_serie1_axis = document.getElementById("d_serie1_axis").options[document.getElementById("d_serie1_axis").selectedIndex].value;
+ d_serie2_axis = document.getElementById("d_serie2_axis").options[document.getElementById("d_serie2_axis").selectedIndex].value;
+ d_serie3_axis = document.getElementById("d_serie3_axis").options[document.getElementById("d_serie3_axis").selectedIndex].value;
+
+ data0 = ""; data1 = ""; data2 = ""; absissa = "";
+ for(i=0;i<8;i++)
+ {
+ data0 = data0 + "!" + document.getElementById("d_serie1_data"+i).value;
+ data1 = data1 + "!" + document.getElementById("d_serie2_data"+i).value;
+ data2 = data2 + "!" + document.getElementById("d_serie3_data"+i).value;
+ absissa = absissa + "!" + document.getElementById("d_absissa_data"+i).value;
+ }
+
+ d_normalize_enabled = document.getElementById("d_normalize_enabled").checked;
+
+ d_axis0_name = document.getElementById("d_axis0_name").value;
+ d_axis1_name = document.getElementById("d_axis1_name").value;
+ d_axis2_name = document.getElementById("d_axis2_name").value;
+
+ d_axis0_unit = document.getElementById("d_axis0_unit").value;
+ d_axis1_unit = document.getElementById("d_axis1_unit").value;
+ d_axis2_unit = document.getElementById("d_axis2_unit").value;
+
+ d_axis0_position = document.getElementById("d_axis0_position").options[document.getElementById("d_axis0_position").selectedIndex].value;
+ d_axis1_position = document.getElementById("d_axis1_position").options[document.getElementById("d_axis1_position").selectedIndex].value;
+ d_axis2_position = document.getElementById("d_axis2_position").options[document.getElementById("d_axis2_position").selectedIndex].value;
+
+ d_axis0_format = document.getElementById("d_axis0_format").options[document.getElementById("d_axis0_format").selectedIndex].value;
+ d_axis1_format = document.getElementById("d_axis1_format").options[document.getElementById("d_axis1_format").selectedIndex].value;
+ d_axis2_format = document.getElementById("d_axis2_format").options[document.getElementById("d_axis2_format").selectedIndex].value;
+
+ URL = "script/session.php?d_serie1_enabled="+d_serie1_enabled+"&d_serie2_enabled="+d_serie2_enabled+"&d_serie3_enabled="+d_serie3_enabled
+ +"&d_absissa_enabled="+d_absissa_enabled+"&d_serie1_axis="+d_serie1_axis+"&d_serie2_axis="+d_serie2_axis+"&d_serie3_axis="+d_serie3_axis
+ +"&data0="+data0+"&data1="+data1+"&data2="+data2+"&absissa="+absissa+"&d_axis0_name="+d_axis0_name+"&d_axis1_name="+d_axis1_name
+ +"&d_axis2_name="+d_axis2_name+"&d_axis0_unit="+d_axis0_unit+"&d_axis1_unit="+d_axis1_unit+"&d_axis2_unit="+d_axis2_unit
+ +"&d_axis0_position="+d_axis0_position+"&d_axis1_position="+d_axis1_position+"&d_axis2_position="+d_axis2_position
+ +"&d_normalize_enabled="+d_normalize_enabled+"&d_serie1_name="+d_serie1_name+"&d_serie2_name="+d_serie2_name+"&d_serie3_name="+d_serie3_name
+ +"&d_axis0_format="+d_axis0_format+"&d_axis1_format="+d_axis1_format+"&d_axis2_format="+d_axis2_format;
+
+ push(URL,2);
+ }
+
+ function saveScale()
+ {
+ document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Saving configuration (Scale)";
+
+ s_x = document.getElementById("s_x").value;
+ s_y = document.getElementById("s_y").value;
+ s_width = document.getElementById("s_width").value;
+ s_height = document.getElementById("s_height").value;
+ s_direction = document.getElementById("s_direction").options[document.getElementById("s_direction").selectedIndex].value;
+ s_arrows_enabled = document.getElementById("s_arrows_enabled").checked;
+ s_mode = document.getElementById("s_mode").options[document.getElementById("s_mode").selectedIndex].value;
+ s_cycle_enabled = document.getElementById("s_cycle_enabled").checked;
+ s_x_margin = document.getElementById("s_x_margin").value;
+ s_y_margin = document.getElementById("s_y_margin").value;
+ s_automargin_enabled = document.getElementById("s_automargin_enabled").checked;
+ s_font = document.getElementById("s_font").options[document.getElementById("s_font").selectedIndex].value;
+ s_font_size = document.getElementById("s_font_size").value;
+ s_font_color = document.getElementById("s_font_color").value;
+
+ s_x_labeling = document.getElementById("s_x_labeling").options[document.getElementById("s_x_labeling").selectedIndex].value;
+ s_x_skip = document.getElementById("s_x_skip").value;
+ s_x_label_rotation = document.getElementById("s_x_label_rotation").value;
+
+ s_grid_color = document.getElementById("s_grid_color").value;
+ s_grid_alpha = document.getElementById("s_grid_alpha").value;
+ s_grid_x_enabled = document.getElementById("s_grid_x_enabled").checked;
+ s_grid_y_enabled = document.getElementById("s_grid_y_enabled").checked;
+
+ s_ticks_color = document.getElementById("s_ticks_color").value;
+ s_ticks_alpha = document.getElementById("s_ticks_alpha").value;
+ s_subticks_color = document.getElementById("s_subticks_color").value;
+ s_subticks_alpha = document.getElementById("s_subticks_alpha").value;
+ s_subticks_enabled = document.getElementById("s_subticks_enabled").checked;
+
+ URL = "script/session.php?s_x="+s_x+"&s_y="+s_y+"&s_width="+s_width+"&s_height="+s_height+"&s_direction="+s_direction
+ +"&s_arrows_enabled="+s_arrows_enabled+"&s_mode="+s_mode+"&s_cycle_enabled="+s_cycle_enabled+"&s_x_margin="+s_x_margin
+ +"&s_y_margin="+s_y_margin+"&s_automargin_enabled="+s_automargin_enabled+"&s_x_labeling="+s_x_labeling+"&s_x_skip="+s_x_skip
+ +"&s_x_label_rotation="+s_x_label_rotation+"&s_grid_color="+s_grid_color+"&s_grid_alpha="+s_grid_alpha+"&s_grid_x_enabled="+s_grid_x_enabled
+ +"&s_grid_y_enabled="+s_grid_y_enabled+"&s_ticks_color="+s_ticks_color+"&s_ticks_alpha="+s_ticks_alpha+"&s_subticks_color="+s_subticks_color
+ +"&s_subticks_alpha="+s_subticks_alpha+"&s_subticks_enabled="+s_subticks_enabled+"&s_font="+s_font+"&s_font_size="+s_font_size
+ +"&s_font_color="+s_font_color+"&Seed="+Math.random(100);
+
+ push(URL,3);
+ }
+
+ function saveChart()
+ {
+ document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Saving configuration (Chart)";
+
+ c_family = document.getElementById("c_family").options[document.getElementById("c_family").selectedIndex].value;
+ c_display_values = document.getElementById("c_display_values").checked;
+ c_break_color = document.getElementById("c_break_color").value;
+ c_break = document.getElementById("c_break").checked;
+
+ c_plot_size = document.getElementById("c_plot_size").value;
+ c_border_size = document.getElementById("c_border_size").value;
+ c_border_enabled = document.getElementById("c_border_enabled").checked;
+
+ c_bar_classic = document.getElementById("c_bar_classic").checked;
+ c_bar_rounded = document.getElementById("c_bar_rounded").checked;
+ c_bar_gradient = document.getElementById("c_bar_gradient").checked;
+ c_around_zero1 = document.getElementById("c_around_zero1").checked;
+
+ c_transparency = document.getElementById("c_transparency").value;
+ c_forced_transparency = document.getElementById("c_forced_transparency").checked;
+ c_around_zero2 = document.getElementById("c_around_zero2").checked;
+
+ URL = "script/session.php?c_family="+c_family+"&c_display_values="+c_display_values+"&c_plot_size="+c_plot_size+"&c_border_size="+c_border_size+"&c_border_enabled="+c_border_enabled
+ +"&c_bar_classic="+c_bar_classic+"&c_bar_rounded="+c_bar_rounded+"&c_bar_gradient="+c_bar_gradient+"&c_around_zero1="+c_around_zero1
+ +"&c_transparency="+c_transparency+"&c_forced_transparency="+c_forced_transparency+"&c_around_zero2="+c_around_zero2
+ +"&c_break="+c_break+"&c_break_color="+c_break_color;
+
+ push(URL,4);
+ }
+
+ function saveLegend()
+ {
+ document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Saving configuration (Legend and Thresholds)";
+
+ l_enabled = document.getElementById("l_enabled").checked;
+
+ l_font = document.getElementById("l_font").options[document.getElementById("l_font").selectedIndex].value;
+ l_font_size = document.getElementById("l_font_size").value;
+ l_font_color = document.getElementById("l_font_color").value;
+
+ l_margin = document.getElementById("l_margin").value;
+ l_alpha = document.getElementById("l_alpha").value;
+ l_format = document.getElementById("l_format").options[document.getElementById("l_format").selectedIndex].value;
+
+ l_orientation = document.getElementById("l_orientation").options[document.getElementById("l_orientation").selectedIndex].value;
+ l_box_size = document.getElementById("l_box_size").value;
+
+ l_position = document.getElementById("l_position").options[document.getElementById("l_position").selectedIndex].value;
+ l_x = document.getElementById("l_x").value;
+ l_y = document.getElementById("l_y").value;
+
+ l_family = document.getElementById("l_family").options[document.getElementById("l_family").selectedIndex].value;
+
+ t_enabled = document.getElementById("t_enabled").checked;
+
+ t_value = document.getElementById("t_value").value;
+ t_axis0 = document.getElementById("t_axis0").checked;
+ t_axis1 = document.getElementById("t_axis1").checked;
+ t_axis2 = document.getElementById("t_axis2").checked;
+
+ t_color = document.getElementById("t_color").value;
+ t_alpha = document.getElementById("t_alpha").value;
+ t_ticks = document.getElementById("t_ticks").checked;
+
+ t_caption = document.getElementById("t_caption").value;
+ t_box = document.getElementById("t_box").checked;
+ t_caption_enabled = document.getElementById("t_caption_enabled").checked;
+
+ sl_enabled = document.getElementById("sl_enabled").checked;
+ sl_shaded = document.getElementById("sl_shaded").checked;
+ sl_caption_enabled = document.getElementById("sl_caption_enabled").checked;
+ sl_caption_line = document.getElementById("sl_caption_line").checked;
+
+ p_template = document.getElementById("p_template").options[document.getElementById("p_template").selectedIndex].value;
+
+ if ( t_axis0 ) { t_axis = 0; }
+ if ( t_axis1 ) { t_axis = 1; }
+ if ( t_axis2 ) { t_axis = 2; }
+
+ URL = "script/session.php?l_enabled="+l_enabled+"&l_font="+l_font+"&l_font_size="+l_font_size+"&l_font_color="+l_font_color
+ +"&l_margin="+l_margin+"&l_alpha="+l_alpha+"&l_format="+l_format+"&l_orientation="+l_orientation+"&l_box_size="+l_box_size
+ +"&t_enabled="+t_enabled+"&t_value="+t_value+"&t_axis="+t_axis+"&t_color="+t_color+"&t_alpha="+t_alpha+"&t_ticks="+t_ticks
+ +"&t_caption="+t_caption+"&t_box="+t_box+"&t_caption_enabled="+t_caption_enabled+"&l_position="+l_position+"&l_x="+l_x+"&l_y="+l_y
+ +"&p_template="+p_template+"&l_family="+l_family+"&sl_enabled="+sl_enabled+"&sl_shaded="+sl_shaded+"&sl_caption_enabled="+sl_caption_enabled
+ +"&sl_caption_line="+sl_caption_line;
+
+ push(URL,5);
+ }
+
+ function randomize()
+ {
+ for(i=0;i<8;i++)
+ {
+ document.getElementById("d_serie1_data"+i).value = Math.ceil(Math.random()*100-50);
+ document.getElementById("d_serie2_data"+i).value = Math.ceil(Math.random()*100-50);
+ document.getElementById("d_serie3_data"+i).value = Math.ceil(Math.random()*100-50);
+ }
+ }
+
+ function setColors()
+ {
+ applyColor("g_title_color","g_title_color_show");
+ applyColor("g_solid_color","g_solid_color_show");
+ applyColor("g_gradient_start","g_gradient_start_show");
+ applyColor("g_gradient_end","g_gradient_end_show");
+ applyColor("s_font_color","s_font_color_show");
+ applyColor("s_grid_color","s_grid_color_show");
+ applyColor("s_ticks_color","s_ticks_color_show");
+ applyColor("s_subticks_color","s_subticks_color_show");
+ applyColor("l_font_color","l_font_color_show");
+ applyColor("t_color","t_color_show");
+ applyColor("c_break_color","c_break_color_show");
+ }
+
+ function applyColor(SourceID,TargetID)
+ {
+ color = document.getElementById(SourceID).value;
+ color = color.replace("#","");
+ document.getElementById(TargetID).style.backgroundColor = "#"+color;
+ }
+
+ function checkChartSettings()
+ {
+ ChartFamily = document.getElementById("c_family").options[document.getElementById("c_family").selectedIndex].value;
+
+ disableItem("c_plot_size"); disableItem("c_border_size"); disableCheck("c_border_enabled");
+ disableRadio("c_bar_classic"); disableRadio("c_bar_rounded"); disableRadio("c_bar_gradient"); disableCheck("c_around_zero1");
+ disableItem("c_transparency"); disableCheck("c_forced_transparency"); disableCheck("c_around_zero2");
+
+ if ( ChartFamily == "plot" )
+ { enableItem("c_plot_size"); enableItem("c_border_size"); enableCheck("c_border_enabled"); checkPlotBorder(); }
+
+ if ( ChartFamily == "bar" || ChartFamily == "sbar" )
+ { enableRadio("c_bar_classic"); enableRadio("c_bar_rounded"); enableRadio("c_bar_gradient"); enableCheck("c_around_zero1"); }
+
+ if ( ChartFamily == "fspline" || ChartFamily == "area" || ChartFamily == "sarea" || ChartFamily == "fstep" )
+ { enableItem("c_transparency"); enableCheck("c_forced_transparency"); enableCheck("c_around_zero2"); checkAreaChart(); }
+
+ if ( Automatic )
+ {
+ if ( ChartFamily == "sbar" || ChartFamily == "sarea" )
+ document.getElementById("s_mode").value = "SCALE_MODE_ADDALL";
+ else
+ document.getElementById("s_mode").value = "SCALE_MODE_FLOATING";
+ }
+ }
+
+ function checkLegend()
+ {
+ l_position = document.getElementById("l_position").options[document.getElementById("l_position").selectedIndex].value;
+
+ if ( l_position == "Manual" )
+ { enableItem("l_x"); enableItem("l_y"); }
+ else
+ { disableItem("l_x"); disableItem("l_y"); }
+ }
+
+ function checkPlotBorder()
+ {
+ borderEnabled = document.getElementById("c_border_enabled").checked;
+ if ( borderEnabled ) { enableItem("c_border_size"); } else { disableItem("c_border_size"); }
+ }
+
+ function checkAreaChart()
+ {
+ c_forced_transparency = document.getElementById("c_forced_transparency").checked;
+ if ( c_forced_transparency ) { enableItem("c_transparency"); } else { disableItem("c_transparency"); }
+ }
+
+ function toggleSubTicks()
+ {
+ if ( !document.getElementById("s_subticks_enabled").checked )
+ { disableItem("s_subticks_color"); disableItem("s_subticks_alpha"); }
+ else
+ { enableItem("s_subticks_color"); enableItem("s_subticks_alpha"); }
+ }
+
+ function toggleAutoMargins()
+ {
+ if ( document.getElementById("s_automargin_enabled").checked )
+ { disableItem("s_x_margin"); disableItem("s_y_margin"); }
+ else
+ { enableItem("s_x_margin"); enableItem("s_y_margin"); }
+ }
+
+ function checkEnabledAxis()
+ {
+ Serie1Enabled = document.getElementById("d_serie1_enabled").checked;
+ Serie2Enabled = document.getElementById("d_serie2_enabled").checked;
+ Serie3Enabled = document.getElementById("d_serie3_enabled").checked;
+ Serie1Binding = document.getElementById("d_serie1_axis").options[document.getElementById("d_serie1_axis").selectedIndex].value;
+ Serie2Binding = document.getElementById("d_serie2_axis").options[document.getElementById("d_serie2_axis").selectedIndex].value;
+ Serie3Binding = document.getElementById("d_serie3_axis").options[document.getElementById("d_serie3_axis").selectedIndex].value;
+
+ Series = 0;
+ if ( Serie1Enabled ) { Series++; }
+ if ( Serie2Enabled ) { Series++; }
+ if ( Serie3Enabled ) { Series++; }
+
+ if ( (Serie1Binding != 0 || !Serie1Enabled) && (Serie2Binding != 0 || !Serie2Enabled) && (Serie3Binding != 0 || !Serie3Enabled) )
+ { disableItem("d_axis0_name"); disableItem("d_axis0_unit"); disableItem("d_axis0_position"); disableItem("d_axis0_format"); }
+ else
+ { enableItem("d_axis0_name"); enableItem("d_axis0_unit"); enableItem("d_axis0_position"); enableItem("d_axis0_format"); }
+
+ if ( (Serie1Binding != 1 || !Serie1Enabled) && (Serie2Binding != 1 || !Serie2Enabled) && (Serie3Binding != 1 || !Serie3Enabled) )
+ { disableItem("d_axis1_name"); disableItem("d_axis1_unit"); disableItem("d_axis1_position"); disableItem("d_axis1_format"); }
+ else
+ { enableItem("d_axis1_name"); enableItem("d_axis1_unit"); enableItem("d_axis1_position"); enableItem("d_axis1_format"); }
+
+ if ( (Serie1Binding != 2 || !Serie1Enabled) && (Serie2Binding != 2 || !Serie2Enabled) && (Serie3Binding != 2 || !Serie3Enabled) )
+ { disableItem("d_axis2_name"); disableItem("d_axis2_unit"); disableItem("d_axis2_position"); disableItem("d_axis2_format"); }
+ else
+ { enableItem("d_axis2_name"); enableItem("d_axis2_unit"); enableItem("d_axis2_position"); enableItem("d_axis2_format"); }
+
+ if ( Automatic )
+ {
+ sl_enabled = document.getElementById("sl_enabled").checked;
+ g_width = document.getElementById("g_width").value;
+ g_height = document.getElementById("g_height").value;
+ s_direction = document.getElementById("s_direction").options[document.getElementById("s_direction").selectedIndex].value;
+
+ leftSeries = 0; rightSeries = 0;
+
+ if ( !document.getElementById("d_axis0_position").disabled && document.getElementById("d_axis0_position").options[document.getElementById("d_axis0_position").selectedIndex].value == "left" ) { leftSeries++; }
+ if ( !document.getElementById("d_axis0_position").disabled && document.getElementById("d_axis0_position").options[document.getElementById("d_axis0_position").selectedIndex].value == "right" ) { rightSeries++; }
+ if ( !document.getElementById("d_axis1_position").disabled && document.getElementById("d_axis1_position").options[document.getElementById("d_axis1_position").selectedIndex].value == "left" ) { leftSeries++; }
+ if ( !document.getElementById("d_axis1_position").disabled && document.getElementById("d_axis1_position").options[document.getElementById("d_axis1_position").selectedIndex].value == "right" ) { rightSeries++; }
+ if ( !document.getElementById("d_axis2_position").disabled && document.getElementById("d_axis2_position").options[document.getElementById("d_axis2_position").selectedIndex].value == "left" ) { leftSeries++; }
+ if ( !document.getElementById("d_axis2_position").disabled && document.getElementById("d_axis2_position").options[document.getElementById("d_axis2_position").selectedIndex].value == "right" ) { rightSeries++; }
+
+ if ( s_direction == "SCALE_POS_LEFTRIGHT" )
+ {
+ if ( leftSeries == 0 ) { leftOffset = 20; } else { leftOffset = 10; }
+ if ( rightSeries == 0 ) { rightOffset = 25; } else { rightOffset = 15; }
+
+ leftMargin = leftOffset + 40 * leftSeries;
+ width = g_width - leftMargin - 40 * rightSeries - rightOffset;
+
+ if ( sl_enabled ) { BottomOffset = Series*15; } else { BottomOffset = 0; }
+
+ document.getElementById("s_x").value = leftMargin;
+ document.getElementById("s_y").value = 50;
+ document.getElementById("s_width").value = width;
+ document.getElementById("s_height").value = g_height - 50 - 40 - BottomOffset;
+ }
+ else
+ {
+ if ( leftSeries == 0 ) { topOffset = 40; } else { topOffset = 40; }
+ if ( rightSeries == 0 ) { bottomOffset = 25; } else { bottomOffset = 15; }
+
+ topMargin = topOffset + 30 * leftSeries;
+ height = g_height - topMargin - 30 * rightSeries - bottomOffset;
+
+ if ( sl_enabled ) { RightOffset = Series*15; } else { RightBottomOffset = 0; }
+
+ document.getElementById("s_x").value = 70;
+ document.getElementById("s_y").value = topMargin;
+ document.getElementById("s_width").value = g_width - 70 - 40 - RightOffset;
+ document.getElementById("s_height").value = height;
+ }
+ }
+ }
+
+ function disableItem(ID)
+ {
+ document.getElementById(ID).style.backgroundColor = "#E0E0E0";
+ document.getElementById(ID).style.color = "#A0A0A0";
+ document.getElementById(ID).disabled = true;
+ }
+
+ function disableCheck(ID)
+ {
+ document.getElementById(ID).style.color = "#A0A0A0";
+ document.getElementById(ID).disabled = true;
+ }
+
+ function disableRadio(ID)
+ {
+ document.getElementById(ID).disabled = true;
+ }
+
+ function enableItem(ID)
+ {
+ document.getElementById(ID).style.backgroundColor = "#FFFFFF";
+ document.getElementById(ID).style.color = "#707070";
+ document.getElementById(ID).disabled = false;
+ }
+
+ function enableCheck(ID)
+ {
+ document.getElementById(ID).style.color = "#707070";
+ document.getElementById(ID).disabled = false;
+ }
+
+ function enableRadio(ID)
+ {
+ document.getElementById(ID).disabled = false;
+ }
+
+ function setDefaultAbsissa()
+ {
+ document.getElementById("d_absissa_data0").value = "January";
+ document.getElementById("d_absissa_data1").value = "February";
+ document.getElementById("d_absissa_data2").value = "March";
+ document.getElementById("d_absissa_data3").value = "April";
+ document.getElementById("d_absissa_data4").value = "May";
+ document.getElementById("d_absissa_data5").value = "June";
+ document.getElementById("d_absissa_data6").value = "July";
+ document.getElementById("d_absissa_data7").value = "August";
+ }
+
+ function push(URL,nextStep)
+ {
+ var xmlhttp=false;
+ /*@cc_on @*/
+ /*@if (@_jscript_version >= 5)
+ try { xmlhttp = new ActiveXObject("Msxml2.XMLHTTP"); } catch (e) { try { xmlhttp = new ActiveXObject("Microsoft.XMLHTTP"); } catch (E) { xmlhttp = false; } }
+ @end @*/
+
+ if (!xmlhttp && typeof XMLHttpRequest!='undefined')
+ { try { xmlhttp = new XMLHttpRequest(); } catch (e) { xmlhttp=false; } }
+
+ if (!xmlhttp && window.createRequest)
+ { try { xmlhttp = window.createRequest(); } catch (e) { xmlhttp=false; } }
+
+ xmlhttp.open("GET", URL,true);
+
+ xmlhttp.onreadystatechange=function() {
+ if (xmlhttp.readyState==4)
+ {
+ if ( nextStep == 1 ) { saveData(); }
+ if ( nextStep == 2 ) { saveScale(); }
+ if ( nextStep == 3 ) { saveChart(); }
+ if ( nextStep == 4 ) { saveLegend(); }
+ if ( nextStep == 5 )
+ {
+ if ( Action == "Render" )
+ doRender();
+ else
+ push("script/render.php?Mode=Source&Seed="+Math.random(100),6);
+ }
+ if ( nextStep == 6 )
+ {
+ document.getElementById("result_area").innerHTML = "<pre name='code'>"+xmlhttp.responseText+"</pre>";
+ }
+ }
+ }
+ xmlhttp.send(null)
+ }
+
+ function doRender()
+ {
+ document.getElementById("result_area").innerHTML = "<img src='graphix/wait.gif' width='24' height='24' alt=''><br/>Rendering";
+
+ RandomKey = Math.random(100);
+ URL = "script/render.php?Seed=" + RandomKey;
+
+ StartFade();
+ }
+
+ function StartFade()
+ {
+ Loader = new Image();
+ Loader.src = URL;
+ setTimeout("CheckLoadingStatus()", 200);
+ }
+
+ function CheckLoadingStatus()
+ {
+ if ( Loader.complete == true )
+ {
+ changeOpac(0, "result_area");
+ HTMLResult = "<center><img src='" + URL + "' alt=''/></center>";
+ document.getElementById("result_area").innerHTML = HTMLResult;
+
+ opacity("result_area",0,100,500);
+ }
+ else
+ setTimeout("CheckLoadingStatus()", 200);
+ }
+
+ function changeOpac(opacity, id)
+ {
+ var object = document.getElementById(id).style;
+ object.opacity = (opacity / 100);
+ object.MozOpacity = (opacity / 100);
+ object.KhtmlOpacity = (opacity / 100);
+ object.filter = "alpha(opacity=" + opacity + ")";
+ }
+
+ function opacity(id, opacStart, opacEnd, millisec)
+ {
+ var speed = Math.round(millisec / 100);
+ var timer = 0;
+
+ if(opacStart > opacEnd)
+ {
+ for(i = opacStart; i >= opacEnd; i--)
+ {
+ setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed));
+ timer++;
+ }
+ }
+ else if(opacStart < opacEnd)
+ {
+ for(i = opacStart; i <= opacEnd; i++)
+ {
+ setTimeout("changeOpac(" + i + ",'" + id + "')",(timer * speed));
+ timer++;
+ }
+ }
+ } \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hs.png b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hs.png
new file mode 100644
index 0000000..3d94486
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hs.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hv.png b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hv.png
new file mode 100644
index 0000000..1c5e01f
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/hv.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/jscolor.js b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/jscolor.js
new file mode 100644
index 0000000..c2f5aae
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/jscolor.js
@@ -0,0 +1,841 @@
+/**
+ * jscolor, JavaScript Color Picker
+ *
+ * @version 1.3.1
+ * @license GNU Lesser General Public License, http://www.gnu.org/copyleft/lesser.html
+ * @author Jan Odvarko, http://odvarko.cz
+ * @created 2008-06-15
+ * @updated 2010-01-23
+ * @link http://jscolor.com
+ */
+
+
+var jscolor = {
+
+
+ dir : '', // location of jscolor directory (leave empty to autodetect)
+ bindClass : 'color', // class name
+ binding : true, // automatic binding via <input class="...">
+ preloading : true, // use image preloading?
+
+
+ install : function() {
+ jscolor.addEvent(window, 'load', jscolor.init);
+ },
+
+
+ init : function() {
+ if(jscolor.binding) {
+ jscolor.bind();
+ }
+ if(jscolor.preloading) {
+ jscolor.preload();
+ }
+ },
+
+
+ getDir : function() {
+ if(!jscolor.dir) {
+ var detected = jscolor.detectDir();
+ jscolor.dir = detected!==false ? detected : 'jscolor/';
+ }
+ return jscolor.dir;
+ },
+
+
+ detectDir : function() {
+ var base = location.href;
+
+ var e = document.getElementsByTagName('base');
+ for(var i=0; i<e.length; i+=1) {
+ if(e[i].href) { base = e[i].href; }
+ }
+
+ var e = document.getElementsByTagName('script');
+ for(var i=0; i<e.length; i+=1) {
+ if(e[i].src && /(^|\/)jscolor\.js([?#].*)?$/i.test(e[i].src)) {
+ var src = new jscolor.URI(e[i].src);
+ var srcAbs = src.toAbsolute(base);
+ srcAbs.path = srcAbs.path.replace(/[^\/]+$/, ''); // remove filename
+ srcAbs.query = null;
+ srcAbs.fragment = null;
+ return srcAbs.toString();
+ }
+ }
+ return false;
+ },
+
+
+ bind : function() {
+ var matchClass = new RegExp('(^|\\s)('+jscolor.bindClass+')\\s*(\\{[^}]*\\})?', 'i');
+ var e = document.getElementsByTagName('input');
+ for(var i=0; i<e.length; i+=1) {
+ var m;
+ if(!e[i].color && e[i].className && (m = e[i].className.match(matchClass))) {
+ var prop = {};
+ if(m[3]) {
+ try {
+ eval('prop='+m[3]);
+ } catch(eInvalidProp) {}
+ }
+ e[i].color = new jscolor.color(e[i], prop);
+ }
+ }
+ },
+
+
+ preload : function() {
+ for(var fn in jscolor.imgRequire) {
+ if(jscolor.imgRequire.hasOwnProperty(fn)) {
+ jscolor.loadImage(fn);
+ }
+ }
+ },
+
+
+ images : {
+ pad : [ 181, 101 ],
+ sld : [ 16, 101 ],
+ cross : [ 15, 15 ],
+ arrow : [ 7, 11 ]
+ },
+
+
+ imgRequire : {},
+ imgLoaded : {},
+
+
+ requireImage : function(filename) {
+ jscolor.imgRequire[filename] = true;
+ },
+
+
+ loadImage : function(filename) {
+ if(!jscolor.imgLoaded[filename]) {
+ jscolor.imgLoaded[filename] = new Image();
+ jscolor.imgLoaded[filename].src = jscolor.getDir()+filename;
+ }
+ },
+
+
+ fetchElement : function(mixed) {
+ return typeof mixed === 'string' ? document.getElementById(mixed) : mixed;
+ },
+
+
+ addEvent : function(el, evnt, func) {
+ if(el.addEventListener) {
+ el.addEventListener(evnt, func, false);
+ } else if(el.attachEvent) {
+ el.attachEvent('on'+evnt, func);
+ }
+ },
+
+
+ fireEvent : function(el, evnt) {
+ if(!el) {
+ return;
+ }
+ if(document.createEventObject) {
+ var ev = document.createEventObject();
+ el.fireEvent('on'+evnt, ev);
+ } else if(document.createEvent) {
+ var ev = document.createEvent('HTMLEvents');
+ ev.initEvent(evnt, true, true);
+ el.dispatchEvent(ev);
+ } else if(el['on'+evnt]) { // alternatively use the traditional event model (IE5)
+ el['on'+evnt]();
+ }
+ },
+
+
+ getElementPos : function(e) {
+ var e1=e, e2=e;
+ var x=0, y=0;
+ if(e1.offsetParent) {
+ do {
+ x += e1.offsetLeft;
+ y += e1.offsetTop;
+ } while(e1 = e1.offsetParent);
+ }
+ while((e2 = e2.parentNode) && e2.nodeName.toUpperCase() !== 'BODY') {
+ x -= e2.scrollLeft;
+ y -= e2.scrollTop;
+ }
+ return [x, y];
+ },
+
+
+ getElementSize : function(e) {
+ return [e.offsetWidth, e.offsetHeight];
+ },
+
+
+ getMousePos : function(e) {
+ if(!e) { e = window.event; }
+ if(typeof e.pageX === 'number') {
+ return [e.pageX, e.pageY];
+ } else if(typeof e.clientX === 'number') {
+ return [
+ e.clientX + document.body.scrollLeft + document.documentElement.scrollLeft,
+ e.clientY + document.body.scrollTop + document.documentElement.scrollTop
+ ];
+ }
+ },
+
+
+ getViewPos : function() {
+ if(typeof window.pageYOffset === 'number') {
+ return [window.pageXOffset, window.pageYOffset];
+ } else if(document.body && (document.body.scrollLeft || document.body.scrollTop)) {
+ return [document.body.scrollLeft, document.body.scrollTop];
+ } else if(document.documentElement && (document.documentElement.scrollLeft || document.documentElement.scrollTop)) {
+ return [document.documentElement.scrollLeft, document.documentElement.scrollTop];
+ } else {
+ return [0, 0];
+ }
+ },
+
+
+ getViewSize : function() {
+ if(typeof window.innerWidth === 'number') {
+ return [window.innerWidth, window.innerHeight];
+ } else if(document.body && (document.body.clientWidth || document.body.clientHeight)) {
+ return [document.body.clientWidth, document.body.clientHeight];
+ } else if(document.documentElement && (document.documentElement.clientWidth || document.documentElement.clientHeight)) {
+ return [document.documentElement.clientWidth, document.documentElement.clientHeight];
+ } else {
+ return [0, 0];
+ }
+ },
+
+
+ URI : function(uri) { // See RFC3986
+
+ this.scheme = null;
+ this.authority = null;
+ this.path = '';
+ this.query = null;
+ this.fragment = null;
+
+ this.parse = function(uri) {
+ var m = uri.match(/^(([A-Za-z][0-9A-Za-z+.-]*)(:))?((\/\/)([^\/?#]*))?([^?#]*)((\?)([^#]*))?((#)(.*))?/);
+ this.scheme = m[3] ? m[2] : null;
+ this.authority = m[5] ? m[6] : null;
+ this.path = m[7];
+ this.query = m[9] ? m[10] : null;
+ this.fragment = m[12] ? m[13] : null;
+ return this;
+ };
+
+ this.toString = function() {
+ var result = '';
+ if(this.scheme !== null) { result = result + this.scheme + ':'; }
+ if(this.authority !== null) { result = result + '//' + this.authority; }
+ if(this.path !== null) { result = result + this.path; }
+ if(this.query !== null) { result = result + '?' + this.query; }
+ if(this.fragment !== null) { result = result + '#' + this.fragment; }
+ return result;
+ };
+
+ this.toAbsolute = function(base) {
+ var base = new jscolor.URI(base);
+ var r = this;
+ var t = new jscolor.URI;
+
+ if(base.scheme === null) { return false; }
+
+ if(r.scheme !== null && r.scheme.toLowerCase() === base.scheme.toLowerCase()) {
+ r.scheme = null;
+ }
+
+ if(r.scheme !== null) {
+ t.scheme = r.scheme;
+ t.authority = r.authority;
+ t.path = removeDotSegments(r.path);
+ t.query = r.query;
+ } else {
+ if(r.authority !== null) {
+ t.authority = r.authority;
+ t.path = removeDotSegments(r.path);
+ t.query = r.query;
+ } else {
+ if(r.path === '') { // TODO: == or === ?
+ t.path = base.path;
+ if(r.query !== null) {
+ t.query = r.query;
+ } else {
+ t.query = base.query;
+ }
+ } else {
+ if(r.path.substr(0,1) === '/') {
+ t.path = removeDotSegments(r.path);
+ } else {
+ if(base.authority !== null && base.path === '') { // TODO: == or === ?
+ t.path = '/'+r.path;
+ } else {
+ t.path = base.path.replace(/[^\/]+$/,'')+r.path;
+ }
+ t.path = removeDotSegments(t.path);
+ }
+ t.query = r.query;
+ }
+ t.authority = base.authority;
+ }
+ t.scheme = base.scheme;
+ }
+ t.fragment = r.fragment;
+
+ return t;
+ };
+
+ function removeDotSegments(path) {
+ var out = '';
+ while(path) {
+ if(path.substr(0,3)==='../' || path.substr(0,2)==='./') {
+ path = path.replace(/^\.+/,'').substr(1);
+ } else if(path.substr(0,3)==='/./' || path==='/.') {
+ path = '/'+path.substr(3);
+ } else if(path.substr(0,4)==='/../' || path==='/..') {
+ path = '/'+path.substr(4);
+ out = out.replace(/\/?[^\/]*$/, '');
+ } else if(path==='.' || path==='..') {
+ path = '';
+ } else {
+ var rm = path.match(/^\/?[^\/]*/)[0];
+ path = path.substr(rm.length);
+ out = out + rm;
+ }
+ }
+ return out;
+ }
+
+ if(uri) {
+ this.parse(uri);
+ }
+
+ },
+
+
+ /*
+ * Usage example:
+ * var myColor = new jscolor.color(myInputElement)
+ */
+
+ color : function(target, prop) {
+
+
+ this.required = true; // refuse empty values?
+ this.adjust = true; // adjust value to uniform notation?
+ this.hash = false; // prefix color with # symbol?
+ this.caps = true; // uppercase?
+ this.valueElement = target; // value holder
+ this.styleElement = target; // where to reflect current color
+ this.hsv = [0, 0, 1]; // read-only 0-6, 0-1, 0-1
+ this.rgb = [1, 1, 1]; // read-only 0-1, 0-1, 0-1
+
+ this.pickerOnfocus = true; // display picker on focus?
+ this.pickerMode = 'HSV'; // HSV | HVS
+ this.pickerPosition = 'bottom'; // left | right | top | bottom
+ this.pickerFace = 10; // px
+ this.pickerFaceColor = 'ThreeDFace'; // CSS color
+ this.pickerBorder = 1; // px
+ this.pickerBorderColor = 'ThreeDHighlight ThreeDShadow ThreeDShadow ThreeDHighlight'; // CSS color
+ this.pickerInset = 1; // px
+ this.pickerInsetColor = 'ThreeDShadow ThreeDHighlight ThreeDHighlight ThreeDShadow'; // CSS color
+ this.pickerZIndex = 10000;
+
+
+ for(var p in prop) {
+ if(prop.hasOwnProperty(p)) {
+ this[p] = prop[p];
+ }
+ }
+
+
+ this.hidePicker = function() {
+ if(isPickerOwner()) {
+ removePicker();
+ }
+ };
+
+
+ this.showPicker = function() {
+ if(!isPickerOwner()) {
+ var tp = jscolor.getElementPos(target); // target pos
+ var ts = jscolor.getElementSize(target); // target size
+ var vp = jscolor.getViewPos(); // view pos
+ var vs = jscolor.getViewSize(); // view size
+ var ps = [ // picker size
+ 2*this.pickerBorder + 4*this.pickerInset + 2*this.pickerFace + jscolor.images.pad[0] + 2*jscolor.images.arrow[0] + jscolor.images.sld[0],
+ 2*this.pickerBorder + 2*this.pickerInset + 2*this.pickerFace + jscolor.images.pad[1]
+ ];
+ var a, b, c;
+ switch(this.pickerPosition.toLowerCase()) {
+ case 'left': a=1; b=0; c=-1; break;
+ case 'right':a=1; b=0; c=1; break;
+ case 'top': a=0; b=1; c=-1; break;
+ default: a=0; b=1; c=1; break;
+ }
+ var l = (ts[b]+ps[b])/2;
+ var pp = [ // picker pos
+ -vp[a]+tp[a]+ps[a] > vs[a] ?
+ (-vp[a]+tp[a]+ts[a]/2 > vs[a]/2 && tp[a]+ts[a]-ps[a] >= 0 ? tp[a]+ts[a]-ps[a] : tp[a]) :
+ tp[a],
+ -vp[b]+tp[b]+ts[b]+ps[b]-l+l*c > vs[b] ?
+ (-vp[b]+tp[b]+ts[b]/2 > vs[b]/2 && tp[b]+ts[b]-l-l*c >= 0 ? tp[b]+ts[b]-l-l*c : tp[b]+ts[b]-l+l*c) :
+ (tp[b]+ts[b]-l+l*c >= 0 ? tp[b]+ts[b]-l+l*c : tp[b]+ts[b]-l-l*c)
+ ];
+ drawPicker(pp[a], pp[b]);
+ }
+ };
+
+
+ this.importColor = function() {
+ if(!valueElement) {
+ this.exportColor();
+ } else {
+ if(!this.adjust) {
+ if(!this.fromString(valueElement.value, leaveValue)) {
+ styleElement.style.backgroundColor = styleElement.jscStyle.backgroundColor;
+ styleElement.style.color = styleElement.jscStyle.color;
+ this.exportColor(leaveValue | leaveStyle);
+ }
+ } else if(!this.required && /^\s*$/.test(valueElement.value)) {
+ valueElement.value = '';
+ styleElement.style.backgroundColor = styleElement.jscStyle.backgroundColor;
+ styleElement.style.color = styleElement.jscStyle.color;
+ this.exportColor(leaveValue | leaveStyle);
+
+ } else if(this.fromString(valueElement.value)) {
+ // OK
+ } else {
+ this.exportColor();
+ }
+ }
+ };
+
+
+ this.exportColor = function(flags) {
+ if(!(flags & leaveValue) && valueElement) {
+ var value = this.toString();
+ if(this.caps) { value = value.toUpperCase(); }
+ if(this.hash) { value = '#'+value; }
+ valueElement.value = value;
+ }
+ if(!(flags & leaveStyle) && styleElement) {
+/*
+ styleElement.style.backgroundColor = '#'+this.toString();
+ styleElement.style.color =
+ 0.213 * this.rgb[0] +
+ 0.715 * this.rgb[1] +
+ 0.072 * this.rgb[2]
+ < 0.5 ? '#FFF' : '#000';
+*/
+ }
+ if(!(flags & leavePad) && isPickerOwner()) {
+ redrawPad();
+ }
+ if(!(flags & leaveSld) && isPickerOwner()) {
+ redrawSld();
+ }
+ };
+
+
+ this.fromHSV = function(h, s, v, flags) { // null = don't change
+ h<0 && (h=0) || h>6 && (h=6);
+ s<0 && (s=0) || s>1 && (s=1);
+ v<0 && (v=0) || v>1 && (v=1);
+ this.rgb = HSV_RGB(
+ h===null ? this.hsv[0] : (this.hsv[0]=h),
+ s===null ? this.hsv[1] : (this.hsv[1]=s),
+ v===null ? this.hsv[2] : (this.hsv[2]=v)
+ );
+ this.exportColor(flags);
+ };
+
+
+ this.fromRGB = function(r, g, b, flags) { // null = don't change
+ r<0 && (r=0) || r>1 && (r=1);
+ g<0 && (g=0) || g>1 && (g=1);
+ b<0 && (b=0) || b>1 && (b=1);
+ var hsv = RGB_HSV(
+ r===null ? this.rgb[0] : (this.rgb[0]=r),
+ g===null ? this.rgb[1] : (this.rgb[1]=g),
+ b===null ? this.rgb[2] : (this.rgb[2]=b)
+ );
+ if(hsv[0] !== null) {
+ this.hsv[0] = hsv[0];
+ }
+ if(hsv[2] !== 0) {
+ this.hsv[1] = hsv[1];
+ }
+ this.hsv[2] = hsv[2];
+ this.exportColor(flags);
+ };
+
+
+ this.fromString = function(hex, flags) {
+ var m = hex.match(/^\W*([0-9A-F]{3}([0-9A-F]{3})?)\W*$/i);
+ if(!m) {
+ return false;
+ } else {
+ if(m[1].length === 6) { // 6-char notation
+ this.fromRGB(
+ parseInt(m[1].substr(0,2),16) / 255,
+ parseInt(m[1].substr(2,2),16) / 255,
+ parseInt(m[1].substr(4,2),16) / 255,
+ flags
+ );
+ } else { // 3-char notation
+ this.fromRGB(
+ parseInt(m[1].charAt(0)+m[1].charAt(0),16) / 255,
+ parseInt(m[1].charAt(1)+m[1].charAt(1),16) / 255,
+ parseInt(m[1].charAt(2)+m[1].charAt(2),16) / 255,
+ flags
+ );
+ }
+ return true;
+ }
+ };
+
+
+ this.toString = function() {
+ return (
+ (0x100 | Math.round(255*this.rgb[0])).toString(16).substr(1) +
+ (0x100 | Math.round(255*this.rgb[1])).toString(16).substr(1) +
+ (0x100 | Math.round(255*this.rgb[2])).toString(16).substr(1)
+ );
+ };
+
+
+ function RGB_HSV(r, g, b) {
+ var n = Math.min(Math.min(r,g),b);
+ var v = Math.max(Math.max(r,g),b);
+ var m = v - n;
+ if(m === 0) { return [ null, 0, v ]; }
+ var h = r===n ? 3+(b-g)/m : (g===n ? 5+(r-b)/m : 1+(g-r)/m);
+ return [ h===6?0:h, m/v, v ];
+ }
+
+
+ function HSV_RGB(h, s, v) {
+ if(h === null) { return [ v, v, v ]; }
+ var i = Math.floor(h);
+ var f = i%2 ? h-i : 1-(h-i);
+ var m = v * (1 - s);
+ var n = v * (1 - s*f);
+ switch(i) {
+ case 6:
+ case 0: return [v,n,m];
+ case 1: return [n,v,m];
+ case 2: return [m,v,n];
+ case 3: return [m,n,v];
+ case 4: return [n,m,v];
+ case 5: return [v,m,n];
+ }
+ }
+
+
+ function removePicker() {
+ delete jscolor.picker.owner;
+ document.getElementsByTagName('body')[0].removeChild(jscolor.picker.boxB);
+ }
+
+
+ function drawPicker(x, y) {
+ if(!jscolor.picker) {
+ jscolor.picker = {
+ box : document.createElement('div'),
+ boxB : document.createElement('div'),
+ pad : document.createElement('div'),
+ padB : document.createElement('div'),
+ padM : document.createElement('div'),
+ sld : document.createElement('div'),
+ sldB : document.createElement('div'),
+ sldM : document.createElement('div')
+ };
+ for(var i=0,segSize=4; i<jscolor.images.sld[1]; i+=segSize) {
+ var seg = document.createElement('div');
+ seg.style.height = segSize+'px';
+ seg.style.fontSize = '1px';
+ seg.style.lineHeight = '0';
+ jscolor.picker.sld.appendChild(seg);
+ }
+ jscolor.picker.sldB.appendChild(jscolor.picker.sld);
+ jscolor.picker.box.appendChild(jscolor.picker.sldB);
+ jscolor.picker.box.appendChild(jscolor.picker.sldM);
+ jscolor.picker.padB.appendChild(jscolor.picker.pad);
+ jscolor.picker.box.appendChild(jscolor.picker.padB);
+ jscolor.picker.box.appendChild(jscolor.picker.padM);
+ jscolor.picker.boxB.appendChild(jscolor.picker.box);
+ }
+
+ var p = jscolor.picker;
+
+ // recompute controls positions
+ posPad = [
+ x+THIS.pickerBorder+THIS.pickerFace+THIS.pickerInset,
+ y+THIS.pickerBorder+THIS.pickerFace+THIS.pickerInset ];
+ posSld = [
+ null,
+ y+THIS.pickerBorder+THIS.pickerFace+THIS.pickerInset ];
+
+ // controls interaction
+ p.box.onmouseup =
+ p.box.onmouseout = function() { target.focus(); };
+ p.box.onmousedown = function() { abortBlur=true; };
+ p.box.onmousemove = function(e) { holdPad && setPad(e); holdSld && setSld(e); };
+ p.padM.onmouseup =
+ p.padM.onmouseout = function() { if(holdPad) { holdPad=false; jscolor.fireEvent(valueElement,'change'); } };
+ p.padM.onmousedown = function(e) { holdPad=true; setPad(e); };
+ p.sldM.onmouseup =
+ p.sldM.onmouseout = function() { if(holdSld) { holdSld=false; jscolor.fireEvent(valueElement,'change'); } };
+ p.sldM.onmousedown = function(e) { holdSld=true; setSld(e); };
+
+ // picker
+ p.box.style.width = 4*THIS.pickerInset + 2*THIS.pickerFace + jscolor.images.pad[0] + 2*jscolor.images.arrow[0] + jscolor.images.sld[0] + 'px';
+ p.box.style.height = 2*THIS.pickerInset + 2*THIS.pickerFace + jscolor.images.pad[1] + 'px';
+
+ // picker border
+ p.boxB.style.position = 'absolute';
+ p.boxB.style.clear = 'both';
+ p.boxB.style.left = x+'px';
+ p.boxB.style.top = y+'px';
+ p.boxB.style.zIndex = THIS.pickerZIndex;
+ p.boxB.style.border = THIS.pickerBorder+'px solid';
+ p.boxB.style.borderColor = THIS.pickerBorderColor;
+ p.boxB.style.background = THIS.pickerFaceColor;
+
+ // pad image
+ p.pad.style.width = jscolor.images.pad[0]+'px';
+ p.pad.style.height = jscolor.images.pad[1]+'px';
+
+ // pad border
+ p.padB.style.position = 'absolute';
+ p.padB.style.left = THIS.pickerFace+'px';
+ p.padB.style.top = THIS.pickerFace+'px';
+ p.padB.style.border = THIS.pickerInset+'px solid';
+ p.padB.style.borderColor = THIS.pickerInsetColor;
+
+ // pad mouse area
+ p.padM.style.position = 'absolute';
+ p.padM.style.left = '0';
+ p.padM.style.top = '0';
+ p.padM.style.width = THIS.pickerFace + 2*THIS.pickerInset + jscolor.images.pad[0] + jscolor.images.arrow[0] + 'px';
+ p.padM.style.height = p.box.style.height;
+ p.padM.style.cursor = 'crosshair';
+
+ // slider image
+ p.sld.style.overflow = 'hidden';
+ p.sld.style.width = jscolor.images.sld[0]+'px';
+ p.sld.style.height = jscolor.images.sld[1]+'px';
+
+ // slider border
+ p.sldB.style.position = 'absolute';
+ p.sldB.style.right = THIS.pickerFace+'px';
+ p.sldB.style.top = THIS.pickerFace+'px';
+ p.sldB.style.border = THIS.pickerInset+'px solid';
+ p.sldB.style.borderColor = THIS.pickerInsetColor;
+
+ // slider mouse area
+ p.sldM.style.position = 'absolute';
+ p.sldM.style.right = '0';
+ p.sldM.style.top = '0';
+ p.sldM.style.width = jscolor.images.sld[0] + jscolor.images.arrow[0] + THIS.pickerFace + 2*THIS.pickerInset + 'px';
+ p.sldM.style.height = p.box.style.height;
+ try {
+ p.sldM.style.cursor = 'pointer';
+ } catch(eOldIE) {
+ p.sldM.style.cursor = 'hand';
+ }
+
+ // load images in optimal order
+ switch(modeID) {
+ case 0: var padImg = 'hs.png'; break;
+ case 1: var padImg = 'hv.png'; break;
+ }
+ p.padM.style.background = "url('"+jscolor.getDir()+"cross.gif') no-repeat";
+ p.sldM.style.background = "url('"+jscolor.getDir()+"arrow.gif') no-repeat";
+ p.pad.style.background = "url('"+jscolor.getDir()+padImg+"') 0 0 no-repeat";
+
+ // place pointers
+ redrawPad();
+ redrawSld();
+
+ jscolor.picker.owner = THIS;
+ document.getElementsByTagName('body')[0].appendChild(p.boxB);
+ }
+
+
+ function redrawPad() {
+ // redraw the pad pointer
+ switch(modeID) {
+ case 0: var yComponent = 1; break;
+ case 1: var yComponent = 2; break;
+ }
+ var x = Math.round((THIS.hsv[0]/6) * (jscolor.images.pad[0]-1));
+ var y = Math.round((1-THIS.hsv[yComponent]) * (jscolor.images.pad[1]-1));
+ jscolor.picker.padM.style.backgroundPosition =
+ (THIS.pickerFace+THIS.pickerInset+x - Math.floor(jscolor.images.cross[0]/2)) + 'px ' +
+ (THIS.pickerFace+THIS.pickerInset+y - Math.floor(jscolor.images.cross[1]/2)) + 'px';
+
+ // redraw the slider image
+ var seg = jscolor.picker.sld.childNodes;
+
+ switch(modeID) {
+ case 0:
+ var rgb = HSV_RGB(THIS.hsv[0], THIS.hsv[1], 1);
+ for(var i=0; i<seg.length; i+=1) {
+ seg[i].style.backgroundColor = 'rgb('+
+ (rgb[0]*(1-i/seg.length)*100)+'%,'+
+ (rgb[1]*(1-i/seg.length)*100)+'%,'+
+ (rgb[2]*(1-i/seg.length)*100)+'%)';
+ }
+ break;
+ case 1:
+ var rgb, s, c = [ THIS.hsv[2], 0, 0 ];
+ var i = Math.floor(THIS.hsv[0]);
+ var f = i%2 ? THIS.hsv[0]-i : 1-(THIS.hsv[0]-i);
+ switch(i) {
+ case 6:
+ case 0: rgb=[0,1,2]; break;
+ case 1: rgb=[1,0,2]; break;
+ case 2: rgb=[2,0,1]; break;
+ case 3: rgb=[2,1,0]; break;
+ case 4: rgb=[1,2,0]; break;
+ case 5: rgb=[0,2,1]; break;
+ }
+ for(var i=0; i<seg.length; i+=1) {
+ s = 1 - 1/(seg.length-1)*i;
+ c[1] = c[0] * (1 - s*f);
+ c[2] = c[0] * (1 - s);
+ seg[i].style.backgroundColor = 'rgb('+
+ (c[rgb[0]]*100)+'%,'+
+ (c[rgb[1]]*100)+'%,'+
+ (c[rgb[2]]*100)+'%)';
+ }
+ break;
+ }
+ }
+
+
+ function redrawSld() {
+ // redraw the slider pointer
+ switch(modeID) {
+ case 0: var yComponent = 2; break;
+ case 1: var yComponent = 1; break;
+ }
+ var y = Math.round((1-THIS.hsv[yComponent]) * (jscolor.images.sld[1]-1));
+ jscolor.picker.sldM.style.backgroundPosition =
+ '0 ' + (THIS.pickerFace+THIS.pickerInset+y - Math.floor(jscolor.images.arrow[1]/2)) + 'px';
+ }
+
+
+ function isPickerOwner() {
+ return jscolor.picker && jscolor.picker.owner === THIS;
+ }
+
+
+ function blurTarget() {
+ if(valueElement === target) {
+ THIS.importColor();
+ }
+ if(THIS.pickerOnfocus) {
+ THIS.hidePicker();
+ }
+ }
+
+
+ function blurValue() {
+ if(valueElement !== target) {
+ THIS.importColor();
+ }
+ }
+
+
+ function setPad(e) {
+ var posM = jscolor.getMousePos(e);
+ var x = posM[0]-posPad[0];
+ var y = posM[1]-posPad[1];
+ switch(modeID) {
+ case 0: THIS.fromHSV(x*(6/(jscolor.images.pad[0]-1)), 1 - y/(jscolor.images.pad[1]-1), null, leaveSld); break;
+ case 1: THIS.fromHSV(x*(6/(jscolor.images.pad[0]-1)), null, 1 - y/(jscolor.images.pad[1]-1), leaveSld); break;
+ }
+ }
+
+
+ function setSld(e) {
+ var posM = jscolor.getMousePos(e);
+ var y = posM[1]-posPad[1];
+ switch(modeID) {
+ case 0: THIS.fromHSV(null, null, 1 - y/(jscolor.images.sld[1]-1), leavePad); break;
+ case 1: THIS.fromHSV(null, 1 - y/(jscolor.images.sld[1]-1), null, leavePad); break;
+ }
+ }
+
+
+ var THIS = this;
+ var modeID = this.pickerMode.toLowerCase()==='hvs' ? 1 : 0;
+ var abortBlur = false;
+ var
+ valueElement = jscolor.fetchElement(this.valueElement),
+ styleElement = jscolor.fetchElement(this.styleElement);
+ var
+ holdPad = false,
+ holdSld = false;
+ var
+ posPad,
+ posSld;
+ var
+ leaveValue = 1<<0,
+ leaveStyle = 1<<1,
+ leavePad = 1<<2,
+ leaveSld = 1<<3;
+
+ // target
+ jscolor.addEvent(target, 'focus', function() {
+ if(THIS.pickerOnfocus) { THIS.showPicker(); }
+ });
+ jscolor.addEvent(target, 'blur', function() {
+ if(!abortBlur) {
+ window.setTimeout(function(){ abortBlur || blurTarget(); abortBlur=false; }, 0);
+ } else {
+ abortBlur = false;
+ }
+ });
+
+ // valueElement
+ if(valueElement) {
+ var updateField = function() {
+ THIS.fromString(valueElement.value, leaveValue);
+ };
+ jscolor.addEvent(valueElement, 'keyup', updateField);
+ jscolor.addEvent(valueElement, 'input', updateField);
+ jscolor.addEvent(valueElement, 'blur', blurValue);
+ valueElement.setAttribute('autocomplete', 'off');
+ }
+
+ // styleElement
+ if(styleElement) {
+ styleElement.jscStyle = {
+ backgroundColor : styleElement.style.backgroundColor,
+ color : styleElement.style.color
+ };
+ }
+
+ // require images
+ switch(modeID) {
+ case 0: jscolor.requireImage('hs.png'); break;
+ case 1: jscolor.requireImage('hv.png'); break;
+ }
+ jscolor.requireImage('cross.gif');
+ jscolor.requireImage('arrow.gif');
+
+ this.importColor();
+ }
+
+};
+
+
+jscolor.install();
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/includes/rounded_corners_lite.inc.js b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/rounded_corners_lite.inc.js
new file mode 100644
index 0000000..afc3ea3
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/includes/rounded_corners_lite.inc.js
@@ -0,0 +1,285 @@
+
+ /****************************************************************
+ * *
+ * curvyCorners *
+ * ------------ *
+ * *
+ * This script generates rounded corners for your divs. *
+ * *
+ * Version 1.2.9 *
+ * Copyright (c) 2006 Cameron Cooke *
+ * By: Cameron Cooke and Tim Hutchison. *
+ * *
+ * *
+ * Website: http://www.curvycorners.net *
+ * Email: info@totalinfinity.com *
+ * Forum: http://www.curvycorners.net/forum/ *
+ * *
+ * *
+ * This library is free software; you can redistribute *
+ * it and/or modify it under the terms of the GNU *
+ * Lesser General Public License as published by the *
+ * Free Software Foundation; either version 2.1 of the *
+ * License, or (at your option) any later version. *
+ * *
+ * This library is distributed in the hope that it will *
+ * be useful, but WITHOUT ANY WARRANTY; without even the *
+ * implied warranty of MERCHANTABILITY or FITNESS FOR A *
+ * PARTICULAR PURPOSE. See the GNU Lesser General Public *
+ * License for more details. *
+ * *
+ * You should have received a copy of the GNU Lesser *
+ * General Public License along with this library; *
+ * Inc., 59 Temple Place, Suite 330, Boston, *
+ * MA 02111-1307 USA *
+ * *
+ ****************************************************************/
+
+var isIE = navigator.userAgent.toLowerCase().indexOf("msie") > -1; var isMoz = document.implementation && document.implementation.createDocument; var isSafari = ((navigator.userAgent.toLowerCase().indexOf('safari')!=-1)&&(navigator.userAgent.toLowerCase().indexOf('mac')!=-1))?true:false; function curvyCorners()
+{ if(typeof(arguments[0]) != "object") throw newCurvyError("First parameter of curvyCorners() must be an object."); if(typeof(arguments[1]) != "object" && typeof(arguments[1]) != "string") throw newCurvyError("Second parameter of curvyCorners() must be an object or a class name."); if(typeof(arguments[1]) == "string")
+{ var startIndex = 0; var boxCol = getElementsByClass(arguments[1]);}
+else
+{ var startIndex = 1; var boxCol = arguments;}
+var curvyCornersCol = new Array(); if(arguments[0].validTags)
+var validElements = arguments[0].validTags; else
+var validElements = ["div"]; for(var i = startIndex, j = boxCol.length; i < j; i++)
+{ var currentTag = boxCol[i].tagName.toLowerCase(); if(inArray(validElements, currentTag) !== false)
+{ curvyCornersCol[curvyCornersCol.length] = new curvyObject(arguments[0], boxCol[i]);}
+}
+this.objects = curvyCornersCol; this.applyCornersToAll = function()
+{ for(var x = 0, k = this.objects.length; x < k; x++)
+{ this.objects[x].applyCorners();}
+}
+}
+function curvyObject()
+{ this.box = arguments[1]; this.settings = arguments[0]; this.topContainer = null; this.bottomContainer = null; this.masterCorners = new Array(); this.contentDIV = null; var boxHeight = get_style(this.box, "height", "height"); var boxWidth = get_style(this.box, "width", "width"); var borderWidth = get_style(this.box, "borderTopWidth", "border-top-width"); var borderColour = get_style(this.box, "borderTopColor", "border-top-color"); var boxColour = get_style(this.box, "backgroundColor", "background-color"); var backgroundImage = get_style(this.box, "backgroundImage", "background-image"); var boxPosition = get_style(this.box, "position", "position"); var boxPadding = get_style(this.box, "paddingTop", "padding-top"); this.boxHeight = parseInt(((boxHeight != "" && boxHeight != "auto" && boxHeight.indexOf("%") == -1)? boxHeight.substring(0, boxHeight.indexOf("px")) : this.box.scrollHeight)); this.boxWidth = parseInt(((boxWidth != "" && boxWidth != "auto" && boxWidth.indexOf("%") == -1)? boxWidth.substring(0, boxWidth.indexOf("px")) : this.box.scrollWidth)); this.borderWidth = parseInt(((borderWidth != "" && borderWidth.indexOf("px") !== -1)? borderWidth.slice(0, borderWidth.indexOf("px")) : 0)); this.boxColour = format_colour(boxColour); this.boxPadding = parseInt(((boxPadding != "" && boxPadding.indexOf("px") !== -1)? boxPadding.slice(0, boxPadding.indexOf("px")) : 0)); this.borderColour = format_colour(borderColour); this.borderString = this.borderWidth + "px" + " solid " + this.borderColour; this.backgroundImage = ((backgroundImage != "none")? backgroundImage : ""); this.boxContent = this.box.innerHTML; if(boxPosition != "absolute") this.box.style.position = "relative"; this.box.style.padding = "0px"; if(isIE && boxWidth == "auto" && boxHeight == "auto") this.box.style.width = "100%"; if(this.settings.autoPad == true && this.boxPadding > 0)
+this.box.innerHTML = ""; this.applyCorners = function()
+{ for(var t = 0; t < 2; t++)
+{ switch(t)
+{ case 0:
+if(this.settings.tl || this.settings.tr)
+{ var newMainContainer = document.createElement("DIV"); newMainContainer.style.width = "100%"; newMainContainer.style.fontSize = "1px"; newMainContainer.style.overflow = "hidden"; newMainContainer.style.position = "absolute"; newMainContainer.style.paddingLeft = this.borderWidth + "px"; newMainContainer.style.paddingRight = this.borderWidth + "px"; var topMaxRadius = Math.max(this.settings.tl ? this.settings.tl.radius : 0, this.settings.tr ? this.settings.tr.radius : 0); newMainContainer.style.height = topMaxRadius + "px"; newMainContainer.style.top = 0 - topMaxRadius + "px"; newMainContainer.style.left = 0 - this.borderWidth + "px"; this.topContainer = this.box.appendChild(newMainContainer);}
+break; case 1:
+if(this.settings.bl || this.settings.br)
+{ var newMainContainer = document.createElement("DIV"); newMainContainer.style.width = "100%"; newMainContainer.style.fontSize = "1px"; newMainContainer.style.overflow = "hidden"; newMainContainer.style.position = "absolute"; newMainContainer.style.paddingLeft = this.borderWidth + "px"; newMainContainer.style.paddingRight = this.borderWidth + "px"; var botMaxRadius = Math.max(this.settings.bl ? this.settings.bl.radius : 0, this.settings.br ? this.settings.br.radius : 0); newMainContainer.style.height = botMaxRadius + "px"; newMainContainer.style.bottom = 0 - botMaxRadius + "px"; newMainContainer.style.left = 0 - this.borderWidth + "px"; this.bottomContainer = this.box.appendChild(newMainContainer);}
+break;}
+}
+if(this.topContainer) this.box.style.borderTopWidth = "0px"; if(this.bottomContainer) this.box.style.borderBottomWidth = "0px"; var corners = ["tr", "tl", "br", "bl"]; for(var i in corners)
+{ if(i > -1 < 4)
+{ var cc = corners[i]; if(!this.settings[cc])
+{ if(((cc == "tr" || cc == "tl") && this.topContainer != null) || ((cc == "br" || cc == "bl") && this.bottomContainer != null))
+{ var newCorner = document.createElement("DIV"); newCorner.style.position = "relative"; newCorner.style.fontSize = "1px"; newCorner.style.overflow = "hidden"; if(this.backgroundImage == "")
+newCorner.style.backgroundColor = this.boxColour; else
+newCorner.style.backgroundImage = this.backgroundImage; switch(cc)
+{ case "tl":
+newCorner.style.height = topMaxRadius - this.borderWidth + "px"; newCorner.style.marginRight = this.settings.tr.radius - (this.borderWidth*2) + "px"; newCorner.style.borderLeft = this.borderString; newCorner.style.borderTop = this.borderString; newCorner.style.left = -this.borderWidth + "px"; break; case "tr":
+newCorner.style.height = topMaxRadius - this.borderWidth + "px"; newCorner.style.marginLeft = this.settings.tl.radius - (this.borderWidth*2) + "px"; newCorner.style.borderRight = this.borderString; newCorner.style.borderTop = this.borderString; newCorner.style.backgroundPosition = "-" + (topMaxRadius + this.borderWidth) + "px 0px"; newCorner.style.left = this.borderWidth + "px"; break; case "bl":
+newCorner.style.height = botMaxRadius - this.borderWidth + "px"; newCorner.style.marginRight = this.settings.br.radius - (this.borderWidth*2) + "px"; newCorner.style.borderLeft = this.borderString; newCorner.style.borderBottom = this.borderString; newCorner.style.left = -this.borderWidth + "px"; newCorner.style.backgroundPosition = "-" + (this.borderWidth) + "px -" + (this.boxHeight + (botMaxRadius + this.borderWidth)) + "px"; break; case "br":
+newCorner.style.height = botMaxRadius - this.borderWidth + "px"; newCorner.style.marginLeft = this.settings.bl.radius - (this.borderWidth*2) + "px"; newCorner.style.borderRight = this.borderString; newCorner.style.borderBottom = this.borderString; newCorner.style.left = this.borderWidth + "px"
+newCorner.style.backgroundPosition = "-" + (botMaxRadius + this.borderWidth) + "px -" + (this.boxHeight + (botMaxRadius + this.borderWidth)) + "px"; break;}
+}
+}
+else
+{ if(this.masterCorners[this.settings[cc].radius])
+{ var newCorner = this.masterCorners[this.settings[cc].radius].cloneNode(true);}
+else
+{ var newCorner = document.createElement("DIV"); newCorner.style.height = this.settings[cc].radius + "px"; newCorner.style.width = this.settings[cc].radius + "px"; newCorner.style.position = "absolute"; newCorner.style.fontSize = "1px"; newCorner.style.overflow = "hidden"; var borderRadius = parseInt(this.settings[cc].radius - this.borderWidth); for(var intx = 0, j = this.settings[cc].radius; intx < j; intx++)
+{ if((intx +1) >= borderRadius)
+var y1 = -1; else
+var y1 = (Math.floor(Math.sqrt(Math.pow(borderRadius, 2) - Math.pow((intx+1), 2))) - 1); if(borderRadius != j)
+{ if((intx) >= borderRadius)
+var y2 = -1; else
+var y2 = Math.ceil(Math.sqrt(Math.pow(borderRadius,2) - Math.pow(intx, 2))); if((intx+1) >= j)
+var y3 = -1; else
+var y3 = (Math.floor(Math.sqrt(Math.pow(j ,2) - Math.pow((intx+1), 2))) - 1);}
+if((intx) >= j)
+var y4 = -1; else
+var y4 = Math.ceil(Math.sqrt(Math.pow(j ,2) - Math.pow(intx, 2))); if(y1 > -1) this.drawPixel(intx, 0, this.boxColour, 100, (y1+1), newCorner, -1, this.settings[cc].radius); if(borderRadius != j)
+{ for(var inty = (y1 + 1); inty < y2; inty++)
+{ if(this.settings.antiAlias)
+{ if(this.backgroundImage != "")
+{ var borderFract = (pixelFraction(intx, inty, borderRadius) * 100); if(borderFract < 30)
+{ this.drawPixel(intx, inty, this.borderColour, 100, 1, newCorner, 0, this.settings[cc].radius);}
+else
+{ this.drawPixel(intx, inty, this.borderColour, 100, 1, newCorner, -1, this.settings[cc].radius);}
+}
+else
+{ var pixelcolour = BlendColour(this.boxColour, this.borderColour, pixelFraction(intx, inty, borderRadius)); this.drawPixel(intx, inty, pixelcolour, 100, 1, newCorner, 0, this.settings[cc].radius, cc);}
+}
+}
+if(this.settings.antiAlias)
+{ if(y3 >= y2)
+{ if (y2 == -1) y2 = 0; this.drawPixel(intx, y2, this.borderColour, 100, (y3 - y2 + 1), newCorner, 0, 0);}
+}
+else
+{ if(y3 >= y1)
+{ this.drawPixel(intx, (y1 + 1), this.borderColour, 100, (y3 - y1), newCorner, 0, 0);}
+}
+var outsideColour = this.borderColour;}
+else
+{ var outsideColour = this.boxColour; var y3 = y1;}
+if(this.settings.antiAlias)
+{ for(var inty = (y3 + 1); inty < y4; inty++)
+{ this.drawPixel(intx, inty, outsideColour, (pixelFraction(intx, inty , j) * 100), 1, newCorner, ((this.borderWidth > 0)? 0 : -1), this.settings[cc].radius);}
+}
+}
+this.masterCorners[this.settings[cc].radius] = newCorner.cloneNode(true);}
+if(cc != "br")
+{ for(var t = 0, k = newCorner.childNodes.length; t < k; t++)
+{ var pixelBar = newCorner.childNodes[t]; var pixelBarTop = parseInt(pixelBar.style.top.substring(0, pixelBar.style.top.indexOf("px"))); var pixelBarLeft = parseInt(pixelBar.style.left.substring(0, pixelBar.style.left.indexOf("px"))); var pixelBarHeight = parseInt(pixelBar.style.height.substring(0, pixelBar.style.height.indexOf("px"))); if(cc == "tl" || cc == "bl"){ pixelBar.style.left = this.settings[cc].radius -pixelBarLeft -1 + "px";}
+if(cc == "tr" || cc == "tl"){ pixelBar.style.top = this.settings[cc].radius -pixelBarHeight -pixelBarTop + "px";}
+switch(cc)
+{ case "tr":
+pixelBar.style.backgroundPosition = "-" + Math.abs((this.boxWidth - this.settings[cc].radius + this.borderWidth) + pixelBarLeft) + "px -" + Math.abs(this.settings[cc].radius -pixelBarHeight -pixelBarTop - this.borderWidth) + "px"; break; case "tl":
+pixelBar.style.backgroundPosition = "-" + Math.abs((this.settings[cc].radius -pixelBarLeft -1) - this.borderWidth) + "px -" + Math.abs(this.settings[cc].radius -pixelBarHeight -pixelBarTop - this.borderWidth) + "px"; break; case "bl":
+pixelBar.style.backgroundPosition = "-" + Math.abs((this.settings[cc].radius -pixelBarLeft -1) - this.borderWidth) + "px -" + Math.abs((this.boxHeight + this.settings[cc].radius + pixelBarTop) -this.borderWidth) + "px"; break;}
+}
+}
+}
+if(newCorner)
+{ switch(cc)
+{ case "tl":
+if(newCorner.style.position == "absolute") newCorner.style.top = "0px"; if(newCorner.style.position == "absolute") newCorner.style.left = "0px"; if(this.topContainer) this.topContainer.appendChild(newCorner); break; case "tr":
+if(newCorner.style.position == "absolute") newCorner.style.top = "0px"; if(newCorner.style.position == "absolute") newCorner.style.right = "0px"; if(this.topContainer) this.topContainer.appendChild(newCorner); break; case "bl":
+if(newCorner.style.position == "absolute") newCorner.style.bottom = "0px"; if(newCorner.style.position == "absolute") newCorner.style.left = "0px"; if(this.bottomContainer) this.bottomContainer.appendChild(newCorner); break; case "br":
+if(newCorner.style.position == "absolute") newCorner.style.bottom = "0px"; if(newCorner.style.position == "absolute") newCorner.style.right = "0px"; if(this.bottomContainer) this.bottomContainer.appendChild(newCorner); break;}
+}
+}
+}
+var radiusDiff = new Array(); radiusDiff["t"] = Math.abs(this.settings.tl.radius - this.settings.tr.radius)
+radiusDiff["b"] = Math.abs(this.settings.bl.radius - this.settings.br.radius); for(z in radiusDiff)
+{ if(z == "t" || z == "b")
+{ if(radiusDiff[z])
+{ var smallerCornerType = ((this.settings[z + "l"].radius < this.settings[z + "r"].radius)? z +"l" : z +"r"); var newFiller = document.createElement("DIV"); newFiller.style.height = radiusDiff[z] + "px"; newFiller.style.width = this.settings[smallerCornerType].radius+ "px"
+newFiller.style.position = "absolute"; newFiller.style.fontSize = "1px"; newFiller.style.overflow = "hidden"; newFiller.style.backgroundColor = this.boxColour; switch(smallerCornerType)
+{ case "tl":
+newFiller.style.bottom = "0px"; newFiller.style.left = "0px"; newFiller.style.borderLeft = this.borderString; this.topContainer.appendChild(newFiller); break; case "tr":
+newFiller.style.bottom = "0px"; newFiller.style.right = "0px"; newFiller.style.borderRight = this.borderString; this.topContainer.appendChild(newFiller); break; case "bl":
+newFiller.style.top = "0px"; newFiller.style.left = "0px"; newFiller.style.borderLeft = this.borderString; this.bottomContainer.appendChild(newFiller); break; case "br":
+newFiller.style.top = "0px"; newFiller.style.right = "0px"; newFiller.style.borderRight = this.borderString; this.bottomContainer.appendChild(newFiller); break;}
+}
+var newFillerBar = document.createElement("DIV"); newFillerBar.style.position = "relative"; newFillerBar.style.fontSize = "1px"; newFillerBar.style.overflow = "hidden"; newFillerBar.style.backgroundColor = this.boxColour; newFillerBar.style.backgroundImage = this.backgroundImage; switch(z)
+{ case "t":
+if(this.topContainer)
+{ if(this.settings.tl.radius && this.settings.tr.radius)
+{ newFillerBar.style.height = topMaxRadius - this.borderWidth + "px"; newFillerBar.style.marginLeft = this.settings.tl.radius - this.borderWidth + "px"; newFillerBar.style.marginRight = this.settings.tr.radius - this.borderWidth + "px"; newFillerBar.style.borderTop = this.borderString; if(this.backgroundImage != "")
+newFillerBar.style.backgroundPosition = "-" + (topMaxRadius + this.borderWidth) + "px 0px"; this.topContainer.appendChild(newFillerBar);}
+this.box.style.backgroundPosition = "0px -" + (topMaxRadius - this.borderWidth) + "px";}
+break; case "b":
+if(this.bottomContainer)
+{ if(this.settings.bl.radius && this.settings.br.radius)
+{ newFillerBar.style.height = botMaxRadius - this.borderWidth + "px"; newFillerBar.style.marginLeft = this.settings.bl.radius - this.borderWidth + "px"; newFillerBar.style.marginRight = this.settings.br.radius - this.borderWidth + "px"; newFillerBar.style.borderBottom = this.borderString; if(this.backgroundImage != "")
+newFillerBar.style.backgroundPosition = "-" + (botMaxRadius + this.borderWidth) + "px -" + (this.boxHeight + (topMaxRadius + this.borderWidth)) + "px"; this.bottomContainer.appendChild(newFillerBar);}
+}
+break;}
+}
+}
+if(this.settings.autoPad == true && this.boxPadding > 0)
+{ var contentContainer = document.createElement("DIV"); contentContainer.style.position = "relative"; contentContainer.innerHTML = this.boxContent; contentContainer.className = "autoPadDiv"; var topPadding = Math.abs(topMaxRadius - this.boxPadding); var botPadding = Math.abs(botMaxRadius - this.boxPadding); if(topMaxRadius < this.boxPadding)
+contentContainer.style.paddingTop = topPadding + "px"; if(botMaxRadius < this.boxPadding)
+contentContainer.style.paddingBottom = botMaxRadius + "px"; contentContainer.style.paddingLeft = this.boxPadding + "px"; contentContainer.style.paddingRight = this.boxPadding + "px"; this.contentDIV = this.box.appendChild(contentContainer);}
+}
+this.drawPixel = function(intx, inty, colour, transAmount, height, newCorner, image, cornerRadius)
+{ var pixel = document.createElement("DIV"); pixel.style.height = height + "px"; pixel.style.width = "1px"; pixel.style.position = "absolute"; pixel.style.fontSize = "1px"; pixel.style.overflow = "hidden"; var topMaxRadius = Math.max(this.settings["tr"].radius, this.settings["tl"].radius); if(image == -1 && this.backgroundImage != "")
+{ pixel.style.backgroundImage = this.backgroundImage; pixel.style.backgroundPosition = "-" + (this.boxWidth - (cornerRadius - intx) + this.borderWidth) + "px -" + ((this.boxHeight + topMaxRadius + inty) -this.borderWidth) + "px";}
+else
+{ pixel.style.backgroundColor = colour;}
+if (transAmount != 100)
+setOpacity(pixel, transAmount); pixel.style.top = inty + "px"; pixel.style.left = intx + "px"; newCorner.appendChild(pixel);}
+}
+function insertAfter(parent, node, referenceNode)
+{ parent.insertBefore(node, referenceNode.nextSibling);}
+function BlendColour(Col1, Col2, Col1Fraction)
+{ var red1 = parseInt(Col1.substr(1,2),16); var green1 = parseInt(Col1.substr(3,2),16); var blue1 = parseInt(Col1.substr(5,2),16); var red2 = parseInt(Col2.substr(1,2),16); var green2 = parseInt(Col2.substr(3,2),16); var blue2 = parseInt(Col2.substr(5,2),16); if(Col1Fraction > 1 || Col1Fraction < 0) Col1Fraction = 1; var endRed = Math.round((red1 * Col1Fraction) + (red2 * (1 - Col1Fraction))); if(endRed > 255) endRed = 255; if(endRed < 0) endRed = 0; var endGreen = Math.round((green1 * Col1Fraction) + (green2 * (1 - Col1Fraction))); if(endGreen > 255) endGreen = 255; if(endGreen < 0) endGreen = 0; var endBlue = Math.round((blue1 * Col1Fraction) + (blue2 * (1 - Col1Fraction))); if(endBlue > 255) endBlue = 255; if(endBlue < 0) endBlue = 0; return "#" + IntToHex(endRed)+ IntToHex(endGreen)+ IntToHex(endBlue);}
+function IntToHex(strNum)
+{ base = strNum / 16; rem = strNum % 16; base = base - (rem / 16); baseS = MakeHex(base); remS = MakeHex(rem); return baseS + '' + remS;}
+function MakeHex(x)
+{ if((x >= 0) && (x <= 9))
+{ return x;}
+else
+{ switch(x)
+{ case 10: return "A"; case 11: return "B"; case 12: return "C"; case 13: return "D"; case 14: return "E"; case 15: return "F";}
+}
+}
+function pixelFraction(x, y, r)
+{ var pixelfraction = 0; var xvalues = new Array(1); var yvalues = new Array(1); var point = 0; var whatsides = ""; var intersect = Math.sqrt((Math.pow(r,2) - Math.pow(x,2))); if ((intersect >= y) && (intersect < (y+1)))
+{ whatsides = "Left"; xvalues[point] = 0; yvalues[point] = intersect - y; point = point + 1;}
+var intersect = Math.sqrt((Math.pow(r,2) - Math.pow(y+1,2))); if ((intersect >= x) && (intersect < (x+1)))
+{ whatsides = whatsides + "Top"; xvalues[point] = intersect - x; yvalues[point] = 1; point = point + 1;}
+var intersect = Math.sqrt((Math.pow(r,2) - Math.pow(x+1,2))); if ((intersect >= y) && (intersect < (y+1)))
+{ whatsides = whatsides + "Right"; xvalues[point] = 1; yvalues[point] = intersect - y; point = point + 1;}
+var intersect = Math.sqrt((Math.pow(r,2) - Math.pow(y,2))); if ((intersect >= x) && (intersect < (x+1)))
+{ whatsides = whatsides + "Bottom"; xvalues[point] = intersect - x; yvalues[point] = 0;}
+switch (whatsides)
+{ case "LeftRight":
+pixelfraction = Math.min(yvalues[0],yvalues[1]) + ((Math.max(yvalues[0],yvalues[1]) - Math.min(yvalues[0],yvalues[1]))/2); break; case "TopRight":
+pixelfraction = 1-(((1-xvalues[0])*(1-yvalues[1]))/2); break; case "TopBottom":
+pixelfraction = Math.min(xvalues[0],xvalues[1]) + ((Math.max(xvalues[0],xvalues[1]) - Math.min(xvalues[0],xvalues[1]))/2); break; case "LeftBottom":
+pixelfraction = (yvalues[0]*xvalues[1])/2; break; default:
+pixelfraction = 1;}
+return pixelfraction;}
+function rgb2Hex(rgbColour)
+{ try{ var rgbArray = rgb2Array(rgbColour); var red = parseInt(rgbArray[0]); var green = parseInt(rgbArray[1]); var blue = parseInt(rgbArray[2]); var hexColour = "#" + IntToHex(red) + IntToHex(green) + IntToHex(blue);}
+catch(e){ alert("There was an error converting the RGB value to Hexadecimal in function rgb2Hex");}
+return hexColour;}
+function rgb2Array(rgbColour)
+{ var rgbValues = rgbColour.substring(4, rgbColour.indexOf(")")); var rgbArray = rgbValues.split(", "); return rgbArray;}
+function setOpacity(obj, opacity)
+{ opacity = (opacity == 100)?99.999:opacity; if(isSafari && obj.tagName != "IFRAME")
+{ var rgbArray = rgb2Array(obj.style.backgroundColor); var red = parseInt(rgbArray[0]); var green = parseInt(rgbArray[1]); var blue = parseInt(rgbArray[2]); obj.style.backgroundColor = "rgba(" + red + ", " + green + ", " + blue + ", " + opacity/100 + ")";}
+else if(typeof(obj.style.opacity) != "undefined")
+{ obj.style.opacity = opacity/100;}
+else if(typeof(obj.style.MozOpacity) != "undefined")
+{ obj.style.MozOpacity = opacity/100;}
+else if(typeof(obj.style.filter) != "undefined")
+{ obj.style.filter = "alpha(opacity:" + opacity + ")";}
+else if(typeof(obj.style.KHTMLOpacity) != "undefined")
+{ obj.style.KHTMLOpacity = opacity/100;}
+}
+function inArray(array, value)
+{ for(var i = 0; i < array.length; i++){ if (array[i] === value) return i;}
+return false;}
+function inArrayKey(array, value)
+{ for(key in array){ if(key === value) return true;}
+return false;}
+function addEvent(elm, evType, fn, useCapture) { if (elm.addEventListener) { elm.addEventListener(evType, fn, useCapture); return true;}
+else if (elm.attachEvent) { var r = elm.attachEvent('on' + evType, fn); return r;}
+else { elm['on' + evType] = fn;}
+}
+function removeEvent(obj, evType, fn, useCapture){ if (obj.removeEventListener){ obj.removeEventListener(evType, fn, useCapture); return true;} else if (obj.detachEvent){ var r = obj.detachEvent("on"+evType, fn); return r;} else { alert("Handler could not be removed");}
+}
+function format_colour(colour)
+{ var returnColour = "#ffffff"; if(colour != "" && colour != "transparent")
+{ if(colour.substr(0, 3) == "rgb")
+{ returnColour = rgb2Hex(colour);}
+else if(colour.length == 4)
+{ returnColour = "#" + colour.substring(1, 2) + colour.substring(1, 2) + colour.substring(2, 3) + colour.substring(2, 3) + colour.substring(3, 4) + colour.substring(3, 4);}
+else
+{ returnColour = colour;}
+}
+return returnColour;}
+function get_style(obj, property, propertyNS)
+{ try
+{ if(obj.currentStyle)
+{ var returnVal = eval("obj.currentStyle." + property);}
+else
+{ if(isSafari && obj.style.display == "none")
+{ obj.style.display = ""; var wasHidden = true;}
+var returnVal = document.defaultView.getComputedStyle(obj, '').getPropertyValue(propertyNS); if(isSafari && wasHidden)
+{ obj.style.display = "none";}
+}
+}
+catch(e)
+{ }
+return returnVal;}
+function getElementsByClass(searchClass, node, tag)
+{ var classElements = new Array(); if(node == null)
+node = document; if(tag == null)
+tag = '*'; var els = node.getElementsByTagName(tag); var elsLen = els.length; var pattern = new RegExp("(^|\s)"+searchClass+"(\s|$)"); for (i = 0, j = 0; i < elsLen; i++)
+{ if(pattern.test(els[i].className))
+{ classElements[j] = els[i]; j++;}
+}
+return classElements;}
+function newCurvyError(errorMessage)
+{ return new Error("curvyCorners Error:\n" + errorMessage)
+}
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/index.php b/notFinishedCode/pChart2.1.2/examples/sandbox/index.php
new file mode 100644
index 0000000..52afeb0
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/index.php
@@ -0,0 +1,707 @@
+<?php
+ /*
+ index.php - Sandbox web frontend
+
+ Version : 1.1.0
+ Made by : Jean-Damien POGOLOTTI
+ Last Update : 18/01/11
+
+ This file can be distributed under the license you can find at :
+
+ http://www.pchart.net/license
+
+ You can find the whole class documentation on the pChart web site.
+ */
+?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
+<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
+<head>
+ <title>Sandbox system</title>
+ <meta http-equiv='Content-Type' content='text/html; charset=utf-8'/>
+ <meta name='description' content='pChart is an object oriented php charting library'/>
+ <meta name='keywords' content='pchart, php chart, charting library, php charting'/>
+ <link rel='stylesheet' type='text/css' href='style.css'/>
+ <link rel='shortcut icon' href='images/favicon.ico'/>
+ <script type='text/javascript' src='includes/rounded_corners_lite.inc.js'></script>
+ <script type='text/javascript' src='includes/jscolor.js'></script>
+ <script type='text/javascript' src='includes/functions.js'></script>
+</head>
+<body>
+ <table style=''><tr><td>
+ <table style='padding: 2px; background-color: #E0E0E0; border: 1px solid #D0D0D0;'><tr>
+ <td class='topMenu'>
+ <div class='topMenu' id='menu1' onmouseover='highlightDIV(1);' onmouseout='clearDIV(1);' onclick='toggleDIV(1);'>
+ <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
+ <td class='topMenu'><img src='graphix/tab.png' width='16' height='16' alt=''/></td>
+ <td class='topMenu'>&nbsp;General settings&nbsp;</td>
+ </tr></table>
+ </div>
+ </td>
+ <td class='topMenu' width='5'></td>
+ <td class='topMenu'>
+ <div class='topMenu' id='menu2' onmouseover='highlightDIV(2);' onmouseout='clearDIV(2);' onclick='toggleDIV(2);'>
+ <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
+ <td class='topMenu'><img src='graphix/tab.png' width='16' height='16' alt=''/></td>
+ <td class='topMenu'>&nbsp;Data&nbsp;</td>
+ </tr></table>
+ </div>
+ </td>
+ <td class='topMenu' width='5'></td>
+ <td class='topMenu'>
+ <div class='topMenu' id='menu3' onmouseover='highlightDIV(3);' onmouseout='clearDIV(3);' onclick='toggleDIV(3);'>
+ <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
+ <td class='topMenu'><img src='graphix/tab.png' width='16' height='16' alt=''/></td>
+ <td class='topMenu'>&nbsp;Scale&nbsp;</td>
+ </tr></table>
+ </div>
+ </td>
+ <td class='topMenu' width='5'></td>
+ <td class='topMenu'>
+ <div class='topMenu' id='menu4' onmouseover='highlightDIV(4);' onmouseout='clearDIV(4);' onclick='toggleDIV(4);'>
+ <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
+ <td class='topMenu'><img src='graphix/tab.png' width='16' height='16' alt=''/></td>
+ <td class='topMenu'>&nbsp;Chart&nbsp;</td>
+ </tr></table>
+ </div>
+ </td>
+ <td class='topMenu' width='5'></td>
+ <td class='topMenu'>
+ <div class='topMenu' id='menu5' onmouseover='highlightDIV(5);' onmouseout='clearDIV(5);' onclick='toggleDIV(5);'>
+ <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
+ <td class='topMenu'><img src='graphix/tab.png' width='16' height='16' alt=''/></td>
+ <td class='topMenu'>&nbsp;Legend, thresholds &amp; Misc&nbsp;</td>
+ </tr></table>
+ </div>
+ </td>
+ </tr></table>
+ </td>
+ <td width='5'></td>
+ <td>
+ <table style='padding: 2px; background-color: #D0D0D0; border: 1px solid #D0D0D0;'><tr>
+ <td class='topMenu'>
+ <div class='topMenu' id='menu6' onmouseover='highlightDIV(6);' onmouseout='clearDIV(6);' onclick='code();'>
+ <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
+ <td class='topMenu'><img src='graphix/cog.png' width='16' height='16' alt=''/></td>
+ <td class='topMenu'>&nbsp;Show code&nbsp;</td>
+ </tr></table>
+ </div>
+ </td>
+ <td class='topMenu' width='5'></td>
+ <td class='topMenu'>
+ <div class='topMenu' id='menu7' onmouseover='highlightDIV(7);' onmouseout='clearDIV(7);' onclick='render();'>
+ <table style='padding: 2px; border: 1px solid #D0D0D0;'><tr>
+ <td class='topMenu'><img src='graphix/accept.png' width='16' height='16' alt=''/></td>
+ <td class='topMenu'>&nbsp;Render picture&nbsp;</td>
+ </tr></table>
+ </div>
+ </td>
+ </tr></table>
+ </td></tr></table>
+
+ <table><tr><td valign='top'>
+
+ <div class="roundedCorner" id='tab1' style='margin-top: 30px; margin-left: 20px; width: 350px; height: 420px; background: #F0F0F0; padding: 10px; color: #667309; border: 1px solid #E0E0E0'>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/wrench.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>General settings</b></td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td>Width &nbsp;</td>
+ <td><input type='text' id='g_width' value='700' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' onkeyup='doLayout();' /></td>
+ <td>&nbsp;&nbsp; Height &nbsp;</td>
+ <td><input type='text' id='g_height' value='230' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' onkeyup='doLayout();' /></td>
+ <td>&nbsp;&nbsp;<input type='checkbox' id='g_transparent' /></td>
+ <td>Transparent background</td>
+ </tr></table>
+ <table><tr>
+ <td><input type='checkbox' id='g_aa' checked='checked' /></td>
+ <td>Turn on antialiasing</td>
+ <td>&nbsp;&nbsp;<input type='checkbox' id='g_shadow' checked='checked' /></td>
+ <td>Enable shadow</td>
+ <td>&nbsp;&nbsp; <input type='checkbox' id='g_border' checked='checked' /></td>
+ <td>with a border</td>
+ </tr></table>
+ <table><tr>
+ <td><input type='checkbox' id='g_autopos' checked='checked' onclick='toggleAuto();' /></td>
+ <td>Automatic positioning of the elements</td>
+ </tr></table>
+
+ <br/>
+
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/comment.png' width='16' height='16' alt=''/></td>
+ <td width='240'><b>Chart title</b></td>
+ <td width='20'><input type='checkbox' id='g_title_enabled' checked='checked' /></td>
+ <td width='38'>Enabled</td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='55'>Chart Title</td>
+ <td><input type='text' id='g_title' value='My first pChart project' style='width: 260px;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ </tr></table>
+ <table><tr>
+ <td width='147'>Alignement method (<a class='smallLinkBlack' target='_new' href='http://wiki.pchart.net/doc.draw.text.html'>help</a>)</td>
+ <td><select id='g_title_align'><?php listalign(); ?></select></td>
+ </tr></table>
+ <table><tr>
+ <td width='55'>X position &nbsp;</td>
+ <td><input type='text' id='g_title_x' value='350' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;&nbsp; Y position &nbsp;</td>
+ <td><input type='text' id='g_title_y' value='25' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;&nbsp; Color &nbsp;</td>
+ <td><input type='text' class='color' id='g_title_color' value='#FFFFFF' style='text-align: center; width: 60px;' onchange='applyColor("g_title_color","g_title_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td><div id='g_title_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ </tr></table>
+ <table><tr>
+ <td width='55'>Font name &nbsp;</td>
+ <td><select id='g_title_font'><?php listfonts(); ?></select></td>
+ <td>&nbsp;&nbsp; Size &nbsp;</td>
+ <td><input type='text' id='g_title_font_size' value='14' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;&nbsp; <input type='checkbox' id='g_title_box' /></td>
+ <td>in a box</td>
+ </tr></table>
+
+ <br/>
+
+ <table style='background-color: #E8E8E8; padding:1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/paintcan.png' width='16' height='16' alt=''/></td>
+ <td width='240'><b>Solid background</b></td>
+ <td width='20'><input type='checkbox' id='g_solid_enabled' checked='checked' /></td>
+ <td width='38'>Enabled</td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='55'>Color</td>
+ <td><input type='text' class='color' id='g_solid_color' value='#AAB757' style='text-align: center; width: 60px;' onchange='applyColor("g_solid_color","g_solid_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td width='40'><div id='g_solid_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ <td width='20'><input type='checkbox' id='g_solid_dashed' checked='checked' /></td>
+ <td width='38'>Dashed</td>
+ </tr></table>
+
+ <br/>
+
+ <table style='background-color: #E8E8E8; padding:1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/paintcan.png' width='16' height='16' alt=''/></td>
+ <td width='240'><b>Gradient background</b></td>
+ <td width='20'><input type='checkbox' id='g_gradient_enabled' checked='checked' /></td>
+ <td width='38'>Enabled</td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='55'>Start color</td>
+ <td><input type='text' class='color' id='g_gradient_start' value='#DBE78B' style='text-align: center; width: 60px;' onchange='applyColor("g_gradient_start","g_gradient_start_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td width='55'><div id='g_gradient_start_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ <td width='54'>End color &nbsp;</td>
+ <td><input type='text' class='color' id='g_gradient_end' value='#018A44' style='text-align: center; width: 60px;' onchange='applyColor("g_gradient_end","g_gradient_end_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td><div id='g_gradient_end_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ </tr></table>
+ <table><tr>
+ <td width='55'>Direction</td>
+ <td width='75'><select id='g_gradient_direction'><option value='vertical'>Vertical</option><option value='horizontal'>Horizontal</option></select></td>
+ <td width='100'>&nbsp; Alpha transparency</td>
+ <td><input type='text' id='g_gradient_alpha' value='50' style='width: 20px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>%</td>
+ </tr></table>
+ </div>
+
+ <div class="roundedCorner" id='tab2' style='display: none; margin-top: 30px; margin-left: 20px; width: 350px; height: 455px; background: #F0F0F0; padding: 10px; color: #667309; border: 1px solid #E0E0E0'>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/database_table.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>Dataset definition</b></td>
+ </tr></table>
+ <br/>
+ <table>
+ <tr>
+ <td width='46'></td>
+ <td width='65'><center>Serie 1</center></td>
+ <td width='65'><center>Serie 2</center></td>
+ <td width='65'><center>Serie 3</center></td>
+ <td width='65'><center>Absissa</center></td>
+ </tr>
+ <tr>
+ <td>Enabled</td>
+ <td><center><input type='checkbox' id='d_serie1_enabled' checked='checked' onclick='checkEnabledAxis();' /></center></td>
+ <td><center><input type='checkbox' id='d_serie2_enabled' checked='checked' onclick='checkEnabledAxis();' /></center></td>
+ <td><center><input type='checkbox' id='d_serie3_enabled' checked='checked' onclick='checkEnabledAxis();' /></center></td>
+ <td><center><input type='checkbox' id='d_absissa_enabled' checked='checked' /></center></td>
+ </tr>
+ </table>
+ <table>
+ <tr>
+ <td width='46'>Name</td>
+ <td width='65'><center><input type='text' id='d_serie1_name' value='Serie 1' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ <td width='65'><center><input type='text' id='d_serie2_name' value='Serie 2' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ <td width='65'><center><input type='text' id='d_serie3_name' value='Serie 3' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ <td width='65'><center>-</center></td>
+ </tr>
+ <tr>
+ <td width='46'>Binding</td>
+ <td width='65'><center><select id='d_serie1_axis' style='width: 54px;' onchange='checkEnabledAxis();'><?php listaxis(); ?></select></center></td>
+ <td width='65'><center><select id='d_serie2_axis' style='width: 54px;' onchange='checkEnabledAxis();'><?php listaxis(); ?></select></center></td>
+ <td width='65'><center><select id='d_serie3_axis' style='width: 54px;' onchange='checkEnabledAxis();'><?php listaxis(); ?></select></center></td>
+ <td width='65'><center>-</center></td>
+ </tr>
+<?php
+ for($i=0; $i<8;$i++)
+ {
+?>
+ <tr>
+<?php if ( $i == 0 ) { ?>
+ <td>Data</td>
+<?php } else { ?>
+ <td></td>
+<?php } ?>
+ <td><center><input type='text' id='d_serie1_data<?php echo $i; ?>' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ <td><center><input type='text' id='d_serie2_data<?php echo $i; ?>' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ <td><center><input type='text' id='d_serie3_data<?php echo $i; ?>' style='width: 50px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ <td><center><input type='text' id='d_absissa_data<?php echo $i; ?>' style='width: 60px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ </tr>
+<?php
+ }
+?>
+ </table>
+ <table>
+ <tr>
+ <td width='50'></td>
+ <td><input type='checkbox' id='d_normalize_enabled' /></td>
+ <td>normalize the datasets.</td>
+ <td width='10'></td>
+ <td>[ <a class='smallLinkBlack' href='javascript:randomize();'>randomize</a> ]</td>
+ </tr>
+ </table>
+ <br/>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/chart_bar_edit.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>Axis position and units</b></td>
+ </tr></table>
+ <br/>
+ <table>
+ <tr>
+ <td width='40'></td>
+ <td width='90'><center><b>Axis 0</b></center></td>
+ <td width='90'><center><b>Axis 1</b></center></td>
+ <td width='90'><center><b>Axis 2</b></center></td>
+ </tr>
+ <tr>
+ <td>Name</td>
+ <td><center><input type='text' id='d_axis0_name' value='1st axis' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ <td><center><input type='text' id='d_axis1_name' value='2nd axis' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ <td><center><input type='text' id='d_axis2_name' value='3rd axis' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ </tr>
+ <tr>
+ <td>Unit</td>
+ <td><center><input type='text' id='d_axis0_unit' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ <td><center><input type='text' id='d_axis1_unit' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ <td><center><input type='text' id='d_axis2_unit' style='width: 76px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></center></td>
+ </tr>
+ <tr>
+ <td>Position</td>
+ <td><center><select id='d_axis0_position' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxispos(); ?></select></center></td>
+ <td><center><select id='d_axis1_position' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxispos(); ?></select></center></td>
+ <td><center><select id='d_axis2_position' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxispos(); ?></select></center></td>
+ </tr>
+ <tr>
+ <td>Format</td>
+ <td><center><select id='d_axis0_format' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxisformat(); ?></select></center></td>
+ <td><center><select id='d_axis1_format' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxisformat(); ?></select></center></td>
+ <td><center><select id='d_axis2_format' style='width: 80px;' onchange='checkEnabledAxis();'><?php listaxisformat(); ?></select></center></td>
+ </tr>
+ </table>
+ </div>
+
+ <div class="roundedCorner" id='tab3' style='display: none; margin-top: 30px; margin-left: 20px; width: 350px; height: 435px; background: #F0F0F0; padding: 10px; color: #667309; border: 1px solid #E0E0E0'>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/layout_edit.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>Charting area definition</b></td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='50'>X &nbsp;</td>
+ <td><input type='text' id='s_x' value='70' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;&nbsp; Y &nbsp;</td>
+ <td><input type='text' id='s_y' value='50' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;&nbsp; Width &nbsp;</td>
+ <td><input type='text' id='s_width' value='590' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;&nbsp; Height &nbsp;</td>
+ <td><input type='text' id='s_height' value='140' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>Direction</td>
+ <td width='160'><select id='s_direction' onchange='checkEnabledAxis();'><option value='SCALE_POS_LEFTRIGHT'>SCALE_POS_LEFTRIGHT</option><option value='SCALE_POS_TOPBOTTOM'>SCALE_POS_TOPBOTTOM</option></select></td>
+ <td>&nbsp;<input type='checkbox' id='s_arrows_enabled' /></td>
+ <td>&nbsp;with arrows</td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>Mode</td>
+ <td width='160'><select id='s_mode'><option value='SCALE_MODE_FLOATING'>SCALE_MODE_FLOATING</option><option value='SCALE_MODE_START0'>SCALE_MODE_START0</option><option value='SCALE_MODE_ADDALL'>SCALE_MODE_ADDALL</option><option value='SCALE_MODE_ADDALL_START0'>SCALE_MODE_ADDALL_START0</option></select></td>
+ <td>&nbsp;<input type='checkbox' id='s_cycle_enabled' checked='checked' /></td>
+ <td>&nbsp;Background</td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>X Margin</td>
+ <td width='35'><input type='text' id='s_x_margin' value='0' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td width='50'>&nbsp; Y Margin</td>
+ <td width='68'><input type='text' id='s_y_margin' value='0' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;&nbsp;<input type='checkbox' id='s_automargin_enabled' checked='checked' onclick='toggleAutoMargins();' /></td>
+ <td>&nbsp;automatic</td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>Font</td>
+ <td><select id='s_font'><?php listfonts("pf_arma_five"); ?></select></td>
+ <td>&nbsp; Size &nbsp;</td>
+ <td><input type='text' id='s_font_size' value='6' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp; Color &nbsp;</td>
+ <td><input type='text' id='s_font_color' class='color' value='#000000' style='text-align: center; width: 50px;' onchange='applyColor("s_font_color","s_font_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td><div id='s_font_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ </tr></table>
+ <br/>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/page_edit.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>X Axis configuration</b></td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='50'>Mode</td>
+ <td><select id='s_x_labeling'><option value='LABELING_ALL'>LABELING_ALL</option><option value='LABELING_DIFFERENT'>LABELING_DIFFERENT</option></select></td>
+ <td>&nbsp;&nbsp; Skip each</td>
+ <td>&nbsp;<input type='text' id='s_x_skip' value='0' style='width: 20px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;labels</td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>Rotation</td>
+ <td><input type='text' id='s_x_label_rotation' value='0' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ </tr></table>
+ <br/>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/page_edit.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>Grid</b></td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='70'>Grid color</td>
+ <td><input type='text' id='s_grid_color' class='color' value='#FFFFFF' style='text-align: center; width: 60px; text-align: center' onchange='applyColor("s_grid_color","s_grid_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td><div id='s_grid_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ <td>&nbsp; Alpha</td>
+ <td>&nbsp; <input type='text' id='s_grid_alpha' value='50' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ </tr></table>
+ <table><tr>
+ <td width='70'>Display</td>
+ <td>&nbsp;<input type='checkbox' id='s_grid_x_enabled' checked='checked' /></td>
+ <td>&nbsp;X Lines</td>
+ <td>&nbsp;&nbsp;&nbsp;<input type='checkbox' id='s_grid_y_enabled' checked='checked' /></td>
+ <td>&nbsp;Y Lines</td>
+ </tr></table>
+
+ <br/>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/page_edit.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>Ticks</b></td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='70'>Ticks color</td>
+ <td><input type='text' id='s_ticks_color' class='color' value='#000000' style='text-align: center; width: 60px; text-align: center' onchange='applyColor("s_ticks_color","s_ticks_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td><div id='s_ticks_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ <td>&nbsp; Alpha</td>
+ <td>&nbsp; <input type='text' id='s_ticks_alpha' value='50' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ </tr></table>
+ <table><tr>
+ <td width='70'>Sub ticks color</td>
+ <td><input type='text' id='s_subticks_color' class='color' value='#FF0000' style='text-align: center; width: 60px; text-align: center' onchange='applyColor("s_subticks_color","s_subticks_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td><div id='s_subticks_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ <td>&nbsp; Alpha</td>
+ <td>&nbsp; <input type='text' id='s_subticks_alpha' value='50' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;<input type='checkbox' id='s_subticks_enabled' checked='checked' onclick='toggleSubTicks();' /></td>
+ <td>&nbsp;enabled</td>
+ </tr></table>
+ </div>
+
+ <div class="roundedCorner" id='tab4' style='display: none; margin-top: 30px; margin-left: 20px; width: 350px; height: 420px; background: #F0F0F0; padding: 10px; color: #667309; border: 1px solid #E0E0E0'>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/wrench.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>Chart</b></td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='60'>Chart family</td>
+ <td><select id='c_family' onchange='checkChartSettings();'><?php echo listCharts(); ?></select></td>
+ <td>&nbsp;Break color</td>
+ <td>&nbsp;<input type='text' id='c_break_color' class='color' value='#EA371A' style='text-align: center; width: 60px; text-align: center' onchange='applyColor("c_break_color","c_break_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td><div id='c_break_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ </tr></table>
+ <table><tr>
+ <td width='60'>Settings : </td>
+ <td><input type='checkbox' id='c_display_values' /></td>
+ <td>&nbsp;Display values</td>
+ <td>&nbsp;<input type='checkbox' id='c_break' /></td>
+ <td>&nbsp;Don't break on VOID</td>
+ </tr></table>
+ <div style='background: #D2F5C1; padding: 4px; color: #667309; margin-top: 10px;'>
+ <table><tr>
+ <td width='20'><img src='graphix/comment.png' width='16' height='16' alt=''/></td>
+ <td>Selecting a chart layout will enable/disable chart specifics options.</td>
+ </tr></table>
+ </div>
+ <br/>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/chart_line.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>Plot specifics</b></td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='60'>Plot size</td>
+ <td><input type='text' id='c_plot_size' value='3' style='width: 20px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td width='60'>&nbsp;&nbsp; Border size</td>
+ <td>&nbsp;<input type='text' id='c_border_size' value='2' style='width: 20px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;<input type='checkbox' id='c_border_enabled' checked='checked' onclick='checkPlotBorder();' /></td>
+ <td>&nbsp;border enabled</td>
+ </tr></table>
+ <br/>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/chart_bar.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>Bar charts specifics</b></td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td>&nbsp;<input type='radio' id='c_bar_classic' name='c_bar_design' value='0' checked='checked' /></td>
+ <td>&nbsp;Classic</td>
+ <td>&nbsp;<input type='radio' id='c_bar_rounded' name='c_bar_design' value='1' /></td>
+ <td>&nbsp;Rounded</td>
+ <td>&nbsp;<input type='radio' id='c_bar_gradient' name='c_bar_design' value='2' /></td>
+ <td>&nbsp;Gradient filling</td>
+ <td>&nbsp;<input type='checkbox' id='c_around_zero1' checked='checked' /></td>
+ <td>&nbsp;around zero</td>
+ </tr></table>
+ <br/>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/chart_curve.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>Area charts specifics</b></td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='100'>Forced transparency</td>
+ <td><input type='text' id='c_transparency' value='50' style='width: 20px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;<input type='checkbox' id='c_forced_transparency' checked='checked' onclick='checkAreaChart();' /></td>
+ <td>&nbsp;enabled</td>
+ <td>&nbsp;<input type='checkbox' id='c_around_zero2' checked='checked' /></td>
+ <td>&nbsp;wrapped around zero</td>
+ </tr></table>
+ </div>
+
+ <div class="roundedCorner" id='tab5' style='display: none; margin-top: 30px; margin-left: 20px; width: 350px; height: 420px; background: #F0F0F0; padding: 10px; color: #667309; border: 1px solid #E0E0E0'>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/application_form.png' width='16' height='16' alt=''/></td>
+ <td width='240'><b>Legend</b></td>
+ <td width='20'><input type='checkbox' id='l_enabled' checked='checked' /></td>
+ <td width='38'>Enabled</td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='50'>Font</td>
+ <td><select id='l_font'><?php listfonts("pf_arma_five"); ?></select></td>
+ <td>&nbsp; Size &nbsp;</td>
+ <td><input type='text' id='l_font_size' value='6' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp; Color &nbsp;</td>
+ <td><input type='text' id='l_font_color' class='color' value='#000000' style='text-align: center; width: 50px;' onchange='applyColor("l_font_color","l_font_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td><div id='l_font_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>Margin</td>
+ <td><input type='text' id='l_margin' value='6' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp; Alpha &nbsp;</td>
+ <td><input type='text' id='l_alpha' value='30' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp; Format</td>
+ <td>&nbsp; <select id='l_format'><?php echo LegendFormat(); ?></select></td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>Orientation</td>
+ <td>&nbsp; <select id='l_orientation' style='width: 160px;'><option value='LEGEND_VERTICAL'>LEGEND_VERTICAL</option><option value='LEGEND_HORIZONTAL' selected='selected'>LEGEND_HORIZONTAL</option></select></td>
+ <td>&nbsp; Box size &nbsp;</td>
+ <td><input type='text' id='l_box_size' value='5' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>Position</td>
+ <td>&nbsp; <select id='l_position' style='width: 160px;' onclick='checkLegend();'><option value='CORNER_TOP_RIGHT'>CORNER_TOP_RIGHT</option><option value='CORNER_BOTTOM_RIGHT'>CORNER_BOTTOM_RIGHT</option><option value='Manual'>Manual</option></select></td>
+ <td>&nbsp; X &nbsp;</td>
+ <td><input type='text' id='l_x' value='10' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp; Y &nbsp;</td>
+ <td><input type='text' id='l_y' value='10' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>Layout</td>
+ <td>&nbsp; <select id='l_family' style='width: 160px;'><option value='LEGEND_SERIE_BOX'>LEGEND_SERIE_BOX</option><option value='LEGEND_FAMILY_CIRCLE'>LEGEND_FAMILY_CIRCLE</option><option value='LEGEND_FAMILY_LINE'>LEGEND_FAMILY_LINE</option></select></td>
+ </tr></table>
+ <br/>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/vector.png' width='16' height='16' alt=''/></td>
+ <td width='240'><b>Threshold</b></td>
+ <td width='20'><input type='checkbox' id='t_enabled' /></td>
+ <td width='38'>Enabled</td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='50'>Value</td>
+ <td width='60'><input type='text' id='t_value' value='0' style='width: 30px; text-align: center' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;<input type='radio' id='t_axis0' name='t_axis' value='0' checked='checked' /></td>
+ <td>&nbsp;Axis 0</td>
+ <td>&nbsp;<input type='radio' id='t_axis1' name='t_axis' value='1' /></td>
+ <td>&nbsp;Axis 1</td>
+ <td>&nbsp;<input type='radio' id='t_axis2' name='t_axis' value='2' /></td>
+ <td>&nbsp;Axis 2</td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>Color</td>
+ <td><input type='text' id='t_color' class='color' value='#000000' style='text-align: center; width: 50px;' onchange='applyColor("t_color","t_color_show");' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td><div id='t_color_show' style='margin-left: 4px; width: 10px; height: 10px; border: 1px solid #808080;'></div></td>
+ <td>&nbsp; Alpha &nbsp;</td>
+ <td><input type='text' id='t_alpha' value='50' style='width: 20px; text-align: center;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp;&nbsp; <input type='checkbox' id='t_ticks' checked='checked' /></td>
+ <td>&nbsp; ticks &nbsp;</td>
+ </tr></table>
+ <table><tr>
+ <td width='50'>Caption</td>
+ <td><input type='text' id='t_caption' value='Threshold' style='width: 50px;' onmouseover='setFocus(this,true);' onmouseout='setFocus(this,false);' /></td>
+ <td>&nbsp; <input type='checkbox' id='t_box' checked='checked' /></td>
+ <td>&nbsp;in a box&nbsp;</td>
+ <td>&nbsp; <input type='checkbox' id='t_caption_enabled' checked='checked' /></td>
+ <td>&nbsp;caption enabled &nbsp;</td>
+ </tr></table>
+ <br/>
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/shape_flip_vertical.png' width='16' height='16' alt=''/></td>
+ <td width='240'><b>Slope chart</b></td>
+ <td width='20'><input type='checkbox' id='sl_enabled' onclick='doLayout();' /></td>
+ <td width='38'>Enabled</td>
+ </tr></table>
+ <table><tr>
+ <td>&nbsp; <input type='checkbox' id='sl_shaded' checked='checked' /></td>
+ <td>&nbsp;Shaded&nbsp;</td>
+ <td>&nbsp; <input type='checkbox' id='sl_caption_enabled' checked='checked' /></td>
+ <td>&nbsp;With caption &nbsp;</td>
+ <td>&nbsp; <input type='checkbox' id='sl_caption_line' checked='checked' /></td>
+ <td>&nbsp;Use line as caption &nbsp;</td>
+ </tr></table>
+ <br/>
+
+ <table style='background-color: #E8E8E8; padding: 1px; border-top: 1px solid #F5F5F5; border-bottom: 1px solid #E0E0E0'><tr>
+ <td width='20'><img src='graphix/color_swatch.png' width='16' height='16' alt=''/></td>
+ <td width='300'><b>Palette</b></td>
+ </tr></table>
+ <br/>
+ <table><tr>
+ <td width='50'>Template</td>
+ <td>&nbsp; <select id='p_template'><?php echo listPalettes(); ?></select></td>
+ </tr></table>
+ </div>
+ </td>
+ <td width='20'></td>
+ <td width='730'>
+ <center><div id='result_area' style='font-size: 10px;'></div></center>
+ </td>
+ </tr></table>
+<script type="text/javascript">
+ CurrentDiv = 1;
+ URL = "";
+ Automatic = true;
+
+ /* Initial layout */
+ toggleDIV(1);
+ applyCorners();
+ randomize();
+ setDefaultAbsissa();
+ checkEnabledAxis();
+ toggleSubTicks();
+ toggleAutoMargins();
+ checkChartSettings();
+ checkLegend();
+ setColors();
+</script>
+</body>
+</html>
+<?php
+ function listfonts($Default="")
+ {
+ echo "<option value='advent_light.ttf'>advent_light</option>";
+ echo "<option value='Bedizen.ttf'>Bedizen</option>";
+ if ( $Default == "" )
+ { echo "<option value='Forgotte.ttf' selected='selected'>Forgotte</option>"; }
+ else
+ { echo "<option value='Forgotte.ttf'>Forgotte</option>"; }
+ echo "<option value='GeosansLight.ttf'>GeosansLight</option>";
+ if ( $Default == "pf_arma_five" )
+ { echo "<option value='pf_arma_five.ttf' selected='selected'>pf_arma_five</option>"; }
+ else
+ { echo "<option value='pf_arma_five.ttf'>pf_arma_five</option>"; }
+ echo "<option value='Silkscreen.ttf'>Silkscreen</option>";
+ }
+
+ function listaxis()
+ {
+ echo "<option value='0' selected='selected'>Axis 0</option>";
+ echo "<option value='1'>Axis 1</option>";
+ echo "<option value='2'>Axis 2</option>";
+ }
+
+ function listaxispos()
+ {
+ echo "<option value='left' selected='selected'>Left</option>";
+ echo "<option value='right'>Right</option>";
+ }
+
+ function LegendFormat()
+ {
+ echo "<option value='LEGEND_NOBORDER' selected='selected'>LEGEND_NOBORDER</option>";
+ echo "<option value='LEGEND_BOX'>LEGEND_BOX</option>";
+ echo "<option value='LEGEND_ROUND'>LEGEND_ROUND</option>";
+ }
+
+ function listCharts()
+ {
+ echo "<option value='plot'>Plot chart</option>";
+ echo "<option value='line'>Line chart</option>";
+ echo "<option value='spline' selected='selected'>Spline chart</option>";
+ echo "<option value='step'>Step chart</option>";
+ echo "<option value='bar'>Bar chart</option>";
+ echo "<option value='area'>Area chart</option>";
+ echo "<option value='fspline'>Filled spline chart &nbsp;&nbsp;&nbsp;&nbsp;</option>";
+ echo "<option value='fstep'>Filled step chart</option>";
+ echo "<option value='sbar'>Stacked bar chart</option>";
+ echo "<option value='sarea'>Stacked area chart</option>";
+ }
+
+ function listPalettes()
+ {
+ echo "<option value='default'>Default</option>";
+ echo "<option value='autumn'>Autumn</option>";
+ echo "<option value='blind'>Blind</option>";
+ echo "<option value='evening'>Evening</option>";
+ echo "<option value='kitchen'>Kitchen</option>";
+ echo "<option value='light'>Light</option>";
+ echo "<option value='navy'>Navy</option>";
+ echo "<option value='shade'>Shade</option>";
+ echo "<option value='spring'>Spring</option>";
+ echo "<option value='shade'>Shade</option>";
+ echo "<option value='summer'>Summer</option>";
+ }
+
+ function listalign()
+ {
+ echo "<option value='TEXT_ALIGN_TOPLEFT'>TEXT_ALIGN_TOPLEFT</option>";
+ echo "<option value='TEXT_ALIGN_TOPMIDDLE'>TEXT_ALIGN_TOPMIDDLE</option>";
+ echo "<option value='TEXT_ALIGN_TOPRIGHT'>TEXT_ALIGN_TOPRIGHT</option>";
+ echo "<option value='TEXT_ALIGN_MIDDLELEFT'>TEXT_ALIGN_MIDDLELEFT</option>";
+ echo "<option selected='selected' value='TEXT_ALIGN_MIDDLEMIDDLE'>TEXT_ALIGN_MIDDLEMIDDLE</option>";
+ echo "<option value='TEXT_ALIGN_MIDDLERIGHT'>TEXT_ALIGN_MIDDLERIGHT</option>";
+ echo "<option value='TEXT_ALIGN_BOTTOMLEFT'>TEXT_ALIGN_BOTTOMLEFT</option>";
+ echo "<option value='TEXT_ALIGN_BOTTOMMIDDLE'>TEXT_ALIGN_BOTTOMMIDDLE</option>";
+ echo "<option value='TEXT_ALIGN_BOTTOMRIGHT'>TEXT_ALIGN_BOTTOMRIGHT</option>";
+ }
+
+ function listaxisformat()
+ {
+ echo "<option selected='selected' value='AXIS_FORMAT_DEFAULT'>DEFAULT</option>";
+ echo "<option value='AXIS_FORMAT_METRIC'>METRIC</option>";
+ echo "<option value='AXIS_FORMAT_CURRENCY'>CURRENCY</option>";
+ }
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/script/render.php b/notFinishedCode/pChart2.1.2/examples/sandbox/script/render.php
new file mode 100644
index 0000000..d281d86
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/script/render.php
@@ -0,0 +1,891 @@
+<?php
+ /*
+ render.php - Sandbox rendering engine
+
+ Version : 1.1.0
+ Made by : Jean-Damien POGOLOTTI
+ Last Update : 18/01/11
+
+ This file can be distributed under the license you can find at :
+
+ http://www.pchart.net/license
+
+ You can find the whole class documentation on the pChart web site.
+ */
+
+ session_start();
+
+ if ( !isset($_GET["Mode"]) ) { $Mode = "Render"; } else { $Mode = $_GET["Mode"]; }
+
+ $Constants = readConstantFile();
+
+ /* -- Retrieve General configuration items -------------------------------- */
+ $g_width = $_SESSION["g_width"];
+ $g_height = $_SESSION["g_height"];
+ $g_border = $_SESSION["g_border"];
+
+ $g_aa = $_SESSION["g_aa"];
+ $g_shadow = $_SESSION["g_shadow"];
+ $g_transparent = $_SESSION["g_transparent"];
+
+ $g_title_enabled = $_SESSION["g_title_enabled"];
+ $g_title = $_SESSION["g_title"];
+ $g_title_align = $_SESSION["g_title_align"];
+ $g_title_x = $_SESSION["g_title_x"];
+ $g_title_y = $_SESSION["g_title_y"];
+ $g_title_color = $_SESSION["g_title_color"];
+ $g_title_font = $_SESSION["g_title_font"];
+ $g_title_font_size = $_SESSION["g_title_font_size"];
+ $g_title_box = $_SESSION["g_title_box"];
+
+ $g_solid_enabled = $_SESSION["g_solid_enabled"];
+ $g_solid_color = $_SESSION["g_solid_color"];
+ $g_solid_dashed = $_SESSION["g_solid_dashed"];
+
+ $g_gradient_enabled = $_SESSION["g_gradient_enabled"];
+ $g_gradient_start = $_SESSION["g_gradient_start"];
+ $g_gradient_end = $_SESSION["g_gradient_end"];
+ $g_gradient_direction = $_SESSION["g_gradient_direction"];
+ $g_gradient_alpha = $_SESSION["g_gradient_alpha"];
+ /* ------------------------------------------------------------------------ */
+
+ /* -- Retrieve Data configuration items ----------------------------------- */
+ $d_serie1_enabled = $_SESSION["d_serie1_enabled"];
+ $d_serie2_enabled = $_SESSION["d_serie2_enabled"];
+ $d_serie3_enabled = $_SESSION["d_serie3_enabled"];
+ $d_absissa_enabled = $_SESSION["d_absissa_enabled"];
+
+ $d_serie1_name = $_SESSION["d_serie1_name"];
+ $d_serie2_name = $_SESSION["d_serie2_name"];
+ $d_serie3_name = $_SESSION["d_serie3_name"];
+
+ $d_serie1_axis = $_SESSION["d_serie1_axis"];
+ $d_serie2_axis = $_SESSION["d_serie2_axis"];
+ $d_serie3_axis = $_SESSION["d_serie3_axis"];
+
+ $data0 = $_SESSION["data0"];
+ $data1 = $_SESSION["data1"];
+ $data2 = $_SESSION["data2"];
+ $absissa = $_SESSION["absissa"];
+
+ $d_normalize_enabled = $_SESSION["d_normalize_enabled"];
+
+ $d_axis0_name = $_SESSION["d_axis0_name"];
+ $d_axis1_name = $_SESSION["d_axis1_name"];
+ $d_axis2_name = $_SESSION["d_axis2_name"];
+
+ $d_axis0_unit = $_SESSION["d_axis0_unit"];
+ $d_axis1_unit = $_SESSION["d_axis1_unit"];
+ $d_axis2_unit = $_SESSION["d_axis2_unit"];
+
+ $d_axis0_position = $_SESSION["d_axis0_position"];
+ $d_axis1_position = $_SESSION["d_axis1_position"];
+ $d_axis2_position = $_SESSION["d_axis2_position"];
+
+ $d_axis0_format = $_SESSION["d_axis0_format"];
+ $d_axis1_format = $_SESSION["d_axis1_format"];
+ $d_axis2_format = $_SESSION["d_axis2_format"];
+
+ /* ------------------------------------------------------------------------ */
+
+ /* -- Retrieve Scale configuration items ---------------------------------- */
+ $s_x = $_SESSION["s_x"];
+ $s_y = $_SESSION["s_y"];
+ $s_width = $_SESSION["s_width"];
+ $s_height = $_SESSION["s_height"];
+ $s_direction = $_SESSION["s_direction"];
+ $s_arrows_enabled = $_SESSION["s_arrows_enabled"];
+ $s_mode = $_SESSION["s_mode"];
+ $s_cycle_enabled = $_SESSION["s_cycle_enabled"];
+ $s_x_margin = $_SESSION["s_x_margin"];
+ $s_y_margin = $_SESSION["s_y_margin"];
+ $s_automargin_enabled = $_SESSION["s_automargin_enabled"];
+ $s_font = $_SESSION["s_font"];
+ $s_font_size = $_SESSION["s_font_size"];
+ $s_font_color = $_SESSION["s_font_color"];
+
+ $s_x_labeling = $_SESSION["s_x_labeling"];
+ $s_x_skip = $_SESSION["s_x_skip"];
+ $s_x_label_rotation = $_SESSION["s_x_label_rotation"];
+
+ $s_grid_color = $_SESSION["s_grid_color"];
+ $s_grid_alpha = $_SESSION["s_grid_alpha"];
+ $s_grid_x_enabled = $_SESSION["s_grid_x_enabled"];
+ $s_grid_y_enabled = $_SESSION["s_grid_y_enabled"];
+
+ $s_ticks_color = $_SESSION["s_ticks_color"];
+ $s_ticks_alpha = $_SESSION["s_ticks_alpha"];
+ $s_subticks_color = $_SESSION["s_subticks_color"];
+ $s_subticks_alpha = $_SESSION["s_subticks_alpha"];
+ $s_subticks_enabled = $_SESSION["s_subticks_enabled"];
+ /* ------------------------------------------------------------------------ */
+
+ /* -- Retrieve Chart configuration items ---------------------------------- */
+ $c_family = $_SESSION["c_family"];
+ $c_display_values = $_SESSION["c_display_values"];
+ $c_break_color = $_SESSION["c_break_color"];
+ $c_break = $_SESSION["c_break"];
+
+ $c_plot_size = $_SESSION["c_plot_size"];
+ $c_border_size = $_SESSION["c_border_size"];
+ $c_border_enabled = $_SESSION["c_border_enabled"];
+
+ $c_bar_classic = $_SESSION["c_bar_classic"];
+ $c_bar_rounded = $_SESSION["c_bar_rounded"];
+ $c_bar_gradient = $_SESSION["c_bar_gradient"];
+ $c_around_zero1 = $_SESSION["c_around_zero1"];
+
+ $c_transparency = $_SESSION["c_transparency"];
+ $c_forced_transparency = $_SESSION["c_forced_transparency"];
+ $c_around_zero2 = $_SESSION["c_around_zero2"];
+ /* ------------------------------------------------------------------------ */
+
+ /* -- Retrieve Legend configuration items ---------------------------------- */
+ $l_enabled = $_SESSION["l_enabled"];
+
+ $l_font = $_SESSION["l_font"];
+ $l_font_size = $_SESSION["l_font_size"];
+ $l_font_color = $_SESSION["l_font_color"];
+
+ $l_margin = $_SESSION["l_margin"];
+ $l_alpha = $_SESSION["l_alpha"];
+ $l_format = $_SESSION["l_format"];
+
+ $l_orientation = $_SESSION["l_orientation"];
+ $l_box_size = $_SESSION["l_box_size"];
+
+ $l_position = $_SESSION["l_position"];
+ $l_x = $_SESSION["l_x"];
+ $l_y = $_SESSION["l_y"];
+
+ $l_family = $_SESSION["l_family"];
+ /* ------------------------------------------------------------------------ */
+
+ /* -- Retrieve Threshold configuration items ------------------------------ */
+ $t_enabled = $_SESSION["t_enabled"];
+
+ $t_value = $_SESSION["t_value"];
+ $t_axis = $_SESSION["t_axis"];
+
+ $t_color = $_SESSION["t_color"];
+ $t_alpha = $_SESSION["t_alpha"];
+ $t_ticks = $_SESSION["t_ticks"];
+
+ $t_caption = $_SESSION["t_caption"];
+ $t_box = $_SESSION["t_box"];
+ $t_caption_enabled = $_SESSION["t_caption_enabled"];
+ /* ------------------------------------------------------------------------ */
+
+ /* -- Retrieve slope chart configuration items ---------------------------- */
+ $sl_enabled = $_SESSION["sl_enabled"];
+ $sl_shaded = $_SESSION["sl_shaded"];
+ $sl_caption_enabled = $_SESSION["sl_caption_enabled"];
+ $sl_caption_line = $_SESSION["sl_caption_line"];
+ /* ------------------------------------------------------------------------ */
+
+ /* -- Retrieve color configuration items ---------------------------------- */
+ $p_template = $_SESSION["p_template"];
+ /* ------------------------------------------------------------------------ */
+
+
+ /* pChart library inclusions */
+ include("../../../class/pData.class.php");
+ include("../../../class/pDraw.class.php");
+ include("../../../class/pImage.class.php");
+
+ $myData = new pData();
+ if ( $Mode == "Source" )
+ {
+ echo "&lt;?php\r\n";
+ echo 'include("class/pData.class.php");'."\r\n";
+ echo 'include("class/pDraw.class.php");'."\r\n";
+ echo 'include("class/pImage.class.php");'."\r\n";
+ echo "\r\n";
+ echo '$myData = new pData();'."\r\n";
+ }
+
+ if ( $p_template != "default" )
+ $myData->loadPalette("../../../palettes/".$p_template.".color",TRUE);
+
+ $Axis = "";
+ if ( $d_serie1_enabled == "true" )
+ {
+ $data0 = stripTail($data0);
+ $Values = preg_split("/!/",right($data0,strlen($data0)-1));
+ foreach($Values as $key => $Value)
+ { if ( $Value == "" ) { $Value = VOID; } $myData->addPoints($Value,"Serie1"); }
+
+ $myData->setSerieDescription("Serie1",$d_serie1_name);
+ $myData->setSerieOnAxis("Serie1",$d_serie1_axis);
+ $Axis[$d_serie1_axis] = TRUE;
+
+ if ( $Mode == "Source" )
+ {
+ $Data = "";
+ foreach($Values as $key => $Value)
+ { if ( $Value == "" || $Value == VOID ) { $Value = "VOID"; } $Data = $Data.",".toString($Value); }
+ $Data = right($Data,strlen($Data)-1);
+
+ echo '$myData->addPoints(array('.$Data.'),"Serie1");'."\r\n";
+ echo '$myData->setSerieDescription("Serie1","'.$d_serie1_name.'");'."\r\n";
+ echo '$myData->setSerieOnAxis("Serie1",'.$d_serie1_axis.');'."\r\n\r\n";
+
+ $Axis[$d_serie1_axis] = TRUE;
+ }
+ }
+
+ if ( $d_serie2_enabled == "true" )
+ {
+ $data1 = stripTail($data1);
+ $Values = preg_split("/!/",right($data1,strlen($data1)-1));
+ foreach($Values as $key => $Value)
+ { if ( $Value == "" ) { $Value = VOID; } $myData->addPoints($Value,"Serie2"); }
+
+ $myData->setSerieDescription("Serie2",$d_serie2_name);
+ $myData->setSerieOnAxis("Serie2",$d_serie2_axis);
+ $Axis[$d_serie2_axis] = TRUE;
+
+ if ( $Mode == "Source" )
+ {
+ $Data = "";
+ foreach($Values as $key => $Value)
+ { if ( $Value == "" ) { $Value = "VOID"; } $Data = $Data.",".toString($Value); }
+ $Data = right($Data,strlen($Data)-1);
+
+ echo '$myData->addPoints(array('.$Data.'),"Serie2");'."\r\n";
+ echo '$myData->setSerieDescription("Serie2","'.$d_serie2_name.'");'."\r\n";
+ echo '$myData->setSerieOnAxis("Serie2",'.$d_serie2_axis.');'."\r\n\r\n";
+
+ $Axis[$d_serie2_axis] = TRUE;
+ }
+ }
+
+ if ( $d_serie3_enabled == "true" )
+ {
+ $data2 = stripTail($data2);
+ $Values = preg_split("/!/",right($data2,strlen($data2)-1));
+ foreach($Values as $key => $Value)
+ { if ( $Value == "" ) { $Value = VOID; } $myData->addPoints($Value,"Serie3"); }
+
+ $myData->setSerieDescription("Serie3",$d_serie3_name);
+ $myData->setSerieOnAxis("Serie3",$d_serie3_axis);
+ $Axis[$d_serie3_axis] = TRUE;
+
+ if ( $Mode == "Source" )
+ {
+ $Data = "";
+ foreach($Values as $key => $Value)
+ { if ( $Value == "" ) { $Value = "VOID"; } $Data = $Data.",".toString($Value); }
+ $Data = right($Data,strlen($Data)-1);
+
+ echo '$myData->addPoints(array('.$Data.'),"Serie3");'."\r\n";
+ echo '$myData->setSerieDescription("Serie3","'.$d_serie3_name.'");'."\r\n";
+ echo '$myData->setSerieOnAxis("Serie3",'.$d_serie3_axis.');'."\r\n\r\n";
+
+ $Axis[$d_serie3_axis] = TRUE;
+ }
+ }
+
+ if ( $d_absissa_enabled == "true" )
+ {
+ $absissa = stripTail($absissa);
+ $Values = preg_split("/!/",right($absissa,strlen($absissa)-1));
+ foreach($Values as $key => $Value)
+ { if ( $Value == "" ) { $Value = VOID; } $myData->addPoints($Value,"Absissa"); }
+
+ $myData->setAbscissa("Absissa");
+
+ if ( $Mode == "Source" )
+ {
+ $Data = "";
+ foreach($Values as $key => $Value)
+ { if ( $Value == "" ) { $Value = "VOID"; } $Data = $Data.",".toString($Value); }
+ $Data = right($Data,strlen($Data)-1);
+
+ echo '$myData->addPoints(array('.$Data.'),"Absissa");'."\r\n";
+ echo '$myData->setAbscissa("Absissa");'."\r\n\r\n";
+ }
+ }
+
+ if ( isset($Axis[0]) )
+ {
+ if ( $d_axis0_position == "left" ) { $myData->setAxisPosition(0,AXIS_POSITION_LEFT); } else { $myData->setAxisPosition(0,AXIS_POSITION_RIGHT); }
+ $myData->setAxisName(0,$d_axis0_name);
+ $myData->setAxisUnit(0,$d_axis0_unit);
+
+ if ( $d_axis0_format == "AXIS_FORMAT_METRIC" ) { $myData->setAxisDisplay(0,680004); }
+ if ( $d_axis0_format == "AXIS_FORMAT_CURRENCY" ) { $myData->setAxisDisplay(0,680005,"$"); }
+
+ if ( $Mode == "Source" )
+ {
+ if ( $d_axis0_position == "left" ) { echo '$myData->setAxisPosition(0,AXIS_POSITION_LEFT);'."\r\n"; } else { echo '$myData->setAxisPosition(0,AXIS_POSITION_RIGHT);'."\r\n"; }
+ echo '$myData->setAxisName(0,"'.$d_axis0_name.'");'."\r\n";
+ echo '$myData->setAxisUnit(0,"'.$d_axis0_unit.'");'."\r\n\r\n";
+ }
+ }
+
+ if ( isset($Axis[1]) )
+ {
+ if ( $d_axis1_position == "left" ) { $myData->setAxisPosition(1,AXIS_POSITION_LEFT); } else { $myData->setAxisPosition(1,AXIS_POSITION_RIGHT); }
+ $myData->setAxisName(1,$d_axis1_name);
+ $myData->setAxisUnit(1,$d_axis1_unit);
+
+ if ( $Mode == "Source" )
+ {
+ if ( $d_axis1_position == "left" ) { echo '$myData->setAxisPosition(1,AXIS_POSITION_LEFT);'."\r\n"; } else { echo '$myData->setAxisPosition(1,AXIS_POSITION_RIGHT);'."\r\n"; }
+ echo '$myData->setAxisName(1,"'.$d_axis1_name.'");'."\r\n";
+ echo '$myData->setAxisUnit(1,"'.$d_axis1_unit.'");'."\r\n\r\n";
+ }
+ }
+
+ if ( isset($Axis[2]) )
+ {
+ if ( $d_axis2_position == "left" ) { $myData->setAxisPosition(2,AXIS_POSITION_LEFT); } else { $myData->setAxisPosition(2,AXIS_POSITION_RIGHT); }
+ $myData->setAxisName(2,$d_axis2_name);
+ $myData->setAxisUnit(2,$d_axis2_unit);
+
+ if ( $Mode == "Source" )
+ {
+ if ( $d_axis2_position == "left" ) { echo '$myData->setAxisPosition(2,AXIS_POSITION_LEFT);'."\r\n"; } else { echo '$myData->setAxisPosition(2,AXIS_POSITION_RIGHT);'."\r\n"; }
+ echo '$myData->setAxisName(2,"'.$d_axis2_name.'");'."\r\n";
+ echo '$myData->setAxisUnit(2,"'.$d_axis2_unit.'");'."\r\n\r\n";
+ }
+ }
+
+ if ( $d_normalize_enabled == "true" )
+ {
+ if ( $Mode == "Render" )
+ $myData->normalize(100);
+ else
+ echo '$myData->normalize(100);'."\r\n";
+ }
+
+ if ( $Mode == "Render" )
+ {
+ if ( $g_transparent == "true" )
+ $myPicture = new pImage($g_width,$g_height,$myData,TRUE);
+ else
+ $myPicture = new pImage($g_width,$g_height,$myData);
+ }
+ else
+ {
+ $myPicture = new pImage($g_width,$g_height,$myData);
+ if ( $g_transparent == "true" )
+ echo '$myPicture = new pImage('.$g_width.','.$g_height.',$myData,TRUE);'."\r\n";
+ else
+ echo '$myPicture = new pImage('.$g_width.','.$g_height.',$myData);'."\r\n";
+ }
+
+ if ( $g_aa == "false" )
+ {
+ if ( $Mode == "Render" )
+ $myPicture->Antialias = FALSE;
+ else
+ echo '$myPicture->Antialias = FALSE;'."\r\n";
+ }
+
+ if ( $g_solid_enabled == "true" )
+ {
+ list($R,$G,$B) = extractColors($g_solid_color);
+ $Settings = array("R"=>$R,"G"=>$G,"B"=>$B);
+
+ if ( $g_solid_dashed == "true" ) { $Settings["Dash"] = TRUE; $Settings["DashR"]=$R+20; $Settings["DashG"]=$G+20; $Settings["DashB"]=$B+20; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawFilledRectangle(0,0,$g_width,$g_height,$Settings);
+ else
+ {
+ echo dumpArray("Settings",$Settings);
+ echo '$myPicture->drawFilledRectangle(0,0,'.$g_width.','.$g_height.',$Settings);'."\r\n\r\n";
+ }
+ }
+
+ if ( $g_gradient_enabled == "true" )
+ {
+ list($StartR,$StartG,$StartB) = extractColors($g_gradient_start);
+ list($EndR,$EndG,$EndB) = extractColors($g_gradient_end);
+
+ $Settings = array("StartR"=>$StartR,"StartG"=>$StartG,"StartB"=>$StartB,"EndR"=>$EndR,"EndG"=>$EndG,"EndB"=>$EndB,"Alpha"=>$g_gradient_alpha);
+
+ if ( $Mode == "Render" )
+ {
+ if ( $g_gradient_direction == "vertical" )
+ $myPicture->drawGradientArea(0,0,$g_width,$g_height,DIRECTION_VERTICAL,$Settings);
+ else
+ $myPicture->drawGradientArea(0,0,$g_width,$g_height,DIRECTION_HORIZONTAL,$Settings);
+ }
+ else
+ {
+ echo dumpArray("Settings",$Settings);
+
+ if ( $g_gradient_direction == "vertical" )
+ echo '$myPicture->drawGradientArea(0,0,'.$g_width.','.$g_height.',DIRECTION_VERTICAL,$Settings);'."\r\n\r\n";
+ else
+ echo '$myPicture->drawGradientArea(0,0,'.$g_width.','.$g_height.',DIRECTION_HORIZONTAL,$Settings);'."\r\n\r\n";
+ }
+ }
+
+ if ( $Mode == "Render" )
+ {
+ if ( $g_border == "true" ) { $myPicture->drawRectangle(0,0,$g_width-1,$g_height-1,array("R"=>0,"G"=>0,"B"=>0)); }
+ if ( $g_shadow == "true" ) { $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>50,"G"=>50,"B"=>50,"Alpha"=>20)); }
+ }
+ else
+ {
+ if ( $g_border == "true" ) { echo '$myPicture->drawRectangle(0,0,'.($g_width-1).','.($g_height-1).',array("R"=>0,"G"=>0,"B"=>0));'."\r\n\r\n"; }
+ if ( $g_shadow == "true" ) { echo '$myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>50,"G"=>50,"B"=>50,"Alpha"=>20));'."\r\n\r\n"; }
+ }
+
+ if ( $g_title_enabled == "true" )
+ {
+ if ( $Mode == "Render" )
+ $myPicture->setFontProperties(array("FontName"=>"../../../fonts/".$g_title_font,"FontSize"=>$g_title_font_size));
+ else
+ echo '$myPicture->setFontProperties(array("FontName"=>"fonts/'.$g_title_font.'","FontSize"=>'.$g_title_font_size.'));'."\r\n";
+
+ list($R,$G,$B) = extractColors($g_title_color);
+
+ $TextSettings = array("Align"=>getTextAlignCode($g_title_align),"R"=>$R,"G"=>$G,"B"=>$B);
+ if ( $g_title_box == "true" ) { $TextSettings["DrawBox"] = TRUE; $TextSettings["BoxAlpha"] = 30; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawText($g_title_x,$g_title_y,$g_title,$TextSettings);
+ else
+ {
+ echo dumpArray("TextSettings",$TextSettings);
+ echo '$myPicture->drawText('.$g_title_x.','.$g_title_y.',"'.$g_title.'",$TextSettings);'."\r\n\r\n";
+ }
+ }
+
+ /* Scale section */
+ if ( $Mode == "Render" )
+ { if ( $g_shadow == "true" ) { $myPicture->setShadow(FALSE); } }
+ else
+ { if ( $g_shadow == "true" ) { echo '$myPicture->setShadow(FALSE);'."\r\n"; } }
+
+ if ( $Mode == "Render" )
+ $myPicture->setGraphArea($s_x,$s_y,$s_x+$s_width,$s_y+$s_height);
+ else
+ echo '$myPicture->setGraphArea('.$s_x.','.$s_y.','.($s_x+$s_width).','.($s_y+$s_height).');'."\r\n";
+
+ list($R,$G,$B) = extractColors($s_font_color);
+ if ( $Mode == "Render" )
+ $myPicture->setFontProperties(array("R"=>$R,"G"=>$G,"B"=>$B,"FontName"=>"../../../fonts/".$s_font,"FontSize"=>$s_font_size));
+ else
+ echo '$myPicture->setFontProperties(array("R"=>'.$R.',"G"=>'.$G.',"B"=>'.$B.',"FontName"=>"fonts/'.$s_font.'","FontSize"=>'.$s_font_size.'));'."\r\n\r\n";
+
+ /* Scale specific parameters -------------------------------------------------------------------------------- */
+ list($GridR,$GridG,$GridB) = extractColors($s_grid_color);
+ list($TickR,$TickG,$TickB) = extractColors($s_ticks_color);
+ list($SubTickR,$SubTickG,$SubTickB) = extractColors($s_subticks_color);
+
+ if ( $s_direction == "SCALE_POS_LEFTRIGHT" ) { $Pos = 690101; } else { $Pos = 690102; }
+ if ( $s_x_labeling == "LABELING_ALL") { $Labeling = 691011; } else { $Labeling = 691012; }
+ if ( $s_mode == "SCALE_MODE_FLOATING" ) { $iMode = 690201; }
+ if ( $s_mode == "SCALE_MODE_START0" ) { $iMode = 690202; }
+ if ( $s_mode == "SCALE_MODE_ADDALL" ) { $iMode = 690203; }
+ if ( $s_mode == "SCALE_MODE_ADDALL_START0" ) { $iMode = 690204; }
+
+ $Settings = array("Pos"=>$Pos,"Mode"=>$iMode,"LabelingMethod"=>$Labeling,"GridR"=>$GridR,"GridG"=>$GridG,"GridB"=>$GridB,"GridAlpha"=>$s_grid_alpha,"TickR"=>$TickR,"TickG"=>$TickG,"TickB"=>$TickB,"TickAlpha"=>$s_ticks_alpha,"LabelRotation"=>$s_x_label_rotation);
+
+ if ( $s_x_skip != 0 ) { $Settings["LabelSkip"] = $s_x_skip; }
+ if ( $s_cycle_enabled == "true" ) { $Settings["CycleBackground"] = TRUE; }
+ if ( $s_arrows_enabled == "true" ) { $Settings["DrawArrows"] = TRUE; }
+ if ( $s_grid_x_enabled == "true" ) { $Settings["DrawXLines"] = TRUE; } else { $Settings["DrawXLines"] = 0; }
+ if ( $s_subticks_enabled == "true" )
+ { $Settings["DrawSubTicks"] = TRUE; $Settings["SubTickR"] = $SubTickR; $Settings["SubTickG"] = $SubTickG; $Settings["SubTickB"] = $SubTickB; $Settings["SubTickAlpha"] = $s_subticks_alpha;}
+ if ( $s_automargin_enabled == "false" )
+ { $Settings["XMargin"] = $s_x_margin; $Settings["YMargin"] = $s_y_margin; }
+
+ if ( $Mode == "Render" )
+ {
+ if ( $s_grid_y_enabled == "true" ) { $Settings["DrawYLines"] = ALL; } else { $Settings["DrawYLines"] = NONE; }
+ $myPicture->drawScale($Settings);
+ }
+ else
+ {
+ if ( $s_grid_y_enabled == "true" ) { $Settings["DrawYLines"] = "ALL"; } else { $Settings["DrawYLines"] = "NONE"; }
+ echo dumpArray("Settings",$Settings);
+ echo '$myPicture->drawScale($Settings);'."\r\n\r\n";
+ }
+ /* ---------------------------------------------------------------------------------------------------------- */
+
+ if ( $Mode == "Render" )
+ { if ( $g_shadow == "true" ) { $myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>50,"G"=>50,"B"=>50,"Alpha"=>10)); } }
+ else
+ { if ( $g_shadow == "true" ) { echo '$myPicture->setShadow(TRUE,array("X"=>1,"Y"=>1,"R"=>50,"G"=>50,"B"=>50,"Alpha"=>10));'."\r\n\r\n"; } }
+
+ /* Chart specific parameters -------------------------------------------------------------------------------- */
+ if ( $c_display_values == "true" ) { $Config = array("DisplayValues"=>TRUE); } else { $Config = ""; }
+
+ if ( $c_family == "plot" )
+ {
+ $Config["PlotSize"] = $c_plot_size;
+ if ( $c_border_enabled == "true" ) { $Config["PlotBorder"] = TRUE; $Config["BorderSize"] = $c_border_size; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawPlotChart($Config);
+ else
+ {
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawPlotChart($Config);'."\r\n";
+ }
+ }
+
+ if ( $c_family == "line" )
+ {
+ if ( $c_break == "true" )
+ {
+ list($BreakR,$BreakG,$BreakB) = extractColors($c_break_color);
+
+ $Config["BreakVoid"] = 0;
+ $Config["BreakR"] = $BreakR;
+ $Config["BreakG"] = $BreakG;
+ $Config["BreakB"] = $BreakB;
+ }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawLineChart($Config);
+ else
+ {
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawLineChart($Config);'."\r\n";
+ }
+ }
+
+ if ( $c_family == "step" )
+ {
+ if ( $c_break == "true" )
+ {
+ list($BreakR,$BreakG,$BreakB) = extractColors($c_break_color);
+
+ $Config["BreakVoid"] = 0;
+ $Config["BreakR"] = $BreakR;
+ $Config["BreakG"] = $BreakG;
+ $Config["BreakB"] = $BreakB;
+ }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawStepChart($Config);
+ else
+ {
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawStepChart($Config);'."\r\n";
+ }
+ }
+
+ if ( $c_family == "spline" )
+ {
+ if ( $c_break == "true" )
+ {
+ list($BreakR,$BreakG,$BreakB) = extractColors($c_break_color);
+
+ $Config["BreakVoid"] = 0;
+ $Config["BreakR"] = $BreakR;
+ $Config["BreakG"] = $BreakG;
+ $Config["BreakB"] = $BreakB;
+ }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawSplineChart($Config);
+ else
+ {
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawSplineChart($Config);'."\r\n";
+ }
+ }
+
+ if ( $c_family == "bar" )
+ {
+ if ( $c_bar_rounded == "true" ) { $Config["Rounded"] = TRUE; }
+ if ( $c_bar_gradient == "true" ) { $Config["Gradient"] = TRUE; }
+ if ( $c_around_zero1 == "true" ) { $Config["AroundZero"] = TRUE; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawBarChart($Config);
+ else
+ {
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawBarChart($Config);'."\r\n";
+ }
+ }
+
+ if ( $c_family == "area" )
+ {
+ if ( $c_forced_transparency == "true" ) { $Config["ForceTransparency"] = $c_transparency; }
+ if ( $c_around_zero2 == "true" ) { $Config["AroundZero"] = TRUE; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawAreaChart($Config);
+ else
+ {
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawAreaChart($Config);'."\r\n";
+ }
+ }
+
+ if ( $c_family == "fstep" )
+ {
+ if ( $c_forced_transparency == "true" ) { $Config["ForceTransparency"] = $c_transparency; }
+ if ( $c_around_zero2 == "true" ) { $Config["AroundZero"] = TRUE; } else { $Config["AroundZero"] = FALSE; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawFilledStepChart($Config);
+ else
+ {
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawFilledStepChart($Config);'."\r\n";
+ }
+ }
+
+ if ( $c_family == "fspline" )
+ {
+ if ( $c_forced_transparency == "true" ) { $Config["ForceTransparency"] = $c_transparency; }
+ if ( $c_around_zero2 == "true" ) { $Config["AroundZero"] = TRUE; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawFilledSplineChart($Config);
+ else
+ {
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawFilledSplineChart($Config);'."\r\n";
+ }
+ }
+
+ if ( $c_family == "sbar" )
+ {
+ if ( $c_bar_rounded == "true" ) { $Config["Rounded"] = TRUE; }
+ if ( $c_bar_gradient == "true" ) { $Config["Gradient"] = TRUE; }
+ if ( $c_around_zero1 == "true" ) { $Config["AroundZero"] = TRUE; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawStackedBarChart($Config);
+ else
+ {
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawStackedBarChart($Config);'."\r\n";
+ }
+ }
+
+ if ( $c_family == "sarea" )
+ {
+ if ( $c_forced_transparency == "true" ) { $Config["ForceTransparency"] = $c_transparency; }
+ if ( $c_around_zero2 == "true" ) { $Config["AroundZero"] = TRUE; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawStackedAreaChart($Config);
+ else
+ {
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawStackedAreaChart($Config);'."\r\n";
+ }
+ }
+
+ if ( $t_enabled == "true" )
+ {
+ list($R,$G,$B) = extractColors($t_color);
+
+ $Config = "";
+ $Config["R"] = $R; $Config["G"] = $G; $Config["B"] = $B;
+ $Config["Alpha"] = $t_alpha;
+
+ if ( isset($myData->Data["Axis"][$t_axis]) ) { $Config["AxisID"] = $t_axis; }
+
+ if ( $t_ticks == "true" ) { $Config["Ticks"] = 4; } else { $Config["Ticks"] = 0; }
+
+ if ( $t_caption_enabled == "true" )
+ {
+ $Config["WriteCaption"] = TRUE;
+ $Config["Caption"] = $t_caption;
+ if ( $t_box == "true" ) { $Config["DrawBox"] = TRUE; }
+ }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawThreshold($t_value,$Config);
+ else
+ {
+ $Config["Caption"] = chr(34).$t_caption.chr(34);
+
+ echo "\r\n";
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawThreshold('.$t_value.',$Config);'."\r\n";
+ }
+ }
+
+ if ( $l_enabled == "true" )
+ {
+ list($R,$G,$B) = extractColors($l_font_color);
+
+ $Config = "";
+ $Config["FontR"] = $R; $Config["FontG"] = $G; $Config["FontB"] = $B;
+ $Config["FontName"] = "../../../fonts/".$l_font;
+ $Config["FontSize"] = $l_font_size;
+ $Config["Margin"] = $l_margin;
+ $Config["Alpha"] = $l_alpha;
+ $Config["BoxSize"] = $l_box_size;
+
+ if ( $l_format == "LEGEND_NOBORDER" ) { $Config["Style"] = 690800; }
+ if ( $l_format == "LEGEND_BOX" ) { $Config["Style"] = 690801; }
+ if ( $l_format == "LEGEND_ROUND" ) { $Config["Style"] = 690802; }
+
+ if ( $l_orientation == "LEGEND_VERTICAL" ) { $Config["Mode"] = 690901; }
+ if ( $l_orientation == "LEGEND_HORIZONTAL" ) { $Config["Mode"] = 690902; }
+
+ if ( $l_family == "LEGEND_FAMILY_CIRCLE" ) { $Config["Family"] = 691052; }
+ if ( $l_family == "LEGEND_FAMILY_LINE" ) { $Config["Family"] = 691053; }
+
+ $Size = $myPicture->getLegendSize($Config);
+ if ( $l_position == "CORNER_TOP_RIGHT" )
+ { $l_y = $l_margin + 10; $l_x = $g_width - $Size["Width"] - 10 + $l_margin; }
+ if ( $l_position == "CORNER_BOTTOM_RIGHT" )
+ { $l_y = $g_height - $Size["Height"] - 10 + $l_margin; $l_x = $g_width - $Size["Width"] - 10 + $l_margin; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawLegend($l_x,$l_y,$Config);
+ else
+ {
+ $Config["FontName"] = chr(34)."fonts/".$l_font.chr(34);
+
+ echo "\r\n";
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawLegend('.$l_x.','.$l_y.',$Config);'."\r\n";
+ }
+ }
+
+ if ( $sl_enabled == "true" )
+ {
+ $Config = "";
+ $Config["CaptionMargin"] = 10;
+ $Config["CaptionWidth"] = 10;
+
+ if ( $sl_shaded == "true" ) { $Config["ShadedSlopeBox"] = TRUE; }
+ if ( $sl_caption_enabled != "true" ) { $Config["Caption"] = FALSE; }
+ if ( $sl_caption_line == "true" ) { $Config["CaptionLine"] =TRUE; }
+
+ if ( $Mode == "Render" )
+ $myPicture->drawDerivative($Config);
+ else
+ {
+ echo "\r\n";
+ echo dumpArray("Config",$Config);
+ echo '$myPicture->drawDerivative($Config);'."\r\n";
+ }
+ }
+
+ if ( $Mode == "Render" )
+ $myPicture->stroke();
+ else
+ echo "\r\n".'$myPicture->stroke();'."\r\n?>";
+
+ function extractColors($Hexa)
+ {
+ if ( strlen($Hexa) != 6 ) { return(array(0,0,0)); }
+
+ $R = hexdec(left($Hexa,2));
+ $G = hexdec(mid($Hexa,3,2));
+ $B = hexdec(right($Hexa,2));
+
+ return(array($R,$G,$B));
+ }
+
+ function getTextAlignCode($Mode)
+ {
+ if ( $Mode == "TEXT_ALIGN_TOPLEFT" ) { return(690401); }
+ if ( $Mode == "TEXT_ALIGN_TOPMIDDLE" ) { return(690402); }
+ if ( $Mode == "TEXT_ALIGN_TOPRIGHT" ) { return(690403); }
+ if ( $Mode == "TEXT_ALIGN_MIDDLELEFT" ) { return(690404); }
+ if ( $Mode == "TEXT_ALIGN_MIDDLEMIDDLE" ) { return(690405); }
+ if ( $Mode == "TEXT_ALIGN_MIDDLERIGHT" ) { return(690406); }
+ if ( $Mode == "TEXT_ALIGN_BOTTOMLEFT" ) { return(690407); }
+ if ( $Mode == "TEXT_ALIGN_BOTTOMMIDDLE" ) { return(690408); }
+ if ( $Mode == "TEXT_ALIGN_BOTTOMRIGHT" ) { return(690409); }
+ }
+
+ function dumpArray($Name,$Values)
+ {
+ if ( $Values == "" ) { return('$'.$Name.' = "";'."\r\n"); }
+
+ $Result = '$'.$Name." = array(";
+ foreach ($Values as $Key => $Value)
+ { $Result = $Result.chr(34).$Key.chr(34)."=>".translate($Value).", "; }
+
+ $Result = left($Result,strlen($Result)-2).");\r\n";
+
+ return($Result);
+ }
+
+ function translate($Value)
+ {
+ global $Constants;
+
+ if ( isset($Constants[$Value]))
+ return($Constants[$Value]);
+ else
+ return($Value);
+ }
+
+
+ function stripTail($Values)
+ {
+ $Values = preg_split("/!/",right($Values,strlen($Values)-1));
+
+ $Temp = ""; $Result = "";
+ foreach($Values as $Key => $Value)
+ {
+ if ( $Value == "" )
+ { $Temp[] = VOID; }
+ else
+ {
+ if ( $Temp != "" && $Result != "" )
+ { $Result = array_merge($Result,$Temp); }
+ elseif( $Temp != "" && $Result == "" )
+ { $Result = $Temp; }
+
+ $Result[] = $Value;
+ $Temp = "";
+ }
+ }
+
+ $Serialized = "!"; foreach($Result as $Key => $Value) { $Serialized = $Serialized.$Value."!"; }
+ $Serialized = left($Serialized,strlen($Serialized)-1);
+
+ return($Serialized);
+ }
+
+ function readConstantFile()
+ {
+ $FileName = "../includes/constants.txt";
+
+ $handle = @fopen($FileName, "r");
+ if ($handle)
+ {
+ $Result = "";
+ while (($buffer = fgets($handle, 4096)) !== false)
+ {
+ $Values = preg_split("/,/",$buffer);
+ $Result[$Values[0]] = $Values[1];
+ }
+ fclose($handle);
+ return($Result);
+ }
+ else
+ { return(array("VOID"=>"0.12345")); }
+ }
+
+ function toString($Value)
+ {
+ if ( is_numeric($Value) || $Value == "VOID")
+ return($Value);
+ else
+ return(chr(34).$Value.chr(34));
+ }
+
+ function left($value,$NbChar)
+ { return substr($value,0,$NbChar); }
+
+ function right($value,$NbChar)
+ { return substr($value,strlen($value)-$NbChar,$NbChar); }
+
+ function mid($value,$Depart,$NbChar)
+ { return substr($value,$Depart-1,$NbChar); }
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/script/session.php b/notFinishedCode/pChart2.1.2/examples/sandbox/script/session.php
new file mode 100644
index 0000000..697f9dd
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/script/session.php
@@ -0,0 +1,24 @@
+<?php
+ /*
+ session.php - Sandbox sesson manager
+
+ Version : 1.1.0
+ Made by : Jean-Damien POGOLOTTI
+ Last Update : 18/01/11
+
+ This file can be distributed under the license you can find at :
+
+ http://www.pchart.net/license
+
+ You can find the whole class documentation on the pChart web site.
+ */
+
+ session_start();
+
+ foreach($_GET as $Key => $Value)
+ { $_SESSION[$Key] = $Value; }
+
+ print_r($_SESSION);
+
+ usleep(200000);
+?> \ No newline at end of file
diff --git a/notFinishedCode/pChart2.1.2/examples/sandbox/style.css b/notFinishedCode/pChart2.1.2/examples/sandbox/style.css
new file mode 100644
index 0000000..6ffbe70
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/sandbox/style.css
@@ -0,0 +1,89 @@
+body
+ {
+ margin: 4px;
+ text-align: left;
+ font-family: tahoma;
+ background-color: #FFFFFF;
+ background-image: url('graphix/background.console.png');
+ }
+
+table { margin: 0px; padding: 0px;}
+
+td { margin: 0px; padding: 0px; }
+
+tr { margin: 0px; padding: 0px; }
+
+td.topMenu { font-family: tahoma; font-size: 11px; }
+
+div.roundedCorner { font-size: 10px; }
+
+div.topMenu { border: 1px solid #FEFEFE; background-color: #EAEAEA; cursor: hand; cursor: pointer; }
+
+input
+ {
+ font-family: tahoma;
+ font-size: 10px;
+ }
+
+input[type="text"]
+ {
+ width: 325px;
+ border: 1px solid #D0D0D0;
+ background-color: #FFFFFF;
+ vertical-align: middle;
+ font-weight: normal;
+ color: #707070;
+ outline: none;
+ height: 15px;
+ }
+
+select
+ {
+ border: 1px solid #D0D0D0;
+ background-color: #FFFFFF;
+ vertical-align: middle;
+ font-weight: normal;
+ color: #707070;
+ outline: none;
+ font-size: 10px;
+ height: 19px;
+ }
+
+input[type="submit"]
+ {
+ border: 1px solid #D0D0D0;
+ background-color: #FFFFFF;
+ vertical-align: middle;
+ font-weight: normal;
+ color: #707070;
+ outline: none;
+ }
+
+pre
+ {
+ font-family; tahoma;
+ font-size: 11px;
+ background-color: #FFFFFF;
+ border: 1px solid #E0E0E0;
+ padding: 5px;
+ margin-top: 20px;
+ text-align: left;
+ overflow-x: auto;
+ white-space: pre-wrap;
+ white-space: -moz-pre-wrap !important;
+ white-space: -pre-wrap;
+ white-space: -o-pre-wrap;
+ word-wrap: break-word;
+ }
+
+a.link:link { text-decoration: none; }
+a.link:visited { text-decoration: none; }
+a.link:hover { text-decoration: underline; }
+
+a.smallLinkGrey:link { text-decoration: none; color: #6A6A6A; }
+a.smallLinkGrey:visited { text-decoration: none; color: #6A6A6A; }
+a.smallLinkGrey:hover { text-decoration: underline; color: #6A6A6A; }
+
+a.smallLinkBlack:link { text-decoration: none; color: #000000; }
+a.smallLinkBlack:visited { text-decoration: none; color: #000000; }
+a.smallLinkBlack:hover { text-decoration: underline; color: #000000; }
diff --git a/notFinishedCode/pChart2.1.2/examples/server.png b/notFinishedCode/pChart2.1.2/examples/server.png
new file mode 100644
index 0000000..3cd12cc
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/server.png
Binary files differ
diff --git a/notFinishedCode/pChart2.1.2/examples/telephone.png b/notFinishedCode/pChart2.1.2/examples/telephone.png
new file mode 100755
index 0000000..7c614b5
--- /dev/null
+++ b/notFinishedCode/pChart2.1.2/examples/telephone.png
Binary files differ