#944 Text Antialiasing in ChartComposite doesn't work

open
nobody
None
5
2012-11-27
2009-07-13
No

The TextAntialiasing in the ChartComponent doesn't work. The issue can be easily tracked down to the paintControl Method of ChartComponent.
Within the JFreeChart rendering hints such as TextAntiAliasing are stored in a RenderingHints Object which is basically a Map. This code from
within the ChartComponent checks against the key, not the value of the TextAntialiasing RenderingHint:

Current implementation as of 1.0.13
if (this.chart.getTextAntiAlias()
== RenderingHints.KEY_TEXT_ANTIALIASING) {
gci.setTextAntialias(SWT.ON);
}

Corrected:
if (this.chart.getTextAntiAlias().equals(
RenderingHints.VALUE_TEXT_ANTIALIAS_ON)) {
gci.setTextAntialias(SWT.ON);
}

Discussion


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks