xcharmouse.h revision 492d43a5
1492d43a5Smrg/* $XTermId: xcharmouse.h,v 1.12 2010/08/19 09:30:03 Ryan.Johnson Exp $ */
2d522f475Smrg
3d522f475Smrg/************************************************************
4d522f475Smrg
5d522f475SmrgCopyright 1998 by Jason Bacon <acadix@execpc.com>
6d522f475Smrg
7d522f475Smrg                        All Rights Reserved
8d522f475Smrg
9d522f475SmrgPermission to use, copy, modify, and distribute this software and its
10d522f475Smrgdocumentation for any purpose and without fee is hereby granted,
11d522f475Smrgprovided that the above copyright notice appear in all copies and that
12d522f475Smrgboth that copyright notice and this permission notice appear in
13d522f475Smrgsupporting documentation, and that the name of the above listed
14d522f475Smrgcopyright holder(s) not be used in advertising or publicity pertaining
15d522f475Smrgto distribution of the software without specific, written prior
16d522f475Smrgpermission.
17d522f475Smrg
18d522f475SmrgTHE ABOVE LISTED COPYRIGHT HOLDER(S) DISCLAIM ALL WARRANTIES WITH REGARD
19d522f475SmrgTO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY
20d522f475SmrgAND FITNESS, IN NO EVENT SHALL THE ABOVE LISTED COPYRIGHT HOLDER(S) BE
21d522f475SmrgLIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
22d522f475SmrgWHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
23d522f475SmrgACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
24d522f475SmrgOR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
25d522f475Smrg
26d522f475Smrg********************************************************/
27d522f475Smrg
28d522f475Smrg#ifndef included_xcharmouse_h
29d522f475Smrg#define included_xcharmouse_h
30d522f475Smrg
31d522f475Smrg/*
32d522f475Smrg * Macros for dpmodes
33d522f475Smrg * J. Bacon, acadix@execpc.com, June 1998
34d522f475Smrg * Steve Wall, September 1999
35d522f475Smrg * Ilya Zakharevich, August 2002
36d522f475Smrg */
37d522f475Smrg
38d522f475Smrg/* DECSET arguments for turning on mouse reporting modes */
39d522f475Smrg#define SET_X10_MOUSE               9
40d522f475Smrg#define SET_VT200_MOUSE             1000
41d522f475Smrg#define SET_VT200_HIGHLIGHT_MOUSE   1001
42d522f475Smrg#define SET_BTN_EVENT_MOUSE         1002
43d522f475Smrg#define SET_ANY_EVENT_MOUSE         1003
44d522f475Smrg
45d522f475Smrg#if OPT_FOCUS_EVENT
46d522f475Smrg#define SET_FOCUS_EVENT_MOUSE       1004 /* can be combined with above */
47d522f475Smrg#endif
48d522f475Smrg
49492d43a5Smrg/* Extend mouse tracking for terminals wider(taller) than 223 cols(rows) */
50492d43a5Smrg#define SET_EXT_MODE_MOUSE          1005 /* compatible with above */
51492d43a5Smrg
52d522f475Smrg#define SET_BUTTON1_MOVE_POINT      2001 /* click1 emit Esc seq to move point*/
53d522f475Smrg#define SET_BUTTON2_MOVE_POINT      2002 /* press2 emit Esc seq to move point*/
54d522f475Smrg#define SET_DBUTTON3_DELETE         2003 /* Double click-3 deletes */
55d522f475Smrg#define SET_PASTE_IN_BRACKET        2004 /* Surround paste by escapes */
56d522f475Smrg#define SET_PASTE_QUOTE             2005 /* Quote each char during paste */
57d522f475Smrg#define SET_PASTE_LITERAL_NL        2006 /* Paste "\n" as C-j */
58d522f475Smrg
59d522f475Smrg#if OPT_DEC_LOCATOR
60d522f475Smrg
61d522f475Smrg/* Bit fields for screen->locator_events */
62d522f475Smrg#define	LOC_BTNS_DN		0x1
63d522f475Smrg#define	LOC_BTNS_UP		0x2
64d522f475Smrg
65d522f475Smrg/* Special values for screen->loc_filter_* */
66d522f475Smrg#define	LOC_FILTER_POS		-1
67d522f475Smrg
68d522f475Smrg#endif /* OPT_DEC_LOCATOR */
69d522f475Smrg
70d522f475Smrg/* Values for screen->send_mouse_pos */
712eaa94a1Schristostypedef enum {
72d522f475Smrg    MOUSE_OFF
73d522f475Smrg    ,X10_MOUSE
74d522f475Smrg    ,VT200_MOUSE
75d522f475Smrg    ,VT200_HIGHLIGHT_MOUSE
76d522f475Smrg    ,BTN_EVENT_MOUSE
77d522f475Smrg    ,ANY_EVENT_MOUSE
78d522f475Smrg    ,DEC_LOCATOR
792eaa94a1Schristos} XtermMouseModes;
80d522f475Smrg
81d522f475Smrg#endif /* included_xcharmouse_h */
82