Please forgive my naivety, but I have a fairly large TeX document and I was hoping that there was an easy way to do the following. I can create code blocks in the text using the following:
\begin{lstlisting}
TEST
\end{lstlisting}
This will give all words within the lstlisting a different font to distinguish it as code from normal text.
I was hoping that there was a way in which I can search the whole document and add these tags to a word. For example every time the word "TEST" appears, it is encased in:
\begin{lstlisting}
TEST
\end{lstlisting}


\lstinline{TEST}for single words in text flow. – moewe Aug 15 '15 at 11:22lstlistingfor this, though.lstinlinemakes more sense, but beware! You may not like an automatic solution for stuff like this. It would be better and more maintainable to do a search/replace (perhaps with sed or the windows equivalent). – Sean Allred Aug 15 '15 at 17:15