Package java.awt

Examples of java.awt.Graphics2D.drawOval()


      int x = randomInt(0, width / 2);
      int y = randomInt(0, height / 2);

      gfx.setXORMode(Color.BLACK);
      gfx.setStroke(new BasicStroke(randomInt(fontSize / 8, fontSize / 2)));
      gfx.drawOval(x, y, dx, dy);

      WritableRaster rstr = image.getRaster();
      int[] vColor = new int[3];
      int[] oldColor = new int[3];
      Random vRandom = new Random(System.currentTimeMillis());
View Full Code Here


    g2.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
         RenderingHints.VALUE_ANTIALIAS_ON);
    g2.setColor(Color.WHITE);
    g2.setStroke(new BasicStroke(1f));
   
    g2.drawOval(7, 7, 6, 6);
   
    g2.drawLine(13, 10, 16, 10);

   
   
View Full Code Here

        else
            g.drawOval(insets.left, insets.top, this.getWidth() - insets.left + insets.right, this.getHeight() - insets.top + insets.bottom );
        g.setColor( this.getForeground() );
        Graphics2D g2d = (Graphics2D)g;
        g2d.setStroke(UIutils.makeStroke(this.lineWeight, this.lineStyle));
        g2d.drawOval(insets.left,
                insets.top,
                this.getWidth() - insets.left + insets.right - 1,
                this.getHeight() - insets.top + insets.bottom - 1);
    }
    public Ellipse cloneComponent(){
View Full Code Here

        else
            g.drawOval(insets.left, insets.top, this.getWidth() - insets.left + insets.right, this.getHeight() - insets.top + insets.bottom );
        g.setColor( this.getForeground() );
        Graphics2D g2d = (Graphics2D)g;
        g2d.setStroke(UIutils.makeStroke(this.lineWeight, this.lineStyle));
        g2d.drawOval(insets.left,
                insets.top,
                this.getWidth() - insets.left + insets.right - 1,
                this.getHeight() - insets.top + insets.bottom - 1);
    }
    public Ellipse cloneComponent(){
View Full Code Here

                            lValorY = ObjectTolong(sorttmodel.getValueAt(j, coly[k]));
                            lValor = (long) ((((lValorY - tiColYMin.getTime()) * 100) / l100PorCienY) * incrementoY);
                            yActual = (int) (ejeY - lValor);
                        }

                        g2.drawOval(xActual - 4, yActual - 4, 8, 8);
                        g2.fillOval(xActual - 2, yActual - 2, 4, 4);

                        if(!bPrimeraVez)
                            g2.drawLine(xAnterior, yAnterior[k], xActual, yActual);
                        else
View Full Code Here

        g2d.fillOval(getTopleftx(), getToplefty(), getDiagonal_size(), getDiagonal_size());

        //cella kerületének és a rajta lévő "X" kirajzolása
        g2d.setColor(getFg_color());
        g2d.setStroke(korvonal_stroke);
        g2d.drawOval(getTopleftx(), getToplefty(), getDiagonal_size(), getDiagonal_size());
        g2d.setStroke(athuzas_stroke);
        g2d.drawLine(getTopleftx() + getCropsize(), getToplefty() + getCropsize(), getTopleftx() + getDiagonal_size() - getCropsize(), getToplefty() + getDiagonal_size() - getCropsize());
        g2d.drawLine(getTopleftx() + getCropsize(), getToplefty() + getDiagonal_size() - getCropsize(), getTopleftx() + getDiagonal_size() - getCropsize(), getToplefty() + getCropsize());

        //a szomszédok irányába mutató nyilak kirajzolása
View Full Code Here

        else
            g.drawOval(insets.left, insets.top, this.getWidth() - insets.left + insets.right, this.getHeight() - insets.top + insets.bottom );
        g.setColor( this.getForeground() );
        Graphics2D g2d = (Graphics2D)g;
        g2d.setStroke(UIutils.makeStroke(this.lineWeight, this.lineStyle));
        g2d.drawOval(insets.left,
                insets.top,
                this.getWidth() - insets.left + insets.right - 1,
                this.getHeight() - insets.top + insets.bottom - 1);
    }
    public Ellipse cloneComponent(){
View Full Code Here

        {
            int d=6;
            g2.setColor(Color.BLACK);
            g2.fillOval(p1.x-d,p1.y-d,d*2,d*2);
            g2.setColor(Color.WHITE);
            g2.drawOval(p1.x-d,p1.y-d,d*2-1,d*2-1);

            g2.setColor(Color.BLACK);
            g2.fillOval(p2.x-d,p2.y-d,d*2,d*2);
            g2.setColor(Color.WHITE);
            g2.drawOval(p2.x-d,p2.y-d,d*2-1,d*2-1);
 
View Full Code Here

            g2.drawOval(p1.x-d,p1.y-d,d*2-1,d*2-1);

            g2.setColor(Color.BLACK);
            g2.fillOval(p2.x-d,p2.y-d,d*2,d*2);
            g2.setColor(Color.WHITE);
            g2.drawOval(p2.x-d,p2.y-d,d*2-1,d*2-1);

            g2.setXORMode(Color.RED);
            g2.setColor(Color.WHITE);
            g2.drawLine(p1.x,p1.y,p2.x,p2.y);       

View Full Code Here

        if (showBackground.getValue())
        {
          g.setColor(backColor.getValue());
          g.fillOval(distance,distance,w-distance*2,h-distance*2);
          g.setColor(Color.BLACK);
          g.drawOval(distance,distance,w-distance*2,h-distance*2);
        }
      }

      g.setColor(lineColor.getValue());
      if (showText.getValue())
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.