HYGoThic-Medium is not a fixed width font. However you can use the characters at \uff01 (Fullwidth Forms) that are the roman characters that have the same width as the hangul characters.
Paulo ----- Original Message ----- From: "Praneeth P.V." <[EMAIL PROTECTED]> To: <[email protected]> Sent: Sunday, May 06, 2007 7:47 PM Subject: [iText-questions] Using CJK Font > Hi, > > I have just started using iText. I find it really useful. However, am > facing > an issue. Here is my problem: > > 1) I am generating a PDF containing only characters from ASCII set. I use > COURIER Font with style NORMAL. This is how i set it. > Font asciiFont = new Font(Font.COURIER,6,Font.NORMAL); > When i use this font, the pdf is generated as desired. I have attached the > file (Ascii.pdf) > 2) Now i modify the content slightly. I change 'Activity' to > '테스트ivity'. > (Replacing the first 3 letters with Korean characters). I generate a > second > PDF using CJK Fonts and add the modified content. I have attached the > second > pdf too. (Unicode.pdf) > The Korean characters are displayed correctly.But now the style is > lost.Itis clearly evident if you compare both the pdfs. I want the > width of each > line to be uniform. However, on using CJK Font, the width seems to have > changed and it is different for different lines. > Each line in the pdfs is a 'Paragraph' with 'Chunk's. > This is the code for creating CJK Font. > BaseFont unicodeFont = BaseFont.createFont > ("HYGoThic-Medium","UniKS-UCS2-H",true); > Font cjkFont = new Font(unicodeFont,6); > > As i told, am new to this. How do i resolve this style issue?please let me > know. > > Thanks, > Praneeth > > P.S.:My earlier message with the same subject is incomplete.I accidentally > sent it.Sorry for that. ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ iText-questions mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/itext-questions Buy the iText book: http://itext.ugent.be/itext-in-action/
