* @see org.apache.fop.render.AbstractPathOrientedRenderer#fillRect(float, float, float, float)
*/
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");
+ }
}
/**
/** @see org.apache.fop.render.AbstractPathOrientedRenderer */
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);
+ }
}
}