45e9809aff7304721fddb95654901b32195c9c7avboxsync/***********************************************************
45e9809aff7304721fddb95654901b32195c9c7avboxsyncCopyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts.
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync All Rights Reserved
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncPermission to use, copy, modify, and distribute this software and its
45e9809aff7304721fddb95654901b32195c9c7avboxsyncdocumentation for any purpose and without fee is hereby granted,
45e9809aff7304721fddb95654901b32195c9c7avboxsyncprovided that the above copyright notice appear in all copies and that
45e9809aff7304721fddb95654901b32195c9c7avboxsyncboth that copyright notice and this permission notice appear in
45e9809aff7304721fddb95654901b32195c9c7avboxsyncsupporting documentation, and that the name of Digital not be
45e9809aff7304721fddb95654901b32195c9c7avboxsyncused in advertising or publicity pertaining to distribution of the
45e9809aff7304721fddb95654901b32195c9c7avboxsyncsoftware without specific, written prior permission.
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncDIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING
45e9809aff7304721fddb95654901b32195c9c7avboxsyncALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL
45e9809aff7304721fddb95654901b32195c9c7avboxsyncDIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR
45e9809aff7304721fddb95654901b32195c9c7avboxsyncANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS,
45e9809aff7304721fddb95654901b32195c9c7avboxsyncWHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION,
45e9809aff7304721fddb95654901b32195c9c7avboxsyncARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS
45e9809aff7304721fddb95654901b32195c9c7avboxsyncSOFTWARE.
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync******************************************************************/
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifndef DIXFONT_H
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define DIXFONT_H 1
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "dix.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include <X11/fonts/font.h>
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include "closure.h"
45e9809aff7304721fddb95654901b32195c9c7avboxsync#include <X11/fonts/fontstruct.h>
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define NullDIXFontProp ((DIXFontPropPtr)0)
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _DIXFontProp *DIXFontPropPtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT Bool SetDefaultFont(char * /*defaultfontname*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void QueueFontWakeup(FontPathElementPtr /*fpe*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void RemoveFontWakeup(FontPathElementPtr /*fpe*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void FontWakeup(pointer /*data*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int /*count*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync pointer /*LastSelectMask*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int OpenFont(ClientPtr /*client*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync XID /*fid*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Mask /*flags*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned /*lenfname*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync char * /*pfontname*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int CloseFont(pointer /*pfont*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync XID /*fid*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsynctypedef struct _xQueryFontReply *xQueryFontReplyPtr;
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void QueryFont(FontPtr /*pFont*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync xQueryFontReplyPtr /*pReply*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int /*nProtoCCIStructs*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int ListFonts(ClientPtr /*client*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned char * /*pattern*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned int /*length*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned int /*max_names*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int
45e9809aff7304721fddb95654901b32195c9c7avboxsyncdoListFontsWithInfo(ClientPtr /*client*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync LFWIclosurePtr /*c*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int doPolyText(ClientPtr /*client*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync PTclosurePtr /*c*/
45e9809aff7304721fddb95654901b32195c9c7avboxsync);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int PolyText(ClientPtr /*client*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync DrawablePtr /*pDraw*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync GCPtr /*pGC*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned char * /*pElt*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned char * /*endReq*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int /*xorg*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int /*yorg*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int /*reqType*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync XID /*did*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int doImageText(ClientPtr /*client*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync ITclosurePtr /*c*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int ImageText(ClientPtr /*client*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync DrawablePtr /*pDraw*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync GCPtr /*pGC*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int /*nChars*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned char * /*data*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int /*xorg*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int /*yorg*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int /*reqType*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync XID /*did*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int SetFontPath(ClientPtr /*client*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int /*npaths*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned char * /*paths*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int * /*error*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int SetDefaultFontPath(char * /*path*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int GetFontPath(ClientPtr client,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int *count,
45e9809aff7304721fddb95654901b32195c9c7avboxsync int *length,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned char **result);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void DeleteClientFontStuff(ClientPtr /*client*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/* Quartz support on Mac OS X pulls in the QuickDraw
45e9809aff7304721fddb95654901b32195c9c7avboxsync framework whose InitFonts function conflicts here. */
45e9809aff7304721fddb95654901b32195c9c7avboxsync#ifdef __APPLE__
45e9809aff7304721fddb95654901b32195c9c7avboxsync#define InitFonts Darwin_X_InitFonts
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void InitFonts(void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void FreeFonts(void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT FontPtr find_old_font(XID /*id*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void GetGlyphs(FontPtr /*font*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned long /*count*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned char * /*chars*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync FontEncoding /*fontEncoding*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned long * /*glyphcount*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CharInfoPtr * /*glyphs*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void QueryGlyphExtents(FontPtr /*pFont*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CharInfoPtr * /*charinfo*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned long /*count*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync ExtentInfoPtr /*info*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT Bool QueryTextExtents(FontPtr /*pFont*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned long /*count*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync unsigned char * /*chars*/,
45e9809aff7304721fddb95654901b32195c9c7avboxsync ExtentInfoPtr /*info*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT Bool ParseGlyphCachingMode(char * /*str*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void InitGlyphCaching(void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void SetGlyphCachingMode(int /*newmode*/);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * libXfont/src/builtins/builtin.h
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void BuiltinRegisterFpeFunctions(void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync/*
45e9809aff7304721fddb95654901b32195c9c7avboxsync * libXfont stubs.
45e9809aff7304721fddb95654901b32195c9c7avboxsync */
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int client_auth_generation(ClientPtr client);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void DeleteFontClientID(Font id);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT FontResolutionPtr GetClientResolutions(int *num);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int GetDefaultPointSize(void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT Font GetNewFontClientID(void);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int init_fs_handlers(FontPathElementPtr fpe,
45e9809aff7304721fddb95654901b32195c9c7avboxsync BlockHandlerProcPtr block_handler);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int RegisterFPEFunctions(NameCheckFunc name_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync InitFpeFunc init_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync FreeFpeFunc free_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync ResetFpeFunc reset_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync OpenFontFunc open_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync CloseFontFunc close_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync ListFontsFunc list_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync StartLfwiFunc start_lfwi_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync NextLfwiFunc next_lfwi_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync WakeupFpeFunc wakeup_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync ClientDiedFunc client_died,
45e9809aff7304721fddb95654901b32195c9c7avboxsync LoadGlyphsFunc load_glyphs,
45e9809aff7304721fddb95654901b32195c9c7avboxsync StartLaFunc start_list_alias_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync NextLaFunc next_list_alias_func,
45e9809aff7304721fddb95654901b32195c9c7avboxsync SetPathFunc set_path_func);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT void remove_fs_handlers(FontPathElementPtr fpe,
45e9809aff7304721fddb95654901b32195c9c7avboxsync BlockHandlerProcPtr blockHandler,
45e9809aff7304721fddb95654901b32195c9c7avboxsync Bool all);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsyncextern _X_EXPORT int StoreFontClientFont(FontPtr pfont, Font id);
45e9809aff7304721fddb95654901b32195c9c7avboxsync
45e9809aff7304721fddb95654901b32195c9c7avboxsync#endif /* DIXFONT_H */