It's very hard to tell what you're trying to do. The page size of 462 x *666*
inches is unsupported in PDF. The current maximum is, unless it's been
updated, 200 in x 200 in. Are you sure you don't mean points rather than
inches? 

Presuming you mean points, I still don't understand what you're trying to do
with this code. If you set the left and right margins to 155 each, you're
creating left and right margins that are more than 2" wide on an A4 sheet.
The top and bottom margins of 260 points give you a total of 7" of margin,
again on an A4 sheet. This would leave a tiny little region to print in.

This is almost certainly wrong. Can you repost your query, explaining what
size page you want, and how big the print area and BE ATTENTIVE to
distinguishing between points and inches. 

I suspect if you do this, you might be able to solve the problem by
yourself. Not many posts deal with problems in the areas you're discussing,
so there is almost certainly a misunderstanding.

---Andrew Binstock


magesh rathnam wrote:
> 
> Hi all,
> 
>    I have a requirement where in I need to have a page of dimension 462 *
> 666 inches. I'm not able to set the page size correctly. I tried using
> 
>         Rectangle r = new Rectangle(462,0,0,666);
>         Document document = new Document(r);
> 
> 
>     But this does not create the document in the size I expected. I tried
> setting the page size to A4 and set Margins to that I can get the document
> of needed size but that did not work out either. I tried
> 
>         Document document = new Document(PageSize.A4);
>         document.setMargins(155, 155, 260, 260);
> 
>    But when I gave a println to see the values
> 
>                System.out.println("document.right() "
> +document.right(155));
>                System.out.println("document.left() " +document.left(155));
>                System.out.println("document.top() " +document.top(260));
>                System.out.println("document.bottom() "
> +document.bottom(260));
> 
> 
> The output was
> 
> document.right() 285.0
> document.left() 310.0
> document.top() 322.0
> document.bottom() 520.0
> 
> Can someone help me in pointing out what am I doing wrong? Can someone get
> me correct code snippet to accomplish the scenario. Appreciate your help.
> 
> Thanks & Regards,
> Magesh.
> 
> -------------------------------------------------------------------------
> Using Tomcat but need to do more? Need to support web services, security?
> Get stuff done quickly with pre-integrated technology to make your job
> easier.
> Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
> http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
> _______________________________________________
> iText-questions mailing list
> iText-questions@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/itext-questions
> Buy the iText book: http://itext.ugent.be/itext-in-action/
> 
> 

-- 
View this message in context: 
http://www.nabble.com/Setting-Page-Margins-tf3176962.html#a8815610
Sent from the iText - General mailing list archive at Nabble.com.


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
iText-questions mailing list
iText-questions@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://itext.ugent.be/itext-in-action/

Reply via email to