introduction

Thomas Kluyver thomas at kluyver.me.uk
Thu Mar 17 14:23:59 UTC 2016


On Thu, Mar 17, 2016, at 01:29 PM, kendell clark wrote:
> Thanks for your help. How would I go about getting a unique string of
> data, integer, text string, whatever to add to the mime type to make it
> unique? Most of the mime types I want to add are binary so can't be
> opened in a traditional text editor, and I know little about hex
> editors.

A hex editor is a good place to start. Usually, the main view is the hex
representation of the binary data (hex is handy because two hex digits
can represent any byte). Then surrounding that, you have views showing
what each part of the data could mean if interpreted as a string or as
different formats of numbers.

However, it's hard to identify a consistent and unique piece of data
just by looking at these, so ideally you should look for some
documentation describing the file format. There was a bug years ago
where printing from OpenOffice failed on a Tuesday, which turned out to
be because an insufficiently unique magic number was causing a file type
to be misidentified:
https://bugs.launchpad.net/ubuntu/+source/cupsys/+bug/255161

> I'd like to also improve xcontent/* mime types so that they're
> more accurate, as far as I can tell by looking in mime-editor they have
> directory structure matches set with a priority of 50, but nothing there
> to match.

I don't know about that; hopefully someone else will be able to help you
with it.

Thomas


More information about the xdg mailing list