scrnintstr.h revision f78b12e570284aa8291f4ca1add24937fd107403
f78b12e570284aa8291f4ca1add24937fd107403vboxsync/***********************************************************
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncCopyright 1987, 1998 The Open Group
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncPermission to use, copy, modify, distribute, and sell this software and its
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncdocumentation for any purpose is hereby granted without fee, provided that
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncthe above copyright notice appear in all copies and that both that
f78b12e570284aa8291f4ca1add24937fd107403vboxsynccopyright notice and this permission notice appear in supporting
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncdocumentation.
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncThe above copyright notice and this permission notice shall be included in
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncall copies or substantial portions of the Software.
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncTHE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncIMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncFITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncOPEN GROUP BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncAN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncCONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncExcept as contained in this notice, the name of The Open Group shall not be
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncused in advertising or otherwise to promote the sale, use or other dealings
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncin this Software without prior written authorization from The Open Group.
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncCopyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.
f78b12e570284aa8291f4ca1add24937fd107403vboxsync All Rights Reserved
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncPermission to use, copy, modify, and distribute this software and its
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncdocumentation for any purpose and without fee is hereby granted,
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncprovided that the above copyright notice appear in all copies and that
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncboth that copyright notice and this permission notice appear in
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncsupporting documentation, and that the name of Digital not be
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncused in advertising or publicity pertaining to distribution of the
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncsoftware without specific, written prior permission.
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncDIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncDIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncWHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
f78b12e570284aa8291f4ca1add24937fd107403vboxsync******************************************************************/
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef struct _PixmapFormat {
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned char depth;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned char bitsPerPixel;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned char scanlinePad;
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef struct _Visual {
f78b12e570284aa8291f4ca1add24937fd107403vboxsync short nplanes;/* = log2 (ColormapEntries). This does not
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * imply that the screen has this many planes.
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * it may have more or fewer */
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef struct _Depth {
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned char depth;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync VisualID *vids; /* block of visual ids for this depth */
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef struct _ScreenSaverStuff {
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*xstate*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * There is a typedef for each screen function pointer so that code that
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * needs to declare a screen function pointer (e.g. in a screen private
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * or as a local variable) can easily do so and retain full type checking.
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*index*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* QueryBestSizeProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*class*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned short * /*pwidth*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned short * /*pheight*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*on*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* GetImageProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*sx*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*sy*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned int /*format*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned long /*planeMask*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync char * /*pdstLine*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* GetSpansProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*wMax*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int* /*pwidth*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*nspans*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync char * /*pdstStart*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* SourceValidateProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*width*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*height*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned int /*subWindowMode*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*y*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned long /*mask*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* RestackWindowProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef int (* ValidateTreeProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* PostValidateTreeProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* WindowExposuresProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* CopyWindowProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* ClearToBackgroundProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* ClipNotifyProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*dx*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*dy*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsync/* pixmap will exist only for the duration of the current rendering operation */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync/* pixmap will be the backing pixmap for a redirected window */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync/* pixmap will contain a glyph */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*width*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*height*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*depth*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned /*usage_hint*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* ConstrainCursorProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* CursorLimitsProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* RecolorCursorProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* DestroyColormapProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* InstallColormapProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* UninstallColormapProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* StoreColorsProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*ndef*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* ResolveColorProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned short* /*pred*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned short* /*pgreen*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned short* /*pblue*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*major*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*minor*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*screenNum*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*screenNum*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned long /*result*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*width*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*height*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*depth*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*bitsPerPixel*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*devKind*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* SetWindowPixmapProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* SetScreenPixmapProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* MarkWindowProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef int (* ConfigNotifyProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*bw*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* MoveWindowProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* ResizeWindowProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned int /*w*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned int /*h*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* HandleExposuresProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* ReparentWindowProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* SetShapeProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /* kind */);
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef void (* ChangeBorderWidthProcPtr)(
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned int /*width*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef struct _Screen {
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int myNum; /* index of this instance in Screens[] */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned char rootDepth;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned long rootVisual;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync unsigned long defColormap;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* next field is a stipple to use as default in
f78b12e570284aa8291f4ca1add24937fd107403vboxsync a GC. we don't build default tiles of all depths
f78b12e570284aa8291f4ca1add24937fd107403vboxsync because they are likely to be of a color
f78b12e570284aa8291f4ca1add24937fd107403vboxsync different from the default fg pixel, so
f78b12e570284aa8291f4ca1add24937fd107403vboxsync we don't win anything by building
f78b12e570284aa8291f4ca1add24937fd107403vboxsync a standard one.
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* Random screen procedures */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* Window Procedures */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync ChangeWindowAttributesProcPtr ChangeWindowAttributes;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* Pixmap procedures */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* Font procedures */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* Cursor Procedures */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync ConstrainCursorHarderProcPtr ConstrainCursorHarder;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* GC procedures */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* Colormap procedures */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync ListInstalledColormapsProcPtr ListInstalledColormaps;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* Region procedures */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* os layer procedures */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* anybody can get a piece of this array */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync CreateScreenResourcesProcPtr CreateScreenResources;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync PixmapPtr pScratchPixmap; /* scratch pixmap "pool" */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync MarkOverlappedWindowsProcPtr MarkOverlappedWindows;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* Device cursor procedures */
f78b12e570284aa8291f4ca1add24937fd107403vboxsync DeviceCursorInitializeProcPtr DeviceCursorInitialize;
f78b12e570284aa8291f4ca1add24937fd107403vboxsync /* set it in driver side if X server can copy the framebuffer content.
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * Meant to be used together with '-background none' option, avoiding
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * malicious users to steal framebuffer's content if that would be the
f78b12e570284aa8291f4ca1add24937fd107403vboxsync * default */
f78b12e570284aa8291f4ca1add24937fd107403vboxsyncstatic inline RegionPtr BitmapToRegion(ScreenPtr _pScreen, PixmapPtr pPix) {
f78b12e570284aa8291f4ca1add24937fd107403vboxsync return (*(_pScreen)->BitmapToRegion)(pPix); /* no mi version?! */
f78b12e570284aa8291f4ca1add24937fd107403vboxsynctypedef struct _ScreenInfo {
f78b12e570284aa8291f4ca1add24937fd107403vboxsync int /*argc*/,
f78b12e570284aa8291f4ca1add24937fd107403vboxsync char ** /*argv*/);
f78b12e570284aa8291f4ca1add24937fd107403vboxsync#endif /* SCREENINTSTRUCT_H */