Examples of drawRoundRect()


Examples of java.awt.Graphics2D.drawRoundRect()

          Graphics2D g2D = (Graphics2D) g;
          g2D.setRenderingHint(RenderingHints.KEY_ANTIALIASING,
                        RenderingHints.VALUE_ANTIALIAS_ON);
         
          //test d'un rectangle avec angle arrondi
          g2D.drawRoundRect(20, 20, 80, 80, 20, 20);
          //test d'un rectangle sans angle arrondi
          g2D.drawRoundRect(120, 20, 80, 80, 0, 0);
         
          //changement de couleur
          g2D.setColor(new Color(255,0,0));
View Full Code Here

Examples of java.awt.Graphics2D.drawRoundRect()

                        RenderingHints.VALUE_ANTIALIAS_ON);
         
          //test d'un rectangle avec angle arrondi
          g2D.drawRoundRect(20, 20, 80, 80, 20, 20);
          //test d'un rectangle sans angle arrondi
          g2D.drawRoundRect(120, 20, 80, 80, 0, 0);
         
          //changement de couleur
          g2D.setColor(new Color(255,0,0));
          g2D.setStroke(new BasicStroke(1));
         
View Full Code Here

Examples of java.awt.Graphics2D.drawRoundRect()

         
          //changement de couleur
          g2D.setColor(new Color(255,0,0));
          g2D.setStroke(new BasicStroke(1));
         
          g2D.drawRoundRect(220, 20, 80, 80, 40, 40);
          RoundRectangle2D.Double rect = new RoundRectangle2D.Double(320, 20, 80, 80, 80, 40);
          g2D.draw(rect);
        }
       
      }
View Full Code Here

Examples of java.awt.Graphics2D.drawRoundRect()

                                g2.drawString(getString(), str_x, str_y);
                        }
                }
                if (isBorderPainted()) {
                        g2.setColor(Color.BLACK);
                        g2.drawRoundRect(bounds.x + getInsets().left, bounds.y + getInsets().top, bounds.width - getInsets().right, bounds.height - getInsets().bottom, arc, arc);
                }
                g2.setPaint(paint);
                g2.setColor(c);
                g2.dispose();
                offscreen.runValidate();
View Full Code Here

Examples of java.awt.Graphics2D.drawRoundRect()

    paintBackgound(g);
    paintDragOver(g);
    final Color edgeColor = nodeView.getEdgeColor();
    g.setColor(edgeColor);
    g.setStroke(BubbleMainView.DEF_STROKE);
    g.drawRoundRect(0, 0, getWidth() - 1, getHeight() - 1, 10, 10);
    g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, renderingHint);
    super.paintComponent(g);
  }

  @Override
View Full Code Here

Examples of java.awt.Graphics2D.drawRoundRect()

            BasicStroke b_stroke = new BasicStroke(stroke_width);
            graphics.setColor(ColorMapper.getColorByName(stroke));
            graphics.setStroke(b_stroke);

            if ((arcwidth != 0) || (archeight != 0)) {
                graphics.drawRoundRect(0, 0, width, height, arcwidth, archeight);
            } else {
                graphics.drawRect(0, 0, width, height);
            }
        }
View Full Code Here

Examples of java.awt.Graphics2D.drawRoundRect()


      g2.setStroke(_STK_STROKE_);
      g2.setPaint(_PNT_PAINT_);

      g2.drawRoundRect(0, 0, k - 1, l - 1, 5, 5);

      g2.setStroke(stkOri);
      g2.setPaint(pntOri);
   }
View Full Code Here

Examples of java.awt.Graphics2D.drawRoundRect()

      int adjustWH = 2;
      Graphics2D g2d = (Graphics2D) g;
     
      GfrUtilGraphics2D.s_setRenderingAntiAliasOn(g2d);

      g2d.drawRoundRect(
              x + adjustXY,
              y + adjustXY,
              width - adjustWH,
              height - adjustWH - 1,
              this._widthRadius_+1,
View Full Code Here

Examples of java.awt.Graphics2D.drawRoundRect()

    final Graphics2D g2  = (Graphics2D) g;
             
    g2.setRenderingHint( RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON );
    for( int j = 0, k = 1; j < 5; j++, k += 2 ) {
      g2.setColor( colrFocus[ j ]);
      g2.drawRoundRect( x + j, y + j, width - k, height - k, 10 - k, 10 - k );
    }
  }

  public static int getAquaColorVariant()
  {
View Full Code Here

Examples of org.locationtech.udig.ui.graphics.ViewportGraphics.drawRoundRect()

            if (legendStyle.isRoundedRectangle) {
                graphics.setColor(legendStyle.backgroundColor);
                graphics.fillRoundRect(round(x), round(y), round(w), round(h), 15, 15);
                graphics.setColor(legendStyle.foregroundColor);
                graphics.setBackground(legendStyle.backgroundColor);
                graphics.drawRoundRect(round(x), round(y), round(w), round(h), 15, 15);
            } else {
                graphics.setColor(legendStyle.backgroundColor);
                graphics.fillRect(round(x), round(y), round(w), round(h));
                graphics.setColor(legendStyle.foregroundColor);
                graphics.setBackground(legendStyle.backgroundColor);
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.