NAME

glXUseXFont - create bitmap display lists from an X font

C SPECIFICATION

void ggllXXUUsseeXXFFoonntt( Font _f_o_n_t,
                  int _f_i_r_s_t,
                  int _c_o_u_n_t,
                  int _l_i_s_t_B_a_s_e )

delim $$

PARAMETERS

_f_o_n_t
Specifies the font from which character glyphs are to be taken.
_f_i_r_s_t
Specifies the index of the first glyph to be taken.
_c_o_u_n_t
Specifies the number of glyphs to be taken.
_l_i_s_t_B_a_s_e
Specifies the index of the first display list to be generated.

DESCRIPTION

ggllXXUUsseeXXFFoonntt generates _c_o_u_n_t display lists, named _l_i_s_t_B_a_s_e through _l_i_s_t_B_a_s_e+_c_o_u_n_t-1, each containing a single ggllBBiittmmaapp command. The parameters of the ggllBBiittmmaapp command of display list _l_i_s_t_B_a_s_e+_i are derived from glyph _f_i_r_s_t+_i. Bitmap parameters _x_o_r_i_g_, _y_o_r_i_g_, _w_i_d_t_h_, and _h_e_i_g_h_t are computed from font metrics as _d_e_s_c_e_n_t_-_1_, _-_l_b_e_a_r_i_n_g_, _r_b_e_a_r_i_n_g_-_l_b_e_a_r_i_n_g_, and _a_s_c_e_n_t_+_d_e_s_c_e_n_t, respectively. _x_m_o_v_e is taken from the glyph's _w_i_d_t_h metric, and _y_m_o_v_e is set to zero. Finally, the glyph's image is converted to the appropriate format for ggllBBiittmmaapp.

Using ggllXXUUsseeXXFFoonntt may be more efficient than accessing the X font and generating the display lists explicitly, both because the display lists are created on the server without requiring a round trip of the glyph data, and because the server may choose to delay the creation of each bitmap until it is accessed.

Empty display lists are created for all glyphs that are requested and are not defined in _f_o_n_t. ggllXXUUsseeXXFFoonntt is ignored if there is no current GLX context.

ERRORS

BBaaddFFoonntt is generated if _f_o_n_t is not a valid font.

GGLLXXBBaaddCCoonntteexxttSSttaattee is generated if the current GLX context is in display-list construction mode.

GGLLXXBBaaddCCuurrrreennttWWiinnddooww is generated if the drawable associated with the current context of the calling thread is a window, and that window is no longer valid.

SEE ALSO

ggllBBiittmmaapp, ggllXXMMaakkeeCCuurrrreenntt