get_mbutton ( : : : Row, Column, Button )

Wait until a mouse button is pressed.

get_mbutton returns the coordinates of the mouse pointer in the current output window and the mouse button pressed (Button):

                  Button = 1: Left button,
                           2: Middle button,
                           4: Right button.
The operator waits until a button is pressed in the current output window. If more than one button is pressed, the sum of the individual buttons' values is returned. The origin of the coordinate system is located in the left upper corner of the window. The row coordinates increase towards the bottom, while the column coordinates increase towards the right. For graphics windows, the coordinates of the lower right corner are (image height-1,image width-1) (see open_window, init_horus), while for text windows they are (window height-1,window width-1) (see open_textwindow).


Attention

get_mbutton only returns if a mouse button is pressed in the current window.


Parameters

Row (output_control)
point.y -> integer
Row coordinate of the mouse position in the window.

Column (output_control)
point.x -> integer
Column coordinate of the mouse position in the window.

Button (output_control)
integer -> integer
Mouse button(s) pressed.


Result

get_mbutton returns the value TRUE if a window is active. Otherwise, an exception is raised.


Possible Predecessors

open_window, set_window, open_textwindow


Alternatives

get_mposition, which_window


See also

open_window, open_textwindow



Copyright © 1996-1997 MVTec Software GmbH