We're sorry Aspose doesn't work properply without JavaScript enabled.

Free Support Forum - aspose.com

Anti-aliasing is no effect in sparkline to image

Workbook wb = new Workbook();
Worksheet worksheet = wb.getWorksheets().get(0);
worksheet.getCells().get("A1").setValue(1);
worksheet.getCells().get("B1").setValue(3);
worksheet.getCells().get("C1").setValue(2);
worksheet.getCells().get("D1").setValue(4);
worksheet.getCells().get("E1").setValue(3);
int idx = worksheet.getSparklineGroupCollection().add(SparklineType.LINE, "A1:E1", false,
CellArea.createCellArea("F1", "F1"));
SparklineGroup sparklineGroup = worksheet.getSparklineGroupCollection().get(idx);
Sparkline sparkline = sparklineGroup.getSparklineCollection().get(0);
ImageOrPrintOptions opt = new ImageOrPrintOptions();
opt.setImageFormat(ImageFormat.getPng());
sparkline.toImage("C:/a.png", opt);
opt.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON);
sparkline.toImage("C:/b.png", opt);




b.png is not anti-aliasing

Hi Xiong,


Thank you for contacting Aspose support.

We have evaluated your presented scenario while using the latest version of Aspose.Cells for Java 8.3.0.3, and we have noticed that setting the anti-aliasing isn’t taking effect while converting sparkline to image. We have logged this incident in our bug tracking system under the ticket CELLSJAVA-41118 for further investigation & correction purposes. Please spare us little time to properly analyze the scenario, and to provide the fix at earliest possible. In the meanwhile, we will keep you posted with updates in this regard.

The issues you have found earlier (filed as CELLSJAVA-41118) have been fixed in this update.


This message was posted using Notification2Forum from Downloads module by Aspose Notifier.