[compiz] g-w-d.c -> my head spins

David Reveman davidr at novell.com
Sun Apr 9 10:26:06 PDT 2006


On Fri, 2006-04-07 at 19:29 +0200, Mirco Müller wrote:
> Am Freitag, den 07.04.2006, 14:37 +0200 schrieb David Reveman:
> 
> > What way?
> 
> 	Ups... hit the Send-button to fast. I forgot some questions. Does this
> field "gravity" in the point-structure mean "origin" of the local
> coordinate system, e.g. a:
> 
> 	{ -6, -5, GRAVITY_NORTH | GRAVITY_WEST },
> 
> means this points origin is in the upper-right corner and it is moved 6
> units/pixels to the left and 5 units/pixels to the top?

gravity flags are used to indicate relative to which window corner that
the texture coordinate should be mapped to. e.g GRAVITY_SOUTH |
GRAVITY_EAST, is the lower right corner of the window.

> 
> What's the meaning of the align field in the quad-structure?

Align field is only used when you set a max width or max height for a
quad and is used by the decorator plugin to determine the position of
the quad when max width or max height is reached.

> 
> 	Where are the contents of the _shadow_quads array actually used? I only
> see them being passed to decoration_to_property() where stuff is crammed
> in data, which then gets passed to XChangeProperty(). With this last
> call I'm totally put on a mental halt as I don't have any clues about
> Xlib or X11's inner workings. This might be an indicator that I'm not
> the right person for doing tweakable shadows. 

g-w-d puts all the quads that represent how a decoration texture is
mapped to a window in an X11 property on the client window. This
property is read by the decoration plugin. XChangeProperty is use for
updating this decoration property.

> 
> 	Sorry, for maybe asking stupid questions to obvious things... but I
> feel really lost atm.

That's OK, I understand that it's definitely not obvious how these
things work. Thanks for not giving up when it's hard to understand.

-David



More information about the compiz mailing list