I thought I already answered this. There is NOTHING in iText that will enable
you to convert a non-PDF/-compliant PDF into one that is.
That is a LOT of very low level PDF processing that simply isn’t available in
iText. You could, possibly, write such code on top of iText – but it will
require deep(!) understanding of PDF and PDF/X. I would give yourself about 6
months of development…at least.
Leonard
From: Sumetha [mailto:[email protected]]
Sent: Wednesday, April 14, 2010 8:23 AM
To: Post all your questions about iText here
Subject: Re: [iText-questions] Merge PDF X-1a Issue – Need Help
Thank you iText team for the reply, i really appreciate it. If i comment
setfullcompression, its converting to 1.3 version. Now getting another issue
we need to set the font and CMYK color to comply with X-1a format. Is there any
option available for pdfcopy to set this. Below is the one for pdfwriter, could
you please guide me if there is way to set this up for pdfcopy.
Thank you for your time and help.
PDFWriter Option: This works with pdfwriter
BaseFont bf = BaseFont.CreateFont(
Path.Combine(
(String)Microsoft.Win32.Registry.CurrentUser.
OpenSubKey("Software").
OpenSubKey("Microsoft").
OpenSubKey("Windows").
OpenSubKey("CurrentVersion").
OpenSubKey("Explorer").
OpenSubKey("Shell Folders").
GetValue("Fonts"),
"arial.ttf"),
"winansi", true);
document.Add(new Paragraph("This is a " + type + " document", new Font(bf, 16,
0, new CMYKColor(255, 255, 0, 0))));
PDFCopy how to set the above base font and CMYK,
pdfDoc = New iTextSharp.text.Document(pdfReader.GetPageSizeWithRotation(1))
pdfWriter = New PdfCopy(pdfDoc, New System.IO.FileStream(PDFOutputFile,
IO.FileMode.Create))
pdfWriter.SetPdfVersion(pdfVersion)
Dim bf As iTextSharp.text.pdf.BaseFont =
iTextSharp.text.pdf.BaseFont.CreateFont(Path.Combine(DirectCast(Microsoft.Win32.Registry.CurrentUser.OpenSubKey("Software").OpenSubKey("Microsoft").OpenSubKey("Windows").OpenSubKey("CurrentVersion").OpenSubKey("Explorer").OpenSubKey("Shell
Folders").GetValue("Fonts"), String), "arial.ttf"), "winansi", True)
pdfDoc.Add(CType(bf, IElement)) -- This is not working
--- On Mon, 4/12/10, 1T3XT info <[email protected]> wrote:
From: 1T3XT info <[email protected]>
Subject: Re: [iText-questions] Merge PDF X-1a Issue – Need Help
To: "Post all your questions about iText here"
<[email protected]>
Date: Monday, April 12, 2010, 9:57 AM
Sumetha wrote:
> When we merge its changing the version of PDF document to 1.5 pdf
> version, even though property is set to 1.3 version with X-1a conformance.
That's normal:
> pdfWriter.SetFullCompression()
"Full compression" was introduced in PDF 1.5.
A PDF that is "fully compressed" can't be read by viewer
that only support PDF 1.4 or earlier, therefore iText
RIGHTFULLY changes the version number.
--
This answer is provided by 1T3XT BVBA
http://www.1t3xt.com/ - http://www.1t3xt.info<http://www.1t3xt.info/>
------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
iText-questions mailing list
[email protected]<http://us.mc1107.mail.yahoo.com/mc/[email protected]>
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://www.itextpdf.com/book/
Check the site with examples before you ask questions:
http://www.1t3xt.info/examples/
You can also search the keywords list: http://1t3xt.info/tutorials/keywords/
------------------------------------------------------------------------------
Download Intel® Parallel Studio Eval
Try the new software tools for yourself. Speed compiling, find bugs
proactively, and fine-tune applications for parallel performance.
See why Intel Parallel Studio got high marks during beta.
http://p.sf.net/sfu/intel-sw-dev
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://www.itextpdf.com/book/
Check the site with examples before you ask questions:
http://www.1t3xt.info/examples/
You can also search the keywords list: http://1t3xt.info/tutorials/keywords/