[latex3-commits] [git/LaTeX3-latex3-pdfresources] textfields: some tests with chinese (cc7cfd3)

Ulrike Fischer fischer at troubleshooting-tex.de
Mon Apr 19 19:23:11 CEST 2021


Repository : https://github.com/latex3/pdfresources
On branch  : textfields
Link       : https://github.com/latex3/pdfresources/commit/cc7cfd345c20c47f41157ce29b52b1b5e7724195

>---------------------------------------------------------------

commit cc7cfd345c20c47f41157ce29b52b1b5e7724195
Author: Ulrike Fischer <fischer at troubleshooting-tex.de>
Date:   Mon Apr 19 19:23:11 2021 +0200

    some tests with chinese


>---------------------------------------------------------------

cc7cfd345c20c47f41157ce29b52b1b5e7724195
 experiments/testfield1.tex | 30 +++++++++++++++++++++++++-----
 1 file changed, 25 insertions(+), 5 deletions(-)

diff --git a/experiments/testfield1.tex b/experiments/testfield1.tex
index c70a477..0b68d71 100644
--- a/experiments/testfield1.tex
+++ b/experiments/testfield1.tex
@@ -7,9 +7,9 @@
 \usepackage{hyperref}
 
 \ExplSyntaxOn
-\pdf_object_new:nn {Comic}{dict}
-\pdf_object_write:nn {Comic}{
-/Type /Font /Subtype /Type0 /Encoding /Identity-H /BaseFont /ComicSansMS}
+%\pdf_object_new:nn {Comic}{dict}
+%\pdf_object_write:nn {Comic}{
+%/Type /Font /Subtype /Type0 /Encoding /Identity-H /BaseFont /ComicSansMS}
 
 % color command, adapted from hgeneric, should perhaps be defined somewhere else
 \str_new:N  \l_pdffield_colormodel_str
@@ -414,9 +414,9 @@
 %\iftutex
 %\setmainfont{AdobeThai-Regular.otf}[Path={C:/Program Files (x86)/Adobe/Acrobat DC/Resource/Font/}]
 %\setmainfont{Mukta} %marathi, worked,
-% \setmainfont{Noto Sans CJK TC} %breaks, adobe crash, browser doesn't show the glyphs.
+\setmainfont{Noto Sans CJK TC} %breaks, adobe crash, browser doesn't show the glyphs.
 %\setsansfont{comicsansms} %works
-\setsansfont{comicsansms}
+%\setsansfont{comicsansms}
 %\setsansfont{arial}
 %\setsansfont{texgyreheros}
 %\setmainfont{calibri} % doesn't work /CIDFontType2
@@ -431,7 +431,27 @@
 %\setmainfont{lmroman10-regular.otf} %replaced by arial CIDFontType0
 \begin{document}
 \ExplSyntaxOn
+{
+\fontspec{Mukta}  \__pdffield_setup_currentfont:n {mukta}
+मध्ये रिलीज झालेल्या
+\int_step_inline:nnn{"800}{"A00}
+         {
+           \directlua{pdf.includechar(font.current(),"0x\int_to_hex:n{#1}")}
+         }
+ 
+\__pdffield_text_add:n {width=4cm,height=0.5cm,name=default}
+}
 
+\par \__pdffield_setup_currentfont:n {chinese}
+\int_step_inline:nnn{"6000}{"6500}
+         {
+           \directlua{pdf.includechar(font.current(),"0x\int_to_hex:n{#1}")}
+         }
+提 
+\__pdffield_text_add:n {width=4cm,height=0.5cm,name=chinese}
+
+\ExplSyntaxOff
+\end{document}
 avb \sffamily abc
 \bitset_set_true:Nn  \l__pdffield_Ff_bitset {DoNotScroll}
 \__pdffield_text_add:n {width=4cm,name=default,height=\baselineskip}





More information about the latex3-commits mailing list.