Changed output:iterate to return index,line,wrapped
Fixed cursor position not on screen when greater than length of string