Fixed resize issues and implemented autocomplete

but so far autocomplete only works for the first word i think :(