From abe3ac6415bb4ae93f146a98756bce8d5ae443f4 Mon Sep 17 00:00:00 2001 From: ishmal Date: Wed, 3 May 2006 22:33:56 +0000 Subject: [PATCH] add gradient comments --- src/extension/internal/odf.cpp | 30 ++++++++++++++++++++++++++++-- 1 file changed, 28 insertions(+), 2 deletions(-) diff --git a/src/extension/internal/odf.cpp b/src/extension/internal/odf.cpp index 27804397d..8d60f5fe0 100644 --- a/src/extension/internal/odf.cpp +++ b/src/extension/internal/odf.cpp @@ -1072,6 +1072,8 @@ OdfOutput::preprocess(ZipFile &zf, Inkscape::XML::Node *node) } else if (style->fill.type == SP_PAINT_TYPE_PAINTSERVER) { + //## Gradient. Look in writeStyle() below to see what info + // we need to read into GradientInfo. if (!SP_IS_GRADIENT(SP_STYLE_FILL_SERVER(style))) return; isGradient = true; @@ -1353,13 +1355,37 @@ bool OdfOutput::writeStyle(Writer &outs) { GradientInfo gi(*giter); outs.printf(" + =================================================================== + */ + outs.printf("draw:display-name=\"linear borderless\" "); } - else if (gi.style == "gradient") + else if (gi.style == "radial") { + /* + =================================================================== + RADIAL gradient. We need something that looks like this: + + + =================================================================== + */ + outs.printf("draw:display-name=\"radial borderless\" "); outs.printf("draw:cx=\".2f%%\" draw:cy=\".2f%%\" ", gi.cx, gi.cy); } else -- 2.39.5