📄 pango-freetype-fonts-and-rendering.html
字号:
<tr><td><span class="term"><em class="parameter"><code>y</code></em> :</span></td><td> the y position of baseline (in Pango units)</td></tr></tbody></table></div><p>Since 1.6</p></div><hr><div class="refsect2" lang="en"><a name="id2879608"></a><h3><a name="pango-ft2-render-layout"></a>pango_ft2_render_layout ()</h3><a class="indexterm" name="id2879621"></a><pre class="programlisting">void pango_ft2_render_layout (FT_Bitmap *bitmap, <a href="pango-Layout-Objects.html#PangoLayout">PangoLayout</a> *layout, int x, int y);</pre><p>Render a <a href="pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a> onto a FreeType2 bitmap</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><em class="parameter"><code>bitmap</code></em> :</span></td><td> a <span class="type">FT_Bitmap</span> to render the layout onto</td></tr><tr><td><span class="term"><em class="parameter"><code>layout</code></em> :</span></td><td> a <a href="pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a></td></tr><tr><td><span class="term"><em class="parameter"><code>x</code></em> :</span></td><td> the X position of the left of the layout (in pixels)</td></tr><tr><td><span class="term"><em class="parameter"><code>y</code></em> :</span></td><td> the Y position of the top of the layout (in pixels)</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2879755"></a><h3><a name="pango-ft2-render-layout-subpixel"></a>pango_ft2_render_layout_subpixel ()</h3><a class="indexterm" name="id2879771"></a><pre class="programlisting">void pango_ft2_render_layout_subpixel (FT_Bitmap *bitmap, <a href="pango-Layout-Objects.html#PangoLayout">PangoLayout</a> *layout, int x, int y);</pre><p>Render a <a href="pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a> onto a FreeType2 bitmap, with helocation specified in fixed-point Pango units rather thanpixels. (Using this will avoid extra inaccuracies fromrounding to integer pixels multiple times, even if thefinal glyph positions are integers.)</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><em class="parameter"><code>bitmap</code></em> :</span></td><td> a <span class="type">FT_Bitmap</span> to render the layout onto</td></tr><tr><td><span class="term"><em class="parameter"><code>layout</code></em> :</span></td><td> a <a href="pango-Layout-Objects.html#PangoLayout"><span class="type">PangoLayout</span></a></td></tr><tr><td><span class="term"><em class="parameter"><code>x</code></em> :</span></td><td> the X position of the left of the layout (in Pango units)</td></tr><tr><td><span class="term"><em class="parameter"><code>y</code></em> :</span></td><td> the Y position of the top of the layout (in Pango units)</td></tr></tbody></table></div><p>Since 1.6</p></div><hr><div class="refsect2" lang="en"><a name="id2879915"></a><h3><a name="pango-ft2-get-unknown-glyph"></a>pango_ft2_get_unknown_glyph ()</h3><a class="indexterm" name="id2879930"></a><pre class="programlisting"><a href="pango-Glyph-Storage.html#PangoGlyph">PangoGlyph</a> pango_ft2_get_unknown_glyph (<a href="pango-Fonts.html#PangoFont">PangoFont</a> *font);</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">pango_ft2_get_unknown_glyph</code> is deprecated and should not be used in newly-written code.</p></div><p>Return the index of a glyph suitable for drawing unknown characters with<em class="parameter"><code>font</code></em>, or <a href="pango-Glyph-Storage.html#PANGO-GLYPH-EMPTY:CAPS"><code class="literal">PANGO_GLYPH_EMPTY</code></a> if no suitable glyph found.</p><p>If you want to draw an unknown-box for a character that is not coveredby the font,use <a href="pango-Glyph-Storage.html#PANGO-GET-UNKNOWN-GLYPH:CAPS"><code class="function">PANGO_GET_UNKNOWN_GLYPH()</code></a> instead.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><em class="parameter"><code>font</code></em> :</span></td><td> a <a href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a></td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td> a glyph index into <em class="parameter"><code>font</code></em>, or <a href="pango-Glyph-Storage.html#PANGO-GLYPH-EMPTY:CAPS"><code class="literal">PANGO_GLYPH_EMPTY</code></a></td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2880063"></a><h3><a name="pango-ft2-font-get-kerning"></a>pango_ft2_font_get_kerning ()</h3><a class="indexterm" name="id2880078"></a><pre class="programlisting">int pango_ft2_font_get_kerning (<a href="pango-Fonts.html#PangoFont">PangoFont</a> *font, <a href="pango-Glyph-Storage.html#PangoGlyph">PangoGlyph</a> left, <a href="pango-Glyph-Storage.html#PangoGlyph">PangoGlyph</a> right);</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">pango_ft2_font_get_kerning</code> is deprecated and should not be used in newly-written code.</p></div><p>Retrieves kerning information for a combination of two glyphs.</p><p>Use <a href="PangoFcFont.html#pango-fc-font-kern-glyphs"><code class="function">pango_fc_font_kern_glyphs()</code></a> instead.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><em class="parameter"><code>font</code></em> :</span></td><td> a <a href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a></td></tr><tr><td><span class="term"><em class="parameter"><code>left</code></em> :</span></td><td> the left <a href="pango-Glyph-Storage.html#PangoGlyph"><span class="type">PangoGlyph</span></a></td></tr><tr><td><span class="term"><em class="parameter"><code>right</code></em> :</span></td><td> the right <a href="pango-Glyph-Storage.html#PangoGlyph"><span class="type">PangoGlyph</span></a></td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td> The amount of kerning (in Pango units) to apply forthe given combination of glyphs.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2880234"></a><h3><a name="pango-ft2-font-get-face"></a>pango_ft2_font_get_face ()</h3><a class="indexterm" name="id2880249"></a><pre class="programlisting">FT_Face pango_ft2_font_get_face (<a href="pango-Fonts.html#PangoFont">PangoFont</a> *font);</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">pango_ft2_font_get_face</code> is deprecated and should not be used in newly-written code.</p></div><p>Returns the native FreeType2 <span class="type">FT_Face</span> structure used for this <a href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a>.This may be useful if you want to use FreeType2 functions directly.</p><p>Use <a href="PangoFcFont.html#pango-fc-font-lock-face"><code class="function">pango_fc_font_lock_face()</code></a> instead; when you are done with aface from <a href="PangoFcFont.html#pango-fc-font-lock-face"><code class="function">pango_fc_font_lock_face()</code></a> you must call<a href="PangoFcFont.html#pango-fc-font-unlock-face"><code class="function">pango_fc_font_unlock_face()</code></a>.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><em class="parameter"><code>font</code></em> :</span></td><td> a <a href="pango-Fonts.html#PangoFont"><span class="type">PangoFont</span></a></td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td> a pointer to a <span class="type">FT_Face</span> structure, with the size set correctly</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2880386"></a><h3><a name="pango-ft2-font-get-coverage"></a>pango_ft2_font_get_coverage ()</h3><a class="indexterm" name="id2880403"></a><pre class="programlisting"><a href="pango-Coverage-Maps.html#PangoCoverage">PangoCoverage</a>* pango_ft2_font_get_coverage (<a href="pango-Fonts.html#PangoFont">PangoFont</a> *font, <a href="pango-Text-Attributes.html#PangoLanguage">PangoLanguage</a> *language);</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">pango_ft2_font_get_coverage</code> is deprecated and should not be used in newly-written code.</p></div><p>Gets the <a href="pango-Coverage-Maps.html#PangoCoverage"><span class="type">PangoCoverage</span></a> for a <span class="type">PangoFT2Font</span>. Use <a href="pango-Fonts.html#pango-font-get-coverage"><code class="function">pango_font_get_coverage()</code></a> instead.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><em class="parameter"><code>font</code></em> :</span></td><td> a <span class="type">PangoFT2Font</span>.</td></tr><tr><td><span class="term"><em class="parameter"><code>language</code></em> :</span></td><td> a language tag.</td></tr><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td> a <a href="pango-Coverage-Maps.html#PangoCoverage"><span class="type">PangoCoverage</span></a>.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2880542"></a><h3><a name="pango-ft2-font-map-for-display"></a>pango_ft2_font_map_for_display ()</h3><a class="indexterm" name="id2880558"></a><pre class="programlisting"><a href="pango-Fonts.html#PangoFontMap">PangoFontMap</a>* pango_ft2_font_map_for_display (void);</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">pango_ft2_font_map_for_display</code> is deprecated and should not be used in newly-written code.</p></div><p>Returns a <a href="pango-FreeType-Fonts-and-Rendering.html#PangoFT2FontMap"><span class="type">PangoFT2FontMap</span></a>. This font map is cached and shouldnot be freed. If the font map is no longer needed, it canbe released with <a href="pango-FreeType-Fonts-and-Rendering.html#pango-ft2-shutdown-display"><code class="function">pango_ft2_shutdown_display()</code></a>. Use of theglobal PangoFT2 fontmap is deprecated; use <a href="pango-FreeType-Fonts-and-Rendering.html#pango-ft2-font-map-new"><code class="function">pango_ft2_font_map_new()</code></a>instead.</p><p></p><div class="variablelist"><table border="0"><col align="left" valign="top"><tbody><tr><td><span class="term"><span class="emphasis"><em>Returns</em></span> :</span></td><td> a <a href="pango-FreeType-Fonts-and-Rendering.html#PangoFT2FontMap"><span class="type">PangoFT2FontMap</span></a>.</td></tr></tbody></table></div></div><hr><div class="refsect2" lang="en"><a name="id2880653"></a><h3><a name="pango-ft2-shutdown-display"></a>pango_ft2_shutdown_display ()</h3><a class="indexterm" name="id2880669"></a><pre class="programlisting">void pango_ft2_shutdown_display (void);</pre><div class="warning" style="margin-left: 0.5in; margin-right: 0.5in;"><h3 class="title">Warning</h3><p><code class="literal">pango_ft2_shutdown_display</code> is deprecated and should not be used in newly-written code.</p></div><p>Free the global fontmap. (See <a href="pango-FreeType-Fonts-and-Rendering.html#pango-ft2-font-map-for-display"><code class="function">pango_ft2_font_map_for_display()</code></a>)Use of the global PangoFT2 fontmap is deprecated.</p><p></p></div></div></div></body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -