home *** CD-ROM | disk | FTP | other *** search
- #ifndef WFMCLIENTDEF
- #define WFMCLIENTDEF
-
- #include <fmclient.h>
-
- #ifdef __cplusplus
- extern "C" {
- #endif
-
- void wfm_init(void);
-
- void wfm_cmov(
- float /* x */,
- float /* y */,
- float /* z */
- );
-
- void wfm_cmov2(
- float /* x */,
- float /* y */
- );
-
- void wfm_cmovi(
- int /* x */,
- int /* y */,
- int /* z */
- );
-
- void wfm_cmov2i(
- int /* x */,
- int /* y */
- );
-
- void wfm_cmovs(
- short /* x */,
- short /* y */,
- short /* z */
- );
-
- void wfm_cmov2s(
- short /* x */,
- short /* y */
- );
-
- void wfm_enumerate(
- void (*callback)(char *)
- );
-
- void wfm_sizeenumerate(
- char * /* name */,
- void (*callback)(long)
- );
-
- void wfm_fontunits(
- float /* pixelsperpoint */
- );
-
- long wfm_makefont(
- long /* fontnum */,
- char * /* name */,
- float[2][2] /* mat */,
- int /* charnamec */,
- char ** /* charnamev */
- );
-
- long wfm_font(
- long /* fontnum */
- );
-
- long wfm_getfont(
- void
- );
-
- void wfm_charstr(
- const char * /* str */
- );
-
- void wfm_charstrn(
- const char * /* str */,
- int /* chrcount */
- );
-
- void wfm_charstrl(
- void * /* str */,
- int /* chrcount */,
- int /* bytesperchr */
- );
-
- void wfm_skipspace(
- float /* wid */
- );
-
- float wfm_strwidth(
- const char * /* str */
- );
-
- /* bytesperchr can be 1, 2, or 4 in a call to wfm_strnwidth */
- float wfm_strnwidth(
- void * /* str */,
- int /* chrcount */,
- int /* bytesperchr */
- );
-
- void wfm_strbounds(
- const char * /* str */,
- long * /* llx */,
- long * /* lly */,
- long * /* urx */,
- long * /* ury */
- );
-
- /* bytesperchr can be 1, 2, or 4 in a call to wfm_strnbounds */
- void wfm_strnbounds(
- void * /* str */,
- int /* chrcount */,
- int /* bytesperchr */,
- long * /* llx */,
- long * /* lly */,
- long * /* urx */,
- long * /* ury */
- );
-
- void wfm_freefont(
- long /* fontnum */
- );
-
- void wfm_setfontpath(
- const char * /* path */
- );
-
- void wfm_fontpath(
- char * /* path */,
- long /* len */
- );
-
- void wfm_makefontmat(
- float[2][2] /* mat */,
- float /* angle */,
- float /* size */
- );
-
- void wfm_cpack(
- long /* c */
- );
-
- void wfm_color(
- int /* c */
- );
-
- void wfm_aacolor(
- int /* cfull */,
- int /* fhalf */
- );
-
- void wfm_aacpack(
- long /* cfull */,
- long /* fhalf */
- );
-
- void wfm_hint(
- long /* hinttype */,
- long /* value */
- );
-
- long wfm_getfontinfo(
- long /* fontnum */,
- fmfontinfo * /* info */
- );
-
- long wfm_getcharmetrics(
- long /* fontnum */,
- fmglyphinfo * /* glyphinfo */
- );
-
- long wfm_outchar(
- const unsigned int /* code */
- );
-
- void wfm_pos(
- float /* x */,
- float /* y */
- );
-
- void wfm_rpos(
- float /* x */,
- float /* y */
- );
-
- /* values for the font type hint FONTHINT_TYPE */
- #define FM_FONTTYPE_ALL 0 /* use all types of fonts */
- #define FM_FONTTYPE_BITMAP 1 /* use only bitmap fonts */
- #define FM_FONTTYPE_OUTLINE 2 /* use only outline fonts */
-
- #define FONTHINT_SCALETHRESH (1) /* bound to font */
- #define FONTHINT_MINOUTLINESIZE (2) /* bound to font */
- #define FONTHINT_MAXAASIZE (3) /* bound to font */
- #define FONTHINT_ROUNDADVANCE (4) /* bound to font */
- #define FONTHINT_AABITMAPFONTS (5) /* bound to font */
- #define FONTHINT_TYPE (6) /* font type hint */
- #define FONTHINT_ENCODING (7) /* font encoding hint */
-
- /* values for the font encoding hint FONTHINT_ENCODING */
- #define FM_ENC_ALL 0 /* all encodings (default) */
- #define FM_ENC_ASCII 1 /* ASCII */
- #define FM_ENC_ISO88591 2 /* ISO8859-1 */
- #define FM_ENC_ADOBE 4 /* Adobe (228) characters in text fonts */
- #define FM_ENC_SPECIFIC 8 /* font specific (e.g., Symbol font) */
- #define FM_ENC_JISX020819760 16 /* JISX0208.1976-0 */
- #define FM_ENC_JISX020119760 32 /* JISX0201.1976-0 */
- #define FM_ENC_JISX020819830 64 /* JISX0208.1983-0 */
- #define FM_ENC_DECTECH 128 /* DEC DECTECH */
- #define FM_ENC_SUNOLCURSOR1 256 /* SUN OLD CURSOR 1 */
- #define FM_ENC_SUNOLGLYPH1 1024 /* SUN OLD GLYPH 1 */
-
- #define MAX_VERTEX 500
- #define MAX_OUTLINE 10
-
- /* structure for returning outline */
- typedef struct { float x; float y; } pt2;
- typedef struct
- {
- short outlinecount;
- short *vertexcount;
- pt2 **vertex;
- float xadvance;
- float yadvance;
- } wfmoutline;
- wfmoutline *wfm_getoutline(
- int /* character */,
- float /* tolerance */
- );
-
- void wfm_freeoutline(
- wfmoutline * /* outline */
- );
-
- void wfm_getbbox(
- int /* character */,
- float * /* llx */,
- float * /* lly */,
- float * /* urx */,
- float * /* ury */
- );
-
- #ifdef __cplusplus
- }
- #endif
-
- #endif
-