Lines Matching defs:face

53   /*    face   :: A handle to the target face object.                      */
62 tt_face_load_loca( TT_Face face,
71 error = face->goto_table( face, TTAG_glyf, stream, &face->glyf_len );
76 face->glyf_len = 0;
81 error = face->goto_table( face, TTAG_loca, stream, &table_len );
88 if ( face->header.Index_To_Loc_Format != 0 )
98 face->num_locations = table_len >> shift;
110 face->num_locations = table_len >> shift;
113 if ( face->num_locations != (FT_ULong)face->root.num_glyphs + 1 )
116 face->num_locations - 1, face->root.num_glyphs ));
119 if ( face->num_locations <= (FT_ULong)face->root.num_glyphs )
122 ( (FT_Long)( face->root.num_glyphs ) + 1 ) << shift;
124 TT_Table entry = face->dir_tables;
125 TT_Table limit = entry + face->num_tables;
149 face->num_locations = face->root.num_glyphs + 1;
153 face->num_locations ));
162 if ( FT_FRAME_EXTRACT( table_len, face->glyph_locations ) )
173 tt_face_get_location( TT_Face face,
184 if ( gindex < face->num_locations )
186 if ( face->header.Index_To_Loc_Format != 0 )
188 p = face->glyph_locations + gindex * 4;
189 p_limit = face->glyph_locations + face->num_locations * 4;
199 p = face->glyph_locations + gindex * 2;
200 p_limit = face->glyph_locations + face->num_locations * 2;
214 if ( pos1 > face->glyf_len )
219 pos1, gindex, face->glyf_len ));
224 if ( pos2 > face->glyf_len )
229 pos2, gindex + 1, face->glyf_len ));
230 pos2 = face->glyf_len;
244 *asize = (FT_UInt)( face->glyf_len - pos1 );
251 tt_face_done_loca( TT_Face face )
253 FT_Stream stream = face->root.stream;
256 FT_FRAME_RELEASE( face->glyph_locations );
257 face->num_locations = 0;
268 /* Load the control value table into a face object. */
271 /* face :: A handle to the target face object. */
280 tt_face_load_cvt( TT_Face face,
292 error = face->goto_table( face, TTAG_cvt, stream, &table_len );
297 face->cvt_size = 0;
298 face->cvt = NULL;
304 face->cvt_size = table_len / 2;
306 if ( FT_NEW_ARRAY( face->cvt, face->cvt_size ) )
309 if ( FT_FRAME_ENTER( face->cvt_size * 2L ) )
313 FT_Short* cur = face->cvt;
314 FT_Short* limit = cur + face->cvt_size;
325 if ( face->doblend )
326 error = tt_face_vary_cvt( face, stream );
334 FT_UNUSED( face );
352 /* face :: A handle to the target face object. */
361 tt_face_load_fpgm( TT_Face face,
373 error = face->goto_table( face, TTAG_fpgm, stream, &table_len );
376 face->font_program = NULL;
377 face->font_program_size = 0;
384 face->font_program_size = table_len;
385 if ( FT_FRAME_EXTRACT( table_len, face->font_program ) )
388 FT_TRACE2(( "loaded, %12d bytes\n", face->font_program_size ));
396 FT_UNUSED( face );
414 /* face :: A handle to the target face object. */
423 tt_face_load_prep( TT_Face face,
434 error = face->goto_table( face, TTAG_prep, stream, &table_len );
437 face->cvt_program = NULL;
438 face->cvt_program_size = 0;
445 face->cvt_program_size = table_len;
446 if ( FT_FRAME_EXTRACT( table_len, face->cvt_program ) )
449 FT_TRACE2(( "loaded, %12d bytes\n", face->cvt_program_size ));
457 FT_UNUSED( face );
472 /* Load the `hdmx' table into the face object. */
475 /* face :: A handle to the target face object. */
484 tt_face_load_hdmx( TT_Face face,
496 error = face->goto_table( face, TTAG_hdmx, stream, &table_size );
500 if ( FT_FRAME_EXTRACT( table_size, face->hdmx_table ) )
503 p = face->hdmx_table;
532 if ( FT_NEW_ARRAY( face->hdmx_record_sizes, num_records ) )
540 face->hdmx_record_sizes[nn] = p[0];
544 face->hdmx_record_count = nn;
545 face->hdmx_table_size = table_size;
546 face->hdmx_record_size = record_size;
552 FT_FRAME_RELEASE( face->hdmx_table );
553 face->hdmx_table_size = 0;
559 tt_face_free_hdmx( TT_Face face )
561 FT_Stream stream = face->root.stream;
565 FT_FREE( face->hdmx_record_sizes );
566 FT_FRAME_RELEASE( face->hdmx_table );
576 tt_face_get_device_metrics( TT_Face face,
582 FT_ULong record_size = face->hdmx_record_size;
583 FT_Byte* record = face->hdmx_table + 8;
586 for ( nn = 0; nn < face->hdmx_record_count; nn++ )
587 if ( face->hdmx_record_sizes[nn] == ppem )