you can use .selstart to set the cursor pos dunno bout the hard ruturn i'm still trying to figure out a way to quickly color text from keywords for my html editor

------------------
DiGiTaIErRoR