diff --git a/src/desktop-style.cpp b/src/desktop-style.cpp
index 94221ba546fb4eb0c2d42dddb5ac7fcbd8ee938b..a6a4d8567518399c31f87e2c39d42e9d67ed4792 100644 (file)
--- a/src/desktop-style.cpp
+++ b/src/desktop-style.cpp
#include "svg/svg.h"
#include "svg/svg-color.h"
#include "selection.h"
-#include "sp-tspan.h"
-#include "sp-textpath.h"
#include "inkscape.h"
#include "style.h"
#include "prefs-utils.h"
#include "sp-flowregion.h"
#include "sp-flowdiv.h"
#include "sp-linear-gradient.h"
-#include "sp-radial-gradient.h"
#include "sp-pattern.h"
+#include "sp-radial-gradient.h"
+#include "sp-textpath.h"
+#include "sp-tref.h"
+#include "sp-tspan.h"
#include "xml/repr.h"
#include "libnrtype/font-style-to-pos.h"
-
#include "desktop-style.h"
/**
@@ -428,7 +428,10 @@ objects_query_fillstroke (GSList *objects, SPStyle *style_res, bool const isfill
// We consider paint "effectively set" for anything within text hierarchy
SPObject *parent = SP_OBJECT_PARENT (obj);
- bool paint_effectively_set = paint->set || (SP_IS_TEXT(parent) || SP_IS_TEXTPATH(parent) || SP_IS_TSPAN(parent) || SP_IS_FLOWTEXT(parent) || SP_IS_FLOWDIV(parent) || SP_IS_FLOWPARA(parent) || SP_IS_FLOWTSPAN(parent) || SP_IS_FLOWLINE(parent));
+ bool paint_effectively_set =
+ paint->set || (SP_IS_TEXT(parent) || SP_IS_TEXTPATH(parent) || SP_IS_TSPAN(parent)
+ || SP_IS_FLOWTEXT(parent) || SP_IS_FLOWDIV(parent) || SP_IS_FLOWPARA(parent)
+ || SP_IS_FLOWTSPAN(parent) || SP_IS_FLOWLINE(parent));
// 1. Bail out with QUERY_STYLE_MULTIPLE_DIFFERENT if necessary
@@ -499,14 +502,14 @@ objects_query_fillstroke (GSList *objects, SPStyle *style_res, bool const isfill
num ++;
}
+ paint_res->type = paint->type;
if (paint_res->set && paint_effectively_set && paint->type == SP_PAINT_TYPE_PAINTSERVER) { // copy the server
if (isfill) {
- SP_STYLE_FILL_SERVER (style_res) = SP_STYLE_FILL_SERVER (style);
+ sp_style_set_to_uri_string (style_res, true, style->getFillURI());
} else {
- SP_STYLE_STROKE_SERVER (style_res) = SP_STYLE_STROKE_SERVER (style);
+ sp_style_set_to_uri_string (style_res, false, style->getStrokeURI());
}
}
- paint_res->type = paint->type;
paint_res->set = paint_effectively_set;
style_res->fill_rule.computed = style->fill_rule.computed; // no averaging on this, just use the last one
}
SPObject *obj = SP_OBJECT (i->data);
if (!SP_IS_TEXT(obj) && !SP_IS_FLOWTEXT(obj)
- && !SP_IS_TSPAN(obj) && !SP_IS_TEXTPATH(obj)
+ && !SP_IS_TSPAN(obj) && !SP_IS_TREF(obj) && !SP_IS_TEXTPATH(obj)
&& !SP_IS_FLOWDIV(obj) && !SP_IS_FLOWPARA(obj) && !SP_IS_FLOWTSPAN(obj))
continue;
SPObject *obj = SP_OBJECT (i->data);
if (!SP_IS_TEXT(obj) && !SP_IS_FLOWTEXT(obj)
- && !SP_IS_TSPAN(obj) && !SP_IS_TEXTPATH(obj)
+ && !SP_IS_TSPAN(obj) && !SP_IS_TREF(obj) && !SP_IS_TEXTPATH(obj)
&& !SP_IS_FLOWDIV(obj) && !SP_IS_FLOWPARA(obj) && !SP_IS_FLOWTSPAN(obj))
continue;
SPObject *obj = SP_OBJECT (i->data);
if (!SP_IS_TEXT(obj) && !SP_IS_FLOWTEXT(obj)
- && !SP_IS_TSPAN(obj) && !SP_IS_TEXTPATH(obj)
+ && !SP_IS_TSPAN(obj) && !SP_IS_TREF(obj) && !SP_IS_TEXTPATH(obj)
&& !SP_IS_FLOWDIV(obj) && !SP_IS_FLOWPARA(obj) && !SP_IS_FLOWTSPAN(obj))
continue;