|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.Objectcom.nokia.mid.ui.CanvasItem
com.nokia.mid.ui.CanvasGraphicsItem
public abstract class CanvasGraphicsItem
A paintable item that can be used on top of Canvas or CustomItem
| Field Summary |
|---|
| Fields inherited from class com.nokia.mid.ui.CanvasItem |
|---|
SCALE_AVERAGE, SCALE_NEAREST, SCALE_NOT_ALLOWED |
| Constructor Summary | |
|---|---|
CanvasGraphicsItem(int width,
int height)
|
|
| Method Summary | |
|---|---|
int |
getContentHeight()
Gets the content's height in pixels. |
int |
getContentWidth()
Gets the content's width in pixels. |
protected abstract void |
paint(javax.microedition.lcdui.Graphics g)
Renders the CanvasGraphicsItem. |
void |
repaint()
Requests a repaint for the entire CanvasGraphicsItem. |
void |
repaint(int x,
int y,
int width,
int height)
Requests a repaint for the specified region of the CanvasGraphicsItem. |
void |
setParent(java.lang.Object theParent)
Set the parent object of this CanvasItem. |
| Methods inherited from class com.nokia.mid.ui.CanvasItem |
|---|
getHeight, getParent, getPositionX, getPositionY, getWidth, getZPosition, isValidImageAnchor, isVisible, scale, scale, setPosition, setScalingMode, setSize, setSize, setVisible, setZPosition |
| Methods inherited from class java.lang.Object |
|---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CanvasGraphicsItem(int width,
int height)
throws java.lang.IllegalArgumentException
java.lang.IllegalArgumentException| Method Detail |
|---|
public void setParent(java.lang.Object theParent)
setParent in class CanvasItemtheParent - the parent object
java.lang.IllegalArgumentException - if parent is not a valid object with which a
TextEditor can be associated, or if CanvasItem is already set to
another another parentprotected abstract void paint(javax.microedition.lcdui.Graphics g)
g - the Graphics object to be used for rendering the Canvaspublic void repaint()
public void repaint(int x,
int y,
int width,
int height)
x - the x coordinate of the rectangle to be repaintedy - the y coordinate of the rectangle to be repaintedwidth - the width of the rectangle to be repaintedheight - the height of the rectangle to be repaintedpublic int getContentWidth()
CanvasItem.getWidth().
public int getContentHeight()
CanvasItem.getHeight().
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||