Page 1 of 1

Documentation incorrect

Posted: Fri Feb 29, 2008 7:58 am
by 7666477
The sample code in: /Docs/JavaDoc/com/steema/teechart/Shape.html seems incorrect. Most of those methods are not found in the Shape class.

For example, these don't exist!!!!
getMarks
getFont
setStyle
setText
setX0
setX1
setY0
setY1

Posted: Fri Feb 29, 2008 10:16 am
by narcis
Hi Happy,

All those properties exist and work fine for me here using latest TeeChart for Java release (Build 1.0.1.830) with the code below. Which exact TeeChart version are you using?

Code: Select all

        com.steema.teechart.styles.Shape shape1 = new com.steema.teechart.styles.Shape(tChart.getChart());
        
        shape1.setX0(0);
        shape1.setY0(0);
        shape1.setX1(100);
        shape1.setY1(100);
        shape1.getMarks().setVisible(true);
        shape1.setStyle(ShapeStyle.DIAMOND);
        shape1.setText(new String[] {"This is my shape"});
        shape1.getFont().setSize(20);

how do I tell?

Posted: Fri Feb 29, 2008 10:19 am
by 7666477
I *think* its the latest, how do I tell exactly?

Posted: Fri Feb 29, 2008 10:30 am
by narcis
Hi Happy,

You can either read it in Release.txt included with TeeChart's installation or add the line below to your code.

Code: Select all

        com.steema.teechart.editors.AboutDialog.showDialog();

Posted: Fri Feb 29, 2008 10:47 am
by 7666477
I am using 1.0.1.830

Thats strange that I don't have those methods!!! What else could be wrong?

Posted: Sat Mar 08, 2008 2:55 pm
by Marc
Hello,

Please check the Shape Class in your referenced TeeChart.Swing.Jar. To test you could set up a new project and reference the jar or open the TeeChart demo 'features' project adding TeeChart.Swing.Jar as a reference library.

Under the path 'com.steema.teechart.styles.Shape' in your IDE navigator you should see the methods described in the previous post:
  • setX0(double arg0)
    setY0(double arg0)
    setX1(double arg0)
    setY1(double arg0)
    getMarks()
    setStyle(ShapeStyle arg0)
    setText(String[] arg0)
    getFont()
If you do not see them then there is most likely a problem with the TeeChart installation or a problem with way your test project is configured. Please let us know if you get any more information to help us better understand the issue.

Regards,
Marc Meumann