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 155696 - add support for XLS import with image generated by Perl/PHP libraries.
add support for XLS import with image generated by Perl/PHP libraries.
Status: RESOLVED FIXED
Product: Gnumeric
Classification: Applications
Component: import/export MS Excel (tm)
git master
Other All
: Normal enhancement
: ---
Assigned To: Jody Goldberg
Jody Goldberg
Depends on:
Blocks:
 
 
Reported: 2004-10-18 07:51 UTC by Alan Knowles
Modified: 2006-10-10 15:21 UTC
See Also:
GNOME target: ---
GNOME version: ---


Attachments
Patch to realize IMDATA images (6.05 KB, patch)
2005-07-06 07:47 UTC, Jon Kåre Hellan
none Details | Review
Patch updated to match current CVS (6.05 KB, patch)
2005-12-19 16:25 UTC, Jon Kåre Hellan
none Details | Review
Patch updated to match current CVS - one more try (5.15 KB, patch)
2005-12-19 17:15 UTC, Jon Kåre Hellan
none Details | Review

Description Alan Knowles 2004-10-18 07:51:39 UTC
both Perl's Spreadsheet::excel, and the PHP version Spreadsheet_Excel_Writer
both appear to use rectangles, with fills to write images to excel.

Importing this into gnumeric just shows a blank rectangle.

(simple code to generate an xls file)
http://devel.akbkhome.com/flexyshipping5/tests/sheet.php
(source)
http://devel.akbkhome.com/svn/team.php/flexyshipping5/tests/sheet.php

The writing routine is in here: (look for 'function insertBitmap')
http://cvs.php.net/co.php/pear/Spreadsheet_Excel_Writer/Writer/Worksheet.php

It would be nice if this worked..
Comment 1 Jon Kåre Hellan 2004-10-18 09:15:58 UTC
The image is an IMDATA record in Windows native bitmap format. We don't support
this yet, but we have understood since August how it works. The format is OS/2
BMP, but the 14 byte header is missing.
Comment 2 Morten Welinder 2004-10-18 13:30:14 UTC
Presumably a matter of making gdk-pixbuf understand the format.
Comment 3 Jon Kåre Hellan 2004-10-18 13:45:42 UTC
I have code in my tree to add the header before passing it to gdk_pixbuf. At the
moment, it dumps the image file to my disk. It wasn't clear to me how to hook the 
image up to gnumeric
Comment 4 Jon Kåre Hellan 2004-10-18 19:11:57 UTC
Committed code so that excel_read_IMDATA returns a valid pixmap when it reads
headerless OS/2 bitmap.
Comment 5 Jon Kåre Hellan 2005-07-06 07:47:13 UTC
Created attachment 48706 [details] [review]
Patch to realize IMDATA images

This patch stores the IMDATA as an MSObject attribute, and realizes it. In
plain
language - makes the image show up on the screen.
Comment 6 Jody Goldberg 2005-10-15 01:20:14 UTC
Let's get this in once we branch.
The cruft in MSObj is looking more and more unfortunate.  We may want to move to
a straight gvalue approach with some hooks on the assignment side to store
things from property bags into gobjects.
Comment 7 Jon Kåre Hellan 2005-12-19 16:25:00 UTC
Created attachment 56168 [details] [review]
Patch updated to match current CVS   

No idea why bugzilla flags this bug as "changed today". Anyway, I tested the patch against current CVS and made it apply cleanly.
Comment 8 Jon Kåre Hellan 2005-12-19 17:15:53 UTC
Created attachment 56170 [details] [review]
Patch updated to match current CVS - one more try

Uploaded the old version by mistake - trying again
Comment 9 Jon Kåre Hellan 2006-10-10 15:21:53 UTC
Fixed in the development version. The fix will be available in the next major release. Thank you for your bug report.