Does the PDF creation supports Hebrew text?

when I used your demo I've noticed that the PDF does not show test in Hebrew. am I missing anything?

2 Replies

SL Sowmiya Loganathan Syncfusion Team January 25, 2018 10:24 AM UTC

Hi Roi, 

Currently we do not have support to “Draw RTL text in the PDF document in Xamarin Forms”. We have added to this in our feature request list and will be implemented in any of our release.   
 
Please find the our support list in the below link:  

Please let us know if you have any further assistance on this. 

Regards, 
Sowmiya L 



SK Sasi Kumar Sekar Syncfusion Team June 26, 2018 07:26 AM UTC

Hi Roi, 
  
We are glad to announce that our Essential Studio 2018 Volume 2 Release v16.2.0.41 is rolled out and is available for download under the following link. 
 
 
We have implemented the feature with “Need to add support for Draw RTL text in Xamarin Platform” in this release. Please refer the below code snippet for further details. 
 
           //Create a new PDF document.  
            PdfDocument document = new PdfDocument(); 
            //Add a new PDF page. 
            PdfPage page = document.Pages.Add();  
            //Create new PdfTrueTypeFont instance. 
            //Load the font from assets. 
            Stream fontStream = typeof(App).GetTypeInfo(). 
            Assembly.GetManifestResourceStream 
            ("RTLDemo.Assets.arial.ttf"); PdfTrueTypeFont font = new PdfTrueTypeFont(fontStream, 12); 
            //Create a PdfStringFormat. 
            PdfStringFormat format = new PdfStringFormat(); 
            //Set text direction.  
            format.TextDirection = PdfTextDirection.RightToLeft; 
            //Set text alignment.  
            format.Alignment = PdfTextAlignment.Right; 
            //Draw text to the PDF document. 
            page.Graphics.DrawString("بالعالم مرحبا !",font, PdfBrushes.Black, Syncfusion.Drawing.PointF.Empty, format); 
            //Save document. 
            MemoryStream ms = new MemoryStream(); 
            document.Save(ms); 
            //Close the PdfDocument instance. 
            document.Close(true); 
 
 
We thank you for your support and appreciate your patience in waiting for this release. Please get in touch with us if you would require any further assistance. 
 
Regards,            
Sasi Kumar S. 


Loader.
Up arrow icon