unify line breaks again
reviewed previous changes, fixed a bunch of typos. updated API