|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--irc.style.CharactersDrawer
Atomic characters drawer. The CharactersDrawer handles graphical and/or vectorial smileys.
Field Summary |
Fields inherited from interface java.awt.image.ImageObserver |
ABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH |
Constructor Summary | |
CharactersDrawer(IRCConfiguration config)
Create a new CharactersDrawer. |
Method Summary | |
java.lang.String |
decodeLine(java.lang.String line)
Prepare and decode the given line for smileys. |
void |
draw(java.lang.String str,
java.awt.Graphics g,
java.awt.FontMetrics fm,
int x,
int y)
Draw the given prepared line. |
int |
getHeight(java.lang.String str,
java.awt.FontMetrics fm)
Get the given string height, in pixel. |
int |
getWidth(java.lang.String str,
java.awt.FontMetrics fm)
Get the given string width, in pixel. |
void |
getWidthHeight(java.lang.String str,
java.awt.FontMetrics fm,
java.awt.Dimension res)
Get the given string width and height, in pixel. |
boolean |
imageUpdate(java.awt.Image img,
int infoflags,
int x,
int y,
int width,
int height)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
public CharactersDrawer(IRCConfiguration config)
config
- the irc configuration.Method Detail |
public java.lang.String decodeLine(java.lang.String line)
line
- source line, before smileys replacement.
public int getWidth(java.lang.String str, java.awt.FontMetrics fm)
str
- the prepared line.fm
- the FontMetrics that will be used on display.
public int getHeight(java.lang.String str, java.awt.FontMetrics fm)
str
- the prepared line.fm
- the FontMetrics that will be used on display.
public void getWidthHeight(java.lang.String str, java.awt.FontMetrics fm, java.awt.Dimension res)
str
- the prepared line.fm
- the FontMetrics that will be used on display.public void draw(java.lang.String str, java.awt.Graphics g, java.awt.FontMetrics fm, int x, int y)
str
- prepared line to draw.g
- graphics to draw onto.fm
- fontmetrics to use.x
- x position.y
- y position.public boolean imageUpdate(java.awt.Image img, int infoflags, int x, int y, int width, int height)
imageUpdate
in interface java.awt.image.ImageObserver
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |