How to use Special characters Use PurePDF?
Posted: Sat Jan 23, 2016 4:55 am
I want to write Some Special characters like "汉字".
my "PurePDF.pb" is here,could you give me some suggestion?
and
my "PurePDF.pb" is here,could you give me some suggestion?
Code: Select all
Procedure ipdf_SetFontData(FontName$,Style$,FontKey$)
Protected vCharWidth,vDefault,vStyle,vFound,Font,hDC,Mem,Len,j, fontNS$
AddElement(Fonts())
Fonts()\FontN = ListSize(Fonts())
Fonts()\FontKey$ = FontKey$
Fonts()\Style$ = Style$
vDefault = #False
fontNS$=UCase(FontName$+Style$)
Select fontNS$
Case "COURIER"
Fonts()\Name$ = #PDF_FONT_COURIER
vDefault = #True
Case "COURIERB"
Fonts()\Name$ = #PDF_FONT_COURIERB
vDefault = #True
Case "COURIERI"
Fonts()\Name$ = #PDF_FONT_COURIERI
vDefault = #True
Case "s"
Fonts()\Name$ = "s"
Restore s
Default ; Font is unknown = Font embedding
CompilerIf #PB_Compiler_OS=#PB_OS_Windows
vDefault = 3
CompilerElse
Fonts()\Name$ = #PDF_FONT_COURIER
vDefault = #True
.........
DataSection
S:
IncludeBinary "s.ttf"
.........