From 08f66322e32cc882733dfae408e040f5057ee2ac Mon Sep 17 00:00:00 2001 From: Werner Lemberg Date: Tue, 8 Jun 2021 18:23:16 +0200 Subject: [PATCH] More various documentation improvements and fixes. --- docs/CHANGES | 3 +++ include/freetype/ftlogging.h | 21 ++++++++++++++++++++- include/freetype/ftmodapi.h | 3 +++ src/base/ftcalc.c | 2 +- src/base/ftlcdfil.c | 4 ++-- src/base/ftobjs.c | 8 ++++---- src/cid/cidload.c | 10 +++++----- src/sfnt/ttcolr.c | 4 ++-- src/sfnt/ttcolr.h | 2 +- 9 files changed, 41 insertions(+), 16 deletions(-) diff --git a/docs/CHANGES b/docs/CHANGES index 65964f999..6767f96db 100644 --- a/docs/CHANGES +++ b/docs/CHANGES @@ -72,6 +72,9 @@ CHANGES BETWEEN 2.10.4 and 2.11.0 This work was Priyesh Kumar's GSoC 2020 project. + - PCF bitmap fonts compressed with LZW (these are usually files with + the extension `.pcf.Z`) are now handled correctly. + - Improved Meson build support for the library. - Meson support to build The FreeType demo programs. diff --git a/include/freetype/ftlogging.h b/include/freetype/ftlogging.h index 8811261b0..a558b85fa 100644 --- a/include/freetype/ftlogging.h +++ b/include/freetype/ftlogging.h @@ -68,6 +68,10 @@ FT_BEGIN_HEADER * @note: * This function does nothing if compilation option `FT_DEBUG_LOGGING` * isn't set. + * + * @since: + * 2.11 + * */ FT_EXPORT( void ) FT_Trace_Set_Level( const char* tracing_level ); @@ -83,10 +87,13 @@ FT_BEGIN_HEADER * (i.e., to the value of the `FT2_DEBUG` environment value or to NULL * if `FT2_DEBUG` is not set). * - * * @note: * This function does nothing if compilation option `FT_DEBUG_LOGGING` * isn't set. + * + * @since: + * 2.11 + * */ FT_EXPORT( void ) FT_Trace_Set_Default_Level( void ); @@ -111,6 +118,10 @@ FT_BEGIN_HEADER * * args:: * Arguments of debug or tracing messages. + * + * @since: + * 2.11 + * */ typedef void (*FT_Custom_Log_Handler)( const char* ft_component, @@ -133,6 +144,10 @@ FT_BEGIN_HEADER * @note: * This function does nothing if compilation option `FT_DEBUG_LOGGING` * isn't set. + * + * @since: + * 2.11 + * */ FT_EXPORT( void ) FT_Set_Log_Handler( FT_Custom_Log_Handler handler ); @@ -150,6 +165,10 @@ FT_BEGIN_HEADER * @note: * This function does nothing if compilation option `FT_DEBUG_LOGGING` * isn't set. + * + * @since: + * 2.11 + * */ FT_EXPORT( void ) FT_Set_Default_Log_Handler( void ); diff --git a/include/freetype/ftmodapi.h b/include/freetype/ftmodapi.h index e507f62b6..1eded9e5e 100644 --- a/include/freetype/ftmodapi.h +++ b/include/freetype/ftmodapi.h @@ -343,6 +343,9 @@ FT_BEGIN_HEADER * The font driver name is a valid `module_name` for @FT_Property_Set * and @FT_Property_Get. This is not the same as @FT_Get_Font_Format. * + * @since: + * 2.11 + * */ #define FT_FACE_DRIVER_NAME( face ) \ ( ( *(FT_Module_Class**)( ( face )->driver ) )->module_name ) diff --git a/src/base/ftcalc.c b/src/base/ftcalc.c index 99f2bc6d9..e60303afc 100644 --- a/src/base/ftcalc.c +++ b/src/base/ftcalc.c @@ -109,7 +109,7 @@ #ifndef FT_MSB - FT_BASE_DEF ( FT_Int ) + FT_BASE_DEF( FT_Int ) FT_MSB( FT_UInt32 z ) { FT_Int shift = 0; diff --git a/src/base/ftlcdfil.c b/src/base/ftlcdfil.c index f3725a3d7..45e5114ed 100644 --- a/src/base/ftlcdfil.c +++ b/src/base/ftlcdfil.c @@ -32,7 +32,7 @@ /* add padding according to filter weights */ - FT_BASE_DEF (void) + FT_BASE_DEF( void ) ft_lcd_padding( FT_BBox* cbox, FT_GlyphSlot slot, FT_Render_Mode mode ) @@ -368,7 +368,7 @@ #else /* !FT_CONFIG_OPTION_SUBPIXEL_RENDERING */ /* add padding to accommodate outline shifts */ - FT_BASE_DEF (void) + FT_BASE_DEF( void ) ft_lcd_padding( FT_BBox* cbox, FT_GlyphSlot slot, FT_Render_Mode mode ) diff --git a/src/base/ftobjs.c b/src/base/ftobjs.c index 3ae39eeeb..4a8014542 100644 --- a/src/base/ftobjs.c +++ b/src/base/ftobjs.c @@ -91,7 +91,7 @@ "LCD 8-bit bitmap", "vertical LCD 8-bit bitmap", "BGRA 32-bit color image bitmap", - "SDF 16-bit bitmap" + "SDF 8-bit bitmap" }; #endif /* FT_DEBUG_LEVEL_TRACE */ @@ -5602,7 +5602,7 @@ /* documentation is in freetype.h */ - FT_EXPORT_DEF ( FT_Bool ) + FT_EXPORT_DEF( FT_Bool ) FT_Get_Color_Glyph_Paint( FT_Face face, FT_UInt base_glyph, FT_Color_Root_Transform root_transform, @@ -5633,7 +5633,7 @@ /* documentation is in freetype.h */ - FT_EXPORT_DEF ( FT_Bool ) + FT_EXPORT_DEF( FT_Bool ) FT_Get_Paint_Layers( FT_Face face, FT_LayerIterator* layer_iterator, FT_OpaquePaint* paint ) @@ -5687,7 +5687,7 @@ /* documentation is in freetype.h */ - FT_EXPORT_DEF ( FT_Bool ) + FT_EXPORT_DEF( FT_Bool ) FT_Get_Colorline_Stops ( FT_Face face, FT_ColorStop * color_stop, FT_ColorStopIterator *iterator ) diff --git a/src/cid/cidload.c b/src/cid/cidload.c index b22b53683..7fd0d7c78 100644 --- a/src/cid/cidload.c +++ b/src/cid/cidload.c @@ -665,11 +665,11 @@ static FT_Error - cid_hex_to_binary( FT_Byte* data, - FT_ULong data_len, - FT_ULong offset, - CID_Face face, - FT_ULong* data_written ) + cid_hex_to_binary( FT_Byte* data, + FT_ULong data_len, + FT_ULong offset, + CID_Face face, + FT_ULong* data_written ) { FT_Stream stream = face->root.stream; FT_Error error; diff --git a/src/sfnt/ttcolr.c b/src/sfnt/ttcolr.c index c3f225d66..d672bb5b7 100644 --- a/src/sfnt/ttcolr.c +++ b/src/sfnt/ttcolr.c @@ -629,7 +629,7 @@ } - FT_LOCAL_DEF ( FT_Bool ) + FT_LOCAL_DEF( FT_Bool ) tt_face_get_colr_glyph_paint( TT_Face face, FT_UInt base_glyph, FT_Color_Root_Transform root_transform, @@ -745,7 +745,7 @@ } - FT_LOCAL_DEF ( FT_Bool ) + FT_LOCAL_DEF( FT_Bool ) tt_face_get_colorline_stops( TT_Face face, FT_ColorStop* color_stop, FT_ColorStopIterator *iterator ) diff --git a/src/sfnt/ttcolr.h b/src/sfnt/ttcolr.h index 4a7ed4bf4..c91d2b172 100644 --- a/src/sfnt/ttcolr.h +++ b/src/sfnt/ttcolr.h @@ -48,7 +48,7 @@ FT_BEGIN_HEADER FT_Color_Root_Transform root_transform, FT_OpaquePaint* paint ); - FT_LOCAL ( FT_Bool ) + FT_LOCAL( FT_Bool ) tt_face_get_paint_layers( TT_Face face, FT_LayerIterator* iterator, FT_OpaquePaint* paint );