chiark / gitweb /
In ViewInvocation, don't highlight the search results
authorRoss Younger <ross@impropriety.org.uk>
Fri, 1 Mar 2013 02:48:00 +0000 (15:48 +1300)
committerRoss Younger <ross@impropriety.org.uk>
Fri, 1 Mar 2013 02:48:00 +0000 (15:48 +1300)
find_definition.py

index 9e215e2..39bb84c 100755 (executable)
@@ -19,8 +19,11 @@ class ViewInvocation(AbstractInvocation):
       self.CMD='view'
       self.waitFor=True
    def invoke(self, filename, expattern):
-      args = [self.CMD, filename, '-c', expattern, '-c', 'redraw']
+      args = [self.CMD, filename, '-c', expattern,
+            '-c', 'redraw',
+            '-c', 'set nohlsearch']
       # -c redraw => avoids that pesky "Press Enter to continue"
+      # -c set nohlsearch => don't highlight the line, just put the cursor there
       proc = subprocess.Popen(args, executable=self.CMD)
       # let it inherit from parent
       if self.waitFor: