next up previous contents
Next: GLib Up: GTK Previous: Advanced data manipulation   Contents


GDK - Gimp Drawing Kit

Gdk is basically a wrapper around the standard Xlib function calls. All functions are written to provide an easy way to access Xlib functions in an easier an slightly more intuitive manner. In addition, since th GDK uses the GLib (Section B.3), it will be more portable and safer to use on multiple platforms.

In the Osiris project the GDK is used by the Editor module to draw rectangular graphical objects and theirs contents as well. Following Gdk functions are used (respectively to draw a line, a rectangle and a string of chars):

void gdk_draw_line( GdkDrawable *drawable,
                    GdkGC *gc,
                    gint x1,
                    gint y1,
                    gint x2,
                    gint y2);

void gdk_draw_rectangle( GdkDrawable *drawable,
                         GdkGC *gc,
                         gint filled,
                         gint x,
                         gint y,
                         gint width,
                         gint height);

void gdk_draw_string( GdkDrawable *drawable,
                      GdkFont *font,
                      GdkGC *gc,
                      gint x,
                      gint y,
                      const gchar *string);



Igor Wojnicki 2001-02-21