Inkscape Community

Help Using Inkscape => Beyond the Basics => Topic started by: brynn on May 07, 2018, 11:32:48 AM

Title: reportable "bug" export png filename?
Post by: brynn on May 07, 2018, 11:32:48 AM
Hi Friends,
This is something that's been new....I think it's new with 0.92.3, but not positive....might be 0.92.  When you start to export the first PNG from an SVG file, the filename which the dialog offers you is like this:

C:/.....dir/folder/name.svg.png

To me, it's just annoying.  I would not name a file like that.  But of course, I'm no expert.  Maybe there is some technical reason for it?

So I would like to report it as a bug, if it is a bug.  But if there is some reason for that, does anyone know what it is?  If there is a reason, then I won't report.  But it certainly is annoying.

After you change the name, then all the subsequent exports from that file are like whatever you changed it to.  And if the file has not been saved as SVG, it doesn't do that.  But for the first export from SVG file, you get filename.svg.png.

I have a sneaking suspicion this is a result of fixing some previous bug or feature request.  If so, then maybe the best solution would be to just leave that field blank, and let the user fill it in.  I don't know.  I just know name.svg.png seems strange.

Thanks for comments  :)
Title: Re: reportable "bug" export png filename?
Post by: Moini on May 07, 2018, 02:14:30 PM
I think it was intentional, but I don't like it, either.

It's supposed to fix an issue with Inkscape saving png images with the wrong or no file extension, which confuses Windows (and Windows users). Most Linux apps go by MIME type, you can name your file whatever you want - it's written in the file what kind of thing it is. More info here: https://www.howtogeek.com/192628/mime-types-explained-why-linux-and-mac-os-x-dont-need-file-extensions/ (the article is from 2014 - don't know if maybe newer Windows versions can do this now).
Title: Re: reportable "bug" export png filename?
Post by: brynn on May 07, 2018, 02:42:24 PM
Do you think it's worth bringing up at all?

I mean, I realize that most of the time I want to change the file name anyway, and it's easy enough to just delete the extra ".svg" part.  But before you know it, people will be actually saving files which are named like that, and my guess would be, either being confused, or not liking it.

Under this circumstance (Export PNG dialog) I don't think Windows would automatically add the extension.  Actually I''ll have to read that link, because I wonder how Linux would guess it?  But in a regular Save As dialog, if you choose the extension from the extension dropdown, you don't have to put it in the file name part.
Title: Re: reportable "bug" export png filename?
Post by: Moini on May 08, 2018, 06:47:04 AM
Exactly, that composing of the file name is an Inkscape functionality for the Export PNG dialog - and probably every user who cares a bit will remove the .svg part of the file name it auto-creates. I think it's a valid request, but there might be reasons why it's not possible to change it - but we will only know if we ask developers. Maybe they thought it would be nice to add the .svg...
Title: Re: reportable "bug" export png filename?
Post by: brynn on May 08, 2018, 09:19:55 PM
I'll give it a try.  We'll see what they say.
Title: Re: reportable "bug" export png filename?
Post by: brynn on May 08, 2018, 09:40:31 PM
https://bugs.launchpad.net/inkscape/+bug/1770070

(Geez!  What's with that "bug reporting guidelines" reminder???  It's a little bit "much" isn't it?)
Title: Re: reportable "bug" export png filename?
Post by: Moini on May 09, 2018, 04:35:39 PM
Yes, that's new. And awful... Are the warning triangles part of launchpad's layout or were they added by one of us?
Title: Re: reportable "bug" export png filename?
Post by: brynn on May 10, 2018, 02:33:47 PM
I have no idea.  I only have a regular LP account - no extra permissions.

Guessing the warning triangles come from Unicode, but don't know for sure.