[Xmonad] darcs patch: code to define a strut-avoiding layout.

Don Stewart dons at galois.com
Thu Nov 1 17:19:43 EDT 2007


mats:
> David Roundy <droundy at darcs.net> writes:
> 
> > I haven't pushed it, but it requires actual testing by someone for whom the
> > strut code doesn't crash xmonad (presumably 32-bit machines will be fine).
> > Review would be less helpful than testing.  I can't test it, for obvious
> > reasons (and am also less than motivated to perfect it, for the same
> > reasons).
> 
> I believe the bugs you are experiencing with ManageDocks may be due to
> the type of getWindowProperty32 from the X11 library. The documentation
> for XGetWindowProperty says:
> 
>   If the returned format is 8, the returned data is represented as a
>   char array.  If the returned format is 16, the returned data is
>   represented as a short array and should be cast to that type to obtain
>   the elements.  If the returned format is 32, the returned data is
>   represented as a long array and should be cast to that type to obtain
>   the elements.
> 
> That is, the data is returned as an array of long even when long is not
> 32 bits wide. My reading of the above is that the return type of
> getWindowProperty32 should be changed to 'IO (Maybe [CLong])' and
> analogous for getWindowProperty8 and getWindowProperty16 w.r.t. CChar
> and CShort. The situation is the same for XChangeProperty, I think.
> 
> I haven't tested this at all (neither on 32 nor 64-bit machines), but if
> you want, you can check if the attached patches solve the problem.
> 

That sounds like you might have identified the problem! We've had other 
issues with incorrect Word32 use in the bindings. 

Can someone confirm that this corrects the problem please?

-- Don


More information about the Xmonad mailing list