我想将文本对齐到第二个单元格的底部。
由于宽度不足,第一个单元格延伸到2行,没关系
但是第二个单元格中的文本只有一行,显示在该单元格的顶部。
如何将其对准底部?
我在尝试了vertical-align =“bottom” text-align =“bottom” text-align =“end”
行,单元格和块级。
<fo:table font="normal 10 pt Arial, sans-serif" width="100%">
<fo:table-column column-width="40mm"/>
<fo:table-column column-width="130mm"/>
<fo:table-body>
<fo:table-row>
<fo:table-cell padding-before="3pt" padding-after="3pt">
<fo:block font-weight="bold">Pricing Rate in % p.a. / "Pensionssatz in % p.a.":</fo:block>
</fo:table-cell>
<fo:table-cell padding-before="3pt" padding-after="3pt">
<fo:block>
**This text I want to be aligned to bottom (in the second line)**
</fo:block>
</fo:table-cell>
</fo:table-row>
</fo:table-body>
</fo:table>
最佳答案
在表单元格上使用 display-align="after"
:
<fo:table-cell padding-before="3pt" padding-after="3pt" display-align="after">
<fo:block>
**This text I want to be aligned to bottom (in the second line)**
</fo:block>
</fo:table-cell>