diff --git a/src/ui/dialog/print.h b/src/ui/dialog/print.h
index 721c910ffd77f1c5f4d3ed452922a2e894a95b81..f6c69bdb87bddf2801422bd735f6a0b3488e3f00 100644 (file)
--- a/src/ui/dialog/print.h
+++ b/src/ui/dialog/print.h
#include "ui/widget/rendering-options.h"
+/*
+ * gtk 2.12.0 has a bug (http://bugzilla.gnome.org/show_bug.cgi?id=482089)
+ * where it fails to correctly deal with gtkmm signal management. As a result
+ * we have call gtk directly instead of doing a much cleaner version of
+ * this printing dialog, using full gtkmmification. (The bug was fixed
+ * in 2.12.1, so when the Inkscape gtk minimum version is bumped there,
+ * we can revert Inkscape commit 16865.
+ */
+struct workaround_gtkmm
+{
+ SPDocument *_doc;
+ SPItem *_base;
+ Inkscape::UI::Widget::RenderingOptions *_tab;
+};
namespace Inkscape {
namespace UI {
class Print {
public:
Print(SPDocument *doc, SPItem *base);
-
- Gtk::PrintOperationResult run(Gtk::PrintOperationAction action, Gtk::Window& parentWindow);
- //GtkPrintOperationResult run(GtkPrintOperationAction action);
+ Gtk::PrintOperationResult run(Gtk::PrintOperationAction, Gtk::Window &parent_window);
protected:
- Glib::RefPtr<Gtk::PrintOperation> _printop;
- //GtkPrintOperation *_printop;
-
- Gtk::Widget *_create_custom_widget ();
- void _custom_widget_apply (Gtk::Widget *widget);
- void _draw_page (const Glib::RefPtr<Gtk::PrintContext> &context,
- int page_nr);
private:
+ GtkPrintOperation *_printop;
SPDocument *_doc;
SPItem *_base;
Inkscape::UI::Widget::RenderingOptions _tab;
+
+ struct workaround_gtkmm _workaround;
};
} // namespace Dialog