Some improvements for xrandr

- choose best available refresh rate
 - if resolution doesn't exist, choose first available
 - other minor changes.

Works fine with Gnome, but I notices some issues on Openbox and Unity.