I'm trying to set an image in this RTF doc to display in a fixed
position in a "square" layout. How do I set an image's layout to do
this? The Image class doesn't seem to have this alignment/layout
value.
RtfDocument doc = new RtfDocument();
float scale = 50;
Image logo = Image.getInstance("webapp/images/logo.gif");
logo.scalePercent(scale);
logo.setAlignment(Image.UNDERLYING);
logo.setAbsolutePosition(0,0);
doc.add(logo);
Thanks, Kianoosh
btw, the resulting document shows the image scale as something like
67%, not 50% that I set here. So I'm not sure if I'm even using that
API correctly either.
-------------------------------------------------------------------------
This SF.Net email is sponsored by the Moblin Your Move Developer's challenge
Build the coolest Linux based applications with Moblin SDK & win great prizes
Grand prize is a trip for two to an Open Source event anywhere in the world
http://moblin-contest.org/redirect.php?banner_id=100&url=/
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Do you like iText?
Buy the iText book: http://www.1t3xt.com/docs/book.php
Or leave a tip: https://tipit.to/itexttipjar