We use cookies to give you the best experience on our website. If you continue to browse, then you agree to our privacy policy and cookie policy.
Unfortunately, activation email could not send to your email. Please try again.

Unicode support in UWP PDF API

Thread ID:

Created:

Updated:

Platform:

Replies:

125118 Jul 22,2016 11:39 AM Jul 26,2016 07:48 AM UWP 1
loading
Tags: Pdf
Anuj
Asked On July 22, 2016 11:39 AM

We are trying to generate pdf in UWP application using PDF API.

And the need is that the Unicode characters should be able to be written to the PDF from the application. Can you please let us know whether multilingual Unicode characters are supported with PDF API from UWP.

 

Thanks in Advance for any inputs on this.


Chinnu Muniyappan [Syncfusion]
Replied On July 26, 2016 07:48 AM

Hi Anuj, 

Thank you for contacting Syncfusion support. 

PdfTrueTypeFont helps to rendering the Unicode characters in PDF document. Please find the below code snippet and sample for more details. 

            //Load the true type font. 
            Stream fontstream = typeof(MainPage).GetTypeInfo().Assembly.GetManifestResourceStream("App1.Assets.arial.ttf"); 
 
            //Create a new PDF document. 
            PdfDocument doc = new PdfDocument(); 
 
            //Add a new page. 
            PdfPage page = doc.Pages.Add(); 
 
            //Initialize the PDF true type font. 
            PdfFont font = new PdfTrueTypeFont(fontstream, 12, PdfFontStyle.Regular); 
 
            //Draw text. 
            page.Graphics.DrawString("hello world! @ # €", font, PdfBrushes.Black, new System.Drawing.PointF(0, 0)); 
 
Sample: 

Please let us know if you have any concern. 

Regards, 
Chinnu 


CONFIRMATION

This post will be permanently deleted. Are you sure you want to continue?

Sorry, An error occured while processing your request. Please try again later.

You are using an outdated version of Internet Explorer that may not display all features of this and other websites. Upgrade to Internet Explorer 8 or newer for a better experience.

;