1) When assigning a title automatically, include extension of the file name.

2) Some little code and comment clean up.
Virtual destructor added for base exception.