1

I have a x-y axis in jfree chart. In legend I want to use superscript(A/B^2) is there any solution for this?I found something for labels but how does it work for jfreechart?

SunyGirl
  • 419
  • 3
  • 10
  • 17

1 Answers1

4

You can use Unicode, e.g. A/B².

Addendum: For more complex rendering, consider one of the org.jfree.chart.annotations suitable for imaging, such as XYDrawableAnnotation, XYImageAnnotation, XYDataImageAnnotation.

Community
  • 1
  • 1
trashgod
  • 203,806
  • 29
  • 246
  • 1,045
  • What if we want to have A/B^\u03C3 (sigma) or something? Is there a solution for that too? – brimborium Sep 20 '12 at 07:21
  • 1
    @brimborium: I'd look at an [annotation](http://www.jfree.org/jfreechart/api/javadoc/org/jfree/chart/annotations/package-summary.html) that can handle an image. – trashgod Sep 20 '12 at 14:03
  • 1
    @trashgod Ah, cool. That would be a possibility. Thanks for the link. :) – brimborium Sep 20 '12 at 14:14