In Ubuntu 11.04, you can click and drag a window to the left, right or top edge of the desktop to achieve the same result, but in Ubuntu 10.10 or 10.04, you need some tweaking as follows.
-
In addition to CompizConfig Settings Manager, install WmCtrl if not added.
- Go to Applications (or Main Menu) > Accessories > Terminal.
- Enter sudo apt-get install wmctrl
- Enter password when prompted.
- Go To System > Preferences > CompizConfig Settings Manager.
- Select "General" from the left panel and click "Commands".
-
In Command line 0, 1 and 2, paste the following codes:
- Command line 0, paste WIDTH=`xdpyinfo | grep 'dimensions:' | cut -f 2 -d ':' | cut -f 1 -d 'x'` && HALF=$(($WIDTH/2)) && wmctrl -r :ACTIVE: -b add,maximized_vert && wmctrl -r :ACTIVE: -e 0,0,0,$HALF,-1
- Command line 1, paste WIDTH=`xdpyinfo | grep 'dimensions:' | cut -f 2 -d ':' | cut -f 1 -d 'x'` && HALF=$(($WIDTH/2)) && wmctrl -r :ACTIVE: -b add,maximized_vert && wmctrl -r :ACTIVE: -e 0,$HALF,0,$HALF,-1
- Command line 2, paste wmctrl -r :ACTIVE: -b add,maximized_vert,maximized_horz
- In the same window, click "Edge Bindings" tab.
- Change Run Command 0, 1 and 2 from "None" to "Left", "Right" and "Top" respectively.
- Click "Back" button and select "General Options", change "Edge Trigger Delay" to about 500.