dark = new Polygon(new int[] { c.x, d.x, e.x + 1 },
dark = new Polygon(new int[] { c.x, d.x, e.x },
  public void paintThumb(Graphics g)  {    Color saved_color = g.getColor();    Polygon thumb = new Polygon();    Point a = new Point(thumbRect.x, thumbRect.y);    Point b = new Point(a);    Point c = new Point(a);    Point d = new Point(a);    Point e = new Point(a);    Polygon bright;    Polygon dark;    Polygon all;    // This will be in X-dimension if the slider is inverted and y if it isn't.	  	      int turnPoint;    if (slider.getOrientation() == JSlider.HORIZONTAL)      {	turnPoint = thumbRect.height * 3 / 4;	b.translate(thumbRect.width, 0);	c.translate(thumbRect.width, turnPoint);	d.translate(thumbRect.width / 2, thumbRect.height);	e.translate(0, turnPoint);	bright = new Polygon(new int[] { b.x, a.x, e.x, d.x },	                     new int[] { b.y, a.y, e.y, d.y }, 4);	dark = new Polygon(new int[] { b.x, c.x, d.x },	                   new int[] { b.y, c.y, d.y }, 3);	all = new Polygon(new int[] { a.x + 1, b.x, c.x, d.x, e.x + 1 },	                  new int[] { a.y + 1, b.y + 1, c.y, d.y + 1, e.y }, 5);      }    else      {	turnPoint = thumbRect.width * 3 / 4;	b.translate(turnPoint, 0);	c.translate(thumbRect.width, thumbRect.height / 2);	d.translate(turnPoint, thumbRect.height);	e.translate(0, thumbRect.height);	bright = new Polygon(new int[] { c.x, b.x, a.x, e.x },	                     new int[] { c.y, b.y, a.y, e.y }, 4);	dark = new Polygon(new int[] { c.x, d.x, e.x + 1 },	                   new int[] { c.y, d.y, e.y }, 3);	all = new Polygon(new int[] { a.x + 1, b.x, c.x - 1, d.x, e.x + 1 },	                  new int[] { a.y + 1, b.y + 1, c.y, d.y, e.y }, 5);      }    g.setColor(Color.WHITE);    g.drawPolyline(bright.xpoints, bright.ypoints, bright.npoints);    g.setColor(Color.BLACK);    g.drawPolyline(dark.xpoints, dark.ypoints, dark.npoints);    g.setColor(Color.GRAY);    g.fillPolygon(all);    g.setColor(saved_color);  }