So you are saying that the marketing department wants the Optima font but is
willing to have a pdf with a lousy raster quality?
There are another options:

- use a true type Optima. iText will subset it.

- create two versions of the document: one with Optima and another with the
built-in fonts with the same metrics as Optima.

Best Regards,
Paulo Soares

> -----Original Message-----
> From: [EMAIL PROTECTED]
> [SMTP:[EMAIL PROTECTED]
> Sent: Wednesday, June 25, 2003 8:51
> To:   [EMAIL PROTECTED]
> Cc:   [EMAIL PROTECTED]
> Subject:      RE: [iText-questions] reduce size of PDFs with huge fonts
> 
> 
> 
> We are using an Optima type 1 font (normal,bold,italic).
> This is a REQUIREMENT of our marketing department.
> So, we can't use a built-in font.
> The tests we have made show that we get from a 3K Text
> with Optima font (150K), a PDF TIFF Image 35 K large.
> But we would like to make this with iText API if possible.
> 
> Best regards,
> 
> Fabrice DUERMAEL
> 
> 
> |---------+---------------------------------------->
> |         |          [EMAIL PROTECTED]           |
> |         | Internet                               |
> |         |                                        |
> |         |          24/06/03 18:27                |
> |         |                                        |
> |---------+---------------------------------------->
>  
> >-------------------------------------------------------------------------
> -----------------------------------------|
>   |
> |
>   |     Pour:       Fabrice DUERMAEL, itext-questions
> |
>   |     cc:
> |
>   |     ccc:
> |
>   |     Objet:      RE: [iText-questions] reduce size of PDFs with huge
> fonts                                        |
>  
> >-------------------------------------------------------------------------
> -----------------------------------------|
> 
> 
> 
> 
> This 150K are with TT fonts? If you need small document just use the
> built-in fonts.
> You'll need other tool, such as ghostscript, to convert the pdf to an
> image
> but I have my doubts about the size improvement.
> 
> Best Regards,
> Paulo Soares
> 
> > -----Original Message-----
> > From:            [EMAIL PROTECTED]
> > [SMTP:[EMAIL PROTECTED]
> > Sent:            Tuesday, June 24, 2003 17:19
> > To:        [EMAIL PROTECTED]
> > Subject:         [iText-questions] reduce size of PDFs with huge fonts
> >
> > Hello,
> >
> > We are in context of PDF text documents sent to extranet with servlets.
> > One
> > constraint is to download VERY
> > QUICKLY these documents. The problem is that text is written in huge
> fonts
> > (150 K) and it takes too much
> > time to download: 50 seconds (and the extranet users has not the font on
> > their workstation installed).
> > We would like something like 5 seconds.
> >
> > One solution would be to transform  in TIF the PDF Text with embedded
> huge
> > fonts,  and wrap it in PDF Image.
> >
> > Here is my code, but rawData is null !
> >
> > My question would be how to transform PDF text pages that are read into
> > images (RenderedImage for instance).
> >
> >
> >
> >             PdfReader   reader = new PdfReader((String) fileName);
> >
> >             PdfStamper stamper = new PdfStamper(reader,new
> > FileOutputStream
> > ("docs/toto"));
> >
> >
> >             PdfImportedPage page = stamper.getImportedPage(reader, 1);
> >             ImgTemplate pdfImage = (ImgTemplate)Image.getInstance(page);
> >
> >
> >                   byte[] rawData = pdfImage.rawData(); //
> > <================= IS NULL !!!
> >
> >
> >
> >                   ByteArrayInputStream bais = new
> > ByteArrayInputStream(rawData);
> >
> >                   ImageInputStream iis =
> > ImageIO.createImageInputStream(bais);
> >                   BufferedImage bi = ImageIO.read(bais);
> >
> >
> >                   TIFFEncodeParam paramOut = new TIFFEncodeParam();
> >
> > paramOut.setCompression(TIFFEncodeParam.COMPRESSION_GROUP4);
> >
> >                   ImageEncoder encoder =
> >                         ImageCodec.createImageEncoder("tiff",
> > outputStream,
> > paramOut);
> >
> >                   encoder.encode(bi);
> >
> > Perhaps are there better alternatives.
> > Have you got any hints ?
> >
> >
> > Best regards,
> >
> > Fabrice DUERMAEL
> >
> >
> >
> >
> > **********************************************************************
> > L'integrite de ce message n'etant pas assuree sur Internet,
> > BNP Paribas Assurance ne peut etre tenu responsable de son contenu.
> > Si vous n'etes pas destinataire de ce message confidentiel,
> > Merci de le detruire et d'avertir immediatement l'expediteur.
> >
> > The integrity of this message cannot be guaranteed on the
> > Internet. BNP Paribas Assurance can not therefore be considered
> > responsible
> > for the contents.
> > If you are not the intended recipient of this confidential message,
> > then please delete it and notify immediately the sender.
> >
> > **********************************************************************
> >
> >
> >
> > -------------------------------------------------------
> > This SF.Net email is sponsored by: INetU
> > Attention Web Developers & Consultants: Become An INetU Hosting Partner.
> > Refer Dedicated Servers. We Manage Them. You Get 10% Monthly Commission!
> > INetU Dedicated Managed Hosting http://www.inetu.net/partner/index.php
> > _______________________________________________
> > iText-questions mailing list
> > [EMAIL PROTECTED]
> > https://lists.sourceforge.net/lists/listinfo/itext-questions
> 
> 
> 
> 
> 
> 
> 
> **********************************************************************
> L'integrite de ce message n'etant pas assuree sur Internet,
> BNP Paribas Assurance ne peut etre tenu responsable de son contenu.
> Si vous n'etes pas destinataire de ce message confidentiel,
> Merci de le detruire et d'avertir immediatement l'expediteur.
> 
> The integrity of this message cannot be guaranteed on the
> Internet. BNP Paribas Assurance can not therefore be considered
> responsible 
> for the contents. 
> If you are not the intended recipient of this confidential message,
> then please delete it and notify immediately the sender.
> 
> **********************************************************************


-------------------------------------------------------
This SF.Net email is sponsored by: INetU
Attention Web Developers & Consultants: Become An INetU Hosting Partner.
Refer Dedicated Servers. We Manage Them. You Get 10% Monthly Commission!
INetU Dedicated Managed Hosting http://www.inetu.net/partner/index.php
_______________________________________________
iText-questions mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/itext-questions

Reply via email to