Makesnippetqueryrelevant: display snippet showing the area surrounding the searched word / phrase text

Added the cosine similarity as an addition factor with weight.

To get the query term in the snippet. Attached is the image from local testing.

Most of the document seems to get the query word but few of them are still not able to get the query words, but snippet is picked from a location very close to the query word. needs a little more tunning of parameters for that i guess.

![2014-08-28-16 37 44-screenshot](https://cloud.githubusercontent.com/assets/1573133/4074644/e778e1a6-2ea3-11e4-94e6-9ed9f91c7fcc.png)

Space between `if` and `(` (also around `+` in the line above).