comparison artifacts/src/main/java/org/dive4elements/river/jfree/StableXYDifferenceRenderer.java @ 8910:d9c89651bd67

Area chart layers may now have an 'arebgpattern'. Real pattern yet to be defined.
author gernotbelger
date Thu, 22 Feb 2018 18:46:37 +0100
parents 5e38e2924c07
children 77eb4553245b
comparison
equal deleted inserted replaced
8909:31dff17c6828 8910:d9c89651bd67
405 * @param paint the paint (<code>null</code> not permitted). 405 * @param paint the paint (<code>null</code> not permitted).
406 * 406 *
407 * @see #getPositivePaint() 407 * @see #getPositivePaint()
408 */ 408 */
409 public void setPositivePaint(Paint paint) { 409 public void setPositivePaint(Paint paint) {
410 if (paint == null) {
411 throw new IllegalArgumentException("Null 'paint' argument.");
412 }
413 this.positivePaint = paint; 410 this.positivePaint = paint;
414 fireChangeEvent(); 411 fireChangeEvent();
415 } 412 }
416 413
417 /** 414 /**
431 * @param paint the paint (<code>null</code> not permitted). 428 * @param paint the paint (<code>null</code> not permitted).
432 * 429 *
433 * @see #getNegativePaint() 430 * @see #getNegativePaint()
434 */ 431 */
435 public void setNegativePaint(Paint paint) { 432 public void setNegativePaint(Paint paint) {
436 if (paint == null) {
437 throw new IllegalArgumentException("Null 'paint' argument.");
438 }
439 this.negativePaint = paint; 433 this.negativePaint = paint;
440 notifyListeners(new RendererChangeEvent(this)); 434 notifyListeners(new RendererChangeEvent(this));
441 } 435 }
442 436
443 /** 437 /**
1772 } 1766 }
1773 l_path.closePath(); 1767 l_path.closePath();
1774 } 1768 }
1775 1769
1776 if (l_path.intersects(x_dataArea)) { 1770 if (l_path.intersects(x_dataArea)) {
1777 x_graphics.setPaint(x_positive ? getPositivePaint() 1771
1778 : getNegativePaint()); 1772 final Paint paint = x_positive ? getPositivePaint(): getNegativePaint();
1773 if( paint != null ) {
1774 x_graphics.setPaint(paint);
1779 x_graphics.fill(l_path); 1775 x_graphics.fill(l_path);
1776 }
1777
1780 if (drawOutline) { 1778 if (drawOutline) {
1781 x_graphics.setStroke(this.outlineStroke); 1779 x_graphics.setStroke(this.outlineStroke);
1782 x_graphics.setPaint(this.outlinePaint); 1780 x_graphics.setPaint(this.outlinePaint);
1783 x_graphics.draw(l_path); 1781 x_graphics.draw(l_path);
1784 } 1782 }

http://dive4elements.wald.intevation.org