I believe, not sure, that BufferedImage aren't supported in RTF, and so...
Raffaele
-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Behalf Of jgmaux
Sent: giovedì 4 gennaio 2007 12.45
To: Post all your questions about iText here
Subject: Re: [iText-questions] RTF: scaleToFit() and scalePercent() of
Imageclass work for RTF?
Thanks,
I have an alternative solution....
(Sorry, my english language is very bad, because I 'am from Spain..)
Using java.awt.image.BufferedImage and related javax.imageio.ImageIO,
java.awt.image.AffineTransformOp, etc.....
public static BufferedImage scale(double scale, BufferedImage srcImg)
{
if (scale == 1 )
{
return srcImg;
}
AffineTransformOp op = new
AffineTransformOp(AffineTransform.getScaleInstance(scale, scale), null);
return op.filter(srcImg, null);
}
After scaled buffered image:
java.awt.Image awt_image =
Toolkit.getDefaultToolkit().createImage(buffered_image.getSource());
com.lowagie.text.Image image = Image.getInstance(awt_image,null);
crash!!!!! I get an OuOfMemoryError:
java.lang.OutOfMemoryError: Java heap space!!!!
Note: original image size = 1Mb.
¿Any Bug (com.lowagie.text.Image Image.getInstance(java.awt.Image)?
Thanks,
GAMBELLI Raffaele wrote:
Hi!
Mark Hall wrote to me this:
While, unfortunaly, image scaling in RTF Document viewed by Word 2000
continues to not working.
That is a nuisance. Unfortunately I won't be able to do any more iText work
until the end of January. The scaling issue stays open and I'll contact you
again when I've got a new version. I've only got Word XP, so I can't actually
test this bug and I'll send you a new jar, when I've found time to create
another fix.
Greetings,
Mark
Best regards.
Raffaele
-----Original Message-----
From: [EMAIL PROTECTED]
[ mailto:[EMAIL PROTECTED] Behalf Of Bruno
Lowagie
Sent: giovedì 4 gennaio 2007 10.08
To: Post all your questions about iText here
Subject: Re: [iText-questions] RTF: scaleToFit() and scalePercent() of
Imageclass work for RTF?
GAMBELLI Raffaele wrote:
However, it is a bug and I don't think Itext team will fix it soon...
I followed an earlier discussion on this,
and understood it was a Word 2000 bug.
It's not up to the iText team to fix bugs in Word.
However I could have misunderstood the discussion.
If so: please provide more accurate information
to the mailing list. Something we can reproduce
with Wordpad and/or a more recent Word version.
best regards,
Bruno
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php
<http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV>
&p=sourceforge&CID=DEVDEV
_______________________________________________
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/
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php
<http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV>
&p=sourceforge&CID=DEVDEV
_______________________________________________
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/
-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
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/