add definition to solve copy&paste problem for listings in generated pdf and underscore escaping problem

It may be useful to solve the following problems
・copy&paste problem for listings in generated pdf
・escaping underscore escaping problem