Word wrapping

TODO: Major code cleanup