|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object sky.monome.frame.DefaultFrame sky.monome.frame.CharacterFrame
public class CharacterFrame
Frame which displays a character.
This frame has a size of 8x8, and uses a new Font("Lucida Sans Typewriter",Font.PLAIN,8)
for displaying the character.
The character can be modified after construction, and the frame automatically notifies its frame listeners.
Field Summary |
---|
Fields inherited from class sky.monome.frame.DefaultFrame |
---|
height, matrix, width |
Constructor Summary | |
---|---|
CharacterFrame()
Constructs a character frame with a default space character. |
|
CharacterFrame(char character)
Constructs a character frame with the specified character. |
Method Summary | |
---|---|
void |
addFrameListener(FrameListener<CharacterFrame> frameListener)
Adds the specified frame listener to the list of frame listeners. |
void |
fireFrameChanged(CharacterFrame dynamicFrame)
Invoked when a frame change occurs. |
char |
getCharacter()
Returns the character that is currently being displayed on this frame. |
FrameListener<CharacterFrame>[] |
getFrameListeners()
Returns an array of all frame listeners. |
int |
getHeight()
Returns the height of this frame. |
int |
getWidth()
Returns the width of this frame. |
void |
removeFrameListener(FrameListener<CharacterFrame> frameListener)
Removes the specified frame listener from the list of frame listeners. |
void |
setCharacter(char character)
Modifies the character that is currently being displayed on this frame. |
Methods inherited from class sky.monome.frame.DefaultFrame |
---|
clear, clear, get, set |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public CharacterFrame()
public CharacterFrame(char character)
character
- Character to display in this character frame.Method Detail |
---|
public char getCharacter()
public void setCharacter(char character)
character
- New character that will be displayed on this frame.public void addFrameListener(FrameListener<CharacterFrame> frameListener)
addFrameListener
in interface DynamicFrame<CharacterFrame>
frameListener
- Frame listener to add to the list of frame listeners.public void removeFrameListener(FrameListener<CharacterFrame> frameListener)
removeFrameListener
in interface DynamicFrame<CharacterFrame>
frameListener
- Frame listener to remove from the list of frame listeners.public FrameListener<CharacterFrame>[] getFrameListeners()
getFrameListeners
in interface DynamicFrame<CharacterFrame>
public void fireFrameChanged(CharacterFrame dynamicFrame)
fireFrameChanged
in interface DynamicFrame<CharacterFrame>
dynamicFrame
- Dynamic frame that triggered the frame event.public int getWidth()
getWidth
in interface SizedFrame
getWidth
in class DefaultFrame
public int getHeight()
getHeight
in interface SizedFrame
getHeight
in class DefaultFrame
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |