我想删除这个估计标题和下面的黑线。我试过把
<fo:block text-align="center" padding-left="4pt" margin-left="4pt" margin-bottom="4pt" padding-bottom="4pt">
<xsl:attribute name="border-bottom-color">black</xsl:attribute>
<xsl:attribute name="border-bottom-width">0.7pt</xsl:attribute>
<xsl:attribute name="border-bottom-style">solid</xsl:attribute>
Estimated
</fo:block>
('Unable to generate PDF.',
b'Exception\norg.apache.fop.apps.FOPException: org.apache.fop.fo.ValidationException:
"fo:table-cell" is missing child elements. Required content model: marker* (%block;)+ (See position 8:104)
javax.xml.transform.TransformerException: org.apache.fop.fo.ValidationException:
"fo:table-cell" is missing child elements. Required content model: marker* (%block;)+ (See position 48:104)')
试图删除“估计”一词
甚至试着去掉黑条:
<xsl:attribute name="border-bottom-color">black</xsl:attribute>
<xsl:attribute name="border-bottom-width">0.7pt</xsl:attribute>
<xsl:attribute name="border-bottom-style">solid</xsl:attribute>
('Unable to generate PDF.', b'Exception\norg.apache.fop.apps.FOPException: org.apache.fop.fo.ValidationException:
The column-number or number of cells in the row overflows the number of fo:table-columns specified for the table. (See position 25:15)
javax.xml.transform.TransformerException:
org.apache.fop.fo.ValidationException: The column-number or number of cells in the row overflows the number of fo:table-columns specified for the table. (See position 25:15)\n\n')
Unable to generate PDF
部分是自定义的
这个xsl-fo的东西真的很挑剔,有人知道为什么我不能删除其中一个而不炸掉它吗?谢谢
如果每次都显示删除的内容,那么删除整个
fo:block
会给您留下一个没有内容的fo:table-cell
。“marker*(%block;)+”告诉您fo:table-cell
应该有一个或多个块级FOs(在零个或多个fo:marker
之后)。你知道吗第二个问题可能与删除属性无关。FOP可能是在检查完FOs的内容之后再检查表的布局。第一个示例中错误的位置与第二个示例中错误消息的位置非常不同。检查它告诉你的线路。你知道吗
如果您想在让FOP抱怨之前检查FO,https://github.com/AntennaHouse/focheck会找到空的表单元格,但它不会检查表布局。你知道吗
顺便说一句,你的三个
xsl:attribute
只需要一个border
就可以完成。你知道吗相关问题 更多 >
编程相关推荐