libgimp: bug fixes and design improvements for generated widgets.
This commit is contained in:
parent
bb322d94d7
commit
5fa38d5765
2 changed files with 10 additions and 6 deletions
|
|
@ -139,11 +139,6 @@ gimp_procedure_dialog_dispose (GObject *object)
|
|||
g_clear_pointer (&dialog->priv->reset_popover, gtk_widget_destroy);
|
||||
g_clear_pointer (&dialog->priv->widgets, g_hash_table_unref);
|
||||
|
||||
if (dialog->priv->widgets)
|
||||
{
|
||||
g_hash_table_destroy (dialog->priv->widgets);
|
||||
dialog->priv->widgets = NULL;
|
||||
}
|
||||
g_clear_object (&dialog->priv->label_group);
|
||||
|
||||
G_OBJECT_CLASS (parent_class)->dispose (object);
|
||||
|
|
@ -400,6 +395,10 @@ gimp_procedure_dialog_get_widget (GimpProcedureDialog *dialog,
|
|||
buffer = gimp_prop_text_buffer_new (G_OBJECT (dialog->priv->config),
|
||||
property, -1);
|
||||
widget = gtk_text_view_new_with_buffer (buffer);
|
||||
gtk_text_view_set_top_margin (GTK_TEXT_VIEW (widget), 3);
|
||||
gtk_text_view_set_bottom_margin (GTK_TEXT_VIEW (widget), 3);
|
||||
gtk_text_view_set_left_margin (GTK_TEXT_VIEW (widget), 3);
|
||||
gtk_text_view_set_right_margin (GTK_TEXT_VIEW (widget), 3);
|
||||
g_object_unref (buffer);
|
||||
}
|
||||
else if (widget_type == GTK_TYPE_ENTRY)
|
||||
|
|
@ -911,7 +910,7 @@ gimp_procedure_dialog_fill_frame (GimpProcedureDialog *dialog,
|
|||
return frame;
|
||||
}
|
||||
|
||||
frame = gtk_frame_new (NULL);
|
||||
frame = gimp_frame_new (NULL);
|
||||
|
||||
if (contents_id)
|
||||
{
|
||||
|
|
@ -923,6 +922,7 @@ gimp_procedure_dialog_fill_frame (GimpProcedureDialog *dialog,
|
|||
return frame;
|
||||
}
|
||||
|
||||
g_object_ref (contents);
|
||||
gtk_container_add (GTK_CONTAINER (frame), contents);
|
||||
gtk_widget_show (contents);
|
||||
}
|
||||
|
|
@ -937,6 +937,7 @@ gimp_procedure_dialog_fill_frame (GimpProcedureDialog *dialog,
|
|||
return frame;
|
||||
}
|
||||
|
||||
g_object_ref (title);
|
||||
gtk_frame_set_label_widget (GTK_FRAME (frame), title);
|
||||
gtk_widget_show (title);
|
||||
|
||||
|
|
|
|||
|
|
@ -144,6 +144,9 @@ gimp_label_int_widget_constructed (GObject *object)
|
|||
|
||||
G_OBJECT_CLASS (parent_class)->constructed (object);
|
||||
|
||||
gtk_grid_set_column_spacing (GTK_GRID (widget), 6);
|
||||
gtk_grid_set_row_spacing (GTK_GRID (widget), 6);
|
||||
|
||||
/* This is important to make this object into a property widget. It
|
||||
* will allow config object to bind the "value" property of this
|
||||
* widget, and therefore be updated automatically.
|
||||
|
|
|
|||
Loading…
Reference in a new issue