<div dir="ltr"><div>Hi!<br></div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, Feb 18, 2021 at 9:46 AM Bastien Nocera <<a href="mailto:hadess@hadess.net">hadess@hadess.net</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex">On Thu, 2021-02-18 at 02:36 +0100, Jehan Pagès wrote:<br>
<snip><br>
> How do we know this? Who will know this if not even you who maintain<br>
> these files know this?<br>
<br>
What files do I maintain? I don't maintain shared-mime-info anymore, I<br>
maintain a single xdg spec, not the mime or desktop ones, and I don't<br>
maintain the implementation in Qt or GLib.<br></blockquote><div><br></div><div>Yes sorry, once again, I was not clear. I was referring to the fact you said you used to maintain a XDG spec, and apparently the GNOME defaults settings. Now even these facts, maybe I don't have them clear, but that illustrates my point that I am not convinced that a solution to the current problem will lie in a common configuration again (per desktop? Per distribution? Per distribution-desktop couple? Even this is not clear as showed a few emails saying contradictory things on what this or that distribution is now doing… or not?! A bit of a mess…), because it's just hard to know where to address fixes and as a consequence, most software developers just won't. So in the end, the list will stay maintained by a handful of people at most and will only contain a few dozen entries.</div><div><br></div><div>Now with the proposed changes, there are 2 cases:</div><div><br></div><div>1. Either you don't really have a concept of native format, you just open a variety of formats. Then you don't have to change anything. By having only a MimeType field, this is what you say to the world: "yeah I can open all these files indistinctively"</div><div>**So for instance image viewer won't have to change their desktop files.**</div><div>They just have many files that they can display. Maybe some even can display XCF, then they will add it to their list.</div><div>**Text editors as well won't have to change their desktop files.**</div><div>They can just open any text-like formats and don't have a concept of native format.<br></div><div><br></div><div>2. Now you have a concept of native format because your software is a bit more specialized than just "display" or "use" random files. Then you can add a NativeMimeType field. For such specialized software, there are also usually other software (or standard formats) doing a similar thing and with their own native formats and maybe your program is able to import it. It's not your native format, support may be more lacking at times. You add these in an IntentMimeType field, telling the world that you are able to handle these files which are made by software of similar intent to yours. So if you don't have the right software supporting this mime type as a native format, all the software with this MIME type as IntentMimeType would have precedence.</div><div><br></div><div>So for some example:</div><div><br></div><div>* GIMP would set XCF (and variants) as its NativeMimeType and PSD, ORA, PSP (and other similar formats for raster editing) as IntentMimeType. Thus saying that "XCF" is what they do best (and a XCF file was likely even created by GIMP or by another software to be exchanged with someone on GIMP), so GIMP is a very suitable default. The intent formats are not GIMP's ones, but if you have no application out there with a suitable NativeMimeType, then GIMP can be considered a fallback.</div><div>On the other hand, if you try to open a JPEG or PNG, software with these in a generic MimeType (without NativeMimeType nor IntentMimeType) would get precedence.<br></div><div>* LibreOffice Writer, OpenOffice or Calligra would set ODT as its NativeMimeType and DOC or OOXML as IntentMimeType. TXT or the like would not get redirected to LibreOffice anymore because you recently installed it or whatever.</div><div>* Abiword on the other hand would set ABW as its NativeMimeType and ODT, DOC or OOXML as IntentMimeType.</div><div>* Blender would have BLEND files as NativeMimeType and could add various formats such as 3DS files on IntentMimeType (if it is able to "open" it from command line as it would a .blend file, I am not sure, I never tried).</div><div><br></div><div>And so on.<br></div><div><br></div><div>Note that if a user set a custom default (explicitly), none of these matters.</div><div><br></div><div>Why I think it's a good proposal:</div><div>1. Many software won't have to change their desktop file. If you are not in an usage area with a concept of specialized formats or the like, you are probably already good.</div><div>2. The software which should update their desktop file, it's not a huge problem if they don't immediately. It will be neither worse nor better than now. And when they update, it's just 2 fields to add.<br></div><div>3. It is just 2 added fields which can be ignored if used on a desktop/distribution which has not updated its scripts for processing desktop files. No breakage either. Then when they update their order algorithm, it's not a huge code change, it's quite a simple one.<br></div><div><br></div><div>In other words, the transition will be smooth.<br></div></div><div><br></div><div>Note also that I am not against any other solution, since I read some were not sure my proposal was the best even though a problem is acknowledged. Maybe it's not, though I haven't thought of any better yet and was not convinced by other ideas so far. But I am happy if anyone comes with some better idea which would supersede mine. Until then, I stick with argumenting my original idea. 🙂<br></div><div><br></div><div>Jehan</div><div><br></div>-- <br><div dir="ltr" class="gmail_signature">ZeMarmot open animation film<br><a href="http://film.zemarmot.net" target="_blank">http://film.zemarmot.net</a><br>Liberapay: <a href="https://liberapay.com/ZeMarmot/" target="_blank">https://liberapay.com/ZeMarmot/</a><br>Patreon: <a href="https://patreon.com/zemarmot" target="_blank">https://patreon.com/zemarmot</a><br>Tipeee: <a href="https://www.tipeee.com/zemarmot" target="_blank">https://www.tipeee.com/zemarmot</a></div></div>