After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 643873 - Incomplete loading of graphs from xlsx
Incomplete loading of graphs from xlsx
Status: RESOLVED FIXED
Product: Gnumeric
Classification: Applications
Component: import/export MS Excel (tm)
git master
Other All
: Normal normal
: ---
Assigned To: Jody Goldberg
Jody Goldberg
: 644983 (view as bug list)
Depends on:
Blocks: 647218
 
 
Reported: 2011-03-04 14:12 UTC by Morten Welinder
Modified: 2011-12-27 14:47 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
XL2003 screen snapshot (76.15 KB, image/png)
2011-03-04 14:12 UTC, Morten Welinder
  Details
Ugly patch (2.49 KB, patch)
2011-03-04 21:26 UTC, Morten Welinder
none Details | Review
Whole patch, still ugly (4.87 KB, patch)
2011-03-04 21:27 UTC, Morten Welinder
committed Details | Review
warnings fix. (16.60 KB, patch)
2011-03-08 10:58 UTC, Jean Bréfort
none Details | Review
enhanced patch (27.65 KB, patch)
2011-03-09 21:30 UTC, Jean Bréfort
none Details | Review
Import combo boxes from xlsx. (8.47 KB, patch)
2011-03-23 19:32 UTC, Jean Bréfort
none Details | Review
sample barchart file (146.05 KB, application/vnd.openxmlformats-officedocument.spreadsheetml.sheet)
2011-03-23 20:48 UTC, Andreas J. Guelzow
  Details
make combo box import acceptable (15.69 KB, patch)
2011-03-27 12:57 UTC, Jean Bréfort
committed Details | Review
screen shot of the first file (173.21 KB, image/jpeg)
2011-08-22 18:03 UTC, Andreas J. Guelzow
  Details
screenshot of the barchart file (64.81 KB, image/jpeg)
2011-08-22 18:04 UTC, Andreas J. Guelzow
  Details

Description Morten Welinder 2011-03-04 14:12:10 UTC
Created attachment 182465 [details]
XL2003 screen snapshot

http://www.autoobserver.com/car-data-center/assets/2011-03%20Sales.xlsx

The graphs in gnumeric are basically blank.  The attached snapshot
shows what xl gets out of the file.
Comment 1 Jean Bréfort 2011-03-04 14:48:41 UTC
Thanks. The issue is the same as #643874. Of course we might use the saved values instead of the expression, but it would be a bug in itself (it might be useful for external references, but it is not the case).
Comment 2 Morten Welinder 2011-03-04 21:26:16 UTC
Created attachment 182520 [details] [review]
Ugly patch

/me creates a link to bug 643874.

Ugly patch that does the job.  We actually get data in the charts!
Comment 3 Morten Welinder 2011-03-04 21:27:44 UTC
Created attachment 182521 [details] [review]
Whole patch, still ugly

Previous patch was incomplete.
Comment 4 Jean Bréfort 2011-03-04 21:59:06 UTC
At least things work. I'm not enough expert to see the ugly aspect.
Comment 5 Morten Welinder 2011-03-05 17:14:49 UTC
"ugly": lexing these need to go into the conventions.

Stangely only the middle graph has titles in Gnumeric.
Comment 6 Jean Bréfort 2011-03-05 18:25:53 UTC
That's because the other graphs use formulas and they are just dropped for now, I'll (try to) fix that.
Comment 7 Jean Bréfort 2011-03-05 19:30:16 UTC
Titles should now appear in all charts.
Comment 8 Jean Bréfort 2011-03-07 08:57:59 UTC
Strange that some columns look like if there were some pattern at work in excel. The file only has solidFill, no pattFill.
Comment 9 Morten Welinder 2011-03-07 14:34:03 UTC
Jean: details like that could be related to the translation that my xl (2003?)
claims is going on when loading the file.
Comment 10 Jean Bréfort 2011-03-07 14:41:04 UTC
Might be because 2003 did not support the alpha value.
Comment 11 Morten Welinder 2011-03-07 16:34:02 UTC
I still get...

> MarketShare!P70 : Unknown color 'bg1'
...
> MarketShare!P70 : Dropping missing object

...but XL shows nothing there either.
Comment 12 Jean Bréfort 2011-03-07 16:47:37 UTC
'bg1' is one of excel theme colors as far as I understand it. I don't know which color it is really.

The missing object thing worries me a bit more. I'll try to understand what it is.
Comment 13 Jean Bréfort 2011-03-08 10:58:51 UTC
Created attachment 182811 [details] [review]
warnings fix.

We just don't create any sheet object, that's why we get the warning. The location is wrong since we do not set state->pos while loading drawings, so it is the last cell instead.

This patch does not fix all is has some weirdness, anyway error messages are gone.
Still need to really load the image and the various objects styles.
Comment 14 Jean Bréfort 2011-03-09 21:30:49 UTC
Created attachment 183024 [details] [review]
enhanced patch

With this patch, there are no more unexpected nodes (nothing is done for most) and it adds basic sheet image import.

There are many things that we don't support. Sheet objects need a lot of improvements (the canvas already supports most, if not all, needed  things).
Comment 15 Jean Bréfort 2011-03-12 10:11:41 UTC
Comment on attachment 183024 [details] [review]
enhanced patch

Commited an enhanced patch
Comment 16 Andreas J. Guelzow 2011-03-17 13:24:09 UTC
*** Bug 644983 has been marked as a duplicate of this bug. ***
Comment 17 Morten Welinder 2011-03-18 23:46:16 UTC
Comment on attachment 182521 [details] [review]
Whole patch, still ugly

committed.

it'll have to be de-uglified later.
Comment 18 Jean Bréfort 2011-03-23 19:32:09 UTC
Created attachment 184166 [details] [review]
Import combo boxes from xlsx.

There is a big issue with this patch that I don't understand: expressions and values leaks. What's wrong?
Comment 19 Andreas J. Guelzow 2011-03-23 20:48:30 UTC
Created attachment 184170 [details]
sample barchart file

file with 1 barchart and 1 image showing the barcharchart as rendered in Excel
Comment 20 Jean Bréfort 2011-03-27 12:57:42 UTC
Created attachment 184357 [details] [review]
make combo box import acceptable

The horizontal position for the controls is not perfect, but with this patch, we are almost at the best that can be done for this sample file without breaking the goffice API.
Comment 21 Jean Bréfort 2011-04-08 12:41:34 UTC
Comment on attachment 184357 [details] [review]
make combo box import acceptable

There is nothing more that can be done for now without breaking goffice API.
Enhancements needed for the future: data labels (I have a partial patch for that), and enhanced GogLabel (fixed width, alignment, wrapping,...).
Comment 22 Andreas J. Guelzow 2011-06-16 20:12:29 UTC
If I try to open ./samples/excel12/chart-tests-excel.xlsx the graphs don't like correct at all (each of them is a tiny plot inside a significantly larger graph object).
Comment 23 Jean Bréfort 2011-06-16 20:20:11 UTC
Hmm, I actually know that. It's a size issue. I hope I can find some time next week to fix that.
Comment 24 Andreas J. Guelzow 2011-08-22 18:03:48 UTC
Created attachment 194401 [details]
screen shot of the first file
Comment 25 Andreas J. Guelzow 2011-08-22 18:04:24 UTC
Created attachment 194402 [details]
screenshot of the barchart file
Comment 26 Jean Bréfort 2011-08-28 17:11:18 UTC
Import of data labels is now much better. There are size inconsistencies, but the file set the size for some labels, but not all.
Need to wrap the labels now.
Comment 27 Jean Bréfort 2011-12-27 14:47:54 UTC
This problem has been fixed in the development version. The fix will be available in the next major software release. Thank you for your bug report.

Not perfect, but not so bad. We don't export such charts to xlsx (or even xls) at the moment.