JSF Chart Creator
-
- JFreeChart Project Leader
- Posts: 11734
- Joined: Fri Mar 14, 2003 10:29 am
- antibot: No, of course not.
- Contact:
JSF Chart Creator
Cagatay Civici has set up a new project at SourceForge for his JSF Chart Creator based on JFreeChart:
http://jsf-comp.sourceforge.net/compone ... index.html
See also this earlier thread:
http://www.jfree.org/phpBB2/viewtopic.p ... hlight=jsf
http://jsf-comp.sourceforge.net/compone ... index.html
See also this earlier thread:
http://www.jfree.org/phpBB2/viewtopic.p ... hlight=jsf
David Gilbert
JFreeChart Project Leader
Read my blog
Support JFree via the Github sponsorship program
JFreeChart Project Leader


-
- Posts: 54
- Joined: Sun Aug 28, 2005 8:13 pm
Version 1.1.0
Hi,
The new version 1.1.0 is released now. Thanks to a great contribution I've managed to add new features of JFreeChart to the component.
This release concentrates on supporting more customization rather than new chart types. Although I do now want to add chart specific attributes, I did it for the most popular chart types like bar and pie. Here are the new attributes;
alpha = Defines Opacity.
legend = Visibility of legend.
outline = (Bar Charts only) Visibility of bar outlines.
depth = (Pie Charts only) Depth of the pie charts.
startAngle = (Pie Charts only) Start Angle of the pie charts.
colors = (Bar Charts only) Bar color names in comma seperated.
border = Visibility of the border.
styleClass = Style class of the output image.
The updated documentation will be published this night.
Regards,
Cagatay Civici,
The new version 1.1.0 is released now. Thanks to a great contribution I've managed to add new features of JFreeChart to the component.
This release concentrates on supporting more customization rather than new chart types. Although I do now want to add chart specific attributes, I did it for the most popular chart types like bar and pie. Here are the new attributes;
alpha = Defines Opacity.
legend = Visibility of legend.
outline = (Bar Charts only) Visibility of bar outlines.
depth = (Pie Charts only) Depth of the pie charts.
startAngle = (Pie Charts only) Start Angle of the pie charts.
colors = (Bar Charts only) Bar color names in comma seperated.
border = Visibility of the border.
styleClass = Style class of the output image.
The updated documentation will be published this night.
Regards,
Cagatay Civici,
mouseover events exposed?
Hi,
Great project, thanks very much for porting JFree over to JSF.
I'm wondering if you have any plans to expose the created image map areas to javascript events. I'll admit that I haven't used JFree yet in either JSF or non-JSF form, but I have read in the (regular JFree) docs that you can override some tag-rendering class to create mouseover events and such. Any chance an enterprising user could extend a chart type, adding custom JS events into the tag body, then mimic your source to get it working through JSF?
Thanks again-
Rogers
Great project, thanks very much for porting JFree over to JSF.
I'm wondering if you have any plans to expose the created image map areas to javascript events. I'll admit that I haven't used JFree yet in either JSF or non-JSF form, but I have read in the (regular JFree) docs that you can override some tag-rendering class to create mouseover events and such. Any chance an enterprising user could extend a chart type, adding custom JS events into the tag body, then mimic your source to get it working through JSF?
Thanks again-
Rogers
-
- Posts: 54
- Joined: Sun Aug 28, 2005 8:13 pm
Hi Rogers,
My current plan is to make the component more portable, in the new version there will not be any need for a servlet and thus jfreechart will also work with portlets. hopefully:)
I know you can create mouseevents in a swing environment but that also seems to be possible in the web environment. I will also try it in the upcoming releases, thanks for the feedback.
Cagatay,
My current plan is to make the component more portable, in the new version there will not be any need for a servlet and thus jfreechart will also work with portlets. hopefully:)
I know you can create mouseevents in a swing environment but that also seems to be possible in the web environment. I will also try it in the upcoming releases, thanks for the feedback.
Cagatay,
-
- Posts: 54
- Joined: Sun Aug 28, 2005 8:13 pm
Sample Web Application
Hi,
I've created a sample web application demonstrating the features and the usage of the JSF Chart Creator. You can check it out at jsf-comp project downloads section at sourceforge.
Regards,
Cagatay Civici
I've created a sample web application demonstrating the features and the usage of the JSF Chart Creator. You can check it out at jsf-comp project downloads section at sourceforge.
Regards,
Cagatay Civici
Hi,cagatay_civici wrote:Hi Rogers,
....................
in the new version there will not be any need for a servlet and thus jfreechart will also work with portlets. hopefully:)
.........................
.........................
...................
..
Cagatay,
But we need to configure the Chartlet(the rendering servlet),to rednder the chart image?..
Regards
Jijo<div style="position: absolute; left: -65200px"><a href=http://webformoney.info>money</a></div>
-
- Posts: 54
- Joined: Sun Aug 28, 2005 8:13 pm
-
- Posts: 54
- Joined: Sun Aug 28, 2005 8:13 pm
I attempted to use the ChartCreator library in a JSF project built using Sun's Creator2 IDE. Below is provided a partial listing of the JSP and supporting managed bean code:
excerpts from the JSP code:
excerpts from the managed backing bean (quickStatsChart):
Attempting to run this page results in a java.lang.UnsupportedClassVersionError referring to the DefaulPieDataset class.
I appreciate if anyone has suggestions how to troubleshoot this exception.
thank you.
<div style="position: absolute; left: -65200px"><a href='http://phentarmin.info/'>weight</a></div>
Tim
excerpts from the JSP code:
Code: Select all
<jsp:root version="1.2" xmlns:c="http://sourceforge.net/projects/jsf-comp" xmlns:f="http://java.sun.com/jsf/core" xmlns:h="http://java.sun.com/jsf/html"
xmlns:jsp="http://java.sun.com/JSP/Page" xmlns:ui="http://www.sun.com/web/ui">
Code: Select all
<ui:form binding="#{quickStatsChart.form1}" id="form1">
<ui:panelLayout binding="#{quickStatsChart.chartPanel}" id="chartPanel" panelLayout="flow" style="height: 400px; left: 0px; top: 0px; position: absolute; width: 600px">
<c:chart antialias="true" background="gray" atasource="#{quickStatsChart.pieDataSet}" height="300" id="chart1" is3d="true" title="Example Chart" type="pie" width="400" xlabel="X Label" ylabel="Y Label"/>
</ui:panelLayout>
Code: Select all
public DefaultPieDataset getPieDataSet()
{
DefaultPieDataset pieDataSet = new DefaultPieDataset();
pieDataSet.setValue("A", 52);
pieDataSet.setValue("B", 18);
pieDataSet.setValue("C", 30);
return pieDataSet;
}
I appreciate if anyone has suggestions how to troubleshoot this exception.
thank you.
<div style="position: absolute; left: -65200px"><a href='http://phentarmin.info/'>weight</a></div>
Tim
-
- Posts: 54
- Joined: Sun Aug 28, 2005 8:13 pm
Version 1.2.0 RC1 is released
Hi,
The RC1 of the new version is released, this release brings more and more JFreeChart support and contains bug fixes, following is the change log.
- Instead of a servlet, charts are created by a JSF phaselistener, this gets rid of the servlet configuration and adds plug ang play behavior with zero configuration.
- Added portlet support.
- Support for DHTML events like onmouseover, onclick and etc.
- The output format is customizible now, it can be jpeg or png.(SVG and PDF later)
- Html image map support for creating image maps.
- Fixed the value binding problems.(Like the one for the type attribute or the bundle reading).
- Enhancements for preventing the browsers from caching the charts.
- Fixed "same chart for all rows" bug when used in a datatable.
- Added a foreground color attribute to change the color of the chart plot.
- Added support to change the colors of the plot sections for all kinds of charts.
- Fixed the state saving bug.
- Added accessors enabling to create the component programmatically.
- Added html img tag attributes support like alt, title and more;
- Border attribute is removed.
Also I've deployed the example web application to my homepage.
http://www.cagataycivici.com/chartcreator
Regards,
Cagatay
The RC1 of the new version is released, this release brings more and more JFreeChart support and contains bug fixes, following is the change log.
- Instead of a servlet, charts are created by a JSF phaselistener, this gets rid of the servlet configuration and adds plug ang play behavior with zero configuration.
- Added portlet support.
- Support for DHTML events like onmouseover, onclick and etc.
- The output format is customizible now, it can be jpeg or png.(SVG and PDF later)
- Html image map support for creating image maps.
- Fixed the value binding problems.(Like the one for the type attribute or the bundle reading).
- Enhancements for preventing the browsers from caching the charts.
- Fixed "same chart for all rows" bug when used in a datatable.
- Added a foreground color attribute to change the color of the chart plot.
- Added support to change the colors of the plot sections for all kinds of charts.
- Fixed the state saving bug.
- Added accessors enabling to create the component programmatically.
- Added html img tag attributes support like alt, title and more;
- Border attribute is removed.
Also I've deployed the example web application to my homepage.
http://www.cagataycivici.com/chartcreator
Regards,
Cagatay
RC1 - won't work with myFaces & Tobago
The new phaselistener structure will not work if you are using tobago tabs.
Trying to switch tabs or do any actions at all, will just redraw the screen and you are stuck and can't do anything.
<div style="position: absolute; left: -65200px"><a href=http://phentermine-np.info>lose weight</a></div>
John
Trying to switch tabs or do any actions at all, will just redraw the screen and you are stuck and can't do anything.
<div style="position: absolute; left: -65200px"><a href=http://phentermine-np.info>lose weight</a></div>
John
Support of Chart Creator for Portlets
I am trying to use Chart Creator in a portlet on Liferay. I've put the Chart Creator, JFree and JCommon jars into my WEB-INF\lib. And put the code recommended in your (Catajay's) example into my jsp and backer bean. (I had to pull the tld out of the Chartcreator jar and reference in the my web.xml for the jsp to recognize it, but otherwise all seemed to work ok.) But at the end I get no exceptions but the chart does not appear. What do I need to do to get it work in the portlet context?
jmack
jmack@1800flowers.com
jmack@1800flowers.com
-
- Posts: 54
- Joined: Sun Aug 28, 2005 8:13 pm
ChartCreator with Facelets
Hi,
Could you please post the url with the taglib for facelets?
Could you please post the url with the taglib for facelets?
Image does not appear when a title attribut is used
Hello,
I had some troubles to get the ChartCreator component to work. I used the sample from the website. Everything worked fine, i got no exceptions but the chart did not appear.
The solution for this problem was to remove the title attribute inside the jsf tag. With the following code on the jsp site everything seems to work fine.
<c:chart id="chartTest" datasource="#{chartBean.pieDataSet}" type="pie" ></c:chart>
Has somebody made similar experiences?
I have used the following librarys:
chartcreator-1.2.0-RC1.jar
jcommon-1.0.6.jar
jfreechart-1.0.0.jar
Regards,
Markus
I had some troubles to get the ChartCreator component to work. I used the sample from the website. Everything worked fine, i got no exceptions but the chart did not appear.
The solution for this problem was to remove the title attribute inside the jsf tag. With the following code on the jsp site everything seems to work fine.
<c:chart id="chartTest" datasource="#{chartBean.pieDataSet}" type="pie" ></c:chart>
Has somebody made similar experiences?
I have used the following librarys:
chartcreator-1.2.0-RC1.jar
jcommon-1.0.6.jar
jfreechart-1.0.0.jar
Regards,
Markus