This project is read-only.

Updated Charting Functionality

Jun 24, 2011 at 5:22 PM

All,

I've decided to help Maarten in finishing up some of this project. I have added Chart formatting functionalities, minus any additional Chart types.

I've submitted the updated code to Maarten for his approval. I certainly hope this project helps others as it has helped me.

Some of the additions/changes include:

// Set bar chart type: "col", "bar"
$bar3DChart->setBarDirection("bar");

// Display blank cells as: "gap", "span", "zero"
$bar3DChart->setDisplayBlanksAs("gap");

// Set bar chart grouping: "percentStacked", "stacked", "standard"
$bar3DChart->setGrouping("standard");

// Set Data Value Format
$series1->setNumberFormat("0%");

// Toggle and set Shadow properties
$shape->getShadow()->setVisible(0);
$shape->getShadow()->setDirection(45);
$shape->getShadow()->setDistance(10);

// Set X-axis Major Tick Marks: "cross", "in", "none", "out"
$shape->getPlotArea()->getAxisX()->setMajorTickMark("none");

// Set X-axis Minor Tick Marks: "cross", "in", "none", "out"
$shape->getPlotArea()->getAxisX()->setMinorTickMark("none");

// Set X-axis Position: "b", "l", "r", "t"
$shape->getPlotArea()->getAxisX()->setAxisPosition("b");

// Set X-axis label alignment: "ctr", "l", "r"
$shape->getPlotArea()->getAxisX()->setLabelAlign("ctr");

// Set X-axis orientation: "minMax", "maxMin"
$shape->getPlotArea()->getAxisX()->setOrientation("maxMin");

// Set X-axis Line: "noFill", "solidFill"
$shape->getPlotArea()->getAxisX()->setValAxisLine("noFill");

// Set Y-axis Major Grid Lines: "solidFill", "noFill"
$shape->getPlotArea()->getAxisY()->setMajorGridlines("noFill");

// Set Y-axis Major Grid Lines Color
$shape->getPlotArea()->getAxisY()->setMajorGridlinesColor("FC0000");

// Toggle Legend Shadow
$shape->getLegend()->setShadow(1);

Aug 9, 2011 at 9:21 AM

Hi SuperDelic,

Where can I find this patch ?

I just need to disable the grid

May 10, 2012 at 8:37 PM

Has there been any update on this SuperDelic?

May 10, 2012 at 9:13 PM

This is definitely a work-in-progress, and it doesn't seem to end.

I just don't have the capacity to silo myself and work on this exclusively, between family life, working long hours, maintaining several websites, and developing apps; I can only work on it when my superiors need functionality that doesn't yet exist in PHPPowerPoint.

The last time I've been able to really work on this code was in December, when I needed to add code to determine whether a chart is Single-series or Multi-series. I work in Market Research, where they likely use every piece of functionality that PowerPoint has, and my goal is to provide all that functionality programmatically using PHPPowerPoint. Every once in a while I'll peruse the Office Open XML book and work on a small piece of functionality.

All work I've done thus far is specific to Charting; I haven't even gotten to Diagrams or any other Drawing ML. Plus, my PHP level is Intermediate at best, and I try to only write code that's in the same style/efficiency as Maarten & Co. have provided all these years to make it easier for any other contributors.

Sorry this is taking so long.

May 10, 2012 at 9:59 PM
Thanks for the response. Is the code that you've put together in terms of stacked charts, etc. working? Any chance of sending it to me? It would really help out in a project I'm busy with...

clayton (at) timcke (dot) co (dot) za

Thanks.
Regards,
Clayton

From: "SuperDelic" <notifications@codeplex.com>
Date: 10 May 2012 13:13:09 -0700
To: <clayton@timcke.co.za>
ReplyTo: phppowerpoint@discussions.codeplex.com
Subject: Re: Updated Charting Functionality [phppowerpoint:262690]

From: SuperDelic

This is definitely a work-in-progress, and it doesn't seem to end.

I just don't have the capacity to silo myself and work on this exclusively, between family life, working long hours, maintaining several websites, and developing apps; I can only work on it when my superiors need functionality that doesn't yet exist in PHPPowerPoint.

The last time I've been able to really work on this code was in December, when I needed to add code to determine whether a chart is Single-series or Multi-series. I work in Market Research, where they likely use every piece of functionality that PowerPoint has, and my goal is to provide all that functionality programmatically using PHPPowerPoint. Every once in a while I'll peruse the Office Open XML book and work on a small piece of functionality.

All work I've done thus far is specific to Charting; I haven't even gotten to Diagrams or any other Drawing ML. Plus, my PHP level is Intermediate at best, and I try to only write code that's in the same style/efficiency as Maarten & Co. have provided all these years to make it easier for any other contributors.

Sorry this is taking so long.

May 27, 2013 at 5:27 AM
SuperDelic,

I'm interested in your stacked chart addition - did you manage to complete this? Do you have any source that we can use to apply to our own versions?

Thanks,
Kaiesh