Package java.awt

Examples of java.awt.Graphics2D.draw()


                big.draw(new Line2D.Double(4, 0, 7, 3));
                big.draw(new Line2D.Double(0, 7, 7, 0));
                big.draw(new Line2D.Double(0, 3, 3, 0));
                big.draw(new Line2D.Double(4, 7, 7, 4));
            } else if (fillPatternString.equalsIgnoreCase(LPC_BACKWARD_DIAG_PATTERN)) {
                big.draw(new Line2D.Double(0, 0, 7, 7));
                big.draw(new Line2D.Double(0, 4, 3, 7));
                big.draw(new Line2D.Double(4, 0, 7, 3));
            } else if (fillPatternString.equalsIgnoreCase(LPC_FORWARD_DIAG_PATTERN)) {
                big.draw(new Line2D.Double(0, 7, 7, 0));
                big.draw(new Line2D.Double(0, 3, 3, 0));
View Full Code Here


                big.draw(new Line2D.Double(0, 7, 7, 0));
                big.draw(new Line2D.Double(0, 3, 3, 0));
                big.draw(new Line2D.Double(4, 7, 7, 4));
            } else if (fillPatternString.equalsIgnoreCase(LPC_BACKWARD_DIAG_PATTERN)) {
                big.draw(new Line2D.Double(0, 0, 7, 7));
                big.draw(new Line2D.Double(0, 4, 3, 7));
                big.draw(new Line2D.Double(4, 0, 7, 3));
            } else if (fillPatternString.equalsIgnoreCase(LPC_FORWARD_DIAG_PATTERN)) {
                big.draw(new Line2D.Double(0, 7, 7, 0));
                big.draw(new Line2D.Double(0, 3, 3, 0));
                big.draw(new Line2D.Double(4, 7, 7, 4));
View Full Code Here

                big.draw(new Line2D.Double(0, 3, 3, 0));
                big.draw(new Line2D.Double(4, 7, 7, 4));
            } else if (fillPatternString.equalsIgnoreCase(LPC_BACKWARD_DIAG_PATTERN)) {
                big.draw(new Line2D.Double(0, 0, 7, 7));
                big.draw(new Line2D.Double(0, 4, 3, 7));
                big.draw(new Line2D.Double(4, 0, 7, 3));
            } else if (fillPatternString.equalsIgnoreCase(LPC_FORWARD_DIAG_PATTERN)) {
                big.draw(new Line2D.Double(0, 7, 7, 0));
                big.draw(new Line2D.Double(0, 3, 3, 0));
                big.draw(new Line2D.Double(4, 7, 7, 4));
            } else {
View Full Code Here

            } else if (fillPatternString.equalsIgnoreCase(LPC_BACKWARD_DIAG_PATTERN)) {
                big.draw(new Line2D.Double(0, 0, 7, 7));
                big.draw(new Line2D.Double(0, 4, 3, 7));
                big.draw(new Line2D.Double(4, 0, 7, 3));
            } else if (fillPatternString.equalsIgnoreCase(LPC_FORWARD_DIAG_PATTERN)) {
                big.draw(new Line2D.Double(0, 7, 7, 0));
                big.draw(new Line2D.Double(0, 3, 3, 0));
                big.draw(new Line2D.Double(4, 7, 7, 4));
            } else {
                // default to solid
                big.fillRect(0, 0, 8, 8);
View Full Code Here

                big.draw(new Line2D.Double(0, 0, 7, 7));
                big.draw(new Line2D.Double(0, 4, 3, 7));
                big.draw(new Line2D.Double(4, 0, 7, 3));
            } else if (fillPatternString.equalsIgnoreCase(LPC_FORWARD_DIAG_PATTERN)) {
                big.draw(new Line2D.Double(0, 7, 7, 0));
                big.draw(new Line2D.Double(0, 3, 3, 0));
                big.draw(new Line2D.Double(4, 7, 7, 4));
            } else {
                // default to solid
                big.fillRect(0, 0, 8, 8);
            }
View Full Code Here

                big.draw(new Line2D.Double(0, 4, 3, 7));
                big.draw(new Line2D.Double(4, 0, 7, 3));
            } else if (fillPatternString.equalsIgnoreCase(LPC_FORWARD_DIAG_PATTERN)) {
                big.draw(new Line2D.Double(0, 7, 7, 0));
                big.draw(new Line2D.Double(0, 3, 3, 0));
                big.draw(new Line2D.Double(4, 7, 7, 4));
            } else {
                // default to solid
                big.fillRect(0, 0, 8, 8);
            }
View Full Code Here

      clone.fill(scaledShape);
    }
    if (shouldDraw)
    {
      configureGraphics(layoutContext, clone);
      clone.draw(scaledShape);
    }
    clone.dispose();
  }

View Full Code Here

                    g2d.setColor(terrible);
                else
                    g2d.setColor(blank);
               
                g2d.fill(shape);
                g2d.draw(shape);
            }
            bi.flush();
            ratings.put(Long.valueOf(rating), new ImageIcon(bi));
        }
    }   
View Full Code Here

      g2.setStroke(stroke);
    }
    else{
      g2.setStroke(new BasicStroke());
    }
    g2.draw(line);
  }
 
  public Component getListCellRendererComponent(JList list, Object value, int index,
                          boolean isSelected, boolean cellHasFocus) {
    stroke=StrokeParameters.createStroke(((StrokeDisplay)value).strokeParams.param1,
View Full Code Here

      rectangle.setFrame(x, y, w-1, h-1);
    }
    else {
      rectangle.setFrame(x, y, w-1, h-1);
    }
    g2d.draw(rectangle);
  }
 
  public void paintFocus(Graphics g) {
    if (((CustomSlider)slider).getPaintFocus()) {
      super.paintFocus(g);
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.