# Nicely typesetting verbatim text

I want an environment in which LaTeX typesets the text just like it otherwise would, but without accepting any commands whatsoever while within this environment. None of the answers to this question solves the problem. Neither does fancyvrb, nor the verbatim packages.

I need this functionality, as I'm composing a LaTeX document from several plain text sources, with text written by authors with no idea of TeX or LaTeX. So the environment should treat everything as normal text. It should break lines, hyphenate words and just do what LaTeX does to normal text.

Do anyone have an idea on how to solve this problem?

EDIT:

An example would be someone writing this, in the plain text input field:

That will result in the following PDF output:

this is a test $#@\\&!@~ this is a test$#@\\&!@~ this is a test \$#@\\&!@~

and now I have another test.} Regular \LaTeX{} continued in same par.

\verbpars{I have succeeded in making it work with an unquoted
percent sign % but it will still break with unmatched braces{}.

But otherwise it may get you what you need.}

% This should not be seen
\end{document}
`

• probably safest to just make % catcode 12 locally as in my answer, otherwise comments in included files will be tricky:-) – David Carlisle Jul 10 '15 at 16:44
• @DavidCarlisle Fixed – Steven B. Segletes Jul 10 '15 at 16:46