Path: csiph.com!x330-a1.tempe.blueboxinc.net!usenet.pasdenom.info!aioe.org!eternal-september.org!feeder.eternal-september.org!.POSTED!not-for-mail From: Tim Watts Newsgroups: comp.os.linux.misc Subject: Re: linux: desktop notification library? Followup-To: comp.os.linux.misc Date: Wed, 18 May 2011 20:28:08 +0100 Organization: A noiseless patient Spider Lines: 55 Message-ID: <97jda8-9cb.ln1@squidward.dionic.net> References: <4dd3bba1$0$31206$a729d347@news.telepac.pt> <8ubda8-mch.ln1@squidward.dionic.net> <4dd40e34$0$31200$a729d347@news.telepac.pt> Mime-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 7Bit Injection-Info: mx04.eternal-september.org; posting-host="6oIlEBqCjOm0MjsSUEk5CA"; logging-data="16747"; mail-complaints-to="abuse@eternal-september.org"; posting-account="U2FsdGVkX1+TbUphMSa1Of9NGMgTIznypQeYk2BEIts=" User-Agent: KNode/4.4.10 Cancel-Lock: sha1:OCpTAw8Qbs8MxbFEyVTYR6L34qo= Xref: x330-a1.tempe.blueboxinc.net comp.os.linux.misc:1165 Rui Maciel wrote: > Tim Watts wrote: > >> libnotify itself is fairly lightwieght: >> >> dpkg -s libnotify1 >> >> Depends: libc6 (>= 2.7), libdbus-glib-1-2 (>= 0.78), libglib2.0-0 (>= >> 2.16.0), libgtk2.0-0 (>= 2.18.0) >> >> So I don't see a serious problem there. > > Being forced to include a hand full of libraries, including libgtk2.0, > isn't exactly being lightweight, even more when considering that a project > is forced to depend on those packages just to be able to trigger DE- > agnostic notification events. > > If you are developing a GTK project then that's acceptable. If you are > developing a project based on some other GUI library then those > requirements become a bit unacceptable. > I think you're being a bit unrealistic. GTK2 is fairly light and almost certainly present on any desktop system that is not an embedded type (no one mentioned embedded), just because some app almost certainly depends on it irrespective of the desktop/window manager. I needed a modal MOTD window app that appeared during login for all window managers and was lightning quick to start and held up th login process until the user clicked OK. I used QT as it was similarly as lightweight, didn't start helper processes all over the place and was easy to work with. I considered GTK2 but QT had some nice GUI tools to help build it (I hardly do GUI programming). If you want to get *really* light, it would be best to implement your own, with either shared memory and semaphors (update lock) or a simple network server that spews copies of the message stream to any clients that choose to connect (and this could be over unix domain sockets, not necessarily a full IP stack). I've had a lot of success with simple messages (SLIP framed) over domain sockets - and shared memory is also pretty easy to work with. Both would be pretty simple, the former probably the simplest and client language agnostic - and someone could even add a 2libnotify gateway daemon if they wanted to stream all the notifications to the same presentation applet. Cheers Tim -- Tim Watts