Add a new feature trim trailing white space before diff and bug correction

Hi,

This time is used the st2 branch. Btw, I wonder why there is a huge difference between master and st2 branches.

* Prevent AttributeError in the console

In the listener, there were error messages when the window was not a file. I put a try/except


* Add trim trailing white space before diff feature

Sometimes, we have to deal with files which are in read only status. This feature enables to trim trailing white before making the diff. For that, a temp file is used.

Hope, it helps

Thanks