Somehow there was a formatting problem with my thread. Here is it again:

Hi all,

I'd like to put paragraphs in columns and add images in between so that they
don't overlap but follow each other. As it turns out, I can do this but
can't scale the image at the same time.To be more specific:

When I add images 

Image img = Image.getInstance(imgFile);

and when I am in composite mode, which means I work with ColumnText and add
objects (paragraphs, images, ...) by

ct.AddElement(p);
ct.AddElement(img);
ct.AddElement(p);

my image gets blown up to the size set previously by

ct.setSimplaColumn(left, bottom, right, top);

and all attempts to scale the image like

img.ScalePercent(100, 50);

before adding it are just IGNORED. The Paragraph p followed by the image is
placed after the image, not over the image, as want it.

However, when I want to scale the image, I have to add it by

ct.AddParagraph(new Chunk(img, 0, 0));

Then the image is not blown up as above and I am even able to scale the
image (all these functions work), however the image is placed over the
existing text and the next paragraph is likewise not placed below the image
but over it. Hence the yLine is not updated after image insertion.

So it seems that I can't have both worlds, what would mean: Being able to
scale the image und at the same time place it between paragraphs without
adjusting the yLine or by other absolute positioning means.

Am I missing a point or are my observations correct ?

I'd appreciate any comments.

PS: I'm using iTextSharp but I don't think that this causes a the problem
here.








-- 
View this message in context: 
http://itext-general.2136553.n4.nabble.com/Image-scaling-not-possible-in-some-cases-tp2313229p2313231.html
Sent from the iText - General mailing list archive at Nabble.com.

------------------------------------------------------------------------------
The Palm PDK Hot Apps Program offers developers who use the
Plug-In Development Kit to bring their C/C++ apps to Palm for a share
of $1 Million in cash or HP Products. Visit us here for more details:
http://p.sf.net/sfu/dev2dev-palm
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
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/

Reply via email to