简体   繁体   中英

iText alignment cell 6 levels

In my project, I'm using iText to print a dynamic table on PDF.

There are 6 different levels in my enumeration. I want to align every level a little bit more to right.

In iText, there is a function: cell.setHorizontalAlignment()

The problem is that you can only choice between: LEFT, CENTER and RIGHT Any possible solutions for this?

An example of what I want:

1
  2
    3
      4
        5
          6

If you want to change the indentation inside a cell, one way is to change the indentation at the level of the Paragraph objects you're adding to the cell. Another way would be to change the padding of the cell (you can change the padding on all sides, or on the right, level, top and bottom separately).

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