Wip randr

Not sure I've done this right. If it's a problem, let me know and I can delete, refork, and add back my commits all based against wip branch.