1af7c02bdSmrg/* 2af7c02bdSmrg * Copyright © 2003 Keith Packard 3af7c02bdSmrg * 4af7c02bdSmrg * Permission to use, copy, modify, distribute, and sell this software and its 5af7c02bdSmrg * documentation for any purpose is hereby granted without fee, provided that 6af7c02bdSmrg * the above copyright notice appear in all copies and that both that 7af7c02bdSmrg * copyright notice and this permission notice appear in supporting 8af7c02bdSmrg * documentation, and that the name of Keith Packard not be used in 9af7c02bdSmrg * advertising or publicity pertaining to distribution of the software without 10af7c02bdSmrg * specific, written prior permission. Keith Packard makes no 11af7c02bdSmrg * representations about the suitability of this software for any purpose. It 12af7c02bdSmrg * is provided "as is" without express or implied warranty. 13af7c02bdSmrg * 14af7c02bdSmrg * KEITH PACKARD DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, 15af7c02bdSmrg * INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO 16af7c02bdSmrg * EVENT SHALL KEITH PACKARD BE LIABLE FOR ANY SPECIAL, INDIRECT OR 17af7c02bdSmrg * CONSEQUENTIAL DAMAGES OR ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, 18af7c02bdSmrg * DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER 19af7c02bdSmrg * TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR 20af7c02bdSmrg * PERFORMANCE OF THIS SOFTWARE. 21af7c02bdSmrg */ 22af7c02bdSmrg 23af7c02bdSmrg#ifndef _XDAMAGE_H_ 24af7c02bdSmrg#define _XDAMAGE_H_ 25af7c02bdSmrg 26af7c02bdSmrg#include <X11/extensions/damagewire.h> 27af7c02bdSmrg#include <X11/extensions/Xfixes.h> 28af7c02bdSmrg#include <X11/Xfuncproto.h> 29af7c02bdSmrg 30af7c02bdSmrg#define XDAMAGE_1_1_INTERFACE 31af7c02bdSmrg 32af7c02bdSmrgtypedef XID Damage; 33af7c02bdSmrg 34af7c02bdSmrgtypedef struct { 35af7c02bdSmrg int type; /* event base */ 36af7c02bdSmrg unsigned long serial; 37af7c02bdSmrg Bool send_event; 38af7c02bdSmrg Display *display; 39af7c02bdSmrg Drawable drawable; 40af7c02bdSmrg Damage damage; 41af7c02bdSmrg int level; 42af7c02bdSmrg Bool more; /* more events will be delivered immediately */ 43af7c02bdSmrg Time timestamp; 44af7c02bdSmrg XRectangle area; 45af7c02bdSmrg XRectangle geometry; 46af7c02bdSmrg} XDamageNotifyEvent; 47af7c02bdSmrg 48af7c02bdSmrg_XFUNCPROTOBEGIN 49af7c02bdSmrg 5081c81b28SmrgBool XDamageQueryExtension (Display *dpy, 5181c81b28Smrg int *event_base_return, 5281c81b28Smrg int *error_base_return); 53af7c02bdSmrg 54af7c02bdSmrgStatus XDamageQueryVersion (Display *dpy, 5581c81b28Smrg int *major_version_return, 5681c81b28Smrg int *minor_version_return); 57af7c02bdSmrg 58af7c02bdSmrgDamage 59af7c02bdSmrgXDamageCreate (Display *dpy, Drawable drawable, int level); 60af7c02bdSmrg 61af7c02bdSmrgvoid 62af7c02bdSmrgXDamageDestroy (Display *dpy, Damage damage); 63af7c02bdSmrg 64af7c02bdSmrgvoid 656dda92f9SmrgXDamageSubtract (Display *dpy, Damage damage, 66af7c02bdSmrg XserverRegion repair, XserverRegion parts); 67af7c02bdSmrg 68af7c02bdSmrgvoid 69af7c02bdSmrgXDamageAdd (Display *dpy, Drawable drawable, XserverRegion region); 70af7c02bdSmrg 71af7c02bdSmrg_XFUNCPROTOEND 72af7c02bdSmrg 73af7c02bdSmrg#endif /* _XDAMAGE_H_ */ 74