gtkimreg(3)

gtkimreg3

Gtk+ widget to select region of a (gdkimlib) image

Usage

#include <gtk/gtkimreg.h>

GtkType gtk_imreg_get_type (void);
GtkWidget* gtk_imreg_new (const gchar * title, GdkImlibImage * im, int rw, int rh, GtkWidget * user_area);
gint gtk_imreg_get_left (GtkImReg * imreg);
gint gtk_imreg_get_top (GtkImReg * imreg);
gint gtk_imreg_get_right (GtkImReg * imreg);
gint gtk_imreg_get_bottom (GtkImReg * imreg);
gint gtk_imreg_get (GtkImReg * imreg, gint * le, gint * to, gint * ri, gint * bo);
gint gtk_imreg_set_left (GtkImReg * imreg, gint left);
gint gtk_imreg_set_top (GtkImReg * imreg, gint top);
gint gtk_imreg_set_right (GtkImReg * imreg, gint right);
gint gtk_imreg_set_bottom (GtkImReg * imreg, gint bottom);
gint gtk_imreg_set (GtkImReg * imreg, gint left, gint top, gint right, gint bottom);

Overview

Select an area in an image given as GdkImlib structure and obtain the coordinates of this image. The user_area can be NULL or an user supplied widget to add certain functionality.
The gtk_imreg_get_ functions are useful in an OK-callback to obtain the chosen coordinates. The gtk_imreg_set_ functions enable the user to preset a region selection.

Examples

See testimreg.c which is shipped with the sources. In a Debian system you can find it under
/usr/share/doc/libgtkimreg-dev/example/testimreg
next to an appropriate Makefile and an image example.

Requires

GTK+ 1.2, GdkImlib 1.9.2 or higher

Releases

4 releases since Debian 3.0 (Woody); the text changed 2 times.

  1. 3.0
  2. 3.1
  3. 4.0–5.0

Author

Andreas Tille <[email protected]>
http://fam-tille.de

From libgtkimreg-dev 0.1.3.1-1 in Debian 5.0 (Lenny). Parsed by carta from the page's man source.