Name

javax.microedition.lcdui.Graphics

Synopsis

This class provides a simple two-dimensional geometric rendering capability. It provides drawing primitives for text, images, lines, rectangles, and arcs. Pixel replacement is the only drawing operation provided.

public classGraphics {
   // public class fields
   public static final int BASELINE = 64;
   public static final int BOTTOM = 32;
   public static final int DOTTED = 1;
   public static final int HCENTER = 1;
   public static final int LEFT = 4;
   public static final int RIGHT = 8;
   public static final int SOLID = 0;
   public static final int TOP = 16;
   public static final int VCENTER = 2;
   // public instance methods
   public void clipRect(int x, int y, int width, int height);
   public void drawArc(int x, int y, int width, int height, int startAngle, int
               arcAngle);
   public void drawChar(char character, int x, int y, int anchor);
   public void drawChars(char[] data, int offset, int length, int x, int y, int 
               anchor);
   public void drawImage(Image img, int x, int y, int anchor);
   public void drawLine(int x1, int y1, int x2, int y2);
   public void drawRect(int x, int y, int width, int height);
   public void drawRoundRect(int x, int y, int width, int height, int arcWidth, int
               arcHeight);
   public void drawString(String str, int x, int y, int anchor);
   public void drawSubString(String str, int offset, int len, int x, int y, int
               anchor);
   public void fillArc(int x, int y, int width, int height, int startAngle, int
               arcAngle);
   public void fillRect(int x, int y, int width, int ...

Get Wireless Java now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.