Here are two tricks to resizing a window to exact dimensions.

1. Safari

Open up a safari window and drop this in the URL field:

javascript:self.resizeTo(1024,800)

2. Applescript

Open up your Applescript editor and run this command:

tell application "Xcode"
activate
set the bounds of the first window to {140, 0, 1160, 775}
end tell

You need the application you want to resize open. I found this useful for setting screen sizes for video capture.

Links:

http://www.ithug.com/2007/09/applescript-moving-and-resizing-windows/