Finishing write random module. Fix some UI flaws in OSX.