[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Bug] Issues with format.el: coding system, byte/char confusi on
From: |
Richard Stallman |
Subject: |
Re: [Bug] Issues with format.el: coding system, byte/char confusi on |
Date: |
Mon, 14 Apr 2003 22:06:15 -0400 |
> 3. The docstring of `after-insert-file-functions' includes "It
should
> return the new byte count", whereas `format-decode' returns the
> new char count.
> It looks like they are really both measured in characters.
> I will fix some doc strings.
In this case, you might also want to check (`position-bytes', but this might
be OK):
(defun after-insert-file-set-buffer-file-coding-system (inserted)
...
(let ((pos-byte (position-bytes (+ (point) inserted))))
(set-buffer-multibyte nil)
(setq inserted (- pos-byte (position-bytes (point))))))
(set-buffer-modified-p modified-p))))
inserted)
If fixed this code, I think. Does the version now installed seem
correct to you?