From 50f9aa34d9c9563df9002d8a70ae37a747c8f422 Mon Sep 17 00:00:00 2001 From: "Jon A. Cruz" Date: Thu, 8 Jul 2010 22:02:03 -0700 Subject: Cleanup of gradient swatch property and collection policy. (bzr r9602) --- src/gradient-chemistry.cpp | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'src/gradient-chemistry.cpp') diff --git a/src/gradient-chemistry.cpp b/src/gradient-chemistry.cpp index 8a199d4a3..974a13b5f 100644 --- a/src/gradient-chemistry.cpp +++ b/src/gradient-chemistry.cpp @@ -1203,11 +1203,13 @@ SPGradient *sp_document_default_gradient_vector( SPDocument *document, SPColor c Inkscape::XML::Node *repr = xml_doc->createElement("svg:linearGradient"); - repr->setAttribute("inkscape:collect", "always"); - // set here, but removed when it's edited in the gradient editor - // to further reduce clutter, we could - // (1) here, search gradients by color and return what is found without duplication - // (2) in fill & stroke, show only one copy of each gradient in list + if ( !singleStop ) { + repr->setAttribute("inkscape:collect", "always"); + // set here, but removed when it's edited in the gradient editor + // to further reduce clutter, we could + // (1) here, search gradients by color and return what is found without duplication + // (2) in fill & stroke, show only one copy of each gradient in list + } Glib::ustring colorStr = color.toString(); addStop( repr, colorStr, 1, "0" ); -- cgit v1.2.3