summaryrefslogtreecommitdiffstats
path: root/src/ui
diff options
context:
space:
mode:
authorJohn Smith <john.smith7545@yahoo.com>2012-08-20 12:53:17 +0000
committerJohn Smith <john.smith7545@yahoo.com>2012-08-20 12:53:17 +0000
commite92962ddc609aaba91d1b9781ea044e84bafeb1b (patch)
treedc25d7d48782832e2c8073f63a2dec4a26081cf8 /src/ui
parentround-off incoming png resolution to 0.1 dpi (Bug 165952 comment 20) (diff)
downloadinkscape-e92962ddc609aaba91d1b9781ea044e84bafeb1b.tar.gz
inkscape-e92962ddc609aaba91d1b9781ea044e84bafeb1b.zip
Fix for 165865 : markers must take object's stroke color
(bzr r11614)
Diffstat (limited to 'src/ui')
-rw-r--r--src/ui/cache/svg_preview_cache.cpp8
-rw-r--r--src/ui/cache/svg_preview_cache.h1
-rw-r--r--src/ui/dialog/inkscape-preferences.cpp12
-rw-r--r--src/ui/dialog/inkscape-preferences.h4
4 files changed, 25 insertions, 0 deletions
diff --git a/src/ui/cache/svg_preview_cache.cpp b/src/ui/cache/svg_preview_cache.cpp
index f8a806a13..7842bd5b3 100644
--- a/src/ui/cache/svg_preview_cache.cpp
+++ b/src/ui/cache/svg_preview_cache.cpp
@@ -121,6 +121,14 @@ GdkPixbuf* SvgPreview::get_preview(const gchar* uri, const gchar* id, Inkscape::
return px;
}
+void SvgPreview::remove_preview_from_cache(const Glib::ustring& key) {
+ std::map<Glib::ustring, GdkPixbuf *>::iterator found = _pixmap_cache.find(key);
+ if ( found != _pixmap_cache.end() ) {
+ _pixmap_cache.erase(key);
+ }
+}
+
+
}
}
}
diff --git a/src/ui/cache/svg_preview_cache.h b/src/ui/cache/svg_preview_cache.h
index 11d26fe22..b04a82350 100644
--- a/src/ui/cache/svg_preview_cache.h
+++ b/src/ui/cache/svg_preview_cache.h
@@ -40,6 +40,7 @@ class SvgPreview {
GdkPixbuf* get_preview_from_cache(const Glib::ustring& key);
void set_preview_in_cache(const Glib::ustring& key, GdkPixbuf* px);
GdkPixbuf* get_preview(const gchar* uri, const gchar* id, Inkscape::DrawingItem *root, double scale_factor, unsigned int psize);
+ void remove_preview_from_cache(const Glib::ustring& key);
};
}; // namespace Cache
diff --git a/src/ui/dialog/inkscape-preferences.cpp b/src/ui/dialog/inkscape-preferences.cpp
index 0e4d7fd56..d72cde42e 100644
--- a/src/ui/dialog/inkscape-preferences.cpp
+++ b/src/ui/dialog/inkscape-preferences.cpp
@@ -1073,6 +1073,18 @@ void InkscapePreferences::initPageBehavior()
_page_behavior.add_line( false, _("Simplification threshold:"), _misc_simpl, "",
_("How strong is the Node tool's Simplify command by default. If you invoke this command several times in quick succession, it will act more and more aggressively; invoking it again after a pause restores the default threshold."), false);
+ _markers_color_stock.init ( _("Color stock markers the same color as object"), "/options/markers/colorStockMarkers", true);
+ _markers_color_custom.init ( _("Color custom markers the same color as object"), "/options/markers/colorCustomMarkers", false);
+ _markers_color_update.init ( _("Update marker color when object color changes"), "/options/markers/colorUpdateMarkers", true);
+
+ _page_behavior.add_group_header( _("Markers"));
+ _page_behavior.add_line( true, "", _markers_color_stock, "",
+ _("Stroke color same as object, fill color either object fill color or marker fill color"));
+ _page_behavior.add_line( true, "", _markers_color_custom, "",
+ _("Stroke color same as object, fill color either object fill color or marker fill color"));
+ _page_behavior.add_line( true, "", _markers_color_update, "",
+ _("Update marker color when object color changes"));
+
// Selecting options
_sel_all.init ( _("Select in all layers"), "/options/kbselection/inlayer", PREFS_SELECTION_ALL, false, 0);
_sel_current.init ( _("Select only within current layer"), "/options/kbselection/inlayer", PREFS_SELECTION_LAYER, true, &_sel_all);
diff --git a/src/ui/dialog/inkscape-preferences.h b/src/ui/dialog/inkscape-preferences.h
index 6d13b9d20..c78eb08d8 100644
--- a/src/ui/dialog/inkscape-preferences.h
+++ b/src/ui/dialog/inkscape-preferences.h
@@ -281,6 +281,10 @@ protected:
UI::Widget::PrefCheckButton _sel_layer_deselects;
UI::Widget::PrefCheckButton _sel_cycle;
+ UI::Widget::PrefCheckButton _markers_color_stock;
+ UI::Widget::PrefCheckButton _markers_color_custom;
+ UI::Widget::PrefCheckButton _markers_color_update;
+
UI::Widget::PrefSpinButton _importexport_export_res;
UI::Widget::PrefSpinButton _importexport_import_res;
UI::Widget::PrefSlider _snap_delay;