> -----Original Message-----
> From: Ray Chan [SMTP:[EMAIL PROTECTED]]
> Sent: Thursday, January 30, 2003 20:15
> To: [EMAIL PROTECTED]; [EMAIL PROTECTED]
> Subject: RE: [iText-questions] How to convert extended font to CID?
>
> Thank you for you answer and effort for improving itext
>
> I had tried the following...
>
> Case 1:
> In win2k (with hkscsfonts patch, arcobat reader 5.0 installed),
> I can successfully create big5 + hkscs font in pdf using:
> BaseFont bf = BaseFont.createFont("MSungStd-Light", "UniCNS-UCS2-V",
> BaseFont.NOT_EMBEDDED);
> in vert_cjk.java. The correct result is shown in the first page but not in
>
> the second
>
You probably have in the second page the specific HK characters that
don't exist in Unicode 16bit. It doesn't stop working by changing pages!
> Case 2:
> If I use:
> BaseFont bf = BaseFont.createFont("MSungStd-Light", "Identity-V",
> BaseFont.NOT_EMBEDDED);
> Then the pdf failed to show the right characters.
> Maybe this is because of the unavailable function
>
The bi5 must first pass through the function and the result is used
to write in this encoding.
> Case 3:
> Since the first case lead to the success, I copy hkscsm3u.ttf from windows
>
> to linux and create font by
> BaseFont bf = BaseFont.createFont("\somepath\hkscsm3u.ttf",
> "UniCNS-UCS2-V",
> BaseFont.NOT_EMBEDDED);
> However, only the hongkong font is shown correctly, other big5 fonts
> disappeared (in the first page of vert_cjk.pdf)
>
There's some confusion. That encoding doesn't work with ttf and the
font that Acrobat uses is most probably not that one. For this to work the
encoding should be Identity-V and you must have another mapping from HK to
the private Unicode space in that font where the special characters are.
Case 2 will work in windows and maybe in linux. Case 3 will work
everywhere because the font will be embedded but you must know the mapping
from HK to the private use area in that particular font.
Best Regards,
Paulo Soares
> For all the 3 cases I had tried above,
> the second page of output pdf either show the wrong characters or no
> characters appeared
>
> Despite of that, I just want to ask is there any way now lead to the
> success
> by configuring linux or something similar to case 1
>
>
>
>
>
>
> >From: Paulo Soares <[EMAIL PROTECTED]>
> >To: 'Ray Chan' <[EMAIL PROTECTED]>,
> >[EMAIL PROTECTED]
> >Subject: RE: [iText-questions] How to convert extended font to CID?
> >Date: Thu, 30 Jan 2003 18:27:37 -0000
> >
> >What I'm going to say is valid for Acrobat in windows and you should
> start
> >there. After working there, worry about xpdf.
> >Acrobat has a single way to address the glyphs in the fonts with the CID
> >number. This is the index to the glyph.
> >There are a number of mappings to simplify our life. One of them is
> >UniCNS-UCS2-V that maps Unicode (16 bits) to CID and doesn't have all the
> >characters. Other encoding is HKscs-B5-H that has the mapping from the
> >extended big5 to the CID. This last mapping is not directly supported in
> >iText because big5 has 8 and 16 bit characters and that wouldn't fit in
> the
> >text strings used in Java. What is needed is a function that converts the
> >big5 from a byte array to a CID in a string that can then be used with
> the
> >font:
> >
> >BaseFont bfChinese = BaseFont.createFont("MSungStd-Light",
> >BaseFont.IDENTITY_H, BaseFont.NOT_EMBEDDED);
> >
> >This function should exist in iText and if you care to wait a couple of
> >weeks it will be there, together with other encodings.
> >
> >Best Regards,
> >Paulo Soares
> >
> >
> >
> > > -----Original Message-----
> > > From: Ray Chan [SMTP:[EMAIL PROTECTED]]
> > > Sent: Thursday, January 30, 2003 17:24
> > > To: [EMAIL PROTECTED]
> > > Subject: [iText-questions] How to convert extended font to CID?
> > >
> > > Could anyone teach me how to convert big5 extended
> > > characters(hkscs2001-->ISO/IEC 10646-2:2001) to CID codes (e.g. in
> java
> > > program) so that I can generate and allow all big5 fonts as well as
> >hkscs
> > > fonts (in \u format) to be displayed in the output pdf under redhat8.
> > >
> > > I got:
> > > -big5-iso.txt (conversion table from HK government)
> > > -5080.Adobe-CNS1-4.pdf (contains many many ... characters and their
> cid)
> > > -HKscs-B5-H (from xpdf chinese patch)
> > > -vert_cjk2.java from paulo
> > > inside it I had try to create font using:
> > > BaseFont bfChinese = BaseFont.createFont("MSungStd-Light",
> > > "UniCNS-UCS2-V",
> > > BaseFont.NOT_EMBEDDED);
> > > it failed to display the desired characters because of incorrect cid
> > > conversion
> > >
> > >
> > > Any help would be appreciated.
> > >
> > >
> > >
> > > _________________________________________________________________
> > > The new MSN 8: smart spam protection and 2 months FREE*
> > > http://join.msn.com/?page=features/junkmail
> > >
> > >
> > >
> > > -------------------------------------------------------
> > > This SF.NET email is sponsored by:
> > > SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
> > > http://www.vasoftware.com
> > > _______________________________________________
> > > iText-questions mailing list
> > > [EMAIL PROTECTED]
> > > https://lists.sourceforge.net/lists/listinfo/itext-questions
>
>
> _________________________________________________________________
> STOP MORE SPAM with the new MSN 8 and get 2 months FREE*
> http://join.msn.com/?page=features/junkmail
-------------------------------------------------------
This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
http://www.vasoftware.com
_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions