Download include/X11/fonts/fontstruct.h from michaelu0826/phantom_env: direct link, hf CLI and curl.
- Browser
- Download file 9.4 kB
-
https://huggingface.co/datasets/michaelu0826/phantom_env/resolve/main/include/X11/fonts/fontstruct.h
- Command line
-
hf download hf://datasets/michaelu0826/phantom_env/include/X11/fonts/fontstruct.h
-
curl -L -o fontstruct.h https://huggingface.co/datasets/michaelu0826/phantom_env/resolve/main/include/X11/fonts/fontstruct.h
9.4 kB
| /*********************************************************** | |
| Copyright 1987 by Digital Equipment Corporation, Maynard, Massachusetts. | |
| All Rights Reserved | |
| Permission to use, copy, modify, and distribute this software and its | |
| documentation for any purpose and without fee is hereby granted, | |
| provided that the above copyright notice appear in all copies and that | |
| both that copyright notice and this permission notice appear in | |
| supporting documentation, and that the name of Digital not be | |
| used in advertising or publicity pertaining to distribution of the | |
| software without specific, written prior permission. | |
| DIGITAL DISCLAIMS ALL WARRANTIES WITH REGARD TO THIS SOFTWARE, INCLUDING | |
| ALL IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS, IN NO EVENT SHALL | |
| DIGITAL BE LIABLE FOR ANY SPECIAL, INDIRECT OR CONSEQUENTIAL DAMAGES OR | |
| ANY DAMAGES WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, | |
| WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, | |
| ARISING OUT OF OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS | |
| SOFTWARE. | |
| ******************************************************************/ | |
| /* | |
| * This version of the server font data structure is only for describing | |
| * the in memory data structure. The file structure is not necessarily a | |
| * copy of this. That is up to the compiler and the OS layer font loading | |
| * machinery. | |
| */ | |
| typedef struct _FontProp { | |
| long name; | |
| long value; /* assumes ATOM is not larger than INT32 */ | |
| } FontPropRec; | |
| typedef struct _FontResolution { | |
| unsigned short x_resolution; | |
| unsigned short y_resolution; | |
| unsigned short point_size; | |
| } FontResolutionRec; | |
| typedef struct _ExtentInfo { | |
| DrawDirection drawDirection; | |
| int fontAscent; | |
| int fontDescent; | |
| int overallAscent; | |
| int overallDescent; | |
| int overallWidth; | |
| int overallLeft; | |
| int overallRight; | |
| } ExtentInfoRec; | |
| typedef struct _CharInfo { | |
| xCharInfo metrics; /* info preformatted for Queries */ | |
| char *bits; /* pointer to glyph image */ | |
| } CharInfoRec; | |
| /* | |
| * Font is created at font load time. It is specific to a single encoding. | |
| * e.g. not all of the glyphs in a font may be part of a single encoding. | |
| */ | |
| typedef struct _FontInfo { | |
| unsigned short firstCol; | |
| unsigned short lastCol; | |
| unsigned short firstRow; | |
| unsigned short lastRow; | |
| unsigned short defaultCh; | |
| unsigned int noOverlap:1; | |
| unsigned int terminalFont:1; | |
| unsigned int constantMetrics:1; | |
| unsigned int constantWidth:1; | |
| unsigned int inkInside:1; | |
| unsigned int inkMetrics:1; | |
| unsigned int allExist:1; | |
| unsigned int drawDirection:2; | |
| unsigned int cachable:1; | |
| unsigned int anamorphic:1; | |
| short maxOverlap; | |
| short pad; | |
| xCharInfo maxbounds; | |
| xCharInfo minbounds; | |
| xCharInfo ink_maxbounds; | |
| xCharInfo ink_minbounds; | |
| short fontAscent; | |
| short fontDescent; | |
| int nprops; | |
| FontPropPtr props; | |
| char *isStringProp; | |
| } FontInfoRec; | |
| typedef struct _Font { | |
| int refcnt; | |
| FontInfoRec info; | |
| char bit; | |
| char byte; | |
| char glyph; | |
| char scan; | |
| fsBitmapFormat format; | |
| int (*get_glyphs) (FontPtr /* font */, | |
| unsigned long /* count */, | |
| unsigned char * /* chars */, | |
| FontEncoding /* encoding */, | |
| unsigned long * /* count */, | |
| CharInfoPtr * /* glyphs */); | |
| int (*get_metrics) (FontPtr /* font */, | |
| unsigned long /* count */, | |
| unsigned char * /* chars */, | |
| FontEncoding /* encoding */, | |
| unsigned long * /* count */, | |
| xCharInfo ** /* glyphs */); | |
| void (*unload_font) (FontPtr /* font */); | |
| void (*unload_glyphs) (FontPtr /* font */); | |
| FontPathElementPtr fpe; | |
| void *svrPrivate; | |
| void *fontPrivate; | |
| void *fpePrivate; | |
| int maxPrivate; | |
| void **devPrivates; | |
| } FontRec; | |
| typedef struct _FontNames { | |
| int nnames; | |
| int size; | |
| int *length; | |
| char **names; | |
| } FontNamesRec; | |
| /* External view of font paths */ | |
| typedef struct _FontPathElement { | |
| int name_length; | |
| const | |
| char *name; | |
| int type; | |
| int refcount; | |
| void *private; | |
| } FontPathElementRec; | |
| typedef Bool (*NameCheckFunc) (const char *name); | |
| typedef int (*InitFpeFunc) (FontPathElementPtr fpe); | |
| typedef int (*FreeFpeFunc) (FontPathElementPtr fpe); | |
| typedef int (*ResetFpeFunc) (FontPathElementPtr fpe); | |
| typedef int (*OpenFontFunc) ( void *client, | |
| FontPathElementPtr fpe, | |
| Mask flags, | |
| const char* name, | |
| int namelen, | |
| fsBitmapFormat format, | |
| fsBitmapFormatMask fmask, | |
| XID id, | |
| FontPtr* pFont, | |
| char** aliasName, | |
| FontPtr non_cachable_font); | |
| typedef void (*CloseFontFunc) (FontPathElementPtr fpe, FontPtr pFont); | |
| typedef int (*ListFontsFunc) (void *client, | |
| FontPathElementPtr fpe, | |
| const char* pat, | |
| int len, | |
| int max, | |
| FontNamesPtr names); | |
| typedef int (*StartLfwiFunc) (void *client, | |
| FontPathElementPtr fpe, | |
| const char* pat, | |
| int len, | |
| int max, | |
| void ** privatep); | |
| typedef int (*NextLfwiFunc) (void *client, | |
| FontPathElementPtr fpe, | |
| char** name, | |
| int* namelen, | |
| FontInfoPtr* info, | |
| int* numFonts, | |
| void *private); | |
| typedef int (*WakeupFpeFunc) (FontPathElementPtr fpe, | |
| unsigned long* LastSelectMask); | |
| typedef void (*ClientDiedFunc) (void *client, | |
| FontPathElementPtr fpe); | |
| typedef int (*LoadGlyphsFunc) (void *client, | |
| FontPtr pfont, | |
| Bool range_flag, | |
| unsigned int nchars, | |
| int item_size, | |
| unsigned char* data); | |
| typedef int (*StartLaFunc) (void *client, | |
| FontPathElementPtr fpe, | |
| const char* pat, | |
| int len, | |
| int max, | |
| void ** privatep); | |
| typedef int (*NextLaFunc) (void *client, | |
| FontPathElementPtr fpe, | |
| char** namep, | |
| int* namelenp, | |
| char** resolvedp, | |
| int* resolvedlenp, | |
| void *private); | |
| typedef void (*SetPathFunc)(void); | |
| typedef struct _FPEFunctions { | |
| NameCheckFunc name_check; | |
| InitFpeFunc init_fpe; | |
| ResetFpeFunc reset_fpe; | |
| FreeFpeFunc free_fpe; | |
| OpenFontFunc open_font; | |
| CloseFontFunc close_font; | |
| ListFontsFunc list_fonts; | |
| StartLaFunc start_list_fonts_and_aliases; | |
| NextLaFunc list_next_font_or_alias; | |
| StartLfwiFunc start_list_fonts_with_info; | |
| NextLfwiFunc list_next_font_with_info; | |
| WakeupFpeFunc wakeup_fpe; | |
| ClientDiedFunc client_died; | |
| /* for load_glyphs, range_flag = 0 -> | |
| nchars = # of characters in data | |
| item_size = bytes/char | |
| data = list of characters | |
| range_flag = 1 -> | |
| nchars = # of fsChar2b's in data | |
| item_size is ignored | |
| data = list of fsChar2b's */ | |
| LoadGlyphsFunc load_glyphs; | |
| SetPathFunc set_path_hook; | |
| } FPEFunctionsRec, FPEFunctions; | |
| /* | |
| * Various macros for computing values based on contents of | |
| * the above structures | |
| */ | |
| /* | |
| * Macros for computing different bounding boxes for fonts; from | |
| * the font protocol | |
| */ | |