Error when importing/opening .ai files

Bug #51490 reported by KenSentMe
10
Affects Status Importance Assigned to Milestone
Inkscape
Unknown
Unknown
inkscape (Ubuntu)
Confirmed
Wishlist
Unassigned

Bug Description

I have Ubuntu Dapper, Inkscape and perlmagick installed. When i try to open or import a Adobe Illustrator file i get a bunch of errors that look like this:

Use of uninitialized value in concatenation (.) or string at /usr/share/inkscape/extensions/ill2svg.pl line 195, <> chunk 489.

At first there was also a Image::magick error, but that one was gone when i installed perlmagick

Revision history for this message
Phil Bull (philbull) wrote :

Thanks for the report.

Could you provide a small sample .ai file so I can test this, please?

Changed in inkscape:
status: Unconfirmed → Needs Info
Revision history for this message
Danny Staple (danny-orionrobots) wrote :

Suggested url for examples: http://www.mapresources.com/samplemaps.asp (found by googling).

Trying any of those on Inkscape 0.44-1ubuntu1 on Edgy I also saw many errors.

I also see a stream of errors, starting with "Couldn't load Perl module Image::Magick. Images will be skipped.", then after more perl moaning, "Error: Unexpected 'LB'! Everything has ended??
Error: Unexpected 'LB'! Everything has ended??
Error: Unexpected 'LB'! Everything has ended??
".

However, at this point clicking OK did lead me to a version of the file being loaded with no text.

If I then install PerlMagick and try the same, then I see only this:
"Inkscape has received additional data from the script executed. The script did not return an error, but this may indicate the results will not be as expected."
and
"Error: Unexpected 'LB'! Everything has ended??
Error: Unexpected 'LB'! Everything has ended??
Error: Unexpected 'LB'! Everything has ended??"

Clicking ok, I again see a version with none of the text present.

Revision history for this message
Bryce Harrington (bryce) wrote :

This is a known issue upstream, and remains unfixed.

There are actually two different AI file formats - one older one that is postscript based, and a newer one that is PDF based. Inkscape's ill2svg.pl script only supports the older postscript format.

The corresponding upstream feature request for this is here:

http://sourceforge.net/tracker/index.php?func=detail&aid=1613051&group_id=93438&atid=604309

Since the later AI format is PDF-based, this bug is dependent on having PDF Import functionality in Inkscape. The tracker item for this is here:

http://sourceforge.net/tracker/index.php?func=detail&aid=1197549&group_id=93438&atid=604309

Since I suspect the PDF-based AI files are more common than the PS-based ones at this point, it might be less frustrating for users to simply drop the 'Import *.ai' option in Ubuntu's Inkscape.

Revision history for this message
Danny Staple (danny-orionrobots) wrote :

If the PDF version was attributed to certain AI version number, could the import menu be changed to "Import *.ai (AI version <x.x)" until PDF Import functionality exists?

I agree that the PDF ones might be more common, but that does not make the functionality useless.

An additional suggestion is to have the importer do enough format checking to give a friendly error message "Sorry - this file format not supported"

Kees Cook (kees)
Changed in inkscape:
importance: Undecided → Wishlist
status: Needs Info → Confirmed
Revision history for this message
Caroline Ford (secretlondon) wrote :

This is actually really annoying - how are we to know that "import ai" only imports 50% of them? As far as I am concerned if it can't import ai files made by photoshop then it doesn't work..

This isn't a wishlist, it's not doing what it says it does..

Revision history for this message
Bryce Harrington (bryce) wrote :

I've implemented DannyStaple's suggestion to say "Import Adobe Illustrator 8.0 (*.ai)" so it is clearer that we're only supporting the older file format.

A full fix would also include a dialog popup saying, "We don't support this version of AI files" if a newer .ai is loaded. But that'll have to wait until a future release.

Revision history for this message
Bastiaan Wakkie (bwakkie) wrote :

Good news! Just checked the inkscape irc and this is what I found out:
The new svn from inkscape offers better import of pdf style ai's where libpoppler-0.5.9 or higher is included!

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.