jed-users mailing list

[2008 Date Index] [2008 Thread Index] [Other years]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]

Re: some UTF8 problems, one fixed


Jörg Sommer <joerg@xxxxxxxxxxxx> wrote:
> It doesn't solve the problem.
>
> Insert the word vorübergehend in a buffer and insert the string vorüb and
> press ESC-/. I get vorübbergehend with two B.

I am unable to reproduce this.  What version of slang are you using?
What does `jed -batch -n` produce?  Also note that if vorübbergehend
appears in the buffer between vorübergehend and the word that you are
trying to expand (vorüb), then it will expand to vorübbergehend first.

> % JED_ROOT=$PWD ./src/objs/xjed -n -f 'define cat_buf() { push_spot(); bob(); push_mark(); eob(); fprintf(stderr, "---\n%s\n", bufsubstr()); pop_spot(); }' -f 'text_mode(); insert("vorübergehend"); cat_buf; insert("\nvor"); dabbrev; cat_buf; insert("\nvorüb"); dabbrev; cat_buf; exit_jed'

The problem with these experiments is that dabbrev was never written
to be used outside of an interactive context.  It assumes that it was
called directly via a keybinding.  The first time it is called it
builds a buffer context that it will use if the next keypress
generates an other call to dabbrev.  If the next keypress is not a
call to dabbrev, the context will get removed.  In your example, this
never happens and as such the second call to dabbrev results in the use of
the context from the first call.

Thanks,
--John

--------------------------
To unsubscribe send email to <jed-users-request@xxxxxxxxxxx> with
the word "unsubscribe" in the message body.
Need help? Email <jed-users-owner@xxxxxxxxxxx>.


[2008 date index] [2008 thread index]
[Thread Prev] [Thread Next]      [Date Prev] [Date Next]