summaryrefslogtreecommitdiff
path: root/pango/pangox.h
diff options
context:
space:
mode:
authorOwen Taylor <otaylor@redhat.com>2000-04-05 00:31:59 +0000
committerOwen Taylor <otaylor@src.gnome.org>2000-04-05 00:31:59 +0000
commit613302136667231bcefd772b419369516eb3bf45 (patch)
tree919ed907f3ca69f79210d0778c65df8bec97d4d0 /pango/pangox.h
parent52f2e805bf993f711d09ba6fe4972c7f7ee33eae (diff)
downloadpango-613302136667231bcefd772b419369516eb3bf45.tar.gz
Add user data to PangoContext
Tue Apr 4 20:13:06 2000 Owen Taylor <otaylor@redhat.com> * pango/pango-context.h: Add user data to PangoContext * pango/pangox.[ch] examples/viewer.c: Rework system for create GC's so that the necessary information is stored on the PangoContext instead of being passed to layout_render() * pango/utils.[ch] pango/pango-context.c: fribidi-0.1.9 wants UCS-4 not UCS2; switch accordingly. * pango/fonts.c pango/pango-font.h pango/pangox.c: Add functions to get overall font metrics, possibly per-language. (Right now, just font ascent, descent.) The implementation of this for X is horribly complex.
Diffstat (limited to 'pango/pangox.h')
-rw-r--r--pango/pangox.h20
1 files changed, 10 insertions, 10 deletions
diff --git a/pango/pangox.h b/pango/pangox.h
index 3460263d..abdf148f 100644
--- a/pango/pangox.h
+++ b/pango/pangox.h
@@ -33,12 +33,16 @@ extern "C" {
#define PANGO_RENDER_TYPE_X "PangoRenderX"
-typedef GC (*PangoGetGCFunc) (PangoAttrColor *color, void *user_data);
-typedef void (*PangoFreeGCFunc) (GC gc, void *user_data);
+typedef GC (*PangoGetGCFunc) (PangoContext *context, PangoAttrColor *color, GC base_gc);
+typedef void (*PangoFreeGCFunc) (PangoContext *context, GC gc);
/* Calls for applications
*/
PangoContext * pango_x_get_context (Display *display);
+void pango_x_context_set_funcs (PangoContext *context,
+ PangoGetGCFunc get_gc_func,
+ PangoFreeGCFunc free_gc_func);
+
PangoFont * pango_x_load_font (Display *display,
gchar *spec);
void pango_x_render (Display *display,
@@ -50,20 +54,16 @@ void pango_x_render (Display *display,
gint y);
void pango_x_render_layout_line (Display *display,
Drawable drawable,
+ GC gc,
PangoLayoutLine *line,
int x,
- int y,
- PangoGetGCFunc get_gc,
- PangoFreeGCFunc free_gc,
- gpointer user_data);
+ int y);
void pango_x_render_layout (Display *display,
Drawable drawable,
+ GC gc,
PangoLayout *layout,
int x,
- int y,
- PangoGetGCFunc get_gc,
- PangoFreeGCFunc free_gc,
- gpointer user_data);
+ int y);
/* API for rendering modules
*/