gimp r26807 - in trunk: . plug-ins/pygimp
- From: larsc svn gnome org
- To: svn-commits-list gnome org
- Subject: gimp r26807 - in trunk: . plug-ins/pygimp
- Date: Thu, 28 Aug 2008 20:49:07 +0000 (UTC)
Author: larsc
Date: Thu Aug 28 20:49:07 2008
New Revision: 26807
URL: http://svn.gnome.org/viewvc/gimp?rev=26807&view=rev
Log:
2008-08-28 Lars-Peter Clausen <lars metafoo de>
* plug-ins/pygimp/gimpui.defs
* plug-ins/pygimp/gimpui.override:
Wrapped GimpRuler, GimpHRuler and GimpVRuler widgets.
Modified:
trunk/ChangeLog
trunk/plug-ins/pygimp/gimpui.defs
trunk/plug-ins/pygimp/gimpui.override
Modified: trunk/plug-ins/pygimp/gimpui.defs
==============================================================================
--- trunk/plug-ins/pygimp/gimpui.defs (original)
+++ trunk/plug-ins/pygimp/gimpui.defs Thu Aug 28 20:49:07 2008
@@ -280,6 +280,27 @@
(gtype-id "GIMP_TYPE_PROGRESS_BAR")
)
+(define-object Ruler
+ (in-module "Gimp")
+ (parent "GtkWidget")
+ (c-name "GimpRuler")
+ (gtype-id "GIMP_TYPE_RULER")
+)
+
+(define-object HRuler
+ (in-module "Gimp")
+ (parent "GimpRuler")
+ (c-name "GimpHRuler")
+ (gtype-id "GIMP_TYPE_HRULER")
+)
+
+(define-object VRuler
+ (in-module "Gimp")
+ (parent "GimpRuler")
+ (c-name "GimpVRuler")
+ (gtype-id "GIMP_TYPE_VRULER")
+)
+
(define-object ScrolledPreview
(in-module "Gimp")
(parent "GimpPreview")
@@ -575,7 +596,7 @@
(is-constructor-of "GimpCellRendererToggle")
(return-type "GtkCellRenderer*")
(properties
- '("stock-id", (argname "stock_id") (optional))
+ '("stock-id" (argname "stock_id") (optional))
)
)
@@ -3222,3 +3243,103 @@
)
+;; From gimpruler.h
+
+(define-function gimp_ruler_get_type
+ (c-name "gimp_ruler_get_type")
+ (return-type "GType")
+)
+
+(define-method set_unit
+ (of-object "GimpRuler")
+ (c-name "gimp_ruler_set_unit")
+ (return-type "none")
+ (parameters
+ '("GimpUnit" "unit")
+ )
+)
+
+(define-method get_unit
+ (of-object "GimpRuler")
+ (c-name "gimp_ruler_get_unit")
+ (return-type "GimpUnit")
+)
+
+(define-method set_position
+ (of-object "GimpRuler")
+ (c-name "gimp_ruler_set_position")
+ (return-type "none")
+ (parameters
+ '("gdouble" "position")
+ )
+)
+
+(define-method get_position
+ (of-object "GimpRuler")
+ (c-name "gimp_ruler_get_position")
+ (return-type "gdouble")
+)
+
+(define-method set_range
+ (of-object "GimpRuler")
+ (c-name "gimp_ruler_set_range")
+ (return-type "none")
+ (parameters
+ '("gdouble" "lower")
+ '("gdouble" "upper")
+ '("gdouble" "max_size")
+ )
+)
+
+(define-method get_range
+ (of-object "GimpRuler")
+ (c-name "gimp_ruler_get_range")
+ (return-type "none")
+ (parameters
+ '("gdouble*" "lower")
+ '("gdouble*" "upper")
+ '("gdouble*" "max_size")
+ )
+)
+
+
+
+;; From gimphruler.h
+
+(define-function gimp_hruler_get_type
+ (c-name "gimp_hruler_get_type")
+ (return-type "GType")
+)
+
+(define-function gimp_hruler_new
+ (c-name "gimp_hruler_new")
+ (is-constructor-of "GimpHRuler")
+ (return-type "GtkWidget*")
+ (properties
+ '("lower" (optional))
+ '("upper" (optional))
+ '("max-size" (argname "max_size") (optional))
+ )
+)
+
+
+
+;; From gimpvruler.h
+
+(define-function gimp_vruler_get_type
+ (c-name "gimp_vruler_get_type")
+ (return-type "GType")
+)
+
+(define-function gimp_vruler_new
+ (c-name "gimp_vruler_new")
+ (is-constructor-of "GimpVRuler")
+ (return-type "GtkWidget*")
+ (properties
+ '("lower" (optional))
+ '("upper" (optional))
+ '("max-size" (argname "max_size") (optional))
+ )
+)
+
+
Modified: trunk/plug-ins/pygimp/gimpui.override
==============================================================================
--- trunk/plug-ins/pygimp/gimpui.override (original)
+++ trunk/plug-ins/pygimp/gimpui.override Thu Aug 28 20:49:07 2008
@@ -1977,3 +1977,16 @@
%%
new-constructor GIMP_TYPE_DRAWABLE_PREVIEW
+%%
+override gimp_ruler_get_range noargs
+static PyObject *
+_wrap_gimp_ruler_get_range(PyGObject *self)
+{
+ gdouble lower;
+ gdouble upper;
+ gdouble max_size;
+
+ gimp_ruler_get_range(GIMP_RULER(self->obj), &lower, &upper, &max_size);
+
+ return Py_BuildValue("(ddd)", lower, upper, max_size);
+}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]