added text editor code