You can use this module with the following in your ~/.xmonad/xmonad.hs:
import XMonad.Actions.Commands
import qualified XMonad.StackSet as W
then add an appropriate mouse binding:
, ((modMask x .|. shiftMask, button3), mouseGesture gestures)
where gestures is a Map from gestures to actions on
windows, for example:
gestures = M.fromList
[ ([], focus)
, ([U], \w -> focus w >> windows W.swapUp)
, ([D], \w -> focus w >> windows W.swapDown)
, ([R, D], \_ -> sendMessage NextLayout)
]
This is just an example, of course; you can use any mouse button and
gesture definitions you want.
For detailed instructions on editing your mouse bindings, see
XMonad.Doc.Extending#Editing_mouse_bindings.
|