index 1efae59e1a56da5c1ffc20843f6618d0cac78b76..9933887f31f6e7f9d0e045e308c2339c6514ded6 100644 (file)
#include <inkscape.h>
#include <document-private.h>
#include <xml/repr.h>
+#include <glibmm/i18n.h>
+#include <display/sp-canvas.h>
// These can be deleted once we sort out the libart dependence.
sp_repr_css_attr_unref (css);
- sp_document_done (SP_ACTIVE_DOCUMENT);
+ sp_document_done (SP_ACTIVE_DOCUMENT, SP_VERB_DIALOG_FILL_STROKE,
+ _("Change fill rule"));
}
static gchar *undo_label_1 = "fill:flatcolor:1";
case SP_PAINT_SELECTOR_MODE_COLOR_CMYK:
{
sp_paint_selector_set_flat_color (psel, SP_ACTIVE_DESKTOP, "fill", "fill-opacity");
- sp_document_maybe_done (sp_desktop_document(SP_ACTIVE_DESKTOP), undo_label);
+ sp_document_maybe_done (sp_desktop_document(SP_ACTIVE_DESKTOP), undo_label, SP_VERB_DIALOG_FILL_STROKE,
+ _("Set fill color"));
g_object_set_data (G_OBJECT (spw), "local", GINT_TO_POINTER (TRUE)); // local change, do not update from selection
break;
}
sp_repr_css_attr_unref (css);
- sp_document_done (document);
+ sp_document_done (document, SP_VERB_DIALOG_FILL_STROKE,
+ _("Remove fill"));
break;
}
case SP_PAINT_SELECTOR_MODE_COLOR_RGB:
case SP_PAINT_SELECTOR_MODE_COLOR_CMYK:
{
+ // FIXME: fix for GTK breakage, see comment in SelectedStyle::on_opacity_changed; here it results in losing release events
+ sp_canvas_force_full_redraw_after_interruptions(sp_desktop_canvas(desktop), 0);
+
sp_paint_selector_set_flat_color (psel, desktop, "fill", "fill-opacity");
- sp_document_maybe_done (sp_desktop_document(desktop), undo_label);
+ sp_document_maybe_done (sp_desktop_document(desktop), undo_label, SP_VERB_DIALOG_FILL_STROKE,
+ _("Set fill color"));
+ // resume interruptibility
+ sp_canvas_end_forced_full_redraws(sp_desktop_canvas(desktop));
// on release, toggle undo_label so that the next drag will not be lumped with this one
if (undo_label == undo_label_1)
sp_repr_css_attr_unref (css);
- sp_document_done (document);
+ sp_document_done (document, SP_VERB_DIALOG_FILL_STROKE,
+ _("Set gradient on fill"));
}
break;
} // end if
- sp_document_done (document);
+ sp_document_done (document, SP_VERB_DIALOG_FILL_STROKE,
+ _("Set pattern on fill"));
} // end if
sp_desktop_set_style (desktop, css);
sp_repr_css_attr_unref (css);
- sp_document_done (document);
+ sp_document_done (document, SP_VERB_DIALOG_FILL_STROKE,
+ _("Unset fill"));
}
break;