On 6 January 2015 at 16:58, Rex Dieter <[email protected]> wrote: > > > categories of programs > > ^^ that. :)
To expand a bit: such categories do not really exist for mimetypes (someone correct me if I'm wrong). You may be able to make use of: - The media types, the part of the mimetype before the slash, e.g. 'image', 'audio', 'text'. However, a lot of disparate kinds of file will end up under the 'application' media type, and it may not be what you want - e.g. 'image' does not distinguish between photos and icons. - Building a mapping of mime types to programs used to open them, and then saying that e.g. anything that can be opened by an office application is an office document. Your example shows one possible issue with this: I wouldn't expect a database file to be treated as an office document. In fact, the whole concept of 'office documents' seems like a bizarre categorisation that only came about because a set of proprietary applications was sold as a bundle. - Hardcoded lists and heuristics - e.g. image/jpeg > 100 KB is probably a photo. Be wary of making this too complex, because for backups you want it to be clear to the user what is included in each category. Thomas
_______________________________________________ xdg mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/xdg
