Current desktop detection / app access ...
George
jirka at 5z.com
Tue May 11 19:11:55 EEST 2004
On Tue, May 11, 2004 at 01:23:18PM +0100, Mark McLoughlin wrote:
> > Would you accept this in gnome-session ?
>
> I'm not 100% against the idea, but I haven't heard anything that
> convinces me its a good idea yet.
If there will be (there are and there always will be) difference in the way
KDE, GNOME and others handle certain things, do GUI, or whatnot, it will be
sometimes necessary to solve it in this way. I can think of quite a few
examples other then what to use for openning documents. One thing is GUI
look and feel which is bound to be somewhat different. Another thing is for
example tooltips or helpfiles which could reference the base desktop, and
thus if you run an app under KDE you want to know ONLY about how this app
interacts with KDE and not with GNOME and vice versa. The GUI should also
not reference or use any features which are not present in the desktop given.
I think the argument that it will force lazy programmers to just solve things
this way is moot since lazy programmers don't care that gui, or vfs, or panel
integration, or tooltips follow the current desktop. It actually seems to me
like a clean solution to have a detection of the desktop that's running and
act accordingly then to act in one particular way which may not be
appropriate for all desktops. You already now have apps that assume either
KDE or GNOME ONLY, and that's the same problem that you say is bad, except
the case statement is something like:
switch (desktop) {
default:
case GNOME:
do_gnome_thing ();
break;
}
Which is far worse IMO because you will be doing the GNOME thing when running
anywhere which is most definately wrong in many situations.
On the other hand if all desktops are supposed to look and behave exactly the
same, then why do we have different desktops? That is, I would propose the
env var to be removed when the KNOME or GDE desktop project gets started and
when no one will make anything with different semantics anymore. Until that
time I think knowing what desktop you are running under and using that
correctly is a reasonable and clean (imo) solution. Another thing is that
the user does not care if the solution is clean or a hack, they only care if
it works or not, and if something is cleanly broken, it's broken and if
something hackishly works, it works.
George
--
George <jirka at 5z.com>
You have the right to food money providing of course you don't mind a little
humiliation, investigation and if you cross your fingers rehabilitation.
-- The Clash
More information about the xdg
mailing list