# GimpUi.ProcedureDialog.get_widget

    @accepts(GimpUi.ProcedureDialog, unicode, GType)
    @returns(Gtk.Widget)
    def get_widget(self, property, widget_type):
        # Python wrapper for gimp_procedure_dialog_get_widget()

Creates a new Gtk.Widget for property according to the property type. The following types are possible:

- %G_TYPE_PARAM_BOOLEAN: * %GTK_TYPE_CHECK_BUTTON (default) * %GTK_TYPE_SWITCH - %G_TYPE_PARAM_INT or %G_TYPE_PARAM_DOUBLE: * %GIMP_TYPE_LABEL_SPIN (default): a spin button with a label. * %GIMP_TYPE_SCALE_ENTRY: a scale entry with label. * %GIMP_TYPE_SPIN_SCALE: a spin scale with label embedded. * %GIMP_TYPE_SPIN_BUTTON: a spin button with no label. - %G_TYPE_PARAM_STRING: * %GIMP_TYPE_LABEL_ENTRY (default): an entry with a label. * %GTK_TYPE_ENTRY: an entry with no label. * %GTK_TYPE_TEXT_VIEW: a text view with no label. - %GIMP_TYPE_PARAM_RGB: * %GIMP_TYPE_LABEL_COLOR (default): a color button with a label. Please use GimpUi.ProcedureDialog.get_color_widget for a non-editable color area with a label. * %GIMP_TYPE_COLOR_BUTTON: a color button with no label. * %GIMP_TYPE_COLOR_AREA: a color area with no label. - %G_TYPE_PARAM_FILE: * %GTK_FILE_CHOOSER_BUTTON (default): generic file chooser button in %GTK_FILE_CHOOSER_ACTION_OPEN mode. Please use GimpUi.ProcedureDialog.get_file_chooser to create buttons in other modes.

If the widget_type is not supported for the actual type of property, the function will fail. To keep the default, set to %G_TYPE_NONE.

If a widget has already been created for this procedure, it will be returned instead (even if with a different widget_type).

self

  the associated GimpUi.ProcedureDialog.

property

  name of the property to build a widget for. It must be a property of the Gimp.Procedure self has been created for.

widget_type

  alternative widget type. %G_TYPE_NONE will create the default type of widget for the associated property type.

Returns