[Regression] No longer able to get/set correct Category axis ticklabel's font names with latest Aspose.Cells

Hi,

There was a regression that prevented us from upgrading Aspose.Cells v21.6 that has been fixed in v21.7. However, I have found another regression with the latest version that prevents me upgrading Aspose.Cells again.

I have noticed Aspose can no longer get the correct font name from the Category axis ticklabels, instead, it now gives incorrect names.

Code:

        var workbook = new Workbook(
            @".\BarChartReco.xlsx");
        var fontName = workbook.Worksheets[0].Charts[0].CategoryAxis.TickLabels.Font.Name;
        Console.WriteLine(fontName); // print 'Calibri' with Aspose.Cells 21.7, should be 'Generis Sans Com'

        var newWorkbook = new Workbook();
        newWorkbook.Copy(workbook);
        var fontNameCopied = newWorkbook.Worksheets[0].Charts[0].CategoryAxis.TickLabels.Font.Name;
        Console.WriteLine(fontNameCopied); // print '游ゴシック' with Aspose.Cells 21.7, should be 'Generis Sans Com'

        workbook.Worksheets[0].Charts[0].CategoryAxis.TickLabels.Font.Name = fontName;
        newWorkbook.Worksheets[0].Charts[0].CategoryAxis.TickLabels.Font.Name = fontNameCopied;

        // neither the resaved outputs has the correct 'Generic Sans Com' on the labels with Aspose.Cells 21.7
        workbook.Save(@".\resaved.xlsx");
        newWorkbook.Save(@".\copied.xlsx");

The font name got from either the original or the copied workbook is wrong (and different). Reassigning the font name and resaving the workbooks will result in wrong fonts in the resaved outputs. When I used Aspose.Cells 21.2.0, the issue didn’t happen.

I’ve attached the test files and outputs from the latest version 21.7.0 and 21.2.0 for your reference, where the result from 21.2.0 was correct and did not lead to unexpected font changes.

I also tried 21.6.0 and it was also producing the correct font, looks like the regression was introduced only since 21.7.0.

BarChartReco.zip (53.1 KB)

Could you please take a look at this regression? We haven’t been able to upgrade Aspose for the past 2 months due to regressions in recent upgrades.

Thanks,

@ServerSide527,
We have observed this issue and logged it in our database for further investigation. You will be notified here once any update is ready for sharing.

This issue is logged as:
CELLSNET-48386 - Wrong font name for category axis tick label font name

@ServerSide527

This is to inform you that we have fixed your issue now. We will soon provide you the fixed version after performing QA and incorporating other enhancements and fixes.

@ServerSide527,
Please try the latest fix .
Aspose.Cells21.7.5 For .Net2_AuthenticodeSigned.Zip (5.5 MB)
Aspose.Cells21.7.5 For .Net4.0.Zip (5.6 MB)
Aspose.Cells21.7.5 For .NetStandard20.Zip (5.6 MB)

The issues you have found earlier (filed as CELLSNET-48386) have been fixed in this update. This message was posted using Bugs notification tool by simon.zhao