Pango Reference Manual | |||
---|---|---|---|
<<< Previous Page | Home | Up | Next Page >>> |
#define PANGO_RENDER_TYPE_WIN32 "PangoRenderWin32" |
A string constant identifying the Win32 renderer. The associated quark (see g_quark_from_string()) is used to identify the renderer in pango_find_map().
PangoContext* pango_win32_get_context (void); |
Retrieves a PangoContext appropriate for rendering with Windows fonts.
void pango_win32_render (HDC hdc, PangoFont *font, PangoGlyphString *glyphs, gint x, gint y); |
Render a PangoGlyphString onto a Windows DC
void pango_win32_render_layout_line (HDC hdc, PangoLayoutLine *line, int x, int y); |
Render a PangoLayoutLine onto a device context
hdc : | HDC to use for uncolored drawing |
line : | a PangoLayoutLine |
x : | the x position of start of string (in pixels) |
y : | the y position of baseline (in pixels) |
void pango_win32_render_layout (HDC hdc, PangoLayout *layout, int x, int y); |
Render a PangoLayoutLine onto an X drawable
PangoGlyph pango_win32_get_unknown_glyph (PangoFont *font); |
Return the index of a glyph suitable for drawing unknown characters.
gint pango_win32_font_get_glyph_index (PangoFont *font, gunichar wc); |
Obtains the index of the glyph for wc in font.
struct PangoWin32FontCache; |
A PangoWin32FontCache caches HFONTs by their LOGFONT descriptions.
PangoWin32FontCache* pango_win32_font_cache_new (void); |
Creates a font cache.
Returns : | The new font cache. This must be freed with pango_win32_font_cache_free(). |
void pango_win32_font_cache_free (PangoWin32FontCache *cache); |
Frees a PangoWin32FontCache and all associated memory. All fonts loaded through this font cache will be freed along with the cache.
cache : | a PangoWin32FontCache |
HFONT pango_win32_font_cache_load (PangoWin32FontCache *cache, const LOGFONT *logfont); |
Creates a HFONT from a LOGFONT. The result may be newly loaded, or it may have been previously stored
cache : | a PangoWin32FontCache |
logfont : | a pointer to a LOGFONT structure describing the font to load. |
Returns : | The font structure, or NULL if the font could not be loaded. In order to free this structure, you must call pango_win32_font_cache_unload(). |
void pango_win32_font_cache_unload (PangoWin32FontCache *cache, HFONT hfont); |
Frees a font structure previously loaded with pango_win32_font_cache_load().
cache : | a PangoWin32FontCache |
hfont : | the HFONT to unload |
PangoFontMap* pango_win32_font_map_for_display (void); |
Returns a PangoWin32FontMap. Font maps are cached and should not be freed. If the font map is no longer needed, it can be released with pango_win32_shutdown_display().
PangoWin32FontCache* pango_win32_font_map_get_font_cache (PangoFontMap *font_map); |
Obtains the font cache associated with the given font map.
font_map : | a PangoWin32FontMap. |
Returns : | the PangoWin32FontCache of font_map. |
LOGFONT* pango_win32_font_logfont (PangoFont *font); |
Determine the LOGFONT struct for the specified bfont.
font : | a PangoFont which must be from the Win32 backend |
Returns : | A newly allocated LOGFONT struct. It must be freed with g_free(). |