public class XPMImage extends Object
Modifier and Type | Field and Description |
---|---|
static String |
COLOUR_BLACK_TILE
Constant
COLOUR_BLACK_TILE="\"8 8 1 1\" \"b c black\" \"bbbbbbbb\" "{trunked} |
static String |
COLOUR_DEFAULT_PITCH_TILE
Constant
COLOUR_DEFAULT_PITCH_TILE="\"8 8 1 1\" \" c None\" \" \" \"{trunked} |
static String |
COLOUR_RED_TILE
Constant
COLOUR_RED_TILE="\"8 8 1 1\" \"r c red\" \"rrrrrrrr\" \""{trunked} |
static String |
COLOUR_WHITE_TILE
Constant
COLOUR_WHITE_TILE="\"8 8 1 1\" \"w c white\" \"wwwwwwww\" "{trunked} |
Constructor and Description |
---|
XPMImage()
Creates an XPM Image the default colour of the pitch.
|
Modifier and Type | Method and Description |
---|---|
int |
getArrayHeight()
Returns the array height as an array index.
|
int |
getArrayWidth()
Returns the array width as an array index.
|
String |
getTile(int x,
int y)
Gets a tile of the XPM Image.
|
int |
getTileHeight()
Returns the tile height.
|
int |
getTileWidth()
Returns the tile width.
|
int |
getXPMHeight()
Returns the XPM image height.
|
int |
getXPMWidth()
Returns the XPM image width.
|
void |
setTile(int x,
int y,
String tile)
Updates an 8*8 tile in the XPM Image.
|
public static final String COLOUR_BLACK_TILE
COLOUR_BLACK_TILE="\"8 8 1 1\" \"b c black\" \"bbbbbbbb\" "{trunked}
public static final String COLOUR_DEFAULT_PITCH_TILE
COLOUR_DEFAULT_PITCH_TILE="\"8 8 1 1\" \" c None\" \" \" \"{trunked}
public static final String COLOUR_RED_TILE
COLOUR_RED_TILE="\"8 8 1 1\" \"r c red\" \"rrrrrrrr\" \""{trunked}
public static final String COLOUR_WHITE_TILE
COLOUR_WHITE_TILE="\"8 8 1 1\" \"w c white\" \"wwwwwwww\" "{trunked}
public String getTile(int x, int y)
x
- Between 0 and 31.y
- Between 0 and 7.public void setTile(int x, int y, String tile)
x
- Between 0 and 31.y
- Between 0 and 7.tile
- An XPM image string defining an 8*8 image.public int getXPMHeight()
public int getXPMWidth()
public int getTileWidth()
public int getTileHeight()
public int getArrayHeight()
public int getArrayWidth()
Copyright © 2003–2015 Atan. All rights reserved.