Yes, starting with line numbers sounds like a good idea. So far, then,
the suggestion in its full glory is:
- link storage
- include punctuation in matching pattern
- expand matching pattern outwards until matching uniqueness is
assured across the whole file
- store line number
- link search
- start at stored line number
- expand outwards until an exact match is found (update stored
line number if match has moved?)
- if no exact match is found, scan the whole buffer for the best
soft match eg. minimum Levenshtein distance (update stored line number
and pattern if match has moved? Better ask the user.)
Scott
Nick Dokos (02/27/2008 08:20 AM) wrote:
Two suggestions:
o Use a line number, instead of a search pattern and don't worry
about subsequent edits to the file that the link points to.
o Use the find-tag strategy: go to the line number as an initial
approximation. If the pattern is found there, done; if not, search
around that point for the pattern and keep expanding the area of the
search until found. I don't know if they still do it that way but I
think that's how it was done some time ago.
Nick
|