|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--sub_arctic.lib.min_interactor | +--sub_arctic.lib.base_interactor | +--sub_arctic.lib.multi_button | +--sub_arctic.lib.menu_button
Field Summary | |
protected java.awt.Font |
_font
The font for this object. |
protected menu |
_menu
This holds a pointer to our menu that we will pop up. |
protected java.lang.String |
_text
The text string on this object. |
protected int |
_x_spacing
The x spacing for this object. |
protected int |
_y_spacing
The y spacing for this object. |
Fields inherited from class sub_arctic.lib.multi_button |
_callback_obj,
_cur_state,
_in_transition,
_state_looks,
_transition_looks,
BUTTON_ACTION_CALLBACK |
Fields inherited from class sub_arctic.lib.base_interactor |
_child_index,
_child_list,
_clip_bounds,
_constraint_flags,
_enabled_constraint,
_flags,
_h,
_h_constraint,
_parent,
_part_a_constraint,
_part_b_constraint,
_user_data,
_visible_constraint,
_w,
_w_constraint,
_x,
_x_constraint,
_y,
_y_constraint,
default_child_hint |
Constructor Summary | |
menu_button(java.lang.String s,
java.awt.Font f,
menu m)
Construct a menu button given a string and a given font. |
|
menu_button(java.lang.String s,
menu m)
Construct a menu button given a string. |
Method Summary | |
void |
menu_done()
This method gets called by the menu_agent to inform us that the interaction is completed. |
boolean |
menu_modify(int x,
int y,
event evt)
This function is called to alert the notifier that the interaction is now over their area. |
menu |
popup_menu()
This returns the menu we are currently using as our popup. |
boolean |
press(event e,
java.lang.Object user_info)
This function is called in response to a press method. |
boolean |
release(event e,
java.lang.Object user_info)
|
void |
set_font(java.awt.Font f)
Set the font associated with this object. |
void |
set_popup_menu(menu m)
This sets the value of the current popup menu. |
void |
set_text(java.lang.String t)
Set the text of this object. |
void |
set_x_spacing(int x)
Set the x spacing. |
void |
set_y_spacing(int y)
Set the y spacing. |
protected void |
style_changed()
Redraw the images for this menu button. |
java.lang.String |
text()
Retrieve the text value on this object. |
int |
x_spacing()
Get the x spacing. |
int |
y_spacing()
Get the y spacing. |
Methods inherited from class sub_arctic.lib.multi_button |
calc_size,
callback_obj,
cur_state,
do_action,
do_callback,
draw_self_local,
first_callback_num,
get_state_look,
get_transition_look,
inout_drag_end,
inout_drag_enter,
inout_drag_exit,
inout_drag_start,
intrinsic_constraints,
last_callback_num,
next_state,
part_a,
set_callback_obj,
set_cur_state,
set_looks,
set_part_a,
set_raw_part_a,
set_state_look,
set_transition_look,
state_looks,
transition_looks |
Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
wait,
wait,
wait |
Field Detail |
protected int _x_spacing
protected int _y_spacing
protected menu _menu
protected java.lang.String _text
protected java.awt.Font _font
Constructor Detail |
public menu_button(java.lang.String s, menu m)
String
- s the string to display on the menu button.menu
- m the menu to pop up when the button is pressed.public menu_button(java.lang.String s, java.awt.Font f, menu m)
String
- s the string to display on the menu button.Font
- f font we draw labels in.menu
- m the menu to pop up when the button is pressed.Method Detail |
public int x_spacing()
public void set_x_spacing(int x)
int
- x the new value for the x spacingpublic int y_spacing()
public void set_y_spacing(int y)
int
- y the new value for the y spacingpublic menu popup_menu()
public void set_popup_menu(menu m)
menu
- m the new menu to usepublic boolean press(event e, java.lang.Object user_info)
event
- e the event to dispatch (the mouse down).Object
- user_info (currently ignored) the object passed to the
pick_collector at pick-time.public boolean release(event e, java.lang.Object user_info)
public java.lang.String text()
public void set_text(java.lang.String t)
String
- t the new text to display on this menu buttonpublic void set_font(java.awt.Font f)
Font
- f the new fontprotected void style_changed()
public void menu_done()
public boolean menu_modify(int x, int y, event evt)
int
- x the x coordinate (in the notifiers coordinate system) of
the cursor.int
- y the y coordinate (in the notifiers coordinate system) of
the cursor.event
- evt the event we are testing.
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |