ratio to_f, fix window movement typo