From 1d31728fb7399f48d272560a290dc990b75a197e Mon Sep 17 00:00:00 2001 From: Tavmjong Bah Date: Tue, 11 Mar 2014 15:52:08 +0100 Subject: Change stroke-dasharray and stroke-dashoffset handling to match other properties. Split style.h into more manageable size files. (bzr r13135) --- src/selection-chemistry.cpp | 14 +++----------- 1 file changed, 3 insertions(+), 11 deletions(-) (limited to 'src/selection-chemistry.cpp') diff --git a/src/selection-chemistry.cpp b/src/selection-chemistry.cpp index b3d9af910..fad2dff5b 100644 --- a/src/selection-chemistry.cpp +++ b/src/selection-chemistry.cpp @@ -2067,17 +2067,9 @@ GSList *sp_get_same_stroke_style(SPItem *sel, GSList *src, SPSelectStrokeStyleTy } } else if (type == SP_STROKE_STYLE_DASHES ) { - match = (sel_style->stroke_dasharray_set == iter_style->stroke_dasharray_set); - if (sel_style->stroke_dasharray_set && iter_style->stroke_dasharray_set) { - match = (sel_style->stroke_dash.n_dash == iter_style->stroke_dash.n_dash); - if (sel_style->stroke_dash.n_dash == iter_style->stroke_dash.n_dash) { - for (int i = 0; i < sel_style->stroke_dash.n_dash; i++) { - if (sel_style->stroke_dash.dash[i] != iter_style->stroke_dash.dash[i]) { - match = false; - break; - } - } - } + match = (sel_style->stroke_dasharray.set == iter_style->stroke_dasharray.set); + if (sel_style->stroke_dasharray.set && iter_style->stroke_dasharray.set) { + match = (sel_style->stroke_dasharray.values == iter_style->stroke_dasharray.values); } } else if (type == SP_STROKE_STYLE_MARKERS) { -- cgit v1.2.3