GNU bug report logs -
#6830
widget-complete bad completions in :type 'file
Previous Next
Full log
Message #88 received at 6830 <at> debbugs.gnu.org (full text, mbox):
>> so using either would be fine.
> ??? I don't understand this part. It maybe OK in this particular
> case, because all you care about is the range of buffer positions
> covered by the overlay.
That's normally the case. If an application actually cares about which
value of `field' shows up, it'll have to do more work.
>> Now, until here, there's still no bug because indeed it doesn't matter
>> which overlay we use to determine the field.
> See above. I'm not sure this is correct in general. And what if one
> of the overlays covers more buffer positions than the other? Wouldn't
> it sometimes confuse the completion code?
The normal priority rules say that a smaller overlay normally takes
priority, but yes, if there's a small field already defined within the
completion region, then the completion code can become confused.
I don't know how likely this is.
>> Does the patch below fix the problem?
> It does, but on Windows both `before_field' and `field' now have the
> value of the widget, not of `completion'.
> More generally, the overlay returned by get-char-property-and-overlay
> in this situation is still arbitrary after your change, and the Lisp
> application still has no control on which one will be returned.
It has the same control as before: the use of the `priority' property.
Stefan
This bug report was last modified 13 years and 75 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.