Opened 12 years ago

Closed 12 years ago

#28 closed defect (fixed)

Mouse click should terminate incremental search

Reported by: alms Owned by: gb
Priority: major Milestone:
Component: IDE Version:
Keywords: Cc:


Clicking the mouse in a text window moves the point but does not terminate incremental search. Subsequent typing doesn't get inserted at the point (as one would expect), it gets appended to the search string and the search resumes. This usually ends with confusing messages about search strings not being found.

Change History (3)

comment:1 Changed 12 years ago by gb

  • Resolution set to fixed
  • Status changed from new to closed

Should be fixed as of changeset:7002.

comment:2 Changed 12 years ago by gb

  • Resolution fixed deleted
  • Status changed from closed to reopened


Type C-s, then click in the text view (with changeset:7013) in effect and without entering a search string; the forward isearch will just turn into a non-incremental search.

I think that if we want a mouse click to terminate isearch and reliably set the insertion point to the location clicked on, we need to treat it differently than other key events that "exit" or "abort" isearch. (Those other key events will also try to set the point, presumably at around the time that the text view's next method handles the mouse click.)

In general, the Hemlock command thread for a window shouldn't respond to mouse events by changing the selection, so the exit in response to a mouse click should follow some path which is careful to avoid changing the selection. (Neither the :exit nor :abort logical key action does this.)

comment:3 Changed 12 years ago by gb

  • Resolution set to fixed
  • Status changed from reopened to closed

See also ticket:44. I think that the current behavior is reasonable.

Note: See TracTickets for help on using tickets.