Stacked Area Chart Labels Are Not Rendered When Converting PPTX to PDF in Java

Summary

Stacked Area Charts (ChartType 48) in PowerPoint presentations don’t render axis labels and legends when converted to PDF using Aspose.Slides 26.2, even though regular Area charts work correctly.

Environment

  • Aspose.Slides Version: 26.2 (Java)
  • Java Version: 17
  • Operating System: Windows/Linux
  • License: Full commercial license (Aspose.Total)

Problem Description

When converting PowerPoint presentations containing Stacked Area Charts to PDF, the chart data areas render correctly but axis labels (X-axis, Y-axis) and legends are completely missing from the PDF output. The text data is present in the PDF (confirmed via text extraction), but it doesn’t render visually.

Regular Area charts (ChartType 47) in the same presentation convert perfectly with all labels visible.

Steps to Reproduce

  1. Load the attached PowerPoint file advanced-charts-test.pptx
    advanced-charts-test.zip (30.9 KB)

  2. Convert to PDF using standard conversion:

Presentation presentation = new Presentation("advanced-charts-test.pptx");
PdfOptions pdfOptions = new PdfOptions();
pdfOptions.setCompliance(PdfCompliance.Pdf17);
pdfOptions.setSufficientResolution(300f);
presentation.save("output.pdf", SaveFormat.Pdf, pdfOptions);
presentation.dispose();
  1. Open the generated PDF and navigate to slide 5 (Stacked Area Chart)

Expected Behavior

The Stacked Area Chart should display:

  • Y-axis labels: 0, 10, 20, 30, 40, 50, 60, 70
  • X-axis labels: 2020, 2021, 2022, 2023, 2024, 2025
  • Legend: North America, Europe, Asia Pacific, Latin America, Other Regions

Actual Behavior

The chart data areas (colored regions) render correctly, but all axis labels and the legend are invisible in the PDF. Text extraction confirms the label text is present in the PDF data but not rendering visually.

Comparison

  • Slide 4 (Area Chart - Type 47): ✓ Works perfectly - all labels visible
  • Slide 5 (Stacked Area Chart - Type 48): ✗ Labels missing

Chart Analysis

Chart inspection reveals:

  • Chart Type: 48 (StackedArea)
  • Y-axis visible: true
  • X-axis visible: true
  • Legend visible: true
  • Legend position/size: NaN values
  • Plot area position/size: NaN values
  • All data series and categories are present

Note: The working Area chart (slide 4) also has NaN geometry values, so this is not unique to the broken chart.

Attempted Workarounds

We tried the following workarounds, none of which fixed the issue:

  1. pdfOptions.setEmbedFullFonts(true) - No effect
  2. chart.validateChartLayout() - NaN values persist
  3. chart.getImage() - Doesn’t fix geometry
  4. Removing LoadOptions - No effect
  5. Various font substitution settings - No effect

Files Attached

  1. advanced-charts-test.pptx - Source PowerPoint file
  2. PEX-15876-slide5.png - Screenshot comparing PDF (left) vs PowerPoint (right)
  3. output.pdf - Generated PDF showing the issue

Impact

This affects any PowerPoint presentations with Stacked Area charts, making them unusable in PDF output as critical chart information (axis labels, legends) is missing.

Request

Please investigate and provide:

  1. Confirmation of the bug
  2. Expected fix timeline or version
  3. Any available workaround we can implement in our code

Additional Information

We are using Aspose.Slides as part of a document conversion service processing customer PowerPoint files. This issue was discovered during testing with various chart types.

Thank you for your assistance!

We’ve discovered a second chart rendering issue in the same presentation file:

Affected Chart:

  • Slide 6: Doughnut Chart (ChartType 66)

Problem Description:
Multi-line data labels on the doughnut chart are being rendered as single-line comma-separated values in the PDF output. PowerPoint displays each label on two lines (e.g., “5” on first line, “5%” on second line), but the PDF shows them as “5, 5%” on a single line.

Expected Behavior:
Data labels should preserve their multi-line formatting from PowerPoint:
5
5%

Actual Behavior:
Labels are concatenated with commas on a single line:
5, 5%

Attempted Workarounds:

  1. pdfOptions.setTextCompression(PdfTextCompression.None) - No effect
  2. Removing LoadOptions during presentation load - No effect
  3. Accessing label separator API (getSeparator/setSeparator) - Not available in Aspose.Slides 26.2

Technical Details:

  • Chart label structure verified: 5 DataLabel objects present
  • Label data is correct in the chart, only rendering is affected
  • This appears to be a chart label rendering issue similar to the Stacked Area Chart problem

@bcartermastercontrol,
Thank you for describing the issue. I need some time to investigate the issue. I will get back to you as soon as possible.

@bcartermastercontrol,
I have reproduced the problem where the axis labels and legend on the Stacked Area chart are not displayed, and the data labels on the Doughnut chart are displayed incorrectly (in a single line) when converting the presentation to PDF.

I also found that the 3D Bar chart on slide 7 is displayed incorrectly.

We have opened the following new ticket(s) in our internal issue tracking system and will deliver their fixes according to the terms mentioned in Free Support Policies.

Issue ID(s):
  SLIDESJAVA-39794: Axis labels and legend on a Stacked Area chart are not displayed when converting PPTX to PDF
  SLIDESJAVA-39795: Data labels on a Doughnut chart are displayed incorrectly when converting PPTX to PDF
  SLIDESJAVA-39796: A 3D Bar chart is displayed incorrectly when converting PPTX to PDF

You can obtain Paid Support Services if you need support on a priority basis, along with the direct access to our Paid Support management team.

The issues you found earlier (filed as SLIDESJAVA-39794,SLIDESJAVA-39795) have been resolved in Aspose.Slides for Java 26.4 (Maven, JAR).
You can check all fixes on the Release Notes page.
You can also find the latest version of our library on the Product Download page.