简体   繁体   中英

Alignment in iText library for java

I just got a question about alignment in the library iText. Say if i was to do a quote program.

For example On the Left side of the page I would want to put Quote # 01 and on the same line on the other side of the page I want to put the date.

Is this possible using the Paragraph class? If not can any body help me out with any other solutions?

To the best of my knowledge, you can't do this within a single paragraph. You'll have to get the current position ( cb.getYLine() ) and place a separate chunk with the date. See itext positioning text absolutely if you need pointers on placing the chunk.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM