问题
I saw this in another post,
<fo:block text-align-last="justify">
LEFT TEXT
<fo:leader leader-pattern="space" />
RIGHT TEXT
</fo:block>
But i want the RIGHT TEXT to be aligned to center of the same line. I am using Apache FOP to generate PDF from xml. Any help would be appreciated!
回答1:
Use a one row, three column table with column widths like 30-40-30 or whatever you need to accommodate the text widths. Put the content in the first two cells only and set the alignment on them to left and center respectively.
来源:https://stackoverflow.com/questions/23948738/left-and-center-aligning-in-same-line-using-xsl-fo