Print Page | Close Window

Text Form Field - Error displaying text in hebrew

Printed From: Debenu Quick PDF Library - PDF SDK Community Forum
Category: For Users of the Library
Forum Name: I need help - I can help
Forum Description: Problems and solutions while programming with the Debenu Quick PDF Library and Debenu PDF Viewer SDK
URL: http://www.quickpdf.org/forum/forum_posts.asp?TID=3433
Printed Date: 28 Apr 24 at 7:48AM
Software Version: Web Wiz Forums 11.01 - http://www.webwizforums.com


Topic: Text Form Field - Error displaying text in hebrew
Posted By: shlomir
Subject: Text Form Field - Error displaying text in hebrew
Date Posted: 17 Jan 17 at 12:35PM
Hi,

I created text field form using debenu, the entered text should be in hebrew or in english.
the problem is that the created field is displaying the entered text only in english, meaning 
that if I enter text in hebrew and focus on sometihng else inside the document (other field for example)
 - it doesn't display the text.
If I click again on the field it shows the entered text.

I created another field using acrobat reader pro with the same settings - and it does display the text correctly:  http://www.dropbox.com/s/i7hkaiqckhcu7up/pdf.pdf?dl=0" rel="nofollow - https://www.dropbox.com/s/i7hkaiqckhcu7up/pdf.pdf?dl=0

the code for the field:

pdflib.SelectPage(sigPosition.Page);
pdflib.SetOrigin(1);
pdflib.SetNeedAppearances(1);
sigIndex = pdflib.NewFormField(sigPosition.Name, sigPosition.Type);
pdflib.SetFormFieldAlignment(sigIndex,2);
pdflib.SaveToFile(tmpFileName);

Thanks in advance
Shlomi



Replies:
Posted By: Ingo
Date Posted: 17 Jan 17 at 8:19PM
Hi Shlomir,

the actual QuickPDF-library deals with unicode.
If your programming language deals with unicode there shouldn't be a problem.
A problem can be the selected font for your text: Not all fonts supports unicode.
Additionally you can try the "advanced search" option (top, right here on the page) with "hebrew" or "arabic" in the message body.

Cheers and welcome here,
Ingo



-------------
Cheers,
Ingo



Posted By: shlomir
Date Posted: 18 Jan 17 at 11:11AM
Thank you for your answer!

I'm using C# .net 4.6.1 - and it supports unicode.

Well the thing is that the field is showing correctly if the field contains only a single letter (Hebrew letter)
Two letters and more and it doesn't display the text at all (not dots or anything)
In english it works just fine.

I tried changing the font to the one I used in Acrobat reader Pro - no success.

Any Ideas?

Shlomi.


Posted By: Ingo
Date Posted: 18 Jan 17 at 9:20PM
Hi Shlomir,

here a few links to dig deeper:
http://www.debenu.com/kb/appearance-streams-pdf-form-fields/
http://www.debenu.com/kb/create-pdf-form-fields-programmatically/
http://www.quickpdf.org/forum/new-user-vb6-with-quickpdf_topic1793.html

Please read in the developer guide starting at page 34:
http://www.debenu.com/docs/pdf_library_developer_guide/foxit_quick_pdf_library_13_developer_guide.pdf

Perhaps your problem have to do with the "right alignment"? Try "left".
Perhaps your problem has to do with the missing "SetFormFieldBounds"? How long is your formfield?



-------------
Cheers,
Ingo



Posted By: shlomir
Date Posted: 19 Jan 17 at 2:46PM
Thank you very much!!

UpdateAppearanceStream solved
the problem.

Thanks again,
Shlomi



Print Page | Close Window

Forum Software by Web Wiz Forums® version 11.01 - http://www.webwizforums.com
Copyright ©2001-2014 Web Wiz Ltd. - http://www.webwiz.co.uk