1bbe1b32bSmrg/*
2bbe1b32bSmrg * Copyright (C) 1999 The XFree86 Project, Inc.  All Rights Reserved.
3bbe1b32bSmrg *
4bbe1b32bSmrg * Permission is hereby granted, free of charge, to any person obtaining a copy
5bbe1b32bSmrg * of this software and associated documentation files (the "Software"), to
6bbe1b32bSmrg * deal in the Software without restriction, including without limitation the
7bbe1b32bSmrg * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or
8bbe1b32bSmrg * sell copies of the Software, and to permit persons to whom the Software is
9bbe1b32bSmrg * furnished to do so, subject to the following conditions:
10bbe1b32bSmrg *
11bbe1b32bSmrg * The above copyright notice and this permission notice shall be included in
12bbe1b32bSmrg * all copies or substantial portions of the Software.
13bbe1b32bSmrg *
14bbe1b32bSmrg * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15bbe1b32bSmrg * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16bbe1b32bSmrg * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL THE
17bbe1b32bSmrg * XFREE86 PROJECT BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
18bbe1b32bSmrg * IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
19bbe1b32bSmrg * CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
20bbe1b32bSmrg *
21bbe1b32bSmrg * Except as contained in this notice, the name of the XFree86 Project shall
22bbe1b32bSmrg * not be used in advertising or otherwise to promote the sale, use or other
23bbe1b32bSmrg * dealings in this Software without prior written authorization from the
24bbe1b32bSmrg * XFree86 Project.
25bbe1b32bSmrg */
26bbe1b32bSmrg#ifndef _DIFS_H
27bbe1b32bSmrg#define _DIFS_H
28bbe1b32bSmrg
29bbe1b32bSmrg#include "difsfn.h"
30bbe1b32bSmrg#include "globals.h"
31bbe1b32bSmrg#include <X11/fonts/fontstruct.h>
32bbe1b32bSmrg
33bbe1b32bSmrgtypedef int (*InitialFunc)(ClientPtr);
34bbe1b32bSmrgtypedef int (*ProcFunc)(ClientPtr);
35bbe1b32bSmrgtypedef int (*SwappedProcFunc)(ClientPtr);
36bbe1b32bSmrgtypedef void (*ReplySwapFunc)(ClientPtr, int, void *);
37bbe1b32bSmrg
38bbe1b32bSmrgextern InitialFunc InitialVector[3];
39bbe1b32bSmrgextern ReplySwapFunc ReplySwapVector[NUM_PROC_VECTORS];
40bbe1b32bSmrg
41bbe1b32bSmrg/* FIXME: this is derived from fontstruct.h; should integrate it */
42bbe1b32bSmrg
43bbe1b32bSmrg/* difs/atom.c */
44bbe1b32bSmrgextern void InitAtoms ( void );
45bbe1b32bSmrg
46bbe1b32bSmrg/* difs/charinfo.c */
47bbe1b32bSmrgextern int GetExtents ( ClientPtr client, FontPtr pfont, Mask flags, unsigned long num_ranges, fsRange *range, unsigned long *num_extents, fsXCharInfo **data );
48bbe1b32bSmrgextern int GetBitmaps ( ClientPtr client, FontPtr pfont, fsBitmapFormat format, Mask flags, unsigned long num_ranges, fsRange *range, int *size, unsigned long *num_glyphs, fsOffset32 **offsets, pointer *data, int *freeData );
49bbe1b32bSmrg
50bbe1b32bSmrg/* difs/initfonts.c */
51bbe1b32bSmrgextern void InitFonts ( void );
52bbe1b32bSmrg
53bbe1b32bSmrg/* difs/fonts.c */
54bbe1b32bSmrgextern int FontToFSError ( int err );
55bbe1b32bSmrgextern int OpenFont ( ClientPtr client, Font fid, fsBitmapFormat format, fsBitmapFormatMask format_mask, int namelen, char *name );
56bbe1b32bSmrgextern int CloseClientFont ( ClientFontPtr cfp, FSID fid );
57bbe1b32bSmrgextern int SetFontCatalogue ( char *str, int *badpath );
58bbe1b32bSmrgextern int ListFonts ( ClientPtr client, int length, unsigned char *pattern, int maxNames );
59bbe1b32bSmrg#if 0
60bbe1b32bSmrgextern int StartListFontsWithInfo ( ClientPtr client, int length, unsigned char *pattern, int maxNames );
61bbe1b32bSmrg#endif
62bbe1b32bSmrgextern int LoadGlyphRanges ( ClientPtr client, FontPtr pfont, Bool range_flag, int num_ranges, int item_size, fsChar2b *data );
63bbe1b32bSmrgextern FontPtr find_old_font ( FSID id );
64bbe1b32bSmrgextern void DeleteClientFontStuff ( ClientPtr client );
6540c5823bSmrgextern int xfs_init_fs_handlers(FontPathElementPtr fpe,
6640c5823bSmrg                                FontBlockHandlerProcPtr block_handler);
6740c5823bSmrg
6840c5823bSmrgextern void xfs_remove_fs_handlers(FontPathElementPtr fpe,
6940c5823bSmrg                                   FontBlockHandlerProcPtr block_handler,
7040c5823bSmrg                                   Bool all);
7140c5823bSmrgextern int register_fpe_funcs(const xfont2_fpe_funcs_rec *funcs);
72bbe1b32bSmrg
73bbe1b32bSmrg/* difs/fontinfo.c */
74bbe1b32bSmrgextern int convert_props ( FontInfoPtr pinfo, fsPropInfo **props );
75bbe1b32bSmrgextern int QueryExtents ( ClientPtr client, ClientFontPtr cfp, int item_size, int nranges, Bool range_flag, pointer range_data );
76bbe1b32bSmrgextern int QueryBitmaps ( ClientPtr client, ClientFontPtr cfp, int item_size, fsBitmapFormat format, int nranges, Bool range_flag, pointer range_data );
77bbe1b32bSmrg
78e1db7cd1Smrg/* difs/swaprep.c */
79e1db7cd1Smrgextern void _X_COLD ReplySwapNotImplemented(ClientPtr, int, void *);
80bbe1b32bSmrg
81bbe1b32bSmrg#endif
82