You can subscribe to this list here.
2003 |
Jan
|
Feb
|
Mar
|
Apr
|
May
|
Jun
|
Jul
|
Aug
(95) |
Sep
(42) |
Oct
(2) |
Nov
(7) |
Dec
(6) |
---|---|---|---|---|---|---|---|---|---|---|---|---|
2004 |
Jan
|
Feb
(34) |
Mar
|
Apr
|
May
(64) |
Jun
(113) |
Jul
(60) |
Aug
(9) |
Sep
(6) |
Oct
(20) |
Nov
(11) |
Dec
|
From: <nat...@us...> - 2003-11-02 13:34:21
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/java/org/krysalis/jcharts/axisChart In directory sc8-pr-cvs1:/tmp/cvs-serv1722 Modified Files: ScatterPlotChart.java Log Message: image map bug fix from 0.7.5 Index: ScatterPlotChart.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/java/org/krysalis/jcharts/axisChart/ScatterPlotChart.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** ScatterPlotChart.java 17 May 2003 16:56:57 -0000 1.1 --- ScatterPlotChart.java 2 Nov 2003 13:34:17 -0000 1.2 *************** *** 88,92 **** if( scatterPlotAxisChart.getGenerateImageMapFlag() ) { ! scatterPlotAxisChart.getImageMap().addImageMapArea( new CircleMapArea( yAxisCoordinates[ dataSet ][ index ], yAxisCoordinates[ dataSet ][ index ], iScatterPlotDataSet.getValue( dataSet, index ), --- 88,92 ---- if( scatterPlotAxisChart.getGenerateImageMapFlag() ) { ! scatterPlotAxisChart.getImageMap().addImageMapArea( new CircleMapArea( xAxisCoordinates[ dataSet ][ index ], yAxisCoordinates[ dataSet ][ index ], iScatterPlotDataSet.getValue( dataSet, index ), |
From: <nat...@us...> - 2003-11-02 13:24:37
|
Update of /cvsroot/jcharts/jCharts/jCharts0.7/docs In directory sc8-pr-cvs1:/tmp/cvs-serv32678 Modified Files: README.html Log Message: fixed image map bug Index: README.html =================================================================== RCS file: /cvsroot/jcharts/jCharts/jCharts0.7/docs/README.html,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** README.html 15 Oct 2003 03:24:38 -0000 1.20 --- README.html 2 Nov 2003 13:24:34 -0000 1.21 *************** *** 97,100 **** --- 97,105 ---- </td> </tr> + <tr> + <td valign="top"> + * Fixed defect in ScatterPlot image map coordinate generation. + </td> + </tr> </table> <br/> |
From: <nat...@us...> - 2003-11-02 13:23:14
|
Update of /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/axisChart In directory sc8-pr-cvs1:/tmp/cvs-serv32514 Modified Files: ScatterPlotChart.java Log Message: fixed image map bug Index: ScatterPlotChart.java =================================================================== RCS file: /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/axisChart/ScatterPlotChart.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** ScatterPlotChart.java 19 Feb 2003 23:25:37 -0000 1.2 --- ScatterPlotChart.java 2 Nov 2003 13:23:11 -0000 1.3 *************** *** 88,92 **** if( scatterPlotAxisChart.getGenerateImageMapFlag() ) { ! scatterPlotAxisChart.getImageMap().addImageMapArea( new CircleMapArea( yAxisCoordinates[ dataSet ][ index ], yAxisCoordinates[ dataSet ][ index ], iScatterPlotDataSet.getValue( dataSet, index ), --- 88,92 ---- if( scatterPlotAxisChart.getGenerateImageMapFlag() ) { ! scatterPlotAxisChart.getImageMap().addImageMapArea( new CircleMapArea( xAxisCoordinates[ dataSet ][ index ], yAxisCoordinates[ dataSet ][ index ], iScatterPlotDataSet.getValue( dataSet, index ), |
Update of /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/test In directory sc8-pr-cvs1:/tmp/cvs-serv32423 Modified Files: BarTestDriver.java ChartTestDriver.java ScatterPlotTestDriver.java StackedBarTestDriver.java Log Message: testing Index: BarTestDriver.java =================================================================== RCS file: /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/test/BarTestDriver.java,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** BarTestDriver.java 31 Mar 2003 00:26:42 -0000 1.19 --- BarTestDriver.java 2 Nov 2003 13:22:31 -0000 1.20 *************** *** 59,62 **** --- 59,66 ---- import java.awt.*; + import java.util.Locale; + import java.util.Collection; + import java.util.Iterator; + import java.text.MessageFormat; *************** *** 136,145 **** ! double[][] data = {{280, 16, -150, 160, 90, 60, 150, 11, -23, 50, 89 }}; Paint[] paints = {Color.green}; String[] legendLabels = {"Test Legend Label"}; AxisChartDataSet axisChartDataSet = new AxisChartDataSet( data, legendLabels, paints, ChartType.BAR, barChartProperties ); ! String[] axisLabels = {"1900", "195555510", "1920", "1935555555555550", "1940", "19555555550", "5555551960", "19755555550", "19855550", "19905555", "20005555" }; //String[] axisLabels = {"1900", "1910", "1920", "1930", "1940", "1950", "1960", "1970", "1980", "1990", "2000" }; IAxisDataSeries dataSeries = new DataSeries( axisLabels, "Wonka Bars", "Years", "Oompa Loompa Productivity" ); --- 140,150 ---- ! /* ! double[][] data = {{280, 16, -150, 160, 90, 60, 150, 11, -23, 50, 89}}; Paint[] paints = {Color.green}; String[] legendLabels = {"Test Legend Label"}; AxisChartDataSet axisChartDataSet = new AxisChartDataSet( data, legendLabels, paints, ChartType.BAR, barChartProperties ); ! String[] axisLabels = {"1900", "195555510", "1920", "1935555555555550", "1940", "19555555550", "5555551960", "19755555550", "19855550", "19905555", "20005555"}; //String[] axisLabels = {"1900", "1910", "1920", "1930", "1940", "1950", "1960", "1970", "1980", "1990", "2000" }; IAxisDataSeries dataSeries = new DataSeries( axisLabels, "Wonka Bars", "Years", "Oompa Loompa Productivity" ); *************** *** 150,155 **** AxisProperties axisProperties = new AxisProperties( true ); ! axisProperties.getYAxisProperties().setShowGridLines( AxisTypeProperties.GRID_LINES_NONE ); ! axisProperties.getYAxisProperties().setAxisStroke( new ChartStroke( new BasicStroke( 1.5f ), Color.red ) ); //axisProperties.setXAxisLabelsAreVertical( true ); --- 155,160 ---- AxisProperties axisProperties = new AxisProperties( true ); ! axisProperties.getYAxisProperties().setShowGridLines( AxisTypeProperties.GRID_LINES_ALL ); ! axisProperties.getYAxisProperties().setGridLineChartStroke( new ChartStroke( new BasicStroke( 1.5f ), Color.red ) ); //axisProperties.setXAxisLabelsAreVertical( true ); *************** *** 164,170 **** --- 169,281 ---- ChartTestDriver.exportImage( axisChart, "BarChartTest.png" ); + */ + + bug2(); + } + + + public static void bug() throws ChartDataException, PropertyException + { + String[] xAxisLabels = {"I", "II", "III", "IV", "V", "VI", "VII", "VIII", "IX", "X", "XI", "XII"}; + //out = response.getOutputStream(); + + //java.util.ResourceBundle txts = java.util.ResourceBundle.getBundle( "charts", new Locale( language ) ); + + //String year = getParameter( request, "Year" ); + //if( year == null ) year = "2002"; + + //Collection v = user.getNumbersByYear( kid, new Long( year ) ); + //Iterator it = v.iterator(); + + double[][] data = new double[1][12]; + for( int i = 0; i < 12; i++ ) + { + double d = 51; + data[0][i] = d; + } + String xAxisTitle = "CHART1_XAXIS"; + String yAxisTitle = "CHART1_YAXIS"; + + //Object[] arg = {year}; + String title = "CHART1_TITLE hhhhhhhhhhhhhhhhhhhhh hhhhhhhhh hhhhhhhhhhh hhhhhhhhhhh hhhhhhhh hhhhhhhh hhhh hhhhh hhhh hhhh hhhh hhhhh hhhhhhhh"; + + DataSeries dataSeries = new DataSeries( xAxisLabels, xAxisTitle, yAxisTitle, title ); + String[] legendLabels = {"CHART1_LEGEND"}; + + Paint[] paints = {new GradientPaint( 0, 0, new Color( 255, 213, 83, 150 ), 0, 350, new Color( 243, 116, 0, 200 ) ) + }; + BarChartProperties barChartProperties = new BarChartProperties(); + + ValueLabelRenderer valueLabelRenderer = new ValueLabelRenderer( false, false, false, -1 ); + valueLabelRenderer.setValueLabelPosition( ValueLabelPosition.ON_TOP ); + valueLabelRenderer.useVerticalLabels( false ); + barChartProperties.addPostRenderEventListener( valueLabelRenderer ); + + AxisChartDataSet axisChartDataSet = new AxisChartDataSet( data, legendLabels, paints, ChartType.BAR, barChartProperties ); + dataSeries.addIAxisPlotDataSet( axisChartDataSet ); + ChartProperties chartProperties = new ChartProperties(); + + LabelAxisProperties xAxisProperties = new LabelAxisProperties(); + //xAxisProperties.setAxisTitleChartFont( ft_axis ); + //xAxisProperties.setScaleChartFont( ft_labels ); + + DataAxisProperties yAxisProperties = new DataAxisProperties(); + //yAxisProperties.setAxisTitleChartFont( ft_axis ); + //yAxisProperties.setScaleChartFont( ft_labels ); + yAxisProperties.setRoundToNearest( 0 ); + + AxisProperties axisProperties = new AxisProperties( xAxisProperties, yAxisProperties ); + LegendProperties legendProperties = new LegendProperties(); + + //chartProperties.setTitleFont( ft_title ); + //legendProperties.setFont( ft_base_ ); + + axisProperties.setBackgroundPaint( new GradientPaint( 0, 0, new Color( 255, 255, 255 ), 0, 300, new + Color( 167, 213, 255 ) ) ); + AxisChart axisChart = new AxisChart( + dataSeries, + chartProperties, + axisProperties, + null, //legendProperties, + 548, 350 ); // wymiary wykresu + + ChartTestDriver.exportImage( axisChart, "Bug_BarChartTest.png" ); } + + private static void bug2() + { + BarChartProperties barChartProperties = null; + LegendProperties legendProperties = null; + AxisProperties axisProperties = null; + ChartProperties chartProperties =null;// = new ChartProperties(); + int width = 550; + int height = 360; + + try + { + String[] xAxisLabels = {"1995", "1996", "1997", "1998", "1999", "2000","2001", "2002", "2003", "2004"}; + String xAxisTitle = "Years"; + String yAxisTitle = "Problems"; + String title = "Micro$oft At Work"; + IAxisDataSeries dataSeries = new DataSeries( xAxisLabels, xAxisTitle,yAxisTitle, title ); + + double[][] data = new double[][]{{1500, 6880, 4510, 2600, 1200, 1580,8000, 4555, 4000, 6120}}; + String[] legendLabels = {"Bugs"}; + Paint[] paints = new Paint[]{Color.blue.darker()}; + dataSeries.addIAxisPlotDataSet( new AxisChartDataSet( data,legendLabels, paints, ChartType.BAR, barChartProperties ) ); + AxisChart axisChart = new AxisChart( dataSeries, chartProperties, axisProperties, legendProperties, width, height ); + + ChartTestDriver.exportImage( axisChart, "Bug222_BarChartTest.png" ); + } + catch( ChartDataException chartDataException ) + { + chartDataException.printStackTrace(); + } + catch( PropertyException propertyException ) { + propertyException.printStackTrace(); + } + } } Index: ChartTestDriver.java =================================================================== RCS file: /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/test/ChartTestDriver.java,v retrieving revision 1.20 retrieving revision 1.21 diff -C2 -d -r1.20 -r1.21 *** ChartTestDriver.java 19 Apr 2003 16:30:55 -0000 1.20 --- ChartTestDriver.java 2 Nov 2003 13:22:31 -0000 1.21 *************** *** 76,79 **** --- 76,80 ---- + /* AxisChartTestBase.axisChartTest( "stockChart", new StockTestDriver() ); *************** *** 93,99 **** AxisChartTestBase.axisChartTest( "lineChart", new LineTestDriver() ); ! AxisChartTestBase.axisChartTest( "scatterChart", new ScatterPlotTestDriver() ); //ChartTestDriver.testAxisScale(); --- 94,101 ---- AxisChartTestBase.axisChartTest( "lineChart", new LineTestDriver() ); + */ ! ScatterChartTestBase.axisChartTest( "scatterChart", new ScatterPlotTestDriver() ); //ChartTestDriver.testAxisScale(); Index: ScatterPlotTestDriver.java =================================================================== RCS file: /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/test/ScatterPlotTestDriver.java,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** ScatterPlotTestDriver.java 31 Mar 2003 00:26:42 -0000 1.5 --- ScatterPlotTestDriver.java 2 Nov 2003 13:22:31 -0000 1.6 *************** *** 56,60 **** * *******************************************************************************************/ ! class ScatterPlotTestDriver extends AxisChartTestBase { boolean supportsImageMap() --- 56,60 ---- * *******************************************************************************************/ ! public class ScatterPlotTestDriver extends ScatterChartTestBase { boolean supportsImageMap() *************** *** 111,116 **** ! Point2D.Double[] points= new Point2D.Double[ 20 ]; ! for( int x = 0; x < 20; x++ ) { //--- y = x^2 --- 111,116 ---- ! Point2D.Double[] points= new Point2D.Double[ numberOfValuesToCreate ]; ! for( int x = 0; x < numberOfValuesToCreate; x++ ) { //--- y = x^2 *************** *** 119,124 **** } ! String[] legendLabels = TestDataGenerator.getRandomStrings( 1, 12, false ); ! // Paint[] paints = TestDataGenerator.getRandomPaints( numberOfDataSets ); Paint paint = TestDataGenerator.getRandomPaint(); --- 119,124 ---- } ! String[] legendLabels = TestDataGenerator.getRandomStrings( numberOfDataSets, 12, false ); ! Paint[] paints = TestDataGenerator.getRandomPaints( numberOfDataSets ); Paint paint = TestDataGenerator.getRandomPaint(); *************** *** 126,130 **** scatterPlotDataSet.addDataPoints( points, paint, legendLabels[ 0 ] ); - System.out.println( "legendLabels[ 0 ]= " + legendLabels[ 0 ] ); return scatterPlotDataSet; } --- 126,129 ---- *************** *** 135,154 **** * ******************************************************************************************/ ! DataSeries getDataSeries() throws ChartDataException { ! DataSeries dataSeries= null; ! int dataSize = (int) TestDataGenerator.getRandomNumber( 3, 3 ); int numberOfDataSets = (int) TestDataGenerator.getRandomNumber( 1, 1 ); ! //ScatterPlotDataSet scatterPlotDataSet= this.createScatterPlotDataSet( ) ! //String[] xAxisLabels = TestDataGenerator.getRandomStrings( numberOfValuesToCreate, ( int ) TestDataGenerator.getRandomNumber( 10 ), false ); String xAxisTitle = TestDataGenerator.getRandomString( 15, true ); String yAxisTitle = TestDataGenerator.getRandomString( 15, true ); ! //dataSeries = new DataSeries( xAxisLabels, xAxisTitle, yAxisTitle, "This is a test title that is so freaking long is is going to wrap around the image for sure. lfksjg;ljs; dflgkjdfgsdgdg dsgdsgsdfg dsfgsdfgsdfgs dfgdsfgd" ); ! ! //dataSeries.addIAxisPlotDataSet( axisChartDataSet ); return dataSeries; --- 134,152 ---- * ******************************************************************************************/ ! ScatterPlotDataSeries getDataSeries() throws ChartDataException { ! ScatterPlotDataSeries dataSeries= null; ! int dataSize = (int) TestDataGenerator.getRandomNumber( 3, 10 ); int numberOfDataSets = (int) TestDataGenerator.getRandomNumber( 1, 1 ); ! ScatterPlotDataSet scatterPlotDataSet= this.createScatterPlotDataSet( numberOfDataSets, dataSize, 50, 50, 0, 0 ); ! String[] xAxisLabels = TestDataGenerator.getRandomStrings( dataSize, ( int ) TestDataGenerator.getRandomNumber( 10 ), false ); String xAxisTitle = TestDataGenerator.getRandomString( 15, true ); String yAxisTitle = TestDataGenerator.getRandomString( 15, true ); ! dataSeries = new ScatterPlotDataSeries( scatterPlotDataSet, xAxisTitle, yAxisTitle, "This is a test title that is so freaking long is is going to wrap around the image for sure. lfksjg;ljs; dflgkjdfgsdgdg dsgdsgsdfg dsfgsdfgsdfgs dfgdsfgd" ); ! dataSeries.addIAxisPlotDataSet( scatterPlotDataSet ); return dataSeries; *************** *** 218,222 **** 400 ); ! ChartTestDriver.exportImage( scatterPlotAxisChart, "ScatterPlotTest.svg" ); } --- 216,220 ---- 400 ); ! ChartTestDriver.exportImage( scatterPlotAxisChart, "ScatterPlotTest.png" ); } Index: StackedBarTestDriver.java =================================================================== RCS file: /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/test/StackedBarTestDriver.java,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** StackedBarTestDriver.java 31 Mar 2003 00:26:42 -0000 1.10 --- StackedBarTestDriver.java 2 Nov 2003 13:22:31 -0000 1.11 *************** *** 58,62 **** * *******************************************************************************************/ ! class StackedBarTestDriver extends AxisChartTestBase { boolean supportsImageMap() --- 58,62 ---- * *******************************************************************************************/ ! public class StackedBarTestDriver extends AxisChartTestBase { boolean supportsImageMap() *************** *** 127,132 **** AxisChartDataSet axisChartDataSet = new AxisChartDataSet( data, legendLabels, paints, ChartType.BAR_STACKED, stackedBarChartProperties ); ! String[] axisLabels = null; //{"1900", "1950", "2000", "2050", "3000", "3050", "4000", "4050" }; ! IAxisDataSeries dataSeries = new DataSeries( axisLabels, "Cookies", "Years", null ); dataSeries.addIAxisPlotDataSet( axisChartDataSet ); --- 127,132 ---- AxisChartDataSet axisChartDataSet = new AxisChartDataSet( data, legendLabels, paints, ChartType.BAR_STACKED, stackedBarChartProperties ); ! String[] axisLabels = {"1900", "1950", "2000", "2050", "3000", "3050", "4000", "4050" }; ! IAxisDataSeries dataSeries = new DataSeries( axisLabels, "Cookies", "Years", "Effort Over Time" ); dataSeries.addIAxisPlotDataSet( axisChartDataSet ); *************** *** 134,142 **** ChartProperties chartProperties = new ChartProperties(); AxisProperties axisProperties = new AxisProperties( false ); ! ! axisProperties.getXAxisProperties().setShowAxisLabels( false ); ! axisProperties.getYAxisProperties().setShowAxisLabels( false ); ! axisProperties.getYAxisProperties().setShowTicks( AxisTypeProperties.TICKS_NONE ); //axisProperties.getYAxisProperties().setShowGridLines( AxisTypeProperties.GRID_LINES_NONE ); --- 134,142 ---- ChartProperties chartProperties = new ChartProperties(); AxisProperties axisProperties = new AxisProperties( false ); + axisProperties.getXAxisProperties().getAxisTitleChartFont(); ! // axisProperties.getXAxisProperties().setShowAxisLabels( false ); ! // axisProperties.getYAxisProperties().setShowAxisLabels( false ); ! // axisProperties.getYAxisProperties().setShowTicks( AxisTypeProperties.TICKS_NONE ); //axisProperties.getYAxisProperties().setShowGridLines( AxisTypeProperties.GRID_LINES_NONE ); *************** *** 150,154 **** */ ! LegendProperties legendProperties = null; //new LegendProperties(); AxisChart axisChart = new AxisChart( dataSeries, chartProperties, axisProperties, legendProperties, 500, 400 ); --- 150,154 ---- */ ! LegendProperties legendProperties = new LegendProperties(); AxisChart axisChart = new AxisChart( dataSeries, chartProperties, axisProperties, legendProperties, 500, 400 ); |
From: <nat...@us...> - 2003-11-02 13:22:16
|
Update of /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/test In directory sc8-pr-cvs1:/tmp/cvs-serv32390 Added Files: ScatterChartTestBase.java Log Message: new --- NEW FILE: ScatterChartTestBase.java --- /*********************************************************************************************** * File Info: $Id: ScatterChartTestBase.java,v 1.1 2003/11/02 13:22:13 nathaniel_auvil Exp $ * Copyright (C) 2000 * Author: Nathaniel G. Auvil * Contributor(s): * * Copyright 2002 (C) Nathaniel G. Auvil. All Rights Reserved. * * Redistribution and use of this software and associated documentation ("Software"), with or * without modification, are permitted provided that the following conditions are met: * * 1. Redistributions of source code must retain copyright statements and notices. * Redistributions must also contain a copy of this document. * * 2. Redistributions in binary form must reproduce the above copyright notice, this list of * conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. * * 3. The name "jCharts" or "Nathaniel G. Auvil" must not be used to endorse or promote * products derived from this Software without prior written permission of Nathaniel G. * Auvil. For written permission, please contact nat...@us... * * 4. Products derived from this Software may not be called "jCharts" nor may "jCharts" appear * in their names without prior written permission of Nathaniel G. Auvil. jCharts is a * registered trademark of Nathaniel G. Auvil. * * 5. Due credit should be given to the jCharts Project (http://jcharts.sourceforge.net/). * * THIS SOFTWARE IS PROVIDED BY Nathaniel G. Auvil AND CONTRIBUTORS ``AS IS'' AND ANY * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL * jCharts OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE ************************************************************************************************/ package org.jCharts.test; import org.jCharts.axisChart.AxisChart; import org.jCharts.axisChart.ScatterPlotAxisChart; import org.jCharts.chartData.*; import org.jCharts.properties.*; import org.jCharts.types.ChartType; import org.jCharts.imageMap.ImageMap; import java.awt.*; /****************************************************************************************** * * *******************************************************************************************/ abstract class ScatterChartTestBase { public ScatterChartTestBase() { System.out.println( "Running: " + this.getClass().getName() ); } abstract ScatterPlotDataSeries getDataSeries() throws ChartDataException; abstract boolean supportsImageMap(); /****************************************************************************************** * Test for LineChart * ******************************************************************************************/ static void axisChartTest( String name, ScatterChartTestBase axisChartTestBase ) throws ChartDataException, PropertyException { LegendProperties legendProperties; ChartProperties chartProperties; AxisProperties axisProperties; AxisChart axisChart; int numTestsToRun = 10; String fileName; HTMLGenerator htmlGenerator = new HTMLGenerator( ChartTestDriver.OUTPUT_PATH + name + "Test.html" ); for( int i = 0; i < numTestsToRun; i++ ) { ScatterPlotDataSeries dataSeries = axisChartTestBase.getDataSeries(); boolean horizontalPlot = false; //( TestDataGenerator.getRandomNumber( 1 ) > 0.5d ); boolean createImageMap = true;// ( TestDataGenerator.getRandomNumber( 1 ) > 0.5d ); axisProperties = new AxisProperties( new DataAxisProperties(), new DataAxisProperties() ); axisProperties.setXAxisLabelsAreVertical( ( TestDataGenerator.getRandomNumber( 1 ) > 0.5d ) ); TestDataGenerator.randomizeAxisProperties( axisProperties ); //axisProperties.setYAxisNumItems( 6 ); DataAxisProperties dataAxisProperties; if( horizontalPlot ) { dataAxisProperties = (DataAxisProperties) axisProperties.getXAxisProperties(); } else { dataAxisProperties = (DataAxisProperties) axisProperties.getYAxisProperties(); } dataAxisProperties.setRoundToNearest( 1 ); dataAxisProperties.setShowAxisLabels( ( TestDataGenerator.getRandomNumber( 1 ) > 0.5d ) ); int width = (int) TestDataGenerator.getRandomNumber( 500, 1000 ); int height = (int) TestDataGenerator.getRandomNumber( 300, 800 ); legendProperties = new LegendProperties(); //TestDataGenerator.randomizeLegend( legendProperties ); //legendProperties.setPlacement( LegendAreaProperties.RIGHT ); chartProperties = new ChartProperties(); //chartProperties.setBorderStroke( new BasicStroke( 1f ) ); axisChart = new ScatterPlotAxisChart( dataSeries, chartProperties, axisProperties, legendProperties, width, height ); fileName = ChartTestDriver.OUTPUT_PATH + name + i + ChartTestDriver.EXTENSION; ImageMap imageMap; if( createImageMap && axisChartTestBase.supportsImageMap() ) { axisChart.renderWithImageMap(); imageMap = axisChart.getImageMap(); } else { imageMap = null; } try { ChartTestDriver.exportImage( axisChart, fileName ); } catch( NullPointerException nullPointerException ) { nullPointerException.printStackTrace(); System.out.println(); } axisChart.toHTML( htmlGenerator, fileName, imageMap ); htmlGenerator.addLineBreak(); } htmlGenerator.saveFile(); } /***************************************************************************************************** * * *****************************************************************************************************/ final DataSeries createDataSeries( int numberOfValuesToCreate ) { String[] xAxisLabels = null; if( ( TestDataGenerator.getRandomNumber( 1 ) > 0.5d ) ) { xAxisLabels = TestDataGenerator.getRandomStrings( numberOfValuesToCreate, (int) TestDataGenerator.getRandomNumber( 10 ), false ); } String xAxisTitle = TestDataGenerator.getRandomString( 15, true ); String yAxisTitle = TestDataGenerator.getRandomString( 15, true ); return new DataSeries( xAxisLabels, xAxisTitle, yAxisTitle, "This is a test title that is so freaking long is is going to wrap around the image for sure. lfksjg;ljs; dflgkjdfgsdgdg dsgdsgsdfg dsfgsdfgsdfgs dfgdsfgd" ); } /***************************************************************************************** * Generates a random MultiDataSet * * @param numberOfDataSets * @param numberOfValuesToCreate the number of doubles to generate * @param minValue * @param maxValue * @return AxisChartDataSet ******************************************************************************************/ AxisChartDataSet createAxisChartDataSet( ChartType chartType, ChartTypeProperties chartTypeProperties, int numberOfDataSets, int numberOfValuesToCreate, int minValue, int maxValue ) throws ChartDataException { double[][] data = TestDataGenerator.getRandomNumbers( numberOfDataSets, numberOfValuesToCreate, minValue, maxValue ); String[] legendLabels = TestDataGenerator.getRandomStrings( numberOfDataSets, 10, false ); Paint[] paints = TestDataGenerator.getRandomPaints( numberOfDataSets ); /* //data[ 0 ][ 0 ]= Double.NaN; data[ 0 ][ 1 ]= Double.NaN; data[ 0 ][ 4 ]= Double.NaN; data[ 0 ][ 6 ]= Double.NaN; //data[ 0 ][ data[ 0 ].length - 1 ]= Double.NaN; data[ 0 ][ data[ 0 ].length - 2 ]= Double.NaN; */ return new AxisChartDataSet( data, legendLabels, paints, chartType, chartTypeProperties ); } } |
From: <nat...@us...> - 2003-10-15 03:24:42
|
Update of /cvsroot/jcharts/jCharts/jCharts0.7/docs In directory sc8-pr-cvs1:/tmp/cvs-serv27938 Modified Files: README.html Log Message: line and point charts are no longer rendered starting at the y-axis Index: README.html =================================================================== RCS file: /cvsroot/jcharts/jCharts/jCharts0.7/docs/README.html,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** README.html 29 Jun 2003 13:30:58 -0000 1.19 --- README.html 15 Oct 2003 03:24:38 -0000 1.20 *************** *** 7,11 **** <html> <head> ! <title>jCharts - 0.7.4</title> </head> --- 7,11 ---- <html> <head> ! <title>jCharts - 0.7.5</title> </head> *************** *** 35,39 **** </TD> <TD ALIGN="right" BGCOLOR="#C0C0C0" STYLE="border-bottom: 1px solid Black;"> ! <DIV STYLE="font: bold 12pt Arial Narrow;">Release 0.7.4</DIV> </TD> </TR> --- 35,39 ---- </TD> <TD ALIGN="right" BGCOLOR="#C0C0C0" STYLE="border-bottom: 1px solid Black;"> ! <DIV STYLE="font: bold 12pt Arial Narrow;">Release 0.7.5</DIV> </TD> </TR> *************** *** 44,56 **** <table WIDTH="98%" CELLSPACING="0" CELLPADDING="5" align="center" class="OUTER_TABLE"> <tr> ! <td bgcolor="#ECEAFF" style="border-bottom: 1px solid Black; font-weight: bold;">jCharts 0.7.4</td> </tr> <tr> <td valign="top"> ! <p>Welcome to the 0.7.4 release of jCharts!</p> <p>Please be aware, there have been significant changes in the Properties model in this Release, and some minor tweaks to the data interfaces. You CAN NOT simply replace the 0.6 jar with the 0.7 jar and have your chart work. Please consult the java docs, examples, test framework, and User Guide for the changes.</p> <p>Do NOT be alarmed, as the changes will **NOT** require a complete rewrite of your code.</p> ! <p>jCharts 0.7.4 **REQUIRES** the JDK 1.4.x for the PNG and JPEG encoders to work, however, legacy support is provided via the JPEGEncoder13 class</p> <br/> </td> --- 44,56 ---- <table WIDTH="98%" CELLSPACING="0" CELLPADDING="5" align="center" class="OUTER_TABLE"> <tr> ! <td bgcolor="#ECEAFF" style="border-bottom: 1px solid Black; font-weight: bold;">jCharts 0.7.5</td> </tr> <tr> <td valign="top"> ! <p>Welcome to the 0.7.5 release of jCharts!</p> <p>Please be aware, there have been significant changes in the Properties model in this Release, and some minor tweaks to the data interfaces. You CAN NOT simply replace the 0.6 jar with the 0.7 jar and have your chart work. Please consult the java docs, examples, test framework, and User Guide for the changes.</p> <p>Do NOT be alarmed, as the changes will **NOT** require a complete rewrite of your code.</p> ! <p>jCharts 0.7.5 **REQUIRES** the JDK 1.4.x for the PNG and JPEG encoders to work, however, legacy support is provided via the JPEGEncoder13 class</p> <br/> </td> *************** *** 67,71 **** <td valign="top"> <pre> ! jCharts0.7.4 +--build --build.xml - ant build script --- 67,71 ---- <td valign="top"> <pre> ! jCharts0.7.5 +--build --build.xml - ant build script *************** *** 79,83 **** +--lib - Apache XML Batik libraries needed for encoding to SVG +--src - all of the source code ! --jCharts-0.7.4.jar - the jCharts compiled code base --jChartsExampleServlets.war - demo web archive. Put it in your Servlet container's 'webapps' directory </pre> --- 79,83 ---- +--lib - Apache XML Batik libraries needed for encoding to SVG +--src - all of the source code ! --jCharts-0.7.5.jar - the jCharts compiled code base --jChartsExampleServlets.war - demo web archive. Put it in your Servlet container's 'webapps' directory </pre> *************** *** 86,89 **** --- 86,104 ---- </table> <br/> + + + <table width="98%" border="0" cellspacing="0" cellpadding="3" align="center" bordercolor="Black" class="OUTER_TABLE"> + <tr> + <td bgcolor="#CAFFC4" style="border-bottom: 1px solid Black; font-weight: bold;">0.7.5</td> + </tr> + <tr> + <td valign="top"> + * Line and Point charts no longer start their plots at the y-axis. + </td> + </tr> + </table> + <br/> + + <table width="98%" border="0" cellspacing="0" cellpadding="3" align="center" bordercolor="Black" class="OUTER_TABLE"> |
From: <nat...@us...> - 2003-10-15 03:23:19
|
Update of /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/axisChart/axis In directory sc8-pr-cvs1:/tmp/cvs-serv27801 Modified Files: XAxis.java Log Message: line and point charts are no longer rendered starting at the y-axis Index: XAxis.java =================================================================== RCS file: /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/axisChart/axis/XAxis.java,v retrieving revision 1.19 retrieving revision 1.20 diff -C2 -d -r1.19 -r1.20 *** XAxis.java 31 Mar 2003 00:26:42 -0000 1.19 --- XAxis.java 15 Oct 2003 03:23:15 -0000 1.20 *************** *** 209,212 **** --- 209,214 ---- || iAxisPlotDataSet.getChartType().equals( ChartType.BAR_CLUSTERED ) || iAxisPlotDataSet.getChartType().equals( ChartType.BAR_STACKED ) + || iAxisPlotDataSet.getChartType().equals( ChartType.LINE ) + || iAxisPlotDataSet.getChartType().equals( ChartType.POINT ) || iAxisPlotDataSet.getChartType().equals( ChartType.STOCK ) ) { |
From: <nic...@us...> - 2003-09-30 15:58:35
|
Update of /cvsroot/jcharts/krysalis-jcharts In directory sc8-pr-cvs1:/tmp/cvs-serv27771 Modified Files: .classpath Log Message: Remove inexistent path that prevented from compiling Index: .classpath =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/.classpath,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** .classpath 6 Sep 2003 11:14:10 -0000 1.4 --- .classpath 30 Sep 2003 15:58:31 -0000 1.5 *************** *** 3,7 **** <classpathentry kind="src" path="src/java"/> <classpathentry kind="src" path="src/scratchpad"/> - <classpathentry kind="src" path="src/test"/> <classpathentry kind="var" path="JRE_LIB" sourcepath="JRE_SRC"/> <classpathentry kind="lib" path="lib/batik-awt-util.jar"/> --- 3,6 ---- |
From: <nat...@us...> - 2003-09-26 01:01:05
|
Update of /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/axisChart In directory sc8-pr-cvs1:/tmp/cvs-serv10187 Modified Files: LineChart.java Log Message: fixed image map label bug Index: LineChart.java =================================================================== RCS file: /cvsroot/jcharts/jCharts/jCharts0.7/src/org/jCharts/axisChart/LineChart.java,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** LineChart.java 19 Mar 2003 01:38:37 -0000 1.14 --- LineChart.java 26 Sep 2003 01:01:01 -0000 1.15 *************** *** 95,99 **** if( axisChart.getXAxis().getAxisLabelsGroup() != null ) { ! label = axisChart.getXAxis().getAxisLabelsGroup().getTextTag( i ).getText(); } else --- 95,99 ---- if( axisChart.getXAxis().getAxisLabelsGroup() != null ) { ! label = axisChart.getXAxis().getAxisLabelsGroup().getTextTag( j ).getText(); } else |
From: <nat...@us...> - 2003-09-26 00:45:47
|
Update of /cvsroot/jcharts/krysalis-jcharts In directory sc8-pr-cvs1:/tmp/cvs-serv7077 Modified Files: status.xml Log Message: Index: status.xml =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/status.xml,v retrieving revision 1.14 retrieving revision 1.15 diff -C2 -d -r1.14 -r1.15 *** status.xml 8 Aug 2003 02:50:57 -0000 1.14 --- status.xml 26 Sep 2003 00:45:41 -0000 1.15 *************** *** 94,97 **** --- 94,100 ---- Added a Radar Chart implementation. </action> + <action dev="nathaniel_auvil" type="fix" context="code"> + Fixed Image Map bug in <code>LineChart</code> that the Label was always the first item in the data set. + </action> </release> |
From: <nat...@us...> - 2003-09-26 00:44:08
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/java/org/krysalis/jcharts/axisChart In directory sc8-pr-cvs1:/tmp/cvs-serv6630 Modified Files: LineChart.java Log Message: fix image map label bug Index: LineChart.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/java/org/krysalis/jcharts/axisChart/LineChart.java,v retrieving revision 1.2 retrieving revision 1.3 diff -C2 -d -r1.2 -r1.3 *** LineChart.java 27 Aug 2003 04:37:44 -0000 1.2 --- LineChart.java 26 Sep 2003 00:44:02 -0000 1.3 *************** *** 103,107 **** if( axisChart.getXAxis().getAxisLabelsGroup() != null ) { ! label = axisChart.getXAxis().getAxisLabelsGroup().getTextTag( i ).getText(); } else --- 103,107 ---- if( axisChart.getXAxis().getAxisLabelsGroup() != null ) { ! label = axisChart.getXAxis().getAxisLabelsGroup().getTextTag( j ).getText(); } else |
From: <nat...@us...> - 2003-09-24 01:18:31
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/documentation/content/xdocs/userGuide In directory sc8-pr-cvs1:/tmp/cvs-serv23190 Added Files: pieChart2DExample.xml Log Message: --- NEW FILE: pieChart2DExample.xml --- <?xml version="1.0" encoding="UTF-8"?> <!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V1.1//EN" "document-v11.dtd"> <document> <header> <title>Pie Charts</title> <authors> <person name="Nathaniel Auvil" email="nat...@so..."/> </authors> </header> <body> <section> <title>2D Pie Chart Example</title> <p> Here is code for a simple 2D Pie Chart... </p> <source> double[] data= { 81d, 55d, 39d, 20.6d }; String[] labels= { "BMW M5", "BMW M3", "Viper GTS-R", "Corvette Z06" }; Paint[] paints= { Color.lightGray, Color.green, Color.blue, Color.red }; PieChartDataSet pieChartDataSet= new PieChartDataSet( "Cars That Own", data, labels, paints, pieChart2DProperties ); PieChart2DProperties pieChart2DProperties= new PieChart2DProperties(); PieChart2D pieChart2D= new PieChart2D( pieChartDataSet, new LegendProperties(), new ChartProperties(), 400, 350 ); </source> <figure src="images/userGuide/pieCharts/pieChartBasic.png" alt="Simple 2D Pie Chart"/> </section> </body> </document> |
From: <nic...@us...> - 2003-09-06 11:14:15
|
Update of /cvsroot/jcharts/krysalis-jcharts In directory sc8-pr-cvs1:/tmp/cvs-serv25210 Modified Files: .classpath Log Message: add junit tests to path Index: .classpath =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/.classpath,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** .classpath 2 Sep 2003 08:44:02 -0000 1.3 --- .classpath 6 Sep 2003 11:14:10 -0000 1.4 *************** *** 3,6 **** --- 3,7 ---- <classpathentry kind="src" path="src/java"/> <classpathentry kind="src" path="src/scratchpad"/> + <classpathentry kind="src" path="src/test"/> <classpathentry kind="var" path="JRE_LIB" sourcepath="JRE_SRC"/> <classpathentry kind="lib" path="lib/batik-awt-util.jar"/> *************** *** 10,13 **** --- 11,15 ---- <classpathentry kind="lib" path="lib/batik-xml.jar"/> <classpathentry kind="lib" path="lib/servlet_2_2.jar"/> + <classpathentry kind="var" path="JUNIT_HOME/junit.jar" sourcepath="JUNIT_HOME/junitsrc.zip"/> <classpathentry kind="output" path="build"/> </classpath> |
From: Nicola K. B. <nic...@ap...> - 2003-09-06 07:54:55
|
http://www.gmane.org is a service that enables to read mailing lists using a news reader. The following user-writeable krysalis mailing lists have been added to gmane: gmane.comp.krysalis.jcharts.devel gmane.comp.krysalis.jcharts.user gmane.comp.krysalis.metamorphosis.sandbox The following cvs-commit read-only lists have been also added: gmane.comp.krysalis.cvs gmane.comp.krysalis.metamorphosis.cvs gmane.comp.krysalis.jcharts.cvs This message should trigger their effective creation. -- Nicola Ken Barozzi nic...@ap... - verba volant, scripta manent - (discussions get forgotten, just code remains) --------------------------------------------------------------------- |
From: <nic...@us...> - 2003-09-05 12:45:25
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt In directory sc8-pr-cvs1:/tmp/cvs-serv24180/src/scratchpad/org/krysalis/jcharts/gantt Modified Files: PlanRenderer.java Log Message: Calculate and real height ofchar. Index: PlanRenderer.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt/PlanRenderer.java,v retrieving revision 1.10 retrieving revision 1.11 diff -C2 -d -r1.10 -r1.11 *** PlanRenderer.java 4 Sep 2003 11:45:16 -0000 1.10 --- PlanRenderer.java 5 Sep 2003 12:45:16 -0000 1.11 *************** *** 79,86 **** HashMap hints) { - //@todo - int height = 6000; - int width = leftWidth + barspaceWidth; - String[] colours; String[] darkcolours; --- 79,82 ---- *************** *** 103,106 **** --- 99,106 ---- float rightEdge; + //@todo + int height = (int) (data.size() * barspaceHeight + currentTopEdge); + int width = leftWidth + barspaceWidth; + Rectangle oldClipBounds = g2.getClipBounds(); if (oldClipBounds == null) { |
From: <nic...@us...> - 2003-09-04 12:36:17
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt In directory sc8-pr-cvs1:/tmp/cvs-serv16319/src/scratchpad/org/krysalis/jcharts/gantt Modified Files: Plan.java Log Message: Issue a repaint when new data is loaded. Index: Plan.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt/Plan.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** Plan.java 2 Sep 2003 08:43:15 -0000 1.1 --- Plan.java 4 Sep 2003 11:43:22 -0000 1.2 *************** *** 194,198 **** data.add(dat); }} ! } --- 194,198 ---- data.add(dat); }} ! repaint(); } |
From: <nic...@us...> - 2003-09-04 11:45:31
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt In directory sc8-pr-cvs1:/tmp/cvs-serv16733/src/scratchpad/org/krysalis/jcharts/gantt Modified Files: DateHandlerTest.java DateHandler.java PlanRenderer.java Log Message: Reformat and tidy code. Index: DateHandlerTest.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt/DateHandlerTest.java,v retrieving revision 1.1 retrieving revision 1.2 diff -C2 -d -r1.1 -r1.2 *** DateHandlerTest.java 3 Sep 2003 10:38:45 -0000 1.1 --- DateHandlerTest.java 4 Sep 2003 11:45:16 -0000 1.2 *************** *** 53,57 **** final public void testGetStringDateFromWeek() throws ParseException { - //TODO Implement getStringDateFromWeek(). //TRANSFORMING WEEK: 39 into: Mon Sep 22 10:36:32 CEST 2003 String result = DateHandler.getStringDateFromWeek(39, true); --- 53,56 ---- Index: DateHandler.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt/DateHandler.java,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** DateHandler.java 3 Sep 2003 10:39:49 -0000 1.8 --- DateHandler.java 4 Sep 2003 11:45:16 -0000 1.9 *************** *** 225,229 **** public static String getStringDateFromWeek(int week, boolean startDay) throws ParseException { ! System.out.print("TRANSFORMING WEEK: " + String.valueOf(week)); Calendar c = Calendar.getInstance(); c.setTime(new Date()); --- 225,230 ---- public static String getStringDateFromWeek(int week, boolean startDay) throws ParseException { ! //@debug ! //System.out.print("TRANSFORMING WEEK: " + String.valueOf(week)); Calendar c = Calendar.getInstance(); c.setTime(new Date()); *************** *** 238,242 **** Date result = c.getTime(); ! System.out.println(" into: " + result); return dateStampFormat.format(result); --- 239,244 ---- Date result = c.getTime(); ! //@debug ! //System.out.println(" into: " + result); return dateStampFormat.format(result); Index: PlanRenderer.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt/PlanRenderer.java,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** PlanRenderer.java 3 Sep 2003 10:38:08 -0000 1.9 --- PlanRenderer.java 4 Sep 2003 11:45:16 -0000 1.10 *************** *** 79,83 **** HashMap hints) { - //@todo int height = 6000; --- 79,82 ---- *************** *** 92,96 **** //@todo String height LineMetrics lm = font.getLineMetrics(title, g2.getFontRenderContext()); ! // ----------------------------------------- // Month *1 --- 91,95 ---- //@todo String height LineMetrics lm = font.getLineMetrics(title, g2.getFontRenderContext()); ! // ----------------------------------------- // Month *1 *************** *** 100,114 **** // Day *3 // ----------------------------------------- ! float singleDateHeight = (lm.getHeight() + 2); float currentTopEdge = singleDateHeight * 3; float rightEdge; Rectangle oldClipBounds = g2.getClipBounds(); ! Shape fullclip = new Rectangle2D.Float(0, 0, width, height).createIntersection(oldClipBounds); ! Shape leftclip = new Rectangle2D.Float(0, 0, firstSpaceWidth, height).createIntersection(oldClipBounds); Shape middleclip = ! new Rectangle2D.Float(firstSpaceWidth, 0, secondSpaceWidth, height).createIntersection(oldClipBounds); Shape rightclip = ! new Rectangle2D.Float(leftWidth, 0, width - leftWidth, height).createIntersection(oldClipBounds); //g2.clip(fullclip); --- 99,124 ---- // Day *3 // ----------------------------------------- ! float singleDateHeight = (lm.getHeight() + 2); float currentTopEdge = singleDateHeight * 3; float rightEdge; Rectangle oldClipBounds = g2.getClipBounds(); ! if (oldClipBounds == null) { ! oldClipBounds = new Rectangle(0, 0, width, height); ! } ! Shape fullclip = ! new Rectangle2D.Float(0, 0, width, height).createIntersection( ! oldClipBounds); ! Shape leftclip = ! new Rectangle2D.Float(0, 0, firstSpaceWidth, height).createIntersection( ! oldClipBounds); Shape middleclip = ! new Rectangle2D ! .Float(firstSpaceWidth, 0, secondSpaceWidth, height) ! .createIntersection(oldClipBounds); Shape rightclip = ! new Rectangle2D ! .Float(leftWidth, 0, width - leftWidth, height) ! .createIntersection(oldClipBounds); //g2.clip(fullclip); *************** *** 144,154 **** float topDateHeight = singleDateHeight; ! float middleDateHeight = singleDateHeight*2; ! float bottomDateHeight = singleDateHeight*3; ! g2.setPaint(Color.BLACK); g2.draw(new Line2D.Float(0, topDateHeight, width, topDateHeight)); ! g2.draw(new Line2D.Float(leftWidth, middleDateHeight, width, middleDateHeight)); ! g2.draw(new Line2D.Float(leftWidth, bottomDateHeight, width, bottomDateHeight)); //currentTopEdge!=necessarily to bottomDateHeight g2.draw(new Line2D.Float(0, currentTopEdge, width, currentTopEdge)); --- 154,166 ---- float topDateHeight = singleDateHeight; ! float middleDateHeight = singleDateHeight * 2; ! float bottomDateHeight = singleDateHeight * 3; ! g2.setPaint(Color.BLACK); g2.draw(new Line2D.Float(0, topDateHeight, width, topDateHeight)); ! g2.draw( ! new Line2D.Float(leftWidth, middleDateHeight, width, middleDateHeight)); ! g2.draw( ! new Line2D.Float(leftWidth, bottomDateHeight, width, bottomDateHeight)); //currentTopEdge!=necessarily to bottomDateHeight g2.draw(new Line2D.Float(0, currentTopEdge, width, currentTopEdge)); *************** *** 157,172 **** //todo need a better positioning if ever ! // ! // //firstdate ! // g2.drawString( ! // dh.shortFormat(dh.getStartDate()), ! // leftWidth + 1, ! // currentTopEdge - 2); ! // ! // //lastdate ! // g2.drawString( ! // dh.shortFormat(dh.getEndDate()), ! // (int) width, ! // currentTopEdge - 2); g2.setPaint(new Color(150, 150, 150)); --- 169,184 ---- //todo need a better positioning if ever ! // ! // //firstdate ! // g2.drawString( ! // dh.shortFormat(dh.getStartDate()), ! // leftWidth + 1, ! // currentTopEdge - 2); ! // ! // //lastdate ! // g2.drawString( ! // dh.shortFormat(dh.getEndDate()), ! // (int) width, ! // currentTopEdge - 2); g2.setPaint(new Color(150, 150, 150)); *************** *** 192,231 **** g2.setPaint(Color.BLACK); ! g2.draw(new Line2D.Float(currentDateLocation, topDateHeight, currentDateLocation, middleDateHeight)); ! g2.drawString( dh.shortFormat(cal.getTime()), ! (int) currentDateLocation+2, (int) (middleDateHeight - 2)); ! // Week number g2.setPaint(Color.BLACK); ! String weekNumString = dh.weekNumberFormat(cal.getTime()); float weekNumStringWidth = ! (float) font.getStringBounds(weekNumString, g2.getFontRenderContext()).getWidth(); //@todo fix centering routing (need string width) g2.drawString( ! dh.weekNumberFormat(cal.getTime()), ! (int) (currentDateLocation + 3.5 * singleDayWidth - weekNumStringWidth / 2) - 2, (int) (bottomDateHeight - 2)); ! ! g2.draw(new Line2D.Float(currentDateLocation ,middleDateHeight, currentDateLocation, bottomDateHeight)); ! ! ! ! ! } ! //@todo activate every day as fourth date hint? ! // g2.setPaint(Color.BLACK); ! // ! // g2.drawString( ! // dh.shortDayOfWeekFormat(cal.getTime()), ! // (int) currentDateLocation +2, ! // (int) (bottomDateHeight - 2)); ! // ! // g2.draw(new Line2D.Float(currentDateLocation ,middleDateHeight, currentDateLocation, bottomDateHeight)); Shape currentDay = --- 204,255 ---- g2.setPaint(Color.BLACK); ! g2.draw( ! new Line2D.Float( ! currentDateLocation, ! topDateHeight, ! currentDateLocation, ! middleDateHeight)); ! g2.drawString( dh.shortFormat(cal.getTime()), ! (int) currentDateLocation + 2, (int) (middleDateHeight - 2)); ! // Week number g2.setPaint(Color.BLACK); ! String weekNumString = dh.weekNumberFormat(cal.getTime()); float weekNumStringWidth = ! (float) font ! .getStringBounds(weekNumString, g2.getFontRenderContext()) ! .getWidth(); //@todo fix centering routing (need string width) g2.drawString( ! dh.weekNumberFormat(cal.getTime()), ! (int) (currentDateLocation ! + 3.5 * singleDayWidth ! - weekNumStringWidth / 2) ! - 2, (int) (bottomDateHeight - 2)); ! ! g2.draw( ! new Line2D.Float( ! currentDateLocation, ! middleDateHeight, ! currentDateLocation, ! bottomDateHeight)); ! ! } ! //@todo activate every day as fourth date hint? ! // g2.setPaint(Color.BLACK); ! // ! // g2.drawString( ! // dh.shortDayOfWeekFormat(cal.getTime()), ! // (int) currentDateLocation +2, ! // (int) (bottomDateHeight - 2)); ! // ! // g2.draw(new Line2D.Float(currentDateLocation ,middleDateHeight, currentDateLocation, bottomDateHeight)); Shape currentDay = *************** *** 260,264 **** // currentDateLocation + 1, // currentTopEdge + offset*15); ! //if MONTH if (cal.get(Calendar.DAY_OF_MONTH) == 1) { --- 284,288 ---- // currentDateLocation + 1, // currentTopEdge + offset*15); ! //if MONTH if (cal.get(Calendar.DAY_OF_MONTH) == 1) { *************** *** 267,271 **** g2.drawString( dh.monthFormat(cal.getTime()), ! (int) currentDateLocation +2, (int) (topDateHeight - 2)); --- 291,295 ---- g2.drawString( dh.monthFormat(cal.getTime()), ! (int) currentDateLocation + 2, (int) (topDateHeight - 2)); *************** *** 277,281 **** currentDateLocation, (topDateHeight))); ! g2.draw( new Line2D.Float( --- 301,305 ---- currentDateLocation, (topDateHeight))); ! g2.draw( new Line2D.Float( *************** *** 336,341 **** g2.draw(taskGraphic); ! //@todo add descr ! //addDescr(doc, taskGraphic, name); //start and end dates --- 360,364 ---- g2.draw(taskGraphic); ! //@todo add tooltip //start and end dates |
From: Ashutosh S. <ash...@al...> - 2003-09-03 11:40:36
|
I recently downloaded jcharts0.7.4.=20 Found the included docs and the example war file quite useful in using = and understanding this library.=20 I need to plot a Time Series chart, say like a chart depicting the = memory usage of the system i.e. (Memory Usage v/s Time). I have an impression that it's not possible to render such a chart using = the existing API.=20 What I see in the current available implementation, for the base class = Chart are - Axis Chart, ScatterPlotAxisChart and PieChart2D. If in case it's possible to plot, Time Series Chart using these API's. = Kindly let me know. Thanks & Regards, Ashutosh |
From: <nic...@us...> - 2003-09-03 10:39:52
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt In directory sc8-pr-cvs1:/tmp/cvs-serv9571/src/scratchpad/org/krysalis/jcharts/gantt Modified Files: DateHandler.java Log Message: Fix bug that made the calendar roll on the DATE and not DAY_OF_YEAR. A testcase has been committed to make sure this doesn't happen again. Index: DateHandler.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt/DateHandler.java,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** DateHandler.java 2 Sep 2003 16:25:55 -0000 1.7 --- DateHandler.java 3 Sep 2003 10:39:49 -0000 1.8 *************** *** 230,238 **** c.set(Calendar.WEEK_OF_YEAR, week); c.set(Calendar.DAY_OF_WEEK, Calendar.MONDAY); ! // | S | M | T | W | T | F | // X +4 if (!startDay) { ! c.roll(Calendar.DATE, +4); } --- 230,238 ---- c.set(Calendar.WEEK_OF_YEAR, week); c.set(Calendar.DAY_OF_WEEK, Calendar.MONDAY); ! // | S | M | T | W | T | F | // X +4 if (!startDay) { ! c.roll(Calendar.DAY_OF_YEAR, +4); } |
From: <nic...@us...> - 2003-09-03 10:38:48
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt In directory sc8-pr-cvs1:/tmp/cvs-serv9402/src/scratchpad/org/krysalis/jcharts/gantt Added Files: DateHandlerTest.java Log Message: Initial Testcase for DateHandler. --- NEW FILE: DateHandlerTest.java --- /* * Created on 3-set-2003 */ package org.krysalis.jcharts.gantt; import java.util.*; import java.text.DateFormat; import java.text.ParseException; import java.text.SimpleDateFormat; import junit.framework.Assert; import junit.framework.TestCase; /** * @author barozzink */ public class DateHandlerTest extends TestCase { DateHandler dh; private final static DateFormat dateStampFormat = new SimpleDateFormat("yyyyMMdd"); //TRANSFORMING WEEK: 39 into: Mon Sep 22 10:36:32 CEST 2003 //TRANSFORMING WEEK: 40 into: Wed Sep 03 10:36:32 CEST 2003 public static void main(String[] args) { junit.swingui.TestRunner.run(DateHandlerTest.class); } /* * @see TestCase#setUp() */ protected void setUp() throws Exception { super.setUp(); Date startDate = dateStampFormat.parse("20030616"); Date endDate = dateStampFormat.parse("20031029"); dh = new DateHandler(startDate,endDate); } /* * @see TestCase#tearDown() */ protected void tearDown() throws Exception { super.tearDown(); } /** * Constructor for DateHandlerTest. * @param arg0 */ public DateHandlerTest(String arg0) { super(arg0); } final public void testGetStringDateFromWeek() throws ParseException { //TODO Implement getStringDateFromWeek(). //TRANSFORMING WEEK: 39 into: Mon Sep 22 10:36:32 CEST 2003 String result = DateHandler.getStringDateFromWeek(39, true); Assert.assertEquals(result, "20030922"); //TRANSFORMING WEEK: 40 into: Fri Oct 03 10:36:32 CEST 2003 result = DateHandler.getStringDateFromWeek(40, false); Assert.assertEquals(result, "20031003"); } } |
From: <nic...@us...> - 2003-09-03 10:38:13
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt In directory sc8-pr-cvs1:/tmp/cvs-serv9315/src/scratchpad/org/krysalis/jcharts/gantt Modified Files: PlanRenderer.java Log Message: Fix clipping so that the component does not draw outside of bounds. Index: PlanRenderer.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/scratchpad/org/krysalis/jcharts/gantt/PlanRenderer.java,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** PlanRenderer.java 2 Sep 2003 16:25:55 -0000 1.8 --- PlanRenderer.java 3 Sep 2003 10:38:08 -0000 1.9 *************** *** 38,41 **** --- 38,42 ---- import java.awt.Font; import java.awt.Graphics2D; + import java.awt.Rectangle; import java.awt.Shape; import java.awt.font.LineMetrics; *************** *** 62,66 **** int barspaceHeight = 20; int barHeightMargin = (barspaceHeight - barHeigth) / 2; ! int barspaceWidth = 700; int firstSpaceWidth = 250; int secondSpaceWidth = 100; --- 63,67 ---- int barspaceHeight = 20; int barHeightMargin = (barspaceHeight - barHeigth) / 2; ! int barspaceWidth = 600; int firstSpaceWidth = 250; int secondSpaceWidth = 100; *************** *** 78,81 **** --- 79,83 ---- HashMap hints) { + //@todo int height = 6000; *************** *** 102,113 **** float rightEdge; ! Shape fullclip = new Rectangle2D.Float(0, 0, width, height); ! Shape leftclip = new Rectangle2D.Float(0, 0, firstSpaceWidth, height); Shape middleclip = ! new Rectangle2D.Float(firstSpaceWidth, 0, secondSpaceWidth, height); Shape rightclip = ! new Rectangle2D.Float(leftWidth, 0, width - leftWidth, height); ! g2.clip(fullclip); g2.setBackground(Color.WHITE); --- 104,116 ---- float rightEdge; ! Rectangle oldClipBounds = g2.getClipBounds(); ! Shape fullclip = new Rectangle2D.Float(0, 0, width, height).createIntersection(oldClipBounds); ! Shape leftclip = new Rectangle2D.Float(0, 0, firstSpaceWidth, height).createIntersection(oldClipBounds); Shape middleclip = ! new Rectangle2D.Float(firstSpaceWidth, 0, secondSpaceWidth, height).createIntersection(oldClipBounds); Shape rightclip = ! new Rectangle2D.Float(leftWidth, 0, width - leftWidth, height).createIntersection(oldClipBounds); ! //g2.clip(fullclip); g2.setBackground(Color.WHITE); *************** *** 298,306 **** g2.setClip(leftclip); g2.drawString(label, 0, currentTopEdge + 12); ! g2.setClip(null); g2.setClip(middleclip); g2.drawString(name, firstSpaceWidth, currentTopEdge + 12); ! g2.setClip(null); int type = currentAction.getType(); --- 301,309 ---- g2.setClip(leftclip); g2.drawString(label, 0, currentTopEdge + 12); ! g2.setClip(oldClipBounds); g2.setClip(middleclip); g2.drawString(name, firstSpaceWidth, currentTopEdge + 12); ! g2.setClip(oldClipBounds); int type = currentAction.getType(); *************** *** 351,355 **** currentTopEdge + 9); ! g2.setClip(null); //rowItems List fragments = currentAction.getRowItems(); --- 354,358 ---- currentTopEdge + 9); ! g2.setClip(oldClipBounds); //rowItems List fragments = currentAction.getRowItems(); *************** *** 379,383 **** g2.setPaint(Color.BLACK); g2.draw(taskGraphic); ! } --- 382,386 ---- g2.setPaint(Color.BLACK); g2.draw(taskGraphic); ! g2.setClip(oldClipBounds); } *************** *** 423,430 **** g2.setPaint(new Color(normMult, 0, 0)); g2.fill(milestoneShape); - g2.setPaint(Color.BLACK); g2.draw(milestoneShape); ! g2.setClip(null); } --- 426,432 ---- g2.setPaint(new Color(normMult, 0, 0)); g2.fill(milestoneShape); g2.setPaint(Color.BLACK); g2.draw(milestoneShape); ! g2.setClip(oldClipBounds); } *************** *** 450,454 **** g2.setPaint(Color.BLACK); g2.draw(taskGraphic); ! break; default : --- 452,456 ---- g2.setPaint(Color.BLACK); g2.draw(taskGraphic); ! g2.setClip(oldClipBounds); break; default : |
From: <nat...@us...> - 2003-09-03 02:40:17
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/java/org/krysalis/jcharts/demo/userGuide In directory sc8-pr-cvs1:/tmp/cvs-serv2517 Modified Files: UserGuideBase.java Log Message: added 3D Pie code framework Index: UserGuideBase.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/java/org/krysalis/jcharts/demo/userGuide/UserGuideBase.java,v retrieving revision 1.4 retrieving revision 1.5 diff -C2 -d -r1.4 -r1.5 *** UserGuideBase.java 8 Aug 2003 08:51:27 -0000 1.4 --- UserGuideBase.java 3 Sep 2003 02:40:13 -0000 1.5 *************** *** 49,54 **** public class UserGuideBase { ! private static final String dir= "/userGuide/"; ! private static String path; private static String subdir; --- 49,53 ---- public class UserGuideBase { ! private static String path= "./src/documentation/resources/images/userGuide/"; private static String subdir; *************** *** 60,75 **** public static void main( String[] args ) throws Throwable { ! if( args.length == 0 || args.length > 2 ) { ! System.out.println( "Usage - java UserGuideBase outputPath whatToRun" ); return; } else { ! UserGuideBase.path = args[0]; ! ! if( args.length == 2 ) { ! String whatToRun = args[1]; System.out.println( "running user guide charts for section: " + whatToRun ); --- 59,72 ---- public static void main( String[] args ) throws Throwable { ! if( args.length > 2 ) { ! System.out.println( "Usage - java UserGuideBase <whatToRun>" ); return; } else { ! if( args.length == 1 ) { ! String whatToRun = args[0]; System.out.println( "running user guide charts for section: " + whatToRun ); *************** *** 102,105 **** --- 99,109 ---- } + if( whatToRun.equals( "pie3d" ) ) + { + UserGuideBase.subdir= "pieChart3d/"; + PieChart3DGuide pieChart3D = new PieChart3DGuide(); + pieChart3D.run(); + } + if( whatToRun.equals( "axis" ) ) { *************** *** 158,161 **** --- 162,168 ---- pieChart.run(); + PieChart3DGuide pieChart3d = new PieChart3DGuide(); + pieChart3d.run(); + AxisChartsGuide axisCharts = new AxisChartsGuide(); axisCharts.run(); *************** *** 194,198 **** try { ! fileOutputStream = new FileOutputStream( UserGuideBase.path + UserGuideBase.dir + UserGuideBase.subdir + fileName + extension ); PNGEncoder.encode( chart, fileOutputStream ); //JPEGEncoder13.encode( chart, 1.0f, fileOutputStream ); --- 201,205 ---- try { ! fileOutputStream = new FileOutputStream( UserGuideBase.path + UserGuideBase.subdir + fileName + extension ); PNGEncoder.encode( chart, fileOutputStream ); //JPEGEncoder13.encode( chart, 1.0f, fileOutputStream ); |
From: <nat...@us...> - 2003-09-03 02:39:37
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/java/org/krysalis/jcharts/demo/userGuide In directory sc8-pr-cvs1:/tmp/cvs-serv2353 Added Files: PieChart3DGuide.java Log Message: initial version --- NEW FILE: PieChart3DGuide.java --- /*********************************************************************************************** * Copyright 2002 (C) Nathaniel G. Auvil. All Rights Reserved. * * Redistribution and use of this software and associated documentation ("Software"), with or * without modification, are permitted provided that the following conditions are met: * * 1. Redistributions of source code must retain copyright statements and notices. * Redistributions must also contain a copy of this document. * * 2. Redistributions in binary form must reproduce the above copyright notice, this list of * conditions and the following disclaimer in the documentation and/or other materials * provided with the distribution. * * 3. The name "jCharts" or "Nathaniel G. Auvil" must not be used to endorse or promote * products derived from this Software without prior written permission of Nathaniel G. * Auvil. For written permission, please contact nat...@us... * * 4. Products derived from this Software may not be called "jCharts" nor may "jCharts" appear * in their names without prior written permission of Nathaniel G. Auvil. jCharts is a * registered trademark of Nathaniel G. Auvil. * * 5. Due credit should be given to the jCharts Project (http://jcharts.sourceforge.net/). * * THIS SOFTWARE IS PROVIDED BY Nathaniel G. Auvil AND CONTRIBUTORS ``AS IS'' AND ANY * EXPRESSED OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF * MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL * jCharts OR ITS CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, * EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF * SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT,STRICT LIABILITY, OR TORT * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN * IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE ************************************************************************************************/ package org.krysalis.jcharts.demo.userGuide; import org.krysalis.jcharts.chartData.ChartDataException; import org.krysalis.jcharts.chartData.PieChartDataSet; import org.krysalis.jcharts.nonAxisChart.PieChart3D; import org.krysalis.jcharts.properties.ChartProperties; import org.krysalis.jcharts.properties.LegendProperties; import org.krysalis.jcharts.properties.PieChart2DProperties; import org.krysalis.jcharts.properties.PieChart3DProperties; import org.krysalis.jcharts.properties.util.ChartStroke; import org.krysalis.jcharts.types.PieLabelType; import java.awt.*; /************************************************************************************* * * @author Nathaniel Auvil * @version $Id: PieChart3DGuide.java,v 1.1 2003/09/03 02:39:33 nathaniel_auvil Exp $ ************************************************************************************/ public class PieChart3DGuide extends UserGuideBase { /***************************************************************************************** * Tests a 'real' data set and usage. * * @throws Throwable ******************************************************************************************/ public void run() throws Throwable { this.basicChart(); this.zeroDegreeOffsetChart(); this.depth(); this.borderStroke(); this.borderPaint(); this.pieValueLabels(); this.pieLegendLabels(); } /******************************************************************************************/ private void outputChart( PieChart3DProperties pieChart3DProperties, String name ) throws ChartDataException { double[] data= { 81d, 55d, 39d, 20.6d }; String[] labels= { "BMW M5", "BMW M3", "Viper GTS-R", "Corvette Z06" }; Paint[] paints= { Color.lightGray, Color.green, Color.blue, Color.red }; PieChartDataSet pieChartDataSet= new PieChartDataSet( "Cars That Own", data, labels, paints, pieChart3DProperties ); PieChart3D pieChart3D= new PieChart3D( pieChartDataSet, new LegendProperties(), new ChartProperties(), 600, 350 ); super.exportImage( pieChart3D, name ); } /******************************************************************************************/ private void basicChart() throws Throwable { PieChart3DProperties pieChart3DProperties= new PieChart3DProperties(); this.outputChart( pieChart3DProperties, "pieChart3DBasic" ); } /******************************************************************************************/ private void zeroDegreeOffsetChart() throws Throwable { PieChart3DProperties pieChart3DProperties= new PieChart3DProperties(); pieChart3DProperties.setZeroDegreeOffset( 45f ); this.outputChart( pieChart3DProperties, "pieChart3DZeroOffset" ); } /******************************************************************************************/ private void depth() throws Throwable { PieChart3DProperties pieChart3DProperties= new PieChart3DProperties(); pieChart3DProperties.setDepth( 50 ); this.outputChart( pieChart3DProperties, "pieChart3DDepth" ); } /******************************************************************************************/ private void borderStroke() throws Throwable { PieChart3DProperties pieChart3DProperties= new PieChart3DProperties(); pieChart3DProperties.setBorderChartStroke( new ChartStroke( new BasicStroke( 4f ), Color.black ) ); this.outputChart( pieChart3DProperties, "pieChart3DBorderStroke" ); } /******************************************************************************************/ private void borderPaint() throws Throwable { /* PieChart2DProperties pieChart2DProperties= new PieChart2DProperties(); pieChart2DProperties.setBorderPaint( Color.gray ); this.outputChart( pieChart2DProperties, "pieChart3DBorderPaint" ); */ } private void pieValueLabels() throws ChartDataException { PieChart3DProperties pieChart3DProperties= new PieChart3DProperties(); pieChart3DProperties.setPieLabelType( PieLabelType.VALUE_LABELS ); this.outputChart( pieChart3DProperties, "pieChart3DValueLabels" ); } private void pieLegendLabels() throws ChartDataException { PieChart3DProperties pieChart3DProperties= new PieChart3DProperties(); pieChart3DProperties.setPieLabelType( PieLabelType.LEGEND_LABELS ); double[] data= { 81d, 55d, 39d, 20.6d }; String[] labels= { "BMW M5", "BMW M3", "Viper GTS-R", "Audi S6" }; Paint[] paints= { Color.lightGray, Color.green, Color.blue, Color.red }; PieChartDataSet pieChartDataSet= new PieChartDataSet( "Cars That Own", data, labels, paints, pieChart3DProperties ); PieChart3D pieChart3D= new PieChart3D( pieChartDataSet, null, new ChartProperties(), 400, 350 ); super.exportImage( pieChart3D, "pieChart3DLegendLabels" ); } } |
From: <nat...@us...> - 2003-09-03 02:39:12
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/java/org/krysalis/jcharts/nonAxisChart In directory sc8-pr-cvs1:/tmp/cvs-serv2285 Modified Files: PieChart3D.java Log Message: fixed bug rendering the default legend underneath. Index: PieChart3D.java =================================================================== RCS file: /cvsroot/jcharts/krysalis-jcharts/src/java/org/krysalis/jcharts/nonAxisChart/PieChart3D.java,v retrieving revision 1.8 retrieving revision 1.9 diff -C2 -d -r1.8 -r1.9 *** PieChart3D.java 9 Aug 2003 19:46:43 -0000 1.8 --- PieChart3D.java 3 Sep 2003 02:39:09 -0000 1.9 *************** *** 243,246 **** --- 243,249 ---- this.diameter = Math.min( this.diameter, widthAvailable ); + this.pie3dWidth = this.diameter; + this.pie3dHeight = this.pie3dWidth * RATIO; + if( this.getLegend().getLegendProperties().getPlacement() == LegendAreaProperties.BOTTOM ) *************** *** 249,254 **** this.pieY += chartTitleHeightPlusPadding; - legendY += this.diameter; - if( this.pieLabels != null ) { --- 252,255 ---- *************** *** 263,266 **** --- 264,268 ---- legendY += this.pieY; + legendY += this.pie3dHeight; legendY += this.getLegend().getLegendProperties().getChartPadding(); legendY += properties.getDepth(); |
From: <nat...@us...> - 2003-09-03 02:16:12
|
Update of /cvsroot/jcharts/krysalis-jcharts/src/documentation/resources/images/userGuide/pieChart3d In directory sc8-pr-cvs1:/tmp/cvs-serv31198/pieChart3d Log Message: Directory /cvsroot/jcharts/krysalis-jcharts/src/documentation/resources/images/userGuide/pieChart3d added to the repository |