home *** CD-ROM | disk | FTP | other *** search
- Protocol requests
-
- These functions make protocol requests corresponding to their names.
-
- Connection Setup
-
- FSServer *
- FSOpenServer(server)
- char *server;
-
- Creates a connection to the font server specified in the 'server' string.
-
- FSCloseServer(svr)
- FSServer *svr;
-
- Closes the connection to the font server.
-
- Font Manipulation
-
- Font
- FSOpenXBitmap(svr, hint, fmask, name, originalid)
- FSServer *svr;
- fsBitmapFormat hint;
- fsBitmapFormatMask fmask;
- char *name;
- Font *originalid;
-
- Opens the font that matches the given name (which may have '*' and '?'
- as wildcards). The hint contains format information that will probably
- be used in subsequent QueryXBitmaps() requests. The fmask tells which
- bits in the mask are valid. If originalid is non-zero, then the server
- already has the font opened under that ID.
-
- FSCloseFont(svr, fid)
- FSServer *svr;
- Font fid;
-
- Closes the font.
-
- char **
- FSListFonts(svr, pattern, maxNames, actualCount)
- FSServer *svr;
- char *pattern;
- int maxNames;
- int *actualCount;
-
- Returns the full names of the fonts matching pattern. Up to maxNames
- names will be returned. The actual value number be placed in
- actualCount.
-
- char **
- FSListWithXInfo(svr, pattern, maxNames, actualCount, info, pprops, offsets,
- prop_data)
- FSServer *svr;
- char *pattern;
- int maxNames;
- int *actualCount;
- fsFontHeader ***info;
- fsPropInfo ***pprops;
- fsPropOffset ***offsets;
- unsigned char ***prop_data;
-
- Returns the full names of the fonts matching pattern. Up to maxNames
- names will be returned. The actual value number be placed in
- actualCount, and each font's header and property information will also
- be returned.
-
- int
- FSQueryXInfo(svr, fid, info, props, offsets, prop_data)
- FSServer *svr;
- Font fid;
- fsFontHeader *info;
- fsPropInfo *props;
- fsPropOffset **offsets;
- unsigned char **prop_data;
-
- Returns the font's header information.
-
- int
- FSQueryXExtents8(svr, fid, range_type, str, str_len, extents)
- FSServer *svr;
- Font fid;
- Bool range_type;
- unsigned char *str;
- unsigned long str_len;
- fsCharInfo **extents;
-
- int
- FSQueryXExtents16(svr, fid, range_type, str, str_len, extents)
- FSServer *svr;
- Font fid;
- Bool range_type;
- fsChar2b *str;
- unsigned long str_len;
- fsCharInfo **extents;
-
- Returns the extents of the given characters. If 'range_type' is set,
- the 'str' is considered a range, otherwise its considered a list of
- characters. A NULL str when range_type is set means that all the
- character extents will be returned.
-
- int
- FSQueryXBitmaps8(svr, fid, format, range_type, str, str_len,, offsets, glyph_data)
- FSServer *svr;
- Font fid;
- fsRange *range;
- fsBitmapFormat format;
- Bool range_type;
- unsigned char *str;
- unsined long str_len;
- unsigned long **offsets;
- unsigned char **glyph_data;
-
- int
- FSQueryXBitmaps16(svr, fid, format, range_type, str, str_len,, offsets, glyph_data)
- FSServer *svr;
- Font fid;
- fsRange *range;
- fsBitmapFormat format;
- Bool range_type;
- fsChar2b *str;
- unsined long str_len;
- unsigned long **offsets;
- unsigned char **glyph_data;
-
- Returns the font's bitmaps in the requested format. The other arguments
- are used as in QueryExtents above.
-
- Extensions
-
- char **
- FSListExtensions(svr, next)
- FSServer *svr;
- int *next;
-
- Lists any extension built into the font server.
-
- Bool
- FSQueryExtension(svr, name, major_opcode, first_event, first_error)
- FSServer *svr;
- char *name;
- int *major_opcode;
- int *first_event;
- int *first_error;
-
- Returns information on the specified extension.
-
- FSFreeExtensionList(list)
- char **list;
-
- Frees the list returned by FSListExtensions().
-
-
- Helper functions -- these don't map to protocol requests, but
- can make writing a FS client simpler.
-
- Synchronization
-
- FSSync(svr, discard)
- FSServer *svr;
- Bool discard;
-
- Flushes the output queue and waits for a reply from the server,
- which will flush the server's output queue.
-
- int
- (* FSSynchronize(svr, onoff)) ()
- FSServer *svr;
- int onoff;
-
- Controls whether the server does every request in synchronous form.
-
- int
- (* FSSetAfterFunction(svr, func)) ()
- FSServer *svr;
- int (*func) ();
-
- Sets the function that will be called after every request. This
- is usually NULL or FSSync().
-
- FSFlush(svr)
- FSServer *svr;
-
- Flushes any queued requests to the font server.
-
- Error Handling
-
- int (* FSSetErrorHandler(handler)) ()
- int (*handler) ();
-
- Changes the error handler to 'handler'. A NULL value will reset
- it to use the default.
-
- int (* FSSetIOErrorHandler(handler)) ()
- int (*handler) ();
-
- Changes the I/O error handler to 'handler'. A NULL value will reset
- it to use the default.
-
- Miscellaneous
-
- long
- FSMaxRequestSize(svr)
- FSServer *svr;
-
- Returns the largest request size in 4 byte quantities) that the
- server can handle.
-
- char *
- FSServerName(server)
- char *server;
-
- Returns the name that FSlib would use to connect to the server.
- Translates a NULL in the value of $FONT_SERVER.
-
-