Spotlight / Finder - search words within files and preview occurrence
I develop a file search tool that is based upon Spotlight: HoudahSpot.

In addition to the Quick Look preview, HoudahSpot provides a text preview. This shows a plain text version of the selected search result. If you found the file by searching for text content, text preview will automatically highlight the words you searched for and scroll to the first occurrence. You can also search within text preview.

If you searched by text content, HoudahSpot will also pass the text you searched for down to the application used for opening the file. In many applications you can then press command-G (find next) to highlight the first occurence of that text.