file selector abstraction (GUI) (libfileselector.so)
Carsten Haitzler (The Rasterman)
raster at rasterman.com
Tue Dec 16 16:09:13 PST 2008
On Tue, 16 Dec 2008 19:12:10 +0000 (GMT) Mark Seaborn <mrs at mythic-beasts.com>
> Carsten Haitzler (The Rasterman) <raster at rasterman.com> wrote:
> > absolutely. also a separate process means that apps cant modify the
> > file selector like add other custom widgets (eg like gimp does with
> > image previews) or other things packed into the selector created
> > using their toolkit. you're on an uphill battle here :)
> Using a separate process doesn't make it impossible, just harder. You
> can use inter-X-client widget embedding.
embedded only works if your widgets use windows. also it leads to a pretty
awful look and feel as you embed foreign widgets into another widget set.
> When using a powerbox (a trusted-path file chooser), there's a
> question of whether it's possible to do image previews securely. The
> application is not supposed to be granted access to the file until the
> user clicks Open/OK. I believe it is possible to do this securely if
> the application-provided previewer is run in a confined process ,
> so that the previewer process does not have access to any channels
> that would allow it to leak the information back to the application or
> anyone else.
> I would also argue that preview widgets should not be application
> specific. A previewer should be registered to work across all
> applications. For example, you should get previews when choosing a
> file to attach to an e-mail, but the e-mail application should not
> have to implement the previewers.
and what if "preview" isnt to show - but play a sound (browsing wav files) or
its a document format SPECIFIC to that app (eg look at xara-lx - or gimp's
xfc's) and thus that app would implement this as it already has the code to.
sure - you can jump hoops and so all sorts of stuff with enough code - but till
people want it? my bet is "likely not". putting previews in or changing the way
the file selector works by adding more widgets (or hiding existing ones) etc.
etc. - i know some apps have put file selectors in their window inside a tab
for example - its not a separate dialog window... :)
------------- Codito, ergo sum - "I code, therefore I am" --------------
The Rasterman (Carsten Haitzler) raster at rasterman.com
More information about the xdg