emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Mule problem.


From: David Kastrup
Subject: Mule problem.
Date: 20 Aug 2004 22:05:09 +0200
User-agent: Gnus/5.09 (Gnus v5.9.0) Emacs/21.3.50

What is the most efficient possibility of encoding or decoding regions
in a buffer while keeping markers intact?

Or, somewhat differently put: assuming that I have a conceptional
marker at every character, what happens to those markers?  Effectively
I need to correlate error messages from a TeX compiler run with stuff
in the source buffer, and TeX has the bad habit of not looking at
characters but bytes in its source, and also of transcribing some
input characters into hexadecimal instead of keeping them.

So I basically have to take the buffer line, convert it into a
canonical form based on the byte sequence, take all the error
messages, convert them into canonical form, too, correlate the errors
in the messages with the canonical form, and then convert everything
back.

It would be most efficient if I could just place markers at the points
of all error, and then call undo repeatedly until I arrive back at the
original buffer line, then take a look at where the markers winded
up.  Unfortunately, this does not work.

If the conversion functions could be given a (sorted) array of string
positions, and would record where those positions moved to upon
conversion, this would help quite a bit.

Any idea of how to work this at the moment?

-- 
David Kastrup, Kriemhildstr. 15, 44793 Bochum




reply via email to

[Prev in Thread] Current Thread [Next in Thread]