[gnumeric] Always export a transparent fill style in charts. [#779160]



commit 04be950110cca129035e3e7513cbe6c918d105fe
Author: Jean Brefort <jean brefort normalesup org>
Date:   Sun Feb 26 09:06:21 2017 +0100

    Always export a transparent fill style in charts. [#779160]

 NEWS                               |    1 +
 plugins/excel/ChangeLog            |    6 ++++++
 plugins/excel/xlsx-write-drawing.c |   14 ++------------
 3 files changed, 9 insertions(+), 12 deletions(-)
---
diff --git a/NEWS b/NEWS
index 9a4304f..3ae97e0 100644
--- a/NEWS
+++ b/NEWS
@@ -2,6 +2,7 @@ Gnumeric 1.12.34
 
 Jean:
        * Fix xlsx export of chart series names. [#778618]
+       * Always export a transparent fill style in charts. [#779160]
 
 Morten:
        * Doc fixes.
diff --git a/plugins/excel/ChangeLog b/plugins/excel/ChangeLog
index ddd8f3d..9b4a5c5 100644
--- a/plugins/excel/ChangeLog
+++ b/plugins/excel/ChangeLog
@@ -1,3 +1,9 @@
+2017-02-26  Jean Brefort  <jean brefort normalesup org>
+
+       * xlsx-write-drawing.c (xlsx_write_go_style_full): always export a
+       transparent fill style. [#779160]
+       (xlsx_write_one_chart): simplify legend style export.
+
 2017-02-21  Jean Brefort  <jean brefort normalesup org>
 
        * xlsx-write-drawing.c (xlsx_write_one_chart): export legend style.
diff --git a/plugins/excel/xlsx-write-drawing.c b/plugins/excel/xlsx-write-drawing.c
index ff5646b..0a743a4 100644
--- a/plugins/excel/xlsx-write-drawing.c
+++ b/plugins/excel/xlsx-write-drawing.c
@@ -353,9 +353,7 @@ xlsx_write_go_style_full (GsfXMLOut *xml, GOStyle *style, const XLSXStyleContext
                gsf_xml_out_end_element (xml); /* </a:prstGeom> */
        }
 
-       if ((style->interesting_fields & GO_STYLE_FILL) &&
-           (style->fill.type != GO_STYLE_FILL_NONE ||
-            sctx->must_fill_fill)) {
+       if (style->interesting_fields & GO_STYLE_FILL) {
                switch (style->fill.type) {
                default:
                        g_warning ("invalid fill type, saving as none");
@@ -1310,15 +1308,7 @@ xlsx_write_one_chart (XLSXWriteState *state, GsfXMLOut *xml, GogObject const *ch
                }
                xlsx_write_chart_cstr_unchecked (xml, "c:legendPos", str);
                xlsx_write_layout (xml, obj);
-               {
-                       /* we need to ensure that fill mode is exported even if set to none. */ 
-                       XLSXStyleContext sctx;
-                       xlsx_style_context_init (&sctx, state);
-                       sctx.must_fill_fill = TRUE;
-                       xlsx_write_go_style_full
-                               (xml, go_styled_object_get_style (GO_STYLED_OBJECT (obj)),
-                               &sctx);
-               }
+               xlsx_write_go_style (xml, state, go_styled_object_get_style (GO_STYLED_OBJECT (obj)));
                gsf_xml_out_end_element (xml); /* </c:legend> */
        }
        gsf_xml_out_end_element (xml); /* </c:chart> */


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]