home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
OS/2 Shareware BBS: 5 Edit
/
05-Edit.zip
/
me34src.zip
/
me3
/
mutt
/
builtin
/
bs_untab.mut
< prev
next >
Wrap
Text File
|
1995-01-14
|
569b
|
25 lines
;; bs_untab.mut : backup 1 character even if that char is a tab
;; Notes:
;; Ignores arg-prefix ie only backups one character.
;; C Durland Public Domain
(defun
BS-untabify
{
(int ts)
(arg-flag FALSE 1) ;; reset arg count
(if (not (forward-char -1)) (done)) ;; at beginning of buffer
(if (looking-at "^I") ;; change tab to blanks
{
(ts (tab-stops))(tab-stops 8)
(tab) ;; tabs-worth-of-blanks dot tab
(tab-stops ts)
(forward-char -1)(delete-char 2) ;; delete a blank and the tab
}
(delete-char 1))
}
)