浏览代码

Avoid painting empty rectangles because that can lead to unwanted artifacts.

git-svn-id: https://svn.apache.org/repos/asf/xmlgraphics/fop/trunk@344330 13f79535-47bb-0310-9956-ffa450edef68
tags/fop-0_90-alpha1
Jeremias Maerki 18 年前
父节点
当前提交
54ff093a1c

+ 3
- 1
src/java/org/apache/fop/render/pdf/PDFRenderer.java 查看文件

* @see org.apache.fop.render.AbstractPathOrientedRenderer#fillRect(float, float, float, float) * @see org.apache.fop.render.AbstractPathOrientedRenderer#fillRect(float, float, float, float)
*/ */
protected void fillRect(float x, float y, float w, float h) { protected void fillRect(float x, float y, float w, float h) {
currentStream.add(x + " " + y + " " + w + " " + h + " re f\n");
if (w != 0 && h != 0) {
currentStream.add(x + " " + y + " " + w + " " + h + " re f\n");
}
} }
/** /**

+ 7
- 5
src/java/org/apache/fop/render/ps/PSRenderer.java 查看文件

/** @see org.apache.fop.render.AbstractPathOrientedRenderer */ /** @see org.apache.fop.render.AbstractPathOrientedRenderer */
protected void fillRect(float x, float y, float width, float height) { protected void fillRect(float x, float y, float width, float height) {
try {
gen.defineRect(x, y, width, height);
gen.writeln("fill");
} catch (IOException ioe) {
handleIOTrouble(ioe);
if (width != 0 && height != 0) {
try {
gen.defineRect(x, y, width, height);
gen.writeln("fill");
} catch (IOException ioe) {
handleIOTrouble(ioe);
}
} }
} }



正在加载...
取消
保存