On Mon, Dec 18, 2006 at 11:46 AM, David Reveman wrote: >> Since we know the strut ends within the box, that secondary check is >> meant to handle the two basic cases of a smaller box (such as for an >> output workarea) to allow a strut which starts outside it, and for a larger >> box (such as for the screen workarea) to ignore any internal struts which >> cross over multiple outputs. > > Sorry, I still don't get it. What struts are a vertical kicker panel > setting? > > +----------------- +----------------- + > | _|_ | > | | | | | > | | | | | > | |_|_| | > | | | > +----------------- +----------------- + > > If the screen looks like this and the thing in the middle is a panel > covering both outputs I assume that the struts are set to either > > leftX1 = screenW / 2 - panelW / 2; > leftX2 = screenW / 2 + panelW / 2; > > or > > rightX1 = screenW / 2 - panelW / 2; > rightX2 = screenW / 2 + panelW / 2; > > or that both those set are set. > > "if (y1 < pBox- >y2 && y2 > pBox- >y1 && x2 < pBox- >x2)" > > should set the left edge properly for both outputs in all those cases. > > What am I missing?
As I understand the spec, and verified in testing, the design is for the _NET_WM_STRUT_PARTIAL hint (and the fallback _NET_WM_STRUT) to define each strut as only a distance from the screen edge, and the start/end (added in _PARTIAL) specifies how much of that edge it takes (instead of defaulting to the entire screen height or width). The starting edge is always an edge of the screen. So, for your example above, I don't think struts get set for a floating window, but you could have two with one being on the right edge of the left screen, and the other being on the left edge of the right screen. In that case the strut edges for the right edge panel are computed in Compiz to be something like: leftX1 = 0; leftX2 = screenW / 2 + panelW; +------ ---- +---------- + |__________|_ | | | | | |__________|_| | | | | +-------- -- +- --------- + And for the left panel it would be: rightX1 = screenW / 2 - panelW; rightX2 = screenW; +--- ------- +- --------- + | _|__________| | | | | | |_|__________| | | | +--- ------- +--- ------- + Here's a reference to the spec, so someone can check my understanding: http://standards.freedesktop.org/wm-spec/1.3/ar01s05.html#id2523368 ...MC _______________________________________________ compiz mailing list compiz@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/compiz