On Thu, Aug 28, 2008 at 04:57:06PM +0200, Patrice Dumas wrote:
On Thu, Aug 28, 2008 at 09:46:15AM -0500, Rex Dieter wrote:
> Patrice Dumas wrote:
>> I am not sure that it covers what is wanted here. With xdg-open, it is
>> likely that on text an editor is opened, but it could also be a viewer.
>> For the diff I don't know. But for directory browsing, I am not sure
>> that it will work, on my system, it uses kdesvn because it registered
>> Maybe it is just that inode/directory should be reserved for directory
>> browsers, and text for editors and not viewers.
> Correct, use of any sort of "default" app, assumes that mimetypes for
> the opened targets are configured properly.
But for text, you cannot know if a viewer or an editor is the right one.
The most common mimetype seems to be text/plain and it cannot convey
this information. I think that in the mailcap format there was such a
distinction possible, but I am not sure that it exists for freedesktop
Regarding the inode/directory mimetype, it isn't obvious that kdesvn
isn't right. Point is that here there is an action that is wanted in
addition to a object type, and xdg-open can only do the somewhat fuzzy
action of 'opening'. Maybe we don't need more and consider that the action
really associated with opening is in fact set by the application we
choose to associate with the mimetype. Put more clearly if we want that
'opening' a text/plain file stands for 'editing' a text/plain file we
should just make sure that all the apps associated with text/plain are
editors and not viewers.
xdg-open seems to be geared towards reading/viewing instead of
editing. At least the documenation stated for example that
Opens the PNG image file /tmp/foobar.png in the user's default image
E.g. it would probably not open in gimp, but in some lightweight png
Maybe xdg-open needs two modes, read-only and editing?
Axel.Thimm at ATrpms.net