Distributed Multihead X  1.16.4
dmxwindow.c File Reference
#include "dmx.h"
#include "dmxsync.h"
#include "dmxwindow.h"
#include "dmxpixmap.h"
#include "dmxcmap.h"
#include "dmxvisual.h"
#include "dmxinput.h"
#include "dmxextension.h"
#include "dmxpict.h"
#include "windowstr.h"

Functions

static void dmxDoRestackWindow (WindowPtr pWindow)
 
static void dmxDoChangeWindowAttributes (WindowPtr pWindow, unsigned long *mask, XSetWindowAttributes *attribs)
 
static void dmxDoSetShape (WindowPtr pWindow)
 
Bool dmxInitWindow (ScreenPtr pScreen)
 
Window dmxCreateRootWindow (WindowPtr pWindow)
 
void dmxResizeScreenWindow (ScreenPtr pScreen, int x, int y, int w, int h)
 
void dmxResizeRootWindow (WindowPtr pRoot, int x, int y, int w, int h)
 
void dmxGetDefaultWindowAttributes (WindowPtr pWindow, Colormap *cmap, Visual **visual)
 
static Window dmxCreateNonRootWindow (WindowPtr pWindow)
 
void dmxCreateAndRealizeWindow (WindowPtr pWindow, Bool doSync)
 
Bool dmxCreateWindow (WindowPtr pWindow)
 
Bool dmxBEDestroyWindow (WindowPtr pWindow)
 
Bool dmxDestroyWindow (WindowPtr pWindow)
 
Bool dmxPositionWindow (WindowPtr pWindow, int x, int y)
 
Bool dmxChangeWindowAttributes (WindowPtr pWindow, unsigned long mask)
 
Bool dmxRealizeWindow (WindowPtr pWindow)
 
Bool dmxUnrealizeWindow (WindowPtr pWindow)
 
void dmxRestackWindow (WindowPtr pWindow, WindowPtr pOldNextSib)
 
static Bool dmxWindowExposurePredicate (Display *dpy, XEvent *ev, XPointer ptr)
 
void dmxWindowExposures (WindowPtr pWindow, RegionPtr prgn, RegionPtr other_exposed)
 
void dmxCopyWindow (WindowPtr pWindow, DDXPointRec ptOldOrg, RegionPtr prgnSrc)
 
void dmxResizeWindow (WindowPtr pWindow, int x, int y, unsigned int w, unsigned int h, WindowPtr pSib)
 
void dmxReparentWindow (WindowPtr pWindow, WindowPtr pPriorParent)
 
void dmxChangeBorderWidth (WindowPtr pWindow, unsigned int width)
 
void dmxSetShape (WindowPtr pWindow, int kind)
 

Detailed Description

This file provides support for window-related functions.

Function Documentation

Bool dmxBEDestroyWindow ( WindowPtr  pWindow)

Destroy pWindow on the back-end server.

References _DMXScreenInfo::beDisplay, DMX_GET_WINDOW_PRIV, dmxScreens, and _dmxWinPriv::window.

Referenced by dmxBEDestroyWindowTree(), and dmxDestroyWindow().

void dmxChangeBorderWidth ( WindowPtr  pWindow,
unsigned int  width 
)
Bool dmxChangeWindowAttributes ( WindowPtr  pWindow,
unsigned long  mask 
)
void dmxCopyWindow ( WindowPtr  pWindow,
DDXPointRec  ptOldOrg,
RegionPtr  prgnSrc 
)

Move pWindow on the back-end server. Determine whether or not it is on or offscreen, and realize it if it is newly on screen and the lazy window creation optimization is enabled.

References _DMXScreenInfo::beDisplay, DMX_GET_WINDOW_PRIV, DMX_UNWRAP, DMX_UPDATE_COPY, DMX_WINDOW_OFFSCREEN, DMX_WRAP, dmxCopyWindow(), dmxCreateAndRealizeWindow(), dmxScreens, dmxSync(), dmxUpdateWindowInfo(), _dmxWinPriv::mapped, _dmxWinPriv::offscreen, and _dmxWinPriv::window.

Referenced by dmxCopyWindow(), and dmxScreenInit().

void dmxCreateAndRealizeWindow ( WindowPtr  pWindow,
Bool  doSync 
)

This function handles lazy window creation and realization. Window creation is handled by dmxCreateNonRootWindow(). It also handles any stacking changes that have occured since the window was originally created by calling dmxDoRestackWindow(). If the window is shaped, the shape is set on the back-end server by calling dmxDoSetShape(), and if the window has pictures (from RENDER) associated with it, those pictures are created on the back-end server by calling dmxCreatePictureList(). If doSync is TRUE, then dmxSync() is called.

References _DMXScreenInfo::beDisplay, DMX_GET_WINDOW_PRIV, dmxCreateNonRootWindow(), dmxCreatePictureList(), dmxDoRestackWindow(), dmxDoSetShape(), dmxScreens, dmxSync(), _dmxWinPriv::hasPict, _dmxWinPriv::isShaped, _dmxWinPriv::mapped, _dmxWinPriv::restacked, and _dmxWinPriv::window.

Referenced by dmxBECreateWindowTree(), dmxCopyWindow(), dmxCreateNonRootWindow(), dmxForceWindowCreation(), dmxPositionWindow(), dmxRealizeWindow(), dmxReparentWindow(), and dmxResizeWindow().

Bool dmxDestroyWindow ( WindowPtr  pWindow)

Destroy pWindow on the back-end server. If any RENDER pictures were created, destroy them as well.

References DMX_GET_WINDOW_PRIV, DMX_UNWRAP, DMX_WRAP, dmxBEDestroyWindow(), dmxDestroyPictureList(), dmxDestroyWindow(), dmxScreens, and dmxSync().

Referenced by dmxDestroyWindow(), and dmxScreenInit().

static void dmxDoChangeWindowAttributes ( WindowPtr  pWindow,
unsigned long *  mask,
XSetWindowAttributes *  attribs 
)
static
static void dmxDoRestackWindow ( WindowPtr  pWindow)
static
static void dmxDoSetShape ( WindowPtr  pWindow)
static
void dmxGetDefaultWindowAttributes ( WindowPtr  pWindow,
Colormap *  cmap,
Visual **  visual 
)
Bool dmxInitWindow ( ScreenPtr  pScreen)

Initialize the private area for the window functions.

References dmxWinPrivateKeyRec.

Referenced by dmxScreenInit().

Bool dmxPositionWindow ( WindowPtr  pWindow,
int  x,
int  y 
)
Bool dmxRealizeWindow ( WindowPtr  pWindow)

Realize pWindow on the back-end server. If the lazy window creation optimization is enabled, the window is only realized when it at least partially overlaps the screen.

References _DMXScreenInfo::beDisplay, DMX_GET_WINDOW_PRIV, DMX_UNWRAP, DMX_UPDATE_REALIZE, DMX_WINDOW_OFFSCREEN, DMX_WRAP, dmxCreateAndRealizeWindow(), dmxRealizeWindow(), dmxScreens, dmxSync(), dmxUpdateWindowInfo(), _dmxWinPriv::mapped, _dmxWinPriv::offscreen, and _dmxWinPriv::window.

Referenced by dmxRealizeWindow(), and dmxScreenInit().

void dmxReparentWindow ( WindowPtr  pWindow,
WindowPtr  pPriorParent 
)
void dmxResizeRootWindow ( WindowPtr  pRoot,
int  x,
int  y,
int  w,
int  h 
)

Change the location and size of the "root" window. Called from dmxCreateWindow.

References _DMXScreenInfo::beDisplay, DMX_GET_WINDOW_PRIV, dmxScreens, dmxSync(), _dmxWinPriv::mapped, and _dmxWinPriv::window.

Referenced by dmxCreateWindow().

void dmxResizeScreenWindow ( ScreenPtr  pScreen,
int  x,
int  y,
int  w,
int  h 
)

Change the location and size of the "screen" window. Called from dmxextension.c dmxConfigureScreenWindow().

References _DMXScreenInfo::beDisplay, dmxScreens, dmxSync(), and _DMXScreenInfo::scrnWin.

void dmxResizeWindow ( WindowPtr  pWindow,
int  x,
int  y,
unsigned int  w,
unsigned int  h,
WindowPtr  pSib 
)

Resize pWindow on the back-end server. Determine whether or not it is on or offscreen, and realize it if it is newly on screen and the lazy window creation optimization is enabled.

References _DMXScreenInfo::beDisplay, DMX_GET_WINDOW_PRIV, DMX_UNWRAP, DMX_UPDATE_RESIZE, DMX_WINDOW_OFFSCREEN, DMX_WRAP, dmxCreateAndRealizeWindow(), dmxResizeWindow(), dmxScreens, dmxSync(), dmxUpdateWindowInfo(), _dmxWinPriv::mapped, _dmxWinPriv::offscreen, and _dmxWinPriv::window.

Referenced by dmxResizeWindow(), and dmxScreenInit().

void dmxRestackWindow ( WindowPtr  pWindow,
WindowPtr  pOldNextSib 
)
void dmxSetShape ( WindowPtr  pWindow,
int  kind 
)
static Bool dmxWindowExposurePredicate ( Display *  dpy,
XEvent *  ev,
XPointer  ptr 
)
static

Referenced by dmxWindowExposures().

void dmxWindowExposures ( WindowPtr  pWindow,
RegionPtr  prgn,
RegionPtr  other_exposed 
)

Handle exposures on pWindow. Since window exposures are handled in DMX, the events that are generated by the back-end server are redundant, so we eat them here.

References _DMXScreenInfo::beDisplay, DMX_GET_WINDOW_PRIV, DMX_UNWRAP, DMX_WRAP, dmxScreens, dmxSync(), dmxWindowExposurePredicate(), dmxWindowExposures(), and _dmxWinPriv::window.

Referenced by dmxScreenInit(), and dmxWindowExposures().


Generated on Tue Aug 18 2015 01:27:31 for Distributed Multihead X by doxygen 1.8.8