1
#include <grass/config.h>
6
#include <grass/raster.h>
7
#include <grass/graphics.h>
12
* \brief get mouse location using a box
14
* Identical to <i>R_get_location_with_line</i> except a rubber-band box is
15
* used instead of a rubber-band line.
16
* <b>button</b> is set to: 1 - left, 2 - middle, 3 - right
26
void REM_get_location_with_box(int cx, int cy, int *wx, int *wy, int *button)
28
_send_ident(GET_LOCATION_WITH_BOX);
39
* \brief get mouse location using a line
41
* Similar to <i>R_get_location_with_pointer</i> except the pointer is
42
* replaced by a line which has one end fixed at the coordinate identified
43
* by the <b>x,y</b> values. The other end of the line is initialized at the
44
* coordinate identified by the <b>nx,ny</b> pointers. This end then tracks
45
* the mouse until a button is pressed. The mouse button (1 for left, 2 for
46
* middle, and 3 for right) is returned in the <b>button</b> pointer.
56
void REM_get_location_with_line(int cx, int cy, int *wx, int *wy, int *button)
58
_send_ident(GET_LOCATION_WITH_LINE);
69
* \brief get mouse location using pointer
71
* A cursor is put on the screen at the location specified by the coordinate
72
* found at the <b>wx,wy</b> pointers. This cursor tracks the mouse (or
73
* other pointing device) until one of three mouse buttons are pressed. Upon
74
* pressing, the cursor is removed from the screen, the current mouse
75
* coordinates are returned by the <b>wx</b> and <b>wy</b> pointers, and the
76
* mouse button (1 for left, 2 for middle, and 3 for right) is returned in
77
* the <b>button</b> pointer.
85
void REM_get_location_with_pointer(int *wx, int *wy, int *button)
87
*button = 0; /* ?, how button = -1 is used (see driver) */
89
_send_ident(GET_LOCATION_WITH_POINTER);
98
#endif /* HAVE_SOCKET */