1bbe1b32bSmrg/************************************************************ 2bbe1b32bSmrg 3bbe1b32bSmrgCopyright 1998 by Thomas E. Dickey <dickey@clark.net> 4bbe1b32bSmrg 5bbe1b32bSmrg All Rights Reserved 6bbe1b32bSmrg 7bbe1b32bSmrgPermission to use, copy, modify, and distribute this software and its 8bbe1b32bSmrgdocumentation for any purpose and without fee is hereby granted, 9bbe1b32bSmrgprovided that the above copyright notice appear in all copies and that 10bbe1b32bSmrgboth that copyright notice and this permission notice appear in 11bbe1b32bSmrgsupporting documentation, and that the name of the above listed 12bbe1b32bSmrgcopyright holder(s) not be used in advertising or publicity pertaining 13bbe1b32bSmrgto distribution of the software without specific, written prior 14bbe1b32bSmrgpermission. 15bbe1b32bSmrg 16bbe1b32bSmrgTHE ABOVE LISTED COPYRIGHT HOLDER(S) DISCLAIM ALL WARRANTIES WITH REGARD 17bbe1b32bSmrgTO THIS SOFTWARE, INCLUDING ALL IMPLIED WARRANTIES OF MERCHANTABILITY 18bbe1b32bSmrgAND FITNESS, IN NO EVENT SHALL THE ABOVE LISTED COPYRIGHT HOLDER(S) BE 19bbe1b32bSmrgLIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 20bbe1b32bSmrgWHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 21bbe1b32bSmrgACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 22bbe1b32bSmrgOR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 23bbe1b32bSmrg 24bbe1b32bSmrg********************************************************/ 25bbe1b32bSmrg 26bbe1b32bSmrg#ifndef _DIFSUTILS_H 27bbe1b32bSmrg#define _DIFSUTILS_H 1 28bbe1b32bSmrg 29bbe1b32bSmrg#include <misc.h> 30bbe1b32bSmrg#include <auth.h> 31bbe1b32bSmrg#include <X11/fonts/font.h> 32bbe1b32bSmrg#include <X11/fonts/fontstruct.h> 3340c5823bSmrg#include <X11/fonts/libxfont2.h> 34bbe1b32bSmrg 35bbe1b32bSmrgtypedef void (*DifsWakeupFunc)(pointer data, int result, unsigned long * pReadmask); 36bbe1b32bSmrgtypedef Bool (*DifsWorkFunc) (ClientPtr, pointer); 37bbe1b32bSmrg 38bbe1b32bSmrgextern AuthContextPtr GetClientAuthorization (void); 39bbe1b32bSmrgextern Bool ClientIsAsleep (ClientPtr client); 40bbe1b32bSmrgextern Bool ClientSleep (ClientPtr client, Bool (*function) (ClientPtr, pointer), pointer data); 41bbe1b32bSmrgextern Bool QueueWorkProc (DifsWorkFunc function, ClientPtr client, pointer data); 4240c5823bSmrgextern Bool RegisterBlockAndWakeupHandlers (FontBlockHandlerProcPtr blockHandler, DifsWakeupFunc wakeupHandler, pointer blockData); 43bbe1b32bSmrg#if 0 44bbe1b32bSmrgextern FontResolutionPtr GetClientResolutions (int *num); 45bbe1b32bSmrg#endif 46bbe1b32bSmrg#if 0 47bbe1b32bSmrgextern int GetDefaultPointSize (void); 48bbe1b32bSmrg#endif 49bbe1b32bSmrgextern int SetDefaultResolutions (char *str); 50bbe1b32bSmrg#if 0 51bbe1b32bSmrgextern int client_auth_generation (ClientPtr client); 52bbe1b32bSmrg#endif 5340c5823bSmrgextern int set_font_authorizations (char **authorizations, int *authlen, void *_client); 5434f90d55Smrgextern int strncmpnocase (const char *first, const char *second, int n); 55bbe1b32bSmrgextern pointer Xalloc (unsigned long m); 56bbe1b32bSmrgextern pointer Xrealloc (pointer n, unsigned long m); 57bbe1b32bSmrgextern void BlockHandler (OSTimePtr pTimeout, pointer pReadmask); 58bbe1b32bSmrgextern void ClientWakeup (ClientPtr client); 59bbe1b32bSmrgextern void InitBlockAndWakeupHandlers (void); 60bbe1b32bSmrgextern void ProcessWorkQueue (void); 6140c5823bSmrgextern void RemoveBlockAndWakeupHandlers (FontBlockHandlerProcPtr blockHandler, DifsWakeupFunc wakeupHandler, pointer blockData); 62bbe1b32bSmrgextern void SetDefaultPointSize (int ps); 63bbe1b32bSmrgextern void WakeupHandler (int result, unsigned long * pReadmask); 64bbe1b32bSmrgextern void Xfree (unsigned long *n); 65bbe1b32bSmrgextern pointer Xcalloc (unsigned long n); 66bbe1b32bSmrg 67bbe1b32bSmrg#endif /* _DIFSUTILS_H */ 68