Open search widget selected

Addresses  #319

If Document doesn't have a selection any existing search term
isn't replaced.
This commit makes the widget open with the term selected
so one can immediately overwrite it.

To be done: Behaviour when widget is already open.
Handle search term properly when widget is open

fixes #319

Now the behaviour is identical whether the search widget is open
or not:

a) No search term
-> word at cursor is search term (if selected or not)

b) Existing search term
-> 1) No selection in document
      Search term is kept but selected
   2) Selection in document
      Selection is new search term
Merge pull request #320 from uliska/search-selection

Improve search field behaviour