Java Graphics Draw drawRequiredMarker(Graphics2D g2, int x, int y, int iconSize)

Here you can find the source of drawRequiredMarker(Graphics2D g2, int x, int y, int iconSize)

Description

draw Required Marker

License

Apache License

Declaration

protected static void drawRequiredMarker(Graphics2D g2, int x, int y,
            int iconSize) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

import java.awt.*;

public class Main {
    protected static void drawRequiredMarker(Graphics2D g2, int x, int y,
            int iconSize) {
        Font font = new Font("Serif", Font.BOLD, 2 * iconSize);
        g2.setFont(font);//from   w  w w . j  av a  2s . c  o  m
        g2.drawString("!", x - iconSize + 2, y + iconSize - 2);
    }
}

Related

  1. drawOptimizedLine(Graphics g, int x1, int y1, int x2, int y2)
  2. drawPaintedShape(Graphics2D graphics, Shape shape, Paint paint, Rectangle2D paintBounds, Stroke stroke)
  3. drawPowerScaleLabel(Graphics g, int base, int power, int x, int y, boolean yAxisP)
  4. drawProgressBar(Graphics2D g, final int x, final int y, final int width, final int height, final Color main, final Color progress, final int alpha, final int percentage)
  5. drawRainbow(Graphics2D g2, int x, int y, int Width, int Height, int Mode)
  6. drawRTriangle(Graphics g, Color color, int x, int y, int r)
  7. drawScaleTick(Graphics g, int x, int y, boolean yAxisP, int length)
  8. drawScrollBar(Graphics g, int which, int direction, int x, int y, int fmWidth, int fmHeight, Color fg, Color bg)
  9. drawSelectionBox(Graphics g)