我正在使用 Jasper 报告生成 pdf 文档。每个段落的第一行是缩进的。当一个段落溢出到下一页时,新页面中的第一行会缩进,即使它不应该是因为它只是另一页的延续。下面是一个段落的例子:
<textField isStretchWithOverflow="true">
<reportElement positionType="Float" x="0" y="60" width="367" height="1">
</reportElement>
<textElement textAlignment="Justified">
<font fontName="Arial" size="12"/>
<paragraph lineSpacing="1_1_2" firstLineIndent="40"/>
</textElement>
<textFieldExpression><![CDATA["This is an extremely long paragraph, so long that it overflows into the next page and gets wrongly indented.\n"]]></textFieldExpression>
</textField>
我知道这不是堆栈溢出,但仍然是溢出问题。有任何想法吗?
PS:我很绝望,我会考虑即使是最疯狂的想法。抱歉,我不知道为什么 xml 没有保持可读的缩进格式。缩进似乎只在你不想要的地方弹出。