Added options, finished format_line(), etc