Hi André,

Several considerations here:
- you're using a com.lowagie package. The last version containing these was
released in July 2009. This means you are using a version that is at least
4 years old. Many improvements have been added to iText since then, as well
as many bug fixes. You might consider upgrading.
- The mailing list post you are using as a reference is 11 years old. Two
books have been published since then.

And in the case this is not the reason of your issue right now, it'll be a
source of trouble later anyway.

Best regards,
alexis



On 3 October 2013 21:32, André Fróes <arfmor...@gmail.com> wrote:

> Hello everyone, I am trying to create a font from a byte[] but it seems
> that it gets corrupted.
> I followed this entry:
> http://www.mail-archive.com/itext-questions@lists.sourceforge.net/msg02588.html
>
> but when I try to use it, in the moment of creation, i get this message:
> com.lowagie.text.DocumentException: Table 'name' does not exist in
> wingding.ttf
>
> Here is my code:
> BaseFont baseWing = BaseFont.createFont("wingding.ttf", BaseFont.CP1250,
> true, true, checkImages.get(0).getFileData(), null);
> Font wingFont = new Font(baseWing);
>
> in the first line, it breaks, doesnt even get to set the basefont to
> wingFont.
> I'd solved this problem earlier when loading from within a package
> locally, but now, I need to use the font comming from a  byte[].
>
> checkImages.get(0).getFileData() is a byte[] that contains the
> wingding.ttf in it, when I debug I can see the bytes there without any
> problem.
>
> Any help is appreciated :D
>
>
> ------------------------------------------------------------------------------
> October Webinars: Code for Performance
> Free Intel webinars can help you accelerate application performance.
> Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most
> from
> the latest Intel processors and coprocessors. See abstracts and register >
> http://pubads.g.doubleclick.net/gampad/clk?id=60134791&iu=/4140/ostg.clktrk
> _______________________________________________
> iText-questions mailing list
> iText-questions@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/itext-questions
>
> iText(R) is a registered trademark of 1T3XT BVBA.
> Many questions posted to this list can (and will) be answered with a
> reference to the iText book: http://www.itextpdf.com/book/
> Please check the keywords list before you ask for examples:
> http://itextpdf.com/themes/keywords.php
>
------------------------------------------------------------------------------
October Webinars: Code for Performance
Free Intel webinars can help you accelerate application performance.
Explore tips for MPI, OpenMP, advanced profiling, and more. Get the most from 
the latest Intel processors and coprocessors. See abstracts and register >
http://pubads.g.doubleclick.net/gampad/clk?id=60134791&iu=/4140/ostg.clktrk
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions

iText(R) is a registered trademark of 1T3XT BVBA.
Many questions posted to this list can (and will) be answered with a reference 
to the iText book: http://www.itextpdf.com/book/
Please check the keywords list before you ask for examples: 
http://itextpdf.com/themes/keywords.php

Reply via email to