shared-mime-database : entry change

Stephane LOEUILLET news at leroutier.net
Sun Dec 7 22:48:56 EET 2003


hi,

actually, the entry for djvu files is :

  <mime-type type="image/x-djvu">
    <magic priority="50">
      <match type="string" value="FORM" offset="4">
        <match type="string" value="DJVU" offset="12"/>
        <match type="string" value="DJVM" offset="12"/>
        <match type="string" value="BM44" offset="12"/>
        <match type="string" value="PM44" offset="12"/>
      </match>
    </magic>
  </mime-type>

it contains 1 error and 3 missing elements :

current mime-type is not the official one
2 glob for file extensions : .djv & .djvu
1 alias for the bad mime-type

so, it should be something like this :

  <mime-type type="image/vnd.djvu">
    <magic priority="50">
      <match type="string" value="FORM" offset="4">
        <match type="string" value="DJVU" offset="12"/>
        <match type="string" value="DJVM" offset="12"/>
        <match type="string" value="BM44" offset="12"/>
        <match type="string" value="PM44" offset="12"/>
      </match>
    </magic>
    <glob pattern="*.djvu"/>
    <glob pattern="*.djv"/>
    <alias type="image/x-djvu"/>
    <comment>DjVu Libre image</comment>
    <comment xml:lang="fr">Image DjVu Libre</comment>
  </mime-type>

for the good mime-type, i directly asked one of the people involded in the
djvu format codec/code. so, it is a sure thing.

to quote him :

> Furthermore, the official mime type for DjVu is image/vnd.djvu.But some
> viewers are unaware of this and require image/x-djvu.Whichever you use
> is more a policy decision than a technical choice.

any comment is welcomed.

++





More information about the xdg mailing list