/** * Set the width of the pinstripes * * @param stripeWidth * a new width for the pinstripes */ public void setStripeWidth(double stripeWidth) { double oldSripeWidth = getStripeWidth(); this.stripeWidth = stripeWidth; firePropertyChange("stripeWidth", oldSripeWidth, getStripeWidth()); }
/** * Set the width of the pinstripes * * @param stripeWidth * a new width for the pinstripes */ public void setStripeWidth(double stripeWidth) { double oldSripeWidth = getStripeWidth(); this.stripeWidth = stripeWidth; firePropertyChange("stripeWidth", oldSripeWidth, getStripeWidth()); }
/** * Set the width of the pinstripes * * @param stripeWidth * a new width for the pinstripes */ public void setStripeWidth(double stripeWidth) { double oldSripeWidth = getStripeWidth(); this.stripeWidth = stripeWidth; firePropertyChange("stripeWidth", oldSripeWidth, getStripeWidth()); }
/** * Set the width of the pinstripes * @param stripeWidth a new width for the pinstripes */ public void setStripeWidth(double stripeWidth) { double oldSripeWidth = getStripeWidth(); this.stripeWidth = stripeWidth; firePropertyChange("stripeWidth",new Double(oldSripeWidth),new Double(stripeWidth)); }
g.setStroke(new BasicStroke((float) getStripeWidth())); g.rotate(toRadians(getAngle())); double gap = getSpacing() + getStripeWidth();
g.setStroke(new BasicStroke((float) getStripeWidth())); g.rotate(toRadians(getAngle())); double gap = getSpacing() + getStripeWidth();
g.setStroke(new BasicStroke((float) getStripeWidth())); g.rotate(toRadians(getAngle())); double gap = getSpacing() + getStripeWidth();
g.setStroke(new BasicStroke((float)getStripeWidth())); spacing += getStripeWidth(); int numLines = (int)(hypLength / spacing);
@Test @Override public void testDefaults() { super.testDefaults(); PinstripePainter pp = (PinstripePainter) p; assertThat(pp.getAngle(), is(45d)); assertThat(pp.getPaint(), is(nullValue())); assertThat(pp.getSpacing(), is(8d)); assertThat(pp.getStripeWidth(), is(1d)); } }