Code

- new: Print Colors Preview Dialog and rendermode
[inkscape.git] / src / desktop.cpp
index f7ef1a8cdb79c6d9a02d6a6aef7be6aaf58c5906..0e4d4caf3d1f4b7904a47c7196bf73f179794294 100644 (file)
@@ -164,8 +164,10 @@ SPDesktop::SPDesktop() :
 }
 
 void
-SPDesktop::init (SPNamedView *nv, SPCanvas *aCanvas)
+SPDesktop::init (SPNamedView *nv, SPCanvas *aCanvas, Inkscape::UI::View::EditWidgetInterface *widget)
 {
+    _widget = widget;
+
     // Temporary workaround for link order issues:
     Inkscape::DeviceManager::getManager().getDevices();
     Inkscape::Preferences *prefs = Inkscape::Preferences::get();
@@ -456,6 +458,9 @@ void SPDesktop::displayModeToggle() {
         _setDisplayMode(Inkscape::RENDERMODE_OUTLINE);
         break;
     case Inkscape::RENDERMODE_OUTLINE:
+        _setDisplayMode(Inkscape::RENDERMODE_PRINT_COLORS_PREVIEW);
+        break;
+    case Inkscape::RENDERMODE_PRINT_COLORS_PREVIEW:
     default:
         _setDisplayMode(Inkscape::RENDERMODE_NORMAL);
     }