|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectlejos.nxt.TextMenu
public class TextMenu
Displays a list of items. The select() method allows the user to scroll the list using the right and left keys to scroll forward and backward through the list. The number maximum number of rows, and an optional title can be specified.
Field Summary | |
---|---|
static String |
blank
a blank line |
Constructor Summary | |
---|---|
TextMenu(String[] items)
This constructor sets the menu size to 8 rows, the top linw is in display row 0 |
|
TextMenu(String[] items,
int size,
int topRow)
This constructor allows specification of the size and top row of the menu. |
|
TextMenu(String[] items,
int size,
String title)
This constuctor allows the specfication of a title (of up to 16 characters) displayed in row 0, and the size of the menu. |
Method Summary | |
---|---|
int |
select()
Allows the to scroll through the items, using the right and left buttons. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait |
Field Detail |
---|
public static String blank
Constructor Detail |
---|
public TextMenu(String[] items)
public TextMenu(String[] items, int size, int topRow)
public TextMenu(String[] items, int size, String title)
items
- - string array containing the menu items. Null strings will produce a blank line in the display.Method Detail |
---|
public int select()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |