IdentationLeft works for me, but in this case I would need IdentationUp,
but this don't exist
SpacingBefore would be good for me, but it don't works.
In the meantime I used this:
I printed a blank paragraph first
prf = New Paragraph(" ", fnt)
Doc.Add(prf)
and then printed my actual paragraph, with SapacingBefore=100
prf = New Paragraph(x, fnt)
prf.SpacingBefore = 100
prf.set()
Doc.Add(prf)
I am sure this way is not fine, but runs well
How would be your code if you need to begin printing a paragraph at
position 620?
2013/8/15 Leo Donahue - RDSA IT <leodona...@mail.maricopa.gov>
> From: SALAZAR, DANTE [mailto:digitron...@cwpanama.net]
> Subject: [iText-questions] Vertical Position of the first paragraph
>
> How can I set the vertical position of the first paragraph?
> I can use GetVerticalPosition and SpacingBefore to set the vertical
> position of successive paragraphs, but not for the first one.
>
> ------------------------------------------------------------------------------
> From: Leo Donahue - RDSA IT <leodona...@mail.maricopa.gov>
> Don't you have to set these before you add the Paragraph to the document
> or some other element? I don't think you can set the vertical position of
> a Paragraph *after* it has been added.
>
> ------------------------------------------------------------------------------
>
> From: SALAZAR, DANTE [mailto:digitron...@cwpanama.net]
> Sent: Wednesday, August 14, 2013 6:51 PM
> To: Post all your questions about iText here
> Subject: Re: [iText-questions] Vertical Position of the first paragraph
>
> Yes, I need to set the vertical position first, but how?
> My code is something like this
> x = "Bla bla bla ....."
> prf = New Paragraph(x, fnt)
> k = wr.GetVerticalPosition(False)
> If k > 600 Then prf.SpacingBefore = 100
> Doc.Add(prf)
> If x is the firts paragraph I am going to print, k=720 and I want to print
> it at position 620, so I set SpacingBefore=100, but when I saw the
> document, the text is printed at the bigining of the page (720), not at
> position 620.
> My question 1 is, is SpacingBefore the correct way to do this, or there is
> something like wr.SetVerticalPosition=620.
> Question 2, why don't works SpacingBefore in this case.
> Thanks
>
>
> ------------------------------------------------------------------------------
>
> You just want to indent your paragraph by 100? setIndentationLeft(100)
> That is not working for you?
>
> Spacing before actually is the spacing "above" the paragraph element.
>
>
> ------------------------------------------------------------------------------
> Get 100% visibility into Java/.NET code with AppDynamics Lite!
> It's a free troubleshooting tool designed for production.
> Get down to code-level detail for bottlenecks, with <2% overhead.
> Download for free and get started troubleshooting in minutes.
> http://pubads.g.doubleclick.net/gampad/clk?id=48897031&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
>
------------------------------------------------------------------------------
Get 100% visibility into Java/.NET code with AppDynamics Lite!
It's a free troubleshooting tool designed for production.
Get down to code-level detail for bottlenecks, with <2% overhead.
Download for free and get started troubleshooting in minutes.
http://pubads.g.doubleclick.net/gampad/clk?id=48897031&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