fixes highlight display issue.
fixes a number of bugs, almost everything works perfectly now.