git/list[1] front-page[2] threads[3] people[4] search[5] about
 

Re: gitk: synchronize highlighting in file view for 'f'&'b' commands

From
EREric Raible <raible@nextest.com>
Date
May 2, 2008, 18:45 UTC
Message-ID
<481B6151.7040707@nextest.com>
In-Reply-To
<18459.3557.603906.871664@cargo.ozlabs.ibm.com>
Paul Mackerras wrote:
Show 18 quoted lines
> Eric Raible writes:
> 
>> Previously, 'b', backspace, and delete all did the same thing.
>> This changes 'b' to perform the inverse of 'f'.  And both of
>> them now highlight the filename of the currently diff.
> 
> OK, but...
> 
>> +    set file [regsub -- "-* (.*?) -*" [$ctext get $loc "$loc lineend"] "\\1"]
>> +    set cline [$cflist search -regexp [subst {^$file$}] 0.0]
> 
> This seems to be working out the index of the line we want to
> highlight in the file list, but both the callers of highlightfile can
> supply that info much more easily by incrementing a count as they go
> through $difffilestart, as far as I can tell.
> 
> Paul.
> 
That very well might be, but I:
1) wanted to make the smallest possible change
2) didn't peruse the code closely enough to see how to do that

I unfortunately don't have the time to pursue this just now. Any chance you could take the idea and fly with it?

Thanks - Eric
Previous: Paul Mackerras
Message 3 of 3 in “gitk: synchronize highlighting in file view for 'f'&'b' commands”
  1. Eric RaibleMar 17, 2008
  2. Paul MackerrasMay 2, 2008
  3. Eric RaibleMay 2, 2008

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.