|
|
|||
Warning, file /include/freetype2/freetype/ftsynth.h was not indexed or was modified since last indexation (in which case cross-reference links may be missing, inaccurate or erroneous).
0001 /**************************************************************************** 0002 * 0003 * ftsynth.h 0004 * 0005 * FreeType synthesizing code for emboldening and slanting 0006 * (specification). 0007 * 0008 * Copyright (C) 2000-2023 by 0009 * David Turner, Robert Wilhelm, and Werner Lemberg. 0010 * 0011 * This file is part of the FreeType project, and may only be used, 0012 * modified, and distributed under the terms of the FreeType project 0013 * license, LICENSE.TXT. By continuing to use, modify, or distribute 0014 * this file you indicate that you have read the license and 0015 * understand and accept it fully. 0016 * 0017 */ 0018 0019 0020 /*************************************************************************/ 0021 /*************************************************************************/ 0022 /*************************************************************************/ 0023 /*************************************************************************/ 0024 /*************************************************************************/ 0025 /********* *********/ 0026 /********* WARNING, THIS IS ALPHA CODE! THIS API *********/ 0027 /********* IS DUE TO CHANGE UNTIL STRICTLY NOTIFIED BY THE *********/ 0028 /********* FREETYPE DEVELOPMENT TEAM *********/ 0029 /********* *********/ 0030 /*************************************************************************/ 0031 /*************************************************************************/ 0032 /*************************************************************************/ 0033 /*************************************************************************/ 0034 /*************************************************************************/ 0035 0036 0037 /* Main reason for not lifting the functions in this module to a */ 0038 /* 'standard' API is that the used parameters for emboldening and */ 0039 /* slanting are not configurable. Consider the functions as a */ 0040 /* code resource that should be copied into the application and */ 0041 /* adapted to the particular needs. */ 0042 0043 0044 #ifndef FTSYNTH_H_ 0045 #define FTSYNTH_H_ 0046 0047 0048 #include <freetype/freetype.h> 0049 0050 #ifdef FREETYPE_H 0051 #error "freetype.h of FreeType 1 has been loaded!" 0052 #error "Please fix the directory search order for header files" 0053 #error "so that freetype.h of FreeType 2 is found first." 0054 #endif 0055 0056 0057 FT_BEGIN_HEADER 0058 0059 /* Embolden a glyph by a 'reasonable' value (which is highly a matter of */ 0060 /* taste). This function is actually a convenience function, providing */ 0061 /* a wrapper for @FT_Outline_Embolden and @FT_Bitmap_Embolden. */ 0062 /* */ 0063 /* For emboldened outlines the height, width, and advance metrics are */ 0064 /* increased by the strength of the emboldening -- this even affects */ 0065 /* mono-width fonts! */ 0066 /* */ 0067 /* You can also call @FT_Outline_Get_CBox to get precise values. */ 0068 FT_EXPORT( void ) 0069 FT_GlyphSlot_Embolden( FT_GlyphSlot slot ); 0070 0071 /* Precisely adjust the glyph weight either horizontally or vertically. */ 0072 /* The `xdelta` and `ydelta` values are fractions of the face Em size */ 0073 /* (in fixed-point format). Considering that a regular face would have */ 0074 /* stem widths on the order of 0.1 Em, a delta of 0.05 (0x0CCC) should */ 0075 /* be very noticeable. To increase or decrease the weight, use positive */ 0076 /* or negative values, respectively. */ 0077 FT_EXPORT( void ) 0078 FT_GlyphSlot_AdjustWeight( FT_GlyphSlot slot, 0079 FT_Fixed xdelta, 0080 FT_Fixed ydelta ); 0081 0082 0083 /* Slant an outline glyph to the right by about 12 degrees. */ 0084 FT_EXPORT( void ) 0085 FT_GlyphSlot_Oblique( FT_GlyphSlot slot ); 0086 0087 /* Slant an outline glyph by a given sine of an angle. You can apply */ 0088 /* slant along either x- or y-axis by choosing a corresponding non-zero */ 0089 /* argument. If both slants are non-zero, some affine transformation */ 0090 /* will result. */ 0091 FT_EXPORT( void ) 0092 FT_GlyphSlot_Slant( FT_GlyphSlot slot, 0093 FT_Fixed xslant, 0094 FT_Fixed yslant ); 0095 0096 /* */ 0097 0098 0099 FT_END_HEADER 0100 0101 #endif /* FTSYNTH_H_ */ 0102 0103 0104 /* END */
| [ Source navigation ] | [ Diff markup ] | [ Identifier search ] | [ general search ] |
|
This page was automatically generated by the 2.3.7 LXR engine. The LXR team |
|