Requests.h revision eaef79e5
1eaef79e5Smrg/* $Xorg: Requests.h,v 1.4 2001/02/09 02:05:28 xorgcvs Exp $ */
2eaef79e5Smrg/*
3eaef79e5Smrg
4eaef79e5SmrgCopyright 1989, 1998  The Open Group
5eaef79e5Smrg
6eaef79e5SmrgPermission to use, copy, modify, distribute, and sell this software and its
7eaef79e5Smrgdocumentation for any purpose is hereby granted without fee, provided that
8eaef79e5Smrgthe above copyright notice appear in all copies and that both that
9eaef79e5Smrgcopyright notice and this permission notice appear in supporting
10eaef79e5Smrgdocumentation.
11eaef79e5Smrg
12eaef79e5SmrgThe above copyright notice and this permission notice shall be included
13eaef79e5Smrgin all copies or substantial portions of the Software.
14eaef79e5Smrg
15eaef79e5SmrgTHE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS
16eaef79e5SmrgOR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
17eaef79e5SmrgMERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
18eaef79e5SmrgIN NO EVENT SHALL THE OPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR
19eaef79e5SmrgOTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
20eaef79e5SmrgARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
21eaef79e5SmrgOTHER DEALINGS IN THE SOFTWARE.
22eaef79e5Smrg
23eaef79e5SmrgExcept as contained in this notice, the name of The Open Group shall
24eaef79e5Smrgnot be used in advertising or otherwise to promote the sale, use or
25eaef79e5Smrgother dealings in this Software without prior written authorization
26eaef79e5Smrgfrom The Open Group.
27eaef79e5Smrg
28eaef79e5Smrg*/
29eaef79e5Smrg/* $XFree86: xc/programs/bitmap/Requests.h,v 1.4 2001/01/17 23:44:51 dawes Exp $ */
30eaef79e5Smrg
31eaef79e5Smrg/*
32eaef79e5Smrg * Author:  Davor Matic, MIT X Consortium
33eaef79e5Smrg */
34eaef79e5Smrg
35eaef79e5Smrg#ifndef _Requests_h
36eaef79e5Smrg#define _Requests_h
37eaef79e5Smrg
38eaef79e5Smrgtypedef int (*DrawOnePointProc)(Widget, Position, Position, int);
39eaef79e5Smrgtypedef int (*DrawTwoPointProc)(Widget, Position, Position,
40eaef79e5Smrg				Position, Position, int);
41eaef79e5Smrgtypedef int (*InterfaceProc)(Widget);
42eaef79e5Smrg
43eaef79e5Smrgtypedef struct {
44eaef79e5Smrg    Boolean  success;
45eaef79e5Smrg    Position at_x, at_y;
46eaef79e5Smrg    Position from_x, from_y,
47eaef79e5Smrg             to_x, to_y;
48eaef79e5Smrg    XtPointer draw;
49eaef79e5Smrg    int      value;
50eaef79e5Smrg    Time     btime;
51eaef79e5Smrg    int      state;
52eaef79e5Smrg} BWStatus;
53eaef79e5Smrg
54eaef79e5Smrgextern void OnePointEngage ( Widget w, BWStatus *status, XtPointer draw, int *state );
55eaef79e5Smrgextern void OnePointTerminate ( Widget w, BWStatus *status, XtPointer draw );
56eaef79e5Smrgextern void OnePointTerminateTransparent ( Widget w, BWStatus *status, XtPointer draw );
57eaef79e5Smrgextern void DragOnePointEngage ( Widget w, BWStatus *status, XtPointer draw, int *state );
58eaef79e5Smrgextern void DragOnePointTerminate ( Widget w, BWStatus *status, XtPointer client_data );
59eaef79e5Smrgextern void TwoPointsEngage ( Widget w, BWStatus *status, XtPointer draw, int *state );
60eaef79e5Smrgextern void TwoPointsTerminate ( Widget w, BWStatus *status, XtPointer draw );
61eaef79e5Smrgextern void TwoPointsTerminateTransparent ( Widget w, BWStatus *status, XtPointer draw );
62eaef79e5Smrgextern void TwoPointsTerminateTimed ( Widget w, BWStatus *status, XtPointer draw );
63eaef79e5Smrgextern void DragTwoPointsEngage ( Widget w, BWStatus *status, XtPointer draw, int *state );
64eaef79e5Smrgextern void DragTwoPointsTerminate ( Widget w, BWStatus *status, XtPointer draw );
65eaef79e5Smrgextern void Interface ( Widget w, BWStatus *status, XtPointer action );
66eaef79e5Smrgextern void Paste ( Widget w, Position at_x, Position at_y, int value );
67eaef79e5Smrg
68eaef79e5Smrgextern void BWDragMarked(Widget w, Position at_x, Position at_y);
69eaef79e5Smrgextern void BWDragStored(Widget w, Position at_x, Position at_y);
70eaef79e5Smrgextern void BWCopy(Widget w, Position at_x, Position at_y, int value);
71eaef79e5Smrgextern void BWMove(Widget w, Position at_x, Position at_y, int value);
72eaef79e5Smrgextern void BWRestore(Widget w, Position at_x, Position at_y, int value);
73eaef79e5Smrgextern void BWDrawPoint(Widget w, Position x, Position y, bit value);
74eaef79e5Smrgextern void BWBlindLine(Widget w, Position from_x, Position from_y,
75eaef79e5Smrg			Position to_x, Position to_y, int value);
76eaef79e5Smrgextern void BWDrawHotSpot(Widget w, Position x, Position y, int value);
77eaef79e5Smrgextern void BWZoomIn(Widget w, Position from_x, Position from_y,
78eaef79e5Smrg		     Position to_x, Position to_y);
79eaef79e5Smrg
80eaef79e5Smrgextern void OnePointHandler(Widget w, XtPointer client_data,
81eaef79e5Smrg			    XEvent *event, Boolean *cont);
82eaef79e5Smrgextern void TwoPointsHandler(Widget w, XtPointer client_data,
83eaef79e5Smrg			     XEvent *event, Boolean *cont);
84eaef79e5Smrgextern void DragTwoPointsHandler(Widget w, XtPointer client_data,
85eaef79e5Smrg				 XEvent *event, Boolean *cont);
86eaef79e5Smrg
87eaef79e5Smrg#endif /* _Requests_h */
88