Fixed issue with replacing UTF-8 characters

fixes #74
Added test case for invalid UTF8 character replacement

Only \r\n, \n\r, \r, \n and \f will be treat as line break characters.
Which reduced the problem caused by miss replace of a legal UTF-8 character when replacing with preg_replace('~\R~').

close #80
update readme, add CHANGLOG and CONTRIBUTING file

fixes #81