Please also provide us sample Excel file as you have shown in your screenshots. It will help us look into your issue more closely and precisely and we will let you know any solution or workaround if possible. Thanks for your cooperation in this regard and have a good day.
I am unable to find two dropdowns as shown inside your GIF image. Please see the following screenshot and its comment for your reference. Let us know how can we enable Microsoft Excel to show two dropdowns like yours.
I’m using 2016 but this feature is available from Office 2010 (or even earlier). You need to add the language in File → Options → Add an Asian language and restart Office. (see my attached screenshot) image.png (68.5 KB)
This will then allow you to set more fonts depending on the text in the font settings for shapes. You can also visit the option by Start → All Programs → Microsoft Office → Office Tools → Language Preferences.
In fact this is supported and easily accessible in a Word document using Aspose.Words (Font.NameFarEast | Aspose.Words for .NET), so I’m wondering how to access it in Excel using Aspose.Cells.
We are afraid, it seems this feature is not available at the moment. We will need to look into it and implement it if possible. Once, we will have some fix or other news for you, we will update you asap.
This issue has been logged as New Feature as follows
CELLSNET-46058 - NameFarEast property needed in Aspose.Cells to set or access Asian/Latin font in chart legends or axis labels or textboxes etc.
Many thanks for the follow-up. In fact we considered it as an issue (not only a new feature) because it had impact on the existing image rendering feature. A chart with this kind of settings cannot be rendered properly to an image. Please find my test code below:
var workbook = new Workbook(@“test.xlsx”);
var options = new ImageOrPrintOptions
{
ImageFormat = ImageFormat.Emf,
ChartImageType = ImageFormat.Emf,
OnlyArea = false,
TextRenderingHint = TextRenderingHint.ClearTypeGridFit,
OnePagePerSheet = true
};
workbook.Worksheets[0].Charts[0].ToImage(@“testout.emf”, options);
I’ve attached the test files for your reference. As you can see if I copy/paste manually using Office the fonts are correct for both Asian and Latin characters, while if I used Aspose rendering the font were wrong for Asian text (Please see my screenshot).
I wanted to attach the font file (simkai.tff for KaiTI) for your convenience but the file size exceeded the limit, so if you still need the font file please let me know the alternative method to provide, otherwise you can use any Asian font to reproduce the issue.
Could you please check the attachments and see if the image rendering is a separate issue and could it be fixed?
You get rendering error because this feature i.e. CELLSNET-46058 is not supported at the moment. Once, this feature is implemented, we think, rendering problems of the chart should also be resolved.
However, we have tested your code and found the rendering problem in chart so we have recorded it as follows.
CELLSNET-46062 - Legend of Chart is not rendered properly because of Asian and Latin Characters
I believe we only need Aspose to access the properties that we can naturally access using Ms Excel, if there’s no equivalent in Ms Office (as in, they are hard-coded in Excel), we should be in the good place. We expect Aspose to behave the same as in office, but we don’t expect it to access anything beyond using Office manually.
I have noticed in 18.5 release note it mentioned “Adds TextOptions.FarEastName and TextOptions.LatinName properties”.
Regarding ticket 46058, I have tried myself and noticed I could indeed access the FarEast font and the Latin font. However I still couldn’t find a way to access these options in chart legend. Is there any update on this?
In fact the version I tested this morning was 18.5.1 already and all my conclusion and comments above were based on this version (including the alignment issue in rendering).
I’m looking forward this feature fully supported in charts and the image text alignment issue being corrected.
Thanks for looking into this. Looks like your pc didn’t have the Asian font I used installed. The font for Asian is KaiTi. (You can see the font in my screenshot is different from your screenshot)
KaiTi font is already installed on my machine and when I try to install the font that is downloaded from your location (URL), I get the message that this font is already installed on your machine.
Many thanks for checking this. I had a look again and think it might be the Latin font, not the Asian font. Please see my screenshot where you can see the Latin text in your output looks different than the one in Excel/my output: image.png (92.8 KB)
I’ve attached the font file for your convenience. Could you please kindly check?
Thanks for the further information and using Aspose.Cells.
We were able to observe the text alignment issue in the chart image and logged it in our database for investigation and for a fix. Once, we will have some news for you about it, we will update you in this topic.
This issue has been logged as
CELLSNET-46149 - Text Alignment Issue in the Chart Image
The issues you have found earlier (filed as CELLSNET-46149) have been fixed in Aspose.Cells for .NET v20.5. This message was posted using Bugs notification tool by Amjad_Sahi