Re: gnome panel 2 background



Hey Iain,

On 8 Jan 2002, iain wrote:

>
> > The idea is to have a Pixmap of the current background, and send the xid
> > of the pixmap and the offsets in it to the applet when the background
> > changes.
> >
> > I have some extensive changes to PanelWidget planned which will change all
> > this and make it work more like normal Gtk+ widgets.
>
> Whats wrong with the current way of doing it? (G1.4)
> applet_widget_get_rgb_bg (APPLET_WIDGET (applet),
> 			  &rgb, &w, &h,
> 			  &rowstride);
>
> Then you create a pixbuf from the rgb data you receive.

	A couple of things

	1. The way I've done the new panel-applet library, the applet
	   can't invoke CORBA methods on the panel. I did this so that
	   applets can be used elsewhere outside of the panel ...

	   try:

	   libbonoboui/test/test-events 'OAFIID:GNOME_PagerApplet'

	2. This way should be a *lot* faster ... Instead of getting
	   the rgb from a pixmap, sending it to the applet via a CORBA
	   call, creating a pixbuf from the rgb and then rendering it
	   - we send the XID of the pixmap, and offsets into that
	   pixmap to the applet and then do an XCopyArea of the
	   applets portion of the pixmap into another pixmap.

	I'm just about to check the applet-side of all this into
libpanel-applet. If anyone who understands gdk/X well has the time to
have a look over it, I'd really appreciate it :-)

Cheers,
Mark.




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