[ 
https://issues.jboss.org/browse/JBSEAM-2275?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=12579863#comment-12579863
 ] 

Jess Sightler commented on JBSEAM-2275:
---------------------------------------

The example for p:linegraph is still missing the 'key' attribute on the p:data 
elements... it still doesn't work when directly copied, resulting in the above 
exception.

> Document on Seam iText charting
> -------------------------------
>
>                 Key: JBSEAM-2275
>                 URL: https://issues.jboss.org/browse/JBSEAM-2275
>             Project: Seam
>          Issue Type: Patch
>    Affects Versions: 2.0.0.GA
>         Environment: JBoss 4.2.1.GA
>            Reporter: Joshua Partogi
>            Assignee: Norman Richards
>             Fix For: 2.0.1.CR1
>
>
> Point 16.2
> 1. Write in doc to use the charting support, we need to add the 
> jfreechart.jar and jcommon-*.jar in the project classpath. We can also add 
> this is our build.xml
> 2. The key attribute is needed upon p:data component usage otherwise it will 
> throw
> this exception java.lang.IllegalArgumentException: Null 'key' argument.
>       at 
> org.jfree.data.DefaultKeyedValues.setValue(DefaultKeyedValues.java:239)
>       at 
> org.jfree.data.DefaultKeyedValues2D.setValue(DefaultKeyedValues2D.java:337)
>       at 
> org.jfree.data.DefaultKeyedValues2D.addValue(DefaultKeyedValues2D.java:303). 
>       
> In examples, it is used in (the ones below are the fixed value):
> Barchart, Linechart, Series
>       
> PieChart
> 1. Attributes:
> title ? The chart title text.
> legend ? A boolean value indicating whether or not the chart should include a 
> legend. Default value is true
> is3D - A boolean value indicating that the chart should be rendered in 3D 
> instead of 2D.
> labelLinkMargin - The link margin
> labelLinkPaint - The paint used for the label linking lines.
> labelLinkStroke - The stroke used for the label linking lines.
> labelLinksVisible - A flag that controls whether or not the label links are 
> drawn.
> labelOutlinePaint - The paint used to draw the outline of the section labels 
> labelOutlineStroke - The stroke used to draw the outline of the section 
> labels 
> labelShadowPaint - The paint used to draw the shadow for the section labels 
> labelPaint - The color used to draw the section labels
> labelGap - The gap between the labels and the plot as a percentage of the 
> plot width. 
> labelBackgroundPaint - The color used to draw the background of the section 
> labels.  If this is null, the background is not filled.
> startAngle - The starting angle
> circular - A boolean value indicating whether whether to draw an ellipse or a 
> perfect circle.
> direction - The direction for the pie segments. If value is not set 
> "anticlockwise" then by default it is clockwise.
> sectionOutlinePaint - The outline paint for ALL sections (overrides list). 
> sectionOutlineStroke - The outline stroke for ALL sections (overrides list). 
> sectionOutlinesVisible - A flag that controls whether or not an outline is 
> drawn for each section in the plot.
> baseSectionOutlinePaint - The base section outline paint
> baseSectionPaint - The base section paint 
> baseSectionOutlineStroke - The base section outline stroke
> 2. Usage:
> <p:document xmlns:p="http://jboss.com/products/seam/pdf";>     
>       <p:piechart title="Pie Chart" circular="false" direction="anticlockwise"
>               startAngle="30" labelGap="0.1" labelLinkPaint="red">    
>               <p:series key="Prices">
>                       <p:data key="2003" columnKey="2003" value="7.36" />
>                       <p:data key="2004" columnKey="2004" value="11.50" />
>                       <p:data key="2005" columnKey="2005" value="34.625" />
>                       <p:data key="2006" columnKey="2006" value="76.30" />
>                       <p:data key="2007" columnKey="2007" value="85.05" />
>               </p:series>
>       </p:piechart>   
> </p:document>

-- 
This message is automatically generated by JIRA.
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        
_______________________________________________
seam-issues mailing list
[email protected]
https://lists.jboss.org/mailman/listinfo/seam-issues

Reply via email to