[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    Re: mimetype specific information
From:       Rolf Magnus <ramagnus () zvw ! de>
Date:       2001-10-25 21:52:36
[Download RAW message or body]

On Thursday 25 October 2001 21:12, aleXXX wrote:

> What we would need here is a way first to detect the mimetype of a file,
> and then look whether we have a "meta info extractor" for this mimetype and
> if we have, start this thingy on the file 

Until here, it's what I wanted.

> and it could produce e.g. a xml
> file containing the meta info. This could be a new mimetype, and we could
> have a new service for this mimetype, which displays the xml nicely.

I was more thinking about something very small. So If I have a directory of 50 
mp3s, I could make a list specific to the mime type that is based on the meta 
info instead of file stat. Those plugins should be very fast to not slow down 
the listing noticably.
I also thought of two modes: one fast mode that gets all info that doesn't 
need much time, and a fast!=true, that returns more info but might take more 
time. For example an mp3 with variable bitrate would return "variable" as 
bitrate in fast mode and calculate the average bitrate if fast!=true. OTOH, 
this may need to be asynchronous.

> UI: property menu in konqy, something like "show meta info", then look for
> a filter (?) mimetype_of_the_file -> meta_info, if we have one do something
> like get("file:/blah/fasel.mp3#mp3info:") and display the result
> (meta_info) in the dialog.

Does it make sense to use an xml format for this? I mean, the dialog still has 
to be programmed to show the data. Then you would need two plugins, one for 
creating the XML and one for displaying it. I think for most things, 
key/value pairs should be enough, and for the other ones, a special dialog 
could always be programmed (There are rumours that there is a plugin system 
for this already ;)
I'm not sure if it would be better to only return strings or extend it to 
different types (ints, floats, pixmaps, whatever)

-- 
Never wondered why a carrot is more orange than an orange?

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic