943N/A/* Copyright (c) 1993, 1994, Oracle and/or its affiliates. All rights reserved.
258N/A *
258N/A * Permission is hereby granted, free of charge, to any person obtaining a
919N/A * copy of this software and associated documentation files (the "Software"),
919N/A * to deal in the Software without restriction, including without limitation
919N/A * the rights to use, copy, modify, merge, publish, distribute, sublicense,
919N/A * and/or sell copies of the Software, and to permit persons to whom the
919N/A * Software is furnished to do so, subject to the following conditions:
258N/A *
919N/A * The above copyright notice and this permission notice (including the next
919N/A * paragraph) shall be included in all copies or substantial portions of the
919N/A * Software.
258N/A *
919N/A * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
919N/A * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
919N/A * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
919N/A * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
919N/A * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
919N/A * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
919N/A * DEALINGS IN THE SOFTWARE.
258N/A */
258N/A
258N/A
258N/A#ifndef _TRANSOVL_H_
258N/A#define _TRANSOVL_H_
258N/A
258N/A#if defined(__cplusplus)
258N/Aextern "C" {
258N/A#endif
258N/A
258N/A#ifndef _TRANSOVL_SERVER_
258N/A
258N/A#include <X11/Xlib.h>
258N/A#include <X11/Xutil.h>
258N/A
258N/A#endif /* _TRANSOVL_SERVER_ */
258N/A
258N/A#define X_OvlQueryVersion 0
258N/A#define X_OvlGetPartners 1
258N/A#define X_OvlGetSharedPixels 2
258N/A#define X_OvlGetSharedColors 3
258N/A#define X_OvlCreateWindow 4
258N/A#define X_OvlIsOverlayWindow 5
258N/A#define X_OvlSetWindowTransparent 6
258N/A#define X_OvlSetPaintType 7
258N/A#define X_OvlCopyPaintType 8
258N/A#define X_OvlCopyAreaAndPaintType 9
258N/A#define X_OvlReadScreen 10
258N/A
258N/A#define OvlNumberEvents 0
258N/A
258N/Atypedef enum {
258N/A XSolarisOvlPaintTransparent,
258N/A XSolarisOvlPaintOpaque
258N/A} XSolarisOvlPaintType;
258N/A
258N/Atypedef enum {
258N/A XSolarisOvlSuccess,
258N/A XSolarisOvlQualifiedSuccess,
258N/A XSolarisOvlCriteriaFailure,
258N/A XSolarisOvlFailure
258N/A} XSolarisOvlSelectStatus;
258N/A
258N/Atypedef enum {
258N/A XSolarisOvlSelectBestOverlay,
258N/A XSolarisOvlSelectBestUnderlay
258N/A} XSolarisOvlSelectType;
258N/A
258N/Atypedef struct {
258N/A unsigned long hardCriteriaMask;
258N/A unsigned long softCriteriaMask;
258N/A int c_class;
258N/A unsigned int depth;
258N/A unsigned int minColors;
258N/A unsigned int minRed;
258N/A unsigned int minGreen;
258N/A unsigned int minBlue;
258N/A unsigned int minBitsPerRGB;
258N/A unsigned int minBuffers;
258N/A} XSolarisOvlVisualCriteria;
258N/A
258N/Atypedef struct {
258N/A XSolarisOvlVisualCriteria overlayCriteria;
258N/A XSolarisOvlVisualCriteria underlayCriteria;
258N/A} XSolarisOvlPairCriteria;
258N/A
258N/A#define XSolarisOvlVisualClass (1L<<0)
258N/A#define XSolarisOvlDepth (1L<<1)
258N/A#define XSolarisOvlMinColors (1L<<2)
258N/A#define XSolarisOvlMinRed (1L<<3)
258N/A#define XSolarisOvlMinGreen (1L<<4)
258N/A#define XSolarisOvlMinBlue (1L<<5)
258N/A#define XSolarisOvlMinBitsPerRGB (1L<<6)
258N/A#define XSolarisOvlMinBuffers (1L<<7)
258N/A#define XSolarisOvlUnsharedPixels (1L<<8)
258N/A#define XSolarisOvlUnsharedColors (1L<<9)
258N/A#define XSolarisOvlPreferredPartner (1L<<10)
258N/A
258N/A#define XSolarisOvlCopyOpaque (1L<<0)
258N/A#define XSolarisOvlCopyTransparent (1L<<1)
258N/A#define XSolarisOvlCopyAll (XSolarisOvlCopyOpaque|XSolarisOvlCopyTransparent)
258N/A
258N/A#ifndef _TRANSOVL_SERVER_
258N/A
258N/A#if defined(__STDC__) || defined(__cplusplus)
258N/Aextern Bool XSolarisOvlQueryExtension(Display *, int *, int *);
258N/A
258N/Aextern Status XSolarisOvlQueryVersion(Display *, int *, int *);
258N/A
258N/Aextern Window XSolarisOvlCreateWindow(Display *, Window, int, int,
258N/A unsigned int, unsigned int, unsigned int, int,
258N/A unsigned int, Visual *, unsigned long, XSetWindowAttributes *);
258N/A
258N/Aextern Bool XSolarisOvlIsOverlayWindow(Display *, Window);
258N/A
258N/Aextern void XSolarisOvlSetWindowTransparent(Display *, Window);
258N/A
258N/Aextern Status XSolarisOvlSetPaintType(Display *, GC, XSolarisOvlPaintType);
258N/A
258N/Aextern XSolarisOvlPaintType XSolarisOvlGetPaintType(Display *, GC);
258N/A
258N/Aextern Status XSolarisOvlCopyPaintType(Display *, Drawable, Drawable, GC,
258N/A int, int, unsigned int, unsigned int, int, int,
258N/A unsigned long, unsigned long);
258N/A
258N/Aextern Status XSolarisOvlCopyAreaAndPaintType(Display *,
258N/A Drawable, Drawable, Drawable, Drawable,
258N/A GC, GC, int, int, int, int,
258N/A unsigned int, unsigned int, int, int, int, int,
258N/A unsigned long, unsigned long);
258N/A
258N/Aextern XImage *XReadScreen(Display *, Window, int, int, unsigned int, unsigned int, Bool);
258N/A
258N/Aextern XSolarisOvlSelectStatus XSolarisOvlSelectPartner(Display *, int, VisualID,
258N/A XSolarisOvlSelectType, int, XSolarisOvlVisualCriteria *, XVisualInfo *,
258N/A unsigned long *);
258N/A
258N/Aextern XSolarisOvlSelectStatus XSolarisOvlSelectPair(Display *, int, int,
258N/A XSolarisOvlPairCriteria *, XVisualInfo *, XVisualInfo *,
258N/A unsigned long *, unsigned long *);
258N/A#else
258N/Aextern Bool XSolarisOvlQueryExtension();
258N/Aextern Status XSolarisOvlQueryVersion();
258N/Aextern Window XSolarisOvlCreateWindow();
258N/Aextern Bool XSolarisOvlIsOverlayWindow();
258N/Aextern void XSolarisOvlSetWindowTransparent();
258N/Aextern Status XSolarisOvlSetPaintType();
258N/Aextern XSolarisOvlPaintType XSolarisOvlGetPaintType();
258N/Aextern Status XSolarisOvlCopyPaintType();
258N/Aextern Status XSolarisOvlCopyAreaAndPaintType();
258N/Aextern XImage *XReadScreen();
258N/Aextern XSolarisOvlSelectStatus XSolarisOvlSelectPartner();
258N/Aextern XSolarisOvlSelectStatus XSolarisOvlSelectPair();
258N/A#endif
258N/A
258N/A#endif /* _TRANSOVL_SERVER_ */
258N/A
258N/A#if defined(__cplusplus)
258N/A}
258N/A#endif
258N/A
258N/A#endif /* _TRANSOVL_H_ */