Take the 2-minute tour ×
Ask Ubuntu is a question and answer site for Ubuntu users and developers. It's 100% free, no registration required.

I just upgraded to ubuntu 11.04, and I am looking for a good way to tile windows. What I need is just to move window to the left or right half side of the screen, and bind the actions to some keyboard shortcuts. For instance move-window-to-display.sh contains

#!/bin/bash

if [ $1 -eq 2 ]
then
    POS="950 0"
    SIZE="967 1031"
else
    POS="0 0"
    SIZE="965 1031"
fi

xdotool windowmove `xdotool getwindowfocus` $POS
xdotool windowsize `xdotool getwindowfocus` $SIZE

exit 0

Then ". move-window-to-display.sh 1" moves the window to the left and ". move-window-to-display.sh 2" to the right. However, this code works but not perfectly, because of xdotool I guess, anyway it is not easy to put the windows at the exact position that we want.

So does anyone have a better way to do this? Either by Shell or by other tools... I tried tiling window manager like xmonad, but it seems too complicated to use...

Thank you very much

share|improve this question
add comment

1 Answer 1

up vote 1 down vote accepted

You can achieve this in Compiz, the default window manager.

First, launch CompizConfig Settings Manager install ccsm by pressing super+a or by clicking on the applications icon then typing 'compiz config' and selecting 'CompizConfig Settings Manager'. If it is not installed, the Software Centre will open so you can install it.

launch ccsm

Then, click on 'Grid' in the window management section.

ccsm

You can then configure the key bindings for putting the window to either side of the screen.

enter image description here

Click on the description of each key binding to change it.

enter image description here

share|improve this answer
    
That is awesome!!! –  SoftTimur Apr 29 '11 at 17:54
    
Thank you very much!!! –  SoftTimur Apr 29 '11 at 17:54
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.