XDG, xdg-open, and view vs. edit

Patryk Zawadzki patrys at pld-linux.org
Mon Mar 30 10:25:02 PDT 2009

On Mon, Mar 30, 2009 at 4:34 PM, Pat Suwalski <pat at suwalski.net> wrote:
> Daniel Bo wrote:
>> That said, I wonder why the choice was to set a default application
>> for opening when most file types have view and edit modes. Why are
>> there not xdg-view and xdg-edit (or --edit and --view switches on
>> xdg-open)?
> My opinion is that it's because most programs don't differentiate
> between editing and viewing. You start the program with a file parameter
> and then you can do anything. In that respect, you're "Open"ing the file
> just like from the File->Open menu.

While this is true you might need two separate applications for
editing and viewing files. Also at times you might want to
programmatically determine if there is a viewer/editor available (for
example it does not make sense for an "edit" button to open a PDF file
in Evince).

Patryk Zawadzki

More information about the xdg mailing list