There are different conventions of representing the new line character in different types of OSes. Does the newline convention have nothing to do with what encoding is used?Is the newline convention not part of any(most) encoding method (e.g. ASCII, utf8, cp1253, ...)?
Is a newline convention not part of an encoding?
character encoding
While the said encodings specify the code for new line and carriage return, it is not part of the encoding whether or not you should use both, as is normal in a Windows environment, or just new line which is normal in a Unix environment.Also worthy of note is that on Unix, the newline is treated as a sort of end of line marker, and thus the last line in the file should also end with a newline. It is not common in Windows applications* to follow this practice, and thus normally text files created by a Windows application do not have an end-of-line marker after the last line.* unless that application is in fact an application written for a Unix environment, and ported to Windows, e.g. vim.