Re: GtkApplication and argc/arv



On Thu, 2011-03-10 at 14:54 +0000, Chris Vine wrote:
> On Thu, 10 Mar 2011 14:48:12 +0100
> Murray Cumming <murrayc murrayc com> wrote:
> > On Thu, 2011-03-10 at 09:59 +0000, Chris Vine wrote:
> > [snip]
> > > The case for having single-instance programs in most cases for
> > > programs with a GUI interface seems self-evident to me, since most
> > > GUI programs keep some running global state which would be extremely
> > > tedious to synchronise between different processes.
> > [snip]
> > 
> > What global state, for instance?
> 
> Most programs will keep application-related data relevant to all
> instances running which is not configuration data suitable for dconf nor
> something for which you want to set up a formal database to deal with
> change notification and resolution.

If it's most programs then surely you can give some example. I don't
think that most applications have to deal with caching, bookmarks, and
history like Firefox.

I accept that _some_ would have some shared data, and they might choose 
to go single-process to make that easier. But it doesn't seem common enough 
to recommend it generally.

> Apart from that, quite frankly it is I think what most users expect
> for programs having only one main window.

Hopefully we don't expect users to have any idea of whether multiple
document windows are really in the same process. The Quit menu item
leaks this low-level concept so I thought we were generally trying to
avoid it.

Or do you mean some other sign that users would have that an application
is single-process, that they would miss if it was multiple-process?

>  The principal problem at the
> moment is gtk_window_present(): a user starts a program (she may have
> forgotten it is already running if it is minimised or on a different
> desktop) and gets presented with ... some odd blinking thing in the
> panel if she is attentive enough to spot it at all.
> 
> Chris

-- 
murrayc murrayc com
www.murrayc.com
www.openismus.com



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]