[winfonts] Remove casts.
* src/winfonts/winfnt.c (winfnt_driver_class): Remove all casts and update affected functions. (FNT_Size_Select): Fix number of arguments.
This commit is contained in:
parent
5a7a593c37
commit
628bebe639
|
@ -1,3 +1,11 @@
|
|||
2011-11-30 Werner Lemberg <wl@gnu.org>
|
||||
|
||||
[winfonts] Remove casts.
|
||||
|
||||
* src/winfonts/winfnt.c (winfnt_driver_class): Remove all casts and
|
||||
update affected functions.
|
||||
(FNT_Size_Select): Fix number of arguments.
|
||||
|
||||
2011-11-30 Werner Lemberg <wl@gnu.org>
|
||||
|
||||
[type42] Remove casts.
|
||||
|
|
|
@ -665,8 +665,9 @@
|
|||
|
||||
|
||||
static void
|
||||
FNT_Face_Done( FNT_Face face )
|
||||
FNT_Face_Done( FT_Face fntface ) /* FNT_Face */
|
||||
{
|
||||
FNT_Face face = (FNT_Face)fntface;
|
||||
FT_Memory memory;
|
||||
|
||||
|
||||
|
@ -677,18 +678,19 @@
|
|||
|
||||
fnt_font_done( face );
|
||||
|
||||
FT_FREE( face->root.available_sizes );
|
||||
face->root.num_fixed_sizes = 0;
|
||||
FT_FREE( fntface->available_sizes );
|
||||
fntface->num_fixed_sizes = 0;
|
||||
}
|
||||
|
||||
|
||||
static FT_Error
|
||||
FNT_Face_Init( FT_Stream stream,
|
||||
FNT_Face face,
|
||||
FT_Face fntface, /* FNT_Face */
|
||||
FT_Int face_index,
|
||||
FT_Int num_params,
|
||||
FT_Parameter* params )
|
||||
{
|
||||
FNT_Face face = (FNT_Face)fntface;
|
||||
FT_Error error;
|
||||
FT_Memory memory = FT_FACE_MEMORY( face );
|
||||
|
||||
|
@ -711,7 +713,7 @@
|
|||
if ( FT_NEW( face->font ) )
|
||||
goto Exit;
|
||||
|
||||
face->root.num_faces = 1;
|
||||
fntface->num_faces = 1;
|
||||
|
||||
font = face->font;
|
||||
font->offset = 0;
|
||||
|
@ -876,7 +878,7 @@
|
|||
goto Exit;
|
||||
|
||||
Fail:
|
||||
FNT_Face_Done( face );
|
||||
FNT_Face_Done( fntface );
|
||||
|
||||
Exit:
|
||||
return error;
|
||||
|
@ -884,11 +886,14 @@
|
|||
|
||||
|
||||
static FT_Error
|
||||
FNT_Size_Select( FT_Size size )
|
||||
FNT_Size_Select( FT_Size size,
|
||||
FT_ULong strike_index )
|
||||
{
|
||||
FNT_Face face = (FNT_Face)size->face;
|
||||
FT_WinFNT_Header header = &face->font->header;
|
||||
|
||||
FT_UNUSED( strike_index );
|
||||
|
||||
|
||||
FT_Select_Metrics( size->face, 0 );
|
||||
|
||||
|
@ -935,7 +940,7 @@
|
|||
if ( error )
|
||||
return error;
|
||||
else
|
||||
return FNT_Size_Select( size );
|
||||
return FNT_Size_Select( size, 0 );
|
||||
}
|
||||
|
||||
|
||||
|
@ -1088,10 +1093,10 @@
|
|||
|
||||
|
||||
static FT_Module_Interface
|
||||
winfnt_get_service( FT_Driver driver,
|
||||
winfnt_get_service( FT_Module module,
|
||||
const FT_String* service_id )
|
||||
{
|
||||
FT_UNUSED( driver );
|
||||
FT_UNUSED( module );
|
||||
|
||||
return ft_service_list_lookup( winfnt_services, service_id );
|
||||
}
|
||||
|
@ -1113,34 +1118,34 @@
|
|||
|
||||
0,
|
||||
|
||||
(FT_Module_Constructor)0,
|
||||
(FT_Module_Destructor) 0,
|
||||
(FT_Module_Requester) winfnt_get_service
|
||||
0, /* FT_Module_Constructor */
|
||||
0, /* FT_Module_Destructor */
|
||||
winfnt_get_service
|
||||
},
|
||||
|
||||
sizeof ( FNT_FaceRec ),
|
||||
sizeof ( FT_SizeRec ),
|
||||
sizeof ( FT_GlyphSlotRec ),
|
||||
|
||||
(FT_Face_InitFunc) FNT_Face_Init,
|
||||
(FT_Face_DoneFunc) FNT_Face_Done,
|
||||
(FT_Size_InitFunc) 0,
|
||||
(FT_Size_DoneFunc) 0,
|
||||
(FT_Slot_InitFunc) 0,
|
||||
(FT_Slot_DoneFunc) 0,
|
||||
FNT_Face_Init,
|
||||
FNT_Face_Done,
|
||||
0, /* FT_Size_InitFunc */
|
||||
0, /* FT_Size_DoneFunc */
|
||||
0, /* FT_Slot_InitFunc */
|
||||
0, /* FT_Slot_DoneFunc */
|
||||
|
||||
#ifdef FT_CONFIG_OPTION_OLD_INTERNALS
|
||||
ft_stub_set_char_sizes,
|
||||
ft_stub_set_pixel_sizes,
|
||||
#endif
|
||||
(FT_Slot_LoadFunc) FNT_Load_Glyph,
|
||||
FNT_Load_Glyph,
|
||||
|
||||
(FT_Face_GetKerningFunc) 0,
|
||||
(FT_Face_AttachFunc) 0,
|
||||
(FT_Face_GetAdvancesFunc) 0,
|
||||
0, /* FT_Face_GetKerningFunc */
|
||||
0, /* FT_Face_AttachFunc */
|
||||
0, /* FT_Face_GetAdvancesFunc */
|
||||
|
||||
(FT_Size_RequestFunc) FNT_Size_Request,
|
||||
(FT_Size_SelectFunc) FNT_Size_Select
|
||||
FNT_Size_Request,
|
||||
FNT_Size_Select
|
||||
};
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue