Whitespace cleanup in lisp
authorSteve Youngs <steve@sxemacs.org>
Sat, 28 Jan 2012 04:16:00 +0000 (14:16 +1000)
committerSteve Youngs <steve@sxemacs.org>
Sat, 28 Jan 2012 04:16:00 +0000 (14:16 +1000)
Signed-off-by: Steve Youngs <steve@sxemacs.org>
165 files changed:
lisp/Makefile.am
lisp/abbrev.el
lisp/about.el
lisp/apropos.el
lisp/auto-save.el
lisp/auto-show.el
lisp/autoload.el
lisp/backquote.el
lisp/buff-menu.el
lisp/build-autoloads.el
lisp/build-rpt.el
lisp/byte-optimize.el
lisp/bytecomp-runtime.el
lisp/bytecomp.el
lisp/cl-compat.el
lisp/cl-extra.el
lisp/cl-macs.el
lisp/cl.el
lisp/cmdloop.el
lisp/code-cmds.el
lisp/code-files.el
lisp/code-process.el
lisp/compat.el
lisp/compile-core.el
lisp/console.el
lisp/cus-edit.el
lisp/cus-face.el
lisp/cus-start.el
lisp/custom.el
lisp/derived.el
lisp/device.el
lisp/dialog-items.el
lisp/dialog.el
lisp/disass.el
lisp/disp-table.el
lisp/dragdrop.el
lisp/dump-paths.el
lisp/dumped-lisp.el
lisp/easy-mmode.el
lisp/easymenu.el
lisp/emod-utils.el
lisp/etags.el
lisp/events.el
lisp/extents.el
lisp/faces.el
lisp/ffi.el
lisp/ffi/ffi-curl.el
lisp/ffi/ffi-dbus.el
lisp/ffi/ffi-gcrypt.el
lisp/ffi/ffi-libc.el
lisp/ffi/ffi-magic.el
lisp/ffi/ffi-sqlite.el
lisp/ffi/ffi-taglib.el
lisp/ffi/ffi-wand.el
lisp/files.el
lisp/fill.el
lisp/find-paths.el
lisp/finder.el
lisp/font-lock.el
lisp/font-menu.el
lisp/font.el
lisp/fontl-hooks.el
lisp/format.el
lisp/frame.el
lisp/glyphs.el
lisp/gnuserv.el
lisp/gui.el
lisp/gutter-items.el
lisp/gutter.el
lisp/help-macro.el
lisp/help.el
lisp/hyper-apropos.el
lisp/indent.el
lisp/info.el
lisp/isearch-mode.el
lisp/iso8859-1.el
lisp/issue-tracker.el
lisp/itimer-autosave.el
lisp/keydefs.el
lisp/keymap.el
lisp/lib-complete.el
lisp/lisp-initd.el
lisp/lisp-mnt.el
lisp/lisp-mode.el
lisp/lisp.el
lisp/list-mode.el
lisp/loaddefs.el
lisp/loadhist.el
lisp/loadup.el
lisp/make-docfile.el
lisp/map-ynp.el
lisp/menubar-items.el
lisp/menubar.el
lisp/minibuf.el
lisp/mode-motion.el
lisp/modeline.el
lisp/mouse.el
lisp/mule/ccl.el
lisp/mule/chinese.el
lisp/mule/cyrillic.el
lisp/mule/japanese.el
lisp/mule/kinsoku.el
lisp/mule/mule-category.el
lisp/mule/mule-charset.el
lisp/mule/mule-cmds.el
lisp/mule/mule-help.el
lisp/mule/mule-init.el
lisp/mule/mule-x-init.el
lisp/mule/thai-xtis.el
lisp/mule/vietnamese.el
lisp/multicast.el
lisp/number.el
lisp/obsolete.el
lisp/package-admin.el
lisp/package-get.el
lisp/package-ui.el
lisp/packages.el
lisp/page.el
lisp/paragraphs.el
lisp/picture.el
lisp/printer.el
lisp/process.el
lisp/rect.el
lisp/regexp-opt.el
lisp/register.el
lisp/replace.el
lisp/resize-minibuffer.el
lisp/select.el
lisp/setup-paths.el
lisp/shadow.el
lisp/simple.el
lisp/site-load.el
lisp/sound.el
lisp/specifier.el
lisp/startup.el
lisp/subr.el
lisp/symbols.el
lisp/syntax.el
lisp/term/apollo.el
lisp/term/internal.el
lisp/term/linux.el
lisp/term/sun-mouse.el
lisp/term/sup-mouse.el
lisp/term/tvi970.el
lisp/term/vt100.el
lisp/term/vt201.el
lisp/term/vt220.el
lisp/text-mode.el
lisp/toolbar-items.el
lisp/tty-init.el
lisp/update-elc-2.el
lisp/update-elc.el
lisp/userlock.el
lisp/version.el
lisp/wid-browse.el
lisp/wid-edit.el
lisp/window-xemacs.el
lisp/window.el
lisp/x-color.el
lisp/x-faces.el
lisp/x-font-menu.el
lisp/x-init.el
lisp/x-iso8859-1.el
lisp/x-mouse.el
lisp/x-scrollbar.el

index 95e46e1..66f7129 100644 (file)
@@ -15,7 +15,7 @@
 ## General Public License for more details.
 
 ## You should have received a copy of the GNU General Public License
-## along with this program.  If not, see <http://www.gnu.org/licenses/>. 
+## along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 ## Process this file with automake to produce Makefile.in
 
@@ -56,10 +56,10 @@ ETAGS = $(top_builddir)/lib-src/etags
 TAGS_DEPENDENCIES = $(ETAGS)
 ETAGS_ARGS =
 
-sxepkg_DATA = 
-xepkg_DATA = 
-mulepkg_DATA = 
-sitepkg_DATA = 
+sxepkg_DATA =
+xepkg_DATA =
+mulepkg_DATA =
+sitepkg_DATA =
 
 subdirs = ffi mule term
 
@@ -81,8 +81,8 @@ corelispels =                                                         \
        cus-edit.el cus-face.el cus-file.el cus-load.el cus-start.el    \
        custom.el derived.el device.el dialog-items.el dialog.el        \
        disass.el disp-table.el dragdrop.el easy-mmode.el easymenu.el   \
-       emod-utils.el etags.el events.el extents.el faces.el ffi.el     \
-       files-nomule.el files.el fill.el float-sup.el font-lock.el      \
+       emod-utils.el etags.el events.el extents.el faces.el ffi.el     \
+       files-nomule.el files.el fill.el float-sup.el font-lock.el      \
        font-menu.el font.el fontl-hooks.el format.el frame.el          \
        glyphs.el gnuserv.el gpm.el gui.el gutter-items.el gutter.el    \
        help-macro.el help-nomule.el help.el hyper-apropos.el indent.el \
@@ -114,7 +114,7 @@ mulelispels =                                                               \
        mule/cyrillic.el mule/english.el mule/ethiopic.el               \
        mule/european.el mule/greek.el mule/hebrew.el mule/japanese.el  \
        mule/kinsoku.el mule/korean.el mule/latin.el mule/misc-lang.el  \
-       mule/mule-category.el mule/ccl.el mule/mule-charset.el          \
+       mule/mule-category.el mule/ccl.el mule/mule-charset.el  \
        mule/mule-cmds.el mule/mule-coding.el mule/mule-help.el         \
        mule/mule-init.el mule/mule-misc.el mule/mule-tty-init.el       \
        mule/mule-x-init.el mule/thai-xtis-chars.el mule/thai-xtis.el   \
@@ -132,15 +132,15 @@ termlispels =                                                             \
 
 builtels =                                                              \
        auto-autoloads.el custom-load.el finder-inf.el                  \
-       custom-defines.el 
+       custom-defines.el
 
 ffibuiltels =                                                           \
-        ffi/auto-autoloads.el ffi/custom-load.el                        \
-        ffi/custom-defines.el
+       ffi/auto-autoloads.el ffi/custom-load.el                        \
+       ffi/custom-defines.el
 
 mulebuiltels =                                                          \
-        mule/auto-autoloads.el mule/custom-load.el                      \
-        mule/custom-defines.el
+       mule/auto-autoloads.el mule/custom-load.el                      \
+       mule/custom-defines.el
 
 
 if HAVE_FFI
@@ -150,7 +150,7 @@ if WITH_MULE
 builtels += $(mulebuiltels)
 endif
 
-nocompile_elfiles = 
+nocompile_elfiles =
 compile_elfiles = $(compile_bldchainels) $(corelispels) $(termlispels)
 if HAVE_FFI
 compile_elfiles += $(ffilispels)
index 211ba61..c6e1d8c 100644 (file)
@@ -18,7 +18,7 @@
 ;; General Public License for more details.
 
 ;; You should have received a copy of the GNU General Public License
-;; along with this program.  If not, see <http://www.gnu.org/licenses/>. 
+;; along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 
 ;;; Synched up with: FSF 19.34 (With some additions)
@@ -72,13 +72,13 @@ Define abbrevs in it according to DEFINITIONS, which is a list of elements
 of the form (ABBREVNAME EXPANSION HOOK USECOUNT)."
   (let ((table (and (boundp table-name) (symbol-value table-name))))
     (cond ((vectorp table))
-          ((not table)
-           (setq table (make-abbrev-table))
-           (set table-name table)
-           (setq abbrev-table-name-list (cons table-name abbrev-table-name-list)))
-          (t
-           (setq table (wrong-type-argument 'vectorp table))
-           (set table-name table)))
+         ((not table)
+          (setq table (make-abbrev-table))
+          (set table-name table)
+          (setq abbrev-table-name-list (cons table-name abbrev-table-name-list)))
+         (t
+          (setq table (wrong-type-argument 'vectorp table))
+          (set table-name table)))
     (while definitions
       (apply (function define-abbrev) table (car definitions))
       (setq definitions (cdr definitions)))))
@@ -91,8 +91,8 @@ To undefine an abbrev, define it with an expansion of `nil'."
   (check-type count (or null integer))
   (check-type table vector)
   (let* ((sym (intern name table))
-         (oexp (and (boundp sym) (symbol-value sym)))
-         (ohook (and (fboundp sym) (symbol-function sym))))
+        (oexp (and (boundp sym) (symbol-value sym)))
+        (ohook (and (fboundp sym) (symbol-function sym))))
     (unless (and (equal ohook hook)
                 (stringp oexp)
                 (stringp expansion)
@@ -112,21 +112,21 @@ To undefine an abbrev, define it with an expansion of `nil'."
   (while l
     (let ((fixup (car l)))
       (if (consp fixup)
-          (progn
-            (setq abbrev-table-name-list (delq fixup abbrev-table-name-list))
-            (define-abbrev-table (car fixup) (cdr fixup))))
+         (progn
+           (setq abbrev-table-name-list (delq fixup abbrev-table-name-list))
+           (define-abbrev-table (car fixup) (cdr fixup))))
       (setq l (cdr l))))
   ;; These are no longer initialized by C code
   (if (not global-abbrev-table)
       (progn
-        (setq global-abbrev-table (make-abbrev-table))
-        (setq abbrev-table-name-list (cons 'global-abbrev-table
-                                           abbrev-table-name-list))))
+       (setq global-abbrev-table (make-abbrev-table))
+       (setq abbrev-table-name-list (cons 'global-abbrev-table
+                                          abbrev-table-name-list))))
   (if (not fundamental-mode-abbrev-table)
       (progn
-        (setq fundamental-mode-abbrev-table (make-abbrev-table))
-        (setq abbrev-table-name-list (cons 'fundamental-mode-abbrev-table
-                                           abbrev-table-name-list))))
+       (setq fundamental-mode-abbrev-table (make-abbrev-table))
+       (setq abbrev-table-name-list (cons 'fundamental-mode-abbrev-table
+                                          abbrev-table-name-list))))
   (and (eq major-mode 'fundamental-mode)
        (not local-abbrev-table)
        (setq local-abbrev-table fundamental-mode-abbrev-table)))
@@ -136,13 +136,13 @@ To undefine an abbrev, define it with an expansion of `nil'."
   "Define ABBREV as a global abbreviation for EXPANSION."
   (interactive "sDefine global abbrev: \nsExpansion for %s: ")
   (define-abbrev global-abbrev-table
-                 (downcase name) expansion nil 0))
+                (downcase name) expansion nil 0))
 
 (defun define-mode-abbrev (name expansion)
   "Define ABBREV as a mode-specific abbreviation for EXPANSION."
   (interactive "sDefine mode abbrev: \nsExpansion for %s: ")
   (define-abbrev (or local-abbrev-table
-                     (error "Major mode has no abbrev table"))
+                    (error "Major mode has no abbrev table"))
                 (downcase name) expansion nil 0))
 
 (defun abbrev-symbol (abbrev &optional table)
@@ -153,16 +153,16 @@ The value is nil if that abbrev is not defined.
 Optional second arg TABLE is abbrev table to look it up in.
 The default is to try buffer's mode-specific abbrev table, then global table."
   (let ((frob (function (lambda (table)
-                (let ((sym (intern-soft abbrev table)))
-                  (if (and (boundp sym)
-                           (stringp (symbol-value sym)))
-                      sym
-                      nil))))))
+               (let ((sym (intern-soft abbrev table)))
+                 (if (and (boundp sym)
+                          (stringp (symbol-value sym)))
+                     sym
+                     nil))))))
     (if table
-        (funcall frob table)
-        (or (and local-abbrev-table
-                 (funcall frob local-abbrev-table))
-            (funcall frob global-abbrev-table)))))
+       (funcall frob table)
+       (or (and local-abbrev-table
+                (funcall frob local-abbrev-table))
+           (funcall frob global-abbrev-table)))))
 
 (defun abbrev-expansion (abbrev &optional table)
   "Return the string that ABBREV expands into in the current buffer.
@@ -170,8 +170,8 @@ Optionally specify an abbrev table as second arg;
 then ABBREV is looked up in that table only."
   (let ((sym (abbrev-symbol abbrev table)))
     (if sym
-        (symbol-value sym)
-        nil)))
+       (symbol-value sym)
+       nil)))
 
 (defun unexpand-abbrev ()
   "Undo the expansion of the last abbrev that expanded.
@@ -179,12 +179,12 @@ This differs from ordinary undo in that other editing done since then
 is not undone."
   (interactive)
   (if (or (< last-abbrev-location (point-min))
-          (> last-abbrev-location (point-max))
-          (not (stringp last-abbrev-text)))
+         (> last-abbrev-location (point-max))
+         (not (stringp last-abbrev-text)))
       nil
     (let* ((opoint (point))
-           (val (symbol-value last-abbrev))
-           (adjust (length val)))
+          (val (symbol-value last-abbrev))
+          (adjust (length val)))
       ;; This isn't correct if (symbol-function last-abbrev-text)
       ;;  was used to do the expansion
       (goto-char last-abbrev-location)
@@ -193,8 +193,8 @@ is not undone."
       (setq adjust (- adjust (length last-abbrev-text)))
       (setq last-abbrev-text nil)
       (if (< last-abbrev-location opoint)
-          (goto-char (- opoint adjust))
-          (goto-char opoint)))))
+         (goto-char (- opoint adjust))
+         (goto-char opoint)))))
 
 \f
 
@@ -206,53 +206,53 @@ human-readable description. Otherwise the description is an
 expression, a call to `define-abbrev-table', which would define the
 abbrev table NAME exactly as it is currently defined."
   (let ((table (symbol-value name))
-        (stream (current-buffer)))
+       (stream (current-buffer)))
     (message "Abbrev-table %s..." name)
     (if human-readable
-        (progn
-          (prin1 (list name) stream)
-          ;; Need two terpri's or cretinous edit-abbrevs blows out
-          (terpri stream)
-          (terpri stream)
-          (mapatoms (function (lambda (sym)
-                      (if (symbol-value sym)
-                          (let* ((n (prin1-to-string (symbol-name sym)))
-                                 (pos (length n)))
-                            (princ n stream)
-                            (while (< pos 14)
-                              (write-char ?\  stream)
-                              (setq pos (1+ pos)))
-                            (princ (format " %-5S " (symbol-plist sym))
-                                   stream)
-                            (if (not (symbol-function sym))
-                                (prin1 (symbol-value sym) stream)
-                              (progn
-                                (setq n (prin1-to-string (symbol-value sym))
-                                      pos (+ pos 6 (length n)))
-                                (princ n stream)
-                                (while (< pos 45)
-                                  (write-char ?\  stream)
-                                  (setq pos (1+ pos)))
-                                (prin1 (symbol-function sym) stream)))
-                            (terpri stream)))))
-                    table)
-          (terpri stream))
-        (progn
-          (princ "\(define-abbrev-table '" stream)
-          (prin1 name stream)
-          (princ " '\(\n" stream)
-          (mapatoms (function (lambda (sym)
-                      (if (symbol-value sym)
-                          (progn
-                            (princ "    " stream)
-                            (prin1 (list (symbol-name sym)
-                                         (symbol-value sym)
-                                         (symbol-function sym)
-                                         (symbol-plist sym))
-                                   stream)
-                            (terpri stream)))))
-                    table)
-          (princ "    \)\)\n" stream)))
+       (progn
+         (prin1 (list name) stream)
+         ;; Need two terpri's or cretinous edit-abbrevs blows out
+         (terpri stream)
+         (terpri stream)
+         (mapatoms (function (lambda (sym)
+                     (if (symbol-value sym)
+                         (let* ((n (prin1-to-string (symbol-name sym)))
+                                (pos (length n)))
+                           (princ n stream)
+                           (while (< pos 14)
+                             (write-char ?\  stream)
+                             (setq pos (1+ pos)))
+                           (princ (format " %-5S " (symbol-plist sym))
+                                  stream)
+                           (if (not (symbol-function sym))
+                               (prin1 (symbol-value sym) stream)
+                             (progn
+                               (setq n (prin1-to-string (symbol-value sym))
+                                     pos (+ pos 6 (length n)))
+                               (princ n stream)
+                               (while (< pos 45)
+                                 (write-char ?\  stream)
+                                 (setq pos (1+ pos)))
+                               (prin1 (symbol-function sym) stream)))
+                           (terpri stream)))))
+                   table)
+         (terpri stream))
+       (progn
+         (princ "\(define-abbrev-table '" stream)
+         (prin1 name stream)
+         (princ " '\(\n" stream)
+         (mapatoms (function (lambda (sym)
+                     (if (symbol-value sym)
+                         (progn
+                           (princ "    " stream)
+                           (prin1 (list (symbol-name sym)
+                                        (symbol-value sym)
+                                        (symbol-function sym)
+                                        (symbol-plist sym))
+                                  stream)
+                           (terpri stream)))))
+                   table)
+         (princ "    \)\)\n" stream)))
     (terpri stream))
   (message ""))
 ;;; End code not in FSF
index 9179f1c..a87d94f 100644 (file)
 (defvar about-other-current-hackers '(peanuthorst))
 
 (defvar about-once-and-future-hackers
-  '(adrian aj ajc alastair baw ben bw cgw chr craig cthomp daiki dan darrylo 
-          devin dkindred dmoore dv eb fabrice golubev gunnar heatxsink hbs hisashi 
-          hmuller hniksic hobley jan jareth jason jens jmiller jonathan juhp 
+  '(adrian aj ajc alastair baw ben bw cgw chr craig cthomp daiki dan darrylo
+          devin dkindred dmoore dv eb fabrice golubev gunnar heatxsink hbs hisashi
+          hmuller hniksic hobley jan jareth jason jens jmiller jonathan juhp
           jwz kazz kirill kyle larsi marcpa martin mcook mly morioka mta myrkraverk
           ograf olivier oscar pelegri pez piper pittman rendhalver rickc rose
           rossini slb sperber stig stigb thiessel tomonori tuck turnbull vin
         (normal-range (- msglen width))
         (long-border-interval 1.5)
         (long-default-interval 0.15)
-         submsg)
+        submsg)
     (if (< msglen width)
-        (display-message 'no-log (concat leader msg))
+       (display-message 'no-log (concat leader msg))
       (while t
-        (dotimes (i msglen)
-          (setq submsg (if (< i normal-range)
-                           (substring msg i (+ i width))
-                         ;; Rolling is needed.
-                         (concat (substring msg i)
-                                 (substring msg 0 (- (+ i width) msglen)))))
-          (display-message 'no-log (concat leader submsg))
-          (unless (sit-for (cond
-                            ((eq i 0) long-border-interval)
-                            (t long-default-interval)))
-            (return-from about-rolling-message)))
-          (garbage-collect)))))
+       (dotimes (i msglen)
+         (setq submsg (if (< i normal-range)
+                          (substring msg i (+ i width))
+                        ;; Rolling is needed.
+                        (concat (substring msg i)
+                                (substring msg 0 (- (+ i width) msglen)))))
+         (display-message 'no-log (concat leader submsg))
+         (unless (sit-for (cond
+                           ((eq i 0) long-border-interval)
+                           (t long-default-interval)))
+           (return-from about-rolling-message)))
+         (garbage-collect)))))
 
 ;; Main entry page.
 
@@ -678,8 +678,8 @@ England.  He'd quite like to have his own company one day, but has yet
 to think of that killer product...
 
 See also ")
-        (about-url-link 'alastair nil "Visit Alastair's home page")
-        (widget-insert ".\n"))
+       (about-url-link 'alastair nil "Visit Alastair's home page")
+       (widget-insert ".\n"))
     (baw
      (widget-insert "
 As of November 2000, I am a software engineer with the Pythonlabs at
@@ -702,39 +702,39 @@ to fend off the legions of groupies that seem to follow me everywhere.
     Milk Me Daddy
     (C) 1990 Warsaw
     ===============
-    Oh daddy with your fingers pink 
-    From whose udders do you drink? 
-    Thy milk offends with putrid stink 
-    I'll vomit now, lactose I think 
-
-    If I could dream, I'd be a cow 
-    Not horse, or mule, or barnyard sow 
-    The cud I'd chew would drip and how! 
-    So milk me daddy, milk me now! 
-
-    My bovine nature knows no bounds 
-    I'd naught awake at midnight sounds 
-    Of teens approaching o'er the grounds 
-    To tip with glee, then screech like clowns 
-
-    And so I stare into this glass 
-    Of sweaty juice, I gulp so fast 
-    Each drop I lick, down to the last 
-    The vertigo I know will pass 
-
-    My mother smiles and pats my head 
-    She's proud of me, so she has said 
-    My pop just now gets out of bed 
-    His eyes quite comatose and red 
-
-    He'll empathize my milky fate 
-    Whilest sopping gravy from his plate 
-    And as the hour is getting late 
-    His belly taut with all he ate 
-
-    He isn't often quite so chatty 
-    His arteries clogged with meat so fatty 
-    With burps that launch soup, thick and splatty 
+    Oh daddy with your fingers pink
+    From whose udders do you drink?
+    Thy milk offends with putrid stink
+    I'll vomit now, lactose I think
+
+    If I could dream, I'd be a cow
+    Not horse, or mule, or barnyard sow
+    The cud I'd chew would drip and how!
+    So milk me daddy, milk me now!
+
+    My bovine nature knows no bounds
+    I'd naught awake at midnight sounds
+    Of teens approaching o'er the grounds
+    To tip with glee, then screech like clowns
+
+    And so I stare into this glass
+    Of sweaty juice, I gulp so fast
+    Each drop I lick, down to the last
+    The vertigo I know will pass
+
+    My mother smiles and pats my head
+    She's proud of me, so she has said
+    My pop just now gets out of bed
+    His eyes quite comatose and red
+
+    He'll empathize my milky fate
+    Whilest sopping gravy from his plate
+    And as the hour is getting late
+    His belly taut with all he ate
+
+    He isn't often quite so chatty
+    His arteries clogged with meat so fatty
+    With burps that launch soup, thick and splatty
     Oh how I wish you'd milk me daddy\n\n\t")
      (about-url-link 'baw nil "Visit Barry's home page")
      (widget-insert "\n"))
@@ -952,8 +952,8 @@ believe now. Oh well, such is life.\n"))
 In real life most of the time my name is Sebastian Freundt.
 I'm a mathematician at the ")
      (about-url-link "http://www.math.tu-berlin.de"
-                     "Technical University of Berlin"
-                     "www.math.tu-berlin.de")
+                    "Technical University of Berlin"
+                    "www.math.tu-berlin.de")
      (widget-insert ".
 My main task there is to hack at the computer algebra system KANT/KASH,
 and incorporate the ideas of the SCIEnce project.
@@ -1196,8 +1196,8 @@ teaches networking basics, Internet technologies (you know, all these
 xxML and hairy script languages !)  and the Scheme language.\n"))
     (peanuthorst
      (widget-insert "
-Horst is a student still working towards his HSC. He has a Unit II 
-certification in Information Technology already, and is studying 
+Horst is a student still working towards his HSC. He has a Unit II
+certification in Information Technology already, and is studying
 Chemistry, German, and Physics.
 
 He started using XEmacs relatively recently, when he started with Linux
@@ -1214,7 +1214,7 @@ I did my PhD at UCB and a postdoc at CSL/PARC.  I joined Sun in 1990,
 spent some time in DevPro (that is when I made my contribution to
 XEmacs) and joined JavaSoft in fall '95, where I've been the lead for
 several JSP-related specifications and JAX-RPC.  I'm currently the Web
-Layer architect for J2EE. 
+Layer architect for J2EE.
 
 I was born in Barcelona and I grew up mostly in Caracas; I have two kids
 and I speak only catalan to them; I can juggle some (career, family, and
@@ -1328,11 +1328,11 @@ development and design of a CAD framework for analog integrated
 circuits with special emphasis on distributed software concepts. He
 has now joined HP as technical consultant.
 
-                      All of the buildings,
-                      all of the cars
-                      were once just a dream
-                      in somebody's head.\n
-                                     P. Gabriel\n"))
+                     All of the buildings,
+                     all of the cars
+                     were once just a dream
+                     in somebody's head.\n
+                                    P. Gabriel\n"))
     (tomonori
      (widget-insert
       "
@@ -1482,7 +1482,7 @@ using Epoch.\n"))
     (dkindred
      (widget-insert "
 Darrell tends to come out of the woodwork a couple of weeks
-before a new release with a flurry of fixes for bugs that 
+before a new release with a flurry of fixes for bugs that
 annoy him.  He hopes he's spared you from a core dump or two.\n"))
     (dmoore
      (widget-insert "
@@ -1527,7 +1527,7 @@ consider a bug.\n"))
     (gunnar
      (widget-insert
       "
-Sorry, no information about my XEmacs contributions yet.\n"))  
+Sorry, no information about my XEmacs contributions yet.\n"))
     (hbs
      (widget-insert "
 Part of the original (pre-19.0) Lucid Emacs development team.  Harlan
@@ -1536,7 +1536,7 @@ are original to the Lucid version of Emacs, including extents and hash
 tables.\n"))
     (heatxsink
      (widget-insert "
-Sorry, no information about my SXEmacs contributions yet.\n")) 
+Sorry, no information about my SXEmacs contributions yet.\n"))
     (hisashi
      (widget-insert
       "
index 6c6df04..b52d594 100644 (file)
@@ -56,7 +56,7 @@
 ;; Reading DOC file doesn't load nroff.
 ;; Added hypertext following of documentation, mouse-2 on variable gives value
 ;;   from buffer in active window.
-;; Added apropos-rewrite-regexp from FSF apropos. 
+;; Added apropos-rewrite-regexp from FSF apropos.
 ;;; Code:
 
 ;; I see a degradation of maybe 10-20% only.
@@ -334,7 +334,7 @@ With optional prefix ARG or if `apropos-do-all' is non-nil, also looks
 at the function and at the names and values of properties.
 Returns list of symbols and values found."
   (interactive "sApropos value (regexp): \nP")
-  (setq apropos-regexp (apropos-rewrite-regexp apropos-regexp))  
+  (setq apropos-regexp (apropos-rewrite-regexp apropos-regexp))
   (or do-all (setq do-all apropos-do-all))
   (setq apropos-accumulator ())
    (let (f v p)
index 8849dbb..0174427 100644 (file)
@@ -400,7 +400,7 @@ Hashed files are not understood, see `auto-save-hash-p'."
 Includes everything that can get us into trouble Unix.")
 
 ;; This code based on code in Bill Perry's url.el.
-    
+
 (defun auto-save-escape-name (str)
   "Escape any evil nasty characters in a potential filename.
 Uses quoted-printable-style escaping -- e.g. the dreaded =3D.
index df57711..856a5e2 100644 (file)
@@ -78,7 +78,7 @@ This variable is automatically local in each buffer where it is set."
 
 (make-variable-buffer-local 'auto-show-mode)
 
-(defcustom auto-show-shift-amount 8 
+(defcustom auto-show-shift-amount 8
   "*Extra columns to scroll. for automatic horizontal scrolling."
   :type 'integer
   :group 'auto-show)
@@ -128,7 +128,7 @@ that the region will be visible when `auto-show-make-point-visible'
 is next called (this happens after every command)."
   (if (auto-show-should-take-action-p)
       (let* ((scroll (window-hscroll)) ;how far window is scrolled
-            (w-width (- (window-width) 
+            (w-width (- (window-width)
                         (if (> scroll 0)
                             2 1)))     ;how wide window is on the screen
             (right-col (+ scroll w-width))
@@ -153,7 +153,7 @@ See also the command `auto-show-mode'."
   (if (auto-show-should-take-action-p)
       (let* ((col (current-column))    ;column on line point is at
             (scroll (window-hscroll))  ;how far window is scrolled
-            (w-width (- (window-width) 
+            (w-width (- (window-width)
                         (if (> scroll 0)
                             2 1)))     ;how wide window is on the screen
             (right-col (+ scroll w-width)))
@@ -166,7 +166,7 @@ See also the command `auto-show-mode'."
            (if (or (> col right-col)   ;to the right of the screen
                    (and (= col right-col)
                         (not (eolp))))
-               (scroll-left (+ auto-show-shift-amount 
+               (scroll-left (+ auto-show-shift-amount
                                (- col (+ scroll w-width))))))))))
 
 ;; XEmacs change:
index 51e665b..52bbd4b 100644 (file)
@@ -235,12 +235,12 @@ the section of autoloads for a file.")
          easy-mmode-define-minor-mode easy-mmode-define-global-mode
          define-minor-mode defun* defmacro*)
        "`defun'-like operators that use `autoload' to load the library.")
-      
+
       (defvar autoload-make-autoload-complex-operators
        '(easy-mmode-define-minor-mode easy-mmode-define-global-mode
          define-minor-mode)
        "`defun'-like operators to macroexpand before using `autoload'.")
-      
+
       (put 'autoload 'doc-string-elt 3)
       (put 'defun    'doc-string-elt 3)
       (put 'defun*   'doc-string-elt 3)
@@ -407,12 +407,12 @@ and TRIM-NAME (result of calling `autoload-trim-file-name' on FILE)."
     (setq file (expand-file-name file))
     ;; #### FSF 21.2.  Do we want this?
 ;     (let* ((source-truename (file-truename file))
-;         (dir-truename (file-name-as-directory
-;                        (file-truename default-directory)))
-;         (len (length dir-truename)))
+;         (dir-truename (file-name-as-directory
+;                        (file-truename default-directory)))
+;         (len (length dir-truename)))
 ;       (if (and (< len (length source-truename))
-;             (string= dir-truename (substring source-truename 0 len)))
-;        (setq file (substring source-truename len))))
+;             (string= dir-truename (substring source-truename 0 len)))
+;        (setq file (substring source-truename len))))
 
     ;; Check for suppression form (XEmacs)
     (let* ((dir (file-name-directory file))
@@ -455,21 +455,21 @@ and TRIM-NAME (result of calling `autoload-trim-file-name' on FILE)."
              ;; place we need the syntax table is when snarfing the Lisp
              ;; function name.
              (set-syntax-table emacs-lisp-mode-syntax-table))
-;          (if visited
-;              (set-buffer visited)
-;            ;; It is faster to avoid visiting the file.
-;            (set-buffer (get-buffer-create " *generate-autoload-file*"))
-;            (kill-all-local-variables)
-;            (erase-buffer)
-;            (setq buffer-undo-list t
-;                  buffer-read-only nil)
-;            ;; This doesn't look right for C files, but it is.  The only
-;            ;; place we need the syntax table is when snarfing the Lisp
-;            ;; function name.
-;            (emacs-lisp-mode)
-;            (if literal
-;                (insert-file-contents-literally file nil)
-;              (insert-file-contents file nil)))
+;          (if visited
+;              (set-buffer visited)
+;            ;; It is faster to avoid visiting the file.
+;            (set-buffer (get-buffer-create " *generate-autoload-file*"))
+;            (kill-all-local-variables)
+;            (erase-buffer)
+;            (setq buffer-undo-list t
+;                  buffer-read-only nil)
+;            ;; This doesn't look right for C files, but it is.  The only
+;            ;; place we need the syntax table is when snarfing the Lisp
+;            ;; function name.
+;            (emacs-lisp-mode)
+;            (if literal
+;                (insert-file-contents-literally file nil)
+;              (insert-file-contents file nil)))
            (unless (setq autoloads-done
                          (funcall fun-to-call outbuf load-name trim-name))
              (return-from generate-autoload-type-section))
@@ -498,19 +498,19 @@ and TRIM-NAME (result of calling `autoload-trim-file-name' on FILE)."
          ;; we alone and our successors can update the file.  The file itself
          ;; will work fine in older XEmacsen, but they won't be able to
          ;; update autoloads -- hence, to build.
-;        ;; Break that line at spaces, to avoid very long lines.
-;        ;; Make each sub-line into a comment.
-;        (with-current-buffer outbuf
-;          (save-excursion
-;            (forward-line -1)
-;            (while (not (eolp))
-;              (move-to-column 64)
-;              (skip-chars-forward "^ \n")
-;              (or (eolp)
-;                  (insert "\n" generate-autoload-section-continuation)))))
+;        ;; Break that line at spaces, to avoid very long lines.
+;        ;; Make each sub-line into a comment.
+;        (with-current-buffer outbuf
+;          (save-excursion
+;            (forward-line -1)
+;            (while (not (eolp))
+;              (move-to-column 64)
+;              (skip-chars-forward "^ \n")
+;              (or (eolp)
+;                  (insert "\n" generate-autoload-section-continuation)))))
          ;; XEmacs: This was commented out before.  #### Correct?
-;        (insert ";;; Generated autoloads from "
-;                (autoload-trim-file-name file) "\n")
+;        (insert ";;; Generated autoloads from "
+;                (autoload-trim-file-name file) "\n")
          ;; XEmacs -- handle suppression
          (when suppress-form
            (insert "\n;;; Suppress form from _pkg.el\n")
@@ -690,7 +690,7 @@ The file is assumed to be already loaded and in the current buffer."
                                   (symbol-value-in-buffer 'default-directory
                                                           outbuf)) outbuf)
        (princ ")\n" outbuf)
-              
+
        (goto-char (point-min))
        (while (not (eobp))
          (skip-chars-forward " \t\n\f")
@@ -834,8 +834,8 @@ at the beginning of lines and ^L characters."
   "Returns relative pathname of FILE including the last directory."
   (setq file (expand-file-name file))
   (file-relative-name file (file-name-directory
-                            (directory-file-name
-                             (file-name-directory file)))))
+                           (directory-file-name
+                            (file-name-directory file)))))
 
 (defun autoload-read-section-header ()
   "Read a section header form.
@@ -897,10 +897,10 @@ equal to `autoload-file-name')."
        ;; up-to-date and recompile when we build.
 
        ;; FSF 21.2: [not applicable to XEmacs]
-;      (or (> (buffer-size) 0)
-;          (error "Autoloads file %s does not exist" buffer-file-name))
-;      (or (file-writable-p buffer-file-name)
-;          (error "Autoloads file %s is not writable" buffer-file-name))
+;      (or (> (buffer-size) 0)
+;          (error "Autoloads file %s does not exist" buffer-file-name))
+;      (or (file-writable-p buffer-file-name)
+;          (error "Autoloads file %s is not writable" buffer-file-name))
 
        ;; NOTE: The rest of this function is totally changed from FSF.
        ;; Hence, not synched.
@@ -939,24 +939,24 @@ equal to `autoload-file-name')."
 
 (defun parse-command-line (cmdl)
   (let ((newcmdl (dllist))
-        (cmdlpl (make-skiplist))
-        (mm (compile-regexp "^--"))
-        (ign (compile-regexp #r"^-\(?:batch\|nd\|vanilla\)"))
-        (ign2 (compile-regexp "^-[lf]$")))
+       (cmdlpl (make-skiplist))
+       (mm (compile-regexp "^--"))
+       (ign (compile-regexp #r"^-\(?:batch\|nd\|vanilla\)"))
+       (ign2 (compile-regexp "^-[lf]$")))
     (while (car cmdl)
       (cond ((string-match mm (car cmdl))
-             (let ((key (intern (car cmdl)))
-                   (val (car (cdr-safe cmdl))))
-               (put-skiplist cmdlpl key val)
-               (setq cmdl (cdr-safe cmdl))))
-            ((string-match ign2 (car cmdl))
-             ;; ignore a pair of parameters
-             (setq cmdl (cdr-safe cmdl)))
-            ((string-match ign (car cmdl))
-             ;; ignore this single parameter
-             )
-            (t
-             (dllist-append newcmdl (car cmdl))))
+            (let ((key (intern (car cmdl)))
+                  (val (car (cdr-safe cmdl))))
+              (put-skiplist cmdlpl key val)
+              (setq cmdl (cdr-safe cmdl))))
+           ((string-match ign2 (car cmdl))
+            ;; ignore a pair of parameters
+            (setq cmdl (cdr-safe cmdl)))
+           ((string-match ign (car cmdl))
+            ;; ignore this single parameter
+            )
+           (t
+            (dllist-append newcmdl (car cmdl))))
       (setq cmdl (cdr-safe cmdl)))
     (put newcmdl :tweaks cmdlpl)
     newcmdl))
@@ -970,32 +970,32 @@ equal to `autoload-file-name')."
     (error "batch-update-directory-autoloads: may be used only with -batch"))
 
   (let* ((cmds (parse-command-line (cdr-safe command-line-args)))
-         (pl (get cmds :tweaks)))
+        (pl (get cmds :tweaks)))
 
     (unless (get-skiplist pl '--autoload-dir-name)
       (put-skiplist pl '--autoload-dir-name
-                    (expand-file-name default-directory)))
+                   (expand-file-name default-directory)))
     (unless (get-skiplist pl '--autoload-file-name)
       (put-skiplist pl '--autoload-file-name
-                    (expand-file-name autoload-file-name
-                                      (get-skiplist pl '--autoload-dir-name))))
+                   (expand-file-name autoload-file-name
+                                     (get-skiplist pl '--autoload-dir-name))))
     (unless (get-skiplist pl '--feature-prefix)
       (put-skiplist pl '--feature-prefix
-                    (file-name-nondirectory
-                     (directory-file-name
-                      (expand-file-name
-                       (get-skiplist pl '--autoload-dir-name))))))
+                   (file-name-nondirectory
+                    (directory-file-name
+                     (expand-file-name
+                      (get-skiplist pl '--autoload-dir-name))))))
 
     (create-autoload-files cmds t)))
 
 (defun create-autoload-files (bunch &optional force)
   (let* ((pl (get bunch :tweaks))
-         (relative (get-skiplist pl '--relative-to))
-         (al-file (get-skiplist pl '--autoload-file-name))
-         (fprefix (get-skiplist pl '--feature-prefix)))
+        (relative (get-skiplist pl '--relative-to))
+        (al-file (get-skiplist pl '--autoload-file-name))
+        (fprefix (get-skiplist pl '--feature-prefix)))
     (mapc-inplace
      #'(lambda (dir)
-         (expand-file-name dir relative))
+        (expand-file-name dir relative))
      bunch)
     (update-autoload-files (dllist-to-list bunch) fprefix al-file force)))
 
index 2eb5529..c0c7f6e 100644 (file)
@@ -113,7 +113,7 @@ template.  Forms following ,@ must evaluate to lists.
 
 Here is how to use backquotes:
   (setq p 'b
-        q '(c d e))
+       q '(c d e))
   `(a ,p ,@q)   -> (a b c d e)
   `(a . b)      -> (a . b)
   `(a . ,p)     -> (a . b)
@@ -229,13 +229,13 @@ This is an extremely rare thing to need to do in lisp."
                           (cond ((eq dflag 'append)
                                  (cons a d ))
                                 (t (list a (bq-process-1 dflag d)))))))
-                ((eq aflag bq-dot-flag)
-                 (if (null dflag)
-                     (bq-comma a)
-                     (cons 'nconc
-                           (cond ((eq dflag 'nconc)
-                                  (cons a d))
-                                 (t (list a (bq-process-1 dflag d)))))))
+               ((eq aflag bq-dot-flag)
+                (if (null dflag)
+                    (bq-comma a)
+                    (cons 'nconc
+                          (cond ((eq dflag 'nconc)
+                                 (cons a d))
+                                (t (list a (bq-process-1 dflag d)))))))
                ((null dflag)
                 (if (memq aflag '(quote t nil))
                     (cons 'quote (list a))
index 194aa8e..cff7562 100644 (file)
@@ -310,7 +310,7 @@ and then move up one line.  Prefix arg means move that many lines."
            (progn (delete-char 1)
                   (insert ? ))
          (delete-region (point) (progn (forward-line 1) (point)))
-         (backward-char 1))))))
+         (backward-char 1))))))
 
 (defun Buffer-menu-select ()
   "Select this line's buffer; also display buffers marked with `>'.
@@ -349,7 +349,7 @@ in the selected frame."
        (other-window 1)
        (switch-to-buffer (car others))
        (setq others (cdr others)))
-      (other-window 1)                         ;back to the beginning!
+      (other-window 1)                 ;back to the beginning!
 )))
 
 
@@ -445,9 +445,9 @@ The current window remains selected."
       (beginning-of-line)
       (forward-char 2)
       (if (/= (following-char) char)
-          (let (buffer-read-only)
-            (delete-char 1)
-            (insert char))))))
+         (let (buffer-read-only)
+           (delete-char 1)
+           (insert char))))))
 
 ;; XEmacs
 (defvar Buffer-menu-popup-menu
@@ -535,7 +535,7 @@ to generate such a string.  This variable is always buffer-local.")
 ;; #### not synched
 (defun list-buffers-internal (output &optional predicate)
   (let ((current (current-buffer))
-        (buffers (buffer-list)))
+       (buffers (buffer-list)))
     (save-excursion
       (set-buffer output)
       (setq buffer-read-only nil)
@@ -544,58 +544,58 @@ to generate such a string.  This variable is always buffer-local.")
       (insert list-buffers-header-line)
 
       (while buffers
-        (let* ((col1 19)
-               (buffer (car buffers))
-               (name (buffer-name buffer))
+       (let* ((col1 19)
+              (buffer (car buffers))
+              (name (buffer-name buffer))
               this-buffer-line-start)
-          (setq buffers (cdr buffers))
-          (cond ((null name))           ;deleted buffer
-                ((and predicate
-                      (not (if (stringp predicate)
-                               (string-match predicate name)
-                               (funcall predicate buffer))))
-                 nil)
-                (t
-                 (set-buffer buffer)
-                 (let ((ro buffer-read-only)
-                       (id list-buffers-identification))
-                   (set-buffer output)
+         (setq buffers (cdr buffers))
+         (cond ((null name))           ;deleted buffer
+               ((and predicate
+                     (not (if (stringp predicate)
+                              (string-match predicate name)
+                              (funcall predicate buffer))))
+                nil)
+               (t
+                (set-buffer buffer)
+                (let ((ro buffer-read-only)
+                      (id list-buffers-identification))
+                  (set-buffer output)
                   (setq this-buffer-line-start (point))
-                   (insert (if (eq buffer current)
-                               (progn (setq current (point)) ?\.)
-                               ?\ ))
-                   (insert (if (buffer-modified-p buffer)
-                               ?\*
-                               ?\ ))
-                   (insert (if ro
-                               ?\%
-                               ?\ ))
-                   (if (string-match "[\n\"\\ \t]" name)
-                       (let ((print-escape-newlines t))
-                         (prin1 name output))
-                       (insert ?\  name))
-                   (indent-to col1 1)
-                   (cond ((stringp id)
-                          (insert id))
-                         (id
-                          (set-buffer buffer)
-                          (condition-case e
-                              (funcall id output)
-                            (error
-                             (princ "***" output) (prin1 e output)))
-                          (set-buffer output)
-                          (goto-char (point-max)))))
+                  (insert (if (eq buffer current)
+                              (progn (setq current (point)) ?\.)
+                              ?\ ))
+                  (insert (if (buffer-modified-p buffer)
+                              ?\*
+                              ?\ ))
+                  (insert (if ro
+                              ?\%
+                              ?\ ))
+                  (if (string-match "[\n\"\\ \t]" name)
+                      (let ((print-escape-newlines t))
+                        (prin1 name output))
+                      (insert ?\  name))
+                  (indent-to col1 1)
+                  (cond ((stringp id)
+                         (insert id))
+                        (id
+                         (set-buffer buffer)
+                         (condition-case e
+                             (funcall id output)
+                           (error
+                            (princ "***" output) (prin1 e output)))
+                         (set-buffer output)
+                         (goto-char (point-max)))))
                 (put-nonduplicable-text-property this-buffer-line-start
                                                  (point)
                                                  'buffer-name name)
                 (put-nonduplicable-text-property this-buffer-line-start
                                                  (point)
                                                  'highlight t)
-                 (insert ?\n)))))
+                (insert ?\n)))))
 
       (Buffer-menu-mode)
       (if (not (bufferp current))
-          (goto-char current)))))
+         (goto-char current)))))
 ;(define-key ctl-x-map "\C-b" 'list-buffers)
 
 (defun list-buffers (&optional files-only)
index 38bb3b1..123c457 100644 (file)
@@ -64,7 +64,7 @@
 ;; emods
 (defun find-emod-directories ()
   (let* ((objdir "../modules/")
-        (files (directory-files-recur 
+        (files (directory-files-recur
                 objdir 'full (mapfam
                               #'(lambda (e)
                                   (replace-in-string e "\\." ""))
@@ -86,7 +86,7 @@
 
 (when (featurep 'modules)
   (let* ((modsrc "../.sxemacs.source.tree/modules/")
-        (mods (mapfam 
+        (mods (mapfam
                #'(lambda (d) (concat modsrc d))
                :result-type #'list (find-emod-directories)))
         (feat "modules")
index e9c2ba2..b8a38ee 100644 (file)
@@ -79,9 +79,9 @@
   "*The list of mail addresses SXEmacs Build Reports should most likely
 go to."
   :type '(repeat
-          :custom-show t
-          :documentation-shown t
-          string)
+         :custom-show t
+         :documentation-shown t
+         string)
   :group 'build-rpt)
 
 (defcustom build-rpt-keep-regexp
@@ -105,9 +105,9 @@ go to."
    "^\\(real\\|user\\|sys\\)\\s-+[0-9]+m")
   "*Regexp of make process output lines to keep in the report."
   :type '(repeat
-          :custom-show t
-          :documentation-shown t
-          regexp)
+         :custom-show t
+         :documentation-shown t
+         regexp)
   :group 'build-rpt)
 
 (defcustom build-rpt-delete-regexp
@@ -119,23 +119,23 @@ go to."
    "wrong-error")
   "*Regexp of make process output lines to delete from the report."
   :type '(repeat
-          :custom-show t
-          :documentation-shown t
-          regexp)
+         :custom-show t
+         :documentation-shown t
+         regexp)
   :group 'build-rpt)
 
 (defcustom build-rpt-make-output-dir (config-value 'sxe_blddir)
   "*Directory where the build report file is found."
   :type '(directory
-          :custom-show t
-          :documentation-shown t)
+         :custom-show t
+         :documentation-shown t)
   :group 'build-rpt)
 
 (defcustom build-rpt-make-output-files
   (list
    ",,vars.out"
    ",,beta.out"
-   ",,make-all.out" 
+   ",,make-all.out"
    ",,make-check-temacs.out"
    ",,make-check.out"
    ",,make-install.out")
@@ -148,18 +148,18 @@ redirection, like so...
   $ make check 2>&1 | tee ,,make-check.out
 "
   :type '(repeat
-          :custom-show t
-          :documentation-shown t
-          file)
+         :custom-show t
+         :documentation-shown t
+         file)
   :group 'build-rpt)
 
 (defcustom build-rpt-installation-file
   (expand-file-name "Installation"
-                    (gethash 'sxe_blddir (config-value-hash-table)))
+                   (gethash 'sxe_blddir (config-value-hash-table)))
   "*Installation file produced by SXEmacs configure process."
   :type '(file
-          :custom-show t
-          :documentation-shown t)
+         :custom-show t
+         :documentation-shown t)
   :group 'build-rpt)
 
 (defcustom build-rpt-version-file
@@ -171,8 +171,8 @@ redirection, like so...
           "src"))))
   "*File containing version info."
   :type '(file
-          :custom-show t
-          :documentation-shown t)
+         :custom-show t
+         :documentation-shown t)
   :group 'build-rpt)
 
 (defcustom build-rpt-subject
@@ -183,8 +183,8 @@ redirection, like so...
   with user input through `build-rpt' according to
   `build-rpt-prompts' using `format'."
   :type '(string
-          :custom-show t
-          :documentation-shown t)
+         :custom-show t
+         :documentation-shown t)
   :group 'build-rpt)
 
 (defcustom build-rpt-prompts
@@ -195,14 +195,14 @@ redirection, like so...
   followed by any number of strings which can be chosen via the history
   mechanism."
   :type '(repeat
-          :custom-show t
-          :documentation-shown t
-          (list
-           :tag "Prompt"
-           string
-           (repeat
-            :tag "Values"
-            string)))
+         :custom-show t
+         :documentation-shown t
+         (list
+          :tag "Prompt"
+          string
+          (repeat
+           :tag "Values"
+           string)))
   :group 'build-rpt)
 
 (defcustom build-rpt-file-encoding
@@ -250,21 +250,21 @@ This is useful if there are customised settings along with the group."
   "Returns the filename the SXEmacs make output is saved in."
   (interactive)
   (if (or (string-equal build-rpt-make-output-dir "")
-          (null build-rpt-make-output-dir))
+         (null build-rpt-make-output-dir))
       (mapcar
        (function
-        (lambda (f)
-          (expand-file-name
-           f
-           (file-name-as-directory
-            (gethash 'sxe_blddir (config-value-hash-table))))))
+       (lambda (f)
+         (expand-file-name
+          f
+          (file-name-as-directory
+           (gethash 'sxe_blddir (config-value-hash-table))))))
        build-rpt-make-output-files)
     (mapcar
      (function
       (lambda (f)
-        (expand-file-name
-         f
-         (file-name-as-directory build-rpt-make-output-dir))))
+       (expand-file-name
+        f
+        (file-name-as-directory build-rpt-make-output-dir))))
      build-rpt-make-output-files)))
 
 (defun build-rpt-read-destination ()
@@ -312,8 +312,8 @@ See also `mail-user-agent', `build-rpt-email', and
                             (if (and (interactive-p)
                                      (featurep 'sendmail))
                                 (user-mail-address)
-                              (concat (user-real-login-name) 
-                                      "-notconfigured@" 
+                              (concat (user-real-login-name)
+                                      "-notconfigured@"
                                       (if mail-host-address
                                           mail-host-address
                                         "localhost"))))))
@@ -351,32 +351,32 @@ See also `mail-user-agent', `build-rpt-email', and
             nil
             nil)
            (goto-char (point-max))
-            (re-search-backward mail-header-separator)
-            (next-line 1))
+           (re-search-backward mail-header-separator)
+           (next-line 1))
        (pop-to-buffer "*build-rpt*")
        (insert (format (concat "Please save this buffer to a file and email it\n"
-                                "Or, alternatively, rerun `M-x build-rpt' after installing the\n"
-                                "\"mail-lib\" XEmacs package.\n\n"
-                                "To: SXEmacs Builds <sxemacs-builds@sxemacs.org>\n"
-                                "Subject: %s\n\n")
-                        (apply #'format build-rpt-subject args)))))
+                               "Or, alternatively, rerun `M-x build-rpt' after installing the\n"
+                               "\"mail-lib\" XEmacs package.\n\n"
+                               "To: SXEmacs Builds <sxemacs-builds@sxemacs.org>\n"
+                               "Subject: %s\n\n")
+                       (apply #'format build-rpt-subject args)))))
     (let* ((rpt-begin (point))
-           (files (reverse (build-rpt-make-output-get)))
-           (file (car files)))
+          (files (reverse (build-rpt-make-output-get)))
+          (file (car files)))
       (while file
-        (if (file-exists-p file)
-            (insert (build-rpt-insert-make-output rpt-begin file))
-          (insert (format "%s not found!\n" file)))
-        (insert "\n")
-        (setq files (cdr files))
-        (setq file (car files)))
+       (if (file-exists-p file)
+           (insert (build-rpt-insert-make-output rpt-begin file))
+         (insert (format "%s not found!\n" file)))
+       (insert "\n")
+       (setq files (cdr files))
+       (setq file (car files)))
       (insert (build-rpt-insert-config-values rpt-begin))
       (insert "\n")
       (insert (build-rpt-insert-ldd rpt-begin))
       (insert "\n")
       (if (file-exists-p build-rpt-installation-file)
-          (insert (build-rpt-insert-installation-file rpt-begin))
-        (insert (format "%s not found!\n" build-rpt-installation-file)))
+         (insert (build-rpt-insert-installation-file rpt-begin))
+       (insert (format "%s not found!\n" build-rpt-installation-file)))
       (insert "\n")
       (insert (build-rpt-insert-header rpt-begin))
       (if build-rpt-interactive
@@ -404,22 +404,22 @@ See also `mail-user-agent', `build-rpt-destination', and
   ;; `interactive' form returns value for formal parameter `args'.
   (interactive
    (let (prompt
-         hist
-         arg
-         (prompts build-rpt-prompts))
+        hist
+        arg
+        (prompts build-rpt-prompts))
      (progn
        (while prompts
-         (defvar hist)
-         (setq prompt (caar prompts))
-         (setq hist (cdar prompts))
-         ;; `build-rpt-prompts' used to be a list of lists, the
-         ;; first element of each list being the prompt, the rest being
-         ;; the history.  The history is now in a separate list.  We
-         ;; better check for that.
-         (if (listp (car hist))
-             (setq hist (car hist)))
-         (setq prompts (cdr prompts))
-         (setq arg (cons (read-string prompt "" 'hist) arg)))
+        (defvar hist)
+        (setq prompt (caar prompts))
+        (setq hist (cdar prompts))
+        ;; `build-rpt-prompts' used to be a list of lists, the
+        ;; first element of each list being the prompt, the rest being
+        ;; the history.  The history is now in a separate list.  We
+        ;; better check for that.
+        (if (listp (car hist))
+            (setq hist (car hist)))
+        (setq prompts (cdr prompts))
+        (setq arg (cons (read-string prompt "" 'hist) arg)))
        arg)))
   (let ((build-rpt-email (build-rpt-read-destination))
        (build-rpt-interactive (interactive-p)))
@@ -446,34 +446,34 @@ The make process output must have been saved in
   (goto-char where)
   (with-temp-buffer
     (if (file-exists-p file)
-        (progn
-          (if (featurep 'mime-setup)
-              (progn
-                (mime-edit-insert-tag
-                 "text"
-                 "plain"
-                 (concat
-                  "\nContent-Disposition: attachment;"
-                  " filename=\""
-                  (file-name-nondirectory
-                   file)
-                  "\""))
-                (mime-edit-insert-binary-file
-                 file
-                 build-rpt-file-encoding))
-            (insert-file-contents file))
-          (when build-rpt-keep-regexp
-            (goto-char (point-min))
-            (delete-non-matching-lines (build-rpt-keep)))
-          (when build-rpt-delete-regexp
-            (goto-char (point-min))
-            (delete-matching-lines (build-rpt-delete)))
-          (goto-char (point-min))
-          (insert "\n")
-          (insert
-           (format "> Contents of %s\n" file)))
+       (progn
+         (if (featurep 'mime-setup)
+             (progn
+               (mime-edit-insert-tag
+                "text"
+                "plain"
+                (concat
+                 "\nContent-Disposition: attachment;"
+                 " filename=\""
+                 (file-name-nondirectory
+                  file)
+                 "\""))
+               (mime-edit-insert-binary-file
+                file
+                build-rpt-file-encoding))
+           (insert-file-contents file))
+         (when build-rpt-keep-regexp
+           (goto-char (point-min))
+           (delete-non-matching-lines (build-rpt-keep)))
+         (when build-rpt-delete-regexp
+           (goto-char (point-min))
+           (delete-matching-lines (build-rpt-delete)))
+         (goto-char (point-min))
+         (insert "\n")
+         (insert
+          (format "> Contents of %s\n" file)))
       (insert "> " file
-              " does not exist!\n\n"))
+             " does not exist!\n\n"))
     (buffer-string)))
 
 (defun build-rpt-insert-installation-file (where)
@@ -483,28 +483,28 @@ created by the SXEmacs Beta configure process."
   (with-temp-buffer
     (if (file-exists-p build-rpt-installation-file)
        (progn
-          (insert "> Contents of "
-                  build-rpt-installation-file
-                  ":\n")
-          (insert "> (Output from ./configure)\n\n")
-          (if (featurep 'mime-setup)
-              (progn
-                (mime-edit-insert-tag
-                 "text"
-                 "plain"
-                 (concat
-                  "\nContent-Disposition: attachment;"
-                  " filename=\""
-                  (file-name-nondirectory
-                   build-rpt-installation-file)
-                  "\""))
-                (mime-edit-insert-binary-file
-                 build-rpt-installation-file
-                 build-rpt-file-encoding))
-            (insert-file-contents
-             build-rpt-installation-file)))
+         (insert "> Contents of "
+                 build-rpt-installation-file
+                 ":\n")
+         (insert "> (Output from ./configure)\n\n")
+         (if (featurep 'mime-setup)
+             (progn
+               (mime-edit-insert-tag
+                "text"
+                "plain"
+                (concat
+                 "\nContent-Disposition: attachment;"
+                 " filename=\""
+                 (file-name-nondirectory
+                  build-rpt-installation-file)
+                 "\""))
+               (mime-edit-insert-binary-file
+                build-rpt-installation-file
+                build-rpt-file-encoding))
+           (insert-file-contents
+            build-rpt-installation-file)))
       (insert "> " build-rpt-installation-file
-              " does not exist!\n\n"))
+             " does not exist!\n\n"))
     (buffer-string)))
 
 (defun build-rpt-insert-config-values (where)
@@ -513,23 +513,23 @@ created by the SXEmacs Beta configure process."
   (goto-char where)
   (with-temp-buffer
     (if (null (config-value-hash-table))
-        (insert "> `config-value-hash-table' is empty, which is weird :(!\n\n")
+       (insert "> `config-value-hash-table' is empty, which is weird :(!\n\n")
        (progn
-          (insert "> Contents of `config-value-hash-table':\n")
-          (let ((curp (point))
-                value-empty)
-            (maphash
-             #'(lambda (key value)
-                 (if (and (stringp value)
-                          (string= "" value))
-                     (setq value-empty (cons key value-empty))
-                   (insert (format "%s %S\n" key value))))
-             (config-value-hash-table))
-            (goto-char curp)
-            ;; we are at `curp' again
-            (insert (format "Empty keys: %s\n\n"
-                            (mapconcat #'prin1-to-string
-                                       value-empty "  "))))))
+         (insert "> Contents of `config-value-hash-table':\n")
+         (let ((curp (point))
+               value-empty)
+           (maphash
+            #'(lambda (key value)
+                (if (and (stringp value)
+                         (string= "" value))
+                    (setq value-empty (cons key value-empty))
+                  (insert (format "%s %S\n" key value))))
+            (config-value-hash-table))
+           (goto-char curp)
+           ;; we are at `curp' again
+           (insert (format "Empty keys: %s\n\n"
+                           (mapconcat #'prin1-to-string
+                                      value-empty "  "))))))
     (buffer-string)))
 
 (defun build-rpt-insert-ldd (where)
@@ -537,36 +537,36 @@ created by the SXEmacs Beta configure process."
   (goto-char where)
   (with-temp-buffer
     (let ((running-binary-tests
-           '((lambda ()
-               (expand-file-name (car command-line-args)
-                                 command-line-default-directory))
-             (lambda ()
-               (locate-file (car command-line-args)
-                            (split-string (getenv "PATH") ":")))))
-           (running-binary)
-           (ldd
-            (let ((sysconfl (split-string system-configuration "-")))
-              (cond
-               ((member "apple" sysconfl)
-                "otool -XL")
-               (t
-                "ldd")))))
+          '((lambda ()
+              (expand-file-name (car command-line-args)
+                                command-line-default-directory))
+            (lambda ()
+              (locate-file (car command-line-args)
+                           (split-string (getenv "PATH") ":")))))
+          (running-binary)
+          (ldd
+           (let ((sysconfl (split-string system-configuration "-")))
+             (cond
+              ((member "apple" sysconfl)
+               "otool -XL")
+              (t
+               "ldd")))))
 
       ;; perform binary finder tests
       (while (and (null running-binary) (car-safe running-binary-tests))
-        (let ((candidate (funcall (car running-binary-tests))))
-          (setq running-binary
-                (and candidate
-                     (file-exists-p candidate)
-                     candidate)
-                running-binary-tests (cdr running-binary-tests))))
+       (let ((candidate (funcall (car running-binary-tests))))
+         (setq running-binary
+               (and candidate
+                    (file-exists-p candidate)
+                    candidate)
+               running-binary-tests (cdr running-binary-tests))))
 
       (if (null running-binary)
-          (insert "cannot obtain ld-dependencies.\n")
-        (insert (shell-command-to-string (concat ldd " " running-binary)))
-        (goto-char (point-min))
-        (while (re-search-forward "^\\s-+" nil t)
-          (replace-match "")))
+         (insert "cannot obtain ld-dependencies.\n")
+       (insert (shell-command-to-string (concat ldd " " running-binary)))
+       (goto-char (point-min))
+       (while (re-search-forward "^\\s-+" nil t)
+         (replace-match "")))
       (goto-char (point-min))
       (insert "> shared library dependencies:\n"))
     (buffer-string)))
@@ -576,14 +576,14 @@ created by the SXEmacs Beta configure process."
 MIME tag REGEXP.  The result is a REGEXP string matching either of the
 REGEXPs in `build-rpt-keep-regexp' or a general MIME tag REGEXP."
   (mapconcat #'identity
-             (cons #r"^--\[\[\|\]\]$" build-rpt-keep-regexp) "\\|"))
+            (cons #r"^--\[\[\|\]\]$" build-rpt-keep-regexp) "\\|"))
 
 (defun build-rpt-delete ()
   "Concatenate elements of `build-rpt-delete-regexp' and a general
 MIME tag REGEXP.  The result is a REGEXP string matching either of the
 REGEXPs in `build-rpt-delete-regexp' or a general MIME tag REGEXP."
   (mapconcat '(lambda (item) item)
-             build-rpt-delete-regexp "\\|"))
+            build-rpt-delete-regexp "\\|"))
 
 ;; To ensure we always get the right build reporter, alias the
 ;; incompatible one to ours if it is ever loaded.
index 1d5a284..0d6d865 100644 (file)
          ((and (fboundp 'compiler-macroexpand)
                (symbolp (car-safe form))
                (get (car-safe form) 'cl-compiler-macro)
-               (not (eq form
-                        (setq form (compiler-macroexpand form)))))
+               (not (eq form
+                        (setq form (compiler-macroexpand form)))))
           (byte-optimize-form form for-effect))
 
          ((not (symbolp fn))
 ;; Byte-compiled code with special number types is not readable by
 ;; SXEmacsen which do not have an mp spine.
 ;; Therefore always tag their usage using (featurep 'ent)
-;; or the like 
+;; or the like
 ;; - hroptatyr
 (defun byte-optimize-delay-constants-math (form start fun)
   ;; Merge all FORM's constants from number START, call FUN on them
        (overflow (memq fun '(+ *))))
     (while (cdr (setq rest (cdr rest)))
       (if (if (featurep 'ent)
-              (numberp (car rest))
-            (integerp (car rest)))
+             (numberp (car rest))
+           (integerp (car rest)))
          (let (constants)
            (setq form (copy-sequence form)
                  rest (nthcdr (1- start) form))
            (while (setq rest (cdr rest))
              (cond ((and (featurep 'ent)
-                          (rationalp (car rest)))
-                     (setq constants (cons (car rest) constants))
-                     (setcar rest nil))
-                    ((integerp (car rest))
-                     (setq constants (cons (car rest) constants))
-                     (setcar rest nil))
-                    ((realp (car rest))
+                         (rationalp (car rest)))
+                    (setq constants (cons (car rest) constants))
+                    (setcar rest nil))
+                   ((integerp (car rest))
+                    (setq constants (cons (car rest) constants))
+                    (setcar rest nil))
+                   ((realp (car rest))
                     (setq constants
                           (cons
                            (coerce-number
                               )))
                            constants))
                     (setcar rest nil))
-                    ((and (or (featurep 'bigc)
-                              (featurep 'bigg))
-                          (complexp (car rest)))
-                     (setq constants (cons (car rest) constants))
-                     (setcar rest nil))
-                    ((and (featurep 'resclass)
-                          (declare-fboundp (residue-class-p (car rest))))
-                     (setq constants (cons (car rest) constants))
-                     (setcar rest nil))))
+                   ((and (or (featurep 'bigc)
+                             (featurep 'bigg))
+                         (complexp (car rest)))
+                    (setq constants (cons (car rest) constants))
+                    (setcar rest nil))
+                   ((and (featurep 'resclass)
+                         (declare-fboundp (residue-class-p (car rest))))
+                    (setq constants (cons (car rest) constants))
+                    (setcar rest nil))))
            ;; If necessary, check now for overflow
            ;; that might be caused by reordering.
            (if (and overflow
                     ;; We have overflow if the result of doing the arithmetic
                     ;; on floats is not even close to the result
                     ;; of doing it on integers.
-                     (not (featurep '(or bigz bigq bigf bigfr bigc bigg resclass)))
-                     ;; This assumption, of course, is not valid if we
-                     ;; have bigz numbers
+                    (not (featurep '(or bigz bigq bigf bigfr bigc bigg resclass)))
+                    ;; This assumption, of course, is not valid if we
+                    ;; have bigz numbers
                     (not (byte-optimize-approx-equal
                            (apply fun (mapcar 'float constants))
                            (float (apply fun constants)))))
   (cond ((numberp (nth 1 form))
         (eval form))
        ((featurep 'ent)
-         ;; we cannot compare to 0 anymore, since there are coercion
-         ;; issues and even non-comparable types
-         form)
-        (byte-compile-delete-errors
+        ;; we cannot compare to 0 anymore, since there are coercion
+        ;; issues and even non-comparable types
+        form)
+       (byte-compile-delete-errors
         (list '= (nth 1 form) 0))
        (form)))
 
               (setq rest (cdr rest))
               (cond ((= tmp 1)
                      (byte-compile-log-lap
-                      "  %s discard\t-->\t<deleted>" lap0)
+                      "  %s discard\t-->\t<deleted>" lap0)
                      (setq lap (delq lap0 (delq lap1 lap))))
                     ((= tmp 0)
                      (byte-compile-log-lap
                 (byte-compile-log-lap
                  "  %s: %s ... %s %s\t-->\t%s: %s %s: ... %s %s %s"
                  (nth 1 (cdr lap2)) (car tmp)
-                  lap1 lap2
+                 lap1 lap2
                  (nth 1 (cdr lap2)) (car tmp)
                  (nth 1 newtag) 'byte-dup lap1
                  (cons 'byte-goto newtag)
            lap1 (nth 1 rest))
       (if (memq (car lap0) byte-constref-ops)
          (if (not (eq (car lap0) 'byte-constant))
-             (progn 
+             (progn
                (incf (gethash (cdr lap0) variable-frequency 0))
                (or (memq (cdr lap0) byte-compile-variables)
                    (setq byte-compile-variables
index cbe5a87..519d006 100644 (file)
@@ -29,8 +29,8 @@
 
 ;; This file is dumped with SXEmacs.
 
-;; The code in this file should always be loaded, because it defines things 
-;; like "defsubst" which should work interpreted as well.  The code in 
+;; The code in this file should always be loaded, because it defines things
+;; like "defsubst" which should work interpreted as well.  The code in
 ;; bytecomp.el and byte-optimize.el can be loaded as needed.
 
 ;; interface to selectively inlining functions.
@@ -506,7 +506,7 @@ SYMBOL must be quoted and can be a list of SYMBOLS.  See also
 
 (put 'byte-compiler-options 'lisp-indent-hook 0)
 (defmacro byte-compiler-options (&rest args)
-  "Set some compilation-parameters for this file.  
+  "Set some compilation-parameters for this file.
 This will affect only the file in which it appears; this does nothing when
 evaluated, or when loaded from a .el file.
 
@@ -532,7 +532,7 @@ some subset of the following flags:
   obsolete     use of an obsolete function or variable.
   pedantic     warn of use of compatible symbols.
 
-If the first element if the list is `+' or `-' then the specified elements 
+If the first element if the list is `+' or `-' then the specified elements
 are added to or removed from the current set of warnings, instead of the
 entire set of warnings being overwritten.
 
index 0e5ed1e..bcee9c0 100644 (file)
@@ -1205,7 +1205,7 @@ otherwise pop it")
                      (and (cdr sig) (> max (cdr sig))))
                  (byte-compile-warn
            "%s being defined to take %s%s, but was previously called with %s"
-                   (nth 1 form)
+                   (nth 1 form)
                    (byte-compile-arglist-signature-string sig)
                    (if (equal sig '(1 . 1)) " arg" " args")
                    (byte-compile-arglist-signature-string (cons min max))))
@@ -1460,8 +1460,8 @@ recompile every `.el' file that already has a `.elc' file."
                                 (y-or-n-p (concat "Compile " source "? "))))))
                 (progn ;(if (and noninteractive (not byte-compile-verbose))
                        ;    (message "Compiling %s..." source))
-                       ; we do this in byte-compile-file.
-                       (if byte-recompile-directory-ignore-errors-p
+                       ; we do this in byte-compile-file.
+                       (if byte-recompile-directory-ignore-errors-p
                             (batch-byte-compile-1 source)
                          (byte-compile-file source))
                        (or noninteractive
@@ -1546,8 +1546,8 @@ With prefix arg (noninteractively: 2nd arg), load the file after compiling."
       (let ((buffer-file-name filename)
            (default-major-mode 'emacs-lisp-mode)
            (enable-local-eval nil))
-        (normal-mode)
-        (setq filename buffer-file-name)))
+       (normal-mode)
+       (setq filename buffer-file-name)))
       (setq byte-compiler-error-flag nil)
     ;; It is important that input-buffer not be current at this call,
     ;; so that the value of point set in input-buffer
@@ -1774,9 +1774,9 @@ With argument, insert value in current buffer after the form."
               "\t (or (and (boundp 'epoch::version) epoch::version)\n"
               "\t     (and (not (featurep 'xemacs))\n"
               "\t          (<= emacs-major-version 19)\n"
-               "\t          (< emacs-minor-version 29))\n"
+              "\t          (< emacs-minor-version 29))\n"
               "\t     (and (<= emacs-major-version 20)\n"
-               "\t          (< emacs-minor-version 14))))\n"
+              "\t          (< emacs-minor-version 14))))\n"
               "    (error \"`"
               ;; prin1-to-string is used to quote backslashes.
               (substring (prin1-to-string (file-name-nondirectory filename))
@@ -2166,7 +2166,7 @@ list that represents a doc string reference.
          ((and (fboundp name)
                (or (subrp (symbol-function name))
                    (eq (car-safe (symbol-function name))
-                       (if macrop 'lambda 'macro))))
+                       (if macrop 'lambda 'macro))))
           (if (memq 'redefine byte-compile-warnings)
               (byte-compile-warn "%s %s being redefined as a %s"
                                  (if (subrp (symbol-function name))
@@ -2326,36 +2326,36 @@ list that represents a doc string reference.
   ;; XEmacs change; our implementation byte compiles and gives warnings
   ;; about the default value code, which GNU's doesn't.
   (let* ((quoted-default (car-safe (cdr-safe (cdr-safe form))))
-         (to-examine (car-safe (cdr-safe quoted-default))))
+        (to-examine (car-safe (cdr-safe quoted-default))))
     (if (memq 'free-vars byte-compile-warnings)
-        (setq byte-compile-bound-variables
-              (cons (cons (nth 1 (nth 1 form))
-                          byte-compile-global-bit)
-                    byte-compile-bound-variables)))
+       (setq byte-compile-bound-variables
+             (cons (cons (nth 1 (nth 1 form))
+                         byte-compile-global-bit)
+                   byte-compile-bound-variables)))
     ;; Byte compile anything that smells like a lambda. I initially
     ;; considered limiting it to the :initialize, :set and :get args, but
     ;; that's not amazingly forward-compatible, and anyone expecting other
-    ;; things to be stored as data, not code, is unrealistic. 
+    ;; things to be stored as data, not code, is unrealistic.
      (loop
        for entry in-ref (nthcdr 4 form)
        do (cond ((and (eq 'function (car-safe entry))
-                      (consp (car-safe (cdr-safe entry))))
-                 (setf entry (copy-sequence entry))
-                 (setcar (cdr entry) (byte-compile-lambda (car (cdr entry)))))
-                ((and (eq 'lambda (car-safe entry)))
-                 (setf entry (byte-compile-lambda entry)))))
-     ;; Byte compile the default value, as we do for defvar. 
+                     (consp (car-safe (cdr-safe entry))))
+                (setf entry (copy-sequence entry))
+                (setcar (cdr entry) (byte-compile-lambda (car (cdr entry)))))
+               ((and (eq 'lambda (car-safe entry)))
+                (setf entry (byte-compile-lambda entry)))))
+     ;; Byte compile the default value, as we do for defvar.
      (when (consp (cdr-safe to-examine))
        (setq form (copy-sequence form))
        (setcdr (third form)
-               (list (byte-compile-top-level to-examine nil 'file)))
+              (list (byte-compile-top-level to-examine nil 'file)))
        ;; And save a value to be examined in the custom UI, if that differs
        ;; from the init value.
        (unless (equal to-examine (car-safe (cdr (third form))))
-         (setf (nthcdr 4 form) (nconc
-                                (list :default 
-                                      (list 'quote to-examine))
-                                (nthcdr 4 form)))))
+        (setf (nthcdr 4 form) (nconc
+                               (list :default
+                                     (list 'quote to-examine))
+                               (nthcdr 4 form)))))
     form))
 
 \f
@@ -2610,14 +2610,14 @@ If FORM is a lambda or a macro, byte-compile it as a function."
            (while (cond
                    ((memq (car (car rest)) '(byte-varref byte-constant))
                     (setq tmp (car (cdr (car rest))))
-                     (if (if (eq (car (car rest)) 'byte-constant)
-                             (or (consp tmp)
-                                 (and (symbolp tmp)
-                                      (not (byte-compile-constant-symbol-p tmp)))))
-                         (if maycall
-                             (setq body (cons (list 'quote tmp) body)))
-                       (setq body (cons tmp body))))
-                    ((and maycall
+                    (if (if (eq (car (car rest)) 'byte-constant)
+                            (or (consp tmp)
+                                (and (symbolp tmp)
+                                     (not (byte-compile-constant-symbol-p tmp)))))
+                        (if maycall
+                            (setq body (cons (list 'quote tmp) body)))
+                      (setq body (cons tmp body))))
+                   ((and maycall
                          ;; Allow a funcall if at most one atom follows it.
                          (null (nthcdr 3 rest))
                          (setq tmp
@@ -2852,7 +2852,7 @@ If FORM is a lambda or a macro, byte-compile it as a function."
        (list 'quote
          (or (car (cdr-safe function))
              (intern (concat "byte-"
-                       (symbol-name (or (car-safe function) function))))))
+                       (symbol-name (or (car-safe function) function))))))
        ''emacs20-opcode t)
       (list 'byte-defop-compiler function compile-handler))))
 
@@ -2950,8 +2950,8 @@ If FORM is a lambda or a macro, byte-compile it as a function."
 (byte-defop-compiler integerp          1)
 (byte-defop-compiler skip-chars-forward     1-2+1)
 (byte-defop-compiler skip-chars-backward    1-2+1)
-(byte-defop-compiler (eql byte-eq)     2)
-(byte-defop-compiler20 old-eq          2)
+(byte-defop-compiler (eql byte-eq)     2)
+(byte-defop-compiler20 old-eq          2)
 (byte-defop-compiler20 old-memq                2)
 (byte-defop-compiler cons              2)
 (byte-defop-compiler aref              2)
@@ -3791,8 +3791,8 @@ If FORM is a lambda or a macro, byte-compile it as a function."
          compiled-clauses)
       (while clauses
        (let* ((clause (car clauses))
-               (condition (car clause)))
-          (cond ((not (or (symbolp condition)
+              (condition (car clause)))
+         (cond ((not (or (symbolp condition)
                          (and (listp condition)
                               (let ((syms condition) (ok t))
                                 (while syms
@@ -3800,9 +3800,9 @@ If FORM is a lambda or a macro, byte-compile it as a function."
                                       (setq ok nil))
                                   (setq syms (cdr syms)))
                                 ok))))
-                 (byte-compile-warn
-                   "%s is not a symbol naming a condition or a list of such (in condition-case)"
-                   (prin1-to-string condition)))
+                (byte-compile-warn
+                  "%s is not a symbol naming a condition or a list of such (in condition-case)"
+                  (prin1-to-string condition)))
 ;;                ((not (or (eq condition 't)
 ;;                       (and (stringp (get condition 'error-message))
 ;;                            (consp (get condition 'error-conditions)))))
@@ -3940,15 +3940,15 @@ If FORM is a lambda or a macro, byte-compile it as a function."
                             fun var string))
        `(put ',var 'variable-documentation ,string))
       (if (cdr (cdr form))             ; `value' provided
-          (cond ((eq fun 'defconst)
-                 ;; `defconst' sets `var' unconditionally.
-                 `(setq ,var ,value))
-                ((eq fun 'defregexp)
-                 ;; `defregexp' sets `var' unconditionally, too
-                 `(setq ,var (compile-regexp ,value)))
-                (t
-                 ;; `defvar' sets `var' only when unbound.
-                 `(if (not (default-boundp ',var)) (set-default ',var ,value)))))
+         (cond ((eq fun 'defconst)
+                ;; `defconst' sets `var' unconditionally.
+                `(setq ,var ,value))
+               ((eq fun 'defregexp)
+                ;; `defregexp' sets `var' unconditionally, too
+                `(setq ,var (compile-regexp ,value)))
+               (t
+                ;; `defvar' sets `var' only when unbound.
+                `(if (not (default-boundp ',var)) (set-default ',var ,value)))))
       `',var))))
 
 (defun byte-compile-autoload (form)
@@ -4269,14 +4269,14 @@ it won't work in an interactive Emacs."
       (error "`batch-byte-compile-one-file-here' is to be used only with -batch"))
   ;; we hard-redefine it, since we ought to be called in batch mode only
   (fset 'byte-compile-dest-file
-        #'(lambda (filename)
-            "Convert an Emacs Lisp source file name to a compiled file name."
-            (let ((outfile
-                   (file-name-sans-extension
-                    (if (string-match "lisp/" filename)
-                        (substring filename (match-end 0))
-                      filename))))
-              (expand-file-name (concat outfile ".elc") default-directory))))
+       #'(lambda (filename)
+           "Convert an Emacs Lisp source file name to a compiled file name."
+           (let ((outfile
+                  (file-name-sans-extension
+                   (if (string-match "lisp/" filename)
+                       (substring filename (match-end 0))
+                     filename))))
+             (expand-file-name (concat outfile ".elc") default-directory))))
   (batch-byte-compile-one-file))
 
 (defun batch-byte-compile-1 (file)
index 04106f3..2ee1b50 100644 (file)
 
 (defun safe-idiv (a b)
   (let* ((q (/ (abs a) (abs b)))
-         (s (* (signum a) (signum b))))
+        (s (* (signum a) (signum b))))
     (Values q (- a (* s q b)) s)))
 
 
 (provide 'cl-compat)
 
 ;;; cl-compat.el ends here
-
index 4bc30d1..00e2662 100644 (file)
@@ -75,21 +75,21 @@ TYPE is a Common Lisp type specifier."
        ((and (eq type 'character) (stringp x) (= (length x) 1)) (aref x 0))
        ((and (eq type 'character) (symbolp x)) (coerce (symbol-name x) type))
        ((and (eq type 'character) (char-int-p x)) (int-char x))
-        ((and (featurep 'number-types)
-              (memq type '(int fixnum
-                           bigz bignum
-                           integer
-                           bigq ratio
-                           rational
-                           float
-                           bigf bigfloat
-                           bigfr
-                           real
-                           bigg
-                           bigc
-                           ;;complex
-                           ))
-              (coerce-number x type)))
+       ((and (featurep 'number-types)
+             (memq type '(int fixnum
+                          bigz bignum
+                          integer
+                          bigq ratio
+                          rational
+                          float
+                          bigf bigfloat
+                          bigfr
+                          real
+                          bigg
+                          bigc
+                          ;;complex
+                          ))
+             (coerce-number x type)))
        ((and (eq type 'integer) (characterp x)) (char-int x))
        ((eq type 'float) (float x))
        ((eq type 'bit-vector) (if (bit-vector-p x) x
@@ -393,20 +393,20 @@ If so, return the true (non-nil) value returned by PREDICATE."
     "Return the greatest common divisor of the arguments."
     (let ((a (abs (or (cl-pop args) 0))))
       (while args
-        (let ((b (abs (cl-pop args))))
-          (while (> b 0) (setq b (% a (setq a b))))))
+       (let ((b (abs (cl-pop args))))
+         (while (> b 0) (setq b (% a (setq a b))))))
       a)))
 
 (unless (fboundp #'lcm)
   (defun lcm (&rest args)
     "Return the least common multiple of the arguments."
     (if (memq 0 args)
-        0
+       0
       (let ((a (abs (or (cl-pop args) 1))))
-        (while args
-          (let ((b (abs (cl-pop args))))
-            (setq a (* (/ a (gcd a b)) b))))
-        a))))
+       (while args
+         (let ((b (abs (cl-pop args))))
+           (setq a (* (/ a (gcd a b)) b))))
+       a))))
 
 (defun isqrt (a)
   "Return the integer square root of the argument."
index dd89a60..d1d2cf0 100644 (file)
@@ -158,7 +158,7 @@ ARGLIST allows full Common Lisp conventions."
   (cond ((symbolp arg)
         ;; Do not upcase &optional, &key etc.
         (if (memq arg lambda-list-keywords)
-             arg
+            arg
           (make-symbol (upcase (symbol-name arg)))))
        ((listp arg)
         (let ((arg (copy-list arg)) junk)
@@ -181,13 +181,13 @@ Supports Common Lisp lambda lists."
     (check-argument-type #'true-list-p arglist)
     (let ((print-gensym nil))
       (condition-case nil
-          (prin1-to-string
-           (cons (if (eq name 'cl-none) 'lambda name)
-                 (cond ((null arglist) nil)
-                       ((listp arglist) (cl-upcase-arg arglist))
-                       ((symbolp arglist)
-                        (cl-upcase-arg (list '&rest arglist)))
-                       (t (wrong-type-argument 'listp arglist)))))
+         (prin1-to-string
+          (cons (if (eq name 'cl-none) 'lambda name)
+                (cond ((null arglist) nil)
+                      ((listp arglist) (cl-upcase-arg arglist))
+                      ((symbolp arglist)
+                       (cl-upcase-arg (list '&rest arglist)))
+                      (t (wrong-type-argument 'listp arglist)))))
       (t "Not available")))))
 
 (defun cl-transform-lambda (form bind-block)
@@ -195,8 +195,8 @@ Supports Common Lisp lambda lists."
         (bind-defs nil) (bind-enquote nil)
         (bind-inits nil) (bind-lets nil) (bind-forms nil)
         (header nil) (simple-args nil)
-         (complex-arglist (cl-function-arglist bind-block args))
-         (doc ""))
+        (complex-arglist (cl-function-arglist bind-block args))
+        (doc ""))
     (while (or (stringp (car body)) (eq (car-safe (car body)) 'interactive))
       (push (pop body) header))
     (setq args (if (listp args) (copy-list args) (list '&rest args)))
@@ -218,15 +218,15 @@ Supports Common Lisp lambda lists."
     (or (eq bind-block 'cl-none)
        (setq body (list (list* 'block bind-block body))))
     (setq simple-args (nreverse simple-args)
-          header (nreverse header))
+         header (nreverse header))
     ;; Add CL lambda list to documentation, if the CL lambda list differs
     ;; from the non-CL lambda list. npak@ispras.ru
     (unless (equal complex-arglist
-                   (cl-function-arglist bind-block simple-args))
+                  (cl-function-arglist bind-block simple-args))
       (and (stringp (car header)) (setq doc (pop header)))
       (push (concat doc
-                    "\n\nCommon Lisp lambda list:\n" 
-                    "  " complex-arglist "\n\n")
+                   "\n\nCommon Lisp lambda list:\n"
+                   "  " complex-arglist "\n\n")
          header))
     (if (null args)
        (list* nil simple-args (nconc header body))
@@ -1191,18 +1191,18 @@ either `being each foo' or `being the foos'.)
               ((memq word key-types)
                (or (memq (car args) '(in of)) (error "Expected `of'"))
                (let* ((map (cl-pop2 args))
-                       other-word
-                       (other (if (eq (car args) 'using)
-                                  (if (and (= (length (cadr args)) 2)
-                                           (memq (setq other-word (caadr args))
-                                                 key-types)
-                                           (not (eq (caadr args) word)))
-                                      (cadr (cl-pop2 args))
-                                    (error "Bad `using' clause"))
-                                (gensym))))
+                      other-word
+                      (other (if (eq (car args) 'using)
+                                 (if (and (= (length (cadr args)) 2)
+                                          (memq (setq other-word (caadr args))
+                                                key-types)
+                                          (not (eq (caadr args) word)))
+                                     (cadr (cl-pop2 args))
+                                   (error "Bad `using' clause"))
+                               (gensym))))
                  (when (memq word '(key-binding key-bindings))
-                    (setq var (prog1 other (setq other var)))
-                    (and other-word (setq word other-word)))
+                   (setq var (prog1 other (setq other var)))
+                   (and other-word (setq word other-word)))
                  (setq loop-map-form
                        (list (if (memq word '(key-seq key-seqs))
                                  'cl-map-keymap-recursively 'cl-map-keymap)
@@ -1296,8 +1296,8 @@ either `being each foo' or `being the foos'.)
 
      ((memq word '(bvconcat bvconcating))
       (let ((what (cl-pop args))
-            (var (cl-loop-handle-accum #*)))
-        (cl-push (list 'progn (list 'callf 'bvconcat var what) t) loop-body)))
+           (var (cl-loop-handle-accum #*)))
+       (cl-push (list 'progn (list 'callf 'bvconcat var what) t) loop-body)))
 
      ((memq word '(sum summing))
       (let ((what (cl-pop args))
@@ -1654,12 +1654,12 @@ Any use of setq to set the value of the symbol while in the scope of this
 definition is treated as if it were a setf.
 A binding for a symbol macro can be shadowed by `let' or `symbol-macrolet'."
   (cond ((not (symbolp symbol))
-         (error "define-symbol-macro: %S is not a symbol"
-                symbol))
-        (t
-         `(progn
-            (put ',symbol 'symbol-macro ',expansion)
-            ',symbol))))
+        (error "define-symbol-macro: %S is not a symbol"
+               symbol))
+       (t
+        `(progn
+           (put ',symbol 'symbol-macro ',expansion)
+           ',symbol))))
 
 (defvar cl-closure-vars nil)
 ;;;###autoload
index 7568c06..da688b8 100644 (file)
@@ -143,11 +143,11 @@ printer proceeds to the next function on the list.")
 (defun print-custom-object (obj &optional stream pl)
   "Print custom object OBJ into STREAM using print level PL."
   (let ((cpfs custom-print-functions)
-        (ret nil))
+       (ret nil))
     (while cpfs
       (when (funcall (car cpfs) obj stream pl)
-        (setq cpfs nil
-              ret t))
+       (setq cpfs nil
+             ret t))
       (setq cpfs (cdr cpfs)))
     ret))
 
@@ -155,7 +155,7 @@ printer proceeds to the next function on the list.")
   "Print object OBJ not using custom printers."
   (let ((custom-object-printer nil))
     (princ obj stream)))
-  
+
 ;; Install custom printer
 (setq custom-object-printer 'print-custom-object)
 
@@ -212,7 +212,7 @@ used on lists."
 (defmacro pushnew (x place &rest keys)
   "(pushnew X PLACE): insert X at the head of the list stored in PLACE.
 Like (push X PLACE), except that the list is unmodified if X is `eql'
-to an element already on the list.  
+to an element already on the list.
 Keywords supported: :test :test-not :key"
   (if (symbolp place) (list 'setq place (list* 'adjoin x place keys))
     (list* 'callf2 'adjoin x place keys)))
index 1f7466d..1333fca 100644 (file)
@@ -1,7 +1,7 @@
 ;;; cmdloop.el --- support functions for the top-level command loop.
 
 ;; Copyright (C) 1992-4, 1997 Free Software Foundation, Inc.
+
 ;; Author: Richard Mlynarik
 ;; Date: 8-Jul-92
 ;; Maintainer: SXEmacs Development Team
@@ -158,14 +158,14 @@ or go back to just one window (by deleting all but the selected window)."
     (display-error error-object t)
 
     (if (noninteractive)
-        (progn
+       (progn
          (if old-debug-on-error
              (progn
                (message "Backtrace:\n\n")
                (backtrace)
                (message "\n")))
-          (message "%s exiting\n." emacs-program-name)
-          (kill-emacs -1)))
+         (message "%s exiting\n." emacs-program-name)
+         (kill-emacs -1)))
     t))
 
 (defun describe-last-error ()
@@ -199,10 +199,10 @@ or go back to just one window (by deleting all but the selected window)."
   (if (not (noninteractive))
       (enqueue-eval-event
        #'(lambda (arg)
-           (let ((tail (nthcdr 30 command-history)))
-             (if tail (setcdr tail nil)))
-           (let ((tail (nthcdr 30 values)))
-             (if tail (setcdr tail nil))))
+          (let ((tail (nthcdr 30 command-history)))
+            (if tail (setcdr tail nil)))
+          (let ((tail (nthcdr 30 values)))
+            (if tail (setcdr tail nil))))
        nil)))
 
 (add-hook 'pre-gc-hook 'truncate-command-history-for-gc)
@@ -261,20 +261,20 @@ or go back to just one window (by deleting all but the selected window)."
 
 (put 'file-error 'display-error
      #'(lambda (error-object stream)
-         (let ((tail (cdr error-object))
-               (first t))
-           (princ (car tail) stream)
-           (while (setq tail (cdr tail))
-             (princ (if first ": " ", ") stream)
-             (princ (car tail) stream)
-             (setq first nil)))))
+        (let ((tail (cdr error-object))
+              (first t))
+          (princ (car tail) stream)
+          (while (setq tail (cdr tail))
+            (princ (if first ": " ", ") stream)
+            (princ (car tail) stream)
+            (setq first nil)))))
 
 (put 'undefined-keystroke-sequence 'display-error
      #'(lambda (error-object stream)
-         (princ (key-description (car (cdr error-object))) stream)
+        (princ (key-description (car (cdr error-object))) stream)
         ;; #### I18N3: doesn't localize properly.
-         (princ (gettext " not defined.") stream) ; doo dah, doo dah.
-         ))
+        (princ (gettext " not defined.") stream) ; doo dah, doo dah.
+        ))
 
 \f
 (defcustom teach-extended-commands-p t
@@ -316,24 +316,24 @@ when called from Lisp."
   ;; Note:  This doesn't hack "this-command-keys"
   (let ((prefix-arg prefix-arg))
     (setq this-command (read-command
-                        ;; Note: this has the hard-wired
-                        ;;  "C-u" and "M-x" string bug in common
-                        ;;  with all GNU Emacs's.
+                       ;; Note: this has the hard-wired
+                       ;;  "C-u" and "M-x" string bug in common
+                       ;;  with all GNU Emacs's.
                        ;; (i.e. it prints C-u and M-x regardless of
                        ;; whether some other keys were actually bound
-                       ;; to `execute-extended-command' and 
+                       ;; to `execute-extended-command' and
                        ;; `universal-argument'.
-                        (cond ((eq prefix-arg '-)
-                               "- M-x ")
-                              ((equal prefix-arg '(4))
-                               "C-u M-x ")
-                              ((integerp prefix-arg)
-                               (format "%d M-x " prefix-arg))
-                              ((and (consp prefix-arg)
-                                    (integerp (car prefix-arg)))
-                               (format "%d M-x " (car prefix-arg)))
-                              (t
-                               "M-x ")))))
+                       (cond ((eq prefix-arg '-)
+                              "- M-x ")
+                             ((equal prefix-arg '(4))
+                              "C-u M-x ")
+                             ((integerp prefix-arg)
+                              (format "%d M-x " prefix-arg))
+                             ((and (consp prefix-arg)
+                                   (integerp (car prefix-arg)))
+                              (format "%d M-x " (car prefix-arg)))
+                             (t
+                              "M-x ")))))
 
   (if (and teach-extended-commands-p
           (interactive-p))
@@ -391,9 +391,9 @@ when called from Lisp."
 ;                (get _command 'disabled))
 ;           (run-hooks disabled-command-hook))
 ;          ((or (stringp _cmd) (vectorp _cmd))
-;           ;; If requested, place the macro in the command history.  
+;           ;; If requested, place the macro in the command history.
 ;           ;;  For other sorts of commands, call-interactively takes
-;           ;;  care of this. 
+;           ;;  care of this.
 ;           (if _record-flag
 ;               (setq command-history
 ;                     (cons (list 'execute-kbd-macro _cmd _prefix)
@@ -410,46 +410,46 @@ No confirmation of the answer is requested; a single character is enough.
 Also accepts Space to mean yes, or Delete to mean no."
   (save-excursion
     (let* ((pre "")
-           (yn (gettext "(y or n) "))
+          (yn (gettext "(y or n) "))
           ;; we need to translate the prompt ourselves because of the
           ;; strange way we handle it.
           (prompt (gettext prompt))
-           event)
+          event)
       (while (stringp yn)
-        (if (let ((cursor-in-echo-area t)
-                  (inhibit-quit t))
-              (message "%s%s%s" pre prompt yn)
-              (setq event (next-command-event event))
+       (if (let ((cursor-in-echo-area t)
+                 (inhibit-quit t))
+             (message "%s%s%s" pre prompt yn)
+             (setq event (next-command-event event))
              (condition-case nil
                  (prog1
                      (or quit-flag (eq 'keyboard-quit (key-binding event)))
                    (setq quit-flag nil))
                (wrong-type-argument t)))
-            (progn
-              (message "%s%s%s%s" pre prompt yn (single-key-description event))
-              (setq quit-flag nil)
-              (signal 'quit '())))
-        (let* ((keys (events-to-keys (vector event)))
+           (progn
+             (message "%s%s%s%s" pre prompt yn (single-key-description event))
+             (setq quit-flag nil)
+             (signal 'quit '())))
+       (let* ((keys (events-to-keys (vector event)))
               (def (lookup-key query-replace-map keys)))
-          (cond ((eq def 'skip)
-                 (message "%s%sNo" prompt yn)
+         (cond ((eq def 'skip)
+                (message "%s%sNo" prompt yn)
                 (setq yn nil))
-                ((eq def 'act)
-                 (message "%s%sYes" prompt yn)
+               ((eq def 'act)
+                (message "%s%sYes" prompt yn)
                 (setq yn t))
                ((eq def 'recenter)
                 (recenter))
                ((or (eq def 'quit) (eq def 'exit-prefix))
                 (signal 'quit '()))
-                ((button-release-event-p event) ; ignore them
-                 nil)
-                (t
-                 (message "%s%s%s%s" pre prompt yn
-                          (single-key-description event))
-                 (ding nil 'y-or-n-p)
-                 (discard-input)
-                 (if (= (length pre) 0)
-                     (setq pre (gettext "Please answer y or n.  ")))))))
+               ((button-release-event-p event) ; ignore them
+                nil)
+               (t
+                (message "%s%s%s%s" pre prompt yn
+                         (single-key-description event))
+                (ding nil 'y-or-n-p)
+                (discard-input)
+                (if (= (length pre) 0)
+                    (setq pre (gettext "Please answer y or n.  ")))))))
       yn)))
 
 (defun yes-or-no-p-minibuf (prompt)
@@ -460,18 +460,18 @@ The user must confirm the answer with RET,
 and can edit it until it has been confirmed."
   (save-excursion
     (let ((p (concat (gettext prompt) (gettext "(yes or no) ")))
-          (ans ""))
+         (ans ""))
       (while (stringp ans)
-        (setq ans (downcase (read-string p nil t))) ;no history
-        (cond ((string-equal ans (gettext "yes"))
-               (setq ans t))
-              ((string-equal ans (gettext "no"))
-               (setq ans nil))
-              (t
-               (ding nil 'yes-or-no-p)
-               (discard-input)
-               (message "Please answer yes or no.")
-               (sleep-for 2))))
+       (setq ans (downcase (read-string p nil t))) ;no history
+       (cond ((string-equal ans (gettext "yes"))
+              (setq ans t))
+             ((string-equal ans (gettext "no"))
+              (setq ans nil))
+             (t
+              (ding nil 'yes-or-no-p)
+              (discard-input)
+              (message "Please answer yes or no.")
+              (sleep-for 2))))
       ans)))
 
 (defun yes-or-no-p (prompt)
@@ -510,13 +510,13 @@ the `next-command-event' function instead."
          (and (event-matches-key-specifier-p event (quit-char))
               (signal 'quit nil)))
       (prog1 (or (event-to-character event)
-                 ;; Kludge.  If the event we read was a mouse-release,
-                 ;; discard it and read the next one.
-                 (if (button-release-event-p event)
-                     (event-to-character (next-command-event event)))
-                 (error "Key read has no ASCII equivalent %S" event))
-        ;; this is not necessary, but is marginally more efficient than GC.
-        (deallocate-event event)))))
+                ;; Kludge.  If the event we read was a mouse-release,
+                ;; discard it and read the next one.
+                (if (button-release-event-p event)
+                    (event-to-character (next-command-event event)))
+                (error "Key read has no ASCII equivalent %S" event))
+       ;; this is not necessary, but is marginally more efficient than GC.
+       (deallocate-event event)))))
 
 (defun read-char-exclusive ()
   "Read a character from the command input (keyboard or macro).
@@ -574,7 +574,7 @@ or three octal digits representing its character code."))
 ;          (logand 255 code))))
     ))
 
-(defun momentary-string-display (string pos &optional exit-char message) 
+(defun momentary-string-display (string pos &optional exit-char message)
   "Momentarily display STRING in the buffer at POS.
 Display remains until next character is typed.
 If the char is EXIT-CHAR (optional third arg, default is SPC) it is swallowed;
index 5eb3b65..9ee7887 100644 (file)
@@ -63,26 +63,26 @@ They means `lf', `crlf', and `cr' respectively."
       (setq eol-type (cond ((or (eq eol-type 'unix)
                                (eq eol-type 'lf))
                            'eol-lf)
-                           ((or (eq eol-type 'dos)
+                          ((or (eq eol-type 'dos)
                                (eq eol-type 'crlf))
                            'eol-crlf)
-                           ((or (eq eol-type 'mac)
+                          ((or (eq eol-type 'mac)
                                (eq eol-type 'cr))
                            'eol-cr)
-                           (t eol-type))))
+                          (t eol-type))))
   (let ((orig-eol-type (coding-system-eol-type coding-system)))
     (if (null orig-eol-type)
-        (if (not eol-type)
-            coding-system
-          (coding-system-property coding-system eol-type))
+       (if (not eol-type)
+           coding-system
+         (coding-system-property coding-system eol-type))
       (let ((base (coding-system-base coding-system)))
-        (if (not eol-type)
-            base
-          (if (= eol-type orig-eol-type)
-              coding-system
-            (setq orig-eol-type (coding-system-eol-type base))
-            (if (null orig-eol-type)
-                (coding-system-property base eol-type))))))))
+       (if (not eol-type)
+           base
+         (if (= eol-type orig-eol-type)
+             coding-system
+           (setq orig-eol-type (coding-system-eol-type base))
+           (if (null orig-eol-type)
+               (coding-system-property base eol-type))))))))
 
 
 (defun universal-coding-system-argument ()
index b63e4e1..1d2a0ef 100644 (file)
@@ -220,22 +220,22 @@ charsets."
             (let ((codesys (intern (buffer-substring
                                     (match-beginning 1)(match-end 1)))))
               (if (find-coding-system codesys) codesys)))
-        ;; (save-excursion
-        ;;   (let (start end)
-        ;;     (and (re-search-forward "^;+[ \t]*Local Variables:" nil t)
-        ;;          (setq start (match-end 0))
-        ;;          (re-search-forward "\n;+[ \t]*End:")
-        ;;          (setq end (match-beginning 0))
-        ;;          (save-restriction
-        ;;            (narrow-to-region start end)
-        ;;            (goto-char start)
-        ;;            (re-search-forward "^;;; coding: \\([^\n]+\\)$" nil t)
-        ;;            )
-        ;;          (let ((codesys
-        ;;                 (intern (buffer-substring
-        ;;                          (match-beginning 1)(match-end 1)))))
-        ;;            (if (find-coding-system codesys) codesys))
-        ;;          )))
+       ;; (save-excursion
+       ;;   (let (start end)
+       ;;     (and (re-search-forward "^;+[ \t]*Local Variables:" nil t)
+       ;;          (setq start (match-end 0))
+       ;;          (re-search-forward "\n;+[ \t]*End:")
+       ;;          (setq end (match-beginning 0))
+       ;;          (save-restriction
+       ;;            (narrow-to-region start end)
+       ;;            (goto-char start)
+       ;;            (re-search-forward "^;;; coding: \\([^\n]+\\)$" nil t)
+       ;;            )
+       ;;          (let ((codesys
+       ;;                 (intern (buffer-substring
+       ;;                          (match-beginning 1)(match-end 1)))))
+       ;;            (if (find-coding-system codesys) codesys))
+       ;;          )))
        (let ((case-fold-search nil))
          (if (search-forward
               ";;;###coding system: " (+ (point-min) 3000) t)
@@ -264,52 +264,52 @@ Return t if file exists."
         (handler (find-file-name-handler filename 'load))
         (path nil))
     (cond (handler
-           (funcall handler 'load filename noerror nomessage nosuffix))
-          ((<= (length filename) 0)
-           (and (null noerror)
-                (signal 'file-error (list "Cannot open load file" filename))))
-          ((setq path (locate-file filename load-path
-                                   (and (not nosuffix) '(".elc" ".el" ""))))
-           ;; now use the internal load to actually load the file.
-           (load-internal
-            file noerror nomessage nosuffix
-            (let ((elc
-                   ;; use string= instead of string-match to keep match-data.
-                   (string= ".elc" (downcase (substring path -4)))))
-              (or (and (not elc) coding-system-for-read) ; prefer for source file
-                  ;; find magic-cookie
-                  (save-excursion
-                    (set-buffer (get-buffer-create " *load*"))
-                    (erase-buffer)
-                    (let ((coding-system-for-read 'raw-text))
-                      (insert-file-contents path nil 0 3000))
-                    (find-coding-system-magic-cookie))
-                  (if elc
-                      ;; if reading a byte-compiled file and we didn't find
-                      ;; a coding-system magic cookie, then use `binary'.
-                      ;; We need to guarantee that we never do autodetection
-                      ;; on byte-compiled files because confusion here would
-                      ;; be a very bad thing.  Pre-existing byte-compiled
-                      ;; files are always in the `binary' coding system.
-                      ;; Also, byte-compiled files always use `lf' to terminate
-                      ;; a line; don't risk confusion here either.
-                      'binary
-                    (or (find-file-coding-system-for-read-from-filename path)
-                        ;; looking up in `file-coding-system-alist'.
-                        ;; otherwise use `buffer-file-coding-system-for-read',
-                        ;; as normal
-                        buffer-file-coding-system-for-read)
-                    )))))
-          ((setq path (locate-file filename load-path
-                                   (and (not nosuffix) 
+          (funcall handler 'load filename noerror nomessage nosuffix))
+         ((<= (length filename) 0)
+          (and (null noerror)
+               (signal 'file-error (list "Cannot open load file" filename))))
+         ((setq path (locate-file filename load-path
+                                  (and (not nosuffix) '(".elc" ".el" ""))))
+          ;; now use the internal load to actually load the file.
+          (load-internal
+           file noerror nomessage nosuffix
+           (let ((elc
+                  ;; use string= instead of string-match to keep match-data.
+                  (string= ".elc" (downcase (substring path -4)))))
+             (or (and (not elc) coding-system-for-read) ; prefer for source file
+                 ;; find magic-cookie
+                 (save-excursion
+                   (set-buffer (get-buffer-create " *load*"))
+                   (erase-buffer)
+                   (let ((coding-system-for-read 'raw-text))
+                     (insert-file-contents path nil 0 3000))
+                   (find-coding-system-magic-cookie))
+                 (if elc
+                     ;; if reading a byte-compiled file and we didn't find
+                     ;; a coding-system magic cookie, then use `binary'.
+                     ;; We need to guarantee that we never do autodetection
+                     ;; on byte-compiled files because confusion here would
+                     ;; be a very bad thing.  Pre-existing byte-compiled
+                     ;; files are always in the `binary' coding system.
+                     ;; Also, byte-compiled files always use `lf' to terminate
+                     ;; a line; don't risk confusion here either.
+                     'binary
+                   (or (find-file-coding-system-for-read-from-filename path)
+                       ;; looking up in `file-coding-system-alist'.
+                       ;; otherwise use `buffer-file-coding-system-for-read',
+                       ;; as normal
+                       buffer-file-coding-system-for-read)
+                   )))))
+         ((setq path (locate-file filename load-path
+                                  (and (not nosuffix)
                                        (if (boundp 'module-extensions)
                                            module-extensions))))
-           (if (featurep 'modules)
-               (let ((load-modules-quietly nomessage))
-                 (declare-fboundp (load-module path)))
-             (signal 'file-error '("This SXEmacs does not support modules"))))
+          (if (featurep 'modules)
+              (let ((load-modules-quietly nomessage))
+                (declare-fboundp (load-module path)))
+            (signal 'file-error '("This SXEmacs does not support modules"))))
          ((null noerror)
-           (signal 'file-error (list "Cannot open load file" filename))))))
+          (signal 'file-error (list "Cannot open load file" filename))))))
 
 (defvar insert-file-contents-access-hook nil
   "A hook to make a file accessible before reading it.
index 59da19d..728b9b4 100644 (file)
@@ -230,7 +230,7 @@ Output via `process-send-string' and input via buffer or filter (see
 `set-process-filter') are stream-oriented.  That means UDP datagrams are
 not guaranteed to be sent and received in discrete packets. (But small
 datagrams around 500 bytes that are not truncated by `process-send-string'
-are usually fine.)  Note further that UDP protocol does not guard against 
+are usually fine.)  Note further that UDP protocol does not guard against
 lost packets."
   (let (cs-r cs-w)
     (let (ret)
index 072fc4d..604f3b4 100644 (file)
@@ -181,7 +181,7 @@ be affected."
          (list fun args
                (nconc
                 (list 'list
-                      (list 'quote 
+                      (list 'quote
                             (intern (concat (symbol-name group) "-"
                                             (symbol-name fun)))))
                 args))
index 920cb93..cc877e4 100644 (file)
 (defun byte-compile-dest-file (filename)
   "Convert an Emacs Lisp source file name to a compiled file name."
   (let ((outfile (if (string-match lispdir-regexp filename)
-                     (file-name-sans-extension
-                      (substring filename (match-end 0)))
-                   filename)))
+                    (file-name-sans-extension
+                     (substring filename (match-end 0)))
+                  filename)))
     (expand-file-name (concat outfile ".elc") destdir)))
 
 (defun parse-command-line (cmdl)
   (let ((newcmdl (dllist))
-        (cmdlpl (make-skiplist))
-        (mm (compile-regexp "^--"))
-        (ign (compile-regexp "^-[^-]")))
+       (cmdlpl (make-skiplist))
+       (mm (compile-regexp "^--"))
+       (ign (compile-regexp "^-[^-]")))
     (while (car cmdl)
       (let* ((file (car cmdl))
-             (current (expand-file-name file sourcedir))
-             (current (if (file-exists-p current)
-                          current
-                        (expand-file-name file destdir))))
-        (cond ((string-match mm file)
-               (let ((key (intern file))
-                     (val (car (cdr-safe cmdl))))
-                 (put-skiplist cmdlpl key val)
-                 (setq cmdl (cdr-safe cmdl))))
-              ((string-match ign file)
-               (setq cmdl (cdr-safe cmdl)))
-              ((string-match emacs-lisp-file-regexp current)
-               (dllist-append newcmdl current))
-              (t nil)))
+            (current (expand-file-name file sourcedir))
+            (current (if (file-exists-p current)
+                         current
+                       (expand-file-name file destdir))))
+       (cond ((string-match mm file)
+              (let ((key (intern file))
+                    (val (car (cdr-safe cmdl))))
+                (put-skiplist cmdlpl key val)
+                (setq cmdl (cdr-safe cmdl))))
+             ((string-match ign file)
+              (setq cmdl (cdr-safe cmdl)))
+             ((string-match emacs-lisp-file-regexp current)
+              (dllist-append newcmdl current))
+             (t nil)))
       (setq cmdl (cdr-safe cmdl)))
     (put newcmdl :tweaks cmdlpl)
     newcmdl))
   (mapc-internal
    #'(lambda (file)
        (when (file-newer-than-file-p file (byte-compile-dest-file file))
-         (dllist-append files-to-compile file)))
+        (dllist-append files-to-compile file)))
    files))
 
 (setq problem-files (dllist))
 (mapc-internal
  #'(lambda (file)
      (condition-case nil
-         (byte-compile-file file)
+        (byte-compile-file file)
        (error
-        (progn
-          (dllist-append problem-files file)
-          (message "Dinn work: %s" file)))))
+       (progn
+         (dllist-append problem-files file)
+         (message "Dinn work: %s" file)))))
  files-to-compile)
 
 ;; (mapc-internal
index bca7b6c..302c717 100644 (file)
@@ -37,7 +37,7 @@ that the information is returned for; nil means the current console."
 
 (defun resume-pid-console (pid)
   "Resume the consoles with a controlling process of PID."
-  (mapc (lambda (c) 
+  (mapc (lambda (c)
          (if (and (eq (console-type c) 'tty)
                   (eql pid (console-tty-controlling-process c)))
              (resume-console c)))
index 8024079..27449e6 100644 (file)
@@ -304,8 +304,8 @@ Return a list suitable for use in `interactive'."
                obarray (lambda (symbol)
                          (and (boundp symbol)
                               (or (get symbol 'custom-type)
-                                  (user-variable-p symbol)))) 
-                t nil nil (and v (symbol-name v))))
+                                  (user-variable-p symbol))))
+               t nil nil (and v (symbol-name v))))
      (list (if (equal val "")
               (if (symbolp v) v nil)
             (intern val)))))
@@ -571,20 +571,20 @@ groups after non-groups, if nil do not order groups at all."
   "Set all modified options and save them."
   (interactive)
   (let ((all-children custom-options)
-        children)
+       children)
     (mapc (lambda (child)
            (when (memq (widget-get child :custom-state) '(modified set))
-              (push child children)))
-          all-children)
+             (push child children)))
+         all-children)
     (let ((the-children children)
-          child)
+         child)
       (while (setq child (pop the-children))
-        (widget-apply child :custom-pre-save)))
+       (widget-apply child :custom-pre-save)))
     (custom-save-all)
     (let ((the-children children)
-          child)
+         child)
       (while (setq child (pop the-children))
-        (widget-apply child :custom-post-save)))
+       (widget-apply child :custom-post-save)))
     ))
 
 (defvar custom-reset-menu
@@ -627,21 +627,21 @@ when the action is chosen.")
   "Reset all modified, set, or saved group members to their standard settings."
   (interactive)
   (let ((all-children custom-options)
-        children must-save)
+       children must-save)
     (mapc (lambda (child)
            (when (memq (widget-get child :custom-state) '(modified set saved))
-              (push child children)))
-          all-children)
+             (push child children)))
+         all-children)
     (let ((the-children children)
-          child)
+         child)
       (while (setq child (pop the-children))
-        (and (widget-apply child :custom-pre-reset-standard)
-             (setq must-save t))))
+       (and (widget-apply child :custom-pre-reset-standard)
+            (setq must-save t))))
     (and must-save (custom-save-all))
     (let ((the-children children)
-          child)
+         child)
       (while (setq child (pop the-children))
-        (widget-apply child :custom-post-reset-standard)))
+       (widget-apply child :custom-post-reset-standard)))
     ))
 
 \f
@@ -834,7 +834,7 @@ This means, in other words, variables defined with a `:version' keyword."
                       (and version
                            (or (null since-version)
                                (customize-version-lessp since-version
-                                                         version))))
+                                                        version))))
                     (push (list symbol 'custom-variable) found))))
     (unless found
       (error "No user options have changed defaults %s"
@@ -1762,7 +1762,7 @@ Backtrace follows:\n\n%s"
                     (return-from custom-load nil)))
               #'(lambda ()
                   (load (expand-file-name "custom-defines" dir))))))
-      ;; we get here only from the `return-from'; see above 
+      ;; we get here only from the `return-from'; see above
       (load source))))
 
 (defun custom-load-widget (widget)
@@ -2197,35 +2197,35 @@ Otherwise, look up symbol in `custom-guess-type-alist'."
 (defvar custom-variable-menu
   `(("Set for Current Session" custom-variable-set
      ,#'(lambda (widget)
-          (eq (widget-get widget :custom-state) 'modified)))
+         (eq (widget-get widget :custom-state) 'modified)))
     ("Save for Future Sessions" custom-variable-save
      ,#'(lambda (widget)
-          (memq (widget-get widget :custom-state)
-                '(modified set changed rogue))))
+         (memq (widget-get widget :custom-state)
+               '(modified set changed rogue))))
     ("Reset to Current" custom-redraw
      ,#'(lambda (widget)
-          (and (default-boundp (widget-value widget))
-               (memq (widget-get widget :custom-state) '(modified changed)))))
+         (and (default-boundp (widget-value widget))
+              (memq (widget-get widget :custom-state) '(modified changed)))))
     ("Reset to Saved" custom-variable-reset-saved
      ,#'(lambda (widget)
-          (and (or (get (widget-value widget) 'saved-value)
-                   (get (widget-value widget) 'saved-variable-comment))
-               (memq (widget-get widget :custom-state)
-                     '(modified set changed rogue)))))
+         (and (or (get (widget-value widget) 'saved-value)
+                  (get (widget-value widget) 'saved-variable-comment))
+              (memq (widget-get widget :custom-state)
+                    '(modified set changed rogue)))))
     ("Reset to Standard Settings" custom-variable-reset-standard
      ,#'(lambda (widget)
-          (and (get (widget-value widget) 'standard-value)
-               (memq (widget-get widget :custom-state)
-                     '(modified set changed saved rogue)))))
+         (and (get (widget-value widget) 'standard-value)
+              (memq (widget-get widget :custom-state)
+                    '(modified set changed saved rogue)))))
     ("---" ignore ignore)
     ("Add Comment" custom-comment-show custom-comment-invisible-p)
     ("---" ignore ignore)
     ("Don't show as Lisp expression" custom-variable-edit
      ,#'(lambda (widget)
-          (eq (widget-get widget :custom-form) 'lisp)))
+         (eq (widget-get widget :custom-form) 'lisp)))
     ("Show as Lisp expression" custom-variable-edit-lisp
      ,#'(lambda (widget)
-          (eq (widget-get widget :custom-form) 'edit))))
+         (eq (widget-get widget :custom-form) 'edit))))
   "Alist of actions for the `custom-variable' widget.
 Each entry has the form (NAME ACTION FILTER) where NAME is the name of
 the menu entry, ACTION is the function to call on the widget when the
@@ -2510,7 +2510,7 @@ value."
   :sample-face 'custom-face-tag-face
   :help-echo "Set or reset this face"
   :documentation-property #'(lambda (face)
-                              (face-doc-string face))
+                             (face-doc-string face))
   :value-create 'custom-face-value-create
   :action 'custom-face-action
   :custom-category 'face
@@ -2663,23 +2663,23 @@ value."
     ("Save for Future Sessions" custom-face-save)
     ("Reset to Saved" custom-face-reset-saved
      ,#'(lambda (widget)
-          (or (get (widget-value widget) 'saved-face)
-              (get (widget-value widget) 'saved-face-comment))))
+         (or (get (widget-value widget) 'saved-face)
+             (get (widget-value widget) 'saved-face-comment))))
     ("Reset to Standard Setting" custom-face-reset-standard
      ,#'(lambda (widget)
-          (get (widget-value widget) 'face-defface-spec)))
+         (get (widget-value widget) 'face-defface-spec)))
     ("---" ignore ignore)
     ("Add Comment" custom-comment-show custom-comment-invisible-p)
     ("---" ignore ignore)
     ("Show all display specs" custom-face-edit-all
      ,#'(lambda (widget)
-          (not (eq (widget-get widget :custom-form) 'all))))
+         (not (eq (widget-get widget :custom-form) 'all))))
     ("Just current attributes" custom-face-edit-selected
      ,#'(lambda (widget)
-          (not (eq (widget-get widget :custom-form) 'selected))))
+         (not (eq (widget-get widget :custom-form) 'selected))))
     ("Show as Lisp expression" custom-face-edit-lisp
      ,#'(lambda (widget)
-          (not (eq (widget-get widget :custom-form) 'lisp)))))
+         (not (eq (widget-get widget :custom-form) 'lisp)))))
   "Alist of actions for the `custom-face' widget.
 Each entry has the form (NAME ACTION FILTER) where NAME is the name of
 the menu entry, ACTION is the function to call on the widget when the
@@ -2840,9 +2840,9 @@ settings."
 (defun custom-face-post-reset-standard (widget)
   "Finish restoring the face edited by WIDGET to its standard settings."
   (let* ((symbol (widget-value widget))
-         (child (car (widget-get widget :children)))
-         (value (get symbol 'face-defface-spec))
-         (comment-widget (widget-get widget :comment-widget)))
+        (child (car (widget-get widget :children)))
+        (value (get symbol 'face-defface-spec))
+        (comment-widget (widget-get widget :comment-widget)))
     (face-spec-set symbol value nil '(custom))
     (put symbol 'face-comment nil)
     (widget-value-set child value)
@@ -3302,19 +3302,19 @@ If GROUPS-ONLY non-nil, return only those members that are groups."
 (defvar custom-group-menu
   `(("Set for Current Session" custom-group-set
      ,#'(lambda (widget)
-          (eq (widget-get widget :custom-state) 'modified)))
+         (eq (widget-get widget :custom-state) 'modified)))
     ("Save for Future Sessions" custom-group-save
      ,#'(lambda (widget)
-          (memq (widget-get widget :custom-state) '(modified set))))
+         (memq (widget-get widget :custom-state) '(modified set))))
     ("Reset to Current" custom-group-reset-current
      ,#'(lambda (widget)
-          (memq (widget-get widget :custom-state) '(modified))))
+         (memq (widget-get widget :custom-state) '(modified))))
     ("Reset to Saved" custom-group-reset-saved
      ,#'(lambda (widget)
-          (memq (widget-get widget :custom-state) '(modified set))))
+         (memq (widget-get widget :custom-state) '(modified set))))
     ("Reset to standard setting" custom-group-reset-standard
      ,#'(lambda (widget)
-          (memq (widget-get widget :custom-state) '(modified set saved)))))
+         (memq (widget-get widget :custom-state) '(modified set saved)))))
   "Alist of actions for the `custom-group' widget.
 Each entry has the form (NAME ACTION FILTER) where NAME is the name of
 the menu entry, ACTION is the function to call on the widget when the
@@ -3349,9 +3349,9 @@ Optional EVENT is the location for the menu."
   "Prepare for saving all modified group members."
   (let ((children (widget-get widget :children)))
     (mapc (lambda (child)
-            (when (memq (widget-get child :custom-state) '(modified set))
-              (widget-apply child :custom-pre-save)))
-          children)))
+           (when (memq (widget-get child :custom-state) '(modified set))
+             (widget-apply child :custom-pre-save)))
+         children)))
 
 (defun custom-group-post-save (widget)
   "Save all modified group members."
@@ -3387,13 +3387,13 @@ Optional EVENT is the location for the menu."
 (defun custom-group-pre-reset-standard (widget)
   "Prepare for resetting all modified, set, or saved group members."
   (let ((children (widget-get widget :children))
-        must-save)
+       must-save)
     (mapc (lambda (child)
-            (when (memq (widget-get child :custom-state)
-                        '(modified set saved))
-              (and (widget-apply child :custom-pre-reset-standard)
-                   (setq must-save t))))
-          children)
+           (when (memq (widget-get child :custom-state)
+                       '(modified set saved))
+             (and (widget-apply child :custom-pre-reset-standard)
+                  (setq must-save t))))
+         children)
     must-save
     ))
 
@@ -3460,40 +3460,40 @@ Leave the point at the end of the file."
   (goto-char (point-min))
   (condition-case nil
       (while (not (eobp))
-        (let ((sexp (read (current-buffer))))
-          (when (and (listp sexp)
-                     (memq (car sexp) symbols))
-            (delete-region (save-excursion
-                             (backward-sexp)
-                             (point))
-                           (point))
-            (while (and (eolp) (not (eobp)))
-              (delete-region (point) (prog2 (forward-line 1) (point))))
-            )))
+       (let ((sexp (read (current-buffer))))
+         (when (and (listp sexp)
+                    (memq (car sexp) symbols))
+           (delete-region (save-excursion
+                            (backward-sexp)
+                            (point))
+                          (point))
+           (while (and (eolp) (not (eobp)))
+             (delete-region (point) (prog2 (forward-line 1) (point))))
+           )))
     (end-of-file nil)))
 
 (defsubst custom-save-variable-p (symbol)
   "Return non-nil if symbol SYMBOL is a customized variable."
   (and (symbolp symbol)
        (let ((spec (car-safe (get symbol 'theme-value))))
-         (or (and spec (eq (car spec) 'user)
-                  (eq (second spec) 'set))
-             (get symbol 'saved-variable-comment)
-             ;; support non-themed vars
-             (and (null spec) (get symbol 'saved-value))))))
+        (or (and spec (eq (car spec) 'user)
+                 (eq (second spec) 'set))
+            (get symbol 'saved-variable-comment)
+            ;; support non-themed vars
+            (and (null spec) (get symbol 'saved-value))))))
 
 (defun custom-save-variable-internal (symbol)
   "Print variable SYMBOL to the standard output.
 SYMBOL must be a customized variable."
   (let ((requests (get symbol 'custom-requests))
-        (now (not (or (get symbol 'standard-value)
-                      (and (not (boundp symbol))
-                           (not (eq (get symbol 'force-value)
-                                    'rogue))))))
-        (comment (get symbol 'saved-variable-comment))
-        ;; Print everything, no placeholders `...'
-        (print-level nil)
-        (print-length nil))
+       (now (not (or (get symbol 'standard-value)
+                     (and (not (boundp symbol))
+                          (not (eq (get symbol 'force-value)
+                                   'rogue))))))
+       (comment (get symbol 'saved-variable-comment))
+       ;; Print everything, no placeholders `...'
+       (print-level nil)
+       (print-length nil))
     (unless (custom-save-variable-p symbol)
       (error 'wrong-type-argument "Not a customized variable" symbol))
     (princ "\n '(")
@@ -3504,10 +3504,10 @@ SYMBOL must be a customized variable."
     ;; (prin1 (third spec))
     ;; XEmacs -- pretty-print value if available
     (if (and custom-save-pretty-print
-             (fboundp 'pp))
-        ;; To suppress bytecompiler warning
-        (with-fboundp 'pp
-          (pp (car (get symbol 'saved-value))))
+            (fboundp 'pp))
+       ;; To suppress bytecompiler warning
+       (with-fboundp 'pp
+         (pp (car (get symbol 'saved-value))))
       (prin1 (car (get symbol 'saved-value))))
     (when (or now requests comment)
       (princ (if now " t" " nil")))
@@ -3534,18 +3534,18 @@ SYMBOL must be a customized variable."
      (custom-save-loaded-themes)
      (custom-save-resets 'theme-value 'custom-reset-variables nil)
      (let ((standard-output (current-buffer))
-           (sorted-list ()))
+          (sorted-list ()))
        ;; First create a sorted list of saved variables.
        (mapatoms
-        (lambda (symbol)
-          (when (custom-save-variable-p symbol)
-            (push symbol sorted-list))))
+       (lambda (symbol)
+         (when (custom-save-variable-p symbol)
+           (push symbol sorted-list))))
        (setq sorted-list (sort sorted-list 'string<))
        (unless (bolp)
         (princ "\n"))
        (princ "(custom-set-variables")
        (mapc 'custom-save-variable-internal
-             sorted-list)
+            sorted-list)
        (princ ")")
        (unless (looking-at "\n")
         (princ "\n")))))
@@ -3557,14 +3557,14 @@ SYMBOL must be a customized variable."
   (let ((theme-spec (car-safe (get symbol 'theme-face)))
        (comment (get symbol 'saved-face-comment)))
     (or (and (not (memq symbol custom-save-face-ignoring))
-             ;; Don't print default face here.
-             (or (and theme-spec
-                      (eq (car theme-spec) 'user)
-                      (eq (second theme-spec) 'set))
-                 ;; cope with non-themed faces
-                 (and (null theme-spec)
-                      (get symbol 'saved-face))))
-        comment)))
+            ;; Don't print default face here.
+            (or (and theme-spec
+                     (eq (car theme-spec) 'user)
+                     (eq (second theme-spec) 'set))
+                ;; cope with non-themed faces
+                (and (null theme-spec)
+                     (get symbol 'saved-face))))
+       comment)))
 
 (defun custom-save-face-internal (symbol)
   "Print face SYMBOL to the standard output.
@@ -3573,15 +3573,15 @@ SYMBOL must be a customized face."
        (now (not (or (get symbol 'face-defface-spec)
              (and (not (find-face symbol))
                   (not (eq (get symbol 'force-face) 'rogue))))))
-        ;; Print everything, no placeholders `...'
-        (print-level nil)
-        (print-length nil))
+       ;; Print everything, no placeholders `...'
+       (print-level nil)
+       (print-length nil))
     (if (memq symbol custom-save-face-ignoring)
-        ;; Do nothing
-        nil
+       ;; Do nothing
+       nil
       ;; Print face
       (unless (custom-save-face-p symbol)
-        (error 'wrong-type-argument "Not a customized face" symbol))
+       (error 'wrong-type-argument "Not a customized face" symbol))
       (princ "\n '(")
       (prin1 symbol)
       (princ " ")
@@ -3605,22 +3605,22 @@ SYMBOL must be a customized face."
     ;;                        'custom-set-faces)
     (custom-save-resets 'theme-face 'custom-reset-faces '(default))
     (let ((standard-output (current-buffer))
-          (sorted-list ()))
+         (sorted-list ()))
       ;; Create a sorted list of faces
       (mapatoms
        (lambda (symbol)
-         (when (custom-save-face-p symbol)
-           (push symbol sorted-list))))
+        (when (custom-save-face-p symbol)
+          (push symbol sorted-list))))
       (setq sorted-list (sort sorted-list 'string<))
       (unless (bolp)
        (princ "\n"))
       (princ "(custom-set-faces")
        ;; The default face must be first, since it affects the others.
       (when (custom-save-face-p 'default)
-        (custom-save-face-internal 'default))
+       (custom-save-face-internal 'default))
       (let ((custom-save-face-ignoring '(default)))
        (mapc 'custom-save-face-internal
-              sorted-list))
+             sorted-list))
       (princ ")")
       (unless (looking-at "\n")
        (princ "\n")))))
@@ -3629,35 +3629,35 @@ SYMBOL must be a customized face."
   "Create a mapper for `custom-save-resets'."
   `(lambda (object)
      (let ((spec (car-safe (get object (quote ,property))))
-           (print-level nil)
-           (print-length nil))
+          (print-level nil)
+          (print-length nil))
        (with-boundp '(ignored-special started-writing)
-         (when (and (not (memq object ignored-special))
-                    (eq (car spec) 'user)
-                    (eq (second spec) 'reset))
-           ;; Do not write reset statements unless necessary.
-           (unless started-writing
-             (setq started-writing t)
-             (unless (bolp)
-               (princ "\n"))
-             (princ "(")
-             (princ (quote ,setter))
-             (princ "\n '(")
-             (prin1 object)
-             (princ " ")
-             (prin1 (third spec))
-             (princ ")")))))))
+        (when (and (not (memq object ignored-special))
+                   (eq (car spec) 'user)
+                   (eq (second spec) 'reset))
+          ;; Do not write reset statements unless necessary.
+          (unless started-writing
+            (setq started-writing t)
+            (unless (bolp)
+              (princ "\n"))
+            (princ "(")
+            (princ (quote ,setter))
+            (princ "\n '(")
+            (prin1 object)
+            (princ " ")
+            (prin1 (third spec))
+            (princ ")")))))))
 
 (defconst custom-save-resets-mapper-alist
   (eval-when-compile
     (list (list 'theme-value 'custom-reset-variables
-                (byte-compile
-                 (make-custom-save-resets-mapper
-                  'theme-value 'custom-reset-variables)))
-          (list 'theme-face 'custom-reset-faces
-                (byte-compile
-                 (make-custom-save-resets-mapper
-                  'theme-face 'custom-reset-faces)))))
+               (byte-compile
+                (make-custom-save-resets-mapper
+                 'theme-value 'custom-reset-variables)))
+         (list 'theme-face 'custom-reset-faces
+               (byte-compile
+                (make-custom-save-resets-mapper
+                 'theme-face 'custom-reset-faces)))))
   "Never use it.
 Hashes several heavily used functions for `custom-save-resets'")
 
@@ -3667,9 +3667,9 @@ Hashes several heavily used functions for `custom-save-resets'")
     ;; (custom-save-delete setter) Done by caller
     (let ((standard-output (current-buffer))
          (mapper (let ((triple (assq property custom-save-resets-mapper-alist)))
-                    (if (and triple (eq (second triple) setter))
-                        (third triple)
-                      (make-custom-save-resets-mapper property setter)))))
+                   (if (and triple (eq (second triple) setter))
+                       (third triple)
+                     (make-custom-save-resets-mapper property setter)))))
       (mapc mapper special)
       (setq ignored-special special)
       (mapatoms mapper)
@@ -3680,8 +3680,8 @@ Hashes several heavily used functions for `custom-save-resets'")
 (defun custom-save-loaded-themes ()
   (let ((themes (reverse (get 'user 'theme-loads-themes)))
        (standard-output (current-buffer))
-        (print-level nil)
-        (print-length nil))
+       (print-level nil)
+       (print-length nil))
     (when themes
       (unless (bolp) (princ "\n"))
       (princ "(custom-load-themes")
@@ -3874,7 +3874,7 @@ Complete content of editable text field.   \\[widget-complete]
 Invoke button under point.                \\[widget-button-press]
 Set all modifications.                    \\[Custom-set]
 Make all modifications default.                   \\[Custom-save]
-Reset all modified options.               \\[Custom-reset-current]
+Reset all modified options.               \\[Custom-reset-current]
 Reset all modified or set options.        \\[Custom-reset-saved]
 Reset all options.                        \\[Custom-reset-standard]
 
index b473fbe..af468c8 100644 (file)
@@ -107,16 +107,16 @@ Control whether the text should be inverted.  Works only on TTY-s")
 ;      ;; filter to make value suitable for customize
 ;      (lambda (real-value)
 ;        (cond ((or (null real-value) (eq real-value 'unspecified))
-;            nil)
-;           ((symbolp real-value)
-;            (list real-value))
-;           (t
-;            real-value)))
+;            nil)
+;           ((symbolp real-value)
+;            (list real-value))
+;           (t
+;            real-value)))
 ;      ;; filter to make customized-value suitable for storing
 ;      (lambda (cus-value)
 ;        (if (and (consp cus-value) (null (cdr cus-value)))
-;         (car cus-value)
-;       cus-value))
+;         (car cus-value)
+;       cus-value))
      custom-set-face-inherit custom-face-inherit))
   "Alist of face attributes.
 
index 7790595..a604485 100644 (file)
             (max-specpdl-size limits integer)
             (meta-prefix-char keyboard character)
             (parse-sexp-ignore-comments editing-basics boolean)
-            (selective-display display 
+            (selective-display display
                                (choice (const :tag "off" nil)
                                        (integer :tag "space"
                                                 :format "%v"
            ;; If variables are removed from C code, give an error here!
            (message "Intrinsic `%S' not bound" symbol))
       ;; This is called before any user can have changed the value.
-      (put symbol 'standard-value 
+      (put symbol 'standard-value
           (list (quote-maybe (default-value symbol))))
       ;; Add it to the right group.
       (custom-add-to-group group symbol 'custom-variable)
index 06d7aca..39075d3 100644 (file)
@@ -78,8 +78,8 @@ symbol."
   (unless (default-boundp symbol)
     ;; Use the saved value if it exists, otherwise the standard setting.
     (set-default symbol (if (get symbol 'saved-value)
-                            (eval (car (get symbol 'saved-value)))
-                          (eval value)))))
+                           (eval (car (get symbol 'saved-value)))
+                         (eval value)))))
 
 (defun custom-initialize-set (symbol value)
   "Initialize SYMBOL with VALUE.
@@ -92,10 +92,10 @@ This is like `custom-initialize-default', but uses the function specified by
 `:set' to initialize SYMBOL."
   (unless (default-boundp symbol)
     (funcall (or (get symbol 'custom-set) 'set-default)
-             symbol
-             (if (get symbol 'saved-value)
-                 (eval (car (get symbol 'saved-value)))
-               (eval value)))))
+            symbol
+            (if (get symbol 'saved-value)
+                (eval (car (get symbol 'saved-value)))
+              (eval value)))))
 
 (defun custom-initialize-reset (symbol value)
   "Initialize SYMBOL with VALUE.
@@ -108,14 +108,14 @@ or (last of all) VALUE.
 Like `custom-initialize-set', but use the function specified by
 `:get' to reinitialize SYMBOL if it is already bound."
     (funcall (or (get symbol 'custom-set) 'set-default)
-             symbol
-             (cond ((default-boundp symbol)
-                    (funcall (or (get symbol 'custom-get) 'default-value)
-                             symbol))
-                   ((get symbol 'saved-value)
-                    (eval (car (get symbol 'saved-value))))
-                   (t
-                    (eval value)))))
+            symbol
+            (cond ((default-boundp symbol)
+                   (funcall (or (get symbol 'custom-get) 'default-value)
+                            symbol))
+                  ((get symbol 'saved-value)
+                   (eval (car (get symbol 'saved-value))))
+                  (t
+                   (eval value)))))
 
 ;; XEmacs change; move to defsubst, since this is only called in one place
 ;; and usage of it clusters.
@@ -125,16 +125,16 @@ Like `custom-initialize-reset', but only use the `:set' function if
 not using the standard setting.
 For the standard setting, use `set-default'."
   (cond ((default-boundp symbol)
-         (funcall (or (get symbol 'custom-set) 'set-default)
-                  symbol
-                  (funcall (or (get symbol 'custom-get) 'default-value)
-                           symbol)))
-        ((get symbol 'saved-value)
-         (funcall (or (get symbol 'custom-set) 'set-default)
-                  symbol
-                  (eval (car (get symbol 'saved-value)))))
-        (t
-         (set-default symbol (eval value)))))
+        (funcall (or (get symbol 'custom-set) 'set-default)
+                 symbol
+                 (funcall (or (get symbol 'custom-get) 'default-value)
+                          symbol)))
+       ((get symbol 'saved-value)
+        (funcall (or (get symbol 'custom-set) 'set-default)
+                 symbol
+                 (eval (car (get symbol 'saved-value)))))
+       (t
+        (set-default symbol (eval value)))))
 
 (defun custom-declare-variable (symbol default doc &rest args)
   "Like `defcustom', but SYMBOL and DEFAULT are evaluated as normal arguments.
@@ -169,11 +169,11 @@ keyword in your own programs.  "
     (while args
       (let ((arg (car args)))
        (setq args (cdr args))
-        (check-argument-type 'keywordp arg)
-        (let ((keyword arg)
-              (value (car args)))
-          (unless args
-            (signal 'error (list "Keyword is missing an argument" keyword)))
+       (check-argument-type 'keywordp arg)
+       (let ((keyword arg)
+             (value (car args)))
+         (unless args
+           (signal 'error (list "Keyword is missing an argument" keyword)))
          (setq args (cdr args))
          (cond ((eq keyword :initialize)
                 (setq initialize value))
@@ -193,10 +193,10 @@ keyword in your own programs.  "
                           value)
                   ;; Fast code for the common case.
                   (put symbol 'custom-options (copy-sequence value))))
-                ;; In the event that the byte compile has compiled the init
-                ;; value, we want the value the UI sees to be uncompiled.
-                ((eq keyword :default)
-                 (put symbol 'standard-value (list value)))
+               ;; In the event that the byte compile has compiled the init
+               ;; value, we want the value the UI sees to be uncompiled.
+               ((eq keyword :default)
+                (put symbol 'standard-value (list value)))
                (t
                 (custom-handle-keyword symbol keyword value
                                        'custom-variable))))))
@@ -221,37 +221,37 @@ The remaining arguments should have the form
 The following keywords are meaningful:
 
 :type  VALUE should be a widget type for editing the symbol's value.
-        The default is `sexp'.
+       The default is `sexp'.
 :options VALUE should be a list of valid members of the widget type.
 :group  VALUE should be a customization group.
-        Add SYMBOL to that group.
+       Add SYMBOL to that group.
 :link LINK-DATA
-        Include an external link after the documentation string for this
-        item.  This is a sentence containing an active field which
-        references some other documentation.
+       Include an external link after the documentation string for this
+       item.  This is a sentence containing an active field which
+       references some other documentation.
 
-        There are three alternatives you can use for LINK-DATA:
+       There are three alternatives you can use for LINK-DATA:
 
-        (custom-manual INFO-NODE)
-             Link to an Info node; INFO-NODE is a string which specifies
-             the node name, as in \"(emacs)Top\".  The link appears as
-             `[manual]' in the customization buffer.
+       (custom-manual INFO-NODE)
+            Link to an Info node; INFO-NODE is a string which specifies
+            the node name, as in \"(emacs)Top\".  The link appears as
+            `[manual]' in the customization buffer.
 
-        (info-link INFO-NODE)
-             Like `custom-manual' except that the link appears in the
-             customization buffer with the Info node name.
+       (info-link INFO-NODE)
+            Like `custom-manual' except that the link appears in the
+            customization buffer with the Info node name.
 
-        (url-link URL)
-             Link to a web page; URL is a string which specifies the URL.
-             The link appears in the customization buffer as URL.
+       (url-link URL)
+            Link to a web page; URL is a string which specifies the URL.
+            The link appears in the customization buffer as URL.
 
-        You can specify the text to use in the customization buffer by
-        adding `:tag NAME' after the first element of the LINK-DATA; for
-        example, (info-link :tag \"foo\" \"(emacs)Top\") makes a link to the
-        Emacs manual which appears in the buffer as `foo'.
+       You can specify the text to use in the customization buffer by
+       adding `:tag NAME' after the first element of the LINK-DATA; for
+       example, (info-link :tag \"foo\" \"(emacs)Top\") makes a link to the
+       Emacs manual which appears in the buffer as `foo'.
 
-        An item can have more than one external link; however, most items
-        have none at all.
+       An item can have more than one external link; however, most items
+       have none at all.
 :initialize
        VALUE should be a function used to initialize the
        variable.  It takes two arguments, the symbol and value
@@ -264,25 +264,25 @@ The following keywords are meaningful:
        The function takes one argument, a symbol, and should return
        the current value for that symbol.  The default choice of function
        is `custom-default-value'. #### XEmacs used to say `default-value';
-        is that right?
+       is that right?
 :require
        VALUE should be a feature symbol.  If you save a value
        for this option, then when your custom init file loads the value,
        it does (require VALUE) first.
 :version
-        VALUE should be a string specifying that the variable was
-        first introduced, or its default value was changed, in Emacs
-        version VERSION.
+       VALUE should be a string specifying that the variable was
+       first introduced, or its default value was changed, in Emacs
+       version VERSION.
 :tag LABEL
-        Use LABEL, a string, instead of the item's name, to label the item
-        in customization menus and buffers.
+       Use LABEL, a string, instead of the item's name, to label the item
+       in customization menus and buffers.
 :load FILE
-        Load file FILE (a string) before displaying this customization
-        item.  Loading is done with `load', and only if the file is
-        not already loaded.
+       Load file FILE (a string) before displaying this customization
+       item.  Loading is done with `load', and only if the file is
+       not already loaded.
 :set-after VARIABLES
        Specifies that SYMBOL should be set after the list of variables
-        VARIABLES when both have been customized.
+       VARIABLES when both have been customized.
 
 Read the section about customization in the Emacs Lisp manual for more
 information."
@@ -307,7 +307,7 @@ The remaining arguments should have the form
 The following KEYWORDs are defined:
 
 :group  VALUE should be a customization group.
-        Add FACE to that group.
+       Add FACE to that group.
 
 SPEC should be an alist of the form ((DISPLAY ATTS)...).
 
@@ -352,9 +352,9 @@ information."
       (setq args (cdr args))
       (check-argument-type 'keywordp arg)
       (let ((keyword arg)
-            (value (car args)))
-        (unless args
-          (signal 'error (list "Keyword is missing an argument" keyword)))
+           (value (car args)))
+       (unless args
+         (signal 'error (list "Keyword is missing an argument" keyword)))
        (setq args (cdr args))
        (cond ((eq keyword :prefix)
               (put symbol 'custom-prefix value))
@@ -386,7 +386,7 @@ The remaining arguments should have the form
 The following KEYWORDs are defined:
 
 :group  VALUE should be a customization group.
-        Add SYMBOL to that group.
+       Add SYMBOL to that group.
 
 Read the section about customization in the Emacs Lisp manual for more
 information."
@@ -438,11 +438,11 @@ Third argument TYPE is the custom option type."
       (setq args (cdr args))
       (check-argument-type 'keywordp arg)
       (let ((keyword arg)
-            (value (car args)))
-        (unless args
-          (signal 'error (list "Keyword is missing an argument" keyword)))
-        (setq args (cdr args))
-        (custom-handle-keyword symbol keyword value type)))))
+           (value (car args)))
+       (unless args
+         (signal 'error (list "Keyword is missing an argument" keyword)))
+       (setq args (cdr args))
+       (custom-handle-keyword symbol keyword value type)))))
 
 (defun custom-handle-keyword (symbol keyword value type)
   "For customization option SYMBOL, handle KEYWORD with VALUE.
@@ -457,7 +457,7 @@ Fourth argument TYPE is the custom option type."
         (custom-add-load symbol value))
        ((eq keyword :tag)
         (put symbol 'custom-tag value))
-       ((eq keyword :set-after)
+       ((eq keyword :set-after)
         (custom-add-dependencies symbol value))
        (t
         (signal 'error (list "Unknown keyword" keyword)))))
@@ -572,8 +572,8 @@ from THEME by `custom-make-theme-feature'."
       (check-argument-type 'keywordp arg)
       (let ((keyword arg)
            (value (car args)))
-        (unless args
-          (signal 'error (list "Keyword is missing an argument" keyword)))
+       (unless args
+         (signal 'error (list "Keyword is missing an argument" keyword)))
        (setq args (cdr args))
        (cond ((eq keyword :short-description)
               (put theme 'theme-short-description value))
@@ -670,38 +670,38 @@ area when toggling value.
 ARGS may also contain boolean :toggle-only, whose non-nil value
 means that only toggle command will be defined."
   (let ((msg (plist-get args :message))
-        (toggle-fun (or (get var 'toggle-function)
-                        (intern (format "toggle-%S" var))))
-        (turn-on-fun (or (get var 'turn-on-function)
-                         (intern (format "turn-on-%S" var))))
-        (turn-off-fun (or (get var 'turn-off-function)
-                          (intern (format "turn-off-%S" var))))
-        (toggle-only (plist-get args :toggle-only)))
+       (toggle-fun (or (get var 'toggle-function)
+                       (intern (format "toggle-%S" var))))
+       (turn-on-fun (or (get var 'turn-on-function)
+                        (intern (format "turn-on-%S" var))))
+       (turn-off-fun (or (get var 'turn-off-function)
+                         (intern (format "turn-off-%S" var))))
+       (toggle-only (plist-get args :toggle-only)))
     (mapc (lambda (p)
-            (setq args (plist-remprop args p)))
-          '(:message :toggle-only))
+           (setq args (plist-remprop args p)))
+         '(:message :toggle-only))
     `(progn
        (defcustom ,var ,value ,doc
-         :type 'boolean ,@args)
+        :type 'boolean ,@args)
        (put ',var 'toggle-variable t)
        (defun ,toggle-fun (arg)
-         ,(format "Toggle `%s' on or off." var)
-         (interactive "_P")
-         (customize-set-variable
-          ',var (if (null arg)
-                    (not ,var)
-                  (> (prefix-numeric-value arg) 0)))
-         ,(when msg
-            `(message "%S is %s" ',var (if ,var "ON" "OFF"))))
+        ,(format "Toggle `%s' on or off." var)
+        (interactive "_P")
+        (customize-set-variable
+         ',var (if (null arg)
+                   (not ,var)
+                 (> (prefix-numeric-value arg) 0)))
+        ,(when msg
+           `(message "%S is %s" ',var (if ,var "ON" "OFF"))))
        (unless ,toggle-only
-         (defun ,turn-on-fun ()
-           ,(format "Turn on `%s'." var)
-           (interactive)
-           (,toggle-fun 1))
-         (defun ,turn-off-fun ()
-           ,(format "Turn off `%s'." var)
-           (interactive)
-           (,toggle-fun -1))))))
+        (defun ,turn-on-fun ()
+          ,(format "Turn on `%s'." var)
+          (interactive)
+          (,toggle-fun 1))
+        (defun ,turn-off-fun ()
+          ,(format "Turn off `%s'." var)
+          (interactive)
+          (,toggle-fun -1))))))
 
 ;;; Initializing.
 
@@ -747,7 +747,7 @@ the list would contain an entry for the `user' theme, too.
 See `custom-known-themes' for a list of known themes."
   (let ((old (get symbol prop)))
     (if (eq (car-safe (car-safe old)) theme)
-        (setq old (cdr old)))
+       (setq old (cdr old)))
     (put symbol prop (cons (list theme mode value) old))))
 
 (defvar custom-local-buffer nil
@@ -827,14 +827,14 @@ in SYMBOL's list property `theme-value' \(using `custom-push-theme')."
                   (now (nth 2 entry))
                   (requests (nth 3 entry))
                   (comment (nth 4 entry))
-                   set)
+                  set)
              (when requests
                (put symbol 'custom-requests requests)
                (mapc 'require requests))
              (setq set (or (get symbol 'custom-set) 'custom-set-default))
              (put symbol 'saved-value (list value))
              (put symbol 'saved-variable-comment comment)
-              (custom-push-theme 'theme-value symbol theme 'set value)
+             (custom-push-theme 'theme-value symbol theme 'set value)
              ;; Allow for errors in the case where the setter has
            ;; changed between versions, say, but let the user know.
            (condition-case data
@@ -857,7 +857,7 @@ in SYMBOL's list property `theme-value' \(using `custom-push-theme')."
          (let ((symbol (nth 0 args))
                (value (nth 1 args)))
            (put symbol 'saved-value (list value))
-            (custom-push-theme 'theme-value symbol theme 'set value))
+           (custom-push-theme 'theme-value symbol theme 'set value))
          (setq args (cdr (cdr args))))))))
 
 (defun custom-set-default (variable value)
@@ -879,8 +879,8 @@ this sets the local binding in that buffer instead."
          (stringp sexp)
          (numberp sexp)
          (vectorp sexp)
-;;;      (and (fboundp 'characterp)
-;;;           (characterp sexp))
+;;;      (and (fboundp 'characterp)
+;;;           (characterp sexp))
          )
       sexp
     (list 'quote sexp)))
@@ -990,14 +990,14 @@ See `custom-known-themes' for a list of known themes."
     (mapatoms (lambda (symbol)
                ;; This works even if symbol is both a variable and a
                ;; face.
-                (setq spec-list (get symbol 'theme-value))
-                (when spec-list
-                  (put symbol 'theme-value (custom-remove-theme spec-list theme))
-                  (custom-theme-reset-internal symbol 'user))
-                (setq spec-list (get symbol 'theme-face))
-                (when spec-list
-                  (put symbol 'theme-face (custom-remove-theme spec-list theme))
-                  (custom-theme-reset-internal-face symbol 'user))))))
+               (setq spec-list (get symbol 'theme-value))
+               (when spec-list
+                 (put symbol 'theme-value (custom-remove-theme spec-list theme))
+                 (custom-theme-reset-internal symbol 'user))
+               (setq spec-list (get symbol 'theme-face))
+               (when spec-list
+                 (put symbol 'theme-face (custom-remove-theme spec-list theme))
+                 (custom-theme-reset-internal-face symbol 'user))))))
 
 (defun custom-theme-load-themes (by-theme &rest body)
   "Load the themes specified by BODY.
@@ -1061,9 +1061,9 @@ THEME-SPEC-LIST."
   ;; it might have gone away without the user knowing.
   (let ((value (cdr (assoc theme theme-spec-list))))
     (if value
-        (if (eq (car value) 'set)
-            (cdr value)
-          (custom-theme-value (cadr value) theme-spec-list)))))
+       (if (eq (car value) 'set)
+           (cdr value)
+         (custom-theme-value (cadr value) theme-spec-list)))))
 
 
 (defun custom-theme-variable-value (variable theme)
@@ -1081,14 +1081,14 @@ If SYMBOL is not defined in TO-THEME, reset SYMBOL to the standard
 value.  See `custom-theme-variable-value'.  The standard value is
 stored in SYMBOL's property `standard-value'."
   (let ((value (custom-theme-variable-value symbol to-theme))
-        was-in-theme)
+       was-in-theme)
     (setq was-in-theme value)
     (setq value (or value (get symbol 'standard-value)))
     (when value
       (put symbol 'saved-value was-in-theme)
       (if (or (get 'force-value symbol) (default-boundp symbol))
-          (funcall (or (get symbol 'custom-set) 'set-default) symbol
-                   (eval (car value)))))
+         (funcall (or (get symbol 'custom-set) 'set-default) symbol
+                  (eval (car value)))))
     value))
 
 
@@ -1103,8 +1103,8 @@ ARGS is a list of lists of the form
 This means reset VARIABLE to its value in TO-THEME."
   (custom-check-theme theme)
   (mapcar #'(lambda (arg)
-              (apply #'custom-theme-reset-internal arg)
-              (custom-push-theme 'theme-value (car arg) theme 'reset (cadr arg)))
+             (apply #'custom-theme-reset-internal arg)
+             (custom-push-theme 'theme-value (car arg) theme 'reset (cadr arg)))
          args))
 
 (defun custom-reset-variables (&rest args)
index e492f96..f34ea51 100644 (file)
@@ -121,12 +121,12 @@ The arguments to this command are as follow:
 
 CHILD:     the name of the command for the derived mode.
 PARENT:    the name of the command for the parent mode (e.g. `text-mode')
-           or nil if there is no parent.
+          or nil if there is no parent.
 NAME:      a string which will appear in the status line (e.g. \"Hypertext\")
 DOCSTRING: an optional documentation string--if you do not supply one,
-           the function will attempt to invent something useful.
+          the function will attempt to invent something useful.
 BODY:      forms to execute just before running the
-           hooks for the new mode.  Do not use `interactive' here.
+          hooks for the new mode.  Do not use `interactive' here.
 
 BODY can start with a bunch of keyword arguments.  The following keyword
   arguments are currently understood:
@@ -302,7 +302,7 @@ which more-or-less shadow %s's corresponding tables."
                    ", as the final step\nduring initialization.")))
 
     (unless (or (string-match (regexp-quote "\\{") docstring)
-                (string-match (regexp-quote "\\[") docstring))
+               (string-match (regexp-quote "\\[") docstring))
       ;; And don't forget to put the mode's keymap.
       (setq docstring (concat docstring "\n\n\\{" (symbol-name map) "}")))
 
index fcb1793..5df671e 100644 (file)
@@ -68,7 +68,7 @@ the terminal type will be inferred from the TERM environment variable.
   If CONTROLLING-PROCESS is non-nil, it should be an integer
 specifying the process id of the process in control of the specified tty.  If
 it is nil, it is assumes to be the value returned by emacs-pid."
-  (make-device 'tty tty (list 'terminal-type terminal-type 
+  (make-device 'tty tty (list 'terminal-type terminal-type
                              'controlling-process controlling-process)))
 
 (defun device-pixel-width (&optional device)
@@ -115,7 +115,7 @@ the toolbar, glyphs, etc."
 If DEVICE is not provided then the selected device is used."
   (or device (setq device (selected-device)))
   (or (symbolp name) (error "function name must be a symbol"))
-  (let ((devmeth (intern (concat (symbol-name 
+  (let ((devmeth (intern (concat (symbol-name
                                  (device-type device)) "-" (symbol-name name)))))
     (if (functionp devmeth)
        (if args
index 8c47c32..3b05a69 100644 (file)
@@ -44,7 +44,7 @@
                     're-search-backward
                   'search-backward))
               (glyph-image-property
-               (car (glyph-image-property 
+               (car (glyph-image-property
                      (nth 1 (glyph-image-property
                            search-dialog :items domain))
                      :items domain)) :text domain))
@@ -54,7 +54,7 @@
   "Popup a search dialog box."
   (interactive)
   (let ((parent (selected-frame)))
-    (make-dialog-box 
+    (make-dialog-box
      'general
      :parent parent
      :title "Search"
      :spec
      (setq search-dialog
           (make-glyph
-           `[layout 
-             :orientation horizontal 
-             :vertically-justify top 
-             :horizontally-justify center 
+           `[layout
+             :orientation horizontal
+             :vertically-justify top
+             :horizontally-justify center
              :border [string :data "Search"]
-             :items 
-             ([layout :orientation vertical 
+             :items
+             ([layout :orientation vertical
                       :justify top     ; implies left also
-                      :items 
+                      :items
                       ([string :data "Search for:"]
                        [button :descriptor "Match Case"
                                :style toggle
                                :callback-ex
                                (lambda (image-instance event)
                                  (isearch-dehighlight)
-                                 (delete-frame 
+                                 (delete-frame
                                   (event-channel event)))])])]))
      ;; These are no longer strictly necessary, but not setting a size
      ;; at all yields a much more noticeable resize since the initial
index 2081854..6f50ed8 100644 (file)
@@ -214,23 +214,23 @@ The keywords allowed are
    [ \"name\" callback <active-p> ]
    [ \"name\" callback <active-p> \"suffix\" ]
    [ \"name\" callback :<keyword> <value>  :<keyword> <value> ... ]
-  
+
   The name is the string to display on the button; it is filtered through the
   resource database, so it is possible for resources to override what string
   is actually displayed.
-  
+
   Accelerators can be indicated in the string by putting the sequence
   \"%_\" before the character corresponding to the key that will invoke
   the button.  Uppercase and lowercase accelerators are equivalent.  The
   sequence \"%%\" is also special, and is translated into a single %.
-  
+
   If the `callback' of a button is a symbol, then it must name a command.
   It will be invoked with `call-interactively'.  If it is a list, then it is
   evaluated with `eval'.
-  
+
   One (and only one) of the buttons may be `nil'.  This marker means that all
   following buttons should be flushright instead of flushleft.
-  
+
   Though the keyword/value syntax is supported for dialog boxes just as in
   popup menus, the only keyword which is both meaningful and fully implemented
   for dialog box buttons is `:active'.
@@ -300,20 +300,20 @@ name can change as a result of selecting a different printer device.  If
 a device is specified, then changes are stored into the settings object
 currently selected into that printer.  If a settings object is supplied,
 then changes are recorded into it, and, it is selected into a
-printer, then changes are propagated to that printer 
+printer, then changes are propagated to that printer
 too.
 
 Return value is nil if the user has canceled the dialog.  Otherwise, it
 is a new plist, with the following properties:
   name                   Printer device name, even if unchanged by the user.
   from-page              First page to print, 1-based.  Returned if
-                         `selected-page-button' is `pages'.
-                         user, then this value is not included in the plist.
+                        `selected-page-button' is `pages'.
+                        user, then this value is not included in the plist.
   to-page                Last page to print, inclusive, 1-based.  Returned if
-                         `selected-page-button' is `pages'.
+                        `selected-page-button' is `pages'.
   copies                 Number of copies to print.  Always returned.
   selected-page-button   Which page button was selected (`all', `selection',
-                         or `pages').
+                        or `pages').
 
 The DEVICE is destroyed and an error is signaled in case of
 initialization problem with the new printer.
@@ -497,13 +497,13 @@ See also the `print' dialog box type."
                     (set-face-background 'modeline [default background] frame)
                     ;; resize before mapping
                     (when cl-autosize
-                      (set-frame-pixel-size 
+                      (set-frame-pixel-size
                        frame
-                       (image-instance-width 
-                        (glyph-image-instance cl-spec 
+                       (image-instance-width
+                        (glyph-image-instance cl-spec
                                               (frame-selected-window frame)))
-                       (image-instance-height 
-                        (glyph-image-instance cl-spec 
+                       (image-instance-height
+                        (glyph-image-instance cl-spec
                                               (frame-selected-window frame)))))
                     ;; somehow, even though the resizing is supposed
                     ;; to be while the frame is not visible, a
index e7854dc..0d58c32 100644 (file)
@@ -83,7 +83,7 @@ redefine OBJECT if it is a symbol."
        (setq macro t
              obj (cdr obj)))
     (if (and (listp obj) (eq (car obj) 'byte-code))
-       (setq obj (list 'lambda nil obj)))      
+       (setq obj (list 'lambda nil obj)))
     (if (and (listp obj) (not (eq (car obj) 'lambda)))
        (error "not a function"))
     (if (consp obj)
@@ -135,10 +135,10 @@ redefine OBJECT if it is a symbol."
        (let ((interactive (if (consp obj)
                               (elt (assq 'interactive obj) 1)
                             (elt (compiled-function-interactive obj) 1))))
-          (if (eq (car-safe (car-safe obj)) 'interactive)
-              (setq obj (cdr obj)))
-          (indent-to indent)
-          (insert " interactive: ")
+         (if (eq (car-safe (car-safe obj)) 'interactive)
+             (setq obj (cdr obj)))
+         (indent-to indent)
+         (insert " interactive: ")
          (if (eq (car-safe interactive) 'byte-code)
              (progn
                (insert "\n")
index e64a327..c072bee 100644 (file)
      (princ "\nCharacter display glyph sequences:\n")
      (save-excursion
        (let ((vector (make-vector 256 nil))
-             (i 0))
-         (while (< i 256)
-           (aset vector i (aref dt i))
-           (incf i))
+            (i 0))
+        (while (< i 256)
+          (aset vector i (aref dt i))
+          (incf i))
         ;; FSF calls `describe-vector' here, but it is so incredibly
         ;; lame a function for that name that I cannot bring myself
         ;; to porting it.  Here is what `describe-vector' does:
    (list (cons fdt-locale
               (mapcar
                (lambda (fdt-x)
-                  (funcall fdt-function (cdr fdt-x))
-                  fdt-x)
+                 (funcall fdt-function (cdr fdt-x))
+                 fdt-x)
                (cdar (specifier-spec-list current-display-table
                                           fdt-locale)))))))
 
@@ -195,9 +195,9 @@ With prefix argument, enable European character display iff arg is positive."
   (frob-display-table
    (lambda (x)
      (if (or (<= (prefix-numeric-value arg) 0)
-             (and (null arg)
-                  (equal (aref x 160) (char-to-string 160))))
-         (standard-display-default-1 x 160 255)
+            (and (null arg)
+                 (equal (aref x 160) (char-to-string 160))))
+        (standard-display-default-1 x 160 255)
        (standard-display-8bit-1 x 160 255)))
    locale))
 
index d763ab0..594d9d3 100644 (file)
@@ -240,7 +240,7 @@ Finds files and URLs. Returns nil if object does not contain URL data."
                    (switch-to-buffer (find-file-noselect
                                       (substring (car data) 5))))
                   ;; to-do: open ftp URLs with efs...
-                  (t 
+                  (t
                    ;; some other URL, try to fire up some browser for it
                    (if-fboundp 'browse-url
                        (browse-url (car data))
@@ -266,7 +266,7 @@ Returns nil if object does not contain MIME data."
           ;; insert drops of text/* into buffer
           ;; create new buffer if pointer is outside buffer...
           ;; but there are many other ways...
-          ;;   
+          ;;
           ;; first thing: check if it's only text/plain and if the
           ;; drop happened inside some buffer. if yes insert it into
           ;; this buffer (hope it is not encoded in some MIME way)
@@ -345,7 +345,7 @@ compare."
 (defun experimental-dragdrop-drag (event object)
   "*{EXPERIMENTAL} The generic drag function.
 Tries to do the best with object in the selected protocol.
-Object must comply to the standart drag'n'drop object 
+Object must comply to the standart drag'n'drop object
 format."
   (error "Not implemented"))
 
index dd0dafa..b96c3ce 100644 (file)
@@ -36,7 +36,7 @@
 
   (when debug-paths
     (princ (format "SXEmacs thinks the roots of its hierarchy are:\n%S\n"
-                   roots)))
+                  roots)))
 
   (let* ((package-locations
          (packages-compute-package-locations
@@ -72,9 +72,9 @@
     (setq mule-lisp-directory '()))
 
   (setq ffi-lisp-directory
-        (when (fboundp #'ffi-defun)
-          (paths-find-ffi-lisp-directory roots
-                                         lisp-directory)))
+       (when (fboundp #'ffi-defun)
+         (paths-find-ffi-lisp-directory roots
+                                        lisp-directory)))
 
   (setq load-path (paths-construct-load-path roots
                                             '()
@@ -83,7 +83,7 @@
                                             lisp-directory
                                             nil
                                             mule-lisp-directory
-                                             ffi-lisp-directory))
+                                            ffi-lisp-directory))
 
   (setq exec-directory (paths-find-exec-directory roots))
   (if debug-paths
index c775066..c592c05 100644 (file)
@@ -8,14 +8,14 @@ in dumped-lisp.el and is not itself listed.")
 
 (setq preloaded-file-list
       (assemble-list
-        "backquote"            ; needed for defsubst etc.
+       "backquote"             ; needed for defsubst etc.
        "bytecomp-runtime"      ; define defsubst
        "find-paths"
        "packages"              ; Bootstrap run-time lisp environment
        "setup-paths"
        "dump-paths"
-       "subr"                  ; load the most basic Lisp functions
-       "replace"               ; match-string used in version.el.
+       "subr"                  ; load the most basic Lisp functions
+       "replace"               ; match-string used in version.el.
        ; Ignore compiled-by-mistake version.elc
        "version.el"
        "cl"
@@ -50,7 +50,7 @@ in dumped-lisp.el and is not itself listed.")
        "simple"
        "keydefs"               ; Before loaddefs so that keymap vars exist.
        "abbrev"
-        "number"
+       "number"
        "derived"
        "minibuf"
        "list-mode"
@@ -68,7 +68,7 @@ in dumped-lisp.el and is not itself listed.")
        "lisp-initd"
        "misc"
        "loadhist"              ; Must be dumped before loaddefs is loaded
-                               ; Used by help. 
+                               ; Used by help.
        ;; (pureload "profile")
        (unless-feature mule "help-nomule")
        "help"
@@ -214,9 +214,9 @@ in dumped-lisp.el and is not itself listed.")
 
 ;; preload the TTY init code.
        (when-feature tty "tty-init")
-        "x-color"
-        "cus-face"
-        "font-lock"
+       "x-color"
+       "cus-face"
+       "font-lock"
        "fontl-hooks"
        "auto-show"
        (when-feature ldap "ldap")
index f75d187..1bc9a60 100644 (file)
@@ -172,7 +172,7 @@ BODY contains code that will be executed each time the mode is (de)activated.
   These following keyword arguments are supported:
 :group GROUP   Custom group name to use in all generated `defcustom' forms.
 :global GLOBAL If non-nil specifies that the minor mode is not meant to be
-               buffer-local, so don't make the variable MODE buffer-local.
+               buffer-local, so don't make the variable MODE buffer-local.
                By default, the mode is buffer-local.
 :init-value VAL        Same as the INIT-VALUE argument.
 :lighter SPEC  Same as the LIGHTER argument.
@@ -184,7 +184,7 @@ other hook.
 MODE-hook: run if the mode is toggled.
 MODE-on-hook: run if the mode is activated.
 MODE-off-hook: run if the mode is deactivated.
+
 \(defmacro easy-mmode-define-minor-mode
   (MODE DOC &optional INIT-VALUE LIGHTER KEYMAP &rest BODY)...\)
 
@@ -238,12 +238,12 @@ For example, you could write
     ;; Add default properties to LIGHTER.
 ;; #### FSF comments this out in 21.3.
 ;     (unless (or (not (stringp lighter))
-;              (get-text-property 0 'local-map lighter)
-;              (get-text-property 0 'keymap lighter))
+;              (get-text-property 0 'local-map lighter)
+;              (get-text-property 0 'keymap lighter))
 ;       (setq lighter
-;          (propertize lighter
-;                      'local-map modeline-minor-mode-map ; XEmacs change
-;                      'help-echo "mouse-3: minor mode menu")))
+;          (propertize lighter
+;                      'local-map modeline-minor-mode-map ; XEmacs change
+;                      'help-echo "mouse-3: minor mode menu")))
 
     `(progn
        ;; Define the variable to enable or disable the mode.
index f78e0e3..b8dbec8 100644 (file)
@@ -128,7 +128,7 @@ STYLE is a symbol describing the type of menu item.  The following are
 defined:
 
 toggle: A checkbox.
-        Currently just prepend the name with the string \"Toggle \".
+       Currently just prepend the name with the string \"Toggle \".
 radio: A radio button.
 nil: An ordinary menu item.
 
index 06c1128..a885097 100644 (file)
@@ -38,7 +38,7 @@
 ;; IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 ;;; Commentary:
-;; 
+;;
 ;;    Here are a number of utils for interacting with emodules, such
 ;;    as finding them, loading them.  That sort of thing.
 ;;
@@ -46,7 +46,7 @@
 
 ;;; Todo:
 ;;
-;;     
+;;
 
 ;;; Code:
 (defvar emodule-completions nil
index c619a9c..357e7d0 100644 (file)
@@ -118,7 +118,7 @@ match.
 
 If the CDR of the elements of this list are strings, then they are
 assumed to name a TAGS file.  If they name a directory, then the string
-\"TAGS\" is appended to them to get the file name.  If they are not 
+\"TAGS\" is appended to them to get the file name.  If they are not
 strings, then they are evaluated, and must return an appropriate string.
 
 For example:
@@ -141,7 +141,7 @@ If the buffer-local variable `buffer-tag-table' is set, then it names a tags
 table that is searched before all others when find-tag is executed from this
 buffer.
 
-If there is a file called \"TAGS\" in the same directory as the file in 
+If there is a file called \"TAGS\" in the same directory as the file in
 question, then that tags file will always be used as well (after the
 `buffer-tag-table' but before the tables specified by this list.)
 
@@ -174,7 +174,7 @@ If nil, prompt whether to re-read the changed TAGS file."
   :group 'etags)
 
 (defcustom make-tags-files-invisible nil
-  "*If non-nil, TAGS-files will not show up in buffer-lists or be 
+  "*If non-nil, TAGS-files will not show up in buffer-lists or be
 selectable (or deletable.)"
   :type 'boolean
   :group 'etags)
@@ -193,7 +193,7 @@ This affects the `tags-search' and `tags-query-replace' commands."
 (defcustom tags-exuberant-ctags-optimization-p nil
   "*If this variable is nil (the default), then exact tag search is able
 to find tag names in the name part of the tagtable (enclosed by  ^?..^A)
-and in the sourceline part of the tagtable ( enclosed by ^..^?). 
+and in the sourceline part of the tagtable ( enclosed by ^..^?).
 This is needed by xemacs etags as not every tag has a name field.
 It is slower for large tables and less precise than the other option.
 
@@ -208,7 +208,7 @@ entry for every tag."
 ;; Buffer tag tables.
 
 (defun buffer-tag-table-list ()
-  "Returns a list (ordered) of the tags tables which should be used for 
+  "Returns a list (ordered) of the tags tables which should be used for
 the current buffer."
   (let (result)
     ;; Explicitly set buffer-tag-table
@@ -289,7 +289,7 @@ A directory name is ok too; it means file TAGS in that directory."
                                     default-directory
                                     (expand-file-name "TAGS" default-directory)
                                     t)))
-  (if (string-equal file "") 
+  (if (string-equal file "")
       (setq tags-file-name nil)
     (setq file (expand-file-name file))
     (when (file-directory-p file)
@@ -474,7 +474,7 @@ File name returned is relative to tag table file's directory."
        #'string<))
 
 (defun buffer-tag-table-files ()
-  "Returns a list of all files referenced by all TAGS tables that 
+  "Returns a list of all files referenced by all TAGS tables that
 this buffer uses."
   (when (zerop (bloom-size tag-table-files-bloom))
     (tag-loop for table in (buffer-tag-table-list)
@@ -697,7 +697,7 @@ If it returns non-nil, this file needs processing by evalling
 (autoload 'get-symbol-syntax-table "symbol-syntax")
 
 (defun find-tag-internal (tagname)
-  
+
   (let ((next (null tagname))
        (tmpnext (null tagname))
        ;; If tagname is a list: (TAGNAME), this indicates
@@ -719,7 +719,7 @@ If it returns non-nil, this file needs processing by evalling
           (setq tag-table-currently-matching-exact t)))
     ;; \_ in the tagname is used to indicate a symbol boundary.
     (if tags-exuberant-ctags-optimization-p
-        (setq exact-tagname (format "\C-?%s\C-a" tagname))
+       (setq exact-tagname (format "\C-?%s\C-a" tagname))
       (setq exact-tagname (format "\C-?%s\C-a\\|\
 \\_%s.?\C-?[0-9]*,[0-9]*$" tagname tagname))
       )
@@ -997,14 +997,14 @@ Value is nil if the file was already visited;
 if the file was newly read in, the value is the filename."
   (interactive "P")
   (cond ((not initialize)
-         ;; Not the first run.
-         )
-        ((eq initialize t)
-         ;; Initialize the list from the tags table.
+        ;; Not the first run.
+        )
+       ((eq initialize t)
+        ;; Initialize the list from the tags table.
         (setq next-file-list (buffer-tag-table-files)))
-        (t
-         ;; Initialize the list by evalling the argument.
-         (setq next-file-list (eval initialize))))
+       (t
+        ;; Initialize the list by evalling the argument.
+        (setq next-file-list (eval initialize))))
   (when (null next-file-list)
     (and novisit
         (get-buffer " *next-file*")
@@ -1016,7 +1016,7 @@ if the file was newly read in, the value is the filename."
     (pop next-file-list)
 
     (if (not (and new novisit))
-        (switch-to-buffer (find-file-noselect file novisit) t)
+       (switch-to-buffer (find-file-noselect file novisit) t)
       ;; Like find-file, but avoids random junk.
       (set-buffer (get-buffer-create " *next-file*"))
       (kill-all-local-variables)
@@ -1041,7 +1041,7 @@ If the latter returns non-nil, we exit; otherwise we scan the next file."
   (interactive)
   (let ((messaged nil)
        (more-files-p t)
-        new)
+       new)
     (while more-files-p
       ;; Scan files quickly for the first or next interesting one.
       (while (or first-time
@@ -1075,8 +1075,8 @@ If the latter returns non-nil, we exit; otherwise we scan the next file."
       ;; If value is non-nil, continue to scan the next file.
       (setq more-files-p (eval tags-loop-operate)))
     (and messaged
-         (null tags-loop-operate)
-         (message "Scanning file %s...found" buffer-file-name))))
+        (null tags-loop-operate)
+        (message "Scanning file %s...found" buffer-file-name))))
 
 ;;;###autoload
 (defun tags-search (regexp &optional file-list-form)
@@ -1087,13 +1087,13 @@ To continue searching for next match, use command \\[tags-loop-continue].
 See documentation of variable `tag-table-alist'."
   (interactive "sTags search (regexp): ")
   (if (and (equal regexp "")
-           (eq (car tags-loop-scan) 'with-search-caps-disable-folding)
-           (null tags-loop-operate))
+          (eq (car tags-loop-scan) 'with-search-caps-disable-folding)
+          (null tags-loop-operate))
       ;; Continue last tags-search as if by `M-,'.
       (tags-loop-continue nil)
     (setq tags-loop-scan `(with-search-caps-disable-folding ,regexp t
-                            (re-search-forward ,regexp nil t))
-          tags-loop-operate nil)
+                           (re-search-forward ,regexp nil t))
+         tags-loop-operate nil)
     (tags-loop-continue (or file-list-form t))))
 
 ;;;###autoload
@@ -1107,13 +1107,13 @@ See documentation of variable `tag-table-alist'."
   (interactive
    "sTags query replace (regexp): \nsTags query replace %s by: \nP")
   (setq tags-loop-scan `(with-search-caps-disable-folding ,from t
-                          (if (re-search-forward ,from nil t)
-                              ;; When we find a match, move back
-                              ;; to the beginning of it so perform-replace
-                              ;; will see it.
-                              (progn (goto-char (match-beginning 0)) t)))
-        tags-loop-operate (list 'perform-replace from to t t 
-                                (not (null delimited))))
+                         (if (re-search-forward ,from nil t)
+                             ;; When we find a match, move back
+                             ;; to the beginning of it so perform-replace
+                             ;; will see it.
+                             (progn (goto-char (match-beginning 0)) t)))
+       tags-loop-operate (list 'perform-replace from to t t
+                               (not (null delimited))))
    (tags-loop-continue (or file-list-form t)))
 \f
 ;; Miscellaneous
index 83cc777..83e5437 100644 (file)
@@ -130,7 +130,7 @@ See `keyboard-translate-table' for more information."
  ;; bindings of the corresponding keys by default, but that made the display
  ;; of M-x describe-bindings much harder to read, so now we'll just bind them
  ;; to self-insert by default.  Not a big difference...
+
 (put 'kp-0 'ascii-character ?0)
 (put 'kp-1 'ascii-character ?1)
 (put 'kp-2 'ascii-character ?2)
index a2fbc3d..8f858ed 100644 (file)
@@ -43,16 +43,16 @@ PROPERTY, and VALUE may also be used to control the extents passed to
 PREDICATE or FUNCTION.  See also `map-extents'."
   (let (*result*)
     (map-extents (if predicate
-                     #'(lambda (ex junk)
-                         (and (funcall predicate ex)
-                              (setq *result* (cons (funcall function ex)
-                                                   *result*)))
-                         nil)
-                   #'(lambda (ex junk)
-                         (setq *result* (cons (funcall function ex)
-                                              *result*))
-                         nil))
-                 buffer-or-string from to nil flags property value)
+                    #'(lambda (ex junk)
+                        (and (funcall predicate ex)
+                             (setq *result* (cons (funcall function ex)
+                                                  *result*)))
+                        nil)
+                  #'(lambda (ex junk)
+                        (setq *result* (cons (funcall function ex)
+                                             *result*))
+                        nil))
+                buffer-or-string from to nil flags property value)
     (nreverse *result*)))
 
 (defun extent-list (&optional buffer-or-string from to flags property value)
index 63ae037..6649204 100644 (file)
@@ -291,51 +291,51 @@ If PROPERTY is not a built-in property, then this function will
 The following symbols have predefined meanings:
 
  foreground         The foreground color of the face.
-                    For valid instantiators, see `make-color-specifier'.
+                   For valid instantiators, see `make-color-specifier'.
 
  background         The background color of the face.
-                    For valid instantiators, see `make-color-specifier'.
+                   For valid instantiators, see `make-color-specifier'.
 
  font               The font used to display text covered by this face.
-                    For valid instantiators, see `make-font-specifier'.
+                   For valid instantiators, see `make-font-specifier'.
 
  display-table      The display table of the face.
-                    This should be a vector of 256 elements.
+                   This should be a vector of 256 elements.
 
  background-pixmap  The pixmap displayed in the background of the face.
-                    Only used by faces on X and MS Windows devices.
-                    For valid instantiators, see `make-image-specifier'.
+                   Only used by faces on X and MS Windows devices.
+                   For valid instantiators, see `make-image-specifier'.
 
  underline          Underline all text covered by this face.
-                    For valid instantiators, see `make-face-boolean-specifier'.
+                   For valid instantiators, see `make-face-boolean-specifier'.
 
  strikethru         Draw a line through all text covered by this face.
-                    For valid instantiators, see `make-face-boolean-specifier'.
+                   For valid instantiators, see `make-face-boolean-specifier'.
 
  highlight          Highlight all text covered by this face.
-                    Only used by faces on TTY devices.
-                    For valid instantiators, see `make-face-boolean-specifier'.
+                   Only used by faces on TTY devices.
+                   For valid instantiators, see `make-face-boolean-specifier'.
 
  dim                Dim all text covered by this face.
-                    For valid instantiators, see `make-face-boolean-specifier'.
+                   For valid instantiators, see `make-face-boolean-specifier'.
 
  blinking           Blink all text covered by this face.
-                    Only used by faces on TTY devices.
-                    For valid instantiators, see `make-face-boolean-specifier'.
+                   Only used by faces on TTY devices.
+                   For valid instantiators, see `make-face-boolean-specifier'.
 
  reverse            Reverse the foreground and background colors.
-                    Only used by faces on TTY devices.
-                    For valid instantiators, see `make-face-boolean-specifier'.
+                   Only used by faces on TTY devices.
+                   For valid instantiators, see `make-face-boolean-specifier'.
 
  inherit           Face name or face object from which to inherit attributes,
-                    or a list of such elements.  Attributes from inherited
-                    faces are merged into the face like an underlying face
-                    would be, with higher priority than underlying faces.
+                   or a list of such elements.  Attributes from inherited
+                   faces are merged into the face like an underlying face
+                   would be, with higher priority than underlying faces.
 
  doc-string         Description of what the face's normal use is.
-                    NOTE: This is not a specifier, unlike all
-                    the other built-in properties, and cannot
-                    contain locale-specific values."
+                   NOTE: This is not a specifier, unlike all
+                   the other built-in properties, and cannot
+                   contain locale-specific values."
 
   (setq face (get-face face))
   (if (memq property built-in-face-specifiers)
@@ -764,8 +764,8 @@ See `face-property-instance' for the semantics of the DOMAIN argument."
     (and (face-equal-loop common-props face1 face2 domain)
         (cond ((eq 'tty (device-type device))
                (face-equal-loop tty-props face1 face2 domain))
-              ;; #### Why isn't this (console-on-window-system-p (device-console device))?
-              ;; #### FIXME!
+              ;; #### Why isn't this (console-on-window-system-p (device-console device))?
+              ;; #### FIXME!
               ((eq 'x (device-type device))
                (face-equal-loop win-props face1 face2 domain))
               (t t)))))
@@ -852,7 +852,7 @@ the function to be called on it."
          (when (not (specifier-specs temp-sp 'global))
            ;; Try fallback via the official ways and then do it "by hand"
            (let* ((fallback (specifier-fallback sp))
-                  (fallback-sp 
+                  (fallback-sp
                    (cond ((specifierp fallback) fallback)
                          ;; just an inst list
                          (fallback
@@ -917,8 +917,8 @@ the function to be called on it."
              (if (not first-valid)
                  (setq first-valid inst-pair))
              (setq result (funcall func sp-inst device))
-              (if result
-                  (setq result (cons tag-set result))))))
+             (if result
+                 (setq result (cons tag-set result))))))
       (setq inst-list (cdr inst-list)))
     (or result first-valid)))
 
@@ -1164,7 +1164,7 @@ specifics on exactly how this function works."
 
 ;; Size frobbing
 ;; Thx Jan Vroonhof, Ref xemacs-beta <87oflypbum.fsf@petteflet.ntlworld.com>
-;; Jan had a separate helper function 
+;; Jan had a separate helper function
 (defun make-face-size (face size &optional locale tags)
   "Adjust FACE to SIZE in LOCALE, if possible.
 
@@ -1681,7 +1681,7 @@ This is an Emacs compatibility function; consider using
 set-face-background-pixmap instead.
 
 PIXMAP should be a string, the name of a file of pixmap data.
-The directories listed in the variable `x-bitmap-file-path' 
+The directories listed in the variable `x-bitmap-file-path'
 under X is searched.
 
 Alternatively, PIXMAP may be a list of the form (WIDTH HEIGHT
index 69e863d..274a366 100644 (file)
   (globally-declare-fboundp
    '(ffi-size-of-type make-ffi-object ffi-canonicalise-type
                      ffi-basic-type-p ffi-load-library ffi-dlerror
-                      ffi-object-type ffi-fetch ffi-slot-offset
-                      ffi-store ffi-aref ffi-make-pointer
-                      ffi-object-address ffi-call-function
-                      ffi-defun ffi-bind)))
+                     ffi-object-type ffi-fetch ffi-slot-offset
+                     ffi-store ffi-aref ffi-make-pointer
+                     ffi-object-address ffi-call-function
+                     ffi-defun ffi-bind)))
 
 \f
 (require 'alist)
   "Create a foreign object of TYPE and set its value to VAL.
 Return created FFI object."
   (let* ((ctype (ffi-canonicalise-type type))
-         (size (cond ((or (eq ctype 'c-string) (eq ctype 'c-data))
-                      (1+ (length val)))
-                     ((and (consp ctype) (eq (car ctype) 'c-data)
-                           (intp (cdr ctype)))
-                      (cdr ctype))
-                     (t
-                      (ffi-size-of-type ctype))))
-         (fo (make-ffi-object type size)))
+        (size (cond ((or (eq ctype 'c-string) (eq ctype 'c-data))
+                     (1+ (length val)))
+                    ((and (consp ctype) (eq (car ctype) 'c-data)
+                          (intp (cdr ctype)))
+                     (cdr ctype))
+                    (t
+                     (ffi-size-of-type ctype))))
+        (fo (make-ffi-object type size)))
     (ffi-set fo val)
     fo))
 
@@ -117,7 +117,7 @@ BODY should use `value' to reference typed value."
 (defmacro ffi-translate-foreign (value type translators)
   `(let ((translator (assq ,type ,translators)))
      (if translator
-         (eval (cdr translator))
+        (eval (cdr translator))
        value)))
 
 (defun ffi-translate-to-foreign (value type)
@@ -137,20 +137,20 @@ BODY should use `value' to reference typed value."
 
     ;; Try to get name from union or struct
     (when (and (null name)
-               (listp type)
-               (memq (car type) '(struct union)))
+              (listp type)
+              (memq (car type) '(struct union)))
       (setq name (cadr type)))
 
     (setq ffi-named-types
-          (put-alist name type ffi-named-types))
+         (put-alist name type ffi-named-types))
 
     ;; Copy translators, if any
     (let ((fft (assq type ffi-type-to-translators))
-          (tft (assq type ffi-type-from-translators)))
+         (tft (assq type ffi-type-from-translators)))
       (when fft
-        (pushnew (cons name (cdr fft)) ffi-type-to-translators :key #'car))
+       (pushnew (cons name (cdr fft)) ffi-type-to-translators :key #'car))
       (when tft
-        (pushnew (cons name (cdr tft)) ffi-type-from-translators :key #'car)))
+       (pushnew (cons name (cdr tft)) ffi-type-from-translators :key #'car)))
 
     name))
 
@@ -165,21 +165,21 @@ TYPE."
   "Define a new structure of NAME and SLOTS.
 SLOTS are in form (NAME TYPE &key :offset)."
   (let ((forms `(progn
-                  (define-ffi-type ,name (struct ,name ,@slots)))))
+                 (define-ffi-type ,name (struct ,name ,@slots)))))
     (loop for sn in slots
       do (setq sn (car sn))
       do (let ((sym (intern (format "%S->%S" name sn))))
-           (setq forms (append forms
-                               `((defun ,sym (obj)
-                                   (ffi-fetch obj (ffi-slot-offset ',name ',sn)
-                                              (ffi-slot-type ',name ',sn))))))
-           (setq forms
-                 (append forms
-                         `((defsetf ,sym (obj) (nv)
-                             (list 'ffi-store obj
-                                   (list 'ffi-slot-offset '',name '',sn)
-                                   (list 'ffi-slot-type '',name '',sn)
-                                   nv)))))))
+          (setq forms (append forms
+                              `((defun ,sym (obj)
+                                  (ffi-fetch obj (ffi-slot-offset ',name ',sn)
+                                             (ffi-slot-type ',name ',sn))))))
+          (setq forms
+                (append forms
+                        `((defsetf ,sym (obj) (nv)
+                            (list 'ffi-store obj
+                                  (list 'ffi-slot-offset '',name '',sn)
+                                  (list 'ffi-slot-type '',name '',sn)
+                                  nv)))))))
     forms))
 
 ;;;###autoload
@@ -192,40 +192,40 @@ NOTE: returned non-nil value is actuall canonicalised type."
   (setq type (ffi-canonicalise-type type))
   (if (cond ((ffi-basic-type-p type) type)
 
-            ;; Pointer
-            ((or (eq type 'pointer)
-                 (and (listp type)
-                      (eq (car type) 'pointer)
-                      (ffi-type-p (cadr type)))) type)
+           ;; Pointer
+           ((or (eq type 'pointer)
+                (and (listp type)
+                     (eq (car type) 'pointer)
+                     (ffi-type-p (cadr type)))) type)
 
-            ;; Maybe TYPE is declared
-            ((ffi-declared-type-p type) type)
+           ;; Maybe TYPE is declared
+           ((ffi-declared-type-p type) type)
 
-            ;; Struct or Union
-            ((and (listp type)
-                  (memq (car type) '(struct union)))
-             type)
+           ;; Struct or Union
+           ((and (listp type)
+                 (memq (car type) '(struct union)))
+            type)
 ;             (not (memq nil
 ;                        (mapcar #'(lambda (slot-type)
 ;                                    (ffi-type-p (cadr slot-type)))
 ;                                (cddr type)))))
 
-            ;; Complex c-data
-            ((and (consp type) (eq (car type) 'c-data)
-                  (or (numberp (cdr type)) (null (cdr type))))
-             type)
-
-            ;; Array
-            ((and (listp type) (eq 'array (car type))
-                  (ffi-type-p (cadr type))
-                  (integerp (caddr type))
-                  (> (caddr type) 0))
-             type)
-
-            ;; Function
-            ((and (listp type) (eq 'function (car type))
-                  (ffi-type-p (cadr type)))
-             (not (memq nil (mapcar 'ffi-type-p (cddr type))))))
+           ;; Complex c-data
+           ((and (consp type) (eq (car type) 'c-data)
+                 (or (numberp (cdr type)) (null (cdr type))))
+            type)
+
+           ;; Array
+           ((and (listp type) (eq 'array (car type))
+                 (ffi-type-p (cadr type))
+                 (integerp (caddr type))
+                 (> (caddr type) 0))
+            type)
+
+           ;; Function
+           ((and (listp type) (eq 'function (car type))
+                 (ffi-type-p (cadr type)))
+            (not (memq nil (mapcar 'ffi-type-p (cddr type))))))
       type                              ; TYPE is valid FFI type
 
     (when signal-p
@@ -247,11 +247,11 @@ $LD_LIBRARY_PATH environment variable or the more global ld.so.cache."
       (error "Can't load library `%s': %s" libname (ffi-dlerror)))
 
     (setq ffi-loaded-libraries
-          (put-alist libname fo ffi-loaded-libraries))
+         (put-alist libname fo ffi-loaded-libraries))
     fo))
 
 (defun* ffi-get (fo &key (type (ffi-object-type fo)) (off 0)
-                    (from-call nil))
+                   (from-call nil))
   "Return FO's value.
 Optional key :TYPE may be used to cast FO to the specified
 type, it defaults to the object's assigned type.
@@ -260,45 +260,45 @@ defaults to 0.
 FROM-CALL is magic, do not use it!"
   (let ((ctype (ffi-canonicalise-type type)))
     (cond ((ffi-basic-type-p ctype)
-           (ffi-fetch fo off type))
-          ;; Arrays
-          ((and (listp ctype)
-                (eq (car ctype) 'array))
-           (vconcat
-            (loop for idx from 0 below (third ctype)
-              collect (ffi-get
-                       fo :type (second ctype)
-                       :off (+ off (* idx (ffi-size-of-type
-                                           (second ctype))))))))
-
-          ;; Structures
-          ((and (listp ctype)
-                (eq (car ctype) 'struct))
-           (loop for sslot in (cddr ctype)
-             collect (list (first sslot)
-                           (ffi-get
-                            fo :type (second sslot)
-                            :off (+ off (ffi-slot-offset
-                                         ctype (first sslot)))))))
-
-          ;; Extremely special case for safe-string!
-          ((eq type 'safe-string)
-           (unless (ffi-null-p fo)
-             (ffi-fetch fo off 'c-string)))
-
-          ((and (not from-call)
-                (or (eq ctype 'pointer)
-                    (and (listp ctype)
-                         (eq (car ctype) 'pointer)
-                         (ffi-type-p (cadr ctype)))))
-           (if (ffi-null-p fo)
-               nil
-             (ffi-fetch fo off type)))
-
-          (t
-           ;; Can't get value in proper form,
-           ;; just return FO unmodified
-           fo))))
+          (ffi-fetch fo off type))
+         ;; Arrays
+         ((and (listp ctype)
+               (eq (car ctype) 'array))
+          (vconcat
+           (loop for idx from 0 below (third ctype)
+             collect (ffi-get
+                      fo :type (second ctype)
+                      :off (+ off (* idx (ffi-size-of-type
+                                          (second ctype))))))))
+
+         ;; Structures
+         ((and (listp ctype)
+               (eq (car ctype) 'struct))
+          (loop for sslot in (cddr ctype)
+            collect (list (first sslot)
+                          (ffi-get
+                           fo :type (second sslot)
+                           :off (+ off (ffi-slot-offset
+                                        ctype (first sslot)))))))
+
+         ;; Extremely special case for safe-string!
+         ((eq type 'safe-string)
+          (unless (ffi-null-p fo)
+            (ffi-fetch fo off 'c-string)))
+
+         ((and (not from-call)
+               (or (eq ctype 'pointer)
+                   (and (listp ctype)
+                        (eq (car ctype) 'pointer)
+                        (ffi-type-p (cadr ctype)))))
+          (if (ffi-null-p fo)
+              nil
+            (ffi-fetch fo off type)))
+
+         (t
+          ;; Can't get value in proper form,
+          ;; just return FO unmodified
+          fo))))
 
 (defun ffi-slot-type (type slot)
   "Return TYPE's SLOT type.
@@ -307,7 +307,7 @@ TYPE must be of structure or union type."
     (unless (memq (car ctype) '(struct union))
       (error "Not struct or union: %S" type))
     (or (cadr (find slot (cddr ctype) :key #'car :test #'eq))
-        (error "No such slot: %S" slot))))
+       (error "No such slot: %S" slot))))
 
 (defun ffi-slot (fo slot)
   "Setf-able slot accessor.
@@ -324,15 +324,15 @@ FO's SLOT."
 (defun ffi-set (fo val)
   "Set FO's foreign value to VAL."
   (let* ((type (ffi-object-type fo))
-         (ctype (ffi-canonicalise-type type)))
+        (ctype (ffi-canonicalise-type type)))
     (if (or (ffi-basic-type-p ctype)
-            (eq ctype 'pointer))
-        (ffi-store fo 0 type val)
+           (eq ctype 'pointer))
+       (ffi-store fo 0 type val)
 
       ;; Pointer type, same as for basic
       (when (or (eq ctype 'pointer)
-                (and (listp ctype) (eq (car ctype) 'pointer)))
-        (ffi-store fo 0 type val))
+               (and (listp ctype) (eq (car ctype) 'pointer)))
+       (ffi-store fo 0 type val))
 
       ;; TODO: Compound type
       )))
@@ -353,17 +353,17 @@ Error will be signaled if FO-POINTER is not of pointer type."
      (defun ,fsym ,args
        ,doc-string
        (let ((ffiargs nil)
-             (ret nil))
-         (mapcar* #'(lambda (type arg)
-                      (setq ffiargs (cons
-                                     (if (ffi-object-p arg)
-                                         arg
-                                       (ffi-create-fo type arg))
-                                     ffiargs)))
-                  (cddr ,ftype) (list ,@args))
-         (setq ffiargs (nreverse ffiargs))
-         (setq ret (apply #'ffi-call-function ,fsym ffiargs))
-         (ffi-get ret :from-call t)))))
+            (ret nil))
+        (mapcar* #'(lambda (type arg)
+                     (setq ffiargs (cons
+                                    (if (ffi-object-p arg)
+                                        arg
+                                      (ffi-create-fo type arg))
+                                    ffiargs)))
+                 (cddr ,ftype) (list ,@args))
+        (setq ffiargs (nreverse ffiargs))
+        (setq ret (apply #'ffi-call-function ,fsym ffiargs))
+        (ffi-get ret :from-call t)))))
 
 (put 'define-ffi-function 'lisp-indent-function 'defun)
 
@@ -411,107 +411,107 @@ Both functions return nil if the symbol is not in the enumeration."
 
   ;; now build that pig of code
   (list 'prog1
-        ;; define the constant `name'
-        (list 'defconst name nil
-              docstring)
-        ;; fill in the values
-        (list 'setq name
-              (cons 'list
-                    (let ((tmpspecs specs)
-                          (i 0)
-                          (delayed (dllist))
-                          (result (dllist)))
-                      (while (car tmpspecs)
-                        (if (eq (cadr tmpspecs) '=)
-                            ;; this is the alias case
-                            ;; we append a cons (left-of-= . right-of-=)
-                            ;; to the dllist `delayed'
-                            ;; if `right-of-=' (i.e. the caddr) is an integer
-                            ;; we set the counter `i' to that value on go on
-                            ;; from there
-                            (let ((leftof (car tmpspecs))
-                                  (rightof (caddr tmpspecs)))
-
-                              ;; pop off the cruft
-                              (setq tmpspecs (nthcdr 3 tmpspecs))
-
-                              (cond ((intp rightof)
-                                     ;; reset the counter
-                                     (setq i rightof)
-                                     ;; prepend leftof again
-                                     (setq tmpspecs
-                                           (cons leftof tmpspecs)))
-                                    (t
-                                     ;; push the stuff to the delayed list
-                                     (dllist-append
-                                      delayed (cons leftof rightof)))))
-
-                          ;; ordinary case
-                          (dllist-append result (cons (car tmpspecs) i))
-                          (setq i (1+ i))
-                          (setq tmpspecs (cdr tmpspecs))))
-
-                      ;; convert `result' to alist
-                      ;; this is necessary here, since we need the alist
-                      ;; property right now to look up the delayed symbols
-                      (setq result (dllist-to-list result))
-
-                      ;; process those delayed thingies
-                      ;; these are basically conses (alias . resolved-symbol)
-                      ;; we lookup `resolved-symbol' in the alist `result'
-                      ;; first and assign (alias . value-of-resolved-symbol)
-                      ;; if that fails, we look at the cars of the delayed
-                      ;; list if we can find `resolved-symbol' there
-                      ;; if so, we re-append the whole cell to the delayed list
-                      ;; if not, we try to find a huge horsewhip to treat
-                      ;; the user to a little surprise :)
-                      (while (dllist-car delayed)
-                        (let ((alias (dllist-pop-car delayed)))
-                          (let ((val (cdr-safe (assoc (cdr alias) result))))
-                            (if (null val)
-                                ;; prevent infinite loops when the user
-                                ;; is too stupid to give us a valid alias
-                                (when (let ((presentp))
-                                        (mapc-internal
-                                         #'(lambda (item)
-                                             (and (eq (cdr alias) (car item))
-                                                  (setq presentp t)))
-                                         delayed)
-                                        presentp)
-                                    (dllist-append delayed alias))
-                              (setq result
-                                    (cons (cons (car alias) val)
-                                          result))))))
-
-                      ;; return `result'
-                      (mapcar
-                       #'(lambda (rescell)
-                           (list 'cons
-                                 (list 'quote (car rescell))
-                                 (list
-                                  'let
-                                  (list (list 'ffival
-                                              (list 'ffi-create-fo
-                                                    ''unsigned-int
-                                                    (cdr rescell))))
-                                  (list 'put 'ffival ''value (cdr rescell))
-                                  'ffival)))
-                       result))))
-
-        ;; define the lookup function
-        (list 'defun name '(symbol)
-              (format "Lookup the value of SYMBOL in the enumeration `%s'."
-                      name)
-              (list 'cdr-safe
-                    (list 'assq 'symbol
-                          name)))
-
-        ;; define the lookup function for the elisp value
-        (list 'defun (intern (format "%s-value" name)) '(symbol)
-              (format (concat "Lookup the elisp value (an integer) of SYMBOL "
-                              "in the enumeration `%s'.")
-                      name)
-              (list 'get (list name 'symbol) ''value))))
+       ;; define the constant `name'
+       (list 'defconst name nil
+             docstring)
+       ;; fill in the values
+       (list 'setq name
+             (cons 'list
+                   (let ((tmpspecs specs)
+                         (i 0)
+                         (delayed (dllist))
+                         (result (dllist)))
+                     (while (car tmpspecs)
+                       (if (eq (cadr tmpspecs) '=)
+                           ;; this is the alias case
+                           ;; we append a cons (left-of-= . right-of-=)
+                           ;; to the dllist `delayed'
+                           ;; if `right-of-=' (i.e. the caddr) is an integer
+                           ;; we set the counter `i' to that value on go on
+                           ;; from there
+                           (let ((leftof (car tmpspecs))
+                                 (rightof (caddr tmpspecs)))
+
+                             ;; pop off the cruft
+                             (setq tmpspecs (nthcdr 3 tmpspecs))
+
+                             (cond ((intp rightof)
+                                    ;; reset the counter
+                                    (setq i rightof)
+                                    ;; prepend leftof again
+                                    (setq tmpspecs
+                                          (cons leftof tmpspecs)))
+                                   (t
+                                    ;; push the stuff to the delayed list
+                                    (dllist-append
+                                     delayed (cons leftof rightof)))))
+
+                         ;; ordinary case
+                         (dllist-append result (cons (car tmpspecs) i))
+                         (setq i (1+ i))
+                         (setq tmpspecs (cdr tmpspecs))))
+
+                     ;; convert `result' to alist
+                     ;; this is necessary here, since we need the alist
+                     ;; property right now to look up the delayed symbols
+                     (setq result (dllist-to-list result))
+
+                     ;; process those delayed thingies
+                     ;; these are basically conses (alias . resolved-symbol)
+                     ;; we lookup `resolved-symbol' in the alist `result'
+                     ;; first and assign (alias . value-of-resolved-symbol)
+                     ;; if that fails, we look at the cars of the delayed
+                     ;; list if we can find `resolved-symbol' there
+                     ;; if so, we re-append the whole cell to the delayed list
+                     ;; if not, we try to find a huge horsewhip to treat
+                     ;; the user to a little surprise :)
+                     (while (dllist-car delayed)
+                       (let ((alias (dllist-pop-car delayed)))
+                         (let ((val (cdr-safe (assoc (cdr alias) result))))
+                           (if (null val)
+                               ;; prevent infinite loops when the user
+                               ;; is too stupid to give us a valid alias
+                               (when (let ((presentp))
+                                       (mapc-internal
+                                        #'(lambda (item)
+                                            (and (eq (cdr alias) (car item))
+                                                 (setq presentp t)))
+                                        delayed)
+                                       presentp)
+                                   (dllist-append delayed alias))
+                             (setq result
+                                   (cons (cons (car alias) val)
+                                         result))))))
+
+                     ;; return `result'
+                     (mapcar
+                      #'(lambda (rescell)
+                          (list 'cons
+                                (list 'quote (car rescell))
+                                (list
+                                 'let
+                                 (list (list 'ffival
+                                             (list 'ffi-create-fo
+                                                   ''unsigned-int
+                                                   (cdr rescell))))
+                                 (list 'put 'ffival ''value (cdr rescell))
+                                 'ffival)))
+                      result))))
+
+       ;; define the lookup function
+       (list 'defun name '(symbol)
+             (format "Lookup the value of SYMBOL in the enumeration `%s'."
+                     name)
+             (list 'cdr-safe
+                   (list 'assq 'symbol
+                         name)))
+
+       ;; define the lookup function for the elisp value
+       (list 'defun (intern (format "%s-value" name)) '(symbol)
+             (format (concat "Lookup the elisp value (an integer) of SYMBOL "
+                             "in the enumeration `%s'.")
+                     name)
+             (list 'get (list name 'symbol) ''value))))
 (put 'ffi-enum 'lisp-indent-function 'defun)
 ;;; example
 ;; (ffi-enum example-enum
@@ -535,27 +535,27 @@ For example:
   `(progn
      (define-ffi-type ,type-name int)
      (let* ((cv 0)
-            (fev (mapcar #'(lambda (sv)
-                             (prog1
-                                 (if (and (listp sv)
-                                          (symbolp (car sv))
-                                          (numberp (cadr sv)))
-                                     (prog1
-                                         (cons (car sv) (cadr sv))
-                                       (setq cv (cadr sv)))
-                                   (cons sv cv))
-                               (incf cv)))
-                         '(,@spec))))
+           (fev (mapcar #'(lambda (sv)
+                            (prog1
+                                (if (and (listp sv)
+                                         (symbolp (car sv))
+                                         (numberp (cadr sv)))
+                                    (prog1
+                                        (cons (car sv) (cadr sv))
+                                      (setq cv (cadr sv)))
+                                  (cons sv cv))
+                              (incf cv)))
+                        '(,@spec))))
        (put ',type-name 'ffi-enum-values fev))
      ;; Translators
      (define-ffi-translator-to-foreign ,type-name
        (or (cdr (assq value (get ',type-name 'ffi-enum-values)))
-           0))
+          0))
      (define-ffi-translator-from-foreign ,type-name
        (or (car (find-if #'(lambda (v)
-                             (= (cdr v) value))
-                         (get ',type-name 'ffi-enum-values)))
-           'undefined-enum-value))))
+                            (= (cdr v) value))
+                        (get ',type-name 'ffi-enum-values)))
+          'undefined-enum-value))))
 
 (defun ffi-enum-values (enum-type)
   "Return alist for ENUM-TYPE.
@@ -579,7 +579,7 @@ For example:
 To get foreign object for this callback function use `ffi-callback-fo'
 and pass the name of the callback."
   (let ((argnames (mapcar #'first args))
-        (argtypes (mapcar #'second args)))
+       (argtypes (mapcar #'second args)))
   `(progn
      (defun ,sym ,argnames
        ,@body)
@@ -644,7 +644,7 @@ and pass the name of the callback."
   (etypecase name
     (list (second name))
     (string (intern (format "%s%s%s" (if fun-p "" "*")
-                            (downcase (substitute ?- ?_ name)) (if fun-p "" "*"))))
+                           (downcase (substitute ?- ?_ name)) (if fun-p "" "*"))))
     (symbol name)))
 
 (defun cffi:foreign-var-name (name)
@@ -653,7 +653,7 @@ and pass the name of the callback."
     (list (first name))
     (string name)
     (symbol (let ((dname (downcase (symbol-name name))))
-              (replace-in-string (substitute ?_ ?- dname) "\\*" "")))))
+             (replace-in-string (substitute ?_ ?- dname) "\\*" "")))))
 
 (defun cffi:get-var-pointer (symbol)
   "Return a pointer to the foreign global variable relative to SYMBOL."
@@ -674,53 +674,53 @@ and pass the name of the callback."
     (unless (null docstring)
       (setq in-args (cons docstring in-args)))
     (setq docstring
-          (format "Lisp variant for `%s' foreign function."
-                  (cffi:foreign-var-name name))))
+         (format "Lisp variant for `%s' foreign function."
+                 (cffi:foreign-var-name name))))
 
   (let* ((nsl (cffi:lisp-var-name name t))
-         (nsf (cffi:foreign-var-name name))
-         (with-rest (when (eq (car (last in-args)) '&rest)
-                      (setq in-args (butlast in-args))
-                      t))
-         (as (mapcar 'first in-args))
-         (at (mapcar 'second in-args))
-         (flet-form) (defun-form nil))
+        (nsf (cffi:foreign-var-name name))
+        (with-rest (when (eq (car (last in-args)) '&rest)
+                     (setq in-args (butlast in-args))
+                     t))
+        (as (mapcar 'first in-args))
+        (at (mapcar 'second in-args))
+        (flet-form) (defun-form nil))
     (setq flet-form
-          (append (list `(mapcar* #'setarg ',at (list ,@as)))
-                  (when with-rest
-                    (list '(while rest-args
-                             (if (ffi-object-p (car rest-args))
-                                 (progn
-                                   (setarg (ffi-object-type (car rest-args))
-                                           (car rest-args))
-                                   (setq rest-args (cdr rest-args)))
-                             (setarg (car rest-args) (cadr rest-args))
-                             (setq rest-args (cddr rest-args))))))
-                  (list '(setq ffiargs (nreverse ffiargs)))
-                  (list `(setq ret (apply #'ffi-call-function
-                                          (get ',nsl 'ffi-fun) ffiargs)))
-                  (list `(ffi-get ret :from-call t))))
+         (append (list `(mapcar* #'setarg ',at (list ,@as)))
+                 (when with-rest
+                   (list '(while rest-args
+                            (if (ffi-object-p (car rest-args))
+                                (progn
+                                  (setarg (ffi-object-type (car rest-args))
+                                          (car rest-args))
+                                  (setq rest-args (cdr rest-args)))
+                            (setarg (car rest-args) (cadr rest-args))
+                            (setq rest-args (cddr rest-args))))))
+                 (list '(setq ffiargs (nreverse ffiargs)))
+                 (list `(setq ret (apply #'ffi-call-function
+                                         (get ',nsl 'ffi-fun) ffiargs)))
+                 (list `(ffi-get ret :from-call t))))
     (setq defun-form
-          (append `(defun ,nsl)
-                  (list (if with-rest
-                            (append as '(&rest rest-args))
-                          as))
-                  (list docstring)
-                  (list (append
-                         '(let (ffiargs ret))
-                         (list (append
-                                '(flet ((setarg (type arg)
-                                          (setq ffiargs
-                                                (cons
-                                                 (if (ffi-object-p arg)
-                                                     arg
-                                                   (ffi-create-fo type arg))
-                                                 ffiargs)))))
-                                flet-form))
-                         ))))
+         (append `(defun ,nsl)
+                 (list (if with-rest
+                           (append as '(&rest rest-args))
+                         as))
+                 (list docstring)
+                 (list (append
+                        '(let (ffiargs ret))
+                        (list (append
+                               '(flet ((setarg (type arg)
+                                         (setq ffiargs
+                                               (cons
+                                                (if (ffi-object-p arg)
+                                                    arg
+                                                  (ffi-create-fo type arg))
+                                                ffiargs)))))
+                               flet-form))
+                        ))))
     (append '(progn) (list defun-form)
-            (list `(put ',nsl 'ffi-fun
-                        (ffi-defun '(function ,ret-type ,@at) ,nsf))))))
+           (list `(put ',nsl 'ffi-fun
+                       (ffi-defun '(function ,ret-type ,@at) ,nsf))))))
 
 (put 'cffi:defcfun 'lisp-indent-function 'defun)
 
@@ -747,15 +747,15 @@ pointer in VAR is invalid beyond the dynamic extent of BODY, and
 may be stack-allocated if supported by the implementation.  If
 SIZE-VAR is supplied, it will be bound to SIZE during BODY."
   (let ((var (car spec))
-        (size (cadr spec))
-        (size-var (caddr spec)))
+       (size (cadr spec))
+       (size-var (caddr spec)))
     (unless size-var
       (setf size-var (gensym "SIZE")))
     `(let* ((,size-var ,size)
-            (,var (cffi:foreign-alloc ,size-var)))
+           (,var (cffi:foreign-alloc ,size-var)))
        (unwind-protect
-           (progn ,@body)
-         (cffi:foreign-free ,var)))))
+          (progn ,@body)
+        (cffi:foreign-free ,var)))))
 
 ;;;# Misc. Pointer Operations
 
@@ -763,9 +763,9 @@ SIZE-VAR is supplied, it will be bound to SIZE during BODY."
   "Return non-nil if ffi objct FO has pointer type."
   (let ((ctype (ffi-canonicalise-type (ffi-object-type fo))))
     (or (eq ctype 'pointer)
-        (and (listp ctype)
-             (eq (car ctype) 'pointer)
-             (ffi-type-p (cadr ctype))))))
+       (and (listp ctype)
+            (eq (car ctype) 'pointer)
+            (ffi-type-p (cadr ctype))))))
 
 (defalias 'cffi:make-pointer 'ffi-make-pointer)
 (defalias 'ffi-pointer-address 'ffi-object-address)
index f2b4ea1..dbb0202 100644 (file)
@@ -164,28 +164,28 @@ Options are passed as keyword-value-pairs. Supported keywords are:
 :fstream ffi-fo - a file descriptor to which output is redirected."
   (while options
     (let ((option (car options))
-          (value (cadr options))
-          error)
+         (value (cadr options))
+         error)
       ;; Handle special cases in options
       (case option
-        ((:url :post-fields)
-         (unless (stringp value)
-           (error 'invalid-argument
-                  "curl:easy-setopt invalid option value(must be string)"
-                  option value))
-         (setq value (ffi-create-fo 'c-string value))
-         ;; Keep reference to value until context is destroyed
-         (push value (get ctx 'saved-values)))
+       ((:url :post-fields)
+        (unless (stringp value)
+          (error 'invalid-argument
+                 "curl:easy-setopt invalid option value(must be string)"
+                 option value))
+        (setq value (ffi-create-fo 'c-string value))
+        ;; Keep reference to value until context is destroyed
+        (push value (get ctx 'saved-values)))
 
-        ((:read-function :write-function)
-         (setq value (ffi-callback-fo value)))
+       ((:read-function :write-function)
+        (setq value (ffi-callback-fo value)))
 
-        ((:nobody :header :post :nosignal)
-         (setq value (ffi-create-fo 'int (if value 1 0)))))
+       ((:nobody :header :post :nosignal)
+        (setq value (ffi-create-fo 'int (if value 1 0)))))
 
       (setq error (curl:curl_easy_setopt ctx option value))
       (unless (zerop error)
-        (error 'invalid-operation "curl:easy-setopt error" error))
+       (error 'invalid-operation "curl:easy-setopt error" error))
 
       (setq options (cddr options)))))
 
@@ -196,7 +196,7 @@ context, see `curl:easy-setopt'."
   (let ((err (curl:curl_easy_perform ctx)))
     (unless (zerop err)
       (error 'invalid-operation "curl:easy-perform error"
-             (cdr (assq err curl:errors-alist))))
+            (cdr (assq err curl:errors-alist))))
     err))
 
 (defun curl:easy-perform& (ctx sentinel fs)
@@ -208,7 +208,7 @@ object with key 'ctx to keep it accessible."
   (if (featurep 'workers)
       (let* ((job (ffi-call-function&
                   (get 'curl:curl_easy_perform 'ffi-fun)
-                   ctx sentinel fs ctx)))
+                  ctx sentinel fs ctx)))
        ;; add ctx to plist of job
        (put job 'ctx ctx)
        job)
@@ -222,13 +222,13 @@ object with key 'ctx to keep it accessible."
 (defun curl:easy-getinfo (ctx what)
   "Get info from the context CTX about WHAT."
   (let* ((ival (cdr (assq what (ffi-enum-values 'curl-info))))
-         (itype (if (not (numberp ival))
-                    (error "Unsupported info" what)
-                  (ecase (lsh (logand #xf00000 ival) -20)
-                    (1 'c-string) (2 'long) (3 'double))))
-         (retfo (make-ffi-object itype)))
+        (itype (if (not (numberp ival))
+                   (error "Unsupported info" what)
+                 (ecase (lsh (logand #xf00000 ival) -20)
+                   (1 'c-string) (2 'long) (3 'double))))
+        (retfo (make-ffi-object itype)))
     (unless (zerop (curl:curl_easy_getinfo
-                    ctx what (ffi-address-of retfo)))
+                   ctx what (ffi-address-of retfo)))
       (error 'invalid-operation "curl:easy-getinfo error"))
     (ffi-get retfo)))
 
@@ -239,10 +239,10 @@ object with key 'ctx to keep it accessible."
   ((ptr pointer) (size int) (nmemb int) (stream pointer))
   "Writer to STREAM buffer."
   (let ((buf (ffi-pointer-to-lisp-object stream))
-        (rsz (* size nmemb)))
+       (rsz (* size nmemb)))
     (when (and (positivep rsz) (buffer-live-p buf))
       (with-current-buffer buf
-        (insert (ffi-get ptr :type (cons 'c-data rsz)))))
+       (insert (ffi-get ptr :type (cons 'c-data rsz)))))
     rsz))
 
 ;;;###autoload
@@ -265,24 +265,24 @@ works with HTTP URLs."
   (when current-prefix-arg
     ;; In case of C-u
     (and (y-or-n-p (format "Only download %s's HTTP header? "
-                           (file-basename file-or-buffer)))
-         (setq options (list :header t :nobody t))))
+                          (file-basename file-or-buffer)))
+        (setq options (list :header t :nobody t))))
 
   (let* ((ctx (curl:easy-init))
-         (bufferp (bufferp file-or-buffer))
-         (fs (if bufferp
-                 (ffi-lisp-object-to-pointer file-or-buffer)
-               (c:fopen (expand-file-name file-or-buffer) "w"))))
+        (bufferp (bufferp file-or-buffer))
+        (fs (if bufferp
+                (ffi-lisp-object-to-pointer file-or-buffer)
+              (c:fopen (expand-file-name file-or-buffer) "w"))))
     (unwind-protect
-        (progn
-          (when bufferp
-            (curl:easy-setopt ctx :write-function 'curl:cb-write-to-buffer))
+       (progn
+         (when bufferp
+           (curl:easy-setopt ctx :write-function 'curl:cb-write-to-buffer))
 
-          ;; Avoid signalling!
-          (curl:easy-setopt ctx :nosignal t)
+         ;; Avoid signalling!
+         (curl:easy-setopt ctx :nosignal t)
 
-          (apply #'curl:easy-setopt ctx :fstream fs :url url options)
-          (curl:easy-perform ctx))
+         (apply #'curl:easy-setopt ctx :fstream fs :url url options)
+         (curl:easy-perform ctx))
       (unless bufferp (c:fclose fs))
       (curl:easy-cleanup ctx))))
 
@@ -308,31 +308,31 @@ is run.  Functions in there will be called with an argument JOB."
                                           (temp-directory)))))
   (when current-prefix-arg
     (and (y-or-n-p (format "Only download %s's HTTP header? "
-                           (file-basename file-or-buffer)))
-         (setq options (list :header t :nobody t))))
+                          (file-basename file-or-buffer)))
+        (setq options (list :header t :nobody t))))
 
   (if (featurep 'workers)
       (let* ((ctx (curl:easy-init))
-             (bufferp (bufferp file-or-buffer))
-             (fs (if bufferp
-                     (ffi-lisp-object-to-pointer file-or-buffer)
-                   (c:fopen (expand-file-name file-or-buffer) "w"))))
-        (condition-case cerr
-            (progn
-              (when bufferp
-                (curl:easy-setopt ctx :write-function 'curl:cb-write-to-buffer))
-
-              ;; Avoid signalling!
-              (curl:easy-setopt ctx :nosignal t)
-
-              (apply #'curl:easy-setopt ctx :fstream fs :url url options)
-              (curl:easy-perform& ctx #'curl:easy-perform-sentinel
-                                  (cons bufferp fs)))
-
-          ;; Close FS, cleanup CTX and resignal error
-          (t (unless bufferp (c:fclose fs))
-             (curl:easy-cleanup ctx)
-             (signal (car cerr) (cdr cerr)))))
+            (bufferp (bufferp file-or-buffer))
+            (fs (if bufferp
+                    (ffi-lisp-object-to-pointer file-or-buffer)
+                  (c:fopen (expand-file-name file-or-buffer) "w"))))
+       (condition-case cerr
+           (progn
+             (when bufferp
+               (curl:easy-setopt ctx :write-function 'curl:cb-write-to-buffer))
+
+             ;; Avoid signalling!
+             (curl:easy-setopt ctx :nosignal t)
+
+             (apply #'curl:easy-setopt ctx :fstream fs :url url options)
+             (curl:easy-perform& ctx #'curl:easy-perform-sentinel
+                                 (cons bufferp fs)))
+
+         ;; Close FS, cleanup CTX and resignal error
+         (t (unless bufferp (c:fclose fs))
+            (curl:easy-cleanup ctx)
+            (signal (car cerr) (cdr cerr)))))
     (error 'unimplemented "Asynchronous Event Queues")))
 
 ;;;###autoload
index 572c3c5..ecfe283 100644 (file)
@@ -145,7 +145,7 @@ the queue. ")
   (dummy4 :pointer))
 
 (cffi:defcfun ("dbus_connection_send_with_reply_and_block"
-               dbus:connection-send-with-reply-and-block) :pointer
+              dbus:connection-send-with-reply-and-block) :pointer
   (connection :pointer)
   (message :pointer)
   (timeout_milliseconds :int)
@@ -157,24 +157,24 @@ the queue. ")
   (serial :pointer))
 
 (cffi:defcfun ("dbus_connection_read_write"
-               dbus:connection-read-write) dbus-bool
+              dbus:connection-read-write) dbus-bool
   (connection :pointer)
   (timeout-milliseconds :int))
 
 (cffi:defcfun ("dbus_connection_read_write_dispatch"
-               dbus:connection-read-write-dispatch) dbus-bool
+              dbus:connection-read-write-dispatch) dbus-bool
   (connection :pointer)
   (timeout-milliseconds :int))
 
 (cffi:defcfun ("dbus_connection_pop_message"
-               dbus:connection-pop-message) :pointer
+              dbus:connection-pop-message) :pointer
   (connection :pointer))
 
 (cffi:defcfun ("dbus_connection_flush" dbus:connection-flush) :void
   (connection :pointer))
 
 (cffi:defcfun ("dbus_connection_register_object_path"
-               dbus:connection-register-object-path) dbus-bool
+              dbus:connection-register-object-path) dbus-bool
   (connection :pointer)
   (path :string)
   (vtable :pointer)
@@ -206,7 +206,7 @@ the queue. ")
 ;;{{{ Message functions
 
 (cffi:defcfun ("dbus_message_new_method_call"
-               dbus:message-new-method-call) :pointer
+              dbus:message-new-method-call) :pointer
   (destination :string)
   (path :string)
   (interface :string)
@@ -218,57 +218,57 @@ the queue. ")
   &rest)
 
 (cffi:defcfun ("dbus_message_append_args"
-               dbus:message-append-args) dbus-bool
+              dbus:message-append-args) dbus-bool
   (message :pointer)
   (first-arg-type :int)
   &rest)
 
 (cffi:defcfun ("dbus_message_get_interface"
-               dbus:message-get-interface) :string
+              dbus:message-get-interface) :string
   (message :pointer))
 
 (cffi:defcfun ("dbus_message_get_member"
-               dbus:message-get-member) :string
+              dbus:message-get-member) :string
   (message :pointer))
 
 (cffi:defcfun ("dbus_message_get_path"
-               dbus:message-get-path) :string
+              dbus:message-get-path) :string
   (message :pointer))
 
 (cffi:defcfun ("dbus_message_unref" dbus:message-unref) :void
   (message :pointer))
 
 (cffi:defcfun ("dbus_message_is_method_call"
-               dbus:message-is-method-call) dbus-bool
+              dbus:message-is-method-call) dbus-bool
   (message :pointer)
   (interface :string)
   (method :string))
 
 (cffi:defcfun ("dbus_message_iter_init"
-               dbus:message-iter-init) dbus-bool
+              dbus:message-iter-init) dbus-bool
   (message :pointer)
   (iter :pointer))
 
 (cffi:defcfun ("dbus_message_iter_get_arg_type"
-               dbus:message-iter-get-arg-type) :int
+              dbus:message-iter-get-arg-type) :int
   (iter :pointer))
 
 (cffi:defcfun ("dbus_message_iter_get_basic"
-               dbus:message-iter-get-basic) :void
+              dbus:message-iter-get-basic) :void
   (iter :pointer)
   (value :pointer))
 
 (cffi:defcfun ("dbus_message_new_method_return"
-               dbus:message-new-method-return) :pointer
+              dbus:message-new-method-return) :pointer
   (method_call :pointer))
 
 (cffi:defcfun ("dbus_message_iter_init_append"
-               dbus:message-iter-init-append) :void
+              dbus:message-iter-init-append) :void
   (message :pointer)
   (iter :pointer))
 
 (cffi:defcfun ("dbus_message_iter_append_basic"
-               dbus:message-iter-append-basic) dbus-bool
+              dbus:message-iter-append-basic) dbus-bool
   (iter :pointer)
   (type :int)
   (value :pointer))
@@ -278,8 +278,8 @@ the queue. ")
 ;;; TODO: elisp-friendly d-bus implementation.
 ;;   - Use macros, like python-dbus uses its decorators
 (defstruct (dbus-connection (:type vector) :named
-                            (:print-function
-                             (lambda (dc s pl)
+                           (:print-function
+                            (lambda (dc s pl)
                               (setq pl pl) ; steenkin byte-compiler! --SY.
                               (princ (format "#<dbus connection: %s>"
                                              (dbus-connection-object dc)) s))))
@@ -292,13 +292,13 @@ the queue. ")
   "Create connection to D-Bus.
 Return newly created connection structure."
   (let ((dcon (make-dbus-connection :bus-name bus-name
-                                    :object object-path)))
+                                   :object object-path)))
     (setf (dbus-connection-ffi-error dcon)
-          (cffi:foreign-alloc 'dbus-error))
+         (cffi:foreign-alloc 'dbus-error))
     (dbus:error-init (dbus-connection-ffi-error dcon))
     (setf (dbus-connection-ffi-conn dcon)
-          (dbus:bus-get DBUS_BUS_SESSION
-                        (dbus-connection-ffi-error dcon)))
+         (dbus:bus-get DBUS_BUS_SESSION
+                       (dbus-connection-ffi-error dcon)))
     dcon))
 
 (defmacro* define-dbus-signal (dcon iface signature &rest body)
index 3c9406c..846cc12 100644 (file)
 
 (defconst gcry:md_open
   (ffi-defun '(function int (pointer gcry_md_hd_t) int unsigned-int)
-             "gcry_md_open")
+            "gcry_md_open")
   "Return a handle for message digests.")
 
 ;;;###autoload
 (defun gcry:md-open (&optional hash-algo)
   "Return a message digest handle, initialised by HASH-ALGO."
   (let ((md-handle (make-ffi-object '(pointer void)))
-        (md-number (if hash-algo
-                       (gcry:md-map-name hash-algo)
-                     0)))
+       (md-number (if hash-algo
+                      (gcry:md-map-name hash-algo)
+                    0)))
     (let ((g-hd (ffi-address-of md-handle))
-          (g-algo (ffi-create-fo 'int md-number))
-          (g-flags (gcry:md_flags 'gcry:md_flag_empty)))
+         (g-algo (ffi-create-fo 'int md-number))
+         (g-flags (gcry:md_flags 'gcry:md_flag_empty)))
       (let ((ret (ffi-get
-                  (ffi-call-function gcry:md_open g-hd g-algo g-flags)))
-            (hd (ffi-get g-hd)))
-        (when (ffi-null-p hd)
-          (error "gcry:md-open: Cannot get initial MD handle"))
-        (and (zerop ret)
-             (ffi-set-object-type md-handle 'gcry_md_hd_t)
-             md-handle)))))
+                 (ffi-call-function gcry:md_open g-hd g-algo g-flags)))
+           (hd (ffi-get g-hd)))
+       (when (ffi-null-p hd)
+         (error "gcry:md-open: Cannot get initial MD handle"))
+       (and (zerop ret)
+            (ffi-set-object-type md-handle 'gcry_md_hd_t)
+            md-handle)))))
 
 (defalias 'gcry:make-message-digest #'gcry:md-open)
 
 (defconst gcry:md_close
   (ffi-defun '(function void gcry_md_hd_t)
-             "gcry_md_close")
+            "gcry_md_close")
   "Destroy a handle for message digests.")
 
 (defmacro gcry:md-close (md-handle)
@@ -97,7 +97,7 @@
 
 (defconst gcry:md_enable
   (ffi-defun '(function int gcry_md_hd_t int)
-             "gcry_md_enable")
+            "gcry_md_enable")
   "Enable hash-algorithm within a message digest context.")
 
 (defun gcry:md-enable (md-handle hash-algo)
   (let ((g-algo (ffi-create-fo 'int (gcry:md-map-name hash-algo))))
     (when (ffi-object-p md-handle)
       (let ((ret (ffi-get
-                  (ffi-call-function gcry:md_enable md-handle g-algo))))
-        (zerop ret)))))
+                 (ffi-call-function gcry:md_enable md-handle g-algo))))
+       (zerop ret)))))
 
 (defconst gcry:md_map_name
   (ffi-defun '(function int (pointer char))
-             "gcry_md_map_name")
+            "gcry_md_map_name")
   "Return the enumeration value of a hash algorithm.")
 
 (defun gcry:md-map-name (string)
 
 (defconst gcry:md_write
   (ffi-defun '(function void gcry_md_hd_t (pointer void) unsigned-int)
-             "gcry_md_write")
+            "gcry_md_write")
   "Write data into message digest context.")
 
 (defun gcry:md-write (md-handle data)
   "Write DATA to the digest machinery specified by MD-HANDLE."
   (let ((g-buffer (ffi-create-fo 'c-data data))
-        (g-length (ffi-create-fo 'unsigned-int (length data))))
+       (g-length (ffi-create-fo 'unsigned-int (length data))))
     (when (ffi-object-p md-handle)
       (ffi-call-function gcry:md_write md-handle g-buffer g-length)
       t)))
 
 (defconst gcry:md_get_algo_dlen
   (ffi-defun '(function unsigned-int int)
-             "gcry_md_get_algo_dlen")
+            "gcry_md_get_algo_dlen")
   "Return the length of the message digest.")
 
 (defun gcry:md-get-algo-dlen (hash-algo)
 
 (defconst gcry:md_read
   (ffi-defun '(function c-data gcry_md_hd_t int)
-             "gcry_md_read")
+            "gcry_md_read")
   "Return the message digest.")
 
 (defun gcry:md-read (md-handle hash-algo)
   (let ((g-algo (ffi-create-fo 'int (gcry:md-map-name hash-algo))))
     (when (ffi-object-p md-handle)
       (let ((ret (ffi-call-function gcry:md_read md-handle g-algo))
-            (len (ffi-get (ffi-call-function gcry:md_get_algo_dlen g-algo))))
-        ;;(ffi-get ret :type (cons 'c-data len))
-        (ffi-fetch ret 0 (cons 'c-data len))))))
+           (len (ffi-get (ffi-call-function gcry:md_get_algo_dlen g-algo))))
+       ;;(ffi-get ret :type (cons 'c-data len))
+       (ffi-fetch ret 0 (cons 'c-data len))))))
 
 ;;(setq handle (gcry:md-open "SHA1"))
 ;;(gcry:md-enable handle "MD5")
@@ -209,39 +209,39 @@ Not all of them are supported for each algorithm."
 
 (defconst gcry:cipher_open
   (ffi-defun '(function int gcry_cipher_hd_t int int unsigned-int)
-             "gcry_cipher_open")
+            "gcry_cipher_open")
   "Return a handle for symmetric ciphers.")
 
 ;;;###autoload
 (defun gcry:cipher-open (cipher-algo &optional mode)
   "Return a symmetric cipher handle, initialised by CIPHER-ALGO."
   (let ((sc-handle (make-ffi-object '(pointer void)))
-        (sc-number (if cipher-algo
-                       (gcry:cipher-map-name cipher-algo)
-                     0)))
+       (sc-number (if cipher-algo
+                      (gcry:cipher-map-name cipher-algo)
+                    0)))
     (when (positivep sc-number)
       (let ((g-hd (ffi-address-of sc-handle))
-            (g-algo (ffi-create-fo 'int sc-number))
-            (g-mode (or (gcry:cipher_modes mode)
-                       (gcry:cipher_modes 'none)))
-            (g-flags (gcry:cipher_flags 'gcry:cipher_flag_empty)))
-        (let ((ret (ffi-get
-                    (ffi-call-function
-                     gcry:cipher_open g-hd g-algo g-mode g-flags)))
-              (hd (ffi-get g-hd)))
-          (when (ffi-null-p hd)
-            (error "gcry:cipher-open: Cannot get initial cipher handle"))
-          (and (zerop ret)
-               (ffi-set-object-type sc-handle 'gcry_cipher_hd_t)
-               (put sc-handle 'cipher-algo g-algo)
-               (put sc-handle 'cipher-mode g-mode)
-               sc-handle))))))
+           (g-algo (ffi-create-fo 'int sc-number))
+           (g-mode (or (gcry:cipher_modes mode)
+                      (gcry:cipher_modes 'none)))
+           (g-flags (gcry:cipher_flags 'gcry:cipher_flag_empty)))
+       (let ((ret (ffi-get
+                   (ffi-call-function
+                    gcry:cipher_open g-hd g-algo g-mode g-flags)))
+             (hd (ffi-get g-hd)))
+         (when (ffi-null-p hd)
+           (error "gcry:cipher-open: Cannot get initial cipher handle"))
+         (and (zerop ret)
+              (ffi-set-object-type sc-handle 'gcry_cipher_hd_t)
+              (put sc-handle 'cipher-algo g-algo)
+              (put sc-handle 'cipher-mode g-mode)
+              sc-handle))))))
 
 (defalias 'gcry:make-symmetric-cipher #'gcry:cipher-open)
 
 (defconst gcry:cipher_close
   (ffi-defun '(function void gcry_cipher_hd_t)
-             "gcry_cipher_close")
+            "gcry_cipher_close")
   "Destroy a handle for symmetric ciphers.")
 
 (defmacro gcry:cipher-close (sc-handle)
@@ -256,7 +256,7 @@ Not all of them are supported for each algorithm."
 
 (defconst gcry:cipher_map_name
   (ffi-defun '(function int (pointer char))
-             "gcry_cipher_map_name")
+            "gcry_cipher_map_name")
   "Return the enumeration value of a cipher algorithm.")
 
 (defun gcry:cipher-map-name (string)
@@ -325,54 +325,54 @@ Not all of them are supported for each algorithm."
 
 (defconst gcry:cipher_ctl
   (ffi-defun '(function int gcry_cipher_hd_t int (pointer void) unsigned-int)
-             "gcry_cipher_ctl")
+            "gcry_cipher_ctl")
   "Generic cipher accessor.")
 
 (defun gcry:cipher-setkey (sc-handle key)
   "Set the key of SC-HANDLE to KEY."
   (when (and (stringp key)
-             (gcry:cipher-handle-p sc-handle))
+            (gcry:cipher-handle-p sc-handle))
     (let ((g-cmd (cdr (assq 'gcryctl_set_key gcry:ctl_cmds)))
-          (g-buffer (ffi-create-fo 'c-string key))
-          (g-nbytes (ffi-create-fo 'unsigned-int (length key))))
+         (g-buffer (ffi-create-fo 'c-string key))
+         (g-nbytes (ffi-create-fo 'unsigned-int (length key))))
       (let ((ret
-             (ffi-get
-              (ffi-call-function gcry:cipher_ctl
-                                 sc-handle g-cmd g-buffer g-nbytes))))
-        (when (zerop ret)
-          t)))))
+            (ffi-get
+             (ffi-call-function gcry:cipher_ctl
+                                sc-handle g-cmd g-buffer g-nbytes))))
+       (when (zerop ret)
+         t)))))
 
 (defun gcry:cipher-setiv (sc-handle iv)
   "Set the initialisation vector of SC-HANDLE to IV."
   (when (and (stringp iv)
-             (gcry:cipher-handle-p sc-handle))
+            (gcry:cipher-handle-p sc-handle))
     (let ((g-cmd (cdr (assq 'gcryctl_set_iv gcry:ctl_cmds)))
-          (g-buffer (ffi-create-fo 'c-string iv))
-          (g-nbytes (ffi-create-fo 'unsigned-int (length iv))))
+         (g-buffer (ffi-create-fo 'c-string iv))
+         (g-nbytes (ffi-create-fo 'unsigned-int (length iv))))
       (let ((ret
-             (ffi-get
-              (ffi-call-function gcry:cipher_ctl
-                                 sc-handle g-cmd g-buffer g-nbytes))))
-        (when (zerop ret)
-          t)))))
+            (ffi-get
+             (ffi-call-function gcry:cipher_ctl
+                                sc-handle g-cmd g-buffer g-nbytes))))
+       (when (zerop ret)
+         t)))))
 
 (defun gcry:padded-length (string &optional block-length)
   "Return the length of STRING after correct padding to
 BLOCK-LENGTH (defaults to 8)."
   (let* ((blklen (or block-length 8))
-         (slen (length string))
-         (blks (1+ (div slen blklen)))
-         (plen (* blks blklen)))
+        (slen (length string))
+        (blks (1+ (div slen blklen)))
+        (plen (* blks blklen)))
     plen))
 
 (defun gcry:padded-string (string &optional block-length)
   "Return the padded version of STRING after correct padding to
 BLOCK-LENGTH (defaults to 8)."
   (let* ((blklen (or block-length 8))
-         (padlen (gcry:padded-length string blklen))
-         (strlen (length string))
-         (defect (- padlen strlen))
-         (pad (make-string defect defect)))
+        (padlen (gcry:padded-length string blklen))
+        (strlen (length string))
+        (defect (- padlen strlen))
+        (pad (make-string defect defect)))
     (concat string pad)))
 ;; (setq somestring "testffff")
 ;; (gcry:padded-string somestring)
@@ -381,13 +381,13 @@ BLOCK-LENGTH (defaults to 8)."
   "Return the unpadded version of STRING assumed a correct padding has
 been applied."
   (let* ((strlen (length string))
-         (padchr (char-to-int (aref string (1- strlen))))
-         ;; validate the padding
-         (first-padchr (when (and (positivep padchr)
-                                  (<= padchr strlen))
-                         (char-to-int (aref string (- strlen padchr)))))
-         (pad-valid-p (when first-padchr
-                        (= first-padchr padchr))))
+        (padchr (char-to-int (aref string (1- strlen))))
+        ;; validate the padding
+        (first-padchr (when (and (positivep padchr)
+                                 (<= padchr strlen))
+                        (char-to-int (aref string (- strlen padchr)))))
+        (pad-valid-p (when first-padchr
+                       (= first-padchr padchr))))
     (when pad-valid-p
       (substring string 0 (- strlen padchr)))))
 ;;(gcry:unpadded-string "abcd\0\0")
@@ -395,61 +395,61 @@ been applied."
 ;; encryption/decryption routines
 (defconst gcry:cipher_encrypt
   (ffi-defun '(function int
-                        gcry_cipher_hd_t c-data unsigned-int
-                        c-data unsigned-int)
-             "gcry_cipher_encrypt")
+                       gcry_cipher_hd_t c-data unsigned-int
+                       c-data unsigned-int)
+            "gcry_cipher_encrypt")
   "Encrypt data under a cipher context.")
 
 (defun gcry:cipher-encrypt (sc-handle plain)
   "Encrypt PLAIN with the settings in SC-HANDLE and return the result."
   (when (and (stringp plain)
-             (gcry:cipher-handle-p sc-handle))
+            (gcry:cipher-handle-p sc-handle))
     (let* ((blklen (gcry:cipher-get-block-length (get sc-handle 'cipher-algo)))
-           ;; add openssl conform padding (gcrypt obviously does not care)
-           (plain (gcry:padded-string plain blklen))
-           (outlen (length plain)))
+          ;; add openssl conform padding (gcrypt obviously does not care)
+          (plain (gcry:padded-string plain blklen))
+          (outlen (length plain)))
 
       (let ((g-in (ffi-create-fo (cons 'c-data (1+ outlen)) plain))
-            (g-inlen (ffi-create-fo 'unsigned-int outlen))
-            (g-out (make-ffi-object (cons 'c-data outlen)))
-            (g-outlen (ffi-create-fo 'unsigned-int outlen)))
-        (let ((ret
-               (ffi-get
-                (ffi-call-function gcry:cipher_encrypt
-                                   sc-handle g-out g-outlen g-in g-inlen))))
-          (when (zerop ret)
-            (ffi-get g-out)))))))
+           (g-inlen (ffi-create-fo 'unsigned-int outlen))
+           (g-out (make-ffi-object (cons 'c-data outlen)))
+           (g-outlen (ffi-create-fo 'unsigned-int outlen)))
+       (let ((ret
+              (ffi-get
+               (ffi-call-function gcry:cipher_encrypt
+                                  sc-handle g-out g-outlen g-in g-inlen))))
+         (when (zerop ret)
+           (ffi-get g-out)))))))
 
 (defconst gcry:cipher_decrypt
   (ffi-defun '(function int
-                        gcry_cipher_hd_t c-data unsigned-int
-                        c-data unsigned-int)
-             "gcry_cipher_decrypt")
+                       gcry_cipher_hd_t c-data unsigned-int
+                       c-data unsigned-int)
+            "gcry_cipher_decrypt")
   "Decrypt data under a cipher context.")
 
 (defun gcry:cipher-decrypt (sc-handle ciphered)
   "Decrypt CIPHERED with the settings in SC-HANDLE and return the result."
   (when (and (stringp ciphered)
-             (gcry:cipher-handle-p sc-handle))
+            (gcry:cipher-handle-p sc-handle))
     (let* (;;(blklen
-           ;; (gcry:cipher-get-block-length (get sc-handle 'cipher-algo)))
-           (outlen (length ciphered)))
+          ;; (gcry:cipher-get-block-length (get sc-handle 'cipher-algo)))
+          (outlen (length ciphered)))
       (let ((g-in (ffi-create-fo 'c-data ciphered))
-            (g-inlen (ffi-create-fo 'unsigned-int outlen))
-            (g-out (make-ffi-object (cons 'c-data outlen)))
-            (g-outlen (ffi-create-fo 'unsigned-int outlen)))
-        (let ((ret
-               (ffi-get
-                (ffi-call-function gcry:cipher_decrypt
-                                   sc-handle g-out g-outlen g-in g-inlen))))
-          (when (zerop ret)
-            (gcry:unpadded-string
-             (ffi-fetch g-out 0 (cons 'c-data outlen)))))))))
+           (g-inlen (ffi-create-fo 'unsigned-int outlen))
+           (g-out (make-ffi-object (cons 'c-data outlen)))
+           (g-outlen (ffi-create-fo 'unsigned-int outlen)))
+       (let ((ret
+              (ffi-get
+               (ffi-call-function gcry:cipher_decrypt
+                                  sc-handle g-out g-outlen g-in g-inlen))))
+         (when (zerop ret)
+           (gcry:unpadded-string
+            (ffi-fetch g-out 0 (cons 'c-data outlen)))))))))
 
 
 (defconst gcry:cipher_algo_info
   (ffi-defun '(function int int int (pointer void) (pointer unsigned-int))
-             "gcry_cipher_algo_info")
+            "gcry_cipher_algo_info")
   "Return information generically of a cipher algorithm.")
 
 (defun gcry:cipher-algo-info (cipher-algo which-info)
@@ -457,29 +457,29 @@ been applied."
 WHICH-INFO must be one of 'gcryctl_get_keylen, 'gcryctl_get_blklen and
 'gcryctl_test_algo."
   (when (or (eq which-info 'gcryctl_get_keylen)
-            (eq which-info 'gcryctl_get_blklen)
-            (eq which-info 'gcryctl_test_algo))
+           (eq which-info 'gcryctl_get_blklen)
+           (eq which-info 'gcryctl_test_algo))
     (let ((g-what (cdr (assq which-info gcry:ctl_cmds)))
-          (g-algo (cond ((stringp cipher-algo)
-                        (ffi-create-fo 'int (gcry:cipher-map-name cipher-algo)))
-                       ((intp cipher-algo)
-                        (ffi-create-fo 'int cipher-algo))
-                       ((and (ffi-object-p cipher-algo)
-                             (eq (ffi-object-type cipher-algo) 'int))
-                        cipher-algo)))
-          (g-buffer (ffi-null-pointer))
-          (g-nbytes (make-ffi-object 'unsigned-int)))
+         (g-algo (cond ((stringp cipher-algo)
+                       (ffi-create-fo 'int (gcry:cipher-map-name cipher-algo)))
+                      ((intp cipher-algo)
+                       (ffi-create-fo 'int cipher-algo))
+                      ((and (ffi-object-p cipher-algo)
+                            (eq (ffi-object-type cipher-algo) 'int))
+                       cipher-algo)))
+         (g-buffer (ffi-null-pointer))
+         (g-nbytes (make-ffi-object 'unsigned-int)))
       (let* ((g-nbytes* (if (eq which-info 'gcryctl_test_algo)
-                           (ffi-null-pointer)
-                         (ffi-address-of g-nbytes)))
-             (ret
-              (ffi-get
-               (ffi-call-function gcry:cipher_algo_info
-                                  g-algo g-what g-buffer g-nbytes*))))
-        (when (zerop ret)
-          (if (eq which-info 'gcryctl_test_algo)
-              t
-            (ffi-get g-nbytes)))))))
+                          (ffi-null-pointer)
+                        (ffi-address-of g-nbytes)))
+            (ret
+             (ffi-get
+              (ffi-call-function gcry:cipher_algo_info
+                                 g-algo g-what g-buffer g-nbytes*))))
+       (when (zerop ret)
+         (if (eq which-info 'gcryctl_test_algo)
+             t
+           (ffi-get g-nbytes)))))))
 
 ;; derived funs
 (defun gcry:cipher-get-key-length (cipher)
index 456652b..ff91d74 100644 (file)
@@ -25,7 +25,7 @@
 
 ;;; Commentary:
 
-;; 
+;;
 
 ;;; Code:
 (require 'ffi)
@@ -80,15 +80,15 @@ STREAM is object returned by call to `c:fopen' function.
 Empty stream is returned if end-of-file indicated.
 Error raises if some error occurs."
   (let* ((fod (make-ffi-object (cons 'c-data size)))
-         (rsz (c:fread-1 fod 1 size stream)))
+        (rsz (c:fread-1 fod 1 size stream)))
     (if (zerop rsz)
-        (cond ((c:feof-p stream) "")
-              ((c:ferror-p stream)
-               (error 'io-error "c:fread error"
-                      (c:strerror (ffi-get c:errno))))
-              (t (error 'io-error "c:fread unknown error")))
+       (cond ((c:feof-p stream) "")
+             ((c:ferror-p stream)
+              (error 'io-error "c:fread error"
+                     (c:strerror (ffi-get c:errno))))
+             (t (error 'io-error "c:fread unknown error")))
       (ffi-get fod :type (cons 'c-data rsz)))))
-    
+
 (cffi:defcfun ("fwrite" c:fwrite-1) unsigned-int
   "Elisp binding to fwrite(3).
 Consider using `c:fwrite' in your programs."
@@ -128,27 +128,27 @@ The argument MODE is a string beginning with one of the following
 sequences (Additional characters may follow these sequences.):
 
 ``r''   Open text file for reading.  The stream is positioned at the
-        beginning of the file.
+       beginning of the file.
 
 ``r+''  Open for reading and writing.  The stream is positioned at the
-        beginning of the file.
+       beginning of the file.
 
 ``w''   Truncate file to zero length or create text file for writing.
-        The stream is positioned at the beginning of the file.
+       The stream is positioned at the beginning of the file.
 
 ``w+''  Open for reading and writing.  The file is created if it does not
-        exist, otherwise it is truncated.  The stream is positioned at
-        the beginning of the file.
+       exist, otherwise it is truncated.  The stream is positioned at
+       the beginning of the file.
 
 ``a''   Open for writing.  The file is created if it does not exist.  The
-        stream is positioned at the end of the file.  Subsequent writes
-        to the file will always end up at the then current end of file,
-        irrespective of any intervening fseek(3) or similar.
+       stream is positioned at the end of the file.  Subsequent writes
+       to the file will always end up at the then current end of file,
+       irrespective of any intervening fseek(3) or similar.
 
 ``a+''  Open for reading and writing.  The file is created if it does not
-        exist.  The stream is positioned at the end of the file.  Subse-
-        quent writes to the file will always end up at the then current
-        end of file, irrespective of any intervening fseek(3) or similar.
+       exist.  The stream is positioned at the end of the file.  Subse-
+       quent writes to the file will always end up at the then current
+       end of file, irrespective of any intervening fseek(3) or similar.
 
 The mode string can also include the letter ``b'' either as a third char-
 acter or as a character between the characters in any of the two-charac-
@@ -157,7 +157,7 @@ ISO/IEC 9899:1990 (``ISO C90'') and has no effect; the ``b'' is ignored."
   (let ((rv (c:fopen-1 file mode)))
     (when (ffi-null-p rv)
       (error 'file-error "c:fopen open error"
-             file (c:strerror (ffi-get c:errno))))
+            file (c:strerror (ffi-get c:errno))))
     rv))
 
 (cffi:defcfun ("dup" c:dup) int
index 5068146..408cdaf 100644 (file)
@@ -38,7 +38,7 @@
 ;; IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 ;;; Commentary:
-;; 
+;;
 ;;    Mimic file(1)'s basic usage.  At the moment, this is quite raw
 ;;    and single-minded.  It will only use the default magic db and
 ;;    doesn't allow use of any of file(1)'s options.
 
   (let ((ftype (magic-file ffi-magic-shared (expand-file-name file))))
     (if (interactive-p)
-        (message ftype)
+       (message ftype)
       ftype)))
 
 (defun magic:error (&optional magic)
index 3dbffa5..bcc7b52 100644 (file)
@@ -41,7 +41,7 @@
 ;;       ==> 0
 ;;
 ;; To create database in memory use (sqlite-open ":memory:")
-;; 
+;;
 ;; Custom collations:
 ;;
 ;;     (defun Nfirst-collation (s1 s2)
   (bound pointer) (length int) (cleanup int))
 
 (cffi:defcfun ("sqlite3_bind_parameter_count"
-               sqlite:bind-parameter-count) int
+              sqlite:bind-parameter-count) int
   (statement sqlite-statement))
 
 (cffi:defcfun ("sqlite3_bind_parameter_index"
-               sqlite:bind-parameter-index) int
+              sqlite:bind-parameter-index) int
   (statement sqlite-statement) (column c-string))
 
 (cffi:defcfun ("sqlite3_bind_parameter_name"
-               sqlite:bind-parameter-name) c-string
+              sqlite:bind-parameter-name) c-string
   (statement sqlite-statement)
   (position int))
 
 ERROR is message to be signaled."
   (let ((tuple (cdr (assq result sqlite-error-codes))))
     (cond ((and tuple (eq (first tuple) 'sqlite-error))
-           (error 'sqlite-sql-error (if (equal error "not an error") "" error)
-                  :code 1 :name (first tuple)
-                  :comment (second tuple)))
-          (tuple
-           (error 'sqlite-error error
-                  :code result :name (first tuple) :comment (second tuple)))
-          (t result))))
+          (error 'sqlite-sql-error (if (equal error "not an error") "" error)
+                 :code 1 :name (first tuple)
+                 :comment (second tuple)))
+         (tuple
+          (error 'sqlite-error error
+                 :code result :name (first tuple) :comment (second tuple)))
+         (t result))))
 
 ;;}}}
 ;;{{{ Open/close database
@@ -262,9 +262,9 @@ ERROR is message to be signaled."
   "Try to open SQLite dabase stored in FILE.
 On success return database object."
   (let* ((db (make-ffi-object 'sqlite))
-         (result (sqlite:open-internal
-                  (expand-file-name file) (ffi-address-of db)))
-         (retdb (ffi-get db)))
+        (result (sqlite:open-internal
+                 (expand-file-name file) (ffi-address-of db)))
+        (retdb (ffi-get db)))
     (sqlite-check-result result (sqlite:errmsg retdb))
     (push retdb sqlite-databases)
     retdb))
@@ -286,11 +286,11 @@ On success return database object."
 (defun sqlite-prepare (db sql)
   "For DB prepare statement for given SQL."
   (let ((stat (make-ffi-object 'sqlite-statement))
-        (tail (make-ffi-object 'pointer)))
+       (tail (make-ffi-object 'pointer)))
     (sqlite-check-result
      (sqlite:prepare db sql (length sql)
-                     (ffi-address-of stat)
-                     (ffi-address-of tail))
+                    (ffi-address-of stat)
+                    (ffi-address-of tail))
      (sqlite:errmsg db))
     (ffi-get stat)))
 
@@ -301,31 +301,31 @@ Optional COPY-FLAG is one of `sqlite-STATIC' or `sqlite-TRANSIENT'
 \(the default one\).  You must know exactly what you are doing if you
 provide COPY-FLAG argument."
   (let ((key (if (integerp key-object)
-                 key-object
-               (sqlite:bind-parameter-index
-                statement
-                (if (symbolp key-object)
-                    (concat ":" (symbol-name key-object))
-                  key-object)))))
+                key-object
+              (sqlite:bind-parameter-index
+               statement
+               (if (symbolp key-object)
+                   (concat ":" (symbol-name key-object))
+                 key-object)))))
     (when key
       (cond ((null value) (sqlite:bind-null statement key))
-            ((integerp value)
-             (sqlite:bind-int statement key value))
-            ((floatp value)
-             (sqlite:bind-double statement key value))
-            ((stringp value)
-             (sqlite:bind-text statement key value (length value)
-                               (or copy-flag sqlite-STATIC)))
-            ((and (consp value) (eq (car value) 'blob)
-                  (stringp (cdr value)))
-             (let ((bval (ffi-create-fo `(c-data . ,(length (cdr value)))
-                                        (cdr value))))
-               (sqlite:bind-blob
-                statement key bval (length (cdr value))
-                (or copy-flag sqlite-STATIC))))
-            (t (error 'sqlite-datatype-error value
-                      :comment (concat "Attempt to insert data not one of "
-                                       "integer, float, text, or blob."))))
+           ((integerp value)
+            (sqlite:bind-int statement key value))
+           ((floatp value)
+            (sqlite:bind-double statement key value))
+           ((stringp value)
+            (sqlite:bind-text statement key value (length value)
+                              (or copy-flag sqlite-STATIC)))
+           ((and (consp value) (eq (car value) 'blob)
+                 (stringp (cdr value)))
+            (let ((bval (ffi-create-fo `(c-data . ,(length (cdr value)))
+                                       (cdr value))))
+              (sqlite:bind-blob
+               statement key bval (length (cdr value))
+               (or copy-flag sqlite-STATIC))))
+           (t (error 'sqlite-datatype-error value
+                     :comment (concat "Attempt to insert data not one of "
+                                      "integer, float, text, or blob."))))
       )))
 
 (defun sqlite-bind-seq (statement sequence)
@@ -343,9 +343,9 @@ provide COPY-FLAG argument."
 BINDING could be plist, list or vector."
   (when binding
     (cond ((and (listp binding) (keywordp (car binding)))
-           (sqlite-bind-plist statement binding))
-          ((or (vectorp binding) (listp binding))
-           (sqlite-bind-seq statement binding)))
+          (sqlite-bind-plist statement binding))
+         ((or (vectorp binding) (listp binding))
+          (sqlite-bind-seq statement binding)))
     t))
 
 (defun sqlite-fetch-column (statement index)
@@ -357,8 +357,8 @@ There is currently no way to specify a casting operation."
     (2 (sqlite:column-double statement index))
     (3 (sqlite:column-text statement index))
     (4 (let ((blob (sqlite:column-blob statement index))
-             (blen (sqlite:column-bytes statement index)))
-         (ffi-get blob :type (cons 'c-data blen))))
+            (blen (sqlite:column-bytes statement index)))
+        (ffi-get blob :type (cons 'c-data blen))))
     (5 nil)))
 
 (defun sqlite-fetch (statement)
@@ -367,7 +367,7 @@ nil is returned for empty row."
   (when (= sqlite-ROW (sqlite:step statement))
     (let ((cols (sqlite:column-count statement)))
       (loop for i from 0 below cols
-        collect (sqlite-fetch-column statement i)))))
+       collect (sqlite-fetch-column statement i)))))
 
 (defun sqlite-reset (statement &optional clear-bindings)
   "Reset STATEMENT, so it could be used again.
@@ -394,14 +394,14 @@ TYPE is one of:
  'immediate
 Default is deffered."
   (let ((ttype (multiple-value-bind (major minor sub)
-                   (mapcar 'string-to-int
-                           (split-string-by-char (sqlite:version) ?\.))
-                 (setq major major)     ; shut up compiler
-                 (if (or (>= minor 0) (>= sub 8))
-                     (cond ((eq type 'exclusive) " exclusive ")
-                           ((eq type 'immediate) " immediate ")
-                           (t " "))
-                   " "))))
+                  (mapcar 'string-to-int
+                          (split-string-by-char (sqlite:version) ?\.))
+                (setq major major)     ; shut up compiler
+                (if (or (>= minor 0) (>= sub 8))
+                    (cond ((eq type 'exclusive) " exclusive ")
+                          ((eq type 'immediate) " immediate ")
+                          (t " "))
+                  " "))))
     (sqlite-execute db (concat "begin" ttype "transaction;") :begin nil)))
 
 (defun sqlite-commit (db)
@@ -414,17 +414,17 @@ Default is deffered."
 
 (defmacro* sqlite-with-transaction ((database &optional type) &body body)
   (let ((db-err (gensym "dberror"))
-        (db-obj (gensym "dbobject")))
+       (db-obj (gensym "dbobject")))
     `(let ((,db-obj ,database)
-           (,db-err t))
+          (,db-err t))
        (sqlite-begin-transaction ,db-obj ,type)
        (unwind-protect
-           (prog1
-               (progn ,@body)
-             (setq ,db-err nil))
-         (if ,db-err
-             (sqlite-rollback ,db-obj)
-           (sqlite-commit ,db-obj))))))
+          (prog1
+              (progn ,@body)
+            (setq ,db-err nil))
+        (if ,db-err
+            (sqlite-rollback ,db-obj)
+          (sqlite-commit ,db-obj))))))
 (put 'sqlite-with-transaction 'lisp-indent-function 'defun)
 
 ;;}}}
@@ -432,17 +432,17 @@ Default is deffered."
 
 (defmacro* sqlite-with-prep ((statement-var db sql &optional bind) &body body)
   (let ((db-obj (gensym "dbobject"))
-        (sql-in (gensym "sqlin"))
-        (bind-in (gensym "bindin")))
+       (sql-in (gensym "sqlin"))
+       (bind-in (gensym "bindin")))
     `(let* ((,db-obj ,db)
-            (,sql-in ,sql)
-            (,bind-in ,bind)
-            (,statement-var (sqlite-prepare ,db-obj ,sql-in)))
+           (,sql-in ,sql)
+           (,bind-in ,bind)
+           (,statement-var (sqlite-prepare ,db-obj ,sql-in)))
        (unwind-protect
-           (progn
-             (sqlite-bind ,statement-var ,bind-in)
-             ,@body)
-         (sqlite-flush ,statement-var)))))
+          (progn
+            (sqlite-bind ,statement-var ,bind-in)
+            ,@body)
+        (sqlite-flush ,statement-var)))))
 (put 'sqlite-with-prep 'lisp-indent-function 'defun)
 
 (defun sqlite-execute (db sql &optional bind begin)
@@ -452,9 +452,9 @@ BIND specifies bindings for SQL query.
 If BEGIN is given, then perform a transaction."
   (if begin
       (sqlite-with-transaction (db)
-        (sqlite-with-prep (st db sql bind)
-          (sqlite-check-result (sqlite:step st) (sqlite:errmsg db))
-          t))
+       (sqlite-with-prep (st db sql bind)
+         (sqlite-check-result (sqlite:step st) (sqlite:errmsg db))
+         t))
     (sqlite-with-prep (st db sql bind)
       (sqlite-check-result (sqlite:step st) (sqlite:errmsg db))
       t)))
@@ -480,8 +480,8 @@ BIND specifies bindings for SQL query."
   ((user-data 'pointer) (len1 'int) (str1 'pointer)
    (len2 'int) (str2 'pointer))
   (let ((fun (ffi-pointer-to-lisp-object user-data))
-        (s1 (ffi-get str1 :type (cons 'c-data len1)))
-        (s2 (ffi-get str2 :type (cons 'c-data len2))))
+       (s1 (ffi-get str1 :type (cons 'c-data len1)))
+       (s2 (ffi-get str2 :type (cons 'c-data len2))))
     (funcall fun s1 s2)))
 
 (defun sqlite-create-collation (db name compare-function)
@@ -491,11 +491,11 @@ COMPARE-FUNCTION must get exactly two string arguments and return:
    0  if strings are equal
    1  if first string is greater then second"
   (let* ((ccolls (get db 'custom-collations))
-         (colla (assoc name ccolls)))
+        (colla (assoc name ccolls)))
     (if colla
-        (setcdr colla compare-function)
+       (setcdr colla compare-function)
       (put db 'custom-collations
-           (cons (cons name compare-function) ccolls))))
+          (cons (cons name compare-function) ccolls))))
   (sqlite-check-result
    (sqlite:create-collation
     db name sqlite-UTF-8
@@ -506,20 +506,20 @@ COMPARE-FUNCTION must get exactly two string arguments and return:
 (defun sqlite-remove-collation (db name)
   "For DB remove collation by NAME."
   (let* ((ccolls (get db 'custom-collations))
-         (colla (assoc name ccolls)))
+        (colla (assoc name ccolls)))
     (when colla
       (sqlite-check-result
        (sqlite:create-collation
-        db name sqlite-UTF-8
-        (ffi-lisp-object-to-pointer (cdr colla))
-        (ffi-null-pointer))
+       db name sqlite-UTF-8
+       (ffi-lisp-object-to-pointer (cdr colla))
+       (ffi-null-pointer))
        (sqlite:errmsg db))
       ;; Remove it from custom-collations
       (put db 'custom-collations (del-alist name ccolls))
       t)))
 
 ;;}}}
-            
+
 (provide 'ffi-sqlite)
 
 ;;; ffi-sqlite.el ends here
index 808e81b..5d74f85 100644 (file)
@@ -62,7 +62,7 @@
 \f
 (defconst taglib:file_new
   (ffi-defun '(function TagLib_File c-string)
-             "taglib_file_new")
+            "taglib_file_new")
   "Create and return File object.")
 (defun taglib:file-new (file)
   "Create and return File object."
@@ -72,7 +72,7 @@
 
 (defconst taglib:file_free
   (ffi-defun '(function void TagLib_File)
-             "taglib_file_free")
+            "taglib_file_free")
   "Destruct File object.")
 (defun taglib:file-free (file-object)
   "Destruct File object."
@@ -81,7 +81,7 @@
 
 (defconst taglib:file_save
   (ffi-defun '(function int TagLib_File)
-             "taglib_file_save")
+            "taglib_file_save")
   "Save tags back to File object.")
 (defun taglib:file-save (file-object)
   "Save tags back to File object."
@@ -95,7 +95,7 @@
 ;;; constructors/destructors
 (defconst taglib:file_tag
   (ffi-defun '(function TagLib_Tag TagLib_File)
-             "taglib_file_tag")
+            "taglib_file_tag")
   "Return the tag object associated with the file object.")
 (defun taglib:file-tag (file-object)
   "Return the tag object associated with FILE-OBJECT."
 
 (defconst taglib:tag_free_strings
   (ffi-defun '(function void)
-             "taglib_tag_free_strings")
+            "taglib_tag_free_strings")
   "Free strings allocated by tag lookup functions.")
 (defun taglib:tag-free-strings ()
   "Free strings allocated by tag lookup functions."
 ;; char *taglib_tag_title(const TagLib_Tag *tag);
 (defconst taglib:tag_title
   (ffi-defun '(function c-string TagLib_Tag)
-             "taglib_tag_title")
+            "taglib_tag_title")
   "Return the title associated with tag.")
 (defun taglib:tag-title (tag-object)
   "Return the title associated with TAG-OBJECT."
   (when (ffi-object-p tag-object)
     (let* ((raw
-            (ffi-call-function taglib:tag_title tag-object))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:tag_title tag-object))
+          (result
+           (ffi-get raw)))
       (taglib:tag-free-strings)
       (unless (zerop (length result))
-        result))))
+       result))))
 
 ;; char *taglib_tag_artist(const TagLib_Tag *tag);
 (defconst taglib:tag_artist
   (ffi-defun '(function c-string TagLib_Tag)
-             "taglib_tag_artist")
+            "taglib_tag_artist")
   "Return the artist associated with tag.")
 (defun taglib:tag-artist (tag-object)
   "Return the artist associated with TAG-OBJECT."
   (when (ffi-object-p tag-object)
     (let* ((raw
-            (ffi-call-function taglib:tag_artist tag-object))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:tag_artist tag-object))
+          (result
+           (ffi-get raw)))
       (taglib:tag-free-strings)
       (unless (zerop (length result))
-        result))))
+       result))))
 
 ;; char *taglib_tag_album(const TagLib_Tag *tag);
 (defconst taglib:tag_album
   (ffi-defun '(function c-string TagLib_Tag)
-             "taglib_tag_album")
+            "taglib_tag_album")
   "Return the album associated with tag.")
 (defun taglib:tag-album (tag-object)
   "Return the album associated with TAG-OBJECT."
   (when (ffi-object-p tag-object)
     (let* ((raw
-            (ffi-call-function taglib:tag_album tag-object))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:tag_album tag-object))
+          (result
+           (ffi-get raw)))
       (taglib:tag-free-strings)
       (unless (zerop (length result))
-        result))))
+       result))))
 
 ;; char *taglib_tag_comment(const TagLib_Tag *tag);
 (defconst taglib:tag_comment
   (ffi-defun '(function c-string TagLib_Tag)
-             "taglib_tag_comment")
+            "taglib_tag_comment")
   "Return the comment associated with tag.")
 (defun taglib:tag-comment (tag-object)
   "Return the comment associated with TAG-OBJECT."
   (when (ffi-object-p tag-object)
     (let* ((raw
-            (ffi-call-function taglib:tag_comment tag-object))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:tag_comment tag-object))
+          (result
+           (ffi-get raw)))
       (taglib:tag-free-strings)
       (unless (zerop (length result))
-        result))))
+       result))))
 
 ;; char *taglib_tag_genre(const TagLib_Tag *tag);
 (defconst taglib:tag_genre
   (ffi-defun '(function c-string TagLib_Tag)
-             "taglib_tag_genre")
+            "taglib_tag_genre")
   "Return the genre associated with tag.")
 (defun taglib:tag-genre (tag-object)
   "Return the genre associated with TAG-OBJECT."
   (when (ffi-object-p tag-object)
     (let* ((raw
-            (ffi-call-function taglib:tag_genre tag-object))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:tag_genre tag-object))
+          (result
+           (ffi-get raw)))
       (taglib:tag-free-strings)
       (unless (zerop (length result))
-        result))))
+       result))))
 
 ;; unsigned int taglib_tag_year(const TagLib_Tag *tag);
 (defconst taglib:tag_year
   (ffi-defun '(function int TagLib_Tag)
-             "taglib_tag_year")
+            "taglib_tag_year")
   "Return the year associated with tag.")
 (defun taglib:tag-year (tag-object)
   "Return the year associated with TAG-OBJECT."
   (when (ffi-object-p tag-object)
     (let* ((raw
-            (ffi-call-function taglib:tag_year tag-object))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:tag_year tag-object))
+          (result
+           (ffi-get raw)))
       (unless (zerop result)
-        result))))
+       result))))
 
 ;; unsigned int taglib_tag_track(const TagLib_Tag *tag);
 (defconst taglib:tag_track
   (ffi-defun '(function int TagLib_Tag)
-             "taglib_tag_track")
+            "taglib_tag_track")
   "Return the track number associated with tag.")
 (defun taglib:tag-track (tag-object)
   "Return the track number associated with TAG-OBJECT."
   (when (ffi-object-p tag-object)
     (let* ((raw
-            (ffi-call-function taglib:tag_track tag-object))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:tag_track tag-object))
+          (result
+           (ffi-get raw)))
       (unless (zerop result)
-        result))))
+       result))))
 
 ;;; modifiers
 ;; void taglib_tag_set_title(TagLib_Tag *tag, const char *title);
 (defconst taglib:tag_set_title
   (ffi-defun '(function void TagLib_Tag c-string)
-             "taglib_tag_set_title")
+            "taglib_tag_set_title")
   "Set the title and associate it with tag.")
 (defun taglib:tag-set-title (tag-object title)
   "Set the title to TITLE and associate it with TAG-OBJECT."
   (when (and (stringp title)
-             (ffi-object-p tag-object))
+            (ffi-object-p tag-object))
     (let ((tit (ffi-create-fo 'c-string title)))
       (ffi-call-function taglib:tag_set_title tag-object tit))
     t))
 ;; void taglib_tag_set_artist(TagLib_Tag *tag, const char *artist);
 (defconst taglib:tag_set_artist
   (ffi-defun '(function void TagLib_Tag c-string)
-             "taglib_tag_set_artist")
+            "taglib_tag_set_artist")
   "Set the artist and associate it with tag.")
 (defun taglib:tag-set-artist (tag-object artist)
   "Set the artist to ARTIST and associate it with TAG-OBJECT."
   (when (and (stringp artist)
-             (ffi-object-p tag-object))
+            (ffi-object-p tag-object))
     (let ((art (ffi-create-fo 'c-string artist)))
       (ffi-call-function taglib:tag_set_artist tag-object art))
     t))
 ;; void taglib_tag_set_album(TagLib_Tag *tag, const char *album);
 (defconst taglib:tag_set_album
   (ffi-defun '(function void TagLib_Tag c-string)
-             "taglib_tag_set_album")
+            "taglib_tag_set_album")
   "Set the album and associate it with tag.")
 (defun taglib:tag-set-album (tag-object album)
   "Set the album to ALBUM and associate it with TAG-OBJECT."
   (when (and (stringp album)
-             (ffi-object-p tag-object))
+            (ffi-object-p tag-object))
     (let ((alb (ffi-create-fo 'c-string album)))
       (ffi-call-function taglib:tag_set_album tag-object alb))
     t))
 ;; void taglib_tag_set_comment(TagLib_Tag *tag, const char *comment);
 (defconst taglib:tag_set_comment
   (ffi-defun '(function void TagLib_Tag c-string)
-             "taglib_tag_set_comment")
+            "taglib_tag_set_comment")
   "Set the comment and associate it with tag.")
 (defun taglib:tag-set-comment (tag-object comment)
   "Set the comment to COMMENT and associate it with TAG-OBJECT."
   (when (and (stringp comment)
-             (ffi-object-p tag-object))
+            (ffi-object-p tag-object))
     (let ((com (ffi-create-fo 'c-string comment)))
       (ffi-call-function taglib:tag_set_comment tag-object com))
     t))
 ;; void taglib_tag_set_genre(TagLib_Tag *tag, const char *genre);
 (defconst taglib:tag_set_genre
   (ffi-defun '(function void TagLib_Tag c-string)
-             "taglib_tag_set_genre")
+            "taglib_tag_set_genre")
   "Set the genre and associate it with tag.")
 (defun taglib:tag-set-genre (tag-object genre)
   "Set the genre to GENRE and associate it with TAG-OBJECT."
   (when (and (stringp genre)
-             (ffi-object-p tag-object))
+            (ffi-object-p tag-object))
     (let ((gen (ffi-create-fo 'c-string genre)))
       (ffi-call-function taglib:tag_set_genre tag-object gen))
     t))
 ;; void taglib_tag_set_year(TagLib_Tag *tag, unsigned int year);
 (defconst taglib:tag_set_year
   (ffi-defun '(function void TagLib_Tag int)
-             "taglib_tag_set_year")
+            "taglib_tag_set_year")
   "Set the year and associate it with tag.")
 (defun taglib:tag-set-year (tag-object year)
   "Set the year to YEAR and associate it with TAG-OBJECT."
   (when (and (natnump year)
-             (ffi-object-p tag-object))
+            (ffi-object-p tag-object))
     (let ((yea (ffi-create-fo 'int year)))
       (ffi-call-function taglib:tag_set_year tag-object yea))
     t))
 ;; void taglib_tag_set_track(TagLib_Tag *tag, unsigned int track);
 (defconst taglib:tag_set_track
   (ffi-defun '(function void TagLib_Tag int)
-             "taglib_tag_set_track")
+            "taglib_tag_set_track")
   "Set the track number and associate it with tag.")
 (defun taglib:tag-set-track (tag-object track)
   "Set the track number to TRACK and associate it with TAG-OBJECT."
   (when (and (natnump track)
-             (ffi-object-p tag-object))
+            (ffi-object-p tag-object))
     (let ((tra (ffi-create-fo 'int track)))
       (ffi-call-function taglib:tag_set_track tag-object tra))
     t))
 ;;; constructors
 (defconst taglib:file_audioproperties
   (ffi-defun '(function TagLib_AudioProperties TagLib_File)
-             "taglib_file_audioproperties")
+            "taglib_file_audioproperties")
   "Return the AudioProperties object associated with the file object.")
 (defun taglib:file-audio-properties (file-object)
   "Return the audio properties object associated with FILE-OBJECT."
 
 (defconst taglib:audioproperties_length
   (ffi-defun '(function int TagLib_AudioProperties)
-             "taglib_audioproperties_length")
+            "taglib_audioproperties_length")
   "Return the length of the audioproperties object in seconds.")
 (defun taglib:audioproperties-length (audioprops)
   "Return the length of AUDIOPROPS in seconds."
   (when (ffi-object-p audioprops)
     (let* ((raw
-            (ffi-call-function taglib:audioproperties_length audioprops))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:audioproperties_length audioprops))
+          (result
+           (ffi-get raw)))
       (unless (zerop result)
-        result))))
+       result))))
 
 (defconst taglib:audioproperties_bitrate
   (ffi-defun '(function int TagLib_AudioProperties)
-             "taglib_audioproperties_bitrate")
+            "taglib_audioproperties_bitrate")
   "Return the bitrate of the audioproperties object in kb/s.")
 (defun taglib:audioproperties-bitrate (audioprops)
   "Return the bitrate of AUDIOPROPS in kb/s (kilobit per second)."
   (when (ffi-object-p audioprops)
     (let* ((raw
-            (ffi-call-function taglib:audioproperties_bitrate audioprops))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:audioproperties_bitrate audioprops))
+          (result
+           (ffi-get raw)))
       (unless (zerop result)
-        result))))
+       result))))
 
 (defconst taglib:audioproperties_samplerate
   (ffi-defun '(function int TagLib_AudioProperties)
-             "taglib_audioproperties_samplerate")
+            "taglib_audioproperties_samplerate")
   "Return the samplerate of the audioproperties object in Hz.")
 (defun taglib:audioproperties-samplerate (audioprops)
   "Return the samplerate of AUDIOPROPS in Hz."
   (when (ffi-object-p audioprops)
     (let* ((raw
-            (ffi-call-function taglib:audioproperties_samplerate audioprops))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:audioproperties_samplerate audioprops))
+          (result
+           (ffi-get raw)))
       (unless (zerop result)
-        result))))
+       result))))
 
 (defconst taglib:audioproperties_channels
   (ffi-defun '(function int TagLib_AudioProperties)
-             "taglib_audioproperties_channels")
+            "taglib_audioproperties_channels")
   "Return the number of channels of the audioproperties object.")
 (defun taglib:audioproperties-channels (audioprops)
   "Return the number of channels of AUDIOPROPS."
   (when (ffi-object-p audioprops)
     (let* ((raw
-            (ffi-call-function taglib:audioproperties_channels audioprops))
-           (result
-            (ffi-get raw)))
+           (ffi-call-function taglib:audioproperties_channels audioprops))
+          (result
+           (ffi-get raw)))
       (unless (zerop result)
-        result))))
+       result))))
 
 \f
 ;;; higher level API
   "Return an alist of available properties of FILE."
   (when (file-readable-p file)
     (let* ((result (dllist))
-           (exp-file (expand-file-name file))
-           (tlf (taglib:file-new exp-file)))
+          (exp-file (expand-file-name file))
+          (tlf (taglib:file-new exp-file)))
       (when (and tlf
-                 (null (ffi-null-p tlf)))
-        (let ((tlt (taglib:file-tag tlf))
-              (tlap (taglib:file-audio-properties tlf))
-              (tfuns (list
-                      (cons 'title #'taglib:tag-title)
-                      (cons 'artist #'taglib:tag-artist)
-                      (cons 'album #'taglib:tag-album)
-                      (cons 'comment #'taglib:tag-comment)
-                      (cons 'genre #'taglib:tag-genre)
-                      (cons 'year #'taglib:tag-year)
-                      (cons 'track #'taglib:tag-track)))
-              (apfuns (list
-                       (cons 'length #'taglib:audioproperties-length)
-                       (cons 'bitrate #'taglib:audioproperties-bitrate)
-                       (cons 'samplerate #'taglib:audioproperties-samplerate)
-                       (cons 'channels #'taglib:audioproperties-channels))))
-          (unless (ffi-null-p tlt)
-            (mapc-internal
-             #'(lambda (fun)
-                 (let ((res (funcall (cdr fun) tlt)))
-                   (when res
-                     (dllist-append result (cons (car fun) res)))))
-             tfuns))
-          (unless (ffi-null-p tlap)
-            (mapc-internal
-             #'(lambda (fun)
-                 (let ((res (funcall (cdr fun) tlap)))
-                   (when res
-                     (dllist-append result (cons (car fun) res)))))
-             apfuns)
-            (dllist-prepend result (cons 'type 'audio))))
-        (taglib:file-free tlf)
-        
-        ;; prepend some generic information
-        (dllist-prepend result (cons 'driver 'taglib))
-        (dllist-prepend result (cons 'file exp-file))
-        (dllist-prepend result (cons 'kind 'file)))
+                (null (ffi-null-p tlf)))
+       (let ((tlt (taglib:file-tag tlf))
+             (tlap (taglib:file-audio-properties tlf))
+             (tfuns (list
+                     (cons 'title #'taglib:tag-title)
+                     (cons 'artist #'taglib:tag-artist)
+                     (cons 'album #'taglib:tag-album)
+                     (cons 'comment #'taglib:tag-comment)
+                     (cons 'genre #'taglib:tag-genre)
+                     (cons 'year #'taglib:tag-year)
+                     (cons 'track #'taglib:tag-track)))
+             (apfuns (list
+                      (cons 'length #'taglib:audioproperties-length)
+                      (cons 'bitrate #'taglib:audioproperties-bitrate)
+                      (cons 'samplerate #'taglib:audioproperties-samplerate)
+                      (cons 'channels #'taglib:audioproperties-channels))))
+         (unless (ffi-null-p tlt)
+           (mapc-internal
+            #'(lambda (fun)
+                (let ((res (funcall (cdr fun) tlt)))
+                  (when res
+                    (dllist-append result (cons (car fun) res)))))
+            tfuns))
+         (unless (ffi-null-p tlap)
+           (mapc-internal
+            #'(lambda (fun)
+                (let ((res (funcall (cdr fun) tlap)))
+                  (when res
+                    (dllist-append result (cons (car fun) res)))))
+            apfuns)
+           (dllist-prepend result (cons 'type 'audio))))
+       (taglib:file-free tlf)
+
+       ;; prepend some generic information
+       (dllist-prepend result (cons 'driver 'taglib))
+       (dllist-prepend result (cons 'file exp-file))
+       (dllist-prepend result (cons 'kind 'file)))
 
       (dllist-to-list result))))
 
index 45819cb..9ca2a59 100644 (file)
@@ -45,7 +45,7 @@
 ;;   so be careful.  Need some assistance from IM developers to solve
 ;;   this problem.
 ;;
-;; 
+;;
 ;;}}}
 ;;; Code:
 \f
@@ -54,8 +54,8 @@
 (eval-when-compile
   (globally-declare-boundp
    '(operations-list undo-list buffer-file-name image-wand preview-wand
-                     preview-region preview-extent
-                     find-file-magic-files-alist)))
+                    preview-region preview-extent
+                    find-file-magic-files-alist)))
 
 (require 'ffi)
 (require 'wid-edit)
@@ -63,7 +63,7 @@
 (defvar Wand-ffio-as-image-data
   (valid-instantiator-p
    (vector 'rawrgb :data (make-ffi-object 'pointer)
-           :pixel-width 2 :pixel-height 2) 'image))
+          :pixel-width 2 :pixel-height 2) 'image))
 
 (defvar Wand-GM-p nil
   "Non-nil if using GraphicsMagick.")
@@ -75,7 +75,7 @@
 (or (ffi-load-library "libWand")
     (ffi-load-library "libMagickWand")
     (and (ffi-load "libGraphicsMagickWand")
-         (setq Wand-GM-p t)))
+        (setq Wand-GM-p t)))
 
 ;;}}}
 ;;{{{ [+] FFI for MagickWand
   "Create a string from CamelCased keyword KW.
 Strips last N words."
   (let ((case-fold-search nil)
-        (kws (substring (symbol-name kw) 1)))
+       (kws (substring (symbol-name kw) 1)))
     (while (string-match "[A-Z]" kws 1)
-      (setq kws (replace-match (concat "-" (downcase (match-string 0 kws))) 
-                               t nil kws)))
+      (setq kws (replace-match (concat "-" (downcase (match-string 0 kws)))
+                              t nil kws)))
     (mapconcat 'identity (butlast (split-string (downcase kws) "-") n) "-")))
 
 (defmacro wand-camel-case-kw-completion (n)
@@ -310,7 +310,7 @@ Strips last N words."
 
 (defconst WandCompositeOperator-completion-table
   (mapcar (wand-camel-case-kw-completion 2)
-          (mapcar #'car (ffi-enum-values 'WandCompositeOperator)))
+         (mapcar #'car (ffi-enum-values 'WandCompositeOperator)))
   "Completion table for composite operator.")
 
 (define-ffi-enum FillRule
@@ -481,7 +481,7 @@ Strips last N words."
 
 (defconst MagickPreviewType-completion-table
   (mapcar (wand-camel-case-kw-completion 1)
-          (mapcar #'car (ffi-enum-values 'MagickPreviewType)))
+         (mapcar #'car (ffi-enum-values 'MagickPreviewType)))
   "Completion table for preview types.")
 
 ;;}}}
@@ -509,8 +509,8 @@ Strips last N words."
   (let ((mt (Wand:MagickToMime format)))
     (unless (ffi-null-p mt)
       (unwind-protect
-          (ffi-get mt :type 'c-string)
-        (Wand:DestroyString mt)))))
+         (ffi-get mt :type 'c-string)
+       (Wand:DestroyString mt)))))
 
 (defun Wand:image-mime-type (wand)
   "Return mime-type for the WAND."
@@ -550,7 +550,7 @@ Strips last N words."
   "With allocated WAND do FORMS."
   `(let ((,wand (Wand:make-wand)))
      (unwind-protect
-         (progn ,@forms)
+        (progn ,@forms)
        (Wand:delete-wand ,wand))))
 (put 'Wand-with-wand 'lisp-indent-function 'defun)
 
@@ -574,7 +574,7 @@ Strips last N words."
   "Return info about the image stored in WAND."
   (let ((ii (Wand:MagickIdentifyImage wand)))
     (unwind-protect
-        (ffi-get ii :type 'c-string)
+       (ffi-get ii :type 'c-string)
       (Wand:RelinquishMemory ii))))
 
 ;; MagickResetImagePage() resets the Wand page canvas and position.
@@ -597,13 +597,13 @@ PROP can be one of: `base', `channels', `colorspace', `depth',
 `directory', `extension', `height', `input', `magick', `name',
 `page', `size', `width', `xresolution', `yresolution'."
   (when (member prop '("group" "kurtosis" "max" "mean"
-                       "min" "output" "scene" "skewness"
-                       "standard-deviation" "standard_deviation"
-                       "unique" "zero"))
+                      "min" "output" "scene" "skewness"
+                      "standard-deviation" "standard_deviation"
+                      "unique" "zero"))
     (error "Unsupported magick property" prop))
   (let ((rt (Wand:GetMagickProperty
-             (ffi-null-pointer) (MagickWand-private->images wand)
-             prop)))
+            (ffi-null-pointer) (MagickWand-private->images wand)
+            prop)))
     (unless (ffi-null-p rt)
       (ffi-get rt :type 'c-string))))
 
@@ -674,7 +674,7 @@ PROP can be one of: `base', `channels', `colorspace', `depth',
 (defun Wand:read-image-blob (wand blob)
   "Read image from BLOB and associate it with WAND."
   (let* ((lb (length blob))
-         (fob (make-ffi-object 'pointer (1+ lb))))
+        (fob (make-ffi-object 'pointer (1+ lb))))
     (ffi-store fob 0 'c-string blob)
     (Wand:MagickReadImageBlob wand fob lb)))
 
@@ -699,9 +699,9 @@ WARNING: this will block untill display exits, so be careful."
   "Return WAND's direct image data according to format.
 Use \(setf \(Wand:image-format w\) FMT\) to set format."
   (let* ((len (make-ffi-object 'unsigned-int))
-         (data (Wand:GetImageBlob wand (ffi-address-of len))))
+        (data (Wand:GetImageBlob wand (ffi-address-of len))))
     (unwind-protect
-        (ffi-get data :type (cons 'c-data (ffi-get len)))
+       (ffi-get data :type (cons 'c-data (ffi-get len)))
       (Wand:RelinquishMemory data))))
 
 (cffi:defcfun ("MagickWriteImage" Wand:MagickWriteImage) MagickBooleanType
@@ -721,19 +721,19 @@ Use \(setf \(Wand:image-format w\) FMT\) to set format."
 ;;{{{  `-- Image format operations
 
 (cffi:defcfun ("MagickQueryFormats"
-               Wand:QueryFormats) (pointer c-string)
-               (pattern c-string)
-               (num-formats (pointer unsigned-long)))
+              Wand:QueryFormats) (pointer c-string)
+              (pattern c-string)
+              (num-formats (pointer unsigned-long)))
 
 (defun Wand:query-formats (pattern)
   "Return list of supported formats that match PATTERN.
 Use \"*\" to query all available formats."
   (let* ((nf (make-ffi-object 'unsigned-long))
-         (fmts (Wand:QueryFormats pattern (ffi-address-of nf))))
+        (fmts (Wand:QueryFormats pattern (ffi-address-of nf))))
     (loop for n from 0 below (ffi-get nf)
       collect (ffi-get
-               (ffi-get fmts :off (* n (ffi-size-of-type 'pointer)))
-               :type 'c-string))))
+              (ffi-get fmts :off (* n (ffi-size-of-type 'pointer)))
+              :type 'c-string))))
 
 (cffi:defcfun ("MagickGetFormat" Wand:wand-format) c-string
   (wand MagickWand))
@@ -798,7 +798,7 @@ Use \(setf \(Wand:image-format w\) FMT\) to set new one."
   "With allocated pixel wand PW do FORMS."
   `(let ((,pw (Wand:NewPixelWand)))
      (unwind-protect
-         (progn ,@forms)
+        (progn ,@forms)
        (Wand:DestroyPixelWand ,pw))))
 (put 'Wand-with-pixel-wand 'lisp-indent-function 'defun)
 
@@ -812,10 +812,10 @@ Use \(setf \(Wand:image-format w\) FMT\) to set new one."
 (defun Wand:pixel-hsl (pw)
   "Return HSL for pixel wand PW."
   (let ((hue (make-ffi-object 'double))
-        (sat (make-ffi-object 'double))
-        (light (make-ffi-object 'double)))
+       (sat (make-ffi-object 'double))
+       (light (make-ffi-object 'double)))
     (Wand:PixelGetHSL pw (ffi-address-of hue) (ffi-address-of sat)
-                      (ffi-address-of light))
+                     (ffi-address-of light))
     (mapcar #'ffi-get (list hue sat light))))
 
 (defsetf Wand:pixel-hsl (pw) (hsl)
@@ -845,13 +845,13 @@ Use \(setf \(Wand:image-format w\) FMT\) to set new one."
 (defun Wand:pixel-rgb-components (pw)
   "Return RGB components for pixel wand PW."
   (mapcar #'(lambda (c) (int (* (funcall c pw) 65535.0)))
-          '(Wand:pixel-red Wand:pixel-green Wand:pixel-blue)))
+         '(Wand:pixel-red Wand:pixel-green Wand:pixel-blue)))
 
 (defsetf Wand:pixel-rgb-components (pw) (rgb)
   "For pixel wand PW set RGB components."
   `(mapcar* #'(lambda (sf c) (funcall sf ,pw (/ c 65535.0)))
-            '(Wand:PixelSetRed Wand:PixelSetGreen Wand:PixelSetBlue)
-            ,rgb))
+           '(Wand:PixelSetRed Wand:PixelSetGreen Wand:PixelSetBlue)
+           ,rgb))
 
 ;; PixelGetColorAsString() returns the color of the pixel wand as a
 ;; string.
@@ -903,14 +903,14 @@ Use \(setf \(Wand:image-format w\) FMT\) to set new one."
 FROM-WIDTH, FROM-HEIGHT, DELTA-WIDTH, DELTA-HEIGHT specifies region to
 fetch data from."
   (let* ((tsz (ecase img-type (rawrgb 3) (rawrgba 4)))
-         (mapn (ecase img-type (rawrgb "RGB") (rawrgba "RGBA")))
-         (target (make-ffi-object 'c-data (* delta-width delta-height tsz))))
+        (mapn (ecase img-type (rawrgb "RGB") (rawrgba "RGBA")))
+        (target (make-ffi-object 'c-data (* delta-width delta-height tsz))))
     (when (Wand:MagickGetImagePixels
-           wand from-width from-height delta-width delta-height
-           mapn :char-pixel target)
+          wand from-width from-height delta-width delta-height
+          mapn :char-pixel target)
       (if Wand-ffio-as-image-data
-          target
-        (ffi-get target)))))
+         target
+       (ffi-get target)))))
 
 (defun Wand:get-image-pixels (wand)
   "Return WAND's raw string of image pixel data (RGB triples)."
@@ -934,7 +934,7 @@ fetch data from."
   "Extract colors from SS string.
 Return list of lists of N int elements representing RBG(A) values."
   (let ((cls (mapcar #'char-to-int (string-to-list ss)))
-        (rls nil))
+       (rls nil))
     (while cls
       (push (subseq cls 0 (or n 3)) rls)
       (setq cls (nthcdr (or n 3) cls)))
@@ -944,11 +944,11 @@ Return list of lists of N int elements representing RBG(A) values."
   "Create pixels string from CLS.
 CLS is list of lists of N int elements representing RBG(A) values."
   (mapconcat #'identity
-             (mapcan #'(lambda (els)
-                         (mapcar #'char-to-string
-                                 (mapcar #'int-to-char els)))
-                     cls)
-             ""))
+            (mapcan #'(lambda (els)
+                        (mapcar #'char-to-string
+                                (mapcar #'int-to-char els)))
+                    cls)
+            ""))
 
 ;; MagickConstituteImage() adds an image to the wand comprised of the
 ;; pixel data you supply. The pixel data must be in scanline order
@@ -1162,8 +1162,8 @@ effect to wipe hard contrasts."
   (wand MagickWand) (brightness double) (saturation double) (hue double))
 
 (defun* Wand:modulate-image (wand &key (brightness 100.0)
-                                  (saturation 100.0)
-                                  (hue 100.0))
+                                 (saturation 100.0)
+                                 (hue 100.0))
   (Wand:MagickModulateImage wand brightness saturation hue))
 
 ;; Separate a two-color high contrast image.
@@ -1214,9 +1214,9 @@ effect to wipe hard contrasts."
 ;; Blur CHANNEL in the image associated with WAND by RADIUS
 ;; pixels with derivation SIGMA.
 (cffi:defcfun ("MagickGaussianBlurImageChannel"
-               Wand:gaussian-blur-image-channel) MagickBooleanType
-               (wand MagickWand) (channel MagickChannelType)
-               (radius double) (sigma double))
+              Wand:gaussian-blur-image-channel) MagickBooleanType
+              (wand MagickWand) (channel MagickChannelType)
+              (radius double) (sigma double))
 
 ;; Blur the image associated with WAND.
 ;; The RADIUS argument is a float and measured in pixels.
@@ -1263,7 +1263,7 @@ effect to wipe hard contrasts."
 ;; defined by RADIUS and SIGMA.  The strength of sharpening is controlled
 ;; by AMOUNT and THRESHOLD.
 (cffi:defcfun ("MagickUnsharpMaskImageChannel"
-               Wand:unsharp-mask-image-channel)
+              Wand:unsharp-mask-image-channel)
   MagickBooleanType
   (wand MagickWand) (channel MagickChannelType)
   (radius double) (sigma double) (amount double) (threshold double))
@@ -1276,7 +1276,7 @@ effect to wipe hard contrasts."
   (Wand:MagickNegateImage wand greyp))
 
 (cffi:defcfun ("MagickNegateImageChannel"
-               Wand:MagickNegateImageChannel)
+              Wand:MagickNegateImageChannel)
   MagickBooleanType
   (wand MagickWand) (channel MagickChannelType) (greyp MagickBooleanType))
 (defun Wand:negate-image-channel (wand channel &optional greyp)
@@ -1306,7 +1306,7 @@ effect to wipe hard contrasts."
 (defun Wand:image-size (wand)
   "Return size of the image, associated with WAND."
   (let ((w (make-ffi-object 'unsigned-long))
-        (h (make-ffi-object 'unsigned-long)))
+       (h (make-ffi-object 'unsigned-long)))
     (when (Wand:MagickGetSize wand (ffi-address-of w) (ffi-address-of h))
       (cons (ffi-get w) (ffi-get h)))))
 (defsetf Wand:image-size (wand) (size)
@@ -1324,9 +1324,9 @@ effect to wipe hard contrasts."
   "Fetch strings from strings array STRS of length SLEN."
   (unless (ffi-null-p strs)
     (unwind-protect
-        (mapcar #'(lambda (pr)
-                    (ffi-get pr :type 'c-string))
-                (ffi-get strs :type (list 'array 'pointer slen)))
+       (mapcar #'(lambda (pr)
+                   (ffi-get pr :type 'c-string))
+               (ffi-get strs :type (list 'array 'pointer slen)))
       (Wand:RelinquishMemory strs))))
 
 ;; Profiles
@@ -1338,8 +1338,8 @@ effect to wipe hard contrasts."
 (defun Wand:image-profiles (wand pattern)
   "Get list of WAND's profiles matching PATTERN."
   (let* ((plen (make-ffi-object 'unsigned-long))
-         (profs (Wand:MagickGetImageProfiles
-                 wand pattern (ffi-address-of plen))))
+        (profs (Wand:MagickGetImageProfiles
+                wand pattern (ffi-address-of plen))))
     (Wand-fetch-relinquish-strings profs (ffi-get plen))))
 
 (cffi:defcfun ("MagickGetImageProfile" Wand:MagickGetImageProfile) pointer
@@ -1358,50 +1358,50 @@ effect to wipe hard contrasts."
 (defun Wand:image-profile-iptc (wand)
   "Fetch IPTC profile from WAND in lisp-friendly form."
   (let* ((plen (make-ffi-object 'unsigned-int))
-         (prof (Wand:MagickGetImageProfile wand "iptc" (ffi-address-of plen)))
-         (rlen (ffi-get plen)) (coff 0) (rv nil))
+        (prof (Wand:MagickGetImageProfile wand "iptc" (ffi-address-of plen)))
+        (rlen (ffi-get plen)) (coff 0) (rv nil))
     (unless (ffi-null-p prof)
       (unwind-protect
-          (flet ((getbyte () (prog1
-                                 (ffi-get prof :off coff :type 'byte)
-                               (incf coff))))
-            ;; 28 - must start any iptc header
-            (while (and (< coff rlen) (= (getbyte) 28))
-              (let* ((itype (getbyte)) (idset (getbyte))
-                     (l1 (getbyte)) (l2 (getbyte))
-                     (ln (logior (ash l1 8) l2)))
-                (when (= itype 2)
-                  ;; only string type supported
-                  (push (cons (cdr (assq idset Wand-iptc-names-table))
-                              (ffi-get prof :off coff :type `(c-data . ,ln)))
-                        rv))
-                (incf coff ln)))
-            rv)
-        (Wand:RelinquishMemory prof)))))
+         (flet ((getbyte () (prog1
+                                (ffi-get prof :off coff :type 'byte)
+                              (incf coff))))
+           ;; 28 - must start any iptc header
+           (while (and (< coff rlen) (= (getbyte) 28))
+             (let* ((itype (getbyte)) (idset (getbyte))
+                    (l1 (getbyte)) (l2 (getbyte))
+                    (ln (logior (ash l1 8) l2)))
+               (when (= itype 2)
+                 ;; only string type supported
+                 (push (cons (cdr (assq idset Wand-iptc-names-table))
+                             (ffi-get prof :off coff :type `(c-data . ,ln)))
+                       rv))
+               (incf coff ln)))
+           rv)
+       (Wand:RelinquishMemory prof)))))
 
 (defun Wand:image-save-iptc-profile (w iptc)
   "For wand W store IPTC profile."
   (let ((oolen (reduce #'(lambda (e1 e2)
-                           (+ e1 5 (length (cdr e2))))
-                       iptc :initial-value 0)))
+                          (+ e1 5 (length (cdr e2))))
+                      iptc :initial-value 0)))
     (when (> oolen 0)
       (let ((prof (make-ffi-object 'pointer oolen))
-            (coff 0))
-        (flet ((savebyte (byte)
-                 (prog1
-                     (ffi-store prof coff 'byte byte)
-                   (incf coff))))
-          (loop for ipel in iptc do
-            (savebyte 28) (savebyte 2)
-            (savebyte (car (find (car ipel)
-                                 Wand-iptc-names-table :key #'cdr)))
-            (let* ((ln (length (cdr ipel)))
-                   (l1 (ash (logand ln #xff00) -8))
-                   (l2 (logand ln #x00ff)))
-              (savebyte l1) (savebyte l2)
-              (ffi-store prof coff 'c-string (cdr ipel))
-              (incf coff ln))))
-        (Wand:MagickSetImageProfile w "iptc" prof oolen)))
+           (coff 0))
+       (flet ((savebyte (byte)
+                (prog1
+                    (ffi-store prof coff 'byte byte)
+                  (incf coff))))
+         (loop for ipel in iptc do
+           (savebyte 28) (savebyte 2)
+           (savebyte (car (find (car ipel)
+                                Wand-iptc-names-table :key #'cdr)))
+           (let* ((ln (length (cdr ipel)))
+                  (l1 (ash (logand ln #xff00) -8))
+                  (l2 (logand ln #x00ff)))
+             (savebyte l1) (savebyte l2)
+             (ffi-store prof coff 'c-string (cdr ipel))
+             (incf coff ln))))
+       (Wand:MagickSetImageProfile w "iptc" prof oolen)))
     ))
 
 ;;}}}
@@ -1415,8 +1415,8 @@ effect to wipe hard contrasts."
 (defun Wand:image-properties (w pattern)
   "Return list of image properties that match PATTERN."
   (let* ((plen (make-ffi-object 'unsigned-long))
-         (props (Wand:MagickGetImageProperties
-                 w pattern (ffi-address-of plen))))
+        (props (Wand:MagickGetImageProperties
+                w pattern (ffi-address-of plen))))
     (Wand-fetch-relinquish-strings props (ffi-get plen))))
 
 (cffi:defcfun ("MagickGetImageProperty" Wand:MagickGetImageProperty) pointer
@@ -1432,8 +1432,8 @@ Use \(setf \(Wand:image-property w prop\) VAL\) to set property."
   (let ((pv (Wand:MagickGetImageProperty w property)))
     (unless (ffi-null-p pv)
       (unwind-protect
-          (ffi-get pv :type 'c-string)
-        (Wand:RelinquishMemory pv)))))
+         (ffi-get pv :type 'c-string)
+       (Wand:RelinquishMemory pv)))))
 
 (defsetf Wand:image-property (w prop) (val)
   `(Wand:MagickSetImageProperty ,w ,prop ,val))
@@ -1450,32 +1450,32 @@ Use \(setf \(Wand:image-property w prop\) VAL\) to set property."
   "Run properties editor."
   (interactive)
   (let* ((iw image-wand)
-         (props (remove-if-not
-                 #'(lambda (prop)
-                     (string-match Wand-mode-properties-pattern prop))
-                 (Wand:image-properties iw ""))))
+        (props (remove-if-not
+                #'(lambda (prop)
+                    (string-match Wand-mode-properties-pattern prop))
+                (Wand:image-properties iw ""))))
     (save-window-excursion
       (with-temp-buffer
-        (save-excursion
-          (mapc #'(lambda (prop)
-                    (insert prop ": " (Wand:image-property iw prop) "\n"))
-                props))
-        (pop-to-buffer (current-buffer))
-        (text-mode)
-        (message "Press %s when done, or %s to cancel"
-                 (sorted-key-descriptions
-                  (where-is-internal 'exit-recursive-edit))
-                 (sorted-key-descriptions
-                  (where-is-internal 'abort-recursive-edit)))
-        (recursive-edit)
-
-        ;; User pressed C-M-c, parse buffer and store new props
-        (goto-char (point-min))
-        (while (not (eobp))
-          (let* ((st (buffer-substring (point-at-bol) (point-at-eol)))
-                 (pv (split-string st ": ")))
-            (setf (Wand:image-property iw (first pv)) (second pv)))
-          (next-line 1))))))
+       (save-excursion
+         (mapc #'(lambda (prop)
+                   (insert prop ": " (Wand:image-property iw prop) "\n"))
+               props))
+       (pop-to-buffer (current-buffer))
+       (text-mode)
+       (message "Press %s when done, or %s to cancel"
+                (sorted-key-descriptions
+                 (where-is-internal 'exit-recursive-edit))
+                (sorted-key-descriptions
+                 (where-is-internal 'abort-recursive-edit)))
+       (recursive-edit)
+
+       ;; User pressed C-M-c, parse buffer and store new props
+       (goto-char (point-min))
+       (while (not (eobp))
+         (let* ((st (buffer-substring (point-at-bol) (point-at-eol)))
+                (pv (split-string st ": ")))
+           (setf (Wand:image-property iw (first pv)) (second pv)))
+         (next-line 1))))))
 
 ;;}}}
 ;;{{{  `-- Image clip mask
@@ -1568,7 +1568,7 @@ If CM is nil or null-pointer then unset clip mask."
   "With allocated drawing wand DW do FORMS."
   `(let ((,dw (Wand:make-drawing-wand)))
      (unwind-protect
-         (progn ,@forms)
+        (progn ,@forms)
        (Wand:delete-drawing-wand ,dw))))
 (put 'Wand-with-drawing-wand 'lisp-indent-function 'defun)
 
@@ -1576,10 +1576,10 @@ If CM is nil or null-pointer then unset clip mask."
 (defun Wand:draw-font (dw)
   "For drawing wand DW return draw font as wand-font object."
   (make-wand-font :family (Wand:draw-font-family dw)
-                  :size (Wand:draw-font-size dw)
-                  :weight (Wand:draw-font-weight dw)
-                  :stretch (Wand:draw-font-stretch dw)
-                  :style (Wand:draw-font-style dw)))
+                 :size (Wand:draw-font-size dw)
+                 :weight (Wand:draw-font-weight dw)
+                 :stretch (Wand:draw-font-stretch dw)
+                 :style (Wand:draw-font-style dw)))
 
 (defsetf Wand:draw-font (dw) (fn)
   "For drawing wand DW set font to FN.
@@ -1587,10 +1587,10 @@ FN might be a string or wand-font object."
   `(if (stringp ,fn)
        (setf (Wand:draw-font-font ,dw) ,fn)
      (let ((fm (wand-font-family ,fn))
-           (sz (wand-font-size ,fn))
-           (weight (wand-font-weight ,fn))
-           (stretch (wand-font-stretch ,fn))
-           (style (wand-font-style ,fn)))
+          (sz (wand-font-size ,fn))
+          (weight (wand-font-weight ,fn))
+          (stretch (wand-font-stretch ,fn))
+          (style (wand-font-style ,fn)))
        (when fm (setf (Wand:draw-font-family ,dw) fm))
        (when sz (setf (Wand:draw-font-size ,dw) sz))
        (when weight (setf (Wand:draw-font-weight ,dw) weight))
@@ -1721,13 +1721,13 @@ FN might be a string or wand-font object."
 
 (defun Wand:points-PointInfo (points)
   (let* ((plen (length points))
-         (coords (make-ffi-object (list 'array 'PointInfo plen))))
+        (coords (make-ffi-object (list 'array 'PointInfo plen))))
     (dotimes (n plen)
       (let ((poi (make-ffi-object 'PointInfo))
-            (npo (nth n points)))
-        (setf (PointInfo->x poi) (float (car npo))
-              (PointInfo->y poi) (float (cdr npo)))
-        (ffi-aset coords n poi)))
+           (npo (nth n points)))
+       (setf (PointInfo->x poi) (float (car npo))
+             (PointInfo->y poi) (float (cdr npo)))
+       (ffi-aset coords n poi)))
     coords))
 
 (defun Wand:draw-polygon (dw points)
@@ -1745,7 +1745,7 @@ FN might be a string or wand-font object."
 
 (defun Wand:draw-segment (dw seg)
   (Wand:draw-line dw (float (caar seg)) (float (cdar seg))
-                  (float (cadr seg)) (float (cddr seg))))
+                 (float (cadr seg)) (float (cddr seg))))
 
 (defun Wand:draw-segments (dw segs)
   (mapc #'(lambda (seg) (Wand:draw-segment dw seg)) segs))
@@ -1885,9 +1885,9 @@ FN might be a string or wand-font object."
 (defun Wand:emacs-image-internal (wand img-type x y w h)
   "Return Emacs image spec."
   (vector img-type
-          :data (Wand:get-image-pixels-internal wand img-type x y w h)
-          :pixel-width w
-          :pixel-height h))
+         :data (Wand:get-image-pixels-internal wand img-type x y w h)
+         :pixel-width w
+         :pixel-height h))
 
 (defun Wand:emacs-image (wand)
   "Return Emacs image for the WAND."
@@ -1908,9 +1908,9 @@ FN might be a string or wand-font object."
 (defun Wand:correct-orientation (wand)
   "Automatically rotate WAND image according to exif:Orientation."
   (let* ((orient (Wand:image-property wand "exif:Orientation"))
-         (angle (cond ((string= orient "6") 90)
-                      ((string= orient "3") 180)
-                      ((string= orient "8") -90))))
+        (angle (cond ((string= orient "6") 90)
+                     ((string= orient "3") 180)
+                     ((string= orient "8") -90))))
     (when angle
       (setf (Wand:image-property wand "exif:Orientation") "1")
       (Wand-operation-apply 'rotate wand angle))))
@@ -1923,17 +1923,17 @@ is used.
 Return non-nil if fiting was performed."
   (unless scaler (setq scaler #'Wand:scale-image))
   (let* ((width (Wand:image-width wand))
-         (height (Wand:image-height wand))
-         (prop (/ (float width) (float height)))
-         rescale)
+        (height (Wand:image-height wand))
+        (prop (/ (float width) (float height)))
+        rescale)
     (when (or force (< max-width width))
       (setq width max-width
-            height (round (/ max-width prop))
-            rescale t))
+           height (round (/ max-width prop))
+           rescale t))
     (when (or force (< max-height height))
       (setq width (round (* max-height prop))
-            height max-height
-            rescale t))
+           height max-height
+           rescale t))
 
     (when rescale
       (funcall scaler wand width height))
@@ -1941,7 +1941,7 @@ Return non-nil if fiting was performed."
 
 (defun Wand-mode-preview-glyph (wand)
   (let ((off-x (get wand 'offset-x))
-        (off-y (get wand 'offset-y)))
+       (off-y (get wand 'offset-y)))
     (Wand:glyph-internal
      wand off-x off-y
      (- (Wand:image-width wand) off-x)
@@ -2145,13 +2145,13 @@ your own scaler with `Wand-make-scaler'."
     "---"
     ("Region" :filter Wand-menu-region-operations)
     ("Transform" :filter (lambda (not-used)
-                           (Wand-menu-generate 'transform-operation)))
+                          (Wand-menu-generate 'transform-operation)))
     ("Effects" :filter (lambda (not-used)
-                         (Wand-menu-generate 'effect-operation)))
+                        (Wand-menu-generate 'effect-operation)))
     ("Enhance" :filter (lambda (not-used)
-                         (Wand-menu-generate 'enhance-operation)))
+                        (Wand-menu-generate 'enhance-operation)))
     ("F/X" :filter (lambda (not-used)
-                     (Wand-menu-generate 'f/x-operation)))
+                    (Wand-menu-generate 'f/x-operation)))
     "---"
     ["Quit" Wand-mode-quit])
   "Menu for Wand display mode.")
@@ -2159,39 +2159,39 @@ your own scaler with `Wand-make-scaler'."
 (defun Wand-menu-page-navigations (not-used)
   "Generate menu for page navigation."
   (list ["Next Page" Wand-mode-next-page
-         :active (Wand:has-next-image image-wand)]
-        ["Previous Page" Wand-mode-prev-page
-         :active (Wand:has-prev-image image-wand)]
-        ["First Page" Wand-mode-first-page
-         :active (/= (Wand:iterator-index image-wand) 0) ]
-        ["Last Page" Wand-mode-last-page
-         :active (/= (Wand:iterator-index image-wand)
-                     (1- (Wand:images-num image-wand))) ]
-        "-"
-        ["Goto Page" Wand-mode-goto-page
-         :active (/= (Wand:images-num image-wand) 1)]))
+        :active (Wand:has-next-image image-wand)]
+       ["Previous Page" Wand-mode-prev-page
+        :active (Wand:has-prev-image image-wand)]
+       ["First Page" Wand-mode-first-page
+        :active (/= (Wand:iterator-index image-wand) 0) ]
+       ["Last Page" Wand-mode-last-page
+        :active (/= (Wand:iterator-index image-wand)
+                    (1- (Wand:images-num image-wand))) ]
+       "-"
+       ["Goto Page" Wand-mode-goto-page
+        :active (/= (Wand:images-num image-wand) 1)]))
 
 (defun Wand-menu-region-operations (not-used)
   "Generate menu for region operations."
   (mapcar #'(lambda (ro)
-              (vector (get ro 'menu-name) ro :active 'preview-region))
-          (apropos-internal "^Wand-mode-"
-                            #'(lambda (c)
-                                (and (commandp c)
-                                     (get c 'region-operation)
-                                     (get c 'menu-name))))))
+             (vector (get ro 'menu-name) ro :active 'preview-region))
+         (apropos-internal "^Wand-mode-"
+                           #'(lambda (c)
+                               (and (commandp c)
+                                    (get c 'region-operation)
+                                    (get c 'menu-name))))))
 
 (defun Wand-mode-commands-by-tag (tag)
   "Return list of wand command for which TAG property is set."
   (apropos-internal "^Wand-mode-"
-                    #'(lambda (c) (and (commandp c) (get c tag)))))
+                   #'(lambda (c) (and (commandp c) (get c tag)))))
 
 (defun Wand-menu-generate (tag)
   "Generate menu structure for TAG commands."
   (mapcar #'(lambda (to)
-              (vector (get to 'menu-name) to))
-          (remove-if-not #'(lambda (c) (get c tag))
-                         (Wand-mode-commands-by-tag 'menu-name))))
+             (vector (get to 'menu-name) to))
+         (remove-if-not #'(lambda (c) (get c tag))
+                        (Wand-mode-commands-by-tag 'menu-name))))
 
 (defun Wand-mode-popup-menu (be)
   "Popup wand menu."
@@ -2211,15 +2211,15 @@ ARGS specifies arguments to operation, first must always be wand."
 (defmacro Wand-possible-for-region (wand &rest body)
   `(if preview-region
        (let* ((iwand ,wand)
-              (region (Wand-mode-image-region))
-              (wand (apply #'Wand:image-region iwand region)))
-         (unwind-protect
-             (progn
-               ,@body
-               (Wand:image-composite iwand wand :CopyCompositeOp
-                                     (nth 2 region) (nth 3 region)))
-           (setq preview-region nil)
-           (Wand:delete-wand wand)))
+             (region (Wand-mode-image-region))
+             (wand (apply #'Wand:image-region iwand region)))
+        (unwind-protect
+            (progn
+              ,@body
+              (Wand:image-composite iwand wand :CopyCompositeOp
+                                    (nth 2 region) (nth 3 region)))
+          (setq preview-region nil)
+          (Wand:delete-wand wand)))
      ,@body))
 (put 'Wand-possible-for-region 'lisp-indent-function 'defun)
 
@@ -2390,7 +2390,7 @@ Return a new wand."
   "Extract RGB pixels from WAND."
   (let ((target (make-ffi-object 'c-data (* w h 3))))
     (when (Wand:MagickGetImagePixels
-           wand x y w h "RGB" :char-pixel target)
+          wand x y w h "RGB" :char-pixel target)
       (Wand:pixels-extract-colors (ffi-get target) 3))))
 
 (defun Wand:get-rgb-pixel-at (wand x y)
@@ -2401,23 +2401,23 @@ Return a new wand."
   "Simple red PIXELS fixator.
 Normalize pixel color if it is too 'red'."
   (let* ((rchan '(0.1 0.6 0.3))
-         (gchan '(0.0 1.0 0.0))
-         (bchan '(0.0 0.0 1.0))
-         (rnorm (/ 1.0 (apply #'+ rchan)))
-         (gnorm (/ 1.0 (apply #'+ gchan)))
-         (bnorm (/ 1.0 (apply #'+ bchan))))
+        (gchan '(0.0 1.0 0.0))
+        (bchan '(0.0 0.0 1.0))
+        (rnorm (/ 1.0 (apply #'+ rchan)))
+        (gnorm (/ 1.0 (apply #'+ gchan)))
+        (bnorm (/ 1.0 (apply #'+ bchan))))
     (flet ((normalize (chan norm r g b)
-             (min 255 (int (* norm (+ (* (first chan) r)
-                                      (* (second chan) g)
-                                      (* (third chan) b)))))))
+            (min 255 (int (* norm (+ (* (first chan) r)
+                                     (* (second chan) g)
+                                     (* (third chan) b)))))))
       (mapcar #'(lambda (pixel-value)
-                  (multiple-value-bind (r g b) pixel-value
-                    (if (>= r (* Wand-mode-redeye-threshold g))
-                        (list (normalize rchan rnorm r g b)
-                              (normalize gchan gnorm r g b)
-                              (normalize bchan bnorm r g b))
-                      (list r g b))))
-              pixels))))
+                 (multiple-value-bind (r g b) pixel-value
+                   (if (>= r (* Wand-mode-redeye-threshold g))
+                       (list (normalize rchan rnorm r g b)
+                             (normalize gchan gnorm r g b)
+                             (normalize bchan bnorm r g b))
+                     (list r g b))))
+             pixels))))
 
 (defun Wand-mode-redeye-blur-radius (w h)
   "Return apropriate blur radius for region of width W and height H.
@@ -2433,29 +2433,29 @@ too small for small regions."
       (Wand:MagickConstituteImage
        cw w h "RGB" :char-pixel
        (let ((stor (make-ffi-object 'c-data (* w h 3))))
-         (ffi-set stor (Wand:pixels-arrange-colors
-                        (Wand-fix-red-pixels
-                         (Wand:get-image-rgb-pixels wand x y w h))))
-         stor))
+        (ffi-set stor (Wand:pixels-arrange-colors
+                       (Wand-fix-red-pixels
+                        (Wand:get-image-rgb-pixels wand x y w h))))
+        stor))
 
       ;; Limit blur effect to ellipse at the center of REGION by
       ;; setting clip mask
       (let ((mask (Wand:copy-wand cw)))
-        (unwind-protect
-            (progn
-              (Wand-with-drawing-wand dw
-                (Wand-with-pixel-wand pw
-                  (setf (Wand:pixel-color pw) "white")
-                  (setf (Wand:draw-fill-color dw) pw)
-                  (Wand:draw-color dw 0.0 0.0 :ResetMethod))
-                (Wand-with-pixel-wand pw
-                  (setf (Wand:pixel-color pw) "black")
-                  (setf (Wand:draw-fill-color dw) pw))
-                (Wand:draw-ellipse
-                 dw (/ w 2.0) (/ h 2.0) (/ w 2.0) (/ h 2.0) 0.0 360.0)
-                (Wand:MagickDrawImage mask dw))
-              (setf (Wand:clip-mask cw) mask))
-          (Wand:delete-wand mask)))
+       (unwind-protect
+           (progn
+             (Wand-with-drawing-wand dw
+               (Wand-with-pixel-wand pw
+                 (setf (Wand:pixel-color pw) "white")
+                 (setf (Wand:draw-fill-color dw) pw)
+                 (Wand:draw-color dw 0.0 0.0 :ResetMethod))
+               (Wand-with-pixel-wand pw
+                 (setf (Wand:pixel-color pw) "black")
+                 (setf (Wand:draw-fill-color dw) pw))
+               (Wand:draw-ellipse
+                dw (/ w 2.0) (/ h 2.0) (/ w 2.0) (/ h 2.0) 0.0 360.0)
+               (Wand:MagickDrawImage mask dw))
+             (setf (Wand:clip-mask cw) mask))
+         (Wand:delete-wand mask)))
 
       (Wand:gaussian-blur-image
        cw 0.0 (Wand-mode-redeye-blur-radius w h))
@@ -2466,9 +2466,9 @@ too small for small regions."
 
 (define-Wand-operation zoom (wand outp factor)
   (let ((nw (funcall (if outp #'/ #'*)
-                     (Wand:image-width wand) (float factor)))
-        (nh (funcall (if outp #'/ #'*)
-                     (Wand:image-height wand) (float factor))))
+                    (Wand:image-width wand) (float factor)))
+       (nh (funcall (if outp #'/ #'*)
+                    (Wand:image-height wand) (float factor))))
     (Wand:scale-image wand (round nw) (round nh))))
 
 (define-Wand-operation sample (wand width height)
@@ -2501,23 +2501,23 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
 
 (defvar Wand-patterns
   (mapcar (lambda (x) (list (symbol-name x)))
-         '(bricks checkerboard circles crosshatch crosshatch30 crosshatch45
-           fishscales gray0 gray5 gray10 gray15 gray20 gray25 gray30
-           gray35 gray40 gray45 gray50 gray55 gray60 gray65 gray70
-           gray75 gray80 gray85 gray90 gray95 gray100 hexagons horizontal
-           horizontalsaw hs_bdiagonal hs_cross
-           hs_diagcross hs_fdiagonal hs_horizontal hs_vertical left30
-           left45 leftshingle octagons right30 right45 rightshingle
-           smallfishscales vertical verticalbricks
-           verticalleftshingle verticalrightshingle verticalsaw)))
+        '(bricks checkerboard circles crosshatch crosshatch30 crosshatch45
+          fishscales gray0 gray5 gray10 gray15 gray20 gray25 gray30
+          gray35 gray40 gray45 gray50 gray55 gray60 gray65 gray70
+          gray75 gray80 gray85 gray90 gray95 gray100 hexagons horizontal
+          horizontalsaw hs_bdiagonal hs_cross
+          hs_diagcross hs_fdiagonal hs_horizontal hs_vertical left30
+          left45 leftshingle octagons right30 right45 rightshingle
+          smallfishscales vertical verticalbricks
+          verticalleftshingle verticalrightshingle verticalsaw)))
 
 (define-Wand-operation pattern (wand pattern op)
   (Wand-with-wand cb-wand
     (setf (Wand:image-size cb-wand)
-          (cons (Wand:image-width wand) (Wand:image-height wand)))
+         (cons (Wand:image-width wand) (Wand:image-height wand)))
     (Wand:MagickReadImage cb-wand (concat "pattern:" pattern))
     (Wand:image-composite wand cb-wand
-                          (cdr (assoc op WandCompositeOperator-completion-table)) 0 0)))
+                         (cdr (assoc op WandCompositeOperator-completion-table)) 0 0)))
 
 ;;}}}
 ;;{{{ Operations list functions
@@ -2528,7 +2528,7 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
 (defun Wand-operation-apply (operation wand &rest args)
   "Apply OPERATION to WAND using addition arguments ARGS."
   (setq operations-list
-        (append operations-list (list (cons operation args))))
+       (append operations-list (list (cons operation args))))
   (setq undo-list nil)                  ; Reset undo
   (apply (Wand-operation-lookup operation) wand args))
 
@@ -2536,7 +2536,7 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
   "Apply all operations in OPERATIONS list."
   (dolist (op (or operations operations-list))
     (apply (Wand-operation-lookup (car op))
-           wand (cdr op))))
+          wand (cdr op))))
 
 ;;}}}
 ;;{{{ Helper functions
@@ -2544,63 +2544,63 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
 (defun Wand-mode-image-region ()
   "Return region in real image, according to `preview-region'."
   (let ((off-x (get preview-wand 'offset-x))
-        (off-y (get preview-wand 'offset-y))
-        (xcoeff (// (Wand:image-width image-wand)
-                    (Wand:image-width preview-wand)))
-        (ycoeff (// (Wand:image-height image-wand)
-                    (Wand:image-height preview-wand))))
+       (off-y (get preview-wand 'offset-y))
+       (xcoeff (// (Wand:image-width image-wand)
+                   (Wand:image-width preview-wand)))
+       (ycoeff (// (Wand:image-height image-wand)
+                   (Wand:image-height preview-wand))))
     (mapcar #'round (list (* (nth 0 preview-region) xcoeff)
-                          (* (nth 1 preview-region) ycoeff)
-                          (* (+ (nth 2 preview-region) off-x) xcoeff)
-                          (* (+ (nth 3 preview-region) off-y) ycoeff)))))
+                         (* (nth 1 preview-region) ycoeff)
+                         (* (+ (nth 2 preview-region) off-x) xcoeff)
+                         (* (+ (nth 3 preview-region) off-y) ycoeff)))))
 
 (defun Wand-mode-file-info ()
   "Return info about file as a string."
   (declare (special off-x))
   (declare (special off-y))
   (let ((iw (Wand:image-width image-wand))
-        (ih (Wand:image-height image-wand))
-        (ow (Wand:image-orig-width image-wand))
-        (oh (Wand:image-orig-height image-wand)))
+       (ih (Wand:image-height image-wand))
+       (ow (Wand:image-orig-width image-wand))
+       (oh (Wand:image-orig-height image-wand)))
     (concat "File: " (file-name-nondirectory buffer-file-name)
-            " (" (Wand:get-magick-property image-wand "size") "), "
-            (Wand:image-format image-wand)
-            " " (format "%dx%d" iw ih)
-            (if (and (not (zerop ow)) (not (zerop oh))
-                     (or (/= ow iw) (/= oh ih)))
-                (format " (Orig: %dx%d)" ow oh)
-              "")
-            (if (> (Wand:images-num image-wand) 1)
-                (format ", Page: %d/%d" (1+ (Wand:iterator-index image-wand))
-                        (Wand:images-num image-wand))
-              "")
-            ;; Print offset info
-            (if (and preview-wand (boundp 'off-x) (boundp 'off-y)
-                     (or (positivep off-x) (positivep off-y)))
-                (format ", Offset: +%d+%d" off-x off-y)
-              "")
-            ;; Print region info
-            (if preview-region
-                (apply #'format ", Region: %dx%d+%d+%d"
-                       (Wand-mode-image-region))
-              ""))))
+           " (" (Wand:get-magick-property image-wand "size") "), "
+           (Wand:image-format image-wand)
+           " " (format "%dx%d" iw ih)
+           (if (and (not (zerop ow)) (not (zerop oh))
+                    (or (/= ow iw) (/= oh ih)))
+               (format " (Orig: %dx%d)" ow oh)
+             "")
+           (if (> (Wand:images-num image-wand) 1)
+               (format ", Page: %d/%d" (1+ (Wand:iterator-index image-wand))
+                       (Wand:images-num image-wand))
+             "")
+           ;; Print offset info
+           (if (and preview-wand (boundp 'off-x) (boundp 'off-y)
+                    (or (positivep off-x) (positivep off-y)))
+               (format ", Offset: +%d+%d" off-x off-y)
+             "")
+           ;; Print region info
+           (if preview-region
+               (apply #'format ", Region: %dx%d+%d+%d"
+                      (Wand-mode-image-region))
+             ""))))
 
 (defun Wand-mode-iptc-split-keywords (tag-value)
   (mapcar #'(lambda (kw) (cons 'keyword kw))
-          (nreverse
-           (split-string tag-value "\\(, \\|,\\)"))))
+         (nreverse
+          (split-string tag-value "\\(, \\|,\\)"))))
 
 (defun Wand-mode-iptc-from-widgets (widgets)
   "Return profile made up from WIDGETS info."
   (mapcan
    #'(lambda (widget)
        (let ((iptc-tag (widget-get widget :iptc-tag))
-             (tag-value (widget-get widget :value)))
-         (cond ((string= tag-value "") nil)
-               ((eq iptc-tag 'keywords)
-                ;; Special case for keywords
-                (Wand-mode-iptc-split-keywords tag-value))
-               (t (list (cons iptc-tag tag-value))))))
+            (tag-value (widget-get widget :value)))
+        (cond ((string= tag-value "") nil)
+              ((eq iptc-tag 'keywords)
+               ;; Special case for keywords
+               (Wand-mode-iptc-split-keywords tag-value))
+              (t (list (cons iptc-tag tag-value))))))
    widgets))
 
 (defun Wand-mode-iptc-notify (wid &rest args)
@@ -2618,39 +2618,39 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
   (kill-local-variable 'widget-field-list)
 
   (let* ((iptc (Wand:image-profile-iptc image-wand))
-         (cpt (cdr (assq 'caption iptc)))
-         (kws (mapcar #'cdr (remove-if-not
-                             #'(lambda (e) (eq 'keyword (car e)))
-                             iptc))))
+        (cpt (cdr (assq 'caption iptc)))
+        (kws (mapcar #'cdr (remove-if-not
+                            #'(lambda (e) (eq 'keyword (car e)))
+                            iptc))))
     (when cpt
       (widget-create 'editable-field
-                     :tag "Caption"
-                     :format "IPTC Caption: %v"
-                     :iptc-tag 'caption
-                     :notify #'Wand-mode-iptc-notify
-                     cpt))
+                    :tag "Caption"
+                    :format "IPTC Caption: %v"
+                    :iptc-tag 'caption
+                    :notify #'Wand-mode-iptc-notify
+                    cpt))
     (when kws
       (widget-create 'editable-field
-                     :format "IPTC Keywords: %v"
-                     :tag "Keywords"
-                     :iptc-tag 'keywords
-                     :notify #'Wand-mode-iptc-notify
-                     (mapconcat #'identity kws ", ")))
+                    :format "IPTC Keywords: %v"
+                    :tag "Keywords"
+                    :iptc-tag 'keywords
+                    :notify #'Wand-mode-iptc-notify
+                    (mapconcat #'identity kws ", ")))
     (widget-setup)))
 
 (defun Wand-mode-add-iptc-tag (tag value)
   "Add TAG to ITPC profile."
   (interactive (list (completing-read
-                      "IPTC Tag: " '(("caption") ("keywords")) nil t)
-                     (read-string "ITPC Tag value: ")))
+                     "IPTC Tag: " '(("caption") ("keywords")) nil t)
+                    (read-string "ITPC Tag value: ")))
   (let ((tags-val (cond ((string= tag "caption")
-                         (list (cons 'caption value)))
-                        ((string= tag "keywords")
-                         (Wand-mode-iptc-split-keywords value))
-                        (t (error "Invalid IPTC tag")))))
+                        (list (cons 'caption value)))
+                       ((string= tag "keywords")
+                        (Wand-mode-iptc-split-keywords value))
+                       (t (error "Invalid IPTC tag")))))
     (Wand:image-save-iptc-profile
      image-wand (nconc (Wand-mode-iptc-from-widgets widget-field-list)
-                       tags-val))
+                      tags-val))
     (Wand-mode-update-info)))
 
 (defun Wand-mode-insert-info ()
@@ -2662,43 +2662,43 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
 
   ;; XXX iptc may set those below again
   (let ((inhibit-read-only t)
-        (before-change-functions nil)
-        (after-change-functions nil))
+       (before-change-functions nil)
+       (after-change-functions nil))
 
     (when (and Wand-mode-show-operations)
       (when operations-list
-        (insert (format "Operations: %S" operations-list) "\n"))
+       (insert (format "Operations: %S" operations-list) "\n"))
       (when Wand-global-operations-list
-        (insert (format "Global operations: %S"
-                        Wand-global-operations-list) "\n")))
+       (insert (format "Global operations: %S"
+                       Wand-global-operations-list) "\n")))
 
     ;; Info about pickup color
     (when (boundp 'pickup-color)
       (declare (special pickup-color))
       (let* ((cf (make-face (gensym "dcolor-") nil t))
-             (place (car pickup-color))
-             (color (cdr pickup-color))
-             (fcol (apply #'format "#%02x%02x%02x" color)))
-        (set-face-background cf fcol)
-        (insert (format "Color: +%d+%d " (car place) (cdr place)))
-        (insert-face "      " cf)
-        (insert (format " %s R:%d, G:%d, B:%d\n" fcol
-                        (car color) (cadr color) (caddr color)))))
+            (place (car pickup-color))
+            (color (cdr pickup-color))
+            (fcol (apply #'format "#%02x%02x%02x" color)))
+       (set-face-background cf fcol)
+       (insert (format "Color: +%d+%d " (car place) (cdr place)))
+       (insert-face "      " cf)
+       (insert (format " %s R:%d, G:%d, B:%d\n" fcol
+                       (car color) (cadr color) (caddr color)))))
 
     (run-hooks 'Wand-insert-info-hook)))
 
 (defun Wand-mode-update-info ()
   "Only update info region."
   (let ((inhibit-read-only t)
-        before-change-functions
-        after-change-functions)
+       before-change-functions
+       after-change-functions)
     (mapc 'widget-delete widget-field-list)
     (save-excursion
       (goto-char (point-min))
       (delete-region (point-at-bol)
-                     (save-excursion
-                       (goto-char (point-max))
-                       (point-at-bol)))
+                    (save-excursion
+                      (goto-char (point-max))
+                      (point-at-bol)))
       (Wand-mode-insert-info))
     (set-buffer-modified-p nil)))
 
@@ -2706,12 +2706,12 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
   "Update file info."
   (when Wand-mode-show-fileinfo
     (let ((inhibit-read-only t)
-          before-change-functions
-          after-change-functions)
+         before-change-functions
+         after-change-functions)
       (save-excursion
-        (goto-char (point-min))
-        (delete-region (point-at-bol) (point-at-eol))
-        (insert (Wand-mode-file-info))))
+       (goto-char (point-min))
+       (delete-region (point-at-bol) (point-at-eol))
+       (insert (Wand-mode-file-info))))
     (set-buffer-modified-p nil)))
 
 (defun Wand-mode-preview-with-region ()
@@ -2722,32 +2722,32 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
       (incf x (get preview-wand 'offset-x))
       (incf y (get preview-wand 'offset-y))
       (Wand-with-drawing-wand dw
-        (Wand-with-pixel-wand pw
-          (setf (Wand:pixel-color pw) Wand-mode-region-outline-color)
-          (Wand:DrawSetStrokeColor dw pw))
-        (Wand-with-pixel-wand pw
-          (setf (Wand:pixel-color pw) Wand-mode-region-fill-color)
-          (setf (Wand:draw-fill-color dw) pw))
-        (setf (Wand:draw-stroke-width dw) Wand-mode-region-outline-width
-              (Wand:draw-stroke-opacity dw) Wand-mode-region-outline-opacity
-              (Wand:draw-fill-opacity dw) Wand-mode-region-fill-opacity)
-        (Wand:draw-lines dw (list (cons x y) (cons (+ x w) y)
-                                  (cons (+ x w) (+ y h)) (cons x (+ y h))
-                                  (cons x y)))
-        (let ((nw (Wand:copy-wand preview-wand)))
-          (put nw 'offset-x (get preview-wand 'offset-x))
-          (put nw 'offset-y (get preview-wand 'offset-y))
-          (Wand:MagickDrawImage nw dw)
-          nw)))))
+       (Wand-with-pixel-wand pw
+         (setf (Wand:pixel-color pw) Wand-mode-region-outline-color)
+         (Wand:DrawSetStrokeColor dw pw))
+       (Wand-with-pixel-wand pw
+         (setf (Wand:pixel-color pw) Wand-mode-region-fill-color)
+         (setf (Wand:draw-fill-color dw) pw))
+       (setf (Wand:draw-stroke-width dw) Wand-mode-region-outline-width
+             (Wand:draw-stroke-opacity dw) Wand-mode-region-outline-opacity
+             (Wand:draw-fill-opacity dw) Wand-mode-region-fill-opacity)
+       (Wand:draw-lines dw (list (cons x y) (cons (+ x w) y)
+                                 (cons (+ x w) (+ y h)) (cons x (+ y h))
+                                 (cons x y)))
+       (let ((nw (Wand:copy-wand preview-wand)))
+         (put nw 'offset-x (get preview-wand 'offset-x))
+         (put nw 'offset-y (get preview-wand 'offset-y))
+         (Wand:MagickDrawImage nw dw)
+         nw)))))
 
 (defun Wand-mode-insert-preview ()
   "Display wand W at the point."
   ;; NOTE: if size not changed, then keep offset-x and offset-y
   ;; properties
   (let ((saved-w (and preview-wand (Wand:image-width preview-wand)))
-        (saved-h (and preview-wand (Wand:image-height preview-wand)))
-        (off-x (or (get preview-wand 'offset-x) 0))
-        (off-y (or (get preview-wand 'offset-y) 0)))
+       (saved-h (and preview-wand (Wand:image-height preview-wand)))
+       (off-x (or (get preview-wand 'offset-x) 0))
+       (off-y (or (get preview-wand 'offset-y) 0)))
     ;; Delete old preview and create new one
     (when preview-wand (Wand:delete-wand preview-wand))
     (setq preview-wand (Wand:get-image image-wand))
@@ -2757,24 +2757,24 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
     ;; displayed-text-pixel-height, and then restore
     ;; Rescale preview to fit the window
     (let ((scale-h (- (window-text-area-pixel-height)
-                      (if (zerop (buffer-size)) 0
-                        (unwind-protect
-                            (progn
-                              (backward-delete-char)
-                              (window-displayed-text-pixel-height))
-                          (insert "\n")))))
-          (scale-w (window-text-area-pixel-width)))
+                     (if (zerop (buffer-size)) 0
+                       (unwind-protect
+                           (progn
+                             (backward-delete-char)
+                             (window-displayed-text-pixel-height))
+                         (insert "\n")))))
+         (scale-w (window-text-area-pixel-width)))
       (when (and (get image-wand 'fitting)
-                 (Wand:fit-size preview-wand scale-w scale-h))
-        (message "Rescale to %dx%d"
-                 (Wand:image-width preview-wand)
-                 (Wand:image-height preview-wand))))
+                (Wand:fit-size preview-wand scale-w scale-h))
+       (message "Rescale to %dx%d"
+                (Wand:image-width preview-wand)
+                (Wand:image-height preview-wand))))
 
     ;; Set offset properties
     (if (and (eq saved-w (Wand:image-width preview-wand))
-             (eq saved-h (Wand:image-height preview-wand)))
-        (progn (put preview-wand 'offset-x off-x)
-               (put preview-wand 'offset-y off-y))
+            (eq saved-h (Wand:image-height preview-wand)))
+       (progn (put preview-wand 'offset-x off-x)
+              (put preview-wand 'offset-y off-y))
       (put preview-wand 'offset-x 0)
       (put preview-wand 'offset-y 0))
 
@@ -2786,12 +2786,12 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
 
     (let ((pwr (Wand-mode-preview-with-region)))
       (unwind-protect
-          (progn
-            (set-extent-end-glyph
-             preview-extent (Wand-mode-preview-glyph (or pwr preview-wand)))
-            (set-extent-endpoints
-             preview-extent (point) (point) (current-buffer)))
-        (when pwr (Wand:delete-wand pwr))))))
+         (progn
+           (set-extent-end-glyph
+            preview-extent (Wand-mode-preview-glyph (or pwr preview-wand)))
+           (set-extent-endpoints
+            preview-extent (point) (point) (current-buffer)))
+       (when pwr (Wand:delete-wand pwr))))))
 
 (defun Wand-redisplay (&optional wand)
   "Redisplay Wand buffer with possible a new WAND."
@@ -2813,44 +2813,44 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
 ;;;###autoload
 (defun Wand-display-noselect (file)
   (let* ((bn (format "*Wand: %s*" (file-name-nondirectory file)))
-         (buf (if (and (eq major-mode 'Wand-mode)
-                       (not (get-buffer bn)))
-                  ;; Use current buffer
-                  (progn
-                    (rename-buffer bn)
-                    (current-buffer))
-                (get-buffer-create bn))))
+        (buf (if (and (eq major-mode 'Wand-mode)
+                      (not (get-buffer bn)))
+                 ;; Use current buffer
+                 (progn
+                   (rename-buffer bn)
+                   (current-buffer))
+               (get-buffer-create bn))))
     (with-current-buffer buf
       (unless (eq major-mode 'Wand-mode)
-        ;; Initialise local variables
-        (kill-all-local-variables)
-        (make-variable-buffer-local 'image-wand)
-        (make-variable-buffer-local 'preview-wand)
-        (make-variable-buffer-local 'preview-region)
-        (make-variable-buffer-local 'preview-extent)
-        (make-variable-buffer-local 'operations-list)
-        (make-variable-buffer-local 'undo-list)
-        (make-variable-buffer-local 'kill-buffer-hook)
-        (setq operations-list nil)
-        (setq undo-list nil)
-        (setq preview-wand nil)
-        (setq preview-extent (make-extent 0 0 ""))
-        (setq image-wand (Wand:make-wand))
-        (put image-wand 'fitting Wand-mode-auto-fit)
-
-        (use-local-map Wand-mode-map)
-        (setq mode-name "Wand")
-        (setq major-mode 'Wand-mode)
-        (setq buffer-read-only t)
-        ;; Setup menubar
-        (when (featurep 'menubar)
-          (set-buffer-menubar current-menubar)
-          (add-submenu '() Wand-menu)
-          (setq mode-popup-menu Wand-menu))
-        (add-hook 'kill-buffer-hook 'Wand-mode-cleanup))
+       ;; Initialise local variables
+       (kill-all-local-variables)
+       (make-variable-buffer-local 'image-wand)
+       (make-variable-buffer-local 'preview-wand)
+       (make-variable-buffer-local 'preview-region)
+       (make-variable-buffer-local 'preview-extent)
+       (make-variable-buffer-local 'operations-list)
+       (make-variable-buffer-local 'undo-list)
+       (make-variable-buffer-local 'kill-buffer-hook)
+       (setq operations-list nil)
+       (setq undo-list nil)
+       (setq preview-wand nil)
+       (setq preview-extent (make-extent 0 0 ""))
+       (setq image-wand (Wand:make-wand))
+       (put image-wand 'fitting Wand-mode-auto-fit)
+
+       (use-local-map Wand-mode-map)
+       (setq mode-name "Wand")
+       (setq major-mode 'Wand-mode)
+       (setq buffer-read-only t)
+       ;; Setup menubar
+       (when (featurep 'menubar)
+         (set-buffer-menubar current-menubar)
+         (add-submenu '() Wand-menu)
+         (setq mode-popup-menu Wand-menu))
+       (add-hook 'kill-buffer-hook 'Wand-mode-cleanup))
 
       (when preview-wand
-        (Wand:delete-wand preview-wand))
+       (Wand:delete-wand preview-wand))
       (setq preview-wand nil)
       (setq preview-region nil)
       (setq operations-list nil)
@@ -2858,21 +2858,21 @@ BLUR is float, 0.25 for insane pixels, > 2.0 for excessively smoth."
       (Wand:clear-wand image-wand)
       ;; Fix buffer-file-name in case of viewing directory
       (when (file-directory-p file)
-        (setq file (or (Wand-next-file (concat file "/.")) file)))
+       (setq file (or (Wand-next-file (concat file "/.")) file)))
       (setq buffer-file-name file)
       (setq default-directory (file-name-directory file))
 
       (unless (Wand:read-image image-wand file)
-        (kill-buffer (current-buffer))
-        (error "Can't read file %s" file))
+       (kill-buffer (current-buffer))
+       (error "Can't read file %s" file))
       (when Wand-mode-auto-rotate
-        (Wand:correct-orientation image-wand))
+       (Wand:correct-orientation image-wand))
 
       ;; Apply operations in case global operations list is used
       (mapc #'(lambda (op)
-                (apply #'Wand-operation-apply
-                       (car op) image-wand (cdr op)))
-            Wand-global-operations-list)
+               (apply #'Wand-operation-apply
+                      (car op) image-wand (cdr op)))
+           Wand-global-operations-list)
 
       (Wand-redisplay)
 
@@ -2896,7 +2896,7 @@ Bindings are:
 (defun Wand-find-file-enable ()
   "Enable `find-file' to use `Wand-display' for supported filetypes."
   (push '(Wand-file-supported-for-read-p . Wand-display-noselect)
-        find-file-magic-files-alist))
+       find-file-magic-files-alist))
 
 (defun Wand-mode-cleanup ()
   "Cleanup when wand buffer is killed."
@@ -2922,21 +2922,21 @@ Bindings are:
   (let ((iw image-wand))
     (with-displaying-help-buffer
      #'(lambda ()
-         (set-buffer standard-output)
-         (insert (Wand:identify-image iw)))
+        (set-buffer standard-output)
+        (insert (Wand:identify-image iw)))
      "Wand:info")))
 
 (defun Wand-mode-operations-table ()
   "Return completion table for Wand operations."
   (mapcar #'(lambda (to)
-              (cons (downcase (get to 'menu-name)) to))
-          (Wand-mode-commands-by-tag 'menu-name)))
+             (cons (downcase (get to 'menu-name)) to))
+         (Wand-mode-commands-by-tag 'menu-name)))
 
 (defun Wand-mode-operate (op-name)
   "Operate on image."
   (interactive (list (completing-read
-                      "Operation: " (Wand-mode-operations-table)
-                      nil t)))
+                     "Operation: " (Wand-mode-operations-table)
+                     nil t)))
   (let ((op (assoc op-name (Wand-mode-operations-table))))
     (let ((current-prefix-arg current-prefix-arg))
       (call-interactively (cdr op)))))
@@ -2951,13 +2951,13 @@ Bindings are:
   "Return non-nil if Wand can read files in FORMAT."
   (unless (member (downcase format) Wand-formats-read-unsupported)
     (let ((fi (Wand:GetMagickInfo
-               format (ffi-address-of
-                       (make-ffi-object 'MagickExceptionInfo)))))
+              format (ffi-address-of
+                      (make-ffi-object 'MagickExceptionInfo)))))
       (and (not (ffi-null-p fi))
-           (not (ffi-null-p (MagickInfo->decoder fi)))
-           ))))
+          (not (ffi-null-p (MagickInfo->decoder fi)))
+          ))))
 ;; ImageMagick on linux treats any format to be RAW for some reason
-           ;; We can't read raw formats
+          ;; We can't read raw formats
 ;           (not (MagickInfo->raw fi))))))
 
 (defcustom Wand-formats-write-unsupported
@@ -2970,10 +2970,10 @@ Bindings are:
   "Return non-nil if Wand can write files in FORMAT."
   (unless (member (downcase format) Wand-formats-write-unsupported)
     (let ((fi (Wand:GetMagickInfo
-               format (ffi-address-of
-                       (make-ffi-object 'MagickExceptionInfo)))))
+              format (ffi-address-of
+                      (make-ffi-object 'MagickExceptionInfo)))))
       (and (not (ffi-null-p fi))
-           (not (ffi-null-p (MagickInfo->encoder fi)))))))
+          (not (ffi-null-p (MagickInfo->encoder fi)))))))
 
 ;;;###autoload
 (defun Wand-file-supported-for-read-p (file)
@@ -2983,11 +2983,11 @@ Bindings are:
   (let ((ext (file-name-extension file)))
     (or (and ext (Wand-format-supported-for-read-p ext))
 
-        (multiple-value-bind (itype imagetext)
-            (split-string (or (magic:file-type file) " ") " ")
-          (and imagetext
-               (string= (downcase imagetext) "image")
-               (Wand-format-supported-for-read-p itype))))))
+       (multiple-value-bind (itype imagetext)
+           (split-string (or (magic:file-type file) " ") " ")
+         (and imagetext
+              (string= (downcase imagetext) "image")
+              (Wand-format-supported-for-read-p itype))))))
 
 (defun Wand-formats-list (fmt-regexp &optional mode)
   "Return names of supported formats that matches FMT-REGEXP.
@@ -2997,23 +2997,23 @@ Optionally you can specify MODE:
   'read-write - Formats that we can and read and write
   'any or nil - Any format (default)."
   (let* ((excp (make-ffi-object 'MagickExceptionInfo))
-         (num (make-ffi-object 'unsigned-long))
-         (fil (Wand:GetMagickInfoList
-               fmt-regexp (ffi-address-of num) (ffi-address-of excp))))
+        (num (make-ffi-object 'unsigned-long))
+        (fil (Wand:GetMagickInfoList
+              fmt-regexp (ffi-address-of num) (ffi-address-of excp))))
     (unless (ffi-null-p fil)
       (unwind-protect
-          (loop for n from 0 below (ffi-get num)
-            with minfo = nil
-            do (setq minfo (ffi-aref fil n))
-            if (ecase (or mode 'any)
-                 (read (not (ffi-null-p (MagickInfo->decoder minfo))))
-                 (write (not (ffi-null-p (MagickInfo->encoder minfo))))
-                 (read-write
-                  (and (not (ffi-null-p (MagickInfo->decoder minfo)))
-                       (not (ffi-null-p (MagickInfo->encoder minfo)))))
-                 (any t))
-            collect (ffi-get (MagickInfo->name minfo) :type 'c-string))
-        (Wand:RelinquishMemory fil)))))
+         (loop for n from 0 below (ffi-get num)
+           with minfo = nil
+           do (setq minfo (ffi-aref fil n))
+           if (ecase (or mode 'any)
+                (read (not (ffi-null-p (MagickInfo->decoder minfo))))
+                (write (not (ffi-null-p (MagickInfo->encoder minfo))))
+                (read-write
+                 (and (not (ffi-null-p (MagickInfo->decoder minfo)))
+                      (not (ffi-null-p (MagickInfo->encoder minfo)))))
+                (any t))
+           collect (ffi-get (MagickInfo->name minfo) :type 'c-string))
+       (Wand:RelinquishMemory fil)))))
 
 ;;}}}
 ;;{{{ File navigation commands
@@ -3022,11 +3022,11 @@ Optionally you can specify MODE:
   "Return next (to CURFILE) image file in the directory.
 If REVERSE-ORDER is specified, then return previous file."
   (let* ((dir (file-name-directory curfile))
-         (fn (file-name-nondirectory curfile))
-         (dfiles (directory-files dir nil nil 'sorted-list t))
-         (nfiles (cdr (member fn (if reverse-order (nreverse dfiles) dfiles)))))
+        (fn (file-name-nondirectory curfile))
+        (dfiles (directory-files dir nil nil 'sorted-list t))
+        (nfiles (cdr (member fn (if reverse-order (nreverse dfiles) dfiles)))))
     (while (and nfiles (not (Wand-file-supported-for-read-p
-                             (concat dir (car nfiles)))))
+                            (concat dir (car nfiles)))))
       (setq nfiles (cdr nfiles)))
     (and nfiles (concat dir (car nfiles)))))
 
@@ -3047,7 +3047,7 @@ If REVERSE-ORDER is specified, then return previous file."
   "View last image in the directory."
   (interactive)
   (let ((rf buffer-file-name)
-        (ff (Wand-next-file buffer-file-name reverse)))
+       (ff (Wand-next-file buffer-file-name reverse)))
     (while ff
       (setq rf ff)
       (setq ff (Wand-next-file rf reverse)))
@@ -3093,8 +3093,8 @@ If REVERSE-ORDER is specified, then return previous file."
   "Display last image in image chain."
   (interactive
    (list (if (numberp current-prefix-arg)
-             current-prefix-arg
-           (read-number "Goto page: " t))))
+            current-prefix-arg
+          (read-number "Goto page: " t))))
   ;; Internally images in chain counts from 0
   (unless (setf (Wand:iterator-index image-wand) (1- n))
     (error "No such page" n))
@@ -3143,16 +3143,16 @@ If negative then to the opposite."
   "Rotate image to the left.
 If ARG is specified then rotate on ARG degree."
   (interactive (list (or (and current-prefix-arg
-                              (prefix-numeric-value current-prefix-arg))
-                         90)))
+                             (prefix-numeric-value current-prefix-arg))
+                        90)))
   (Wand-mode-rotate (- arg)))
 
 (defun Wand-mode-rotate-right (arg)
   "Rotate image to the right.
 If ARG is specified then rotate on ARG degree."
   (interactive (list (or (and current-prefix-arg
-                              (prefix-numeric-value current-prefix-arg))
-                         90)))
+                             (prefix-numeric-value current-prefix-arg))
+                        90)))
   (Wand-mode-rotate arg))
 
 (defun Wand-mode-raise (arg)
@@ -3177,8 +3177,8 @@ If ARG is specified then rotate on ARG degree."
 (defun Wand-mode-sharpen (radius sigma)
   "Sharpen image with by RADIUS and SIGMA."
   (interactive (list (read-number "Radius [1]: " nil "1")
-                     (read-number (format "Sigma [%d]: " Wand-mode-sigma)
-                                  nil (number-to-string Wand-mode-sigma))))
+                    (read-number (format "Sigma [%d]: " Wand-mode-sigma)
+                                 nil (number-to-string Wand-mode-sigma))))
   (Wand-operation-apply 'sharpen image-wand radius sigma)
   (Wand-redisplay))
 (put 'Wand-mode-sharpen 'can-preview :SharpenPreview)
@@ -3188,8 +3188,8 @@ If ARG is specified then rotate on ARG degree."
 (defun Wand-mode-gaussian-blur (radius sigma)
   "Apply gaussian blur of RADIUS and SIGMA to the image."
   (interactive (list (read-number "Radius [1]: " nil "1")
-                     (read-number (format "Sigma [%d]: " Wand-mode-sigma)
-                                  nil (number-to-string Wand-mode-sigma))))
+                    (read-number (format "Sigma [%d]: " Wand-mode-sigma)
+                                 nil (number-to-string Wand-mode-sigma))))
   (Wand-operation-apply 'gauss-blur image-wand radius sigma)
   (Wand-redisplay))
 (put 'Wand-mode-gaussian-blur 'can-preview :BlurPreview)
@@ -3217,8 +3217,8 @@ Default is 1."
 (defun Wand-mode-emboss (radius sigma)
   "Emboss the image with RADIUS and SIGMA."
   (interactive (list (read-number "Radius [1.0]: " nil "1.0")
-                     (read-number (format "Sigma [%d]: " Wand-mode-sigma)
-                                  nil (number-to-string Wand-mode-sigma))))
+                    (read-number (format "Sigma [%d]: " Wand-mode-sigma)
+                                 nil (number-to-string Wand-mode-sigma))))
   (Wand-operation-apply 'emboss image-wand radius sigma)
   (Wand-redisplay))
 (put 'Wand-mode-emboss 'effect-operation t)
@@ -3238,14 +3238,14 @@ Default is 1."
   "Add noise of NOISE-TYPE."
   (interactive
    (list (completing-read "Noise type [poisson]: "
-                          (mapcar #'(lambda (ev)
-                                      (let ((sn (symbol-name (car ev))))
-                                        (list (and (string-match
-                                                    ":\\(.+\\)Noise" sn)
-                                                   (downcase
-                                                    (match-string 1 sn))))))
-                                  (ffi-enum-values 'MagickNoiseType))
-                          nil t nil nil "poisson")))
+                         (mapcar #'(lambda (ev)
+                                     (let ((sn (symbol-name (car ev))))
+                                       (list (and (string-match
+                                                   ":\\(.+\\)Noise" sn)
+                                                  (downcase
+                                                   (match-string 1 sn))))))
+                                 (ffi-enum-values 'MagickNoiseType))
+                         nil t nil nil "poisson")))
   (let ((nt (intern (format ":%sNoise" (capitalize noise-type)))))
     (Wand-operation-apply 'add-noise image-wand nt))
   (Wand-redisplay))
@@ -3267,8 +3267,8 @@ Default is 1."
   "Increase or decrease contrast.
 By default increase."
   (interactive (list (completing-read
-                      "Contrast [increase]: " '(("increase") ("decrease"))
-                      nil t nil nil "increase")))
+                     "Contrast [increase]: " '(("increase") ("decrease"))
+                     nil t nil nil "increase")))
   (Wand-operation-apply 'contrast image-wand (string= ctype "increase"))
   (Wand-redisplay))
 (put 'Wand-mode-contrast 'enhance-operation t)
@@ -3318,14 +3318,14 @@ If prefix ARG is specified then negate by grey."
 (defun Wand-mode-modulate (type inc)
   "Modulate image's brightness, saturation or hue."
   (interactive (let* ((tp (completing-read
-                           "Modulate [saturation]: "
-                           '(("brightness") ("saturation") ("hue"))
-                           nil t nil nil "saturation"))
-                      (tinc (read-number (format "Increase %s [25%%]: " tp)
-                                         nil "25")))
-                 (list (cond ((string= tp "brightness") :brightness)
-                             ((string= tp "hue") :hue)
-                             (t :saturation)) tinc)))
+                          "Modulate [saturation]: "
+                          '(("brightness") ("saturation") ("hue"))
+                          nil t nil nil "saturation"))
+                     (tinc (read-number (format "Increase %s [25%%]: " tp)
+                                        nil "25")))
+                (list (cond ((string= tp "brightness") :brightness)
+                            ((string= tp "hue") :hue)
+                            (t :saturation)) tinc)))
   (Wand-operation-apply 'modulate image-wand type inc)
   (Wand-redisplay))
 (put 'Wand-mode-modulate 'enhance-operation t)
@@ -3338,7 +3338,7 @@ If prefix ARG is specified then negate by grey."
   "Solarise image with solarize factor SF."
   (interactive (list (read-number "Solarize factor [50%]: " nil "50")))
   (Wand-operation-apply 'solarize image-wand
-                        (* (Wand:quantum-range) (/ sf 100.0)))
+                       (* (Wand:quantum-range) (/ sf 100.0)))
   (Wand-redisplay))
 (put 'Wand-mode-solarize 'f/x-operation t)
 (put 'Wand-mode-solarize 'menu-name "Solarize")
@@ -3366,7 +3366,7 @@ Default radius is 3."
 If prefix ARG is specified then radius for charcoal painting is ARG.
 Default is 1."
   (interactive (list (read-number "Radius [1.0]: " nil "1.0")
-                     (read-number "Sigma [1.0]: " nil "1.0")))
+                    (read-number "Sigma [1.0]: " nil "1.0")))
   (Wand-operation-apply 'charcoal image-wand radius sigma)
   (Wand-redisplay))
 (put 'Wand-mode-charcoal 'can-preview :CharcoalDrawingPreview)
@@ -3377,7 +3377,7 @@ Default is 1."
   "Apply sepia tone to image by THRESHOLD."
   (interactive (list (read-number "Threshold [80%]: " nil "80")))
   (Wand-operation-apply 'sepia-tone image-wand
-                        (* (Wand:quantum-range) (/ threshold 100.0)))
+                       (* (Wand:quantum-range) (/ threshold 100.0)))
   (Wand-redisplay))
 (put 'Wand-mode-sepia-tone 'f/x-operation t)
 (put 'Wand-mode-sepia-tone 'menu-name "Sepia Tone")
@@ -3402,7 +3402,7 @@ RADIUS range is [-1.0, 1.0]."
 (defun Wand-mode-wave (amplitude wave-length)
   "Create wave effect on image with AMPLITUDE and WAVE-LENGTH."
   (interactive (list (read-number "Amplitude [2]: " nil "2")
-                     (read-number "Wave length [10]: " nil "10")))
+                    (read-number "Wave length [10]: " nil "10")))
   (Wand-operation-apply 'wave image-wand amplitude wave-length)
   (Wand-redisplay))
 (put 'Wand-mode-wave 'f/x-operation t)
@@ -3417,49 +3417,49 @@ RADIUS range is [-1.0, 1.0]."
   (interactive "e")
   (with-current-buffer (event-buffer event)
     (let ((gc-cons-threshold most-positive-fixnum) ; inhibit gc
-          (sx (event-glyph-x-pixel event))
-          (sy (event-glyph-y-pixel event))
-          (had-preview-region preview-region)
-          (mouse-down t))
+         (sx (event-glyph-x-pixel event))
+         (sy (event-glyph-y-pixel event))
+         (had-preview-region preview-region)
+         (mouse-down t))
       (setq preview-region (list 0 0 sx sy))
       (while mouse-down
-        (setq event (next-event event))
-        (cond ((motion-event-p event)
-               (let ((mx (event-glyph-x-pixel event))
-                     (my (event-glyph-y-pixel event)))
-                 (when (and mx my)
-                   (setq preview-region
-                         (list (abs (- sx mx)) (abs (- sy my))
-                               (min sx mx) (min sy my)))
-                   ;; Update info and preview image
-                   (Wand-mode-update-file-info)
-                   (let ((pwr (Wand-mode-preview-with-region)))
-                     (unwind-protect
-                         (set-extent-end-glyph
-                          preview-extent (Wand-mode-preview-glyph pwr))
-                       (Wand:delete-wand pwr))))))
-
-              ((button-release-event-p event)
-               (setq mouse-down nil)
-               (if (and (positivep (nth 0 preview-region))
-                        (positivep (nth 1 preview-region)))
-                   ;; Save region
-                   (put image-wand 'last-preview-region preview-region)
-
-                 (setq preview-region nil)
-                 (if had-preview-region
-                     (progn
-                       ;; Remove any regions
-                       (Wand-mode-update-file-info)
-                       (set-extent-end-glyph
-                        preview-extent (Wand-mode-preview-glyph preview-wand)))
-
-                   ;; Otherwise pickup color
-                   (let* ((col (Wand:get-rgb-pixel-at preview-wand sx sy))
-                          (pickup-color (cons (cons sx sy) col)))
-                     (declare (special pickup-color))
-                     (Wand-mode-update-info)))))
-              (t (dispatch-event event)))))))
+       (setq event (next-event event))
+       (cond ((motion-event-p event)
+              (let ((mx (event-glyph-x-pixel event))
+                    (my (event-glyph-y-pixel event)))
+                (when (and mx my)
+                  (setq preview-region
+                        (list (abs (- sx mx)) (abs (- sy my))
+                              (min sx mx) (min sy my)))
+                  ;; Update info and preview image
+                  (Wand-mode-update-file-info)
+                  (let ((pwr (Wand-mode-preview-with-region)))
+                    (unwind-protect
+                        (set-extent-end-glyph
+                         preview-extent (Wand-mode-preview-glyph pwr))
+                      (Wand:delete-wand pwr))))))
+
+             ((button-release-event-p event)
+              (setq mouse-down nil)
+              (if (and (positivep (nth 0 preview-region))
+                       (positivep (nth 1 preview-region)))
+                  ;; Save region
+                  (put image-wand 'last-preview-region preview-region)
+
+                (setq preview-region nil)
+                (if had-preview-region
+                    (progn
+                      ;; Remove any regions
+                      (Wand-mode-update-file-info)
+                      (set-extent-end-glyph
+                       preview-extent (Wand-mode-preview-glyph preview-wand)))
+
+                  ;; Otherwise pickup color
+                  (let* ((col (Wand:get-rgb-pixel-at preview-wand sx sy))
+                         (pickup-color (cons (cons sx sy) col)))
+                    (declare (special pickup-color))
+                    (Wand-mode-update-info)))))
+             (t (dispatch-event event)))))))
 
 (defun Wand-mode-activate-region ()
   "Activate last preview-region."
@@ -3471,33 +3471,33 @@ RADIUS range is [-1.0, 1.0]."
   "Drag image to view unshown part of the image."
   (interactive "e")
   (let ((gc-cons-threshold most-positive-fixnum) ; inhibit gc
-        (sx (event-glyph-x-pixel event))
-        (sy (event-glyph-y-pixel event))
-        (pw (Wand:image-width preview-wand))
-        (ph (Wand:image-height preview-wand))
-        (mouse-down t))
+       (sx (event-glyph-x-pixel event))
+       (sy (event-glyph-y-pixel event))
+       (pw (Wand:image-width preview-wand))
+       (ph (Wand:image-height preview-wand))
+       (mouse-down t))
     (while mouse-down
       (setq event (next-event event))
       (if (or (motion-event-p event) (button-release-event-p event))
-          (let ((off-x (+ (- sx (event-glyph-x-pixel event))
-                          (or (get preview-wand 'offset-x) 0)))
-                (off-y (+ (- sy (event-glyph-y-pixel event))
-                          (or (get preview-wand 'offset-y) 0))))
-            (when (< off-x 0) (setq off-x 0))
-            (when (< off-y 0) (setq off-y 0))
-            (Wand-mode-update-file-info)
-            (if (motion-event-p event)
-                (set-extent-end-glyph
-                 preview-extent (Wand:glyph-internal
-                                 preview-wand off-x off-y
-                                 (- pw off-x) (- ph off-y)))
-
-              ;; Button released
-              (setq mouse-down nil)
-              (put preview-wand 'offset-x off-x)
-              (put preview-wand 'offset-y off-y)))
-
-        (dispatch-event event)))))
+         (let ((off-x (+ (- sx (event-glyph-x-pixel event))
+                         (or (get preview-wand 'offset-x) 0)))
+               (off-y (+ (- sy (event-glyph-y-pixel event))
+                         (or (get preview-wand 'offset-y) 0))))
+           (when (< off-x 0) (setq off-x 0))
+           (when (< off-y 0) (setq off-y 0))
+           (Wand-mode-update-file-info)
+           (if (motion-event-p event)
+               (set-extent-end-glyph
+                preview-extent (Wand:glyph-internal
+                                preview-wand off-x off-y
+                                (- pw off-x) (- ph off-y)))
+
+             ;; Button released
+             (setq mouse-down nil)
+             (put preview-wand 'offset-x off-x)
+             (put preview-wand 'offset-y off-y)))
+
+       (dispatch-event event)))))
 
 (defun Wand-mode-crop ()
   "Crop image to selected region."
@@ -3536,7 +3536,7 @@ RADIUS range is [-1.0, 1.0]."
 (defun Wand-mode-preview-op (op)
   "Preview some operation OP with 8 subnails."
   (interactive (list (completing-read "Operation: "
-                        MagickPreviewType-completion-table nil t)))
+                       MagickPreviewType-completion-table nil t)))
   (Wand-redisplay (Wand-operation-apply 'preview-op image-wand op)))
 (put 'Wand-mode-preview-op 'region-operation t)
 (put 'Wand-mode-preview-op 'menu-name "Preview operation")
@@ -3549,27 +3549,27 @@ RADIUS range is [-1.0, 1.0]."
 If FACTOR is nil, then `Wand-mode-zoom-factor' is used."
   (interactive "P")
   (Wand-operation-apply 'zoom image-wand nil
-                        (if factor
-                            (prefix-numeric-value factor)
-                          Wand-mode-zoom-factor))
+                       (if factor
+                           (prefix-numeric-value factor)
+                         Wand-mode-zoom-factor))
   (Wand-redisplay))
 
 (defun Wand-mode-zoom-out (factor)
   "Zoom image out by `Wand-mode-zoom-factor'."
   (interactive "P")
   (Wand-operation-apply 'zoom image-wand t
-                        (if factor
-                            (prefix-numeric-value factor)
-                          Wand-mode-zoom-factor))
+                       (if factor
+                           (prefix-numeric-value factor)
+                         Wand-mode-zoom-factor))
   (Wand-redisplay))
 
 (defun Wand-mode-sample (w h)
   "Sample image to WxH size."
   (interactive
    (list (read-number (format "Width [%d]: " (Wand:image-width image-wand))
-                      t (int-to-string (Wand:image-width image-wand)))
-         (read-number (format "Height [%d]: " (Wand:image-height image-wand))
-                      t (int-to-string (Wand:image-height image-wand)))))
+                     t (int-to-string (Wand:image-width image-wand)))
+        (read-number (format "Height [%d]: " (Wand:image-height image-wand))
+                     t (int-to-string (Wand:image-height image-wand)))))
   (Wand-operation-apply 'sample image-wand w h)
   (Wand-redisplay))
 (put 'Wand-mode-sample 'transform-operation t)
@@ -3579,13 +3579,13 @@ If FACTOR is nil, then `Wand-mode-zoom-factor' is used."
   "Resize image to fit into WxH size."
   (interactive
    (let* ((dw (read-number
-               (format "Width [%d]: " (Wand:image-width image-wand))
-               t (int-to-string (Wand:image-width image-wand))))
-          (dh (round (* (Wand:image-height image-wand)
-                        (// dw (Wand:image-width image-wand))))))
+              (format "Width [%d]: " (Wand:image-width image-wand))
+              t (int-to-string (Wand:image-width image-wand))))
+         (dh (round (* (Wand:image-height image-wand)
+                       (// dw (Wand:image-width image-wand))))))
      (list dw (read-number (format "Height [%d]: " dh)
-                           t (int-to-string dh)))))
-  
+                          t (int-to-string dh)))))
+
   (Wand-operation-apply 'fit-size image-wand w h)
   (Wand-redisplay))
 (put 'Wand-mode-fit-size 'transform-operation t)
@@ -3595,9 +3595,9 @@ If FACTOR is nil, then `Wand-mode-zoom-factor' is used."
   "Rescale image to WxH using liquid rescale."
   (interactive
    (list (read-number (format "Width [%d]: " (Wand:image-width image-wand))
-                      t (int-to-string (Wand:image-width image-wand)))
-         (read-number (format "Height [%d]: " (Wand:image-height image-wand))
-                      t (int-to-string (Wand:image-height image-wand)))))
+                     t (int-to-string (Wand:image-width image-wand)))
+        (read-number (format "Height [%d]: " (Wand:image-height image-wand))
+                     t (int-to-string (Wand:image-height image-wand)))))
   (Wand-operation-apply 'liquid-rescale image-wand w h)
   (Wand-redisplay))
 (put 'Wand-mode-liquid-rescale 'transform-operation t)
@@ -3616,10 +3616,10 @@ Levels is a  number of color levels allowed in each channel.
 (defun Wand-mode-pattern (pattern &optional op)
   "Enable checkerboard as tile background."
   (interactive (list (completing-read "Pattern: " Wand-patterns nil t)
-                     (if current-prefix-arg
-                         (completing-read "Composite Op: "
-                            WandCompositeOperator-completion-table nil t)
-                       Wand-pattern-composite-op)))
+                    (if current-prefix-arg
+                        (completing-read "Composite Op: "
+                           WandCompositeOperator-completion-table nil t)
+                      Wand-pattern-composite-op)))
   (Wand-operation-apply 'pattern image-wand pattern op)
   (Wand-redisplay))
 (put 'Wand-mode-pattern 'transform-operation t)
@@ -3637,32 +3637,32 @@ A-la `list-colors-display'."
 
     (Wand-with-drawing-wand d-out
       (Wand-with-pixel-wand pw
-        (setf (Wand:pixel-color pw) "blue")
-        (setf (Wand:draw-fill-color d-out) pw))
+       (setf (Wand:pixel-color pw) "blue")
+       (setf (Wand:draw-fill-color d-out) pw))
       (Wand:draw-rectangle d-out 10.0 0.0 42.0 32.0)
 
       (Wand-with-wand w-out
-        (setf (Wand:image-size w-out)
-              (cons 80 (face-height 'default)))
-        (Wand:MagickReadImage w-out "pattern:horizontal")
-        (Wand:MagickDrawImage w-out d-out)
-
-        (flet ((draw-in-out (cop)
-                 (Wand-with-wand w-in
-                   (setf (Wand:image-size w-in)
-                         (cons 80 (face-height 'default)))
-                   (Wand:MagickReadImage w-in "pattern:vertical")
-                   (Wand:MagickDrawImage w-in d-in)
-                   (Wand:image-composite w-in w-out (cdr cop) 0 0)
-                   (let ((pnt (point)))
-                     (insert " " (car cop) "\n")
-                     (set-extent-end-glyph
-                      (make-extent pnt pnt)
-                      (Wand:glyph w-in))))))
-          (with-output-to-temp-buffer "*Wand-Composite-Ops*"
-            (set-buffer standard-output)
-            (mapc #'draw-in-out
-              (cdr WandCompositeOperator-completion-table))))))))
+       (setf (Wand:image-size w-out)
+             (cons 80 (face-height 'default)))
+       (Wand:MagickReadImage w-out "pattern:horizontal")
+       (Wand:MagickDrawImage w-out d-out)
+
+       (flet ((draw-in-out (cop)
+                (Wand-with-wand w-in
+                  (setf (Wand:image-size w-in)
+                        (cons 80 (face-height 'default)))
+                  (Wand:MagickReadImage w-in "pattern:vertical")
+                  (Wand:MagickDrawImage w-in d-in)
+                  (Wand:image-composite w-in w-out (cdr cop) 0 0)
+                  (let ((pnt (point)))
+                    (insert " " (car cop) "\n")
+                    (set-extent-end-glyph
+                     (make-extent pnt pnt)
+                     (Wand:glyph w-in))))))
+         (with-output-to-temp-buffer "*Wand-Composite-Ops*"
+           (set-buffer standard-output)
+           (mapc #'draw-in-out
+             (cdr WandCompositeOperator-completion-table))))))))
 
 (defun Wand-list-patterns ()
   "Show available patterns in separate buffer.
@@ -3670,18 +3670,18 @@ A-la `list-colors-display'."
   (interactive)
   (with-output-to-temp-buffer "*Wand-Patterns*"
     (flet ((draw-pattern (pat-name)
-             (let ((pnt (point)))
-               (insert " " pat-name "\n")
-               (set-extent-end-glyph
-                (make-extent pnt pnt)
-                (Wand-with-wand wand
-                  (setf (Wand:image-size wand)
-                        (cons 80 (face-height 'default)))
-                  (Wand:MagickReadImage wand (concat "pattern:" pat-name))
-                  (Wand:glyph wand))))))
+            (let ((pnt (point)))
+              (insert " " pat-name "\n")
+              (set-extent-end-glyph
+               (make-extent pnt pnt)
+               (Wand-with-wand wand
+                 (setf (Wand:image-size wand)
+                       (cons 80 (face-height 'default)))
+                 (Wand:MagickReadImage wand (concat "pattern:" pat-name))
+                 (Wand:glyph wand))))))
       (save-excursion
-        (set-buffer standard-output)
-        (mapc #'draw-pattern (mapcar #'car Wand-patterns))))))
+       (set-buffer standard-output)
+       (mapc #'draw-pattern (mapcar #'car Wand-patterns))))))
 (put 'Wand-list-patterns 'transform-operation t)
 (put 'Wand-list-patterns 'menu-name "List Patterns")
 
@@ -3718,7 +3718,7 @@ A-la `list-colors-display'."
   (dotimes (n arg)
     (let ((op (pop undo-list)))
       (when op
-        (apply #'Wand-operation-apply (car op) image-wand (cdr op)))))
+       (apply #'Wand-operation-apply (car op) image-wand (cdr op)))))
   (Wand-redisplay)
   (message "Redo!"))
 
@@ -3728,7 +3728,7 @@ A-la `list-colors-display'."
   (let ((last-op (car (last operations-list))))
     (when last-op
       (apply #'Wand-operation-apply
-             (car last-op) image-wand (cdr last-op))
+            (car last-op) image-wand (cdr last-op))
       (Wand-redisplay))))
 
 (defun Wand-mode-global-operations-list (arg)
@@ -3738,45 +3738,45 @@ Useful to skim over images in directory applying operations, for
 example zoom."
   (interactive "P")
   (setq Wand-global-operations-list
-        (and (not arg) operations-list))
+       (and (not arg) operations-list))
   (Wand-redisplay))
 
 (defun Wand-mode-write-file (format nfile)
   "Write file using output FORMAT."
   (interactive
    (let* ((ofmt (completing-read
-                 (format "Output Format [%s]: "
-                         (Wand:image-format image-wand))
-                 (mapcar #'list (Wand-formats-list "*" 'write))
-                 nil t nil nil (Wand:image-format image-wand)))
-          (nfname (concat (file-name-sans-extension buffer-file-name)
-                          "." (downcase ofmt)))
-          (fn (read-file-name
-               "Filename: "
-               (file-name-directory buffer-file-name)
-               nfname nil (file-name-nondirectory nfname))))
+                (format "Output Format [%s]: "
+                        (Wand:image-format image-wand))
+                (mapcar #'list (Wand-formats-list "*" 'write))
+                nil t nil nil (Wand:image-format image-wand)))
+         (nfname (concat (file-name-sans-extension buffer-file-name)
+                         "." (downcase ofmt)))
+         (fn (read-file-name
+              "Filename: "
+              (file-name-directory buffer-file-name)
+              nfname nil (file-name-nondirectory nfname))))
      (list ofmt fn)))
 
   (unless (Wand-format-supported-for-write-p format)
     (error "Unsupported format for writing: %s" format))
 
   (when (or (not Wand-mode-query-for-overwrite)
-            (not (file-exists-p nfile))
-            (y-or-n-p (format "File %s exists, overwrite? " nfile)))
+           (not (file-exists-p nfile))
+           (y-or-n-p (format "File %s exists, overwrite? " nfile)))
     (setf (Wand:image-format image-wand) format)
     (let ((saved-iw image-wand))        ; do this because it is buffer-local
       (with-temp-buffer
-        (insert (Wand:image-blob saved-iw))
-        (set-visited-file-name nfile t)
-        (set-buffer-modified-p t)
-        (setq buffer-read-only nil)
-        (let ((buffer-file-coding-system (get-coding-system 'binary)))
-          (save-buffer))))
+       (insert (Wand:image-blob saved-iw))
+       (set-visited-file-name nfile t)
+       (set-buffer-modified-p t)
+       (setq buffer-read-only nil)
+       (let ((buffer-file-coding-system (get-coding-system 'binary)))
+         (save-buffer))))
     (message "File %s saved" nfile)
 
     ;; Redisplay in case we can do it
     (if (Wand-format-supported-for-read-p format)
-        (Wand-display nfile)
+       (Wand-display nfile)
       (find-file nfile))))
 
 (defun Wand-mode-save-file (nfile)
@@ -3785,9 +3785,9 @@ Output format determined by NFILE extension, and no sanity checks
 performed, use `Wand-mode-write-file' if are not sure."
   (interactive
    (list (read-file-name "Filename: "
-                         (file-name-directory buffer-file-name)
-                         buffer-file-name nil
-                         (file-name-nondirectory buffer-file-name))))
+                        (file-name-directory buffer-file-name)
+                        buffer-file-name nil
+                        (file-name-nondirectory buffer-file-name))))
   (Wand-mode-write-file
    (upcase (file-name-extension nfile)) nfile))
 
index e261a1b..c200929 100644 (file)
@@ -203,8 +203,8 @@ nil means make them for files that have some already.
   "*If t, delete excess backup versions silently.
 If nil, ask confirmation.  Any other value prevents any trimming."
   :type '(choice (const :tag "Delete" t)
-                 (const :tag "Ask" nil)
-                 (sexp :tag "Leave" :format "%t\n" other))
+                (const :tag "Ask" nil)
+                (sexp :tag "Leave" :format "%t\n" other))
   :group 'backup)
 
 (defcustom kept-old-versions 2
@@ -385,8 +385,8 @@ FUNCTION-OF-ONE-ARGUMENT must return some buffer."
       (let ((name (copy-sequence filename))
            (start 0))
        ;; leave ':' if part of drive specifier
-       (if (and (> (length name) 1)
-                (eq (aref name 1) ?:))
+       (if (and (> (length name) 1)
+                (eq (aref name 1) ?:))
            (setq start 2))
        ;; destructively replace invalid filename characters with !
        (while (string-match "[?*:<>|\"\000-\037]" name start)
@@ -440,12 +440,12 @@ of the same functionality is available as `split-path', which see."
       (setq dir (file-truename dir)))
   (setq dir (abbreviate-file-name (expand-file-name dir)))
   (cond ((not (file-directory-p dir))
-         (error "%s is not a directory" dir))
+        (error "%s is not a directory" dir))
        ;; this breaks ange-ftp, which doesn't (can't?) overload `file-executable-p'.
-        ;;((not (file-executable-p dir))
-        ;; (error "Cannot cd to %s:  Permission denied" dir))
-        (t
-         (setq default-directory dir))))
+       ;;((not (file-executable-p dir))
+       ;; (error "Cannot cd to %s:  Permission denied" dir))
+       (t
+        (setq default-directory dir))))
 
 (defun cd (dir)
   "Make DIR become the current buffer's default directory.
@@ -467,11 +467,11 @@ colon-separated list of directories when resolving a relative directory name."
        (setq cd-path (or trypath (list "./")))))
     (or (catch 'found
          (mapcar #'(lambda (x)
-                       (let ((f (expand-file-name (concat x dir))))
+                       (let ((f (expand-file-name (concat x dir))))
                          (if (file-directory-p f)
                              (progn
-                               (cd-absolute f)
-                               (throw 'found t)))))
+                               (cd-absolute f)
+                               (throw 'found t)))))
                  cd-path)
          nil)
        ;; jwz: give a better error message to those of us with the
@@ -881,7 +881,7 @@ If there is no such live buffer, return nil."
                 (save-excursion
                   (set-buffer (car list))
                   (if (and buffer-file-number
-                           (equal buffer-file-number number)
+                          (equal buffer-file-number number)
                            ;; Verify this buffer's file number
                            ;; still belongs to its file.
                            (file-exists-p buffer-file-name)
@@ -924,15 +924,15 @@ conversion, find-file-hooks, automatic uncompression, etc.
   "Try to use dired to open FILENAME, which is directory."
   (if (and (fboundp 'dired-noselect) find-file-run-dired)
       (dired-noselect (if find-file-use-truenames
-                          (abbreviate-file-name (file-truename filename))
-                        filename))
+                         (abbreviate-file-name (file-truename filename))
+                       filename))
     (error "%s is a directory" filename)))
 
 (defun find-file-find-magic (filename)
   "Find entry in `find-file-magic-files-alist' that matches FILENAME."
   (find filename find-file-magic-files-alist :key #'car
-        :test #'(lambda (fn predicate)
-                  (funcall predicate fn))))
+       :test #'(lambda (fn predicate)
+                 (funcall predicate fn))))
 
 (defun find-file-noselect (filename &optional nowarn rawfile)
   "Read file FILENAME into a buffer and return the buffer.
@@ -945,14 +945,14 @@ If RAWFILE is non-nil, the file is read literally."
   ;; Try magic files first
   (let ((mfa-item (find-file-find-magic filename)))
     (if mfa-item
-        (funcall (cdr mfa-item) filename)
+       (funcall (cdr mfa-item) filename)
 
       (let* ((buf (get-file-buffer filename))
-             (truename (abbreviate-file-name (file-truename filename)))
-             (number (nthcdr 10 (file-attributes truename)))
+            (truename (abbreviate-file-name (file-truename filename)))
+            (number (nthcdr 10 (file-attributes truename)))
 ;         ;; Find any buffer for a file which has same truename.
 ;         (other (and (not buf) (find-buffer-visiting filename)))
-             (error nil))
+            (error nil))
 
 ;     ;; Let user know if there is a buffer with the same truename.
 ;      (if (and (not buf) same-truename (not nowarn))
@@ -966,49 +966,49 @@ If RAWFILE is non-nil, the file is read literally."
 ;      (if (or find-file-existing-other-name find-file-visit-truename)
 ;        (setq buf (or same-truename same-number)))
 
-        (when (and buf
-                   (or find-file-compare-truenames find-file-use-truenames)
-                   (not nowarn))
-          (save-excursion
-            (set-buffer buf)
-            (if (not (string-equal buffer-file-name filename))
-                (message "%s and %s are the same file (%s)"
-                         filename buffer-file-name
-                         buffer-file-truename))))
-
-        (if buf
-            (or nowarn
-                (verify-visited-file-modtime buf)
-                (cond ((not (file-exists-p filename))
-                       (error "File %s no longer exists!" filename))
-                      ;; Certain files should be reverted automatically
-                      ;; if they have changed on disk and not in the buffer.
-                      ((and (not (buffer-modified-p buf))
-                            (dolist (rx revert-without-query nil)
-                              (when (string-match rx filename)
-                                (return t))))
-                       (with-current-buffer buf
-                         (message "Reverting file %s..." filename)
-                         (revert-buffer t t)
-                         (message "Reverting file %s... done" filename)))
-                      ((yes-or-no-p
-                        (if (string= (file-name-nondirectory filename)
-                                     (buffer-name buf))
-                            (format
-                             (if (buffer-modified-p buf)
-                                 (gettext "File %s changed on disk.  Discard your edits? ")
-                               (gettext "File %s changed on disk.  Reread from disk? "))
-                             (file-name-nondirectory filename))
-                          (format
-                           (if (buffer-modified-p buf)
-                               (gettext "File %s changed on disk.  Discard your edits in %s? ")
-                             (gettext "File %s changed on disk.  Reread from disk into %s? "))
-                           (file-name-nondirectory filename)
-                           (buffer-name buf))))
-                       (with-current-buffer buf
-                         (revert-buffer t t)))))
-          ;; Else: we must create a new buffer for filename
-          (save-excursion
+       (when (and buf
+                  (or find-file-compare-truenames find-file-use-truenames)
+                  (not nowarn))
+         (save-excursion
+           (set-buffer buf)
+           (if (not (string-equal buffer-file-name filename))
+               (message "%s and %s are the same file (%s)"
+                        filename buffer-file-name
+                        buffer-file-truename))))
+
+       (if buf
+           (or nowarn
+               (verify-visited-file-modtime buf)
+               (cond ((not (file-exists-p filename))
+                      (error "File %s no longer exists!" filename))
+                     ;; Certain files should be reverted automatically
+                     ;; if they have changed on disk and not in the buffer.
+                     ((and (not (buffer-modified-p buf))
+                           (dolist (rx revert-without-query nil)
+                             (when (string-match rx filename)
+                               (return t))))
+                      (with-current-buffer buf
+                        (message "Reverting file %s..." filename)
+                        (revert-buffer t t)
+                        (message "Reverting file %s... done" filename)))
+                     ((yes-or-no-p
+                       (if (string= (file-name-nondirectory filename)
+                                    (buffer-name buf))
+                           (format
+                            (if (buffer-modified-p buf)
+                                (gettext "File %s changed on disk.  Discard your edits? ")
+                              (gettext "File %s changed on disk.  Reread from disk? "))
+                            (file-name-nondirectory filename))
+                         (format
+                          (if (buffer-modified-p buf)
+                              (gettext "File %s changed on disk.  Discard your edits in %s? ")
+                            (gettext "File %s changed on disk.  Reread from disk into %s? "))
+                          (file-name-nondirectory filename)
+                          (buffer-name buf))))
+                      (with-current-buffer buf
+                        (revert-buffer t t)))))
+         ;; Else: we must create a new buffer for filename
+         (save-excursion
 ;;; The truename stuff makes this obsolete.
 ;;;      (let* ((link-name (car (file-attributes filename)))
 ;;;             (linked-buf (and (stringp link-name)
@@ -1016,63 +1016,63 @@ If RAWFILE is non-nil, the file is read literally."
 ;;;        (if (bufferp linked-buf)
 ;;;            (message "Symbolic link to file in buffer %s"
 ;;;                     (buffer-name linked-buf))))
-            (setq buf (create-file-buffer filename))
-            ;; Catch various signals, such as QUIT, and kill the buffer
-            ;; in that case.
-            (condition-case data
-                (progn
-                  (set-buffer-major-mode buf)
-                  (set-buffer buf)
-                  (erase-buffer)
-                  (condition-case ()
-                      (if rawfile
-                          (insert-file-contents-literally filename t)
-                        (insert-file-contents filename t))
-                    (file-error
-                     (when (and (file-exists-p filename)
-                                (not (file-readable-p filename)))
-                       (signal 'file-error (list "File is not readable" filename)))
-                     (if rawfile
-                         ;; Unconditionally set error
-                         (setq error t)
-                       (or
-                        ;; Run find-file-not-found-hooks until one returns non-nil.
-                        (run-hook-with-args-until-success 'find-file-not-found-hooks)
-                        ;; If they fail too, set error.
-                        (setq error t)))))
-                  ;; Find the file's truename, and maybe use that as visited name.
-                  ;; automatically computed in XEmacs, unless jka-compr was used!
-                  (unless buffer-file-truename
-                    (setq buffer-file-truename truename))
-                  (setq buffer-file-number number)
-                  (and find-file-use-truenames
-                       ;; This should be in C.  Put pathname
-                       ;; abbreviations that have been explicitly
-                       ;; requested back into the pathname.  Most
-                       ;; importantly, strip out automounter /tmp_mnt
-                       ;; directories so that auto-save will work
-                       (setq buffer-file-name (abbreviate-file-name buffer-file-name)))
-                  ;; Set buffer's default directory to that of the file.
-                  (setq default-directory (file-name-directory buffer-file-name))
-                  ;; Turn off backup files for certain file names.  Since
-                  ;; this is a permanent local, the major mode won't eliminate it.
-                  (and (not (funcall backup-enable-predicate buffer-file-name))
-                       (progn
-                         (make-local-variable 'backup-inhibited)
-                         (setq backup-inhibited t)))
-                  (if rawfile
-                      ;; #### FSF 20.3 sets buffer-file-coding-system to
-                      ;; `no-conversion' here.  Should we copy?  It also
-                      ;; makes `find-file-literally' a local variable
-                      ;; and sets it to t.
-                      nil
-                    (after-find-file error (not nowarn))
-                    (setq buf (current-buffer))))
-              (t
-               (kill-buffer buf)
-               (signal (car data) (cdr data))))
-            ))
-        buf))))
+           (setq buf (create-file-buffer filename))
+           ;; Catch various signals, such as QUIT, and kill the buffer
+           ;; in that case.
+           (condition-case data
+               (progn
+                 (set-buffer-major-mode buf)
+                 (set-buffer buf)
+                 (erase-buffer)
+                 (condition-case ()
+                     (if rawfile
+                         (insert-file-contents-literally filename t)
+                       (insert-file-contents filename t))
+                   (file-error
+                    (when (and (file-exists-p filename)
+                               (not (file-readable-p filename)))
+                      (signal 'file-error (list "File is not readable" filename)))
+                    (if rawfile
+                        ;; Unconditionally set error
+                        (setq error t)
+                      (or
+                       ;; Run find-file-not-found-hooks until one returns non-nil.
+                       (run-hook-with-args-until-success 'find-file-not-found-hooks)
+                       ;; If they fail too, set error.
+                       (setq error t)))))
+                 ;; Find the file's truename, and maybe use that as visited name.
+                 ;; automatically computed in XEmacs, unless jka-compr was used!
+                 (unless buffer-file-truename
+                   (setq buffer-file-truename truename))
+                 (setq buffer-file-number number)
+                 (and find-file-use-truenames
+                      ;; This should be in C.  Put pathname
+                      ;; abbreviations that have been explicitly
+                      ;; requested back into the pathname.  Most
+                      ;; importantly, strip out automounter /tmp_mnt
+                      ;; directories so that auto-save will work
+                      (setq buffer-file-name (abbreviate-file-name buffer-file-name)))
+                 ;; Set buffer's default directory to that of the file.
+                 (setq default-directory (file-name-directory buffer-file-name))
+                 ;; Turn off backup files for certain file names.  Since
+                 ;; this is a permanent local, the major mode won't eliminate it.
+                 (and (not (funcall backup-enable-predicate buffer-file-name))
+                      (progn
+                        (make-local-variable 'backup-inhibited)
+                        (setq backup-inhibited t)))
+                 (if rawfile
+                     ;; #### FSF 20.3 sets buffer-file-coding-system to
+                     ;; `no-conversion' here.  Should we copy?  It also
+                     ;; makes `find-file-literally' a local variable
+                     ;; and sets it to t.
+                     nil
+                   (after-find-file error (not nowarn))
+                   (setq buf (current-buffer))))
+             (t
+              (kill-buffer buf)
+              (signal (car data) (cdr data))))
+           ))
+       buf))))
 \f
 ;; FSF has `insert-file-literally' and `find-file-literally' here.
 
@@ -1135,9 +1135,9 @@ Finishes by calling the functions in `find-file-hooks'."
                          (signal 'quit nil))))
                   nil))))
       (when msg
-        (message "%s" msg)
-        (unless not-serious
-          (save-excursion (sit-for 1 t)))))
+       (message "%s" msg)
+       (unless not-serious
+         (save-excursion (sit-for 1 t)))))
     (if (and auto-save-default (not noauto))
        (auto-save-mode t)))
   (unless nomodes
@@ -1157,14 +1157,14 @@ run `normal-mode' explicitly."
   (interactive)
   (or find-file (funcall (or default-major-mode 'fundamental-mode)))
   (and (condition-case err
-           (progn (set-auto-mode)
-                  t)
-         (error (message "File mode specification error: %s"
-                         (prin1-to-string err))
-                nil))
+          (progn (set-auto-mode)
+                 t)
+        (error (message "File mode specification error: %s"
+                        (prin1-to-string err))
+               nil))
        (condition-case err
-           (hack-local-variables (not find-file))
-         (error (lwarn 'local-variables 'warning
+          (hack-local-variables (not find-file))
+        (error (lwarn 'local-variables 'warning
                  "File local-variables error: %s"
                  (error-message-string err))))))
 
@@ -1229,12 +1229,12 @@ If it matches, mode MODE is selected.")
 ;(eval-when-compile
 ;  (require 'regexp-opt)
 ;  (list
-;   (format "\\.\\(?:%s\\)\\'" 
+;   (format "\\.\\(?:%s\\)\\'"
 ;         (regexp-opt
 ;          '(
 ;            ;; Compressed files
 ;            "7Z" "7z" "ARC" "EAR" "JAR" "LZH" "RAR" "WAR"
-;            "XPI" "Z" "ZIP" "ZOO" "arc" "bz2" "ear" "gz" 
+;            "XPI" "Z" "ZIP" "ZOO" "arc" "bz2" "ear" "gz"
 ;            "jar" "tar" "tgz" "tiff" "war" "xpi" "zip" "zoo"
 ;            "zoo" "lha" "lzh" "lzma" "xz"
 ;            ;; Code
@@ -1293,13 +1293,13 @@ and we don't even do that unless it would come from the file name."
        ;; this buffer isn't associated with a file.
        (null buffer-file-name)
        (let ((name (file-name-sans-versions buffer-file-name))
-              (keep-going t))
-          (while keep-going
-            (setq keep-going nil)
-            (let ((alist auto-mode-alist)
-                  (mode nil))
+             (keep-going t))
+         (while keep-going
+           (setq keep-going nil)
+           (let ((alist auto-mode-alist)
+                 (mode nil))
 
-              ;; Find first matching alist entry.
+             ;; Find first matching alist entry.
 
              ;; #### This is incorrect. In NT, case sensitivity is a volume
              ;; property. For instance, NFS mounts *are* case sensitive.
@@ -1337,14 +1337,14 @@ and we don't even do that unless it would come from the file name."
                              (setq mode (cdr (car alist)))
                              (setq alist nil))
                          (setq alist (cdr alist)))))))
-              (if mode
+             (if mode
                  (if (not (fboundp mode))
-                      (let ((name (declare-fboundp (package-get-package-provider mode))))
-                        (if name
-                            (message "Mode %s is not installed.  Download package %s" mode name)
-                          (message "Mode %s either doesn't exist or is not a known package" mode))
-                        (sit-for 2)
-                        (error "%s" mode))
+                     (let ((name (declare-fboundp (package-get-package-provider mode))))
+                       (if name
+                           (message "Mode %s is not installed.  Download package %s" mode name)
+                         (message "Mode %s either doesn't exist or is not a known package" mode))
+                       (sit-for 2)
+                       (error "%s" mode))
                    (unless (and just-from-file-name
                                 (or
                                  ;; Don't reinvoke major mode.
@@ -1383,10 +1383,10 @@ for current buffer."
                   (setq temp (cdr temp))
                   temp))))
       (progn
-        ;; Look for variables in the -*- line.
-        (hack-local-variables-prop-line force)
-        ;; Look for "Local variables:" block in last page.
-        (hack-local-variables-last-page force)))
+       ;; Look for variables in the -*- line.
+       (hack-local-variables-prop-line force)
+       ;; Look for "Local variables:" block in last page.
+       (hack-local-variables-last-page force)))
   (run-hooks 'hack-local-variables-hook))
 
 ;;; Local variables may be specified in the last page of the file (within 3k
@@ -1417,26 +1417,26 @@ for current buffer."
 (defun hack-local-variables-p (modeline)
   (or (eq enable-local-variables t)
       (and enable-local-variables
-           (save-window-excursion
-             (condition-case nil
-                 (switch-to-buffer (current-buffer))
-               (error
-                ;; If we fail to switch in the selected window,
-                ;; it is probably a minibuffer.
-                ;; So try another window.
-                (condition-case nil
-                    (switch-to-buffer-other-window (current-buffer))
-                  (error
-                   (switch-to-buffer-other-frame (current-buffer))))))
-             (or modeline (save-excursion
-                             (beginning-of-line)
-                             (set-window-start (selected-window) (point))))
-             (y-or-n-p (format
-                        "Set local variables as specified %s of %s? "
-                        (if modeline "in -*- line" "at end")
-                        (if buffer-file-name
-                            (file-name-nondirectory buffer-file-name)
-                            (concat "buffer " (buffer-name)))))))))
+          (save-window-excursion
+            (condition-case nil
+                (switch-to-buffer (current-buffer))
+              (error
+               ;; If we fail to switch in the selected window,
+               ;; it is probably a minibuffer.
+               ;; So try another window.
+               (condition-case nil
+                   (switch-to-buffer-other-window (current-buffer))
+                 (error
+                  (switch-to-buffer-other-frame (current-buffer))))))
+            (or modeline (save-excursion
+                            (beginning-of-line)
+                            (set-window-start (selected-window) (point))))
+            (y-or-n-p (format
+                       "Set local variables as specified %s of %s? "
+                       (if modeline "in -*- line" "at end")
+                       (if buffer-file-name
+                           (file-name-nondirectory buffer-file-name)
+                           (concat "buffer " (buffer-name)))))))))
 
 (defun hack-local-variables-last-page (&optional force)
   ;; Set local variables set in the "Local Variables:" block of the last page.
@@ -1446,10 +1446,10 @@ for current buffer."
     (if (let ((case-fold-search t))
          (and (search-forward "Local Variables:" nil t)
               (or force
-                   (hack-local-variables-p nil))))
+                  (hack-local-variables-p nil))))
        (let ((continue t)
              prefix prefixlen suffix start
-              (enable-local-eval enable-local-eval))
+             (enable-local-eval enable-local-eval))
          ;; The prefix is what comes before "local variables:" in its line.
          ;; The suffix is what comes after "local variables:" in its line.
          (skip-chars-forward " \t")
@@ -1494,7 +1494,7 @@ for current buffer."
                (or (if suffix (looking-at suffix) (eolp))
                    (error "Local variables entry is terminated incorrectly"))
                ;; Set the variable.  "Variables" mode and eval are funny.
-                (hack-one-local-variable var val))))))))
+               (hack-one-local-variable var val))))))))
 
 ;; jwz - New Version 20.1/19.15
 (defun hack-local-variables-prop-line (&optional force)
@@ -1983,9 +1983,9 @@ the value is \"\"."
   (save-match-data
     (let ((file (file-name-sans-versions (file-name-nondirectory filename))))
       (if (string-match #r"\.[^.]*\'" file)
-          (substring file (+ (match-beginning 0) (if period 0 1)))
-        (if period
-            "")))))
+         (substring file (+ (match-beginning 0) (if period 0 1)))
+       (if period
+           "")))))
 
 (defun make-backup-file-name (file)
   "Create the non-numeric backup file name for FILE.
@@ -2230,19 +2230,19 @@ After saving the buffer, run `after-save-hook'."
            ;; outermost call).
            ;;
            ;; Ugh, have to duplicate logic of run-hook-with-args-until-success
-            (let ((hooks (append (files-fetch-hook-value 'write-contents-hooks)
-                                 (files-fetch-hook-value
+           (let ((hooks (append (files-fetch-hook-value 'write-contents-hooks)
+                                (files-fetch-hook-value
                                  'local-write-file-hooks)
-                                 (files-fetch-hook-value 'write-file-hooks)))
+                                (files-fetch-hook-value 'write-file-hooks)))
                  (after-save-hook nil)
-                  (local-write-file-hooks nil)
+                 (local-write-file-hooks nil)
                  (write-contents-hooks nil)
                  (write-file-hooks nil)
                  done)
-              (while (and hooks
-                          (let ((continue-save-buffer-hooks-tail hooks))
-                            (not (setq done (funcall (car hooks))))))
-                (setq hooks (cdr hooks)))
+             (while (and hooks
+                         (let ((continue-save-buffer-hooks-tail hooks))
+                           (not (setq done (funcall (car hooks))))))
+               (setq hooks (cdr hooks)))
              ;; If a hook returned t, file is already "written".
              ;; Otherwise, write it the usual way now.
              (if (not done)
@@ -2486,8 +2486,8 @@ With arg, set read-only iff arg is positive."
   (interactive "_P")
   (setq buffer-read-only
        (if (null arg)
-            (not buffer-read-only)
-            (> (prefix-numeric-value arg) 0)))
+           (not buffer-read-only)
+           (> (prefix-numeric-value arg) 0)))
   ;; Force modeline redisplay
   (redraw-modeline))
 
@@ -2673,7 +2673,7 @@ Revert only if they differ."
           (found nil)
           (delay-prompt nil)
           (auto-save-p (and (not ignore-auto)
-                             (recent-auto-save-p)
+                            (recent-auto-save-p)
                             buffer-auto-save-file-name
                             (file-readable-p buffer-auto-save-file-name)
                             (y-or-n-p
@@ -2703,7 +2703,7 @@ Revert only if they differ."
                             ;; ... and if different, prompt
                             (or noconfirm found
                                 (and delay-prompt
-                                     (yes-or-no-p 
+                                     (yes-or-no-p
                                       (format "Revert buffer from file %s? "
                                               file-name))))))
                    ;; If file was backed up but has changed since,
@@ -2796,7 +2796,7 @@ Return nil if identical, and the new buffer if different."
                  bmax (point-max))))))
     (if (not (and (eq bmin (point-min))
                  (eq bmax (point-max))
-                 (eq (compare-buffer-substrings 
+                 (eq (compare-buffer-substrings
                       newbuf bmin bmax (current-buffer) bmin bmax) 0)))
        newbuf
       (and (kill-buffer newbuf) nil))))
@@ -2967,7 +2967,7 @@ LIST defaults to all existing live buffers."
 With prefix argument ARG, turn auto-saving on if positive, else off."
   (interactive "P")
   (setq buffer-auto-save-file-name
-        (and (if (null arg)
+       (and (if (null arg)
                 (or (not buffer-auto-save-file-name)
                     ;; If autosave is off because buffer has shrunk,
                     ;; then toggling should turn it on.
@@ -3123,10 +3123,10 @@ and `list-directory-verbose-switches'."
 ;;   File lines should display the basename.
 ;; - must be consistent with
 ;;   - functions dired-move-to-filename, (these two define what a file line is)
-;;              dired-move-to-end-of-filename,
+;;              dired-move-to-end-of-filename,
 ;;              dired-between-files, (shortcut for (not (dired-move-to-filename)))
-;;              dired-insert-headerline
-;;              dired-after-subdir-garbage (defines what a "total" line is)
+;;              dired-insert-headerline
+;;              dired-after-subdir-garbage (defines what a "total" line is)
 ;;   - variable dired-subdir-regexp
 (defun insert-directory (file switches &optional wildcard full-directory-p)
   "Insert directory listing for FILE, formatted according to SWITCHES.
index 485145d..84cd6d1 100644 (file)
@@ -416,7 +416,7 @@ space does not end a sentence, so don't break a line there."
          ;; end patch
          (goto-char from)
          (skip-chars-forward " \t")
-         (if (and nosqueeze (not (eq justify 'full)))
+         (if (and nosqueeze (not (eq justify 'full)))
              nil
            (canonically-space-region (or squeeze-after (point)) (point-max))
            (goto-char (point-max))
@@ -1020,7 +1020,7 @@ MAIL-FLAG for a mail message, i. e. don't fill header lines."
                          (looking-at "[ \t]*$")))
            (if (looking-at "[ \t]*[^ \t\n]+:")
                (search-forward "\n\n" nil 'move)
-                (forward-line 1))))
+               (forward-line 1))))
       (narrow-to-region (point) max)
       ;; Loop over paragraphs.
       (while (progn (skip-chars-forward " \t\n") (not (eobp)))
@@ -1061,11 +1061,11 @@ MAIL-FLAG for a mail message, i. e. don't fill header lines."
                                         (progn
                                           (forward-char (length fill-prefix))
                                           (looking-at paragraph-separate))))))
-                            ;; If this line has more or less indent
-                            ;; than the fill prefix wants, end the paragraph.
-                            (and (looking-at fill-prefix-regexp)
-                                 (save-excursion
-                                   (not
+                           ;; If this line has more or less indent
+                           ;; than the fill prefix wants, end the paragraph.
+                           (and (looking-at fill-prefix-regexp)
+                                (save-excursion
+                                  (not
                                    (progn
                                      (forward-char (length fill-prefix))
                                      (or (looking-at paragraph-separate)
index ec507fc..aa89a66 100644 (file)
@@ -111,9 +111,9 @@ from the search."
    ;; inplace
    (and
     (paths-file-readable-directory-p (paths-construct-path
-                                      (list directory "lisp")))
+                                     (list directory "lisp")))
     (paths-file-readable-directory-p (paths-construct-path
-                                      (list directory "etc"))))))
+                                     (list directory "etc"))))))
 
 (defun paths-root-in-place-p (root)
   "Check if ROOT is an in-place installation root for XEmacs."
@@ -170,7 +170,7 @@ to EXPAND-FILE-NAME."
 
 (defun paths-find-emacs-directory (roots suffix base
                                   &optional envvar default keep-suffix
-                                            in-place-external)
+                                            in-place-external)
   "Find a directory in the XEmacs hierarchy.
 ROOTS must be a list of installation roots.
 SUFFIX is the subdirectory from there.
@@ -250,13 +250,13 @@ If ENFORCE-VERSION is non-nil, the directory must contain the SXEmacs version."
    ;; look for lib/sxemacs-xx.y.z
    ;; what do we do if user specifies --libdir?
    (paths-find-emacs-directory roots
-                               (file-name-as-directory
-                                (paths-construct-path
-                                 (list "lib"
-                                       (construct-emacs-version-name))))
-                               base
-                               envvar default
-                               enforce-version))
+                              (file-name-as-directory
+                               (paths-construct-path
+                                (list "lib"
+                                      (construct-emacs-version-name))))
+                              base
+                              envvar default
+                              enforce-version))
 
 (defun paths-find-version-archindep-directory
   (roots base &optional envvar default enforce-version)
@@ -264,13 +264,13 @@ If ENFORCE-VERSION is non-nil, the directory must contain the SXEmacs version."
 If ENFORCE-VERSION is non-nil, the directory must contain the SXEmacs version."
    ;; look for share/sxemacs-xx.y.z
    (paths-find-emacs-directory roots
-                               (file-name-as-directory
-                                (paths-construct-path
-                                 (list "share"
-                                       (construct-emacs-version-name))))
-                               base
-                               envvar default
-                               enforce-version))
+                              (file-name-as-directory
+                               (paths-construct-path
+                                (list "share"
+                                      (construct-emacs-version-name))))
+                              base
+                              envvar default
+                              enforce-version))
 
 ;; we default to the arch-independent directory atm
 (defalias 'path-find-version-directory #'paths-find-version-archindep-directory)
@@ -280,15 +280,15 @@ If ENFORCE-VERSION is non-nil, the directory must contain the SXEmacs version."
   (or
    ;; from more to less specific
    (paths-find-version-archdep-directory roots
-                                         (paths-construct-path
-                                          (list system-configuration base))
-                                         envvar default)
+                                        (paths-construct-path
+                                         (list system-configuration base))
+                                        envvar default)
    (paths-find-version-archdep-directory roots
-                                         base
-                                         envvar)
+                                        base
+                                        envvar)
    (paths-find-version-archdep-directory roots
-                                         system-configuration
-                                         envvar)))
+                                        system-configuration
+                                        envvar)))
 
 (defun construct-emacs-version-name ()
   "Construct the raw XEmacs version number."
@@ -347,30 +347,30 @@ Otherwise, they are left alone."
   "Find all plausible installation roots for SXEmacs."
   (let* ((potential-invocation-root
          (paths-find-emacs-root
-           invocation-directory invocation-name))
+          invocation-directory invocation-name))
         (invocation-roots nil)
         (potential-installation-roots
-          (when (null dumpp)
-            (paths-uniq-append
-             (and configure-exec-prefix-directory
-                  (list (file-name-as-directory
-                         configure-exec-prefix-directory)))
-             (and configure-prefix-directory
-                  (list (file-name-as-directory
-                         configure-prefix-directory))))))
+         (when (null dumpp)
+           (paths-uniq-append
+            (and configure-exec-prefix-directory
+                 (list (file-name-as-directory
+                        configure-exec-prefix-directory)))
+            (and configure-prefix-directory
+                 (list (file-name-as-directory
+                        configure-prefix-directory))))))
         (installation-roots
          (paths-filter #'paths-emacs-root-p potential-installation-roots))
-         (source-tree-root
-          (or (getenv "SOURCE_TREE_ROOT")
-              (and potential-invocation-root
-                   (file-exists-p
-                    (expand-file-name ".sxemacs.source.tree"
-                                      potential-invocation-root))
-                   (file-truename
-                    (expand-file-name ".sxemacs.source.tree"
-                                      potential-invocation-root)))))
-         (build-tree-root
-          (getenv "BUILD_TREE_ROOT")))
+        (source-tree-root
+         (or (getenv "SOURCE_TREE_ROOT")
+             (and potential-invocation-root
+                  (file-exists-p
+                   (expand-file-name ".sxemacs.source.tree"
+                                     potential-invocation-root))
+                  (file-truename
+                   (expand-file-name ".sxemacs.source.tree"
+                                     potential-invocation-root)))))
+        (build-tree-root
+         (getenv "BUILD_TREE_ROOT")))
     (when source-tree-root
       (setq invocation-roots (cons source-tree-root invocation-roots)
            invocation-roots (cons (or configure-prefix-directory
index 0b7011c..9b7a412 100644 (file)
@@ -10,7 +10,7 @@
 ;;     library directory names in finder-program-info, for fast display of
 ;;     Lisp libraries and associated commentaries.  Added {v}, finder-view,
 ;;     and {e}, finder-edit commands for displaying libraries.
-;;     
+;;
 ;;     Added user variable, 'finder-abbreviate-directory-list', used to
 ;;     abbreviate directories before they are saved to finder-program-info.
 ;;     Such relative directories can be portable from one Emacs installation
@@ -156,9 +156,9 @@ arguments compiles from `load-path'."
     (let ((processed nil)
          (directory-abbrev-alist
           (append
-           (mapcar (function (lambda (dir)
-                               (cons (concat "^" (regexp-quote dir))
-                                     "")))
+          (mapcar (function (lambda (dir)
+                              (cons (concat "^" (regexp-quote dir))
+                                    "")))
                    finder-abbreviate-directory-list)
            directory-abbrev-alist))
          (using-load-path))
@@ -174,33 +174,33 @@ arguments compiles from `load-path'."
       (mapcar
        (lambda (d)
         (mapcar
-         (lambda (f) 
-            (let ((exhau-f (expand-file-name f d)))
-              (when (and (not (member f processed))
-                         (file-readable-p exhau-f))
-                (let (summary keystart keywords)
-                  (setq processed (cons f processed))
-                  (if (not finder-compile-keywords-quiet)
-                      (message "Processing %s ..." f))
-                  (save-excursion
-                    (set-buffer (get-buffer-create "*finder-scratch*"))
-                    (buffer-disable-undo (current-buffer))
-                    (erase-buffer)
-                    (insert-file-contents (expand-file-name f d))
-                    (condition-case err
-                        (setq summary  (lm-synopsis)
-                              keywords (lm-keywords))
-                      (t (message "finder: error processing %s %S" f err))))
-                  (when summary
-                    (insert (format "    (\"%s\"\n        " f))
-                    (prin1 summary (current-buffer))
-                    (insert "\n        ")
-                    (setq keystart (point))
-                    (insert (if keywords (format "(%s)" keywords) "nil"))
-                    (subst-char-in-region keystart (point) ?, ? )
-                    (insert "\n        ")
-                    (prin1 (abbreviate-file-name d) (current-buffer))
-                    (insert ")\n"))))))
+         (lambda (f)
+           (let ((exhau-f (expand-file-name f d)))
+             (when (and (not (member f processed))
+                        (file-readable-p exhau-f))
+               (let (summary keystart keywords)
+                 (setq processed (cons f processed))
+                 (if (not finder-compile-keywords-quiet)
+                     (message "Processing %s ..." f))
+                 (save-excursion
+                   (set-buffer (get-buffer-create "*finder-scratch*"))
+                   (buffer-disable-undo (current-buffer))
+                   (erase-buffer)
+                   (insert-file-contents (expand-file-name f d))
+                   (condition-case err
+                       (setq summary  (lm-synopsis)
+                             keywords (lm-keywords))
+                     (t (message "finder: error processing %s %S" f err))))
+                 (when summary
+                   (insert (format "    (\"%s\"\n        " f))
+                   (prin1 summary (current-buffer))
+                   (insert "\n        ")
+                   (setq keystart (point))
+                   (insert (if keywords (format "(%s)" keywords) "nil"))
+                   (subst-char-in-region keystart (point) ?, ? )
+                   (insert "\n        ")
+                   (prin1 (abbreviate-file-name d) (current-buffer))
+                   (insert ")\n"))))))
          ;;
          ;; Skip null, non-existent or relative pathnames, e.g. "./", if
          ;; using load-path, so that they do not interfere with a scan of
@@ -234,8 +234,8 @@ arguments compiles from `load-path'."
               (= (preceding-char) ?\t))
          (let (indent-tabs-mode)
            (delete-char -1)
-            (indent-to col)
-            (move-to-column column)))))
+           (indent-to col)
+           (move-to-column column)))))
   (apply 'insert strings))
 
 (defun finder-list-keywords ()
index 0f0deb9..734689f 100644 (file)
@@ -67,7 +67,7 @@
 ;; string of the variable `font-lock-keywords' for the appropriate syntax.
 ;;
 ;; The default value for `lisp-font-lock-keywords' is the value of the variable
-;; `lisp-font-lock-keywords-1'.  You may like `lisp-font-lock-keywords-2' 
+;; `lisp-font-lock-keywords-1'.  You may like `lisp-font-lock-keywords-2'
 ;; better; it highlights many more words, but is slower and makes your buffers
 ;; be very visually noisy.
 ;;
 ;; doesn't work.  Or maybe it allows you to think less and drift off to sleep.
 ;;
 ;; So, here are my opinions/advice/guidelines:
-;; 
+;;
 ;; - Use the same face for the same conceptual object, across all modes.
 ;;   i.e., (b) above, all modes that have items that can be thought of as, say,
 ;;   keywords, should be highlighted with the same face, etc.
@@ -327,98 +327,98 @@ string text when fontifying."
  FONT-LOCK-KEYWORDS := List of FONT-LOCK-FORM's.
 
  FONT-LOCK-FORM     :== MATCHER
-                      | (MATCHER . MATCH)
-                      | (MATCHER . FACE-FORM)
-                      | (MATCHER . HIGHLIGHT)
-                      | (MATCHER HIGHLIGHT ...)
-                      | (eval . FORM)
+                     | (MATCHER . MATCH)
+                     | (MATCHER . FACE-FORM)
+                     | (MATCHER . HIGHLIGHT)
+                     | (MATCHER HIGHLIGHT ...)
+                     | (eval . FORM)
 
  MATCHER            :== A string containing a regexp.
-                      | A variable containing a regexp to search for.
-                      | A function to call to make the search.
-                        It is called with one arg, the limit of the search,
-                        and should leave MATCH results in the XEmacs global
-                        match data.
+                     | A variable containing a regexp to search for.
+                     | A function to call to make the search.
+                       It is called with one arg, the limit of the search,
+                       and should leave MATCH results in the XEmacs global
+                       match data.
 
  MATCH              :== An integer match subexpression number from MATCHER.
 
  FACE-FORM           :== The symbol naming a defined face.
-                      | Expression whos value is the face name to use.  If you
-                        want FACE-FORM to be a symbol that evaluates to a face,
-                        use a form like \"(progn sym)\".
+                     | Expression whos value is the face name to use.  If you
+                       want FACE-FORM to be a symbol that evaluates to a face,
+                       use a form like \"(progn sym)\".
 
  HIGHLIGHT          :== MATCH-HIGHLIGHT
-                      | MATCH-ANCHORED
+                     | MATCH-ANCHORED
 
  FORM               :== Expression returning a FONT-LOCK-FORM, evaluated when
-                        the FONT-LOCK-FORM is first used in a buffer.  This
-                        feature can be used to provide a FONT-LOCK-FORM that
-                        can only be generated when Font Lock mode is actually
-                        turned on.
+                       the FONT-LOCK-FORM is first used in a buffer.  This
+                       feature can be used to provide a FONT-LOCK-FORM that
+                       can only be generated when Font Lock mode is actually
+                       turned on.
 
  MATCH-HIGHLIGHT    :== (MATCH FACE-FORM OVERRIDE LAXMATCH)
 
  OVERRIDE           :== t        - overwrite existing fontification
-                      | 'keep    - only parts not already fontified are
-                                   highlighted.
-                      | 'prepend - merge faces, this fontification has
-                                   precedence over existing
-                      | 'append  - merge faces, existing fontification has
-                                   precedence over
-                                   this face.
+                     | 'keep    - only parts not already fontified are
+                                  highlighted.
+                     | 'prepend - merge faces, this fontification has
+                                  precedence over existing
+                     | 'append  - merge faces, existing fontification has
+                                  precedence over
+                                  this face.
 
  LAXMATCH           :== If non-nil, no error is signalled if there is no MATCH
-                        in MATCHER.
+                       in MATCHER.
 
  MATCH-ANCHORED     :== (ANCHOR-MATCHER PRE-MATCH-FORM \\
-                                          POST-MATCH-FORM MATCH-HIGHLIGHT ...)
+                                         POST-MATCH-FORM MATCH-HIGHLIGHT ...)
 
  ANCHOR-MATCHER     :== Like a MATCHER, except that the limit of the search
-                        defaults to the end of the line after PRE-MATCH-FORM
-                        is evaluated.  However, if PRE-MATCH-FORM returns a
-                        position greater than the end of the line, that
-                        position is used as the limit of the search.  It is
-                        generally a bad idea to return a position greater than
-                        the end of the line, i.e., cause the ANCHOR-MATCHER
-                        search to span lines.
+                       defaults to the end of the line after PRE-MATCH-FORM
+                       is evaluated.  However, if PRE-MATCH-FORM returns a
+                       position greater than the end of the line, that
+                       position is used as the limit of the search.  It is
+                       generally a bad idea to return a position greater than
+                       the end of the line, i.e., cause the ANCHOR-MATCHER
+                       search to span lines.
 
  PRE-MATCH-FORM     :== Evaluated before the ANCHOR-MATCHER is used, therefore
-                        can be used to initialize before, ANCHOR-MATCHER is
-                        used.  Typically, PRE-MATCH-FORM is used to move to
-                        some position relative to the original MATCHER, before
-                        starting with the ANCHOR-MATCHER.
+                       can be used to initialize before, ANCHOR-MATCHER is
+                       used.  Typically, PRE-MATCH-FORM is used to move to
+                       some position relative to the original MATCHER, before
+                       starting with the ANCHOR-MATCHER.
 
  POST-MATCH-FORM    :== Like PRE-MATCH-FORM, but used to clean up after the
-                        ANCHOR-MATCHER.  It might be used to move, before
-                        resuming with MATCH-ANCHORED's parent's MATCHER.
+                       ANCHOR-MATCHER.  It might be used to move, before
+                       resuming with MATCH-ANCHORED's parent's MATCHER.
 
 For example, an element of the first form highlights (if not already highlighted):
 
   \"\\\\\\=<foo\\\\\\=>\"                    Discrete occurrences of \"foo\" in the value
-                                 of the variable `font-lock-keyword-face'.
+                                of the variable `font-lock-keyword-face'.
 
   (\"fu\\\\(bar\\\\)\" . 1)            Substring \"bar\" within all occurrences of
-                                 \"fubar\" in the value of
-                                 `font-lock-keyword-face'.
+                                \"fubar\" in the value of
+                                `font-lock-keyword-face'.
 
   (\"fubar\" . fubar-face)         Occurrences of \"fubar\" in the value of
-                                 `fubar-face'.
+                                `fubar-face'.
 
   (\"foo\\\\|bar\" 0 foo-bar-face t) Occurrences of either \"foo\" or \"bar\" in the
-                                 value of `foo-bar-face', even if already
-                                 highlighted.
+                                value of `foo-bar-face', even if already
+                                highlighted.
 
   (fubar-match 1 fubar-face)     The first subexpression within all
-                                 occurrences of whatever the function
-                                 `fubar-match' finds and matches in the value
-                                 of `fubar-face'.
+                                occurrences of whatever the function
+                                `fubar-match' finds and matches in the value
+                                of `fubar-face'.
 
   (\"\\\\\\=<anchor\\\\\\=>\" (0 anchor-face) (\"\\\\\\=<item\\\\\\=>\" nil nil (0 item-face)))
    -------------- ---------------  ------------ --- --- -------------
        |            |               |            |   |          |
    MATCHER          |         ANCHOR-MATCHER     |   +------+ MATCH-HIGHLIGHT
-             MATCH-HIGHLIGHT                 PRE-MATCH-FORM |
-                                                           POST-MATCH-FORM
+            MATCH-HIGHLIGHT                 PRE-MATCH-FORM |
+                                                          POST-MATCH-FORM
 
   Discrete occurrences of \"anchor\" in the value of `anchor-face', and
   subsequent discrete occurrences of \"item\" (on the same line) in the value
@@ -661,7 +661,7 @@ The corresponding face should be set using `edit-faces' or the
 (defvar font-lock-warning-face 'font-lock-warning-face
   "This variable should not be set.
 It is present only for reasons of backwards compatibility.
-The corresponding face should be set using `edit-faces' or the 
+The corresponding face should be set using `edit-faces' or the
 `set-face-*' functions.")
 (defvar font-lock-doc-string-face 'font-lock-doc-string-face
   "This variable should not be set.
@@ -1002,7 +1002,7 @@ see the variables `c-font-lock-extra-types', `c++-font-lock-extra-types',
           ;; If the keywords were compiled before, compile them again.
           (if was-compiled
               (setq font-lock-keywords
-                     (font-lock-compile-keywords font-lock-keywords)))))))
+                    (font-lock-compile-keywords font-lock-keywords)))))))
 
 (defun font-lock-update-removed-keyword-alist (mode keywords how)
   "Update `font-lock-removed-keywords-alist' when adding new KEYWORDS to MODE."
@@ -1109,7 +1109,7 @@ happens, so the major mode can be corrected."
           ;; If the keywords were compiled before, compile them again.
           (if was-compiled
               (setq font-lock-keywords
-                     (font-lock-compile-keywords font-lock-keywords)))))))
+                    (font-lock-compile-keywords font-lock-keywords)))))))
 \f
 ;;;;;;;;;;;;;;;;;;;;;;        actual code        ;;;;;;;;;;;;;;;;;;;;;;
 
@@ -1203,7 +1203,7 @@ See the variable `font-lock-keywords' for customization."
                        'font-lock-after-change-function t)
           (setq font-lock-defaults-computed nil
                 font-lock-keywords nil)
-          ;; We have no business doing this here, since 
+          ;; We have no business doing this here, since
           ;; pre-idle-hook is global.  Other buffers may
           ;; still be in font-lock mode.  -dkindred@cs.cmu.edu
           ;; (remove-hook 'pre-idle-hook 'font-lock-pre-idle-hook)
@@ -1371,7 +1371,7 @@ This can take a while for large buffers."
       (or was-on (font-lock-mode 1))
       (font-lock-unfontify-region (point-min) (point-max) t)
       ;;    (buffer-syntactic-context-flush-cache)
-    
+
       ;; If a ^G is typed during fontification, abort the fontification, but
       ;; return normally (do not signal.)  This is to make it easy to abort
       ;; fontification if it's taking a long time, without also causing the
@@ -1428,7 +1428,7 @@ This can take a while for large buffers."
 ;; The following must be rethought, since keywords can override fontification.
 ;      ;; Now scan for keywords, but not if we are inside a comment now.
 ;      (or (and (not font-lock-keywords-only)
-;             (let ((state (parse-partial-sexp beg end nil nil 
+;             (let ((state (parse-partial-sexp beg end nil nil
 ;                                              font-lock-cache-state)))
 ;               (or (nth 4 state) (nth 7 state))))
 ;        (font-lock-fontify-keywords-region beg end))
@@ -1623,7 +1623,7 @@ is currently ignored."
       (when (or (nth 3 state) (nth 4 state))
        (setq string (nth 3 state) beg (point))
        (setq state (parse-partial-sexp (point) end nil nil state 'syntax-table))
-       (font-lock-set-face beg (point) (if string 
+       (font-lock-set-face beg (point) (if string
                                            font-lock-string-face
                                          font-lock-comment-face)))
       ;;
@@ -1744,26 +1744,26 @@ Optional argument OBJECT is the string or buffer containing the text."
 HIGHLIGHT should be of the form MATCH-HIGHLIGHT,
 see `font-lock-syntactic-keywords'."
   (let* ((match (nth 0 highlight))
-        (start (match-beginning match)) (end (match-end match))
-        (value (nth 1 highlight))
-        (override (nth 2 highlight)))
+        (start (match-beginning match)) (end (match-end match))
+        (value (nth 1 highlight))
+        (override (nth 2 highlight)))
     (unless (numberp (car-safe value))
       (setq value (eval value)))
     (cond ((not start)
-          ;; No match but we might not signal an error.
-          (or (nth 3 highlight)
-              (error "No match %d in highlight %S" match highlight)))
-         ((not override)
-          ;; Cannot override existing fontification.
-          (or (map-extents 'extent-property (current-buffer)
+          ;; No match but we might not signal an error.
+          (or (nth 3 highlight)
+              (error "No match %d in highlight %S" match highlight)))
+         ((not override)
+          ;; Cannot override existing fontification.
+          (or (map-extents 'extent-property (current-buffer)
                            start end 'syntax-table)
               (font-lock-set-syntax start end value)))
-         ((eq override t)
-          ;; Override existing fontification.
+         ((eq override t)
+          ;; Override existing fontification.
           (font-lock-set-syntax start end value))
-         ((eq override 'keep)
-          ;; Keep existing fontification.
-          (font-lock-fillin-text-property start end
+         ((eq override 'keep)
+          ;; Keep existing fontification.
+          (font-lock-fillin-text-property start end
                                           'syntax-table 'font-lock value)))))
 
 (defun font-lock-fontify-syntactic-anchored-keywords (keywords limit)
@@ -1771,22 +1771,22 @@ see `font-lock-syntactic-keywords'."
  KEYWORDS should be of the form MATCH-ANCHORED, see `font-lock-keywords',
  LIMIT can be modified by the value of its PRE-MATCH-FORM."
   (let ((matcher (nth 0 keywords)) (lowdarks (nthcdr 3 keywords)) highlights
-       ;; Evaluate PRE-MATCH-FORM.
-       (pre-match-value (eval (nth 1 keywords))))
+       ;; Evaluate PRE-MATCH-FORM.
+       (pre-match-value (eval (nth 1 keywords))))
     ;; Set LIMIT to value of PRE-MATCH-FORM or the end of line.
     (if (and (numberp pre-match-value) (> pre-match-value (point)))
-       (setq limit pre-match-value)
+       (setq limit pre-match-value)
       (save-excursion (end-of-line) (setq limit (point))))
     (save-match-data
       ;; Find an occurrence of `matcher' before `limit'.
       (while (if (stringp matcher)
-                (re-search-forward matcher limit t)
-              (funcall matcher limit))
-       ;; Apply each highlight to this instance of `matcher'.
-       (setq highlights lowdarks)
-       (while highlights
-         (font-lock-apply-syntactic-highlight (car highlights))
-         (setq highlights (cdr highlights)))))
+                (re-search-forward matcher limit t)
+              (funcall matcher limit))
+       ;; Apply each highlight to this instance of `matcher'.
+       (setq highlights lowdarks)
+       (while highlights
+         (font-lock-apply-syntactic-highlight (car highlights))
+         (setq highlights (cdr highlights)))))
     ;; Evaluate POST-MATCH-FORM.
     (eval (nth 2 keywords))))
 
@@ -1891,7 +1891,7 @@ START should be at the beginning of a line."
            (font-lock-compile-keywords font-lock-keywords)))
     (let* ((case-fold-search font-lock-keywords-case-fold-search)
           (keywords (cdr font-lock-keywords))
-          (bufname (buffer-name)) 
+          (bufname (buffer-name))
           (progress 5) (old-progress 5)
           (iter 0)
           (nkeywords (length keywords))
@@ -1900,8 +1900,8 @@ START should be at the beginning of a line."
       ;; Fontify each item in `font-lock-keywords' from `start' to `end'.
       ;; In order to measure progress accurately we need to know how
       ;; many keywords we have and how big the region is. Then progress
-      ;; is ((pos - start)/ (end - start) * nkeywords 
-      ;;       + iteration / nkeywords) * 100
+      ;; is ((pos - start)/ (end - start) * nkeywords
+      ;;       + iteration / nkeywords) * 100
       (while keywords
        ;;
        ;; Find an occurrence of `matcher' from `start' to `end'.
@@ -2086,13 +2086,13 @@ Each keyword has the form (MATCHER HIGHLIGHT ...).  See `font-lock-keywords'."
                                      (boundp n))
                                 n
                               nil))))
-               (setq font-lock-keywords 
+               (setq font-lock-keywords
                      (symbol-value
                       (or (funcall try (get major-mode 'font-lock-keywords))
                           (funcall try (concat major "-font-lock-keywords"))
                           (funcall try (and (string-match "-mode\\'" major)
-                                            (concat (substring 
-                                                     major 0 
+                                            (concat (substring
+                                                     major 0
                                                      (match-beginning 0))
                                                     "-font-lock-keywords")))
                           'font-lock-keywords)))))
@@ -2115,7 +2115,7 @@ Each keyword has the form (MATCHER HIGHLIGHT ...).  See `font-lock-keywords'."
            ;; older way:
            ;; cleverly examine the syntax table.
            (font-lock-examine-syntax-table))
-          
+
          ;; Syntax table?
          (if (nth 3 defaults)
              (let ((slist (nth 3 defaults)))
@@ -2152,7 +2152,7 @@ Each keyword has the form (MATCHER HIGHLIGHT ...).  See `font-lock-keywords'."
 ;; for SYNTAX-BEGIN.  Thus the calculation of the cache is usually
 ;; faster but not infallible, so we risk mis-fontification.  --sm.
 
-(put 'c-mode 'font-lock-defaults 
+(put 'c-mode 'font-lock-defaults
      '((c-font-lock-keywords
        c-font-lock-keywords-1 c-font-lock-keywords-2 c-font-lock-keywords-3)
        nil nil ((?_ . "w")) beginning-of-defun))
@@ -2165,7 +2165,7 @@ Each keyword has the form (MATCHER HIGHLIGHT ...).  See `font-lock-keywords'."
        c++-font-lock-keywords-3)
        nil nil ((?_ . "w") (?~ . "w")) beginning-of-defun))
 
-(put 'java-mode 'font-lock-defaults 
+(put 'java-mode 'font-lock-defaults
      '((java-font-lock-keywords
        java-font-lock-keywords-1 java-font-lock-keywords-2
        java-font-lock-keywords-3)
@@ -2431,10 +2431,10 @@ Each keyword has the form (MATCHER HIGHLIGHT ...).  See `font-lock-keywords'."
   ;; belonging to it) is expected to by skip-able by `forward-sexp', and items
   ;; are expected to be separated with a "," or ";".
   (if (looking-at (concat "[ \t*&]*"
-                          #r"\(\(?:\sw\|\s_\)+\)"
-                          #r"\(::\(\(?:\sw\|\s_\)+\)\)?"
-                          "[ \t]*"
-                          #r"\((\)?"))
+                         #r"\(\(?:\sw\|\s_\)+\)"
+                         #r"\(::\(\(?:\sw\|\s_\)+\)\)?"
+                         "[ \t]*"
+                         #r"\((\)?"))
       (save-match-data
        (condition-case nil
            (save-restriction
@@ -2501,7 +2501,7 @@ Each keyword has the form (MATCHER HIGHLIGHT ...).  See `font-lock-keywords'."
    ;; These are all anchored at the beginning of line for speed.
    ;;
    ;; Fontify function name definitions (GNU style; without type on line).
-   
+
    ;; In FSF this has the simpler definition of "\\sw+" for ctoken.
    ;; I'm not sure if ours is more correct.
    ;; This is a subset of the next rule, and is slower when present. --dmoore
@@ -2517,14 +2517,14 @@ Each keyword has the form (MATCHER HIGHLIGHT ...).  See `font-lock-keywords'."
    ;; x?x?x?y?z should always be: (x(xx?)?)?y?z --dmoore
    (list (concat
          "^\\("
-          "\\(" ctoken "[ \t]+\\)"     ; type specs; there can be no
+         "\\(" ctoken "[ \t]+\\)"      ; type specs; there can be no
          "\\("
-          "\\(" ctoken "[ \t]+\\)"     ; more than 3 tokens, right?
-          "\\(" ctoken "[ \t]+\\)"
+         "\\(" ctoken "[ \t]+\\)"      ; more than 3 tokens, right?
+         "\\(" ctoken "[ \t]+\\)"
          "?\\)?\\)?"
-          "\\([*&]+[ \t]*\\)?"         ; pointer
-          "\\(" ctoken "\\)[ \t]*(")   ; name
-         10 'font-lock-function-name-face)
+         "\\([*&]+[ \t]*\\)?"          ; pointer
+         "\\(" ctoken "\\)[ \t]*(")    ; name
+        10 'font-lock-function-name-face)
    ;;
    ;; This is faster but not by much.  I don't see why not.
    ;(list (concat "^\\(" ctoken "\\)[ \t]*(") 1 'font-lock-function-name-face)
@@ -2534,8 +2534,8 @@ Each keyword has the form (MATCHER HIGHLIGHT ...).  See `font-lock-keywords'."
    ;;
    ;; Fontify structure names (in structure definition form).
    (list (concat "^\\(typedef[ \t]+struct\\|struct\\|static[ \t]+struct\\)"
-          "[ \t]+\\(" ctoken "\\)[ \t]*\\(\{\\|$\\)")
-         2 'font-lock-function-name-face)
+          "[ \t]+\\(" ctoken "\\)[ \t]*\\(\{\\|$\\)")
+        2 'font-lock-function-name-face)
    ;;
    ;; Fontify case clauses.  This is fast because its anchored on the left.
    '("case[ \t]+\\(\\(\\sw\\|\\s_\\)+\\)[ \t]+:". 1)
@@ -2728,7 +2728,7 @@ This adds highlighting of Java documentation tags, such as @see.")
 
 (defvar java-font-lock-type-regexp
   (concat #r"\<\(boolean\|byte\|char\|double\|float\|int"
-          #r"\|long\|short\|void\)\>")
+         #r"\|long\|short\|void\)\>")
   "Regexp which should match a primitive type.")
 
 (defvar java-font-lock-identifier-regexp
@@ -2754,7 +2754,7 @@ The name is assumed to begin with a capital letter.")
   (setq java-font-lock-keywords-1
        (list
         ;; Keywords:
-        (list        
+        (list
          (concat
           #r"\<\("
           #r"break\|byvalue\|"
@@ -2779,7 +2779,7 @@ The name is assumed to begin with a capital letter.")
         (list (concat #r"\<\(class\|interface\)\>\s *"
                       java-font-lock-identifier-regexp)
               2 'font-lock-function-name-face)
-        
+
         ;; Package declarations:
         (list (concat #r"\<\(package\|import\)\>\s *"
                       java-font-lock-identifier-regexp)
@@ -2789,7 +2789,7 @@ The name is assumed to begin with a capital letter.")
                     nil nil '(1 (if (equal (char-after (match-end 0)) ?.)
                                     'font-lock-reference-face
                                   'font-lock-type-face))))
-        
+
         ;; Constructors:
         (list (concat
                "^\\s *\\(" java-modifier-regexp "\\s +\\)*"
@@ -2829,7 +2829,7 @@ The name is assumed to begin with a capital letter.")
 
   ;; Types and declared variable names:
   (setq java-font-lock-keywords-2
-       (append 
+       (append
 
         java-font-lock-keywords-1
         (list
@@ -2899,11 +2899,11 @@ The name is assumed to begin with a capital letter.")
                  (goto-char (match-end 1))
                  (goto-char (match-end 0))
                  (1 font-lock-variable-name-face))))))
-       
+
   ;; Modifier keywords and Java doc tags
   (setq java-font-lock-keywords-3
        (append
+
         '(
           ;; Feature scoping:
           ;; These must come first or the Modifiers from keywords-1 will
@@ -2913,7 +2913,7 @@ The name is assumed to begin with a capital letter.")
           (#r"\<protected\>" 0 font-lock-preprocessor-face)
           (#r"\<public\>"    0 font-lock-reference-face))
         java-font-lock-keywords-2
+
         (list
 
          ;; Javadoc tags
@@ -2933,11 +2933,11 @@ The name is assumed to begin with a capital letter.")
                      '(goto-char (match-end 0)) nil
                      '(1 (if (equal (char-after (match-end 0)) ?.)
                              'font-lock-reference-face 'font-lock-type-face) t)))
-    
-         ;; Doc tag - Cross-references, usually to methods 
+
+         ;; Doc tag - Cross-references, usually to methods
          '("@see\\s +\\(\\S *[^][ \t\n\r\f(){},.;:]\\)"
            1 font-lock-function-name-face t)
-    
+
          ;; Doc tag - docRoot (1.3)
          '(#r"\({ *@docRoot *}\)"
            0 font-lock-keyword-face t)
@@ -2950,7 +2950,7 @@ The name is assumed to begin with a capital letter.")
          ;; Doc tag - Links
          '(#r"{ *@link\s +\(\(\S +\)\|\(\S +\s +\S +\)\) *}"
            1 font-lock-function-name-face t)
-    
+
          )))
   )
 
@@ -3025,7 +3025,7 @@ The name is assumed to begin with a capital letter.")
      3 (if (match-beginning 2) 'bold 'italic) keep))
   "Default expressions to highlight in TeX modes.")
 
-(defconst ksh-font-lock-keywords 
+(defconst ksh-font-lock-keywords
   (list
    '(#r"\(^\|[^\$\\]\)#.*" . font-lock-comment-face)
    '(#r"\<\(if\|then\|else\|elif\|fi\|case\|esac\|for\|do\|done\|foreach\|in\|end\|select\|while\|repeat\|time\|function\|until\|exec\|command\|coproc\|noglob\|nohup\|nocorrect\|source\|autoload\|alias\|unalias\|export\|set\|echo\|eval\|cd\|log\|compctl\)\>" . font-lock-keyword-face)
@@ -3034,7 +3034,7 @@ The name is assumed to begin with a capital letter.")
    )
   "Additional expressions to highlight in ksh-mode.")
 
-(defconst sh-font-lock-keywords 
+(defconst sh-font-lock-keywords
   (list
    '(#r"\(^\|[^\$\\]\)#.*" . font-lock-comment-face)
    '(#r"\<\(if\|then\|else\|elif\|fi\|case\|esac\|for\|do\|done\|in\|while\|exec\|export\|set\|echo\|eval\|cd\)\>" . font-lock-keyword-face)
index 4f55c8a..03ec57e 100644 (file)
@@ -153,7 +153,7 @@ the last entry in the menu."
                 (function)))
 
 (defvar font-menu-preferred-resolution
-  (make-specifier-and-init 'generic '((global 
+  (make-specifier-and-init 'generic '((global
                                       ((x) . "*-*"))) t)
   "Preferred horizontal and vertical font menu resolution (e.g. \"75:75\").")
 
@@ -343,7 +343,7 @@ or if you change your font path, you can call this to re-initialize the menus."
         (from-size   (aref font-data 2))
           (from-weight (aref font-data 3))
         (from-slant  (aref font-data 4))
-        (face-list-to-change (delq 'default (face-list)))
+        (face-list-to-change (delq 'default (face-list)))
         new-default-face-font)
     (unless from-family
       (signal 'error '("couldn't parse font name for default face")))
index 5829c68..66c7b5c 100644 (file)
@@ -470,9 +470,9 @@ The type may be the strings \"px\", \"pix\", or \"pixel\" (pixels), \"pt\" or
                                    (boundp 'x-font-regexp)
                                    x-font-regexp)
  (let
-     ((-               "[-?]")
+     ((-               "[-?]")
       (foundry         "[^-]*")
-      (family          "[^-]*")
+      (family          "[^-]*")
       ;(weight         #r"\(bold\|demibold\|medium\|black\)")
       (weight\?                #r"\([^-]*\)")
       ;(slant          #r"\([ior]\)")
index 9fc1fa5..6f37367 100644 (file)
@@ -70,7 +70,7 @@ If EXPLICIT-DEFAULTS is not nil and not t, it should be something
 that is allowable as a value for `font-lock-defaults' and will be
 used to initialize the Font Lock variables."
 
-  (with-boundp '(font-lock-auto-fontify 
+  (with-boundp '(font-lock-auto-fontify
                 font-lock-mode-disable-list font-lock-mode-enable-list
                 font-lock-keywords)
     (when
index 2e7414d..cf1b7c6 100644 (file)
@@ -133,31 +133,31 @@ Elements are of the form \(NAME DOC-STR REGEXP FROM-FN TO-FN MODIFY MODE-FN).
 NAME    is a symbol, which is stored in `buffer-file-format'.
 
 DOC-STR should be a single line providing more information about the
-        format.  It is currently unused, but in the future will be shown to
-        the user if they ask for more information.
+       format.  It is currently unused, but in the future will be shown to
+       the user if they ask for more information.
 
 REGEXP  is a regular expression to match against the beginning of the file;
-        it should match only files in that format.
+       it should match only files in that format.
 
 FROM-FN is called to decode files in that format; it gets two args, BEGIN
-        and END, and can make any modifications it likes, returning the new
-        end.  It must make sure that the beginning of the file no longer
-        matches REGEXP, or else it will get called again.
+       and END, and can make any modifications it likes, returning the new
+       end.  It must make sure that the beginning of the file no longer
+       matches REGEXP, or else it will get called again.
        Alternatively, FROM-FN can be a string, which specifies a shell command
        (including options) to be used as a filter to perform the conversion.
 
 TO-FN   is called to encode a region into that format; it is passed three
-        arguments: BEGIN, END, and BUFFER.  BUFFER is the original buffer that
-        the data being written came from, which the function could use, for
-        example, to find the values of local variables.  TO-FN should either
-        return a list of annotations like `write-region-annotate-functions',
-        or modify the region and return the new end.
+       arguments: BEGIN, END, and BUFFER.  BUFFER is the original buffer that
+       the data being written came from, which the function could use, for
+       example, to find the values of local variables.  TO-FN should either
+       return a list of annotations like `write-region-annotate-functions',
+       or modify the region and return the new end.
        Alternatively, TO-FN can be a string, which specifies a shell command
        (including options) to be used as a filter to perform the conversion.
 
 MODIFY, if non-nil, means the TO-FN wants to modify the region.  If nil,
-        TO-FN will not make any changes but will instead return a list of
-        annotations.
+       TO-FN will not make any changes but will instead return a list of
+       annotations.
 
 MODE-FN, if specified, is called when visiting a file with that format.")
 
index 6636a66..f366856 100644 (file)
@@ -545,8 +545,8 @@ The value returned is the value of the last form in BODY."
   (let ((old-frame (gensym "ssf")))
     `(let ((,old-frame (selected-frame)))
        (unwind-protect
-           (progn ,@body)
-         (select-frame ,old-frame)))))
+          (progn ,@body)
+        (select-frame ,old-frame)))))
 
 (defmacro with-selected-frame (frame &rest body)
   "Execute forms in BODY with FRAME as the selected frame.
@@ -838,7 +838,7 @@ For use as the value of `deselect-frame-hook'."
   :group 'frames)
 
 (defcustom get-frame-for-buffer-default-instance-limit nil
-  "*The default instance limit for creating new frames; 
+  "*The default instance limit for creating new frames;
 see doc of `get-frame-for-buffer'."
   :type 'integer
   :group 'frames)
@@ -897,7 +897,7 @@ This is a subroutine of `get-frame-for-buffer' (which see)."
        ;; Sort the list so that iconic frames will be found last.  They
        ;; will be used too, but mapped frames take precedence.  And
        ;; fully visible frames come before occluded frames.
-        ;; Hidden frames come after really visible ones
+       ;; Hidden frames come after really visible ones
        (setq frames
              (sort (frame-list)
                    #'(lambda (s1 s2)
index 76fcea0..1313074 100644 (file)
@@ -1056,34 +1056,34 @@ If unspecified in a particular domain, `nontext-pointer-glyph' is used.")
   ;; finish initializing sxemacs logo -- created internally because it
   ;; has a built-in bitmap
   (let ((temp-etcdir
-         (if (getenv "SOURCE_TREE_ROOT")
-             (expand-file-name "etc/" (getenv "SOURCE_TREE_ROOT"))
-           (expand-file-name "etc/" ".."))))
+        (if (getenv "SOURCE_TREE_ROOT")
+            (expand-file-name "etc/" (getenv "SOURCE_TREE_ROOT"))
+          (expand-file-name "etc/" ".."))))
 
     (when debug-paths
       (princ (format "tempetc: %s\n" temp-etcdir)
-             'external-debugging-output))
+            'external-debugging-output))
 
     (if (featurep 'xpm)
-        (set-glyph-image sxemacs-logo
-                         (expand-file-name
-                          (if emacs-beta-version
-                              "sxemacs-beta.xpm"
-                            "sxemacs.xpm") temp-etcdir)
-                         'global 'x))
+       (set-glyph-image sxemacs-logo
+                        (expand-file-name
+                         (if emacs-beta-version
+                             "sxemacs-beta.xpm"
+                           "sxemacs.xpm") temp-etcdir)
+                        'global 'x))
     (cond ((featurep 'xpm)
-           (set-glyph-image frame-icon-glyph
-                            (expand-file-name "sxemacs-icon.xpm" temp-etcdir)
-                            'global 'x))
-          ((featurep 'x)
-           (set-glyph-image frame-icon-glyph
-                            (expand-file-name "xemacs-icon2.xbm" temp-etcdir)
-                            'global 'x)))
+          (set-glyph-image frame-icon-glyph
+                           (expand-file-name "sxemacs-icon.xpm" temp-etcdir)
+                           'global 'x))
+         ((featurep 'x)
+          (set-glyph-image frame-icon-glyph
+                           (expand-file-name "xemacs-icon2.xbm" temp-etcdir)
+                           'global 'x)))
 
     (if (featurep 'tty)
-        (set-glyph-image sxemacs-logo
-                         "SXEmacs <insert spiffy graphic logo here>"
-                         'global 'tty))))
+       (set-glyph-image sxemacs-logo
+                        "SXEmacs <insert spiffy graphic logo here>"
+                        'global 'tty))))
 
 (init-glyphs)
 
index 39c84f5..faba993 100644 (file)
@@ -127,7 +127,7 @@ only argument, and its return value will be interpreted as above."
   :tag "Gnuserv Frame"
   :type '(radio (const :tag "Create new frame each time" nil)
                (const :tag "Use selected frame" t)
-               (function-item :tag "Use main Emacs frame"
+               (function-item :tag "Use main Emacs frame"
                               gnuserv-main-frame-function)
                (function-item :tag "Use visible frame, otherwise create new"
                               gnuserv-visible-frame-function)
@@ -229,11 +229,11 @@ will request editing of several files.
 
 ID       - Client id (integer).
 BUFFERS  - List of buffers that \"belong\" to the client.
-           NOTE: one buffer can belong to several clients.
+          NOTE: one buffer can belong to several clients.
 DEVICE   - The device this client is on.  If the device was also created.
-           by a client, it will be placed to `gnuserv-devices' list.
+          by a client, it will be placed to `gnuserv-devices' list.
 FRAME    - Frame created by the client, or nil if the client didn't
-           create a frame.
+          create a frame.
 
 All the slots default to nil."
   (id nil)
index f353be9..30f3584 100644 (file)
@@ -5,7 +5,7 @@
 
 ;; Maintainer: SXEmacs Development Team
 ;; Keywords: internal, dumped
+
 ;; This file is part of SXEmacs.
 
 ;; SXEmacs is free software: you can redistribute it and/or modify
index 3d714ab..3edb53d 100644 (file)
@@ -36,13 +36,13 @@ Do not set this. Use `set-glyph-image' to change the properties of the tab.")
 
 (defcustom gutter-buffers-tab-visible-p
   (gutter-element-visible-p default-gutter-visible-p 'buffers-tab)
-  "Whether the buffers tab is globally visible. 
+  "Whether the buffers tab is globally visible.
 
 There are side-effects, so don't setq it; use Customize or the options menu."
   :group 'buffers-tab
   :type 'boolean
   :set #'(lambda (var val)
-          (set-gutter-element-visible-p default-gutter-visible-p 
+          (set-gutter-element-visible-p default-gutter-visible-p
                                         'buffers-tab val)
           (setq gutter-buffers-tab-visible-p val)))
 
@@ -128,7 +128,7 @@ list in `buffer-list' order (usual most-recently-selected-first)."
   :type 'face
   :group 'buffers-tab)
 
-(defcustom buffers-tab-grouping-regexp 
+(defcustom buffers-tab-grouping-regexp
   '(#r"^\(gnus-\|message-mode\|mime/viewer-mode\)"
     #r"^\(emacs-lisp-\|lisp-\)")
   "*If non-nil, a list of regular expressions for buffer grouping.
@@ -155,7 +155,7 @@ about a buffer."
   "*Maximum length of text which may appear in a \"Buffers\" tab.
 This is a specifier, use set-specifier to modify it.")
 
-(defcustom buffers-tab-max-buffer-line-length 
+(defcustom buffers-tab-max-buffer-line-length
   (specifier-instance buffers-tab-default-buffer-line-length)
   "*Maximum length of text which may appear in a \"Buffers\" tab.
 Buffer names over this length will be truncated with elipses.
@@ -183,7 +183,7 @@ If this is 0, then the full buffer name will be shown."
   "For use as a value of `buffers-tab-selection-function'.
 This selects buffers by major mode `buffers-tab-grouping-regexp'."
   (let ((mode1 (symbol-name (symbol-value-in-buffer 'major-mode buf1)))
-       (mode2 (symbol-name (symbol-value-in-buffer 'major-mode 
+       (mode2 (symbol-name (symbol-value-in-buffer 'major-mode
                                                    buffer-to-select)))
        (modenm1 (symbol-value-in-buffer 'mode-name buf1))
        (modenm2 (symbol-value-in-buffer 'mode-name buffer-to-select)))
@@ -191,7 +191,7 @@ This selects buffers by major mode `buffers-tab-grouping-regexp'."
               (eq modenm1 modenm2)
               (and (string-match "^[^-]+-" mode1)
                    (string-match
-                    (concat "^" (regexp-quote 
+                    (concat "^" (regexp-quote
                                  (substring mode1 0 (match-end 0))))
                     mode2))
               (and buffers-tab-grouping-regexp
@@ -212,7 +212,7 @@ This just returns the buffer's name, optionally truncated."
     (if (and (> len 0)
             (> (length (buffer-name buffer)) len))
        (if (string-match ".*<.>$" (buffer-name buffer))
-           (concat (substring (buffer-name buffer) 
+           (concat (substring (buffer-name buffer)
                               0 (- len 6)) "..."
                               (substring (buffer-name buffer) -3))
          (concat (substring (buffer-name buffer)
@@ -224,7 +224,7 @@ This just returns the buffer's name, optionally truncated."
     (mapcar
      #'(lambda (buffer)
         (prog1
-            (vector 
+            (vector
              (funcall buffers-tab-format-buffer-line-function
                       buffer)
              (list buffers-tab-switch-to-buffer-function
@@ -250,7 +250,7 @@ redefining the function `format-buffers-menu-line'."
     ;; NB it is too late if we run the omit function as part of the
     ;; filter functions because we need to know which buffer is the
     ;; context buffer before they get run.
-    (let* ((buffers (delete-if 
+    (let* ((buffers (delete-if
                     buffers-tab-omit-function (buffer-list frame)))
           (first-buf (car buffers)))
       ;; maybe force the selected window
@@ -260,14 +260,14 @@ redefining the function `format-buffers-menu-line'."
        (setq buffers (cons (window-buffer (selected-window frame))
                            (delq first-buf buffers))))
       ;; if we're in deletion ignore the current buffer
-      (when in-deletion 
+      (when in-deletion
        (setq buffers (delq (current-buffer) buffers))
        (setq first-buf (car buffers)))
       ;; filter buffers
       (when buffers-tab-filter-functions
        (setq buffers
-             (delete-if 
-              #'null 
+             (delete-if
+              #'null
               (mapcar #'(lambda (buf)
                           (let ((tmp-buf buf))
                             (mapc #'(lambda (fun)
@@ -294,7 +294,7 @@ redefining the function `format-buffers-menu-line'."
   (let* ((gutter-string (copy-sequence "\n"))
         (gutter-buffers-tab-extent (make-extent 0 1 gutter-string)))
     (set-extent-begin-glyph gutter-buffers-tab-extent
-                           (setq gutter-buffers-tab 
+                           (setq gutter-buffers-tab
                                  (make-glyph)))
     ;; Nuke all existing tabs
     (remove-gutter-element top-gutter 'buffers-tab)
@@ -308,7 +308,7 @@ redefining the function `format-buffers-menu-line'."
           (cond ((eq gutter-buffers-tab-orientation 'top)
                  ;; This looks better than a 3d border
                  (set-specifier top-gutter-border-width 0 'global x)
-                 (set-gutter-element top-gutter 'buffers-tab 
+                 (set-gutter-element top-gutter 'buffers-tab
                                      gutter-string 'global x))
                 ((eq gutter-buffers-tab-orientation 'bottom)
                  (set-specifier bottom-gutter-border-width 0 'global x)
@@ -347,19 +347,19 @@ redefining the function `format-buffers-menu-line'."
                         :pixel-width :pixel-height)
                     (if (or (eq gutter-buffers-tab-orientation 'top)
                             (eq gutter-buffers-tab-orientation 'bottom))
-                        '(gutter-pixel-width) '(gutter-pixel-height)) 
+                        '(gutter-pixel-width) '(gutter-pixel-height))
                     :items items)
             frame)
            ;; set-glyph-image will not make the gutter dirty
            (set-gutter-dirty-p gutter-buffers-tab-orientation)))))))
 
 ;; A myriad of different update hooks all doing slightly different things
-(add-one-shot-hook 
+(add-one-shot-hook
  'after-init-hook
  #'(lambda ()
      ;; don't add the hooks if the user really doesn't want them
      (when gutter-buffers-tab-enabled
-       (add-hook 'create-frame-hook 
+       (add-hook 'create-frame-hook
                 #'(lambda (frame)
                     (when gutter-buffers-tab (update-tab-in-gutter frame t))))
        (add-hook 'buffer-list-changed-hook 'update-tab-in-gutter)
@@ -428,17 +428,17 @@ side-by-side."
                    ,progress-text-instantiator)])
     (set-glyph-image progress-layout-glyph progress-layout-instantiator
                     locale))
-   (t 
+   (t
     (setq progress-glyph-height 24)
     (setq progress-layout-instantiator
-         `[layout 
+         `[layout
            :orientation vertical :margin-width 4
            :horizontally-justify left :vertically-justify center
            :items (,progress-text-instantiator
-                   [layout 
+                   [layout
                     :orientation horizontal
                     :items (,progress-gauge-instantiator
-                            [button 
+                            [button
                              :pixel-height (eval progress-glyph-height)
                              :descriptor " Stop "
                              ;; 'quit is special and acts "asynchronously".
@@ -503,7 +503,7 @@ you should just use (progress nil)."
            oldmsg)
        ;; nothing to display so get rid of the gauge
        (set-specifier bottom-gutter-border-width 0 frame)
-       (set-gutter-element-visible-p bottom-gutter-visible-p 
+       (set-gutter-element-visible-p bottom-gutter-visible-p
                                      'progress nil frame)))))
 
 (defun progress-feedback-clear-when-idle (&optional label)
@@ -527,7 +527,7 @@ you should just use (progress nil)."
 
 (defun progress-feedback-dispatch-non-command-events ()
   ;; don't allow errors to hose things
-  (condition-case t 
+  (condition-case t
       ;; (sit-for 0) is too agressive and cause more display than we
       ;; want.
       (dispatch-non-command-events)
@@ -542,7 +542,7 @@ you should just use (progress nil)."
        (progn
          (setcdr top message)
          (if (equal tmsg message)
-             (progn 
+             (progn
                (set-instantiator-property progress-gauge-instantiator :value value)
                (set-progress-feedback-instantiator (frame-selected-window frame)))
            (raw-append-progress-feedback message value frame))
@@ -579,7 +579,7 @@ you should just use (progress nil)."
          (set-instantiator-property progress-text-instantiator :data message)
          (set-progress-abort-instantiator (frame-selected-window frame))
          (set-specifier bottom-gutter-height 'autodetect frame)
-         (set-gutter-element-visible-p bottom-gutter-visible-p 
+         (set-gutter-element-visible-p bottom-gutter-visible-p
                                        'progress t frame)
          ;; we have to do this so redisplay is up-to-date and so
          ;; redisplay-gutter-area performs optimally.
@@ -637,7 +637,7 @@ message."
         (abort-progress-feedback label message frame))
        ((or (not (valid-image-instantiator-format-p 'progress-gauge frame))
             progress-feedback-use-echo-area)
-        (display-message label 
+        (display-message label
           (concat message (if (eq value 100) "done."
                             (make-string (/ value 5) ?.)))
           frame))
index f5d8ceb..cd09836 100644 (file)
@@ -76,7 +76,7 @@ will be created to put the glyph into."
   "Remove gutter element PROP from GUTTER-SPECIFIER in optional LOCALE.
 This is a convenience function for removing gutter elements."
   (modify-specifier-instances gutter-specifier #'plist-remprop (list prop)
-                              'force nil locale tag-set))
+                             'force nil locale tag-set))
 
 (defun set-gutter-element-visible-p (gutter-visible-specifier-p
                                     prop &optional visible-p
@@ -104,7 +104,7 @@ Given GUTTER-VISIBLE-SPECIFIER-P and gutter element PROP, return
 non-nil if it is visible in optional DOMAIN."
   (let ((spec (specifier-instance gutter-visible-specifier-p domain)))
     (or (and (listp spec) (memq 'buffers-tab spec))
-       spec)))
+       spec)))
 
 (defun set-gutter-dirty-p (gutter-or-location)
   "Make GUTTER-OR-LOCATION dirty to force redisplay updates."
@@ -114,9 +114,9 @@ non-nil if it is visible in optional DOMAIN."
            (eq gutter-or-location 'bottom)
            (eq gutter-or-location 'left)
            (eq gutter-or-location 'right))
-    (or (gutter-specifier-p gutter-or-location) 
+    (or (gutter-specifier-p gutter-or-location)
        (setq gutter-or-location
-             (eval (intern (concat 
+             (eval (intern (concat
                             (symbol-name gutter-or-location)
                             "-gutter")))))
     (set-specifier-dirty-flag gutter-or-location)))
@@ -182,5 +182,3 @@ corresponding symbol occurs in the gutter-visible instantiator."
   )
 
 ;;; gutter.el ends here.
-
-
index 0f801f2..e736613 100644 (file)
@@ -44,7 +44,7 @@
 ;;->
 ;;->c  Redistribute civs from overfull sectors into connected underfull ones
 ;;->     The functions typically named by empire-ideal-civ-fcn control
-;;->          based in part on empire-sector-civ-threshold  
+;;->          based in part on empire-sector-civ-threshold
 ;;->m  Redistribute military using levels given by empire-ideal-mil-fcn
 ;;->p  Redistribute excess population to highways for max pop growth
 ;;->     Excess is any sector so full babies will not be born.
@@ -173,4 +173,3 @@ and then returns."
                  (set-window-configuration config))))))))
 
 ;;; help-macro.el
-
index 3ec02df..f586ee5 100644 (file)
@@ -43,7 +43,7 @@
   (globally-declare-fboundp
    '(find-function find-variable view-scroll-lines-up)))
 
-(require 'loadhist) ;; For symbol-file. 
+(require 'loadhist) ;; For symbol-file.
 
 (defgroup help nil
   "Support for on-line help systems."
   :group 'help)
 
 (defvar help-map (let ((map (make-sparse-keymap)))
-                   (set-keymap-name map 'help-map)
-                   (set-keymap-prompt
+                  (set-keymap-name map 'help-map)
+                  (set-keymap-prompt
                    map (gettext "(Type ? for further options)"))
-                   map)
+                  map)
   "Keymap for characters following the Help key.")
 
 ;; global-map definitions moved to keydefs.el
@@ -332,7 +332,7 @@ If INSERT (the prefix arg) is non-nil, insert the message in the buffer."
        defn menup)
     (setq defn (key-or-menu-binding key 'menup))
     (if (or (null defn) (integerp defn))
-        (princ (format "%s is undefined" (key-description key)))
+       (princ (format "%s is undefined" (key-description key)))
       ;; If it's a keyboard macro which trivially invokes another command,
       ;; document that instead.
       (if (or (stringp defn) (vectorp defn))
@@ -373,14 +373,14 @@ If FUNCTION is nil, applies `message' to it, thus printing it."
        (funcall
        (or function 'message)
        (concat
-         (substitute-command-keys
-          (if (one-window-p t)
-              (if pop-up-windows
-                  (gettext "Type \\[delete-other-windows] to remove help window.")
-                (gettext "Type \\[switch-to-buffer] RET to remove help window."))
+        (substitute-command-keys
+         (if (one-window-p t)
+             (if pop-up-windows
+                 (gettext "Type \\[delete-other-windows] to remove help window.")
+               (gettext "Type \\[switch-to-buffer] RET to remove help window."))
    (gettext "Type \\[switch-to-buffer-other-window] RET to restore the other window.")))
-         (substitute-command-keys
-          (gettext "  \\[scroll-other-window] to scroll the help."))))))
+        (substitute-command-keys
+         (gettext "  \\[scroll-other-window] to scroll the help."))))))
 
 (defcustom help-selects-help-window t
   "*If nil, use the \"old Emacs\" behavior for Help buffers.
@@ -407,22 +407,22 @@ zero or nil, only one help buffer, \"*Help*\" is ever used."
   (setq help-buffer-list (remove newbuf help-buffer-list))
   ;; maybe kill excess help buffers
   (if (and (integerp help-max-help-buffers)
-           (> (length help-buffer-list) help-max-help-buffers))
+          (> (length help-buffer-list) help-max-help-buffers))
       (let ((keep-list nil)
-            (num-kill (- (length help-buffer-list)
-                         help-max-help-buffers)))
-        (while help-buffer-list
-          (let ((buf (car help-buffer-list)))
-            (if (and (or (equal buf newbuf) (get-buffer buf))
-                     (string-match "^*Help" buf)
-                     (save-excursion (set-buffer buf)
-                                     (eq major-mode 'help-mode)))
-                (if (and (>= num-kill (length help-buffer-list))
-                         (not (get-buffer-window buf t t)))
-                    (kill-buffer buf)
-                  (setq keep-list (cons buf keep-list)))))
-          (setq help-buffer-list (cdr help-buffer-list)))
-        (setq help-buffer-list (nreverse keep-list))))
+           (num-kill (- (length help-buffer-list)
+                        help-max-help-buffers)))
+       (while help-buffer-list
+         (let ((buf (car help-buffer-list)))
+           (if (and (or (equal buf newbuf) (get-buffer buf))
+                    (string-match "^*Help" buf)
+                    (save-excursion (set-buffer buf)
+                                    (eq major-mode 'help-mode)))
+               (if (and (>= num-kill (length help-buffer-list))
+                        (not (get-buffer-window buf t t)))
+                   (kill-buffer buf)
+                 (setq keep-list (cons buf keep-list)))))
+         (setq help-buffer-list (cdr help-buffer-list)))
+       (setq help-buffer-list (nreverse keep-list))))
   ;; push new buffer
   (setq help-buffer-list (cons newbuf help-buffer-list)))
 
@@ -433,8 +433,8 @@ You should never set this directory, only let-bind it.")
 (defun help-buffer-name (name)
   "Return a name for a Help buffer using string NAME for context."
   (if (and (integerp help-max-help-buffers)
-           (> help-max-help-buffers 0)
-           (stringp name))
+          (> help-max-help-buffers 0)
+          (stringp name))
       (if help-buffer-prefix-string
          (format "*%s: %s*" help-buffer-prefix-string name)
        (format "*%s*" name))
@@ -525,7 +525,7 @@ When called interactively, KEY may also be a menu selection."
   (let ((defn (key-or-menu-binding key))
        (key-string (key-description key)))
     (if (or (null defn) (integerp defn))
-        (message "%s is undefined" key-string)
+       (message "%s is undefined" key-string)
       (with-displaying-help-buffer
        (lambda ()
         (princ key-string)
@@ -656,15 +656,15 @@ is non-nil then only the mouse bindings are displayed."
 
 (defun describe-bindings-1 (&optional prefix mouse-only-p)
   (let ((heading (if mouse-only-p
-            (gettext "button          binding\n------          -------\n")
-            (gettext "key             binding\n---             -------\n")))
-        (buffer (current-buffer))
-        (minor minor-mode-map-alist)
+           (gettext "button          binding\n------          -------\n")
+           (gettext "key             binding\n---             -------\n")))
+       (buffer (current-buffer))
+       (minor minor-mode-map-alist)
        (extent-maps (mapcar-extents
                      'extent-keymap
                      nil (current-buffer) (point) (point) nil 'keymap))
-        (local (current-local-map))
-        (shadow '()))
+       (local (current-local-map))
+       (shadow '()))
     (set-buffer standard-output)
     (while extent-maps
       (insert "Bindings for Text Region:\n"
@@ -676,25 +676,25 @@ is non-nil then only the mouse bindings are displayed."
             extent-maps (cdr extent-maps)))
     (while minor
       (let ((sym (car (car minor)))
-            (map (cdr (car minor))))
-        (if (symbol-value-in-buffer sym buffer nil)
-            (progn
-              (insert (format "Minor Mode Bindings for `%s':\n"
-                              sym)
-                      heading)
-              (describe-bindings-internal map nil shadow prefix mouse-only-p)
-              (insert "\n")
-              (setq shadow (cons map shadow))))
-        (setq minor (cdr minor))))
+           (map (cdr (car minor))))
+       (if (symbol-value-in-buffer sym buffer nil)
+           (progn
+             (insert (format "Minor Mode Bindings for `%s':\n"
+                             sym)
+                     heading)
+             (describe-bindings-internal map nil shadow prefix mouse-only-p)
+             (insert "\n")
+             (setq shadow (cons map shadow))))
+       (setq minor (cdr minor))))
     (if local
-        (progn
-          (insert "Local Bindings:\n" heading)
-          (describe-bindings-internal local nil shadow prefix mouse-only-p)
-          (insert "\n")
-          (setq shadow (cons local shadow))))
+       (progn
+         (insert "Local Bindings:\n" heading)
+         (describe-bindings-internal local nil shadow prefix mouse-only-p)
+         (insert "\n")
+         (setq shadow (cons local shadow))))
     (insert "Global Bindings:\n" heading)
     (describe-bindings-internal (current-global-map)
-                                nil shadow prefix mouse-only-p)
+                               nil shadow prefix mouse-only-p)
     (when (and prefix function-key-map (not mouse-only-p))
       (insert "\nFunction key map translations:\n" heading)
       (describe-bindings-internal function-key-map nil nil
@@ -841,13 +841,13 @@ The number of messages shown is controlled by `view-lossage-message-count'."
 \(Use SPC or DEL to scroll through this text.  Type \\<help-map>\\[help-quit] to exit the Help command.)
 
 \\[hyper-apropos]      Type a substring; it shows a hypertext list of
-        functions and variables that contain that substring.
+       functions and variables that contain that substring.
        See also the `apropos' command.
 \\[command-apropos]    Type a substring; it shows a list of commands
-        (interactively callable functions) that contain that substring.
+       (interactively callable functions) that contain that substring.
 \\[describe-bindings]  Table of all key bindings.
 \\[describe-key-briefly]       Type a command key sequence;
-        it displays the function name that sequence runs.
+       it displays the function name that sequence runs.
 \\[customize]  Customize Emacs options.
 \\[Info-goto-emacs-command-node]       Type a function name; it displays the Info node for that command.
 \\[describe-function]  Type a function name; it shows its documentation.
@@ -857,9 +857,9 @@ The number of messages shown is controlled by `view-lossage-message-count'."
 \\[info]       Info documentation reader.
 \\[Info-query] Type an Info file name; it displays it in Info reader.
 \\[describe-key]       Type a command key sequence;
-        it displays the documentation for the command bound to that key.
+       it displays the documentation for the command bound to that key.
 \\[Info-goto-emacs-key-command-node]   Type a command key sequence;
-        it displays the Info node for the command bound to that key.
+       it displays the Info node for the command bound to that key.
 \\[view-lossage]       Recent input keystrokes and minibuffer messages.
 \\[describe-mode]      Documentation of current major and minor modes.
 \\[view-emacs-news]    News of recent SXEmacs changes.
@@ -972,13 +972,13 @@ When run interactively, it defaults to any function found by
 `function-at-point'."
   (interactive
     (let* ((fn (function-at-point))
-           (val (let ((enable-recursive-minibuffers t))
-                  (completing-read
-                    (if fn
-                        (format (gettext "Describe function (default %s): ")
+          (val (let ((enable-recursive-minibuffers t))
+                 (completing-read
+                   (if fn
+                       (format (gettext "Describe function (default %s): ")
                                fn)
-                        (gettext "Describe function: "))
-                    obarray 'fboundp t nil 'function-history
+                       (gettext "Describe function: "))
+                   obarray 'fboundp t nil 'function-history
                    (symbol-name fn)))))
       (list (intern val))))
   (with-displaying-help-buffer
@@ -1065,15 +1065,15 @@ arguments in the standard Lisp style."
                         ((equal args "") nil)
                         (args))))
                (t t)))
-         (print-gensym nil))
+        (print-gensym nil))
     (cond ((listp arglist)
           (prin1-to-string
            (cons function (loop
-                             for arg in arglist
-                             collect (if (memq arg '(&optional &rest))
-                                         arg
-                                       (make-symbol (upcase (symbol-name
-                                                             arg))))))
+                            for arg in arglist
+                            collect (if (memq arg '(&optional &rest))
+                                        arg
+                                      (make-symbol (upcase (symbol-name
+                                                            arg))))))
            t))
          ((stringp arglist)
           (format "(%s %s)" function arglist)))))
@@ -1088,7 +1088,7 @@ part of the documentation of internal subroutines."
               (void-function "(alias for undefined function)")
               (error "(unexpected error from `documention')"))))
     (when (and strip-arglist
-               (string-match "[\n\t ]*\narguments: ?(\\([^)]*\\))\n?\\'" doc))
+              (string-match "[\n\t ]*\narguments: ?(\\([^)]*\\))\n?\\'" doc))
       (setq doc (substring doc 0 (match-beginning 0)))
       (and (zerop (length doc)) (setq doc (gettext "not documented"))))
     doc))
@@ -1261,29 +1261,29 @@ part of the documentation of internal subroutines."
                                           (an-p "an ")
                                           (t "a "))
                                     "%s"
-                                     (cond
-                                      ((eq 'neither macro-p)
-                                       "")
-                                      (macro-p " macro")
-                                      (t " function"))))
+                                    (cond
+                                     ((eq 'neither macro-p)
+                                      "")
+                                     (macro-p " macro")
+                                     (t " function"))))
                           string)))))
       (cond ((or (stringp def) (vectorp def))
-             (princ "a keyboard macro.")
+            (princ "a keyboard macro.")
             (setq kbd-macro-p t))
-            ((special-form-p fndef)
-             (funcall int "built-in special form" nil 'neither))
-            ((subrp fndef)
-             (funcall int "built-in" nil macrop))
-            ((compiled-function-p fndef)
-             (funcall int "compiled Lisp" nil macrop))
-            ((eq (car-safe fndef) 'lambda)
-             (funcall int "Lisp" nil macrop))
-            ((eq (car-safe def) 'autoload)
+           ((special-form-p fndef)
+            (funcall int "built-in special form" nil 'neither))
+           ((subrp fndef)
+            (funcall int "built-in" nil macrop))
+           ((compiled-function-p fndef)
+            (funcall int "compiled Lisp" nil macrop))
+           ((eq (car-safe fndef) 'lambda)
+            (funcall int "Lisp" nil macrop))
+           ((eq (car-safe def) 'autoload)
             (funcall int "autoloaded Lisp" t (elt def 4)))
            ((and (symbolp def) (not (fboundp def)))
             (princ "a symbol with a void (unbound) function definition."))
-            (t
-             nil)))
+           (t
+            nil)))
     (princ "\n")
     (or file-name
        (setq file-name (symbol-file function 'defun)))
@@ -1293,7 +1293,7 @@ part of the documentation of internal subroutines."
            (princ file-name)
          (let ((opoint (point standard-output))
                e)
-            (require 'hyper-apropos)
+           (require 'hyper-apropos)
            (princ file-name)
            (setq e (make-extent opoint (point standard-output)
                                 standard-output))
@@ -1348,48 +1348,48 @@ part of the documentation of internal subroutines."
                 (princ "\nInvoked with:\n")
                 (let ((global-binding
                        (where-is-internal function global-map))
-                      (global-tty-binding 
+                      (global-tty-binding
                        (where-is-internal function global-tty-map))
-                      (global-window-system-binding 
+                      (global-window-system-binding
                        (where-is-internal function global-window-system-map)))
-                   (if (or global-binding global-tty-binding
-                           global-window-system-binding)
-                       (if (and (equal global-binding
-                                       global-tty-binding)
-                                (equal global-binding
-                                       global-window-system-binding))
-                           (princ
-                            (substitute-command-keys
-                             (format "\n\\[%s]" function)))
-                         (when (and global-window-system-binding
-                                    (not (equal global-window-system-binding
-                                                global-binding)))
-                           (princ 
-                            (format 
-                             "\n%s\n        -- under window systems\n"
-                             (mapconcat #'key-description
-                                        global-window-system-binding
-                                        ", "))))
-                         (when (and global-tty-binding
-                                    (not (equal global-tty-binding
-                                                global-binding)))
-                           (princ 
-                            (format 
-                             "\n%s\n        -- under TTYs\n"
-                             (mapconcat #'key-description
-                                        global-tty-binding
-                                        ", "))))
-                         (when global-binding
-                           (princ 
-                            (format 
-                             "\n%s\n        -- generally (that is, unless\
+                  (if (or global-binding global-tty-binding
+                          global-window-system-binding)
+                      (if (and (equal global-binding
+                                      global-tty-binding)
+                               (equal global-binding
+                                      global-window-system-binding))
+                          (princ
+                           (substitute-command-keys
+                            (format "\n\\[%s]" function)))
+                        (when (and global-window-system-binding
+                                   (not (equal global-window-system-binding
+                                               global-binding)))
+                          (princ
+                           (format
+                            "\n%s\n        -- under window systems\n"
+                            (mapconcat #'key-description
+                                       global-window-system-binding
+                                       ", "))))
+                        (when (and global-tty-binding
+                                   (not (equal global-tty-binding
+                                               global-binding)))
+                          (princ
+                           (format
+                            "\n%s\n        -- under TTYs\n"
+                            (mapconcat #'key-description
+                                       global-tty-binding
+                                       ", "))))
+                        (when global-binding
+                          (princ
+                           (format
+                            "\n%s\n        -- generally (that is, unless\
  overridden by TTY- or
-           window-system-specific mappings)\n"
-                             (mapconcat #'key-description
-                                        global-binding
-                                        ", ")))))
-                     (princ (substitute-command-keys
-                             (format "\n\\[%s]" function))))))))))))
+          window-system-specific mappings)\n"
+                            (mapconcat #'key-description
+                                       global-binding
+                                       ", ")))))
+                    (princ (substitute-command-keys
+                            (format "\n\\[%s]" function))))))))))))
 
 
 
@@ -1479,12 +1479,12 @@ there is no variable around that point, nil is returned."
   "Display the full documentation of VARIABLE (a symbol)."
   (interactive
    (let* ((v (variable-at-point))
-          (val (let ((enable-recursive-minibuffers t))
-                 (completing-read
-                   (if v
-                       (format "Describe variable (default %s): " v)
-                       (gettext "Describe variable: "))
-                   obarray 'boundp t nil 'variable-history
+         (val (let ((enable-recursive-minibuffers t))
+                (completing-read
+                  (if v
+                      (format "Describe variable (default %s): " v)
+                      (gettext "Describe variable: "))
+                  obarray 'boundp t nil 'variable-history
                   (symbol-name v)))))
      (list (intern val))))
   (with-displaying-help-buffer
@@ -1529,7 +1529,7 @@ there is no variable around that point, nil is returned."
                 (set-extent-property e 'find-variable-symbol variable))
               (princ"\"\n")))
         (princ "\nValue: ")
-        (if (not (boundp variable))
+        (if (not (boundp variable))
             (Help-princ-face "void\n" 'hyper-apropos-documentation)
           (Help-prin1-face (symbol-value variable)
                            'hyper-apropos-documentation)
@@ -1606,7 +1606,7 @@ If INSERT (the prefix arg) is non-nil, insert the message in the buffer."
      (setq val (read-command
                (if fn (format "Where is command (default %s): " fn)
                  "Where is command: ")
-                (and fn (symbol-name fn))))
+               (and fn (symbol-name fn))))
      (list (if (equal (symbol-name val) "")
               fn val)
           current-prefix-arg)))
@@ -1720,12 +1720,12 @@ after the listing is made.)"
     (if e
        (find-function (extent-property e 'find-function-symbol))
       (setq e (extent-at pos nil 'find-variable-symbol))
-      (if e 
+      (if e
          (find-variable (extent-property e 'find-variable-symbol))
        (view-scroll-lines-up 1)))))
 
 (defun help-mouse-find-source-or-track (event)
-  "Follow any cross reference to source code under the mouse; 
+  "Follow any cross reference to source code under the mouse;
 if none, call mouse-track.  "
   (interactive "e")
   (mouse-set-point event)
@@ -1733,7 +1733,7 @@ if none, call mouse-track.  "
     (if e
        (find-function (extent-property e 'find-function-symbol))
       (setq e (extent-at (point) nil 'find-variable-symbol))
-      (if e 
+      (if e
          (find-variable (extent-property e 'find-variable-symbol))
        (view-scroll-lines-up 1)))))
 
index c739699..a3ae02b 100644 (file)
@@ -349,7 +349,7 @@ See also `hyper-apropos-mode'."
 
 (defun hyper-apropos-mode (regexp)
   "Improved apropos mode for displaying Emacs documentation.  Function and
-variable names are displayed in the buffer \"*Hyper Apropos*\".  
+variable names are displayed in the buffer \"*Hyper Apropos*\".
 
 Functions are preceded by a single character to indicates their types:
     a = autoloaded, b = byte-compiled, i = internal, l = lambda, m = macro.
@@ -358,20 +358,20 @@ Variables are preceded by an asterisk if they are user variables.
 
 General Commands:
 
-       SPC     - scroll documentation or apropos window forward
-         b     - scroll documentation or apropos window backward
+       SPC     - scroll documentation or apropos window forward
+         b     - scroll documentation or apropos window backward
          k     - eliminate all hits that don't contain keyword
          n     - new search
-         /     - isearch-forward
-         q     - quit and restore previous window configuration
-  
+         /     - isearch-forward
+         q     - quit and restore previous window configuration
+
   Operations for Symbol on Current Line:
-  
-       RET     - toggle display of symbol's documentation
+
+       RET     - toggle display of symbol's documentation
                  (also on button2 in xemacs)
-         w     - show the keybinding if symbol is a command
-         i     - invoke function on current line
-         s     - set value of variable on current line
+         w     - show the keybinding if symbol is a command
+         i     - invoke function on current line
+         s     - set value of variable on current line
          t     - display the C or lisp source (find-tag)"
   (delete-other-windows)
   (setq mode-name "Hyper-Apropos"
@@ -398,9 +398,9 @@ General Commands:
 (defun hyper-describe-key-briefly (key &optional show)
   (interactive "kDescribe key briefly: \nP")
   (let (menup defn interm final msg)
-    (setq defn (key-or-menu-binding key 'menup))    
+    (setq defn (key-or-menu-binding key 'menup))
     (if (or (null defn) (integerp defn))
-        (or (numberp show) (message "%s is undefined" (key-description key)))
+       (or (numberp show) (message "%s is undefined" (key-description key)))
       (cond ((stringp defn)
             (setq interm defn
                   final (key-binding defn)))
@@ -415,7 +415,7 @@ General Commands:
               (setq interm (butlast interm)))
             (if final
                 (setq interm (vconcat interm))
-              (setq interm defn 
+              (setq interm defn
                     final (key-binding defn)))))
       (setq msg (format
                 "%s runs %s%s%s"
@@ -454,7 +454,7 @@ See also `hyper-apropos' and `hyper-describe-function'."
      (or (find-face v)
         (setq v (variable-at-point)))
      (setq val (let ((enable-recursive-minibuffers t))
-                 (completing-read
+                (completing-read
                  (concat (if (hyper-apropos-follow-ref-buffer current-prefix-arg)
                              "Follow face"
                            "Describe face")
@@ -623,7 +623,7 @@ See also `hyper-apropos' and `hyper-describe-function'."
                "see below")
            "is void")))
 
-(defun hyper-apropos-follow-ref-buffer (this-ref-buffer) 
+(defun hyper-apropos-follow-ref-buffer (this-ref-buffer)
   (and (not this-ref-buffer)
        (eq major-mode 'hyper-apropos-help-mode)
        hyper-apropos-ref-buffer
@@ -763,8 +763,8 @@ See also `hyper-apropos' and `hyper-describe-function'."
                                   "()")))
                       ((and (or (eq symtype 'subr) (eq symtype 'autoload))
                             (string-match
-                              "[\n\t ]*\narguments: ?(\\([^)]*\\))\n?\\'"
-                             doc))
+                             "[\n\t ]*\narguments: ?(\\([^)]*\\))\n?\\'"
+                             doc))
                        (insert (substring doc
                                           (match-beginning 1)
                                           (match-end 1)))
@@ -788,7 +788,7 @@ See also `hyper-apropos' and `hyper-describe-function'."
        ;; variable ----------------------------------------------------------
        (and (memq 'variable type)
             (or (boundp symbol) (default-boundp symbol))
-            (progn 
+            (progn
               (setq ok t)
               (setq aliases (hyper-apropos-get-alias symbol
                                                 'variable-alias
@@ -984,7 +984,7 @@ See also `hyper-apropos' and `hyper-describe-function'."
                (setq symtype (cdr symtype)))))))
     (save-excursion
       (set-buffer hyper-apropos-help-buf)
-      (goto-char (point-min)) 
+      (goto-char (point-min))
       ;; pop up window and shrink it if it's wasting space
       (if hyper-apropos-shrink-window
          (shrink-window-if-larger-than-buffer
index 75eb8b8..cf8620e 100644 (file)
@@ -303,7 +303,7 @@ Called from a program, takes three args: START, END and COLUMN."
            (let ((regexp (regexp-quote fill-prefix)))
            (while (< (point) end)
              (or (looking-at regexp)
-                  (and (bolp) (eolp))
+                 (and (bolp) (eolp))
                  (insert fill-prefix))
              (forward-line 1))))
        (if indent-region-function
@@ -314,8 +314,8 @@ Called from a program, takes three args: START, END and COLUMN."
          (goto-char start)
          (or (bolp) (forward-line 1))
          (while (< (point) end)
-            (or (and (bolp) (eolp))
-                (funcall indent-line-function))
+           (or (and (bolp) (eolp))
+               (funcall indent-line-function))
            (forward-line 1))
          (move-marker end nil))))
     (setq column (prefix-numeric-value column))
index 4e02b08..e15974e 100644 (file)
@@ -1147,9 +1147,9 @@ and `END-INFO-DIR-ENTRY'."
        (goto-char start)
        (while (re-search-forward
                (concat #r"^\* \([^:]+\):\("
-                        "[ \t]*"
-                        #r"(\([^)]*\))\w*\.\|:\)")
-                nil t)
+                       "[ \t]*"
+                       #r"(\([^)]*\))\w*\.\|:\)")
+               nil t)
          (setq entry (list (match-string 2)
                            (match-string 1)
                            (downcase (or (match-string 3)
@@ -1603,8 +1603,8 @@ annotation for any node of any file.  (See `a' and `x' commands.)"
                     nil t))
   (let (filename)
     (string-match (concat #r"\s *\((\s *\("
-                          "[^\t)]*"
-                          #r"\)\s *)\s *\|\)\(.*\)")
+                         "[^\t)]*"
+                         #r"\)\s *)\s *\|\)\(.*\)")
                  nodename)
     (setq filename (if (= (match-beginning 1) (match-end 1))
                       ""
@@ -1746,23 +1746,23 @@ annotation for any node of any file.  (See `a' and `x' commands.)"
   (setq Info-last-search regexp)
   (with-search-caps-disable-folding regexp t
     (let ((found ())
-          (onode Info-current-node)
-          (ofile Info-current-file)
-          (opoint (point))
-          (osubfile Info-current-subfile))
+         (onode Info-current-node)
+         (ofile Info-current-file)
+         (opoint (point))
+         (osubfile Info-current-subfile))
       (save-excursion
-        (save-restriction
-          (widen)
-          (if (null Info-current-subfile)
-              (progn (re-search-forward regexp) (setq found (point)))
-            (condition-case nil
-                (progn (re-search-forward regexp) (setq found (point)))
-              (search-failed nil)))))
+       (save-restriction
+         (widen)
+         (if (null Info-current-subfile)
+             (progn (re-search-forward regexp) (setq found (point)))
+           (condition-case nil
+               (progn (re-search-forward regexp) (setq found (point)))
+             (search-failed nil)))))
       (if (not found)
          ;; can only happen in subfile case -- else would have erred
-          (unwind-protect
-              (let ((list ()))
-                (save-excursion
+         (unwind-protect
+             (let ((list ()))
+               (save-excursion
                  (set-buffer (marker-buffer Info-tag-table-marker))
                  (goto-char (point-min))
                  (search-forward "\n\^_\nIndirect:")
@@ -1784,26 +1784,26 @@ annotation for any node of any file.  (See `a' and `x' commands.)"
                      (goto-char (1+ (match-end 0))))
                    (setq list (nreverse list)
                          list (cdr list))))
-                (while list
-                  (message "Searching subfile %s..." (cdr (car list)))
-                  (Info-read-subfile (car (car list)))
-                  (setq list (cdr list))
-                  (goto-char (point-min))
-                  (if (re-search-forward regexp nil t)
-                      (setq found (point) list ())))
-                (if found
-                    (message "")
-                  (signal 'search-failed (list regexp))))
-            (if (not found)
-                (progn (Info-read-subfile opoint)
-                       (goto-char opoint)
-                       (Info-select-node)))))
+               (while list
+                 (message "Searching subfile %s..." (cdr (car list)))
+                 (Info-read-subfile (car (car list)))
+                 (setq list (cdr list))
+                 (goto-char (point-min))
+                 (if (re-search-forward regexp nil t)
+                     (setq found (point) list ())))
+               (if found
+                   (message "")
+                 (signal 'search-failed (list regexp))))
+           (if (not found)
+               (progn (Info-read-subfile opoint)
+                      (goto-char opoint)
+                      (Info-select-node)))))
       (widen)
       (goto-char found)
       (Info-select-node)
       (or (and (equal onode Info-current-node)
-               (equal ofile Info-current-file))
-          (Info-history-add ofile onode opoint)))))
+              (equal ofile Info-current-file))
+         (Info-history-add ofile onode opoint)))))
 \f
 ;; Extract the value of the node-pointer named NAME.
 ;; If there is none, use ERRORNAME in the error message;
@@ -1957,7 +1957,7 @@ NAME may be an abbreviation of the reference name."
 (defun Info-next-reference (n)
   (interactive "p")
   (let ((pat (format (concat "\\*%s[ \n\t]*"
-                             #r"\([^:]*\):\|^\* .*:\|<<.*>>")
+                            #r"\([^:]*\):\|^\* .*:\|<<.*>>")
                     Info-footnote-tag))
        (old-pt (point))
        wrapped found-nomenu)
@@ -2077,8 +2077,8 @@ Completion is allowed, and the menu item point is on is the default."
         (if (string= item "")
             (if default
                 (setq item default)
-                ;; ask again
-                (setq item nil))))
+                ;; ask again
+                (setq item nil))))
        (list item))))
   ;; there is a problem here in that if several menu items have the same
   ;; name you can only go to the node of the first with this command.
@@ -2440,7 +2440,7 @@ This command is designed to be used whether you are already in Info or not."
                                        (format " (default %s)" fn)
                                      ""))
                            obarray 'fboundp t
-                            nil nil (and fn (symbol-name fn))))
+                           nil nil (and fn (symbol-name fn))))
                 (list (if (equal val "")
                           fn (intern val)))))
   (save-window-excursion
index b90140c..f52c33c 100644 (file)
@@ -539,12 +539,12 @@ is treated as a regexp.  See \\[isearch-forward] for more info."
          ;; #### What we really need is a buffer-local
          ;; overriding-local-map.  See isearch-pre-command-hook for
          ;; more details.
-         overriding-local-map (progn
-                                (set-keymap-parents isearch-mode-map
-                                 (nconc (current-minor-mode-maps)
+         overriding-local-map (progn
+                                (set-keymap-parents isearch-mode-map
+                                 (nconc (current-minor-mode-maps)
                                         (and (current-local-map)
                                              (list (current-local-map)))))
-                                isearch-mode-map)
+                                isearch-mode-map)
          isearch-selected-frame (selected-frame)
 
          )
@@ -771,7 +771,7 @@ If first char entered is \\[isearch-yank-word], then do word search instead."
          ;; like switch buffers and start another isearch, and return.
 ;;     (condition-case nil
          (isearch-done t t)
-          ;;#### What does this mean?  There is no such condition!
+         ;;#### What does this mean?  There is no such condition!
 ;;     (exit nil))                     ; was recursive editing
 
          (unwind-protect
@@ -968,9 +968,9 @@ Deletes when `delete-key-deletes-forward' is t and C-h is used for deleting
 backwards."
   (interactive)
   (if (and delete-key-deletes-forward
-           (case (device-type)
-             ('tty (eq tty-erase-char ?\C-h))
-             ('x (not (x-keysym-on-keyboard-sans-modifiers-p 'backspace)))))
+          (case (device-type)
+            ('tty (eq tty-erase-char ?\C-h))
+            ('x (not (x-keysym-on-keyboard-sans-modifiers-p 'backspace)))))
       (isearch-delete-char)
     (isearch-mode-help)))
 
@@ -1047,8 +1047,8 @@ backwards."
       (setq isearch-case-fold-search
            (no-upper-case-p isearch-string isearch-regexp)))
   (setq isearch-mode (if case-fold-search
-                         (if isearch-case-fold-search
-                             " Isearch"  ;As God Intended Mode
+                        (if isearch-case-fold-search
+                            " Isearch"  ;As God Intended Mode
                           " ISeARch") ;Warn about evil case via StuDLYcAps.
                       " Isearch")))
 
@@ -1291,9 +1291,9 @@ Obsolete."
   ;; Helper for isearch-complete and isearch-complete-edit
   ;; Return t if completion OK, nil if no completion exists.
   (let* ((ring (if isearch-regexp regexp-search-ring search-ring))
-         (alist (mapcar (function (lambda (string) (list string))) ring))
-         (completion-ignore-case case-fold-search)
-         (completion (try-completion isearch-string alist)))
+        (alist (mapcar (function (lambda (string) (list string))) ring))
+        (completion-ignore-case case-fold-search)
+        (completion (try-completion isearch-string alist)))
     (cond
      ((eq completion t)
       ;; isearch-string stays the same
@@ -1435,12 +1435,12 @@ If there is no completion possible, say so and continue searching."
                              (< (point) isearch-opoint)))
                       "overwrapped "
                     (if isearch-wrapped "wrapped "))
-                  (if isearch-word "word ")
-                  (if isearch-regexp "regexp ")
-                  (if nonincremental "search" "I-search")
-                  (if isearch-forward nil " backward")
+                  (if isearch-word "word ")
+                  (if isearch-regexp "regexp ")
+                  (if nonincremental "search" "I-search")
+                  (if isearch-forward nil " backward")
                   ": "
-                  )))
+                  )))
     (aset m 0 (upcase (aref m 0)))
     (gettext m)))
 
@@ -1809,9 +1809,9 @@ have special meaning in a regexp."
   "Eval BODY with `case-fold-search' let to nil if STRING contains
 uppercase letters and `search-caps-disable-folding' is t."
   `(let ((case-fold-search
-          (if (and case-fold-search search-caps-disable-folding)
-              (isearch-no-upper-case-p ,string)
-            case-fold-search)))
+         (if (and case-fold-search search-caps-disable-folding)
+             (isearch-no-upper-case-p ,string)
+           case-fold-search)))
      ,@body))
 (make-obsolete 'with-caps-disable-folding 'with-search-caps-disable-folding)
 (put 'with-caps-disable-folding 'lisp-indent-function 1)
index e9f053a..3abee4d 100644 (file)
@@ -68,7 +68,7 @@
   (modify-syntax-entry ?\276 "_"     table)   ; threequarters
   (modify-syntax-entry ?\277 "_"     table)   ; questiondown
   ;;
-  ;; the upper-case characters (plus "multiply" and "ssharp") 
+  ;; the upper-case characters (plus "multiply" and "ssharp")
   ;;
   (modify-syntax-entry ?\300 "w" table)   ; Agrave
   (modify-syntax-entry ?\301 "w" table)   ; Aacute
                    (list
                     (list 'quote
                           (list downcase nil nil nil))))))))
+
  (?\300  ?\340)                ; Agrave
  (?\301  ?\341)                ; Aacute
  (?\302  ?\342)                ; Acircumflex
index 5ea36ca..be60010 100644 (file)
@@ -38,7 +38,7 @@
 ;; IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
 
 ;;; Commentary:
-;; 
+;;
 ;;    This will hopefully turn into an interface to the SXEmacs issue
 ;;    tracker.  For now, it is basically a clone of xemacsbug with a
 ;;    couple of things changed to suit SXEmacs conditions.
@@ -75,8 +75,8 @@
 It takes the format (HEADER . VALUE) where both HEADER and VALUE are
 strings. See `compose-mail'."
   :group 'sxemacsbug
-  :type '(repeat 
-         (cons (string :tag "Header") 
+  :type '(repeat
+         (cons (string :tag "Header")
                (string :tag "Value"))))
 
 (defcustom report-sxemacs-bug-beta-address "SXEmacs Devel <sxemacs-devel@sxemacs.org>"
@@ -90,8 +90,8 @@ strings. See `compose-mail'."
 It takes the format (HEADER . VALUE) where both HEADER and VALUE are
 strings. See `compose-mail'."
   :group 'sxemacsbug
-  :type '(repeat 
-         (cons (string :tag "Header") 
+  :type '(repeat
+         (cons (string :tag "Header")
                (string :tag "Value"))))
 
 (defvar report-sxemacs-bug-orig-text nil
@@ -128,7 +128,7 @@ Also include a reliable recipe for triggering the bug, as well as
 any C and lisp back-traces that you may have.
 \(setq stack-trace-on-error t\), or \(setq debug-on-error t\) if you
 are familiar with the debugger, to get a lisp back-trace.
-To get a core file for the C back-trace on a GNU/Linux system do 
+To get a core file for the C back-trace on a GNU/Linux system do
 'ulimit -c unlimited' in the shell prior to starting SXEmacs.
 
 Type \\[report-sxemacs-bug-info] to visit in Info the SXEmacs Manual section
@@ -149,7 +149,7 @@ To your ~/.sxemacs/init.el")
   "Display the help buffer for `report-sxemacs-bug'."
   (declare-fboundp
    (with-electric-help
-    #'(lambda () 
+    #'(lambda ()
        (define-key (current-local-map) "\C-c\C-i" 'report-sxemacs-bug-info)
        (princ (substitute-command-keys report-sxemacs-bug-help)) nil) "*Bug Help*")))
 
@@ -363,7 +363,7 @@ and send the mail again.") nil) "*Bug Help*")))
 This is a convenience for reporting SXEmacs issues at
 http://issues.sxemacs.org/.  Returns t if any backtrace buffers are
 found and saved, nil otherwise."
-  (let ((ctrace (or (get-buffer (concat "*gdb-sxemacs-" 
+  (let ((ctrace (or (get-buffer (concat "*gdb-sxemacs-"
                                        emacs-program-version
                                        "*"))
                    (get-buffer "*gdb-sxemacs*")))
@@ -398,7 +398,7 @@ http://issues.sxemacs.org/.  Returns t on success, nil otherwise."
            (write-region (point-min) (point-max) file))
          t)
       nil)))
-         
+
 (defconst report-sxemacs-bugzilla-notrace
   "Thank you very much for taking the time to report a problem with SXEmacs
 ========================================================================
@@ -478,7 +478,7 @@ Devel <sxemacs-devel@sxemacs.org> mailing list.
       (insert report-sxemacs-bugzilla-notrace)
       (toggle-read-only 1)
       (pop-to-buffer (get-buffer "Reporting Bugs"))
-      (view-minor-mode 
+      (view-minor-mode
        nil #'(lambda (&rest not-used-buffer)
               (kill-buffer (get-buffer "Reporting Bugs"))
               (jump-to-register ?S)
index fdf8468..52aa517 100644 (file)
@@ -46,7 +46,7 @@ on the number of characters typed.")
 
 ;jwz: this is preloaded so don't ;;;###autoload
 (defvar auto-gc-threshold (/ gc-cons-threshold 3)
-  "*GC when this many bytes have been consed since the last GC, 
+  "*GC when this many bytes have been consed since the last GC,
 and the user has been idle for `auto-save-timeout' seconds.")
 
 (defun auto-save-itimer ()
index 4a9c3f9..40a329c 100644 (file)
@@ -97,7 +97,7 @@ The normal global definition of the character C-x indirects to this keymap.")
 (let ((n 33))
   (while (<= n 255)
     (if (not (= n 127))
-        (define-key global-map n 'self-insert-command))
+       (define-key global-map n 'self-insert-command))
     (setq n (1+ n))))
 (define-key global-map " " 'self-insert-command)
 
@@ -191,8 +191,8 @@ The normal global definition of the character C-x indirects to this keymap.")
 
 ;; New FSF19 bindings: C-x n as a prefix for narrowing commands.
 (define-key global-map "\C-xn" (let ((map (make-sparse-keymap)))
-                                 (set-keymap-name map 'narrowing-prefix)
-                                 map))
+                                (set-keymap-name map 'narrowing-prefix)
+                                map))
 (put 'narrow-to-region 'disabled t)
 (define-key global-map "\C-xnn" 'narrow-to-region)
 (define-key global-map "\C-xnw" 'widen)
@@ -328,8 +328,8 @@ The normal global definition of the character C-x indirects to this keymap.")
 
 ;; New FSF19 bindings: C-x r as a prefix for register commands
 (define-key global-map "\C-xr" (let ((map (make-sparse-keymap)))
-                                 (set-keymap-name map 'rectangle-prefix)
-                                 map))
+                                (set-keymap-name map 'rectangle-prefix)
+                                map))
 (define-key global-map "\C-xr\C-@" 'point-to-register)
 (define-key global-map "\C-xr " 'point-to-register)
 (define-key global-map "\C-xrj" 'jump-to-register)
@@ -519,7 +519,7 @@ The normal global definition of the character C-x indirects to this keymap.")
 ;; expected behavior even in, for example, vi-mode.
 
 ;; We use here symbolic names, assuming that the corresponding keys will
-;; generate these keysyms.  This is not true on Suns, but x-win-sun.el 
+;; generate these keysyms.  This is not true on Suns, but x-win-sun.el
 ;; fixes that.  If it turns out that the semantics of these keys should
 ;; differ from server to server, this should be moved into server-specific
 ;; files, but these appear to be the standard Motif and PC bindings.
@@ -612,7 +612,7 @@ The normal global definition of the character C-x indirects to this keymap.")
 (define-key global-map 'delete         'backward-or-forward-delete-char)
 (define-key global-map '(meta delete)  'backward-or-forward-kill-word)
 (define-key global-map [(control x) (delete)]
-                                       'backward-or-forward-kill-sentence)
+                                       'backward-or-forward-kill-sentence)
 (define-key global-map 'kp-delete      'backward-or-forward-delete-char)
 (define-key global-map '(meta kp-delete) 'backward-or-forward-kill-word)
 (define-key global-map [(control x) (kp-delete)]
index a4fbeb2..7370b06 100644 (file)
@@ -115,7 +115,7 @@ KEYMAP are redefined.  See also `accessible-keymaps'."
     (if (or (null defn) (integerp defn))
        (error "%s is undefined" (key-description key))
       (if (or (stringp defn) (vectorp defn))
-          (setq defn (key-binding defn))) ;; a keyboard macro
+         (setq defn (key-binding defn))) ;; a keyboard macro
       (insert (format "%s" defn)))))
 
 (defun read-command-or-command-sexp (prompt)
@@ -126,10 +126,10 @@ Prompts with PROMPT."
   ;; commandp (as does 'read-command') but that is not easy to do
   ;; because we must supply arg4 = require-match = nil for sexp case.
   (let ((result (car (read-from-string
-                      (completing-read prompt obarray 'commandp)))))
+                     (completing-read prompt obarray 'commandp)))))
     (if (and (consp result)
-             (not (eq (car result) 'lambda)))
-        `(lambda ()
+            (not (eq (car result) 'lambda)))
+       `(lambda ()
           (interactive)
           ,result)
       result)))
@@ -142,8 +142,8 @@ The binding is probably a symbol with a function definition; see
 the documentation for `lookup-key' for more information."
   (let ((map (current-local-map)))
     (if map
-        (lookup-key map keys accept-defaults)
-        nil)))
+       (lookup-key map keys accept-defaults)
+       nil)))
 
 (defun global-key-binding (keys &optional accept-defaults)
   "Return the binding for command KEYS in current global keymap only.
@@ -161,11 +161,11 @@ Note that if KEY has a local binding in the current buffer
 that local binding will continue to shadow any global binding."
   ;;(interactive "KSet key globally: \nCSet key %s to command: ")
   (interactive (list (setq key (read-key-sequence "Set key globally: "))
-                     ;; Command sexps are allowed here so that this arg
-                     ;; may be supplied interactively via insert-key-binding.
-                     (read-command-or-command-sexp
-                       (format "Set key %s to command: "
-                               (key-description key)))))
+                    ;; Command sexps are allowed here so that this arg
+                    ;; may be supplied interactively via insert-key-binding.
+                    (read-command-or-command-sexp
+                      (format "Set key %s to command: "
+                              (key-description key)))))
   (define-key (current-global-map) key command)
   nil)
 
@@ -178,11 +178,11 @@ The binding goes in the current buffer's local map,
 which is shared with other buffers in the same major mode."
   ;;(interactive "KSet key locally: \nCSet key %s locally to command: ")
   (interactive (list (setq key (read-key-sequence "Set key locally: "))
-                     ;; Command sexps are allowed here so that this arg
-                     ;; may be supplied interactively via insert-key-binding.
-                     (read-command-or-command-sexp
-                       (format "Set key %s locally to command: "
-                               (key-description key)))))
+                    ;; Command sexps are allowed here so that this arg
+                    ;; may be supplied interactively via insert-key-binding.
+                    (read-command-or-command-sexp
+                      (format "Set key %s locally to command: "
+                              (key-description key)))))
   (if (null (current-local-map))
       (use-local-map (make-sparse-keymap)))
   (define-key (current-local-map) key command)
@@ -218,37 +218,37 @@ that come after prefix bindings.
 If optional argument ACCEPT-DEFAULT is non-nil, recognize default
 bindings; see the description of `lookup-key' for more details about this."
   (let ((tail minor-mode-map-alist)
-        a s v)
+       a s v)
     (while tail
       (setq a (car tail)
-            tail (cdr tail))
+           tail (cdr tail))
       (and (consp a)
-           (symbolp (setq s (car a)))
-           (boundp s)
-           (symbol-value s)
-           ;; indirect-function deals with autoloadable keymaps
-           (setq v (indirect-function (cdr a)))
-           (setq v (lookup-key v key accept-default))
-           ;; Terminate loop, with v set to non-nil value
-           (setq tail nil)))
+          (symbolp (setq s (car a)))
+          (boundp s)
+          (symbol-value s)
+          ;; indirect-function deals with autoloadable keymaps
+          (setq v (indirect-function (cdr a)))
+          (setq v (lookup-key v key accept-default))
+          ;; Terminate loop, with v set to non-nil value
+          (setq tail nil)))
     v))
 
 
 (defun current-minor-mode-maps ()
   "Return a list of keymaps for the minor modes of the current buffer."
   (let ((l '())
-        (tail minor-mode-map-alist)
-        a s v)
+       (tail minor-mode-map-alist)
+       a s v)
     (while tail
       (setq a (car tail)
-            tail (cdr tail))
+           tail (cdr tail))
       (and (consp a)
-           (symbolp (setq s (car a)))
-           (boundp s)
-           (symbol-value s)
-           ;; indirect-function deals with autoloadable keymaps
-           (setq v (indirect-function (cdr a)))
-           (setq l (cons v l))))
+          (symbolp (setq s (car a)))
+          (boundp s)
+          (symbol-value s)
+          ;; indirect-function deals with autoloadable keymaps
+          (setq v (indirect-function (cdr a)))
+          (setq l (cons v l))))
     (nreverse l)))
 
 \f
@@ -264,11 +264,11 @@ Regardless of MAPVAR, COMMAND's function-value is always set to the keymap."
   (let ((map (make-sparse-keymap name)))
     (fset name map)
     (cond ((not mapvar)
-           (set name map))
-          ((eq mapvar 't)
-           )
-          (t
-           (set mapvar map)))
+          (set name map))
+         ((eq mapvar 't)
+          )
+         (t
+          (set mapvar map)))
     name))
 
 \f
@@ -286,84 +286,84 @@ or a string (if they all fit in the ASCII range).
 Optional arg NO-MICE means that button events are not allowed."
  (if (and events (symbolp events)) (setq events (vector events)))
  (cond ((stringp events)
-        events)
+       events)
        ((not (vectorp events))
-        (signal 'wrong-type-argument (list 'vectorp events)))
+       (signal 'wrong-type-argument (list 'vectorp events)))
        ((let* ((length (length events))
-               (string (make-string length 0))
-               c ce
-               (i 0))
-          (while (< i length)
-            (setq ce (aref events i))
-            (or (eventp ce) (setq ce (character-to-event ce)))
-            ;; Normalize `c' to `?c' and `(control k)' to `?\C-k'
-            ;; By passing t for the `allow-meta' arg we could get kbd macros
-            ;; with meta in them to translate to the string form instead of
-            ;; the list/symbol form; but I expect that would cause confusion,
-            ;; so let's use the list/symbol form whenever there's
-            ;; any ambiguity.
-            (setq c (event-to-character ce))
-            (if (and c
-                     character-set-property
-                     (key-press-event-p ce))
-                (cond ((symbolp (event-key ce))
-                       (if (get (event-key ce) character-set-property)
-                           ;; Don't use a string for `backspace' and `tab' to
-                           ;;  avoid that unpleasant little ambiguity.
-                           (setq c nil)))
-                      ((and (= (event-modifier-bits ce) 1) ;control
-                            (integerp (event-key ce)))
-                       (let* ((te (character-to-event c)))
-                         (if (and (symbolp (event-key te))
-                                  (get (event-key te) character-set-property))
-                             ;; Don't "normalize" (control i) to tab
-                             ;;  to avoid the ambiguity in the other direction
-                             (setq c nil))
-                         (deallocate-event te)))))
-            (if c
-                (aset string i c)
-                (setq i length string nil))
-            (setq i (1+ i)))
-          string))
+              (string (make-string length 0))
+              c ce
+              (i 0))
+         (while (< i length)
+           (setq ce (aref events i))
+           (or (eventp ce) (setq ce (character-to-event ce)))
+           ;; Normalize `c' to `?c' and `(control k)' to `?\C-k'
+           ;; By passing t for the `allow-meta' arg we could get kbd macros
+           ;; with meta in them to translate to the string form instead of
+           ;; the list/symbol form; but I expect that would cause confusion,
+           ;; so let's use the list/symbol form whenever there's
+           ;; any ambiguity.
+           (setq c (event-to-character ce))
+           (if (and c
+                    character-set-property
+                    (key-press-event-p ce))
+               (cond ((symbolp (event-key ce))
+                      (if (get (event-key ce) character-set-property)
+                          ;; Don't use a string for `backspace' and `tab' to
+                          ;;  avoid that unpleasant little ambiguity.
+                          (setq c nil)))
+                     ((and (= (event-modifier-bits ce) 1) ;control
+                           (integerp (event-key ce)))
+                      (let* ((te (character-to-event c)))
+                        (if (and (symbolp (event-key te))
+                                 (get (event-key te) character-set-property))
+                            ;; Don't "normalize" (control i) to tab
+                            ;;  to avoid the ambiguity in the other direction
+                            (setq c nil))
+                        (deallocate-event te)))))
+           (if c
+               (aset string i c)
+               (setq i length string nil))
+           (setq i (1+ i)))
+         string))
        (t
-        (let* ((length (length events))
-               (new (copy-sequence events))
-               event mods key
-               (i 0))
-          (while (< i length)
-            (setq event (aref events i))
-            (cond ((key-press-event-p event)
-                   (setq mods (event-modifiers event)
-                         key (event-key event))
-                   (if (numberp key)
-                       (setq key (intern (make-string 1 key))))
-                   (aset new i (if mods
-                                   (nconc mods (cons key nil))
-                                   key)))
-                  ((misc-user-event-p event)
-                   (aset new i (list 'menu-selection
-                                     (event-function event)
-                                     (event-object event))))
-                  ((or (button-press-event-p event)
-                       (button-release-event-p event))
-                   (if no-mice
-                       (error
-                         "Mouse events can't be saved in keyboard macros."))
-                   (setq mods (event-modifiers event)
-                         key (intern (format "button%d%s"
-                                             (event-button event)
-                                             (if (button-release-event-p event)
-                                                 "up" ""))))
-                   (aset new i (if mods
-                                   (nconc mods (cons key nil))
-                                   key)))
-                  ((or (and event (symbolp event))
-                       (and (consp event) (symbolp (car event))))
-                   (aset new i event))
-                  (t
-                   (signal 'wrong-type-argument (list 'eventp event))))
-            (setq i (1+ i)))
-          new))))
+       (let* ((length (length events))
+              (new (copy-sequence events))
+              event mods key
+              (i 0))
+         (while (< i length)
+           (setq event (aref events i))
+           (cond ((key-press-event-p event)
+                  (setq mods (event-modifiers event)
+                        key (event-key event))
+                  (if (numberp key)
+                      (setq key (intern (make-string 1 key))))
+                  (aset new i (if mods
+                                  (nconc mods (cons key nil))
+                                  key)))
+                 ((misc-user-event-p event)
+                  (aset new i (list 'menu-selection
+                                    (event-function event)
+                                    (event-object event))))
+                 ((or (button-press-event-p event)
+                      (button-release-event-p event))
+                  (if no-mice
+                      (error
+                        "Mouse events can't be saved in keyboard macros."))
+                  (setq mods (event-modifiers event)
+                        key (intern (format "button%d%s"
+                                            (event-button event)
+                                            (if (button-release-event-p event)
+                                                "up" ""))))
+                  (aset new i (if mods
+                                  (nconc mods (cons key nil))
+                                  key)))
+                 ((or (and event (symbolp event))
+                      (and (consp event) (symbolp (car event))))
+                  (aset new i event))
+                 (t
+                  (signal 'wrong-type-argument (list 'eventp event))))
+           (setq i (1+ i)))
+         new))))
 
 \f
 (defun next-key-event ()
index 6ff1679..61529ef 100644 (file)
@@ -62,7 +62,7 @@
 
 (defun library-all-completions (FILE SEARCH-PATH &optional FULL FAST)
   "Return all completions for FILE in any directory on SEARCH-PATH.
-If optional third argument FULL is non-nil, returned pathnames should be 
+If optional third argument FULL is non-nil, returned pathnames should be
   absolute rather than relative to some directory on the SEARCH-PATH.
 If optional fourth argument FAST is non-nil, don't sort the completions,
   or remove duplicates."
@@ -71,26 +71,26 @@ If optional fourth argument FAST is non-nil, don't sort the completions,
       ;; It's an absolute file name, so don't need SEARCH-PATH
       (progn
        (setq FILE (expand-file-name FILE))
-       (file-name-all-completions 
+       (file-name-all-completions
         (file-name-nondirectory FILE) (file-name-directory FILE)))
     (let ((subdir (file-name-directory FILE))
          (file (file-name-nondirectory FILE))
          all-completions)
       ;; Make list of completions in each directory on SEARCH-PATH
       (while SEARCH-PATH
-       (let* ((dir (concat (file-name-as-directory 
+       (let* ((dir (concat (file-name-as-directory
                             (expand-file-name (car SEARCH-PATH)))
                            subdir))
               (dir-prefix (if FULL dir subdir)))
          (if (file-directory-p dir)
-             (let ((subdir-completions 
+             (let ((subdir-completions
                     (file-name-all-completions file dir)))
                (while subdir-completions
-                 (setq all-completions 
+                 (setq all-completions
                        (cons (concat dir-prefix (car subdir-completions))
                              all-completions))
                  (setq subdir-completions (cdr subdir-completions))))))
-       (setq SEARCH-PATH (cdr SEARCH-PATH)))   
+       (setq SEARCH-PATH (cdr SEARCH-PATH)))
       (if FAST all-completions
        (let ((sorted (nreverse (sort all-completions 'string<)))
              compressed)
@@ -126,7 +126,7 @@ Display MESSAGE and evaluate FORMS, returning value of the last one."
 ;;=== Completion caching ==================================================
 
 (defconst lib-complete:cache nil
-  "Used within `read-library' and `read-library-internal' to prevent 
+  "Used within `read-library' and `read-library-internal' to prevent
 costly repeated calls to `library-all-completions'.
 Format is a list of lists of the form
 
@@ -146,50 +146,50 @@ where each <cache-record> has the form
 (defun lib-complete:get-completion-table (FILE PATH FILTER)
   (let* ((subdir (file-name-directory FILE))
         (root (file-name-nondirectory FILE))
-        (PATH 
-         (mapcar 
+        (PATH
+         (mapcar
           (function (lambda (dir) (file-name-as-directory
                                    (expand-file-name (or dir "")))))
           PATH))
         (key (vector PATH subdir FILTER))
-        (real-dirs 
+        (real-dirs
          (if subdir
              (mapcar (function (lambda (dir) (concat dir subdir))) PATH)
            PATH))
         (path-modtimes
-         (mapcar 
-          (function (lambda (fn) (if fn (nth 5 (file-attributes fn))))) 
+         (mapcar
+          (function (lambda (fn) (if fn (nth 5 (file-attributes fn)))))
           real-dirs))
         (cache-entry (assoc key lib-complete:cache))
         (cache-records (cdr cache-entry)))
     ;; Look for cached entry
     (catch 'table
       (while cache-records
-       (if (and 
+       (if (and
             (lib-complete:better-root (nth 0 (car cache-records)) root)
             (equal (nth 1 (car cache-records)) path-modtimes))
            (throw 'table (nth 2 (car cache-records))))
        (setq cache-records (cdr cache-records)))
       ;; Otherwise build completions
-      (let ((completion-list 
+      (let ((completion-list
             (progn-with-message "(building completion table...)"
               (library-all-completions FILE PATH nil 'fast)))
            (completion-table (make-vector 127 0)))
        (while completion-list
          (let ((completion
-                (if (or (not FILTER) 
-                        (file-directory-p (car completion-list))) 
+                (if (or (not FILTER)
+                        (file-directory-p (car completion-list)))
                     (car completion-list)
                   (funcall FILTER (car completion-list)))))
            (if completion
                (intern completion completion-table)))
          (setq completion-list (cdr completion-list)))
        ;; Cache the completions
-       (lib-complete:cache-completions key root 
+       (lib-complete:cache-completions key root
                                        path-modtimes completion-table)
        completion-table))))
 
-(defvar lib-complete:max-cache-size 40 
+(defvar lib-complete:max-cache-size 40
   "*Maximum number of search paths which are cached.")
 
 (defun lib-complete:cache-completions (key root modtimes table)
@@ -204,7 +204,7 @@ where each <cache-record> has the form
        (if (or (equal root (nth 0 (car cache-records)))
                (lib-complete:better-root root (nth 0 (car cache-records))))
            nil
-         (setq new-cache-records 
+         (setq new-cache-records
                (cons (car cache-records) new-cache-records)))
        (setq cache-records (cdr cache-records))))
     ;; Add entry to front of cache
@@ -232,7 +232,7 @@ where each <cache-record> has the form
      ((eq FLAG 'lambda) (and (intern-soft FILE completion-table) t))
      )))
 
-(defun read-library (PROMPT SEARCH-PATH &optional DEFAULT MUST-MATCH 
+(defun read-library (PROMPT SEARCH-PATH &optional DEFAULT MUST-MATCH
                            FULL FILTER)
   "Read library name, prompting with PROMPT and completing in directories
 from SEARCH-PATH.  A nil in the search path represents the current
@@ -241,16 +241,16 @@ cache being invalidated whenever one of the directories on the path changes.
 Default to DEFAULT if user enters a null string.
 Optional fourth arg MUST-MATCH non-nil means require existing file's name.
   Non-nil and non-t means also require confirmation after completion.
-Optional fifth argument FULL non-nil causes a full pathname, rather than a 
+Optional fifth argument FULL non-nil causes a full pathname, rather than a
   relative pathname, to be returned.  Note that FULL implies MUST-MATCH.
 Optional sixth argument FILTER can be used to provide a function to
   filter the completions.  This function is passed the filename, and should
-  return a transformed filename (possibly a null transformation) or nil, 
+  return a transformed filename (possibly a null transformation) or nil,
   indicating that the filename should not be included in the completions."
   (let* ((read-library-internal-search-path SEARCH-PATH)
-        (library (completing-read PROMPT 'read-library-internal 
+        (library (completing-read PROMPT 'read-library-internal
                                   FILTER (or MUST-MATCH FULL) nil)))
-    (cond 
+    (cond
      ((equal library "") DEFAULT)
      (FULL (locate-file library read-library-internal-search-path
                         '(".el" ".el.gz" ".elc")))
@@ -262,8 +262,8 @@ Optional sixth argument FILTER can be used to provide a function to
   (declare (special read-library-internal-search-path))
   (let ((read-library-internal-search-path load-path))
     (completing-read prompt
-                    'read-library-internal 
-                    (lambda (fn) 
+                    'read-library-internal
+                    (lambda (fn)
                       (cond
                        ((string-match #r"\.el\(\.gz\|\.Z\)?$" fn)
                         (substring fn 0 (match-beginning 0)))))
@@ -280,13 +280,13 @@ Optional sixth argument FILTER can be used to provide a function to
 (defun load-library (library)
   "Load the library named LIBRARY.
 This is an interface to the function `load'."
-  (interactive 
+  (interactive
    (list (read-library "Load library: " load-path nil nil nil
-                      (function (lambda (fn) 
-                                  (cond 
+                      (function (lambda (fn)
+                                  (cond
                                    ((string-match "\\.elc?$" fn)
                                     (substring fn 0 (match-beginning 0))))))
-                      ))) 
+                      )))
   (load library))
 
 ;;=== find-library with completion (Author: Bob Weiner) ===================
@@ -299,14 +299,14 @@ specifies the coding system to use when decoding the file.  Interactively,
 with a prefix argument, this prompts for the coding system.  Optional third
 argument DISPLAY-FUNCTION must take two arguments, the filename to display
 and CODESYS.  The default for DISPLAY-FUNCTION is `find-file'."
-  (interactive 
+  (interactive
    (list (read-library-name "Find library: ")
         (if current-prefix-arg
             (read-coding-system "Coding System: "))))
   (let ((path (if (or (null library) (equal library ""))
                   nil
                (locate-file library load-path
-                             '("" ".el" ".el.gz" ".el.Z")))))
+                            '("" ".el" ".el.gz" ".el.Z")))))
     (if path (funcall (if (fboundp display-function)
                          display-function 'find-file)
                      path codesys)
@@ -318,7 +318,7 @@ LIBRARY should be a name without any path information and may include or omit
 the \".el\" suffix.  Under XEmacs/Mule, the optional second argument CODESYS
 specifies the coding system to use when decoding the file.  Interactively,
 with a prefix argument, this prompts for the coding system."
-  (interactive 
+  (interactive
    (list (read-library-name "Find library in other window: ")
         (if current-prefix-arg
             (read-coding-system "Coding System: "))))
@@ -330,7 +330,7 @@ LIBRARY should be a name without any path information and may include or omit
 the \".el\" suffix.  Under XEmacs/Mule, the optional second argument CODESYS
 specifies the coding system to use when decoding the file.  Interactively,
 with a prefix argument, this prompts for the coding system."
-  (interactive 
+  (interactive
    (list (read-library-name "Find library in other frame: ")
         (if current-prefix-arg
             (read-coding-system "Coding System: "))))
index 03a71d2..c83bfff 100644 (file)
@@ -61,7 +61,7 @@ Only takes effect when `lisp-initd-byte-compile-elisp' is non-nil.")
   "Kill the byte-compile Compile Log buffers")
 
 
-(defvar lisp-initd-gather-func #'directory-files 
+(defvar lisp-initd-gather-func #'directory-files
   "Function used to gather the files used in init.  For acceptable
 arguments see `directory-files'.  The function is expected to return a
 sorted list of absolute pathnames, accept and honor the MATCH argument
@@ -75,15 +75,15 @@ If DO-INIT is non-nil the file is loaded."
   (let* ((initd-dir    (file-name-as-directory
                        (expand-file-name
                         (or dir lisp-initd-dir))))
-         (initd-file   (or file lisp-initd-basename))
+        (initd-file   (or file lisp-initd-basename))
         (initd-el     (expand-file-name (concat initd-file ".el")
-                                        (paths-construct-path 
+                                        (paths-construct-path
                                          (list initd-dir ".."))))
-         (initd-elc    (concat initd-el "c"))
-         (initd-files  (funcall lisp-initd-gather-func initd-dir
+        (initd-elc    (concat initd-el "c"))
+        (initd-files  (funcall lisp-initd-gather-func initd-dir
                                t "^.*\.el$" nil t))
         (init-file     (if lisp-initd-byte-compile-elisp initd-elc initd-el))
-         init-buffer)
+        init-buffer)
 
     ;; No use in keeping an outdate byte-compiled file...
     (when (and (file-exists-p initd-el)
@@ -101,19 +101,19 @@ If DO-INIT is non-nil the file is loaded."
       (message "Recompiling init files....")
       (setq init-buffer (generate-new-buffer (concat "*" initd-el "*")))
       (with-current-buffer init-buffer
-        (set-visited-file-name initd-el)
+       (set-visited-file-name initd-el)
        (insert ";; This is an automatically generated file.\n"
                ";; DO NOT EDIT\n"
                ";;\n")
        (insert "(message \"Compiled " initd-dir " loading started\")\n")
-       (mapc 
+       (mapc
         #'(lambda (current)
             (condition-case err
                 (insert "(condition-case err (progn\n"
                         ";; ------------------------------------\n"
                         ";; " current "\n"
-                        (save-excursion        
-                          (save-restriction 
+                        (save-excursion
+                          (save-restriction
                             (with-temp-buffer
                               (insert-file-contents current)
                               (eval-buffer)
@@ -121,15 +121,15 @@ If DO-INIT is non-nil the file is loaded."
                         "\n"
                         ";; ----------------------------------\n"
                         ")\n"
-                        "(error (message \"Error loading " current 
+                        "(error (message \"Error loading " current
                         ": \\\"%S\\\" (signal:\'%S\' . data:\'%S\')\" "
                         "err (car err) (cdr err))))\n"
                         ";; ----------------------------------\n\n")
               (error
                (progn
-                 (insert "(warn \"\\\"" current 
+                 (insert "(warn \"\\\"" current
                          "\\\" not inserted "
-                         (replace-regexp-in-string 
+                         (replace-regexp-in-string
                           "\"" "\\\""
                           (format (concat "due to syntax error: %S"
                                           " (signal:%S . data:%S)")
@@ -163,7 +163,7 @@ If DIR, a string, is omitted `lisp-initd-dir' is used.  DIR can be
 either a complete path, or the last element of a path.  If the latter,
 DIR is expanded against the _parent_ directory of `lisp-initd-dir'.
 
-Optional file arg, FILE is the name of the file to be loaded.  
+Optional file arg, FILE is the name of the file to be loaded.
 If it is omitted, `lisp-initd-basename' is used.
 
 See `lisp-initd-compile'."
@@ -173,12 +173,11 @@ See `lisp-initd-compile'."
   (when dir
     (unless (string-match "/" dir)
       (setq dir (file-name-as-directory
-                (expand-file-name dir (paths-construct-path 
+                (expand-file-name dir (paths-construct-path
                                        (list lisp-initd-dir "..")))))))
   (when current-prefix-arg
     (setq file (read-string "File: ")))
-    
+
   (lisp-initd-compile dir file t))
 
 (provide 'lisp-initd)
-
index 6e2f69b..12d6cb6 100644 (file)
@@ -26,7 +26,7 @@
 ;; along with this program.  If not, see <http://www.gnu.org/licenses/>.
 
 ;;; Synched up with: FSF 20.2.
+
 ;;; Commentary:
 
 ;; This minor mode adds some services to Emacs-Lisp editing mode.
@@ -34,7 +34,7 @@
 ;; First, it knows about the header conventions for library packages.
 ;; One entry point supports generating synopses from a library directory.
 ;; Another can be used to check for missing headers in library files.
-;; 
+;;
 ;; Another entry point automatically addresses bug mail to a package's
 ;; maintainer or author.
 
 
 ;; This file is an example of the header conventions.  Note the following
 ;; features:
-;; 
+;;
 ;;    * Header line --- makes it possible to extract a one-line summary of
 ;; the package's uses automatically for use in library synopses, KWIC
 ;; indexes and the like.
-;; 
+;;
 ;;    Format is three semicolons, followed by the filename, followed by
 ;; three dashes, followed by the summary.  All fields space-separated.
-;; 
+;;
 ;;    * Author line --- contains the name and net address of at least
 ;; the principal author.
-;; 
+;;
 ;;    If there are multiple authors, they should be listed on continuation
 ;; lines led by ;;<TAB><TAB> (or multiple blanks), like this:
-;; 
+;;
 ;; ;; Author: Ashwin Ram <Ram-Ashwin@cs.yale.edu>
 ;; ;;          Dave Sill <de5@ornl.gov>
 ;; ;;          David Lawrence <tale@pawl.rpi.edu>
 ;; ;;          Joe Wells <jbw@maverick.uswest.com>
 ;; ;;          Dave Brennan <brennan@hal.com>
 ;; ;;          Eric Raymond <esr@snark.thyrsus.com>
-;; 
+;;
 ;; This field may have some special values; notably "FSF", meaning
 ;; "Free Software Foundation".
-;; 
+;;
 ;;    * Maintainer line --- should be a single name/address as in the Author
 ;; line, or an address only, or the string "FSF".  If there is no maintainer
 ;; line, the person(s) in the Author field are presumed to be it.  The example
 ;; that does "send mail to the author" without having to mine the name out by
 ;; hand. Please be careful about surrounding the network address with <> if
 ;; there's also a name in the field.
-;; 
+;;
 ;;    * Created line --- optional, gives the original creation date of the
 ;; file.  For historical interest, basically.
-;; 
+;;
 ;;    * Version line --- intended to give the reader a clue if they're looking
 ;; at a different version of the file than the one they're accustomed to.  This
 ;; may be an RCS or SCCS header.
-;; 
+;;
 ;;    * Adapted-By line --- this is for FSF's internal use.  The person named
 ;; in this field was the one responsible for installing and adapting the
 ;; package for the distribution.  (This file doesn't have one because the
 ;; author *is* one of the maintainers.)
-;; 
+;;
 ;;    * Keywords line --- used by the finder code (now under construction)
 ;; for finding Emacs Lisp code related to a topic.
 ;;
 ;;
 ;;    * Commentary line --- enables Lisp code to find the developer's and
 ;; maintainers' explanations of the package internals.
-;; 
+;;
 ;;    * Change log line --- optional, exists to terminate the commentary
 ;; section and start a change-log part, if one exists.
-;; 
+;;
 ;;    * Code line --- exists so Lisp can know where commentary and/or
 ;; change-log sections end.
-;; 
+;;
 ;;    * Footer line --- marks end-of-file so it can be distinguished from
 ;; an expanded formfeed or the results of truncation.
 
@@ -314,7 +314,7 @@ The return value has the form (NAME . ADDRESS)."
 
 (defun lm-last-modified-date (&optional file)
   "Return the modify-date given in file FILE, or current buffer if FILE is nil."
-  (save-excursion 
+  (save-excursion
     (if file
        (find-file file))
     (prog1
@@ -325,7 +325,7 @@ The return value has the form (NAME . ADDRESS)."
               (lm-code-mark) t))
            (format "%s %s %s"
                    (buffer-substring (match-beginning 3) (match-end 3))
-                   (nth (string-to-int 
+                   (nth (string-to-int
                          (buffer-substring (match-beginning 2) (match-end 2)))
                         '("" "Jan" "Feb" "Mar" "Apr" "May" "Jun"
                           "Jul" "Aug" "Sep" "Oct" "Nov" "Dec"))
@@ -342,7 +342,7 @@ The return value has the form (NAME . ADDRESS)."
 (defun lm-version (&optional file)
   "Return the version listed in file FILE, or current buffer if FILE is nil.
 This can be found in an RCS or SCCS header to crack it out of."
-  (save-excursion 
+  (save-excursion
     (if file
        (find-file file))
     (prog1
@@ -356,7 +356,7 @@ This can be found in an RCS or SCCS header to crack it out of."
             (buffer-substring (match-beginning 1) (match-end 1)))
 
            ;; Look for an SCCS header
-           ((re-search-forward 
+           ((re-search-forward
              (concat
               (regexp-quote "@(#)")
               (regexp-quote (file-name-nondirectory (buffer-file-name)))
@@ -555,7 +555,7 @@ Prompts for bug subject.  Leaves you in a mail buffer."
   (let ((package       (lm-get-package-name))
        (addr           (lm-maintainer))
        (version        (lm-version)))
-    (declare-fboundp 
+    (declare-fboundp
      (mail nil
           (if addr
               (concat (car addr) " <" (cdr addr) ">")
index 4737eb5..8d81dbc 100644 (file)
 
 (defvar lisp-imenu-generic-expression
       '(
-       (nil 
+       (nil
         #r"^\s-*(def\(un\|subst\|macro\|advice\)\s-+\([-A-Za-z0-9+*|:]+\)" 2)
-       ("Variables" 
+       ("Variables"
         #r"^\s-*(def\(var\|const\|custom\)\s-+\([-A-Za-z0-9+*|:]+\)" 2)
-       ("Types" 
-        #r"^\s-*(def\(group\|type\|struct\|class\|ine-condition\)\s-+\([-A-Za-z0-9+*|:]+\)" 
+       ("Types"
+        #r"^\s-*(def\(group\|type\|struct\|class\|ine-condition\)\s-+\([-A-Za-z0-9+*|:]+\)"
         2))
 
   "Imenu generic expression for Lisp mode.  See `imenu-generic-expression'.")
   ;; Look within the line for a ; following an even number of backslashes
   ;; after either a non-backslash or the line beginning.
   (setq comment-start-skip (concat #r"\(\(^\|"
-                                   "[^\\\\\n]"
-                                   #r"\)\(\\\\\)*\);+ *"))
+                                  "[^\\\\\n]"
+                                  #r"\)\(\\\\\)*\);+ *"))
   (make-local-variable 'comment-column)
   (setq comment-column 40)
   (make-local-variable 'comment-indent-function)
@@ -312,7 +312,7 @@ if that value is non-nil."
        mode-popup-menu emacs-lisp-mode-popup-menu
        mode-name "Emacs-Lisp")
   (if (and (featurep 'menubar)
-           current-menubar)
+          current-menubar)
       (progn
        ;; make a local copy of the menubar, so our modes don't
        ;; change the global menubar
@@ -399,7 +399,7 @@ if that value is non-nil."
   (setq mode-name "Lisp Interaction")
   (setq mode-popup-menu lisp-interaction-mode-popup-menu)
   (if (and (featurep 'menubar)
-           current-menubar)
+          current-menubar)
       (progn
        ;; make a local copy of the menubar, so our modes don't
        ;; change the global menubar
@@ -584,44 +584,44 @@ of the start of the containing expression."
     (beginning-of-line)
     (let ((indent-point (point))
          ;; XEmacs change (remove paren-depth)
-          state ;;paren-depth
-          ;; setting this to a number inhibits calling hook
-          (desired-indent nil)
-          (retry t)
-          calculate-lisp-indent-last-sexp containing-sexp)
+         state ;;paren-depth
+         ;; setting this to a number inhibits calling hook
+         (desired-indent nil)
+         (retry t)
+         calculate-lisp-indent-last-sexp containing-sexp)
       (if parse-start
-          (goto-char parse-start)
-          (beginning-of-defun))
+         (goto-char parse-start)
+         (beginning-of-defun))
       ;; Find outermost containing sexp
       (while (< (point) indent-point)
-        (setq state (parse-partial-sexp (point) indent-point 0)))
+       (setq state (parse-partial-sexp (point) indent-point 0)))
       ;; Find innermost containing sexp
       (while (and retry
                  state
                  ;; XEmacs change (remove paren-depth)
-                  (> ;;(setq paren-depth (elt state 0))
+                 (> ;;(setq paren-depth (elt state 0))
                     (elt state 0)
                     0))
-        (setq retry nil)
-        (setq calculate-lisp-indent-last-sexp (elt state 2))
-        (setq containing-sexp (elt state 1))
-        ;; Position following last unclosed open.
-        (goto-char (1+ containing-sexp))
-        ;; Is there a complete sexp since then?
-        (if (and calculate-lisp-indent-last-sexp
+       (setq retry nil)
+       (setq calculate-lisp-indent-last-sexp (elt state 2))
+       (setq containing-sexp (elt state 1))
+       ;; Position following last unclosed open.
+       (goto-char (1+ containing-sexp))
+       ;; Is there a complete sexp since then?
+       (if (and calculate-lisp-indent-last-sexp
                 (> calculate-lisp-indent-last-sexp (point)))
-            ;; Yes, but is there a containing sexp after that?
-            (let ((peek (parse-partial-sexp calculate-lisp-indent-last-sexp
+           ;; Yes, but is there a containing sexp after that?
+           (let ((peek (parse-partial-sexp calculate-lisp-indent-last-sexp
                                            indent-point 0)))
-              (if (setq retry (car (cdr peek))) (setq state peek)))))
+             (if (setq retry (car (cdr peek))) (setq state peek)))))
       (if retry
-          nil
-        ;; Innermost containing sexp found
-        (goto-char (1+ containing-sexp))
-        (if (not calculate-lisp-indent-last-sexp)
+         nil
+       ;; Innermost containing sexp found
+       (goto-char (1+ containing-sexp))
+       (if (not calculate-lisp-indent-last-sexp)
            ;; indent-point immediately follows open paren.
            ;; Don't call hook.
-            (setq desired-indent (current-column))
+           (setq desired-indent (current-column))
          ;; Find the start of first element of containing sexp.
          (parse-partial-sexp (point) calculate-lisp-indent-last-sexp 0 t)
          (cond ((looking-at "\\s(")
@@ -656,25 +656,25 @@ of the start of the containing expression."
       ;; Call indentation hook except when overridden by lisp-indent-offset
       ;; or if the desired indentation has already been computed.
       (let ((normal-indent (current-column)))
-        (cond ((elt state 3)
-               ;; Inside a string, don't change indentation.
-               (goto-char indent-point)
-               (skip-chars-forward " \t")
-               (current-column))
-              (desired-indent)
-              ((and (boundp 'lisp-indent-function)
-                    lisp-indent-function
-                    (not retry))
-               (or (funcall lisp-indent-function indent-point state)
-                   normal-indent))
+       (cond ((elt state 3)
+              ;; Inside a string, don't change indentation.
+              (goto-char indent-point)
+              (skip-chars-forward " \t")
+              (current-column))
+             (desired-indent)
+             ((and (boundp 'lisp-indent-function)
+                   lisp-indent-function
+                   (not retry))
+              (or (funcall lisp-indent-function indent-point state)
+                  normal-indent))
              ;; XEmacs change:
-              ;; lisp-indent-offset shouldn't override lisp-indent-function !
-              ((and (integerp lisp-indent-offset) containing-sexp)
-               ;; Indent by constant offset
-               (goto-char containing-sexp)
-               (+ normal-indent lisp-indent-offset))
-              (t
-               normal-indent))))))
+             ;; lisp-indent-offset shouldn't override lisp-indent-function !
+             ((and (integerp lisp-indent-offset) containing-sexp)
+              ;; Indent by constant offset
+              (goto-char containing-sexp)
+              (+ normal-indent lisp-indent-offset))
+             (t
+              normal-indent))))))
 
 (defun lisp-indent-function (indent-point state)
   ;; free reference to `calculate-lisp-indent-last-sexp'
@@ -683,21 +683,21 @@ of the start of the containing expression."
     (goto-char (1+ (elt state 1)))
     (parse-partial-sexp (point) calculate-lisp-indent-last-sexp 0 t)
     (if (and (elt state 2)
-             (not (looking-at #r"\sw\|\s_")))
-        ;; car of form doesn't seem to be a symbol
-        (progn
-          (if (not (> (save-excursion (forward-line 1) (point))
-                      calculate-lisp-indent-last-sexp))
-              (progn (goto-char calculate-lisp-indent-last-sexp)
-                     (beginning-of-line)
-                     (parse-partial-sexp (point)
+            (not (looking-at #r"\sw\|\s_")))
+       ;; car of form doesn't seem to be a symbol
+       (progn
+         (if (not (> (save-excursion (forward-line 1) (point))
+                     calculate-lisp-indent-last-sexp))
+             (progn (goto-char calculate-lisp-indent-last-sexp)
+                    (beginning-of-line)
+                    (parse-partial-sexp (point)
                                         calculate-lisp-indent-last-sexp 0 t)))
-          ;; Indent under the list or under the first sexp on the same
-          ;; line as calculate-lisp-indent-last-sexp.  Note that first
-          ;; thing on that line has to be complete sexp since we are
-          ;; inside the innermost containing sexp.
-          (backward-prefix-chars)
-          (current-column))
+         ;; Indent under the list or under the first sexp on the same
+         ;; line as calculate-lisp-indent-last-sexp.  Note that first
+         ;; thing on that line has to be complete sexp since we are
+         ;; inside the innermost containing sexp.
+         (backward-prefix-chars)
+         (current-column))
       (let ((function (buffer-substring (point)
                                        (progn (forward-sexp 1) (point))))
            method)
@@ -727,8 +727,8 @@ of the start of the containing expression."
 
 (defun lisp-indent-specform (count state indent-point normal-indent)
   (let ((containing-form-start (elt state 1))
-        (i count)
-        body-indent containing-form-column)
+       (i count)
+       body-indent containing-form-column)
     ;; Move to the start of containing form, calculate indentation
     ;; to use for non-distinguished forms (> count), and move past the
     ;; function symbol.  lisp-indent-function guarantees that there is at
@@ -742,33 +742,33 @@ of the start of the containing expression."
     ;; Now find the start of the last form.
     (parse-partial-sexp (point) indent-point 1 t)
     (while (and (< (point) indent-point)
-                (condition-case ()
-                    (progn
-                      (setq count (1- count))
-                      (forward-sexp 1)
-                      (parse-partial-sexp (point) indent-point 1 t))
-                  (error nil))))
+               (condition-case ()
+                   (progn
+                     (setq count (1- count))
+                     (forward-sexp 1)
+                     (parse-partial-sexp (point) indent-point 1 t))
+                 (error nil))))
     ;; Point is sitting on first character of last (or count) sexp.
     (if (> count 0)
-        ;; A distinguished form.  If it is the first or second form use double
-        ;; lisp-body-indent, else normal indent.  With lisp-body-indent bound
-        ;; to 2 (the default), this just happens to work the same with if as
-        ;; the older code, but it makes unwind-protect, condition-case,
-        ;; with-output-to-temp-buffer, et. al. much more tasteful.  The older,
-        ;; less hacked, behavior can be obtained by replacing below with
-        ;; (list normal-indent containing-form-start).
-        (if (<= (- i count) 1)
-            (list (+ containing-form-column (* 2 lisp-body-indent))
-                  containing-form-start)
-            (list normal-indent containing-form-start))
+       ;; A distinguished form.  If it is the first or second form use double
+       ;; lisp-body-indent, else normal indent.  With lisp-body-indent bound
+       ;; to 2 (the default), this just happens to work the same with if as
+       ;; the older code, but it makes unwind-protect, condition-case,
+       ;; with-output-to-temp-buffer, et. al. much more tasteful.  The older,
+       ;; less hacked, behavior can be obtained by replacing below with
+       ;; (list normal-indent containing-form-start).
+       (if (<= (- i count) 1)
+           (list (+ containing-form-column (* 2 lisp-body-indent))
+                 containing-form-start)
+           (list normal-indent containing-form-start))
       ;; A non-distinguished form.  Use body-indent if there are no
       ;; distinguished forms and this is the first undistinguished form,
       ;; or if this is the first undistinguished form and the preceding
       ;; distinguished form has indentation at least as great as body-indent.
       (if (or (and (= i 0) (= count 0))
-              (and (= count 0) (<= body-indent normal-indent)))
-          body-indent
-          normal-indent))))
+             (and (= count 0) (<= body-indent normal-indent)))
+         body-indent
+         normal-indent))))
 
 (defun lisp-indent-defform (state indent-point)
   (goto-char (car (cdr state)))
index cbacc3d..06c1d93 100644 (file)
@@ -61,7 +61,7 @@ move backward across N balanced expressions."
   (if (and (> arg 0) (looking-at "#s(\\|#r[uU]?\"\\|#p\\["))
     (goto-char (1+ (- (point) (- (match-end 0) (match-beginning 0))))))
   (goto-char (or (scan-sexps (point) arg) (buffer-end arg)))
-  (when (< arg 0) 
+  (when (< arg 0)
     (backward-prefix-chars)
     ;; XEmacs: evil hack! Skip back over #[sr] so that structures and raw
     ;; strings are read properly.  the current cheesified syntax tables just
@@ -231,7 +231,7 @@ If COUNT < 1, nothing is done.  \(This is a bug.)"
   (interactive "_p")
   (if (or (null count) (= count 0)) (setq count 1))
   (if end-of-defun-function
-      (if (> count 0) 
+      (if (> count 0)
          (dotimes (i count)
            (funcall end-of-defun-function)))
   (let ((first t))
index 390ccdd..2f3b63d 100644 (file)
@@ -2,7 +2,7 @@
 
 ;; Copyright (C) 1992-4, 1997 Free Software Foundation, Inc.
 ;; Copyright (C) 1996, 2000 Ben Wing.
+
 ;; Maintainer: SXEmacs Development Team
 ;; Keywords: extensions, dumped
 
@@ -98,7 +98,7 @@
   (add-local-hook 'pre-command-hook 'list-mode-extent-pre-hook)
   (set (make-local-variable 'next-line-add-newlines) nil)
   (setq list-mode-extent nil)
-;; It is visually disconcerting to have the text cursor disappear within list 
+;; It is visually disconcerting to have the text cursor disappear within list
 ;; buffers, especially when moving from window to window, so leave it
 ;; visible.  -- Bob Weiner, 06/20/1999
 ; (set-specifier text-cursor-visible-p nil (current-buffer))
@@ -334,7 +334,7 @@ If `completion-highlight-first-word-only' is non-nil, then only the start
                       ;; be the selected-frame at the point this is
                       ;; run.  We keep the selected-frame call around
                       ;; just in case.
-               (window-width (get-lru-window (last-nonminibuf-frame)))
+              (window-width (get-lru-window (last-nonminibuf-frame)))
                     80))))
          (let ((count 0)
                (max-width 0)
@@ -357,7 +357,7 @@ If `completion-highlight-first-word-only' is non-nil, then only the start
                      (setq max-width len))
                  (setq count (1+ count)
                        tail (cdr tail)))))
-        
+
            (setq max-width (+ 2 max-width)) ; at least two chars between cols
            (setq old-max-width max-width)
            (let ((rows (let ((cols (min (/ win-width max-width) count)))
@@ -368,7 +368,7 @@ If `completion-highlight-first-word-only' is non-nil, then only the start
                              (setq max-width (/ win-width cols))
                              (if (/= (% count cols) 0) ; want ceiling...
                                  (1+ (/ count cols))
-                                (/ count cols)))))))
+                               (/ count cols)))))))
              (when
                  (and cl-window-height
                       (> rows cl-window-height))
@@ -395,9 +395,9 @@ If `completion-highlight-first-word-only' is non-nil, then only the start
                        (if (/= indent 0)
                            (if bufferp
                                (indent-to indent 2)
-                              (while (progn (write-char ?\ )
-                                            (setq column (1+ column))
-                                            (< column indent)))))
+                             (while (progn (write-char ?\ )
+                                           (setq column (1+ column))
+                                           (< column indent)))))
                        (setq indent (+ indent max-width))
                        (let ((start (point))
                              end)
@@ -480,18 +480,18 @@ buffer."
   (interactive)
   (message "Making completion list...")
   (let ((completions (all-completions (buffer-string)
-                                      minibuffer-completion-table
-                                      minibuffer-completion-predicate)))
+                                     minibuffer-completion-table
+                                     minibuffer-completion-predicate)))
     (message nil)
     (if (null completions)
-        (progn
-          (ding nil 'no-completion)
-          (temp-minibuffer-message " [No completions]"))
-        (with-output-to-temp-buffer "*Completions*"
+       (progn
+         (ding nil 'no-completion)
+         (temp-minibuffer-message " [No completions]"))
+       (with-output-to-temp-buffer "*Completions*"
          (funcall completion-display-completion-list-function
                   (sort completions #'string-lessp))))))
 
-(define-derived-mode completion-list-mode list-mode 
+(define-derived-mode completion-list-mode list-mode
   "Completion List"
   "Major mode for buffers showing lists of possible completions.
 \\{completion-list-mode-map}"
index 7f1fa50..134c214 100644 (file)
@@ -55,7 +55,7 @@
 ;; It is no longer necessary.  Instead use autoload.el to maintain them
 ;; for you.  Just insert ";;;###autoload" before defuns or defmacros you
 ;; want to be autoloaded, or other forms you want copied into loaddefs.el
-;; (defvars, key definitions, etc.).  For example, 
+;; (defvars, key definitions, etc.).  For example,
 ;;     ;;;###autoload
 ;;     (defun foobar () ....)
 ;;     ;;;###autoload (define-key global-map "f" 'foobar)
index 46136a6..1ea7a05 100644 (file)
@@ -52,42 +52,42 @@ with `defface' and `custom-declare-face'."
   (interactive "SFind source file for symbol: ") ; XEmacs
   (let (built-in-file autoload-cons symbol-details)
     (cond ((and (eq 'autoload
-                    (car-safe
-                     (setq autoload-cons
-                           (and (fboundp sym) (symbol-function sym)))))
-                (or (and (or (null type) (eq 'defvar type))
-                         (eq (fifth autoload-cons) 'keymap))
-                    (and (or (null type) (eq 'defun type))
-                         (memq (fifth autoload-cons) '(nil macro)))))
-           (return-from symbol-file (locate-library (second autoload-cons))))
-          ((eq 'defvar type)
-           ;; Load history entries corresponding to variables are just
-           ;; symbols.
-           (dolist (entry load-history)
-             (when (memq sym (cdr entry))
-               (return-from symbol-file (car entry)))))
-           ((not (null type))
-            ;; Non-variables have the type stored as the car of the entry. 
-            (dolist (entry load-history)
-              (when (and (setq symbol-details (rassq sym (cdr entry)))
-                         (eq type (car symbol-details)))
-                (return-from symbol-file (car entry)))))
-          (t
-           ;; If TYPE hasn't been specified, we need to check both for
-           ;; variables and other symbols.
-           (dolist (entry load-history)
-             (when (or (memq sym (cdr entry))
-                       (rassq sym (cdr entry)))
-               (return-from symbol-file (car entry))))))
+                   (car-safe
+                    (setq autoload-cons
+                          (and (fboundp sym) (symbol-function sym)))))
+               (or (and (or (null type) (eq 'defvar type))
+                        (eq (fifth autoload-cons) 'keymap))
+                   (and (or (null type) (eq 'defun type))
+                        (memq (fifth autoload-cons) '(nil macro)))))
+          (return-from symbol-file (locate-library (second autoload-cons))))
+         ((eq 'defvar type)
+          ;; Load history entries corresponding to variables are just
+          ;; symbols.
+          (dolist (entry load-history)
+            (when (memq sym (cdr entry))
+              (return-from symbol-file (car entry)))))
+          ((not (null type))
+           ;; Non-variables have the type stored as the car of the entry.
+           (dolist (entry load-history)
+             (when (and (setq symbol-details (rassq sym (cdr entry)))
+                        (eq type (car symbol-details)))
+               (return-from symbol-file (car entry)))))
+         (t
+          ;; If TYPE hasn't been specified, we need to check both for
+          ;; variables and other symbols.
+          (dolist (entry load-history)
+            (when (or (memq sym (cdr entry))
+                      (rassq sym (cdr entry)))
+              (return-from symbol-file (car entry))))))
     (when (setq built-in-file (built-in-symbol-file sym type))
       (if (equal built-in-file (file-truename built-in-file))
-          ;; Probably a full path name:
-          built-in-file
-        ;; This is a bit heuristic, but shouldn't realistically be a
-        ;; problem:
-        (if (string-match "\.elc?$" built-in-file)
-            (concat lisp-directory built-in-file)
-          (concat source-directory "/src/" built-in-file))))))
+         ;; Probably a full path name:
+         built-in-file
+       ;; This is a bit heuristic, but shouldn't realistically be a
+       ;; problem:
+       (if (string-match "\.elc?$" built-in-file)
+           (concat lisp-directory built-in-file)
+         (concat source-directory "/src/" built-in-file))))))
 
 (defun feature-symbols (feature)
   "Return the file and list of symbols associated with a given FEATURE."
index a2e64b4..9591871 100644 (file)
   "Non-nil when the current emacs is SXEmacs.")
 
 ;; Can't make this constant for now because it causes an error in
-;; update-elc.el. 
+;; update-elc.el.
 (defvar source-lisp (file-name-directory (expand-file-name (nth 2 command-line-args))) "\
-Root of tree containing the Lisp source code for the current build. 
+Root of tree containing the Lisp source code for the current build.
 Differs from `lisp-directory' if this SXEmacs has been installed. ")
 
 (defconst build-directory (expand-file-name ".." (expand-file-name ".." invocation-directory)) "\
-Root of tree containing object files and executables produced by build. 
-Differs from `source-directory' if configured with --srcdir option, a practice 
+Root of tree containing object files and executables produced by build.
+Differs from `source-directory' if configured with --srcdir option, a practice
 recommended for developers.")
 
 (defconst source-directory (expand-file-name ".." source-lisp)  "\
-Root of tree containing source code for the current build. 
+Root of tree containing source code for the current build.
 Used during loadup and for documenting source of symbols defined in C.")
 
 (defvar preloaded-file-list nil "\
@@ -71,13 +71,13 @@ with the exception of `loadup.el'.")
 ;(start-profiling)
 
 (defun compute-build-root (dir)
-  "Given DIR as basis, traverse parent-wards until the cookie 
+  "Given DIR as basis, traverse parent-wards until the cookie
 file .sxemacs.source.tree is found."
   (when (stringp dir)
     (while (and (file-readable-p dir)
-                (not (string-equal "/" dir))
-                (not (file-exists-p
-                      (expand-file-name ".sxemacs.source.tree" dir))))
+               (not (string-equal "/" dir))
+               (not (file-exists-p
+                     (expand-file-name ".sxemacs.source.tree" dir))))
       (setq dir (expand-file-name ".." dir)))
     dir))
 
@@ -89,7 +89,7 @@ file .sxemacs.source.tree is found."
                (not (memq 'quick-build internal-error-checking)))
           30000 3000000)))
 
-  
+
 ;; This is awfully damn early to be getting an error, right?
 (call-with-condition-handler 'really-early-error-handler
     #'(lambda ()
@@ -109,20 +109,20 @@ file .sxemacs.source.tree is found."
                  (kill-buffer (current-buffer)))))
 
        (let ((build-root (compute-build-root invocation-directory))
-              (source-tree-root (getenv "SOURCE_TREE_ROOT"))
-              (build-tree-root (getenv "BUILD_TREE_ROOT")))
+             (source-tree-root (getenv "SOURCE_TREE_ROOT"))
+             (build-tree-root (getenv "BUILD_TREE_ROOT")))
          (setq load-path
-                (list (expand-file-name "lisp" build-root)
-                      (expand-file-name "lisp" build-tree-root)
-                      (expand-file-name "lisp" source-tree-root)))
+               (list (expand-file-name "lisp" build-root)
+                     (expand-file-name "lisp" build-tree-root)
+                     (expand-file-name "lisp" source-tree-root)))
          (setq module-load-path
-                (list (expand-file-name "modules" build-root)
-                      (expand-file-name "modules" build-tree-root)
-                      (expand-file-name "modules" source-tree-root)))
-          (unless (file-exists-p (car load-path))
-            (setq load-path (cdr load-path)))
-          (unless (file-exists-p (car module-load-path))
-            (setq module-load-path (cdr module-load-path))))
+               (list (expand-file-name "modules" build-root)
+                     (expand-file-name "modules" build-tree-root)
+                     (expand-file-name "modules" source-tree-root)))
+         (unless (file-exists-p (car load-path))
+           (setq load-path (cdr load-path)))
+         (unless (file-exists-p (car module-load-path))
+           (setq module-load-path (cdr module-load-path))))
 
        ;; message not defined yet ...
        (external-debugging-output (format "\nUsing load-path %s" load-path))
@@ -144,13 +144,13 @@ file .sxemacs.source.tree is found."
        ;; #### This code is duplicated in two other places.
        (let ((temp-path (expand-file-name "." (car load-path))))
          (setq load-path
-                (nconc
-                 (mapcar
-                  #'(lambda (i) (concat i "/"))
-                  (directory-files temp-path t "^[^-.]"
-                                   nil 'dirs-only))
-                 (cons (file-name-as-directory temp-path)
-                       load-path))))
+               (nconc
+                (mapcar
+                 #'(lambda (i) (concat i "/"))
+                 (directory-files temp-path t "^[^-.]"
+                                  nil 'dirs-only))
+                (cons (file-name-as-directory temp-path)
+                      load-path))))
 
        (setq load-warn-when-source-newer t ; Used to be set to nil at the end
              load-warn-when-source-only  t) ; Set to nil at the end
@@ -177,8 +177,8 @@ file .sxemacs.source.tree is found."
              ;;(print (format "guessed-roots: %S" (paths-find-emacs-roots invocation-directory invocation-name)))
              nil)))
 
-        (let ((f (locate-file "dumped-lisp.el" load-path)))
-          (load f))
+       (let ((f (locate-file "dumped-lisp.el" load-path)))
+         (load f))
 
        (let ((files preloaded-file-list)
              file)
@@ -252,7 +252,7 @@ file .sxemacs.source.tree is found."
       ;; load-history) is normally done in lread.c after reading the
       ;; entirety of a file, something which never happens for loadup.el.
       current-load-list nil)
-;; Make the path to this file look a little nicer: 
+;; Make the path to this file look a little nicer:
 (setcar (car load-history) (file-truename (caar load-history)))
 
 (garbage-collect)
@@ -336,7 +336,7 @@ file .sxemacs.source.tree is found."
       ;; This is handled earlier in the build process.
       ;; (condition-case () (delete-file "sxemacs") (file-error nil))
       (when-fboundp 'really-free
-        (really-free))
+       (really-free))
       (dump-emacs invf dmpf)
       (kill-emacs))))
 
index 0244966..ce106d2 100644 (file)
        (append package-preloaded-file-list
                preloaded-file-list
                packages-hardcoded-lisp)
-         
+
        processed (cons "-d" processed)
        processed (cons source-lisp processed)
        ;; Include loadup.el, which is never in preloaded-file-list:
   (while preloaded-file-list
     (setq arg0 (packages-add-suffix (car preloaded-file-list))
          arg (locate-library arg0)
-          absolute arg)
+         absolute arg)
     (if (null arg)
        (progn
          (message "Error: dumped file %s does not exist" arg0)
          ;; Uncomment in case of difficulties
-          ;(message "late-package-hierarchies: %S"
-          ;         late-package-hierarchies)
-          ;(message "guessed-roots: %S" (paths-find-emacs-roots
-          ;                              invocation-directory
-          ;                              invocation-name
-          ;                              #'paths-emacs-root-p))
-          ;(message "guessed-data-roots: %S" (paths-find-emacs-roots
-          ;                                   invocation-directory
-          ;                                   invocation-name
-          ;                                   #'paths-emacs-data-root-p))
-          )
+         ;(message "late-package-hierarchies: %S"
+         ;         late-package-hierarchies)
+         ;(message "guessed-roots: %S" (paths-find-emacs-roots
+         ;                              invocation-directory
+         ;                              invocation-name
+         ;                              #'paths-emacs-root-p))
+         ;(message "guessed-data-roots: %S" (paths-find-emacs-roots
+         ;                                   invocation-directory
+         ;                                   invocation-name
+         ;                                   #'paths-emacs-data-root-p))
+         )
       (when (equal arg (expand-file-name arg0 source-lisp))
        ;; Use relative paths where possible, since this makes file lookup
        ;; in an installed XEmacs easier:
       (if (null (member arg processed))
          (progn
            (if (and (null docfile-out-of-date)
-                     ;; We need to check the absolute path here:
+                    ;; We need to check the absolute path here:
                     (file-newer-than-file-p absolute docfile))
                (setq docfile-out-of-date t))
            (setq processed (cons arg processed)))))
index 1e31f8b..a9b264b 100644 (file)
@@ -99,7 +99,7 @@ Returns the number of actions taken."
     (if (should-use-dialog-box-p)
        ;; Make a list describing a dialog box.
        (let (;; (object (capitalize (or (nth 0 help) "object")))
-             ;; (objects (capitalize (or (nth 1 help) "objects")))
+             ;; (objects (capitalize (or (nth 1 help) "objects")))
              ;; (action (capitalize (or (nth 2 help) "act on")))
              )
          (setq map `(("%_Yes" . act) ("%_No" . skip)
index a1c106d..b73d1b6 100644 (file)
@@ -58,9 +58,9 @@ Return a list of (label value) lists with labels truncated to last
 LABEL-LENGTH characters of value."
   (mapcar #'(lambda (x)
              (if (<= (length x) label-length)
-                  (list x x)
-                (list
-                 (concat "..." (substring x (- label-length))) x)))
+                 (list x x)
+               (list
+                (concat "..." (substring x (- label-length))) x)))
          (if (<= (length list) count)
              list
            (butlast list (- (length list) count)))))
@@ -531,11 +531,11 @@ See also `menu-split-long-menu'."
             menu
           (let ((items
                  (submenu-generate-accelerator-spec
-                   (mapcar #'(lambda (label-value)
+                  (mapcar #'(lambda (label-value)
                               (vector (first label-value)
                                       (list 'grep (second label-value))))
                           (Menubar-items-truncate-history
-                            grep-history 10 50)))))
+                           grep-history 10 50)))))
             (append menu '("---") items))))
        ["%_Grep..." grep :active (fboundp 'grep)]
        ["%_Kill Grep" kill-compilation
@@ -644,7 +644,7 @@ See also `menu-split-long-menu'."
                               (vector (first label-value)
                                       (list 'compile (second label-value))))
                           (Menubar-items-truncate-history
-                            compile-history 10 50)))))
+                           compile-history 10 50)))))
             (append menu '("---") items))))
        ["%_Compile..." compile :active (fboundp 'compile)]
        ["%_Repeat Compilation" recompile :active (fboundp 'recompile)]
@@ -987,12 +987,12 @@ See also `menu-split-long-menu'."
         :active (and (boundp 'browse-url-browser-function)
                      (fboundp 'browse-url-w3)
                      (fboundp 'w3-fetch))]
-        ["Emacs-%_W3 (gnuclient)"
-         (customize-set-variable 'browse-url-browser-function 'browse-url-w3-gnudoit)
-         :style radio
-         :selected (and (boundp 'browse-url-browser-function)
-                        (eq browse-url-browser-function
-                            'browse-url-w3-gnudoit))
+       ["Emacs-%_W3 (gnuclient)"
+        (customize-set-variable 'browse-url-browser-function 'browse-url-w3-gnudoit)
+        :style radio
+        :selected (and (boundp 'browse-url-browser-function)
+                       (eq browse-url-browser-function
+                           'browse-url-w3-gnudoit))
         :active (and (boundp 'browse-url-browser-function)
                      (fboundp 'browse-url-w3-gnudoit))]
        ["%_Netscape"
index 6aef638..a0a3352 100644 (file)
@@ -361,16 +361,16 @@ menu item called \"Item\" under the \"Foo\" submenu of \"Menu\".
 NEW-NAME is the string that the menu item will be printed as from now on."
   (check-type new-name string)
   (let* ((menubar current-menubar)
-         (pair (find-menu-item menubar path))
-         (item (car pair))
-         (menu (cdr pair)))
+        (pair (find-menu-item menubar path))
+        (item (car pair))
+        (menu (cdr pair)))
     (or item
-        (signal 'error (list (if menu (gettext "No such menu item")
-                               (gettext "No such menu"))
-                             path)))
+       (signal 'error (list (if menu (gettext "No such menu item")
+                              (gettext "No such menu"))
+                            path)))
     (if (and (consp item)
-             (stringp (car item)))
-        (setcar item new-name)
+            (stringp (car item)))
+       (setcar item new-name)
       (aset item 0 new-name))
     (set-menubar-dirty-flag)
     item))
@@ -386,46 +386,46 @@ NEW-NAME is the string that the menu item will be printed as from now on."
 (defun enable-menu-item-1 (path toggle-p on-p)
   (let (menu item)
     (if (and (vectorp path) (> (length path) 2)) ; limited syntax checking...
-        (setq item path)
+       (setq item path)
       (let* ((menubar current-menubar)
-             (pair (find-menu-item menubar path)))
-        (setq item (car pair)
-              menu (cdr pair))
-        (or item
-            (signal 'error (list (if menu
-                                     "No such menu item"
-                                   "No such menu")
-                                 path)))
-        (if (consp item)
-            (error "%S is a menu, not a menu item" path))))
+            (pair (find-menu-item menubar path)))
+       (setq item (car pair)
+             menu (cdr pair))
+       (or item
+           (signal 'error (list (if menu
+                                    "No such menu item"
+                                  "No such menu")
+                                path)))
+       (if (consp item)
+           (error "%S is a menu, not a menu item" path))))
     (if (or (> (length item) 4)
-            (and (symbolp (aref item 2))
-                 (= ?: (aref (symbol-name (aref item 2)) 0))))
-        ;; plist-like syntax
-        (let ((i 2)
-              (keyword (if toggle-p :selected :active))
-              (ok nil))
-          (while (< i (length item))
-            (cond ((eq (aref item i) keyword)
-                   (aset item (1+ i) on-p)
-                   (setq ok t)))
-            (setq i (+ i 2)))
-          (cond (ok nil)
-                (toggle-p
-                 (signal 'error (list "not a toggle menu item" item)))
-                (t
-                 ;; Need to copy the item to extend it, sigh...
-                 (let ((cons (memq item menu))
-                       (new-item (vconcat item (list keyword on-p))))
-                   (if cons
-                       (setcar cons (setq item new-item))
-                     (if menu
-                         (error "couldn't find %S on its parent?" item)
-                       (error "no %S slot to set: %S" keyword item)))))))
+           (and (symbolp (aref item 2))
+                (= ?: (aref (symbol-name (aref item 2)) 0))))
+       ;; plist-like syntax
+       (let ((i 2)
+             (keyword (if toggle-p :selected :active))
+             (ok nil))
+         (while (< i (length item))
+           (cond ((eq (aref item i) keyword)
+                  (aset item (1+ i) on-p)
+                  (setq ok t)))
+           (setq i (+ i 2)))
+         (cond (ok nil)
+               (toggle-p
+                (signal 'error (list "not a toggle menu item" item)))
+               (t
+                ;; Need to copy the item to extend it, sigh...
+                (let ((cons (memq item menu))
+                      (new-item (vconcat item (list keyword on-p))))
+                  (if cons
+                      (setcar cons (setq item new-item))
+                    (if menu
+                        (error "couldn't find %S on its parent?" item)
+                      (error "no %S slot to set: %S" keyword item)))))))
       ;; positional syntax
       (if toggle-p
-          (signal 'error (list "not a toggle menu item" item))
-        (aset item 2 on-p)))
+         (signal 'error (list "not a toggle menu item" item))
+       (aset item 2 on-p)))
     (set-menubar-dirty-flag)
     item))
 
@@ -687,8 +687,8 @@ MENU-DESC and EVENT are as in the call to `popup-menu'."
              ((event-matches-key-specifier-p new-event (quit-char))
               (signal 'quit nil))
              ;; this function has been ordered to do essentially
-        ;; X-specifc processing after this check.
-             ((not (popup-up-p))       
+       ;; X-specifc processing after this check.
+             ((not (popup-up-p))
               (setq unread-command-events (cons new-event
                                                 unread-command-events))
               (throw 'popup-done nil))
index 9cf418e..02c1d69 100644 (file)
@@ -121,7 +121,7 @@ minibuffer is reinvoked while it is the selected window."
 
 (defvar minibuffer-default nil
   "Default value for minibuffer input.")
-  
+
 (defvar minibuffer-local-map
   (let ((map (make-sparse-keymap 'minibuffer-local-map)))
     map)
@@ -181,10 +181,10 @@ minibuffer is reinvoked while it is the selected window."
 
 (defvar read-expression-map (let ((map (make-sparse-keymap
                                        'read-expression-map)))
-                              (set-keymap-parents map
+                             (set-keymap-parents map
                                                  (list minibuffer-local-map))
-                              (define-key map "\M-\t" 'lisp-complete-symbol)
-                              map)
+                             (define-key map "\M-\t" 'lisp-complete-symbol)
+                             map)
   "Minibuffer keymap used for reading Lisp expressions.")
 
 (defvar read-shell-command-map
@@ -347,9 +347,9 @@ minibuffer history if its length is less than that value."
         (princ (cadr error-object) stream)))
 
 (defun read-from-minibuffer (prompt &optional initial-contents
-                                    keymap
-                                    readp
-                                    history
+                                   keymap
+                                   readp
+                                   history
                                    abbrev-table
                                    default)
   "Read a string from the minibuffer, prompting with string PROMPT.
@@ -379,13 +379,13 @@ Seventh arg DEFAULT, if non-nil, will be returned when user enters
 See also the variable `completion-highlight-first-word-only' for
   control over completion display."
   (if (and (not enable-recursive-minibuffers)
-           (> (minibuffer-depth) 0)
-           (eq (selected-window) (minibuffer-window)))
+          (> (minibuffer-depth) 0)
+          (eq (selected-window) (minibuffer-window)))
       (error "Command attempted to use minibuffer while in minibuffer"))
 
   (if (and minibuffer-max-depth
           (> minibuffer-max-depth 0)
-           (>= (minibuffer-depth) minibuffer-max-depth))
+          (>= (minibuffer-depth) minibuffer-max-depth))
       (minibuffer-max-depth-exceeded))
 
   ;; catch this error before the poor user has typed something...
@@ -398,25 +398,25 @@ See also the variable `completion-highlight-first-word-only' for
 
   (if (noninteractive)
       (progn
-        ;; XEmacs in -batch mode calls minibuffer: print the prompt.
-        (message "%s" (gettext prompt))
-        ;;#### force-output
+       ;; XEmacs in -batch mode calls minibuffer: print the prompt.
+       (message "%s" (gettext prompt))
+       ;;#### force-output
 
-        ;;#### Should this even be falling though to the code below?
-        ;;#### How does this stuff work now, anyway?
-        ))
+       ;;#### Should this even be falling though to the code below?
+       ;;#### How does this stuff work now, anyway?
+       ))
   (let* ((dir default-directory)
-         (owindow (selected-window))
+        (owindow (selected-window))
         (oframe (selected-frame))
-         (window (minibuffer-window))
-         (buffer (if (eq (minibuffer-depth) 0)
-                     (window-buffer window)
+        (window (minibuffer-window))
+        (buffer (if (eq (minibuffer-depth) 0)
+                    (window-buffer window)
                   (get-buffer-create (format " *Minibuf-%d"
                                              (minibuffer-depth)))))
-         (frame (window-frame window))
-         (mconfig (if (eq frame (selected-frame))
-                      nil (current-window-configuration frame)))
-         (oconfig (current-window-configuration))
+        (frame (window-frame window))
+        (mconfig (if (eq frame (selected-frame))
+                     nil (current-window-configuration frame)))
+        (oconfig (current-window-configuration))
         ;; dynamic scope sucks sucks sucks sucks sucks sucks.
         ;; `M-x doctor' makes history a local variable, and thus
         ;; our binding above is buffer-local and doesn't apply
@@ -424,11 +424,11 @@ See also the variable `completion-highlight-first-word-only' for
         (_history_ history)
         (minibuffer-default default))
     (unwind-protect
-         (progn
-           (set-buffer (reset-buffer buffer))
-           (setq default-directory dir)
-           (make-local-variable 'print-escape-newlines)
-           (setq print-escape-newlines t)
+        (progn
+          (set-buffer (reset-buffer buffer))
+          (setq default-directory dir)
+          (make-local-variable 'print-escape-newlines)
+          (setq print-escape-newlines t)
           (make-local-variable 'current-minibuffer-contents)
           (make-local-variable 'current-minibuffer-point)
           (make-local-variable 'initial-minibuffer-history-position)
@@ -443,103 +443,103 @@ See also the variable `completion-highlight-first-word-only' for
             (make-local-variable 'mouse-track-click-hook)
             (add-hook 'mouse-track-click-hook
                       'minibuffer-smart-maybe-select-highlighted-completion))
-           (set-window-buffer window buffer)
-           (select-window window)
-           (set-window-hscroll window 0)
-           (buffer-enable-undo buffer)
-           (message nil)
-           (if initial-contents
-               (if (consp initial-contents)
-                   (progn
-                     (insert (car initial-contents))
-                     (goto-char (1+ (cdr initial-contents)))
+          (set-window-buffer window buffer)
+          (select-window window)
+          (set-window-hscroll window 0)
+          (buffer-enable-undo buffer)
+          (message nil)
+          (if initial-contents
+              (if (consp initial-contents)
+                  (progn
+                    (insert (car initial-contents))
+                    (goto-char (1+ (cdr initial-contents)))
                     (setq current-minibuffer-contents (car initial-contents)
                           current-minibuffer-point (cdr initial-contents)))
                 (insert initial-contents)
                 (setq current-minibuffer-contents initial-contents
                       current-minibuffer-point (point))))
-           (use-local-map (help-keymap-with-help-key
+          (use-local-map (help-keymap-with-help-key
                           (or keymap minibuffer-local-map)
                           minibuffer-help-form))
-           (let ((mouse-grabbed-buffer
+          (let ((mouse-grabbed-buffer
                  (and minibuffer-smart-completion-tracking-behavior
                       (current-buffer)))
-                 (current-prefix-arg current-prefix-arg)
+                (current-prefix-arg current-prefix-arg)
 ;;                 (help-form minibuffer-help-form)
-                 (minibuffer-history-variable (cond ((not _history_)
-                                                     'minibuffer-history)
-                                                    ((consp _history_)
-                                                     (car _history_))
-                                                    (t
-                                                     _history_)))
-                 (minibuffer-history-position (cond ((consp _history_)
-                                                     (cdr _history_))
-                                                    (t
-                                                     0)))
-                 (minibuffer-scroll-window owindow))
+                (minibuffer-history-variable (cond ((not _history_)
+                                                    'minibuffer-history)
+                                                   ((consp _history_)
+                                                    (car _history_))
+                                                   (t
+                                                    _history_)))
+                (minibuffer-history-position (cond ((consp _history_)
+                                                    (cdr _history_))
+                                                   (t
+                                                    0)))
+                (minibuffer-scroll-window owindow))
             (setq initial-minibuffer-history-position
                   minibuffer-history-position)
             (if abbrev-table
                 (setq local-abbrev-table abbrev-table
                       abbrev-mode t))
             ;; This is now run from read-minibuffer-internal
-             ;(if minibuffer-setup-hook
-             ;    (run-hooks 'minibuffer-setup-hook))
-             ;(message nil)
-
-             ;; Adjust the prompt
-             (flet ((fmt-prompt-stack (p ps)
-                      (if (not ps)
-                          p
-                        (fmt-prompt-stack (concat "[" (car ps) "]" p) (cdr ps)))))
-               (push prompt minibuffer-prompt-stack)
-               (setq prompt (fmt-prompt-stack prompt (cdr minibuffer-prompt-stack))))
-
-             (if (eq 't
-                     (catch 'exit
-                       (unwind-protect
-                           (if (> (recursion-depth) (minibuffer-depth))
-                               (let ((standard-output t)
-                                     (standard-input t))
-                                 (read-minibuffer-internal prompt))
-                             (read-minibuffer-internal prompt))
-                         (pop minibuffer-prompt-stack))))
-                       
-                 ;; Translate an "abort" (throw 'exit 't)
-                 ;;  into a real quit
-                 (signal 'quit '())
-               ;; return value
-               (let* ((val (progn (set-buffer buffer)
-                                  (if minibuffer-exit-hook
-                                      (run-hooks 'minibuffer-exit-hook))
-                                  (if (and (eq (char-after (point-min)) nil)
+            ;(if minibuffer-setup-hook
+            ;    (run-hooks 'minibuffer-setup-hook))
+            ;(message nil)
+
+            ;; Adjust the prompt
+            (flet ((fmt-prompt-stack (p ps)
+                     (if (not ps)
+                         p
+                       (fmt-prompt-stack (concat "[" (car ps) "]" p) (cdr ps)))))
+              (push prompt minibuffer-prompt-stack)
+              (setq prompt (fmt-prompt-stack prompt (cdr minibuffer-prompt-stack))))
+
+            (if (eq 't
+                    (catch 'exit
+                      (unwind-protect
+                          (if (> (recursion-depth) (minibuffer-depth))
+                              (let ((standard-output t)
+                                    (standard-input t))
+                                (read-minibuffer-internal prompt))
+                            (read-minibuffer-internal prompt))
+                        (pop minibuffer-prompt-stack))))
+
+                ;; Translate an "abort" (throw 'exit 't)
+                ;;  into a real quit
+                (signal 'quit '())
+              ;; return value
+              (let* ((val (progn (set-buffer buffer)
+                                 (if minibuffer-exit-hook
+                                     (run-hooks 'minibuffer-exit-hook))
+                                 (if (and (eq (char-after (point-min)) nil)
                                           default)
                                      default
                                    (buffer-string))))
                      (histval (if (and default (string= val ""))
                                   default
                                 val))
-                      (err nil))
-                 (if readp
-                     (condition-case e
-                         (let ((v (read-from-string val)))
-                           (if (< (cdr v) (length val))
-                               (save-match-data
-                                 (or (string-match "[ \t\n]*\\'" val (cdr v))
-                                     (error "Trailing garbage following expression"))))
-                           (setq v (car v))
-                           ;; total total kludge
-                           (if (stringp v) (setq v (list 'quote v)))
-                           (setq val v))
-                       (end-of-file
+                     (err nil))
+                (if readp
+                    (condition-case e
+                        (let ((v (read-from-string val)))
+                          (if (< (cdr v) (length val))
+                              (save-match-data
+                                (or (string-match "[ \t\n]*\\'" val (cdr v))
+                                    (error "Trailing garbage following expression"))))
+                          (setq v (car v))
+                          ;; total total kludge
+                          (if (stringp v) (setq v (list 'quote v)))
+                          (setq val v))
+                      (end-of-file
                        (setq err
                              '(input-error "End of input before end of expression")))
                       (error (setq err e))))
-                 ;; Add the value to the appropriate history list unless
-                 ;; it's already the most recent element, or it's only
-                 ;; two characters long.
-                 (if (and (symbolp minibuffer-history-variable)
-                          (boundp minibuffer-history-variable))
+                ;; Add the value to the appropriate history list unless
+                ;; it's already the most recent element, or it's only
+                ;; two characters long.
+                (if (and (symbolp minibuffer-history-variable)
+                         (boundp minibuffer-history-variable))
                     (let ((list (symbol-value minibuffer-history-variable)))
                       (or (eq list t)
                           (null val)
@@ -552,8 +552,8 @@ See also the variable `completion-highlight-first-word-only' for
                                (if minibuffer-history-uniquify
                                    (cons histval (remove histval list))
                                  (cons histval list))))))
-                 (if err (signal (car err) (cdr err)))
-                 val))))
+                (if err (signal (car err) (cdr err)))
+                val))))
       ;; stupid display code requires this for some reason
       (set-buffer buffer)
       (buffer-disable-undo buffer)
@@ -606,8 +606,8 @@ See also the variable `completion-highlight-first-word-only' for
          (goto-char (point-min))
          (if (re-search-forward
               (concat "^(setq minibuffer-max-depth "
-                       #r"\([0-9]+\|'?nil\|'?()\))"
-                       "\n")
+                      #r"\([0-9]+\|'?nil\|'?()\))"
+                      "\n")
               nil t)
              (delete-region (match-beginning 0 ) (match-end 0))
            ;; Must have been disabled by default.
@@ -641,57 +641,57 @@ See also the variable `completion-highlight-first-word-only' for
       ;;  gets set. In this case, we want that ^G to be interpreted
       ;;  as a normal character, and act just like typeahead.
       (if (and quit-flag (not unread-command-event))
-          (setq unread-command-event (character-to-event (quit-char))
-                quit-flag nil)))))
+         (setq unread-command-event (character-to-event (quit-char))
+               quit-flag nil)))))
 
 
 ;; Determines whether buffer-string is an exact completion
 (defun exact-minibuffer-completion-p (buffer-string)
   (cond ((not minibuffer-completion-table)
-         ;; Empty alist
-         nil)
-        ((vectorp minibuffer-completion-table)
-         (let ((tem (intern-soft buffer-string
-                                 minibuffer-completion-table)))
-           (if (or tem
-                   (and (string-equal buffer-string "nil")
-                        ;; intern-soft loses for 'nil
-                        (catch 'found
-                          (mapatoms #'(lambda (s)
+        ;; Empty alist
+        nil)
+       ((vectorp minibuffer-completion-table)
+        (let ((tem (intern-soft buffer-string
+                                minibuffer-completion-table)))
+          (if (or tem
+                  (and (string-equal buffer-string "nil")
+                       ;; intern-soft loses for 'nil
+                       (catch 'found
+                         (mapatoms #'(lambda (s)
                                        (if (string-equal
                                             (symbol-name s)
                                             buffer-string)
                                            (throw 'found t)))
                                    minibuffer-completion-table)
-                          nil)))
-               (if minibuffer-completion-predicate
-                   (funcall minibuffer-completion-predicate
-                            tem)
-                   t)
-               nil)))
-        ((and (consp minibuffer-completion-table)
-              ;;#### Emacs-Lisp truly sucks!
-              ;; lambda, autoload, etc
-              (not (symbolp (car minibuffer-completion-table))))
-         (if (not completion-ignore-case)
-             (assoc buffer-string minibuffer-completion-table)
-             (let ((s (upcase buffer-string))
-                   (tail minibuffer-completion-table)
-                   tem)
-               (while tail
-                 (setq tem (car (car tail)))
-                 (if (or (equal tem buffer-string)
-                         (equal tem s)
-                        (if tem (equal (upcase tem) s)))
-                     (setq s 'win
-                           tail nil)    ;exit
-                     (setq tail (cdr tail))))
-               (eq s 'win))))
-        (t
-         (funcall minibuffer-completion-table
-                  buffer-string
-                  minibuffer-completion-predicate
-                  'lambda)))
+                         nil)))
+              (if minibuffer-completion-predicate
+                  (funcall minibuffer-completion-predicate
+                           tem)
+                  t)
+              nil)))
+       ((and (consp minibuffer-completion-table)
+             ;;#### Emacs-Lisp truly sucks!
+             ;; lambda, autoload, etc
+             (not (symbolp (car minibuffer-completion-table))))
+        (if (not completion-ignore-case)
+            (assoc buffer-string minibuffer-completion-table)
+            (let ((s (upcase buffer-string))
+                  (tail minibuffer-completion-table)
+                  tem)
+              (while tail
+                (setq tem (car (car tail)))
+                (if (or (equal tem buffer-string)
+                        (equal tem s)
+                       (if tem (equal (upcase tem) s)))
+                    (setq s 'win
+                          tail nil)    ;exit
+                    (setq tail (cdr tail))))
+              (eq s 'win))))
+       (t
+        (funcall minibuffer-completion-table
+                 buffer-string
+                 minibuffer-completion-predicate
+                 'lambda)))
   )
 
 ;; 0 'none                 no possible completion
@@ -703,22 +703,22 @@ See also the variable `completion-highlight-first-word-only' for
 ;; 6 'uncompleted          no completion happened
 (defun minibuffer-do-completion-1 (buffer-string completion)
   (cond ((not completion)
-         'none)
-        ((eq completion t)
-         ;; exact and unique match
-         'unique)
-        (t
-         ;; It did find a match.  Do we match some possibility exactly now?
-         (let ((completedp (not (string-equal completion buffer-string))))
-           (if completedp
-               (progn
-                 ;; Some completion happened
-                 (erase-buffer)
-                 (insert completion)
-                 (setq buffer-string completion)))
-           (if (exact-minibuffer-completion-p buffer-string)
-               ;; An exact completion was possible
-               (if completedp
+        'none)
+       ((eq completion t)
+        ;; exact and unique match
+        'unique)
+       (t
+        ;; It did find a match.  Do we match some possibility exactly now?
+        (let ((completedp (not (string-equal completion buffer-string))))
+          (if completedp
+              (progn
+                ;; Some completion happened
+                (erase-buffer)
+                (insert completion)
+                (setq buffer-string completion)))
+          (if (exact-minibuffer-completion-p buffer-string)
+              ;; An exact completion was possible
+              (if completedp
 ;; Since no callers need to know the difference, don't bother
 ;;  with this (potentially expensive) discrimination.
 ;;                 (if (eq (try-completion completion
@@ -726,58 +726,58 @@ See also the variable `completion-highlight-first-word-only' for
 ;;                                         minibuffer-completion-predicate)
 ;;                         't)
 ;;                     'completed-exact-unique
-                       'completed-exact
+                      'completed-exact
 ;;                     )
-                   'exact)
-               ;; Not an exact match
-               (if completedp
-                   'completed
-                   'uncompleted))))))
+                  'exact)
+              ;; Not an exact match
+              (if completedp
+                  'completed
+                  'uncompleted))))))
 
 
 (defun minibuffer-do-completion (buffer-string)
   (let* ((completion (try-completion buffer-string
-                                     minibuffer-completion-table
-                                     minibuffer-completion-predicate))
-         (status (minibuffer-do-completion-1 buffer-string completion))
-         (last last-exact-completion))
+                                    minibuffer-completion-table
+                                    minibuffer-completion-predicate))
+        (status (minibuffer-do-completion-1 buffer-string completion))
+        (last last-exact-completion))
     (setq last-exact-completion nil)
     (cond ((eq status 'none)
-           ;; No completions
-           (ding nil 'no-completion)
-           (temp-minibuffer-message " [No match]"))
-          ((eq status 'unique)
-           )
-          (t
-           ;; It did find a match.  Do we match some possibility exactly now?
-           (if (not (string-equal completion buffer-string))
-               (progn
-                 ;; Some completion happened
-                 (erase-buffer)
-                 (insert completion)
-                 (setq buffer-string completion)))
-           (cond ((eq status 'exact)
-                  ;; If the last exact completion and this one were
-                  ;;  the same, it means we've already given a
-                  ;;  "Complete but not unique" message and that the
-                  ;;  user's hit TAB again, so now we give help.
-                  (setq last-exact-completion completion)
-                  (if (equal buffer-string last)
-                      (minibuffer-completion-help)))
-                 ((eq status 'uncompleted)
-                  (if completion-auto-help
-                      (minibuffer-completion-help)
-                      (temp-minibuffer-message " [Next char not unique]")))
-                 (t
-                  nil))))
+          ;; No completions
+          (ding nil 'no-completion)
+          (temp-minibuffer-message " [No match]"))
+         ((eq status 'unique)
+          )
+         (t
+          ;; It did find a match.  Do we match some possibility exactly now?
+          (if (not (string-equal completion buffer-string))
+              (progn
+                ;; Some completion happened
+                (erase-buffer)
+                (insert completion)
+                (setq buffer-string completion)))
+          (cond ((eq status 'exact)
+                 ;; If the last exact completion and this one were
+                 ;;  the same, it means we've already given a
+                 ;;  "Complete but not unique" message and that the
+                 ;;  user's hit TAB again, so now we give help.
+                 (setq last-exact-completion completion)
+                 (if (equal buffer-string last)
+                     (minibuffer-completion-help)))
+                ((eq status 'uncompleted)
+                 (if completion-auto-help
+                     (minibuffer-completion-help)
+                     (temp-minibuffer-message " [Next char not unique]")))
+                (t
+                 nil))))
     status))
 
 \f
 ;;;; completing-read
 
 (defun completing-read (prompt table
-                        &optional predicate require-match
-                                  initial-contents history default)
+                       &optional predicate require-match
+                                 initial-contents history default)
   "Read a string in the minibuffer, with completion.
 
 PROMPT is a string to prompt with; normally it ends in a colon and a space.
@@ -809,9 +809,9 @@ DEFAULT, if non-nil, will be returned when the user enters an empty
 Completion ignores case if the ambient value of
   `completion-ignore-case' is non-nil."
   (let ((minibuffer-completion-table table)
-        (minibuffer-completion-predicate predicate)
-        (minibuffer-completion-confirm (if (eq require-match 't) nil t))
-        (last-exact-completion nil)
+       (minibuffer-completion-predicate predicate)
+       (minibuffer-completion-confirm (if (eq require-match 't) nil t))
+       (last-exact-completion nil)
        ret)
     (setq ret (read-from-minibuffer prompt
                                    initial-contents
@@ -846,11 +846,11 @@ scroll the window of possible completions."
       (setq minibuffer-scroll-window nil))
   (let ((window minibuffer-scroll-window))
     (if (and window (windowp window) (window-buffer window)
-             (buffer-name (window-buffer window)))
+            (buffer-name (window-buffer window)))
        ;; If there's a fresh completion window with a live buffer
        ;;  and this command is repeated, scroll that window.
        (let ((obuf (current-buffer)))
-          (unwind-protect
+         (unwind-protect
              (progn
                (set-buffer (window-buffer window))
                (if (pos-visible-in-window-p (point-max) window)
@@ -859,7 +859,7 @@ scroll the window of possible completions."
                  ;; Else scroll down one frame.
                  (scroll-other-window)))
            (set-buffer obuf))
-          nil)
+         nil)
       (let ((status (minibuffer-do-completion (buffer-string))))
        (if (eq status 'none)
            nil
@@ -886,17 +886,17 @@ a repetition of this command will exit."
     ;; Short-cut -- don't call minibuffer-do-completion if we already
     ;;  have an (possibly nonunique) exact completion.
     (if (exact-minibuffer-completion-p buffer-string)
-        (throw 'exit nil))
+       (throw 'exit nil))
     (let ((status (minibuffer-do-completion buffer-string)))
       (if (or (eq status 'unique)
-              (eq status 'exact)
-              (if (or (eq status 'completed-exact)
-                      (eq status 'completed-exact-unique))
-                  (if minibuffer-completion-confirm
-                      (progn (temp-minibuffer-message " [Confirm]")
-                             nil)
-                      t)))
-          (throw 'exit nil)))))
+             (eq status 'exact)
+             (if (or (eq status 'completed-exact)
+                     (eq status 'completed-exact-unique))
+                 (if minibuffer-completion-confirm
+                     (progn (temp-minibuffer-message " [Confirm]")
+                            nil)
+                     t)))
+         (throw 'exit nil)))))
 
 
 (defun self-insert-and-exit ()
@@ -917,16 +917,16 @@ the character in question must be typed again)."
       (throw 'exit nil))
   (let ((buffer-string (buffer-string)))
     (if (exact-minibuffer-completion-p buffer-string)
-        (throw 'exit nil))
+       (throw 'exit nil))
     (let ((completion (if (not minibuffer-completion-table)
-                          t
-                          (try-completion buffer-string
-                                          minibuffer-completion-table
-                                          minibuffer-completion-predicate))))
+                         t
+                         (try-completion buffer-string
+                                         minibuffer-completion-table
+                                         minibuffer-completion-predicate))))
       (if (or (eq completion 't)
-              ;; Crockishly allow user to specify null string
-              (string-equal buffer-string ""))
-          (throw 'exit nil))
+             ;; Crockishly allow user to specify null string
+             (string-equal buffer-string ""))
+         (throw 'exit nil))
       (if completion ;; rewritten for I18N3 snarfing
          (temp-minibuffer-message " [incomplete; confirm]")
        (temp-minibuffer-message " [no completions; confirm]"))
@@ -934,12 +934,12 @@ the character in question must be typed again)."
                     (prog1
                         (next-command-event)
                       (setq quit-flag nil)))))
-        (cond ((equal event last-command-event)
-               (throw 'exit nil))
-              ((equal (quit-char) (event-to-character event))
-               ;; Minibuffer abort.
-               (throw 'exit t)))
-        (dispatch-event event)))))
+       (cond ((equal event last-command-event)
+              (throw 'exit nil))
+             ((equal (quit-char) (event-to-character event))
+              ;; Minibuffer abort.
+              (throw 'exit t)))
+       (dispatch-event event)))))
 \f
 ;;;; minibuffer-complete-word
 
@@ -953,22 +953,22 @@ is added, provided that matches some possible completion.
 Return nil if there is no valid completion, else t."
   (interactive)
   (let* ((buffer-string (buffer-string))
-         (completion (try-completion buffer-string
-                                     minibuffer-completion-table
-                                     minibuffer-completion-predicate))
-         (status (minibuffer-do-completion-1 buffer-string completion)))
+        (completion (try-completion buffer-string
+                                    minibuffer-completion-table
+                                    minibuffer-completion-predicate))
+        (status (minibuffer-do-completion-1 buffer-string completion)))
     (cond ((eq status 'none)
-           (ding nil 'no-completion)
-           (temp-minibuffer-message " [No match]")
-           nil)
-          ((eq status 'unique)
-           ;; New message, only in this new Lisp code
-           (temp-minibuffer-message " [Sole completion]")
-           t)
-          (t
-           (cond ((or (eq status 'uncompleted)
-                      (eq status 'exact))
-                  (let ((foo #'(lambda (s)
+          (ding nil 'no-completion)
+          (temp-minibuffer-message " [No match]")
+          nil)
+         ((eq status 'unique)
+          ;; New message, only in this new Lisp code
+          (temp-minibuffer-message " [Sole completion]")
+          t)
+         (t
+          (cond ((or (eq status 'uncompleted)
+                     (eq status 'exact))
+                 (let ((foo #'(lambda (s)
                                 (condition-case nil
                                     (if (try-completion
                                          (concat buffer-string s)
@@ -978,50 +978,50 @@ Return nil if there is no valid completion, else t."
                                           (goto-char (point-max))
                                           (insert s)
                                           t)
-                                       nil)
-                                   (error nil))))
-                        (char last-command-char))
-                    ;; Try to complete by adding a word-delimiter
-                    (or (and (characterp char) (> char 0)
-                             (funcall foo (char-to-string char)))
-                        (and (not (eq char ?\ ))
-                             (funcall foo " "))
-                        (and (not (eq char ?\-))
-                             (funcall foo "-"))
-                        (progn
-                          (if completion-auto-help
-                              (minibuffer-completion-help)
-                              ;; New message, only in this new Lisp code
+                                      nil)
+                                  (error nil))))
+                       (char last-command-char))
+                   ;; Try to complete by adding a word-delimiter
+                   (or (and (characterp char) (> char 0)
+                            (funcall foo (char-to-string char)))
+                       (and (not (eq char ?\ ))
+                            (funcall foo " "))
+                       (and (not (eq char ?\-))
+                            (funcall foo "-"))
+                       (progn
+                         (if completion-auto-help
+                             (minibuffer-completion-help)
+                             ;; New message, only in this new Lisp code
                            ;; rewritten for I18N3 snarfing
                            (if (eq status 'exact)
                                (temp-minibuffer-message
                                 " [Complete, but not unique]")
                              (temp-minibuffer-message " [Ambiguous]")))
-                          nil))))
-                 (t
-                  (erase-buffer)
-                  (insert completion)
-                  ;; First word-break in stuff found by completion
-                  (goto-char (point-min))
-                  (let ((len (length buffer-string))
-                        n)
-                    (if (and (< len (length completion))
-                             (catch 'match
-                               (setq n 0)
-                               (while (< n len)
-                                 (if (char-equal
-                                       (upcase (aref buffer-string n))
-                                       (upcase (aref completion n)))
-                                     (setq n (1+ n))
-                                     (throw 'match nil)))
-                               t)
-                             (progn
-                               (goto-char (point-min))
-                               (forward-char len)
-                               (re-search-forward "\\W" nil t)))
-                        (delete-region (point) (point-max))
-                        (goto-char (point-max))))
-                  t))))))
+                         nil))))
+                (t
+                 (erase-buffer)
+                 (insert completion)
+                 ;; First word-break in stuff found by completion
+                 (goto-char (point-min))
+                 (let ((len (length buffer-string))
+                       n)
+                   (if (and (< len (length completion))
+                            (catch 'match
+                              (setq n 0)
+                              (while (< n len)
+                                (if (char-equal
+                                      (upcase (aref buffer-string n))
+                                      (upcase (aref completion n)))
+                                    (setq n (1+ n))
+                                    (throw 'match nil)))
+                              t)
+                            (progn
+                              (goto-char (point-min))
+                              (forward-char len)
+                              (re-search-forward "\\W" nil t)))
+                       (delete-region (point) (point-max))
+                       (goto-char (point-max))))
+                 t))))))
 \f
 \f
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
@@ -1147,7 +1147,7 @@ This is not enabled by default because
     (let ((kludge-string (concat (buffer-string) string)))
       (if (or (and (fboundp 'ange-ftp-ftp-path)
                   (declare-fboundp (ange-ftp-ftp-path kludge-string)))
-              (and (fboundp 'efs-ftp-path) 
+              (and (fboundp 'efs-ftp-path)
                    (declare-fboundp (efs-ftp-path kludge-string))))
           ;; #### evil evil evil, but more so.
           string
@@ -1302,7 +1302,7 @@ If N is negative, find the next or Nth next match."
                        (if minibuffer-history-sexp-flag
                            (let ((print-level nil))
                              (prin1-to-string (nth (1- pos) history)))
-                            (nth (1- pos) history)))
+                           (nth (1- pos) history)))
          (setq n (+ n (if (< n 0) 1 -1)))))
     (setq minibuffer-history-position pos)
     (setq current-minibuffer-contents (buffer-string)
@@ -1312,7 +1312,7 @@ If N is negative, find the next or Nth next match."
       (insert (if minibuffer-history-sexp-flag
                  (let ((print-level nil))
                    (prin1-to-string elt))
-                  elt)))
+                 elt)))
       (goto-char (point-min)))
   (if (or (eq (car (car command-history)) 'previous-matching-history-element)
          (eq (car (car command-history)) 'next-matching-history-element))
@@ -1491,34 +1491,34 @@ Prompts with PROMPT.  Optional second arg DEFAULT is value to return if user
 enters an empty line.  If optional third arg REQUIRE-MATCH is non-nil,
 only existing buffer names are allowed."
   (let ((prompt (if default
-                    (format "%s(default %s) "
-                            (gettext prompt) (if (bufferp default)
+                   (format "%s(default %s) "
+                           (gettext prompt) (if (bufferp default)
                                                 (buffer-name default)
                                               default))
-                    prompt))
-        (alist (mapcar #'(lambda (b) (cons (buffer-name b) b))
-                       (buffer-list)))
-        result)
+                   prompt))
+       (alist (mapcar #'(lambda (b) (cons (buffer-name b) b))
+                      (buffer-list)))
+       result)
     (while (progn
-             (setq result (completing-read prompt alist nil require-match
-                                          nil 'buffer-history 
+            (setq result (completing-read prompt alist nil require-match
+                                          nil 'buffer-history
                                           (if (bufferp default)
                                               (buffer-name default)
                                             default)))
-             (cond ((not (equal result ""))
-                    nil)
-                   ((not require-match)
-                    (setq result default)
-                    nil)
-                   ((not default)
-                    t)
-                   ((not (get-buffer default))
-                    t)
-                   (t
-                    (setq result default)
-                    nil))))
+            (cond ((not (equal result ""))
+                   nil)
+                  ((not require-match)
+                   (setq result default)
+                   nil)
+                  ((not default)
+                   t)
+                  ((not (get-buffer default))
+                   t)
+                  (t
+                   (setq result default)
+                   nil))))
     (if (bufferp result)
-        (buffer-name result)
+       (buffer-name result)
       result)))
 
 (defun read-number (prompt &optional integers-only default-value)
@@ -1555,9 +1555,9 @@ If DEFAULT-VALUE is non-nil, return that if user enters an empty
 ;; Quote "$" as "$$" to get it past substitute-in-file-name
 (defun un-substitute-in-file-name (string)
   (let ((regexp "\\$")
-        (olen (length string))
-        new
-        n o ch)
+       (olen (length string))
+       new
+       n o ch)
     (if (not (string-match regexp string))
        string
       (setq n 1)
@@ -1583,13 +1583,13 @@ If DEFAULT-VALUE is non-nil, return that if user enters an empty
 ;; improve the performance of this operation.
 (defun minibuf-directory-files (dir &optional match-regexp files-only)
   (let ((want-file (or (eq files-only nil) (eq files-only t)))
-        (want-dirs (or (eq files-only nil) (not (eq files-only t)))))
+       (want-dirs (or (eq files-only nil) (not (eq files-only t)))))
     (delete nil
-            (mapcar (function (lambda (f)
-                                (if (file-directory-p (expand-file-name f dir))
-                                    (and want-dirs (file-name-as-directory f))
-                                  (and want-file f))))
-                    (delete "." (directory-files dir nil match-regexp))))))
+           (mapcar (function (lambda (f)
+                               (if (file-directory-p (expand-file-name f dir))
+                                   (and want-dirs (file-name-as-directory f))
+                                 (and want-file f))))
+                   (delete "." (directory-files dir nil match-regexp))))))
 
 
 (defun read-file-name-2 (history prompt dir default
@@ -1600,15 +1600,15 @@ If DEFAULT-VALUE is non-nil, return that if user enters an empty
   (setq dir (abbreviate-file-name dir t))
   (let* ((insert (cond ((and (not insert-default-directory)
                             (not initial-contents))
-                        "")
-                       (initial-contents
-                        (cons (un-substitute-in-file-name
+                       "")
+                      (initial-contents
+                       (cons (un-substitute-in-file-name
                               (concat dir initial-contents))
-                              (length dir)))
-                       (t
-                        (un-substitute-in-file-name dir))))
-         (val 
-                ;;  Hateful, broken, case-sensitive un*x
+                             (length dir)))
+                      (t
+                       (un-substitute-in-file-name dir))))
+        (val
+               ;;  Hateful, broken, case-sensitive un*x
 ;;;                 (completing-read prompt
 ;;;                                  completer
 ;;;                                  dir
@@ -1649,12 +1649,12 @@ If DEFAULT-VALUE is non-nil, return that if user enters an empty
 ;;;                 (set hist (cons e (cdr (symbol-value hist))))))))
 
     (cond ((not val)
-           (error "No file name specified"))
-          ((and default
-                (equal val (if (consp insert) (car insert) insert)))
-           default)
-          (t
-           (substitute-in-file-name val)))))
+          (error "No file name specified"))
+         ((and default
+               (equal val (if (consp insert) (car insert) insert)))
+          default)
+         (t
+          (substitute-in-file-name val)))))
 
 ;; #### this function should use minibuffer-completion-table
 ;; or something.  But that is sloooooow.
@@ -1680,7 +1680,7 @@ If DEFAULT-VALUE is non-nil, return that if user enters an empty
       (reset-buffer completion-buf)
       (let ((standard-output completion-buf))
        (display-completion-list
-         (minibuf-directory-files full nil (if dir-p 'directory))
+        (minibuf-directory-files full nil (if dir-p 'directory))
         :user-data dir-p
         :reference-buffer minibuf
         :activate-callback 'read-file-name-activate-callback)
@@ -1733,7 +1733,7 @@ If DEFAULT-VALUE is non-nil, return that if user enters an empty
                      initial-contents completer)))
 
 (defun read-file-name (prompt
-                       &optional dir default must-match initial-contents
+                      &optional dir default must-match initial-contents
                       history)
   "Read file name, prompting with PROMPT and completing in directory DIR.
 This will prompt with a dialog box if appropriate, according to
@@ -1752,7 +1752,7 @@ Fifth arg INITIAL-CONTENTS specifies text to start with.  If this is not
 Sixth arg HISTORY specifies the history list to use.  Default is
  `file-name-history'.
 DIR defaults to current buffer's directory default."
-  (read-file-name-1 
+  (read-file-name-1
    'file (or history 'file-name-history)
    prompt dir (or default
                  (and initial-contents
@@ -1767,7 +1767,7 @@ DIR defaults to current buffer's directory default."
    'read-file-name-internal))
 
 (defun read-directory-name (prompt
-                            &optional dir default must-match initial-contents
+                           &optional dir default must-match initial-contents
                            history)
   "Read directory name, prompting with PROMPT and completing in directory DIR.
 This will prompt with a dialog box if appropriate, according to
@@ -1795,85 +1795,85 @@ DIR defaults to current buffer's directory default."
            string))
       ;; Not doing environment-variable completion hack
       (let* ((orig (if (equal string "") nil string))
-             (sstring (if orig (substitute-in-file-name string) string))
-             (specdir (if orig (file-name-directory sstring) nil))
-             (name    (if orig (file-name-nondirectory sstring) string))
-             (direct  (if specdir (expand-file-name specdir dir) dir)))
-        ;; ~username completion
-        (if (and (fboundp 'user-name-completion-1)
-                 (string-match "^[~]" name))
-            (let ((user (substring name 1)))
-              (cond ((eq action 'lambda)
-                     (file-directory-p name))
-                    ((eq action 't)
-                     ;; all completions
-                     (mapcar #'(lambda (p) (concat "~" p))
-                             (user-name-all-completions user)))
-                    (t;; 'nil
-                     ;; complete
-                     (let* ((val+uniq (user-name-completion-1 user))
-                            (val  (car val+uniq))
-                            (uniq (cdr val+uniq)))
-                       (cond ((stringp val)
-                              (if uniq
-                                  (file-name-as-directory (concat "~" val))
-                                (concat "~" val)))
-                             ((eq val t)
-                              (file-name-as-directory name))
-                             (t nil))))))
-          (funcall completer
-                   action
-                   orig
-                   sstring
-                   specdir
-                   direct
-                   name)))
+            (sstring (if orig (substitute-in-file-name string) string))
+            (specdir (if orig (file-name-directory sstring) nil))
+            (name    (if orig (file-name-nondirectory sstring) string))
+            (direct  (if specdir (expand-file-name specdir dir) dir)))
+       ;; ~username completion
+       (if (and (fboundp 'user-name-completion-1)
+                (string-match "^[~]" name))
+           (let ((user (substring name 1)))
+             (cond ((eq action 'lambda)
+                    (file-directory-p name))
+                   ((eq action 't)
+                    ;; all completions
+                    (mapcar #'(lambda (p) (concat "~" p))
+                            (user-name-all-completions user)))
+                   (t;; 'nil
+                    ;; complete
+                    (let* ((val+uniq (user-name-completion-1 user))
+                           (val  (car val+uniq))
+                           (uniq (cdr val+uniq)))
+                      (cond ((stringp val)
+                             (if uniq
+                                 (file-name-as-directory (concat "~" val))
+                               (concat "~" val)))
+                            ((eq val t)
+                             (file-name-as-directory name))
+                            (t nil))))))
+         (funcall completer
+                  action
+                  orig
+                  sstring
+                  specdir
+                  direct
+                  name)))
       ;; An odd number of trailing $'s
       (let* ((start (match-beginning 3))
-             (env (substring string
-                             (cond ((= start (length string))
-                                    ;; "...$"
-                                    start)
-                                   ((= (aref string start) ?{)
-                                    ;; "...${..."
-                                    (1+ start))
-                                   (t
-                                    start))))
-             (head (substring string 0 (1- start)))
-             (alist #'(lambda ()
-                        (mapcar #'(lambda (x)
-                                    (cons (substring x 0 (string-match "=" x))
-                                          nil))
-                                process-environment))))
+            (env (substring string
+                            (cond ((= start (length string))
+                                   ;; "...$"
+                                   start)
+                                  ((= (aref string start) ?{)
+                                   ;; "...${..."
+                                   (1+ start))
+                                  (t
+                                   start))))
+            (head (substring string 0 (1- start)))
+            (alist #'(lambda ()
+                       (mapcar #'(lambda (x)
+                                   (cons (substring x 0 (string-match "=" x))
+                                         nil))
+                               process-environment))))
 
        (cond ((eq action 'lambda)
-               nil)
-              ((eq action 't)
-               ;; all completions
-               (mapcar #'(lambda (p)
+              nil)
+             ((eq action 't)
+              ;; all completions
+              (mapcar #'(lambda (p)
                           (if (and (> (length p) 0)
                                    ;;#### Unix-specific
                                    ;;####  -- need absolute-pathname-p
                                    (/= (aref p 0) ?/))
                               (concat "$" p)
-                             (concat head "$" p)))
-                       (all-completions env (funcall alist))))
-              (t ;; nil
-               ;; complete
-               (let* ((e (funcall alist))
-                      (val (try-completion env e)))
-                 (cond ((stringp val)
-                        (if (string-match "[^A-Za-z0-9_]" val)
-                            (concat head
-                                    "${" val
-                                    ;; completed uniquely?
-                                    (if (eq (try-completion val e) 't)
-                                        "}" ""))
-                            (concat head "$" val)))
-                       ((eql val 't)
-                        (concat head
-                                (un-substitute-in-file-name (getenv env))))
-                       (t nil))))))))
+                            (concat head "$" p)))
+                      (all-completions env (funcall alist))))
+             (t ;; nil
+              ;; complete
+              (let* ((e (funcall alist))
+                     (val (try-completion env e)))
+                (cond ((stringp val)
+                       (if (string-match "[^A-Za-z0-9_]" val)
+                           (concat head
+                                   "${" val
+                                   ;; completed uniquely?
+                                   (if (eq (try-completion val e) 't)
+                                       "}" ""))
+                           (concat head "$" val)))
+                      ((eql val 't)
+                       (concat head
+                               (un-substitute-in-file-name (getenv env))))
+                      (t nil))))))))
 
 
 (defun read-file-name-internal (string dir action)
@@ -1881,42 +1881,42 @@ DIR defaults to current buffer's directory default."
    string dir action
    #'(lambda (action orig string specdir dir name)
       (cond ((eq action 'lambda)
-             (if (not orig)
-                 nil
-               (let ((sstring (condition-case nil
-                                  (expand-file-name string)
-                                (error nil))))
-                 (if (not sstring)
-                     ;; Some pathname syntax error in string
-                     nil
-                     (file-exists-p sstring)))))
-            ((eq action 't)
-             ;; all completions
-             (mapcar #'un-substitute-in-file-name
-                     (if (string= name "")
-                         (delete "./" (file-name-all-completions "" dir))
-                       (file-name-all-completions name dir))))
-            (t;; nil
-             ;; complete
-             (let* ((d (or dir default-directory))
+            (if (not orig)
+                nil
+              (let ((sstring (condition-case nil
+                                 (expand-file-name string)
+                               (error nil))))
+                (if (not sstring)
+                    ;; Some pathname syntax error in string
+                    nil
+                    (file-exists-p sstring)))))
+           ((eq action 't)
+            ;; all completions
+            (mapcar #'un-substitute-in-file-name
+                    (if (string= name "")
+                        (delete "./" (file-name-all-completions "" dir))
+                      (file-name-all-completions name dir))))
+           (t;; nil
+            ;; complete
+            (let* ((d (or dir default-directory))
                    (val (file-name-completion name d)))
-               (if (and (eq val 't)
-                        (not (null completion-ignored-extensions)))
-                   ;;#### (file-name-completion "foo") returns 't
-                   ;;   when both "foo" and "foo~" exist and the latter
-                   ;;   is "pruned" by completion-ignored-extensions.
-                   ;; I think this is a bug in file-name-completion.
-                   (setq val (let ((completion-ignored-extensions '()))
-                               (file-name-completion name d))))
-               (if (stringp val)
-                   (un-substitute-in-file-name (if specdir
-                                                   (concat specdir val)
-                                                   val))
-                   (let ((tem (un-substitute-in-file-name string)))
-                     (if (not (equal tem orig))
-                         ;; substitute-in-file-name did something
-                         tem
-                         val)))))))))
+              (if (and (eq val 't)
+                       (not (null completion-ignored-extensions)))
+                  ;;#### (file-name-completion "foo") returns 't
+                  ;;   when both "foo" and "foo~" exist and the latter
+                  ;;   is "pruned" by completion-ignored-extensions.
+                  ;; I think this is a bug in file-name-completion.
+                  (setq val (let ((completion-ignored-extensions '()))
+                              (file-name-completion name d))))
+              (if (stringp val)
+                  (un-substitute-in-file-name (if specdir
+                                                  (concat specdir val)
+                                                  val))
+                  (let ((tem (un-substitute-in-file-name string)))
+                    (if (not (equal tem orig))
+                        ;; substitute-in-file-name did something
+                        tem
+                        val)))))))))
 
 (defun read-directory-name-internal (string dir action)
   (read-file-name-internal-1
@@ -1935,27 +1935,27 @@ DIR defaults to current buffer's directory default."
                         (mapcar fn
                                 ;; Wretched unix
                                 (delete "." l))))))
-        (cond ((eq action 'lambda)
-               ;; complete?
-               (if (not orig)
-                   nil
+       (cond ((eq action 'lambda)
+              ;; complete?
+              (if (not orig)
+                  nil
                 (file-directory-p string)))
-              ((eq action 't)
-               ;; all completions
-               (funcall dirs #'(lambda (n)
+             ((eq action 't)
+              ;; all completions
+              (funcall dirs #'(lambda (n)
                                 (un-substitute-in-file-name
                                  (file-name-as-directory n)))))
-              (t
-               ;; complete
-               (let ((val (try-completion
-                           name
-                           (funcall dirs
-                                    #'(lambda (n)
+             (t
+              ;; complete
+              (let ((val (try-completion
+                          name
+                          (funcall dirs
+                                   #'(lambda (n)
                                        (list (file-name-as-directory
                                               n)))))))
-                 (if (stringp val)
-                     (un-substitute-in-file-name (if specdir
-                                                     (concat specdir val)
+                (if (stringp val)
+                    (un-substitute-in-file-name (if specdir
+                                                    (concat specdir val)
                                                   val))
                   (let ((tem (un-substitute-in-file-name string)))
                     (if (not (equal tem orig))
@@ -2112,7 +2112,7 @@ whether it is a file(/result) or a directory (/result/)."
                   (when (featurep 'scrollbar)
                     (set-specifier scrollbar-width 0 (current-buffer)))
                   (setq truncate-lines t))))
-           
+
            (set-buffer filebuf)
            (add-local-hook 'completion-setup-hook rfcshookfun)
            (when file-p
@@ -2253,7 +2253,7 @@ whether it is a file(/result) or a directory (/result/)."
 Prompting with string PROMPT.
 If the user enters null input, return second argument DEFAULT-CODING-SYSTEM.
 DEFAULT-CODING-SYSTEM can be a string, symbol, or coding-system object."
-  (intern (completing-read prompt obarray 'find-coding-system t nil nil 
+  (intern (completing-read prompt obarray 'find-coding-system t nil nil
                           (cond ((symbolp default-coding-system)
                                  (symbol-name default-coding-system))
                                 ((coding-system-p default-coding-system)
index 1ea0aa0..cdc66a5 100644 (file)
@@ -31,7 +31,7 @@
 (defvar mode-motion-hook nil
   "Function or functions which are called whenever the mouse moves.
 Each function must take a single argument of the motion event.
-You should normally use this rather than `mouse-motion-handler', which 
+You should normally use this rather than `mouse-motion-handler', which
 does some additional window-system-dependent things.  This hook is local
 to every buffer, and should normally be set up by major-modes which want
 to use special highlighting.  Every time the mouse moves over a window,
index 6ac7c00..339812d 100644 (file)
@@ -643,7 +643,7 @@ Normally nil in most modes, since there is no process to display.")
   'global-mode-string
   " %[("
   (cons modeline-minor-mode-extent
-        (list "" 'mode-name 'minor-mode-alist))
+       (list "" 'mode-name 'minor-mode-alist))
   (cons modeline-narrowed-extent "%n")
   'modeline-process
   ")%]----"
index 362e712..237a165 100644 (file)
@@ -117,12 +117,12 @@ between point and mark."
   (interactive "P")
   ;; we fallback to the clipboard if the current selection is not existent
   (let ((text (or (get-selection-no-error 'PRIMARY   'UTF8_STRING)
-                  (get-selection-no-error 'PRIMARY   'STRING)
-                  (and check-cutbuffer-p (get-cutbuffer))
-                  (get-selection-no-error 'CLIPBOARD 'UTF8_STRING)
-                  (get-selection-no-error 'CLIPBOARD 'STRING)
-                  (error "no selection: PRIMARY or CLIPBOARD")
-                  )))
+                 (get-selection-no-error 'PRIMARY   'STRING)
+                 (and check-cutbuffer-p (get-cutbuffer))
+                 (get-selection-no-error 'CLIPBOARD 'UTF8_STRING)
+                 (get-selection-no-error 'CLIPBOARD 'STRING)
+                 (error "no selection: PRIMARY or CLIPBOARD")
+                 )))
     (cond (move-point-event
           (mouse-set-point move-point-event)
           (push-mark (point)))
@@ -1057,7 +1057,7 @@ at the initial click position."
             (not (= start end)))
        ;; I guess cutbuffers should do something with rectangles too.
        ;; does anybody use them?
-        (x-store-cutbuffer (buffer-substring start end)))))
+       (x-store-cutbuffer (buffer-substring start end)))))
 
 (defun mouse-track-activate-rectangular-selection ()
   (if (consp default-mouse-track-extent)
@@ -1264,7 +1264,7 @@ at the initial click position."
 ;;;      ;;
 ;;;      (if nil ; (eq default-mouse-track-type 'char)
 ;;;          (let ((after-end-p (and (not (eobp))
-;;;                                  (eolp)
+;;;                                  (eolp)
 ;;;                                  (> (point) (car result)))))
 ;;;            (if after-end-p
 ;;;                (progn
@@ -1522,17 +1522,17 @@ and `mode-motion-hook'."
          (glyph-extent (highlight-extent glyph-extent t))
          (t (highlight-extent nil nil)))
     (cond ((extentp help)
-           (or inhibit-help-echo
-               (eq help last-help-echo-object) ;save some time
+          (or inhibit-help-echo
+              (eq help last-help-echo-object) ;save some time
               (eq (selected-window) (minibuffer-window))
-               (let ((hprop (extent-property help 'help-echo)))
-                 (setq last-help-echo-object help)
-                 (or (stringp hprop)
-                     (setq hprop (funcall hprop help)))
-                 (and hprop (show-help-echo hprop)))))
+              (let ((hprop (extent-property help 'help-echo)))
+                (setq last-help-echo-object help)
+                (or (stringp hprop)
+                    (setq hprop (funcall hprop help)))
+                (and hprop (show-help-echo hprop)))))
          ((and (featurep 'toolbar)
-                (toolbar-button-p help)
-                (toolbar-button-enabled-p help))
+               (toolbar-button-p help)
+               (toolbar-button-enabled-p help))
           (or (not toolbar-help-enabled)
               (eq help last-help-echo-object) ;save some time
               (eq (selected-window) (minibuffer-window))
@@ -1541,7 +1541,7 @@ and `mode-motion-hook'."
                 (or (stringp hstring)
                     (setq hstring (funcall hstring help)))
                 (and hstring (show-help-echo hstring)))))
-          (last-help-echo-object
+         (last-help-echo-object
           (clear-help-echo)))
     (if mouse-grabbed-buffer (setq buffer mouse-grabbed-buffer))
     (if (and buffer (symbol-value-in-buffer 'mode-motion-hook buffer nil))
index 033d8c7..194cc6f 100644 (file)
              (ccl-embed-data op)
              (ccl-embed-data arg))
          (ccl-check-register arg cmd)
-         (ccl-embed-code (if read-flag 'read-jump-cond-expr-register 
+         (ccl-embed-code (if read-flag 'read-jump-cond-expr-register
                            'jump-cond-expr-register)
                          rrr 0)
          (ccl-embed-data op)
           (error "CCL: Invalid argument %s: %s" arg cmd)))
     (ccl-embed-code 'read-jump rrr ccl-loop-head))
   t)
-                           
+
 ;; Compile READ statement.
 (defun ccl-compile-read (cmd)
   (if (< (length cmd) 2)
                        add 1))
                (setq arg (cdr arg)
                      len (+ len add)))
-             (if mp 
+             (if mp
                  (cons (- len) result)
                result))))
     (setq arg (append (list (nth 0 cmd) (nth 1 cmd) (nth 2 cmd))
         (rrr (ash (logand code 255) -5))
         (cc (ash code -8)))
     (insert (format "%5d:[%s] " (1- ccl-current-ic) cmd))
-    (funcall (get cmd 'ccl-dump-function) rrr cc))) 
+    (funcall (get cmd 'ccl-dump-function) rrr cc)))
 
 (defun ccl-dump-set-register (rrr cc)
   (insert (format "r%d = r%d\n" rrr cc)))
     (insert (format "map-single r%d r%d map(%S)\n" RRR rrr id))))
 
 \f
-;; CCL emulation staffs 
+;; CCL emulation staffs
 
 ;; Not yet implemented.
 \f
@@ -1336,8 +1336,8 @@ WRITE :=
        | (write integer)
        ;; Write the byte sequence of `string' as is to the output
        ;; buffer.  It is encoded by binary coding system, thus,
-        ;; by this operation, you cannot write multibyte string
-        ;; as it is.
+       ;; by this operation, you cannot write multibyte string
+       ;; as it is.
        | (write string)
        ;; Same as: (write string)
        | string
@@ -1418,7 +1418,7 @@ ASSIGNMENT_OPERATOR :=
        ;; (REG <8= ARG) is the same as:
        ;;      ((REG <<= 8)
        ;;       (REG |= ARG))
-       | <8= 
+       | <8=
 
        ;; (REG >8= ARG) is the same as:
        ;;      ((r7 = (REG & 255))
index ca4cf20..3449e36 100644 (file)
       (name plane final)
       (make-charset
        name (concat "CNS 11643 Plane " plane " (Chinese traditional)")
-       `(registry 
-         ,(concat "CNS11643[.-]\\(.*[.-]\\)?" plane "$")
-         dimension 2
-         chars 94
-         final ,final
-         graphic 0))
+       `(registry
+        ,(concat "CNS11643[.-]\\(.*[.-]\\)?" plane "$")
+        dimension 2
+        chars 94
+        final ,final
+        graphic 0))
       (modify-syntax-entry   name "w")
       (modify-category-entry name ?t)
       ))
 
 \f
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
-;;; Chinese GB2312 (simplified) 
+;;; Chinese GB2312 (simplified)
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;
 
 ;; (make-coding-system
       (insert-buffer-substring buf from to))
     (declare-fboundp (encode-hz-region 1 (point-max)))
     nil))
-          
+
 (set-language-info-alist
  "Chinese-GB" '((setup-function . setup-chinese-gb-environment-internal)
                (charset chinese-gb2312 sisheng)
index c3a79f4..374094d 100644 (file)
@@ -81,9 +81,9 @@
    32  ?\e$(C"F\e(B 32  32  ?\e$B"#\e(B 32  ?\e$B"e\e(B ?\e$A!V\e(B ?\e$A!\\e(B ?\e$A!]\e(B ?\e,L \e(B  32  ?\e,A0\e(B  ?\e,A2\e(B  ?\e,A7\e(B  ?\e,Aw\e(B
    ?\e$(G#D\e(B 32  32  ?\e,Lq\e(B  32  32  32  32  32  32  32  32  32  32  32  ?\e$(G#E\e(B
    32  32  ?\e$(G#G\e(B ?\e,L!\e(B  32  32  32  32  32  32  32  32  ?\e$(G#F\e(B 32  32  ?\e,A)\e(B
-   ?\e,Ln\e(B  ?\e,LP\e(B  ?\e,LQ\e(B  ?\e,Lf\e(B  ?\e,LT\e(B  ?\e,LU\e(B  ?\e,Ld\e(B  ?\e,LS\e(B  ?\e,Le\e(B  ?\e,LX\e(B  ?\e,LY\e(B  ?\e,LZ\e(B  ?\e,L[\e(B  ?\e,L\\e(B  ?\e,L]\e(B  ?\e,L^\e(B 
-   ?\e,L_\e(B  ?\e,Lo\e(B  ?\e,L`\e(B  ?\e,La\e(B  ?\e,Lb\e(B  ?\e,Lc\e(B  ?\e,LV\e(B  ?\e,LR\e(B  ?\e,Ll\e(B  ?\e,Lk\e(B  ?\e,LW\e(B  ?\e,Lh\e(B  ?\e,Lm\e(B  ?\e,Li\e(B  ?\e,Lg\e(B  ?\e,Lj\e(B 
-   ?\e,LN\e(B  ?\e,L0\e(B  ?\e,L1\e(B  ?\e,LF\e(B  ?\e,L4\e(B  ?\e,L5\e(B  ?\e,LD\e(B  ?\e,L3\e(B  ?\e,LE\e(B  ?\e,L8\e(B  ?\e,L9\e(B  ?\e,L:\e(B  ?\e,L;\e(B  ?\e,L<\e(B  ?\e,L=\e(B  ?\e,L>\e(B 
+   ?\e,Ln\e(B  ?\e,LP\e(B  ?\e,LQ\e(B  ?\e,Lf\e(B  ?\e,LT\e(B  ?\e,LU\e(B  ?\e,Ld\e(B  ?\e,LS\e(B  ?\e,Le\e(B  ?\e,LX\e(B  ?\e,LY\e(B  ?\e,LZ\e(B  ?\e,L[\e(B  ?\e,L\\e(B  ?\e,L]\e(B  ?\e,L^\e(B
+   ?\e,L_\e(B  ?\e,Lo\e(B  ?\e,L`\e(B  ?\e,La\e(B  ?\e,Lb\e(B  ?\e,Lc\e(B  ?\e,LV\e(B  ?\e,LR\e(B  ?\e,Ll\e(B  ?\e,Lk\e(B  ?\e,LW\e(B  ?\e,Lh\e(B  ?\e,Lm\e(B  ?\e,Li\e(B  ?\e,Lg\e(B  ?\e,Lj\e(B
+   ?\e,LN\e(B  ?\e,L0\e(B  ?\e,L1\e(B  ?\e,LF\e(B  ?\e,L4\e(B  ?\e,L5\e(B  ?\e,LD\e(B  ?\e,L3\e(B  ?\e,LE\e(B  ?\e,L8\e(B  ?\e,L9\e(B  ?\e,L:\e(B  ?\e,L;\e(B  ?\e,L<\e(B  ?\e,L=\e(B  ?\e,L>\e(B
    ?\e,L?\e(B  ?\e,LO\e(B  ?\e,L@\e(B  ?\e,LA\e(B  ?\e,LB\e(B  ?\e,LC\e(B  ?\e,L6\e(B  ?\e,L2\e(B  ?\e,LL\e(B  ?\e,LK\e(B  ?\e,L7\e(B  ?\e,LH\e(B  ?\e,LM\e(B  ?\e,LI\e(B  ?\e,LG\e(B  ?\e,LJ\e(B ]
   "Cyrillic KOI8-R decoding table.")
 
       (setq i (1+ i)))
     table)
   "Cyrillic ALTERNATIVNYJ encoding table.")
-  
+
 )
 
 
index 8162db3..818c3c6 100644 (file)
@@ -68,7 +68,7 @@
       do (modify-category-entry `[japanese-jisx0208 ,row] ?C))
 (loop for char in '(?\e$B!<\e(B ?\e$B!+\e(B ?\e$B!,\e(B)
       do (modify-category-entry char ?K)
-         (modify-category-entry char ?H))
+        (modify-category-entry char ?H))
 (loop for char in '(?\e$B!3\e(B ?\e$B!4\e(B ?\e$B!5\e(B ?\e$B!6\e(B ?\e$B!7\e(B ?\e$B!8\e(B ?\e$B!9\e(B ?\e$B!:\e(B ?\e$B!;\e(B)
       do (modify-category-entry char ?C))
 (modify-category-entry 'japanese-jisx0212 ?C)
 ;; locally.
 
 (defvar aletter (concat "\\(" ascii-char "\\|" kanji-char "\\)"))
-(defvar kanji-space-insertable (concat 
+(defvar kanji-space-insertable (concat
           "\e$B!"\e(B" aletter                   "\\|"
           "\e$B!#\e(B" aletter                   "\\|"
           aletter "\e$B!J\e(B"                   "\\|"
index 8037ee8..9b07eee 100644 (file)
@@ -1,4 +1,4 @@
-;; kinsoku.el -- Kinsoku (line wrap) processing for XEmacs/Mule
+;; kinsoku.el -- Kinsoku (line wrap) processing for XEmacs/Mule -*- coding: iso-2022-7bit; -*-
 
 ;; Copyright (C) 1997 Free Software Foundation, Inc.
 ;; This file is part of Mule (MULtilingual Enhancement of XEmacs).
   "EOL kinsoku for GB2312.")
 (defvar kinsoku-big5-bol
   (concat  "\e$(0!"!#!$!%!&!'!(!)!*!+!,!-!.!/!0!1!2\e(B"
-          "\e$(0!3!4!5!6!7!8!9!:!;!<!=!?!A!C!E!G!I!K\e(B"
-          "\e$(0!M!O!Q\e(B       \e$(0!S!U!W!Y![!]!_!a!c!e!g!i!k!q\e(B"
-          "\e$(0"#"$"%"&"'"(")"*"+","2"3"4"j"k"l"x%7\e(B")
+          "\e$(0!3!4!5!6!7!8!9!:!;!<!=!?!A!C!E!G!I!K\e(B"
+          "\e$(0!M!O!Q\e(B       \e$(0!S!U!W!Y![!]!_!a!c!e!g!i!k!q\e(B"
+          "\e$(0"#"$"%"&"'"(")"*"+","2"3"4"j"k"l"x%7\e(B")
   "BOL kinsoku for BIG5.")
 (defvar kinsoku-big5-eol
   (concat "\e$(0!>!@!B!D!F!H!J!L!N!P!R!T!V!X!Z!\!^!`!b\e(B"
-         "\e$(0!d!f!h!j!k!q!p"i"j"k"n"x$u$v$w$x$y$z${\e(B"
-         "\e$(0$|$}$~%!%"%#%$%%%&%'%(%)%*%+%:\e(B")
+         "\e$(0!d!f!h!j!k!q!p"i"j"k"n"x$u$v$w$x$y$z${\e(B"
+         "\e$(0$|$}$~%!%"%#%$%%%&%'%(%)%*%+%:\e(B")
   "EOL kinsoku for BIG5.")
 
 (define-category ?s "Kinsoku forbidden start of line characters")
@@ -256,7 +256,7 @@ point\e$B$,9TKv6XB'$K?($l$k>l9g$O9T$r=L$a$F!"6XB'$K?($l$J$$E@$rC5$9!#\e(B
 (defun kinsoku-process-extend ()
   "Move point forward to a permissable for line-breaking.
 \e$B9T$r?-$P$7$F6XB'$K?($l$J$$E@$X0\F0$9$k!#\e(B"
-  (let ((max-column (+ fill-column 
+  (let ((max-column (+ fill-column
                       (if (and (numberp kinsoku-extend-limit)
                                (>= kinsoku-extend-limit 0))
                           kinsoku-extend-limit
@@ -270,7 +270,7 @@ point\e$B$,9TKv6XB'$K?($l$k>l9g$O9T$r=L$a$F!"6XB'$K?($l$J$$E@$rC5$9!#\e(B
                (not (eolp))
                (or (kinsoku-eol-p)
                    (kinsoku-bol-p)
-                   ;;; don't break in the middle of an English word
+                   ;;; don't break in the middle of an English word
                    (and (char-in-category-p ch1 ?a)
                         (setq ch2 (char-before))
                         (char-in-category-p ch2 ?a)
index a120e2a..527dfac 100644 (file)
@@ -281,7 +281,7 @@ Each element is a list of a charset, a designator, and maybe a doc string.")
 ;;; be buffer-local---strategy for dealing with this: check all $language.el
 ;;; files and also mule-base/$language-utils.el files for variables set;
 ;;; these should be made buffer local and some kind of a- or p-list of vars
-;;; to be set for a language environment created. 
+;;; to be set for a language environment created.
 (defvar word-across-newline "\\(\\cj\\|\\cc\\|\\ct\\)"
   "Regular expression of such characters which can be a word across newline.")
 
index 84112cc..673dedc 100644 (file)
@@ -58,15 +58,15 @@ BUFFER defaults to the current buffer if omitted."
 (defun charsets-in-string (string)
   "Return a list of the charsets in STRING."
   (let ((i 0)
-       (len (length string))
-       prev-charset charset list)
+       (len (length string))
+       prev-charset charset list)
     (while (< i len)
       (setq charset (char-charset (aref string i)))
       (if (not (eq prev-charset charset))
-         (progn
-           (setq prev-charset charset)
-           (or (memq charset list)
-               (setq list (cons charset list)))))
+         (progn
+           (setq prev-charset charset)
+           (or (memq charset list)
+               (setq list (cons charset list)))))
       (setq i (1+ i)))
     list))
 
index 0faf689..883f9e4 100644 (file)
@@ -75,26 +75,26 @@ They means `lf', `crlf', and `cr' respectively."
       (setq eol-type (cond ((or (eq eol-type 'unix)
                                (eq eol-type 'lf))
                            'eol-lf)
-                           ((or (eq eol-type 'dos)
+                          ((or (eq eol-type 'dos)
                                (eq eol-type 'crlf))
                            'eol-crlf)
-                           ((or (eq eol-type 'mac)
+                          ((or (eq eol-type 'mac)
                                (eq eol-type 'cr))
                            'eol-cr)
-                           (t eol-type))))
+                          (t eol-type))))
   (let ((orig-eol-type (coding-system-eol-type coding-system)))
     (if (null orig-eol-type)
-        (if (not eol-type)
-            coding-system
-          (coding-system-property coding-system eol-type))
+       (if (not eol-type)
+           coding-system
+         (coding-system-property coding-system eol-type))
       (let ((base (coding-system-base coding-system)))
-        (if (not eol-type)
-            base
-          (if (eq eol-type orig-eol-type)
-              coding-system
-            (setq orig-eol-type (coding-system-eol-type base))
-            (if (null orig-eol-type)
-                (coding-system-property base eol-type))))))))
+       (if (not eol-type)
+           base
+         (if (eq eol-type orig-eol-type)
+             coding-system
+           (setq orig-eol-type (coding-system-eol-type base))
+           (if (null orig-eol-type)
+               (coding-system-property base eol-type))))))))
 
 ;; (defun coding-system-change-text-conversion (coding-system coding)
 ;;   "Return a coding system which differs from CODING-SYSTEM in text conversion.
@@ -138,7 +138,7 @@ Meaningful values for KEY include
   setup-function     value is a function to call to switch to this
                        language environment.
   exit-function      value is a function to call to leave this
-                       language environment.
+                       language environment.
   coding-system      value is a list of coding systems that are good
                        for saving text written in this language environment.
                        This list serves as suggestions to the user;
@@ -226,8 +226,8 @@ ALIST is an alist of KEY and INFO values.  See the documentation of
     ;; Set up menu items for this language env.
     (let ((doc (assq 'documentation alist)))
       (when doc
-        ;; (define-key-after describe-map (vector (intern lang-env))
-        ;;   (cons lang-env 'describe-specified-language-support) t)
+       ;; (define-key-after describe-map (vector (intern lang-env))
+       ;;   (cons lang-env 'describe-specified-language-support) t)
        (when (featurep 'menubar)
          (eval-after-load
              "menubar-items.elc"
@@ -249,7 +249,7 @@ ALIST is an alist of KEY and INFO values.  See the documentation of
          (vector ,lang-env
                  '(set-language-environment ,lang-env)
                  t))))
-    
+
     (while alist
       (set-language-info lang-env (car (car alist)) (cdr (car alist)))
       (setq alist (cdr alist)))))
@@ -278,7 +278,7 @@ This file contains a list of libraries of Emacs input methods (LEIM)
 in the format of Lisp expression for registering each input method.
 Emacs loads this file at startup time.")
 
-(defvar leim-list-header (format 
+(defvar leim-list-header (format
 ";;; %s -- list of LEIM (Library of Emacs Input Method)
 ;;
 ;; This file contains a list of LEIM (Library of Emacs Input Method)
@@ -901,7 +901,7 @@ ISO-8859-5 and ISO-2022-JP are different coding categories.)"
           (if (memq eol-type '(lf crlf cr unix dos mac))
               (coding-system-change-eol-conversion default-coding eol-type)
             default-coding))
-          ;; (setq default-sendmail-coding-system default-coding)
+         ;; (setq default-sendmail-coding-system default-coding)
          (while priority
            (unless (memq (setq category (car categories)) checked-categories)
              (set-coding-category-system category (car priority))
@@ -909,7 +909,7 @@ ISO-8859-5 and ISO-2022-JP are different coding categories.)"
            (setq priority (cdr priority)
                  categories (cdr categories)))
          (set-coding-priority-list (nreverse checked-categories))
-          ;; (update-coding-systems-internal)
+         ;; (update-coding-systems-internal)
          ))))
 
 ;; Print all arguments with `princ', then print "\n".
@@ -993,11 +993,11 @@ ISO-8859-5 and ISO-2022-JP are different coding categories.)"
                           (car l)
                           (coding-system-mnemonic (car l))
                           (coding-system-doc-string (car l))))
-            ;; (let ((aliases (coding-system-get (car l) 'alias-coding-systems)))
-            ;;   (when aliases
-            ;;     (princ "\t")
-            ;;     (princ (cons 'alias: (cdr aliases)))
-            ;;     (terpri)))
+           ;; (let ((aliases (coding-system-get (car l) 'alias-coding-systems)))
+           ;;   (when aliases
+           ;;     (princ "\t")
+           ;;     (princ (cons 'alias: (cdr aliases)))
+           ;;     (terpri)))
            (setq l (cdr l))))))))
 \f
 ;;; Charset property
@@ -1060,7 +1060,7 @@ It can be retrieved with `(get-char-code-property CHAR PROPNAME)'."
 ;;       (setq desc (or (cdr (assq char iso-2022-control-alist))
 ;;                      (char-to-string char)))
 ;;       (let ((i 1)
-;;             (len (length str))) 
+;;             (len (length str)))
 ;;         (while (< i len)
 ;;           (setq char (aref str i))
 ;;           (if (>= char 128)
@@ -1090,14 +1090,14 @@ It can be retrieved with `(get-char-code-property CHAR PROPNAME)'."
 ;;       ;; To exclude such tailing bytes, we at first encode one-char
 ;;       ;; string and two-char string, then check how many bytes at the
 ;;       ;; tail of both encoded strings are the same.
-;; 
+;;
 ;;       (setq enc1 (string-as-unibyte (encode-coding-string str1 coding-system))
 ;;             i1 (length enc1)
 ;;             enc2 (string-as-unibyte (encode-coding-string str2 coding-system))
 ;;             i2 (length enc2))
 ;;       (while (and (> i1 0) (= (aref enc1 (1- i1)) (aref enc2 (1- i2))))
 ;;         (setq i1 (1- i1) i2 (1- i2)))
-;; 
+;;
 ;;       ;; Now (substring enc1 i1) and (substring enc2 i2) are the same,
 ;;       ;; and they are the extra control sequences at the tail to
 ;;       ;; exclude.
index 45279b0..3bc3146 100644 (file)
@@ -1,4 +1,4 @@
-;;; mule-help.el --- Mule-ized Help functions 
+;;; mule-help.el --- Mule-ized Help functions
 
 ;; Copyright (C) 1997 by Free Software Foundation, Inc.
 
@@ -24,7 +24,7 @@
 
 ;;; Commentary:
 
-;; 
+;;
 
 ;;; Code:
 
index 8e077d4..27fa5b2 100644 (file)
 ;;;  By default, Japanese is set as the primary environment.
 ;;;  You can change primary environment in `./lisp/site-init.el by
 ;;;  `set-primary-environment'.  For instance,
-;;;    (set-primary-environment 'chinese)
+;;;    (set-primary-environment 'chinese)
 ;;;  makes Chinese the primary environment.
 ;;;  If you are still not satisfied with the settings, you can
 ;;;  override them after the above line.  For instance,
-;;;    (set-default-buffer-file-coding-system 'big5)
+;;;    (set-default-buffer-file-coding-system 'big5)
 ;;;  makes big5 be used for file I/O by default.
 ;;;  If you are not satisfied with other default settings in this file,
 ;;;  override any of them also in `./lisp/site-init.el'.  For instance,
@@ -97,12 +97,12 @@ then `set-language-environment' is called with LANGUAGE-ENVIRONMENT.")
       (load (format "%s%s/locale-start"
                    (locate-data-directory "start-files")
                    lang) t t)))
-  
+
   (when current-language-environment
     ;; Translate remaining args on command line using file-name-coding-system
     (loop for arg in-ref command-line-args-left do
          (setf arg (decode-coding-string arg file-name-coding-system)))
-    
+
     ;; rman seems to be incompatible with encoded text
     (and-boundp 'Manual-use-rosetta-man
       (setq Manual-use-rosetta-man nil))
@@ -116,7 +116,7 @@ then `set-language-environment' is called with LANGUAGE-ENVIRONMENT.")
        (with-fboundp 'setenv
         (setenv "LC_MESSAGES" "C")
         (setenv "LC_TIME"     "C")))))
-  
+
   ;; Register available input methods by loading LEIM list file.
   (load "leim-list.el" 'noerror 'nomessage 'nosuffix)
   )
index d063fe3..deff049 100644 (file)
@@ -91,7 +91,7 @@ achieved by using a national variant roman font to display ASCII."
 
        ;; Chinese fonts
        "-*-*-medium-r-*--*-gb2312.1980-*"
-       
+
        ;; Use One font specification for CNS chinese
        ;; Too many variations in font naming
        "-*-fixed-medium-r-*--*-cns11643*-*"
@@ -101,14 +101,14 @@ achieved by using a national variant roman font to display ASCII."
        ;; "-*-fixed-medium-r-*--*-cns11643.5-0"
        ;; "-*-fixed-medium-r-*--*-cns11643.6-0"
        ;; "-*-fixed-medium-r-*--*-cns11643.7-0"
-       
+
        "-*-fixed-medium-r-*--*-big5*-*"
        "-*-fixed-medium-r-*--*-sisheng_cwnn-0"
 
        ;; Other fonts
-       
+
        ;; "-*-fixed-medium-r-*--*-viscii1.1-1"
-       
+
        ;; "-*-fixed-medium-r-*--*-mulearabic-0"
        ;; "-*-fixed-medium-r-*--*-mulearabic-1"
        ;; "-*-fixed-medium-r-*--*-mulearabic-2"
index e3a6bea..8c8ea3f 100644 (file)
@@ -68,7 +68,7 @@
 ;; rx' == (tis620-to-thai-xtis-second-byte-bitpattern rx)
 ;; r3 == "no vower nor tone"
 ;; r4 == (charset-id 'thai-xtis)
-;; 
+;;
 ;;          |               input (= r0)
 ;;   state  |--------------------------------------------
 ;;          |  consonant  |    vowel    |    tone
@@ -82,9 +82,9 @@
 ;;  r1 == C | WRITE r1,r2 | WRITE r1,r2 | WRITE r1,r2|r0'
 ;;  r2 == V | r1 = r0     | WRITE r0,r3 | r1 = r2 = 0
 ;;          | r2 = 0      | r1 = r2 = 0 |
-;; 
-;; 
-;;          |               input (= r0) 
+;;
+;;
+;;          |               input (= r0)
 ;;   state  |-----------------------------------------
 ;;          |    symbol   |    ASCII    |     EOF
 ;; ---------+-------------+-------------+-------------
index e6133e6..ef67303 100644 (file)
@@ -39,7 +39,7 @@
    64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
    80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
    96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111
-   112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 
+   112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
    ?\e,2U\e(B ?\e,2!\e(B ?\e,2"\e(B ?\e,2#\e(B ?\e,2$\e(B ?\e,2%\e(B ?\e,2&\e(B ?\e,2'\e(B ?\e,2(\e(B ?\e,2)\e(B ?\e,2*\e(B ?\e,2+\e(B ?\e,2,\e(B ?\e,2-\e(B ?\e,2.\e(B ?\e,2/\e(B
    ?\e,20\e(B ?\e,21\e(B ?\e,22\e(B ?\e,25\e(B ?\e,2~\e(B ?\e,2>\e(B ?\e,26\e(B ?\e,27\e(B ?\e,28\e(B ?\e,2v\e(B ?\e,2w\e(B ?\e,2o\e(B ?\e,2|\e(B ?\e,2{\e(B ?\e,2x\e(B ?\e,2O\e(B
    ?\e,2u\e(B ?\e,1!\e(B ?\e,1"\e(B ?\e,1#\e(B ?\e,1$\e(B ?\e,1%\e(B ?\e,1&\e(B ?\e,1'\e(B ?\e,1(\e(B ?\e,1)\e(B ?\e,1*\e(B ?\e,1+\e(B ?\e,1,\e(B ?\e,1-\e(B ?\e,1.\e(B ?\e,1/\e(B
@@ -77,7 +77,7 @@ Both tables are indexed by the position code of Vietnamese characters.")
    64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79
    80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95
    96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111
-   112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 
+   112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127
    ?\e,2`\e(B ?\e,2d\e(B ?\e,2c\e(B ?\e,2a\e(B ?\e,2U\e(B ?\e,2#\e(B ?\e,2'\e(B ?\e,2h\e(B ?\e,2k\e(B ?\e,2(\e(B ?\e,2i\e(B ?\e,2)\e(B ?\e,2.\e(B ?\e,2l\e(B ?\e,2o\e(B ?\e,2n\e(B
    ?\e,2m\e(B ?\e,28\e(B ?\e,2r\e(B ?\e,2v\e(B ?\e,2u\e(B ?\e,2s\e(B ?\e,2w\e(B ?\e,25\e(B ?\e,26\e(B ?\e,27\e(B ?\e,2^\e(B ?\e,2>\e(B ?\e,2~\e(B ?\e,2y\e(B ?\e,2|\e(B ?\e,2{\e(B
    160 ?\e,2e\e(B ?\e,2b\e(B ?\e,2j\e(B ?\e,2t\e(B ?\e,2=\e(B ?\e,2_\e(B ?\e,2p\e(B ?\e,1e\e(B ?\e,1b\e(B ?\e,1j\e(B ?\e,1t\e(B ?\e,1>\e(B ?\e,1y\e(B ?\e,1p\e(B ?\e,2"\e(B
@@ -174,7 +174,7 @@ Both tables are indexed by the position code of Vietnamese characters.")
       (if (r0 < 128)
          ;; ASCII
          (write-read-repeat r0)
-       ;; not ASCII 
+       ;; not ASCII
        (if (r0 != ,leading-code-private-11)
            ;; not Vietnamese
            (write-read-repeat r0)
index f4ae507..6b21af7 100644 (file)
@@ -59,8 +59,8 @@ ADDRESS specifies a standard multicast address \"dest/port/ttl\":
  ttl is the time-to-live (15 for site, 63 for region and 127 for world).
 
 WARNING: it is *strongly* recommended to avoid using groups beginning with
-         224 or 239. Such groups are considered 'admin' groups, and may
-         behave in a surprising way ..."
+        224 or 239. Such groups are considered 'admin' groups, and may
+        behave in a surprising way ..."
   (let (dest port ttl)
     ;; We check only the general form of the multicast address.
     ;; The rest will be handled by the internal function.
index 0895dd6..89ea3aa 100644 (file)
@@ -26,7 +26,7 @@
 ;;; Comments:
 ;; This file provides some additional functionality not worth
 ;; implementing in C.
-;; 
+;;
 ;; Note to myself: number.el is a stupid name :(
 
 \f
@@ -134,7 +134,7 @@ This is a convenience function analogous to `float'."
 (defun canonical-valuation (number)
   "Return the canonical valuation of NUMBER."
   (cond ((archimedeanp number)
-         (abs number))))
+        (abs number))))
 
 \f
 (provide 'number)
index 4ba7ac1..2475b7a 100644 (file)
@@ -57,7 +57,7 @@ If OLDVAR was bound and NEWVAR was not, Set NEWVAR to OLDVAR.
 
 Note: Use this before any other references (defvar/defcustom) to NEWVAR."
   (let ((needs-setting (and (boundp oldvar) (not (boundp newvar))))
-        (value (and (boundp oldvar) (symbol-value oldvar))))
+       (value (and (boundp oldvar) (symbol-value oldvar))))
      (defvaralias oldvar newvar)
      (make-obsolete-variable oldvar newvar)
      (and needs-setting (set newvar value))))
@@ -227,7 +227,7 @@ set Info-directory-list.")
 ;; Can't make this obsolete.  easymenu depends on it.
 (make-compatible 'add-menu 'add-submenu)
 
-(define-obsolete-function-alias 'package-get-download-menu 
+(define-obsolete-function-alias 'package-get-download-menu
   'package-ui-download-menu)
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;; minibuffer
@@ -262,7 +262,7 @@ set Info-directory-list.")
 
 (make-obsolete-variable 'executing-macro 'executing-kbd-macro)
 
-(define-compatible-function-alias 'interactive-form 
+(define-compatible-function-alias 'interactive-form
   'function-interactive) ;GNU 21.1
 (define-compatible-function-alias 'assq-delete-all
   'remassq) ;GNU 21.1
@@ -325,7 +325,7 @@ to the selected device."
     (when ms
       (declare-fboundp (play-media-stream ms device)))))
 (make-obsolete #'play-sound-file
-               "use `make-media-stream' and `play-media-stream' instead.")
+              "use `make-media-stream' and `play-media-stream' instead.")
 
 
 ;;;;;;;;;;;;;;;;;;;;;;;;;;;; window-system objects
index b528223..f45c667 100644 (file)
@@ -163,28 +163,28 @@ Possible values for TYPE are:
        (let ((path-list (paths-decode-directory-path env-value 'drop-empties)))
          (cond ((eq type 'site)
                 (while path-list
-                  (if (equal (file-name-nondirectory 
+                  (if (equal (file-name-nondirectory
                               (directory-file-name (car path-list)))
                              "site-packages")
                       (setq top-dir (car path-list)))
                   (setq path-list (cdr path-list))))
                ((eq type 'sxemacs)
                 (while path-list
-                  (if (equal (file-name-nondirectory 
+                  (if (equal (file-name-nondirectory
                               (directory-file-name (car path-list)))
                              "sxemacs-packages")
                       (setq top-dir (car path-list)))
                   (setq path-list (cdr path-list))))
                ((eq type 'std)
                 (while path-list
-                  (if (equal (file-name-nondirectory 
+                  (if (equal (file-name-nondirectory
                               (directory-file-name (car path-list)))
                              "xemacs-packages")
                       (setq top-dir (car path-list)))
                   (setq path-list (cdr path-list))))
                ((eq type 'mule)
                 (while path-list
-                  (if (equal (file-name-nondirectory 
+                  (if (equal (file-name-nondirectory
                               (directory-file-name (car path-list)))
                              "mule-packages")
                       (setq top-dir (car path-list)))
@@ -212,28 +212,28 @@ Possible values for TYPE are:
                                 (packages-compute-package-locations user-init-directory)))))
          (cond ((eq type 'site)
                 (while path-list
-                  (if (equal (file-name-nondirectory 
+                  (if (equal (file-name-nondirectory
                               (directory-file-name (car path-list)))
                              "site-packages")
                       (setq top-dir (car path-list)))
                   (setq path-list (cdr path-list))))
                ((eq type 'sxemacs)
                 (while path-list
-                  (if (equal (file-name-nondirectory 
+                  (if (equal (file-name-nondirectory
                               (directory-file-name (car path-list)))
                              "sxemacs-packages")
                       (setq top-dir (car path-list)))
                   (setq path-list (cdr path-list))))
                ((eq type 'std)
                 (while path-list
-                  (if (equal (file-name-nondirectory 
+                  (if (equal (file-name-nondirectory
                               (directory-file-name (car path-list)))
                              "xemacs-packages")
                       (setq top-dir (car path-list)))
                   (setq path-list (cdr path-list))))
                ((eq type 'mule)
                 (while path-list
-                  (if (equal (file-name-nondirectory 
+                  (if (equal (file-name-nondirectory
                               (directory-file-name (car path-list)))
                              "mule-packages")
                       (setq top-dir (car path-list)))
@@ -331,7 +331,7 @@ all else fails.  As a side effect of installing packages under
                ;; neither can the user, nothing left to do except barf. :-(
                (error 'search-failed
                       (format
-                       "Can't find suitable installation directory for package: %s" 
+                       "Can't find suitable installation directory for package: %s"
                        package))))))))))
 
 (defun package-admin-get-manifest-file (pkg-topdir package)
@@ -358,7 +358,7 @@ is the top-level directory under which the package was installed."
          (if (eq system-type 'windows-nt)
              (setq case-fold-search t))
 
-         (setq regexp (concat "\\bpkginfo" 
+         (setq regexp (concat "\\bpkginfo"
                               (char-to-string directory-sep-char)
                               "MANIFEST\\...*"))
 
@@ -373,7 +373,7 @@ is the top-level directory under which the package was installed."
                ;; Here, we don't use a single regexp because we want to search
                ;; the directories for a package name in a particular order.
                (if (catch 'done
-                     (let ((dirs '("lisp" "man")) 
+                     (let ((dirs '("lisp" "man"))
                            rexp)
                        (while dirs
                          (setq rexp (concat "\\b" (car dirs)
@@ -487,25 +487,25 @@ is the top-level directory under which the package was installed."
 This is a feeble attempt at making a portable rmdir."
   (setq directory (file-name-as-directory directory))
   (let ((files (directory-files directory nil nil nil t))
-        (dirs (directory-files directory nil nil nil 'dirs)))
+       (dirs (directory-files directory nil nil nil 'dirs)))
     (while dirs
       (if (not (member (car dirs) '("." "..")))
-          (let ((dir (expand-file-name (car dirs) directory)))
-            (condition-case err
-                (if (file-symlink-p dir) ;; just in case, handle symlinks
-                    (delete-file dir)
-                  (package-admin-rmtree dir))
-              (file-error
-               (message "%s: %s: \"%s\"" (nth 1 err) (nth 2 err) (nth 3 err)))))
-        (setq dirs (cdr dirs))))
+         (let ((dir (expand-file-name (car dirs) directory)))
+           (condition-case err
+               (if (file-symlink-p dir) ;; just in case, handle symlinks
+                   (delete-file dir)
+                 (package-admin-rmtree dir))
+             (file-error
+              (message "%s: %s: \"%s\"" (nth 1 err) (nth 2 err) (nth 3 err)))))
+       (setq dirs (cdr dirs))))
     (while files
       (condition-case err
-          (delete-file (expand-file-name (car files) directory))
-        (file-error
-         (message "%s: %s: \"%s\"" (nth 1 err) (nth 2 err) (nth 3 err))))
+         (delete-file (expand-file-name (car files) directory))
+       (file-error
+        (message "%s: %s: \"%s\"" (nth 1 err) (nth 2 err) (nth 3 err))))
       (setq files (cdr files)))
     (condition-case err
-        (delete-directory directory)
+       (delete-directory directory)
       (file-error
        (message "%s: %s: \"%s\"" (nth 1 err) (nth 2 err) (nth 3 err))))))
 
index 4b4a2db..3f650cd 100644 (file)
@@ -33,7 +33,7 @@
 ;;     Retrieve a package and any other required packages from an archive
 ;;
 ;;
-;; Note (JV): Most of this no longer applies!  
+;; Note (JV): Most of this no longer applies!
 ;; Note (SY): Definitely no longer applies, but I'm leaving these
 ;;            comments here because there are some nifty ideas here.
 ;;
@@ -168,7 +168,7 @@ one version of a package available.")
   :group 'package-get)
 
 ;;;###autoload
-(defcustom package-get-package-index-file-location 
+(defcustom package-get-package-index-file-location
   (car (split-path (or (getenv "EMACSPACKAGEPATH") user-init-directory)))
   "*The directory where the package-index file can be found."
   :type 'directory
@@ -425,7 +425,7 @@ and remote access is likely in the near future."
   "Update an entry in `package-get-base'."
   (let ((existing (assq (car entry) package-get-base)))
     (if existing
-        (setcdr existing (cdr entry))
+       (setcdr existing (cdr entry))
       (setq package-get-base (cons entry package-get-base)))))
 
 (defun package-get-locate-file (file &optional nil-if-not-found no-remote)
@@ -437,7 +437,7 @@ If NO-REMOTE is non-nil never search remote locations."
   (if (file-name-absolute-p file)
       file
     (let ((site package-get-remote)
-          (expanded nil))
+         (expanded nil))
       (when site
        (unless (and no-remote (caar (list site)))
          (let ((expn (package-get-remote-filename (car (list site)) file)))
@@ -445,11 +445,11 @@ If NO-REMOTE is non-nil never search remote locations."
                (setq site nil
                      expanded expn)))))
       (or expanded
-          (and (not nil-if-not-found)
-               file)))))
+         (and (not nil-if-not-found)
+              file)))))
 
 (defun package-get-locate-index-file (no-remote)
-  "Locate the package-get index file.  
+  "Locate the package-get index file.
 
 Do not return remote paths if NO-REMOTE is non-nil.  If the index
 file doesn't exist in `package-get-package-index-file-location', ask
@@ -464,7 +464,7 @@ template."
                              package-get-package-index-file-location))
            (progn
              (save-excursion
-               (set-buffer 
+               (set-buffer
                 (find-file-noselect (expand-file-name
                                      package-get-base-filename
                                      package-get-package-index-file-location)))
@@ -508,13 +508,13 @@ Unless FORCE-CURRENT is non-nil never try to update the database."
   (interactive
    (let ((dflt (package-get-locate-index-file nil)))
      (list (read-file-name "Load package-get database: "
-                           (file-name-directory dflt)
-                           dflt
-                           t
-                           (file-name-nondirectory dflt)))))
+                          (file-name-directory dflt)
+                          dflt
+                          t
+                          (file-name-nondirectory dflt)))))
   (setq db-file (expand-file-name (or db-file
-                                      (package-get-locate-index-file
-                                        (not force-current)))))
+                                     (package-get-locate-index-file
+                                        (not force-current)))))
   (if (not (file-exists-p db-file))
       (error 'file-error
             (format "Package-get database file `%s' does not exist" db-file)))
@@ -523,11 +523,11 @@ Unless FORCE-CURRENT is non-nil never try to update the database."
             (format "Package-get database file `%s' not readable" db-file)))
   (let ((buf (get-buffer-create "*package database*")))
     (unwind-protect
-        (save-excursion
-          (set-buffer buf)
-          (erase-buffer buf)
-          (insert-file-contents-literally db-file)
-          (package-get-update-base-from-buffer buf)
+       (save-excursion
+         (set-buffer buf)
+         (erase-buffer buf)
+         (insert-file-contents-literally db-file)
+         (package-get-update-base-from-buffer buf)
          (if (file-remote-p db-file)
              (package-get-maybe-save-index db-file)))
       (kill-buffer buf))))
@@ -560,21 +560,21 @@ START and END in the current buffer."
   (save-excursion
     (goto-char start)
     (if (not (re-search-forward "^(package-get-update-base-entry" nil t))
-        (error 'search-failed
+       (error 'search-failed
               "Buffer does not contain package-get database entries"))
     (beginning-of-line)
     (let ((count 0))
       (while (and (< (point) end)
-                  (re-search-forward "^(package-get-update-base-entry" nil t))
-        (beginning-of-line)
-        (let ((entry (read (current-buffer))))
-          (if (or (not (consp entry))
-                  (not (eq (car entry) 'package-get-update-base-entry)))
-              (error 'syntax-error
+                 (re-search-forward "^(package-get-update-base-entry" nil t))
+       (beginning-of-line)
+       (let ((entry (read (current-buffer))))
+         (if (or (not (consp entry))
+                 (not (eq (car entry) 'package-get-update-base-entry)))
+             (error 'syntax-error
                     "Invalid package-get database entry found"))
-          (package-get-update-base-entry
-           (car (cdr (car (cdr entry)))))
-          (setq count (1+ count))))
+         (package-get-update-base-entry
+          (car (cdr (car (cdr entry)))))
+         (setq count (1+ count))))
       (message "Got %d package-get database entries" count))))
 
 ;;;###autoload
@@ -586,28 +586,28 @@ Note: This database will be unsigned of course."
   (package-get-require-base t)
   (let ((buf (get-buffer-create "*package database*")))
     (unwind-protect
-        (save-excursion
-          (set-buffer buf)
-          (erase-buffer buf)
-          (goto-char (point-min))
-          (let ((entries package-get-base) entry plist)
-            (insert ";; Package Index file -- Do not edit manually.\n")
-            (insert ";;;@@@\n")
-            (while entries
-              (setq entry (car entries))
-              (setq plist (car (cdr entry)))
-              (insert "(package-get-update-base-entry (quote\n")
-              (insert (format "(%s\n" (symbol-name (car entry))))
-              (while plist
-                (insert (format "  %s%s %S\n"
-                                (if (eq plist (car (cdr entry))) "(" " ")
-                                (symbol-name (car plist))
-                                (car (cdr plist))))
-                (setq plist (cdr (cdr plist))))
-              (insert "))\n))\n;;;@@@\n")
-              (setq entries (cdr entries))))
-          (insert ";; Package Index file ends here\n")
-          (write-region (point-min) (point-max) file))
+       (save-excursion
+         (set-buffer buf)
+         (erase-buffer buf)
+         (goto-char (point-min))
+         (let ((entries package-get-base) entry plist)
+           (insert ";; Package Index file -- Do not edit manually.\n")
+           (insert ";;;@@@\n")
+           (while entries
+             (setq entry (car entries))
+             (setq plist (car (cdr entry)))
+             (insert "(package-get-update-base-entry (quote\n")
+             (insert (format "(%s\n" (symbol-name (car entry))))
+             (while plist
+               (insert (format "  %s%s %S\n"
+                               (if (eq plist (car (cdr entry))) "(" " ")
+                               (symbol-name (car plist))
+                               (car (cdr plist))))
+               (setq plist (cdr (cdr plist))))
+             (insert "))\n))\n;;;@@@\n")
+             (setq entries (cdr entries))))
+         (insert ";; Package Index file ends here\n")
+         (write-region (point-min) (point-max) file))
       (kill-buffer buf))))
 
 (defun package-get-interactive-package-query (get-version package-symbol)
@@ -707,7 +707,7 @@ Returns nil upon error."
              (if (not (setq fetched-packages
                             (package-get-all reqd-name reqd-version
                                              fetched-packages
-                                              install-dir)))
+                                             install-dir)))
                  (throw 'exit nil))))
        (setq this-requires (cdr this-requires))))
     fetched-packages))
@@ -720,32 +720,32 @@ package provides that functionality.  Returns the list of packages
 required by PACKAGES."
   (package-get-require-base t)
   (let ((orig-packages packages)
-        dependencies provided)
+       dependencies provided)
     (while packages
       (let* ((package (car packages))
-             (the-package (package-get-info-find-package
-                           package-get-base package))
-             (this-package (package-get-info-version
-                            the-package nil))
-             (this-requires (package-get-info-prop this-package 'requires))
-             (new-depends   (set-difference
-                             (mapcar
-                              #'(lambda (reqd)
-                                  (let* ((reqd-package (package-get-package-provider reqd))
-                                         (reqd-name    (car reqd-package)))
-                                    (if (null reqd-name)
-                                        (error 'search-failed
+            (the-package (package-get-info-find-package
+                          package-get-base package))
+            (this-package (package-get-info-version
+                           the-package nil))
+            (this-requires (package-get-info-prop this-package 'requires))
+            (new-depends   (set-difference
+                            (mapcar
+                             #'(lambda (reqd)
+                                 (let* ((reqd-package (package-get-package-provider reqd))
+                                        (reqd-name    (car reqd-package)))
+                                   (if (null reqd-name)
+                                       (error 'search-failed
                                               (format "Unable to find a provider for %s" reqd)))
-                                    reqd-name))
-                              this-requires)
-                             dependencies))
-             (this-provides (package-get-info-prop this-package 'provides)))
-        (setq dependencies
-              (union dependencies new-depends))
-        (setq provided
-              (union provided (union (list package) this-provides)))
-        (setq packages
-              (union new-depends (cdr packages)))))
+                                   reqd-name))
+                             this-requires)
+                            dependencies))
+            (this-provides (package-get-info-prop this-package 'provides)))
+       (setq dependencies
+             (union dependencies new-depends))
+       (setq provided
+             (union provided (union (list package) this-provides)))
+       (setq packages
+             (union new-depends (cdr packages)))))
     (set-difference dependencies orig-packages)))
 
 (defun package-get-load-package-file (lispdir file)
@@ -896,7 +896,7 @@ current buffer."
               (when (memq item (package-get-info (caar pkgs) field))
                 (setq results (push (caar pkgs) results)))
               (setq pkgs (cdr pkgs)))))
-         (t 
+         (t
           (error 'wrong-type-argument field)))
     (if (interactive-p)
        (if arg
@@ -932,8 +932,8 @@ successfully installed but errors occurred during initialization, or
          (package-get-info-version
           (package-get-info-find-package package-get-base
                                          package) version))
-         (latest (package-get-info-prop this-package 'version))
-         (installed (package-get-key package :version))
+        (latest (package-get-info-prop this-package 'version))
+        (installed (package-get-key package :version))
         (found nil)
         (search-dir package-get-remote)
         (base-filename (package-get-info-prop this-package 'filename))
@@ -941,7 +941,7 @@ successfully installed but errors occurred during initialization, or
         filenames full-package-filename)
     (if (and (equal (package-get-info package 'category) "mule")
             (not (featurep 'mule)))
-       (error 'invalid-state 
+       (error 'invalid-state
               "Mule packages can't be installed with a non-Mule SXEmacs"))
     (if (null this-package)
        (if package-get-remote
@@ -959,18 +959,18 @@ successfully installed but errors occurred during initialization, or
     ;; If they asked for the latest using version=nil, don't get an older
     ;; version than we already have.
     (if installed
-        (if (> (if (stringp installed)
-                   (string-to-number installed)
-                 installed)
-               (if (stringp latest)
-                   (string-to-number latest)
-                 latest))
-            (if (not (null version))
-                (warn "Installing %s package version %s, you had a newer version %s"
+       (if (> (if (stringp installed)
+                  (string-to-number installed)
+                installed)
+              (if (stringp latest)
+                  (string-to-number latest)
+                latest))
+           (if (not (null version))
+               (warn "Installing %s package version %s, you had a newer version %s"
                  package latest installed)
-              (warn "Skipping %s package, you have a newer version %s"
+             (warn "Skipping %s package, you have a newer version %s"
                package installed)
-              (throw 'skip-update t))))
+             (throw 'skip-update t))))
 
     ;; Contrive a list of possible package filenames.
     ;; Ugly.  Is there a better way to do this?
@@ -1219,8 +1219,8 @@ lead to Emacs accessing remote sites."
       (setq packages (cdr packages)))
     (when (interactive-p)
       (if found
-          (message "%S" found)
-        (message "No appropriate package found")))
+         (message "%S" found)
+       (message "No appropriate package found")))
     found))
 
 (defun package-get-ever-installed-p (pkg &optional notused)
index 667a1ba..b77e71b 100644 (file)
@@ -42,7 +42,7 @@ new ones."
   :tag "Install Location"
   :type '(choice (const :tag "Automatic" nil)
                 (directory)))
-                
+
 (defcustom pui-list-verbose t
   "*If non-nil, display verbose info in the package list buffer."
   :group 'pui
@@ -77,7 +77,7 @@ Set this to `nil' to use the `default' face."
 Set this to `nil' to use the `default' face."
    :group 'pui
    :type 'face)
-   
+
 (defcustom pui-info-buffer "*Packages*"
   "*Buffer to use for displaying package information."
   :group 'pui
@@ -123,7 +123,7 @@ Set this to `nil' to use the `default' face."
   (let ((m (make-sparse-keymap)))
     (set-keymap-name m 'pui-package-keymap)
     (define-key m 'button2 'pui-toggle-package-event)
-;; We use a popup menu    
+;; We use a popup menu
     (define-key m 'button3 'pui-popup-context-sensitive)
     m)
   "Keymap to use over package names/descriptions.")
@@ -139,7 +139,7 @@ Set this to `nil' to use the `default' face."
 (defun package-ui-add-site (site)
   "Add site to package-get-remote and possibly offer to update package list."
   (let ((had-none (null package-get-remote)))
-    (setq package-get-remote site)    
+    (setq package-get-remote site)
     (when (and had-none package-get-was-current
               (y-or-n-p "Update Package list?"))
       (setq package-get-was-current nil)
@@ -153,46 +153,46 @@ Set this to `nil' to use the `default' face."
 (defun package-ui-download-menu ()
   "Build the `Add Download Site' menu."
   (mapcar (lambda (site)
-           (vector (car site)
-                   `(if (equal package-get-remote (quote ,(cdr site)))
-                     (setq package-get-remote nil)
-                     (package-ui-add-site (quote ,(cdr site))))
+           (vector (car site)
+                   `(if (equal package-get-remote (quote ,(cdr site)))
+                     (setq package-get-remote nil)
+                     (package-ui-add-site (quote ,(cdr site))))
                    ;; I've used radio buttons so that only a single
                    ;; site can be selected, but they are in fact
                    ;; toggles.  SY.
-                   :style 'radio
-                   :selected `(equal package-get-remote (quote ,(cdr site)))))
-         package-get-download-sites))
+                   :style 'radio
+                   :selected `(equal package-get-remote (quote ,(cdr site)))))
+         package-get-download-sites))
 
 ;;;###autoload
 (defun package-ui-pre-release-download-menu ()
   "Build the 'Pre-Release Download Sites' menu."
   (mapcar (lambda (site)
-           (vector (car site)
-                   `(if (equal package-get-remote (quote ,(cdr site)))
-                     (setq package-get-remote nil)
-                     (package-ui-add-site (quote ,(cdr site))))
+           (vector (car site)
+                   `(if (equal package-get-remote (quote ,(cdr site)))
+                     (setq package-get-remote nil)
+                     (package-ui-add-site (quote ,(cdr site))))
                    ;; I've used radio buttons so that only a single
                    ;; site can be selected, but they are in fact
                    ;; toggles.  SY.
-                   :style 'radio
-                   :selected `(equal package-get-remote (quote ,(cdr site)))))
-         package-get-pre-release-download-sites))
+                   :style 'radio
+                   :selected `(equal package-get-remote (quote ,(cdr site)))))
+         package-get-pre-release-download-sites))
 
 ;;;###autoload
 (defun package-ui-site-release-download-menu ()
   "Build the 'Site Release Download Sites' menu."
   (mapcar (lambda (site)
-           (vector (car site)
-                   `(if (equal package-get-remote (quote ,(cdr site)))
-                     (setq package-get-remote nil)
-                     (package-ui-add-site (quote ,(cdr site))))
+           (vector (car site)
+                   `(if (equal package-get-remote (quote ,(cdr site)))
+                     (setq package-get-remote nil)
+                     (package-ui-add-site (quote ,(cdr site))))
                    ;; I've used radio buttons so that only a single
                    ;; site can be selected, but they are in fact
                    ;; toggles.  SY.
-                   :style 'radio
-                   :selected `(equal package-get-remote (quote ,(cdr site)))))
-         package-get-site-release-download-sites))
+                   :style 'radio
+                   :selected `(equal package-get-remote (quote ,(cdr site)))))
+         package-get-site-release-download-sites))
 
 ;;;###autoload
 (defun pui-set-local-package-get-directory ()
@@ -200,7 +200,7 @@ Set this to `nil' to use the `default' face."
 Note that no provision is made for saving any changes made by this function.
 It exists mainly as a convenience for one-time package installations from
 disk."
-  (interactive) 
+  (interactive)
   (let ((dir (read-directory-name
              "New package binary directory to add? "
              nil nil t)))
@@ -217,15 +217,15 @@ disk."
 (defun pui-package-symbol-char (pkg-sym version)
   (progn
     (if (package-get-info-find-package packages-package-list pkg-sym)
-        (let ((installed (package-get-key pkg-sym :version)))
-          (if (>= (if (stringp installed)
-                      (string-to-number installed)
-                    installed)
-                  (if (stringp version)
-                      (string-to-number version)
-                    version))
-              (list " " pui-up-to-date-package-face)
-            (list "*" pui-outdated-package-face)))
+       (let ((installed (package-get-key pkg-sym :version)))
+         (if (>= (if (stringp installed)
+                     (string-to-number installed)
+                   installed)
+                 (if (stringp version)
+                     (string-to-number version)
+                   version))
+             (list " " pui-up-to-date-package-face)
+           (list "*" pui-outdated-package-face)))
       (list "-" pui-uninstalled-package-face))))
 
 (defun pui-update-package-display (extent &optional pkg-sym version)
@@ -295,7 +295,7 @@ and whether or not it is up-to-date."
       (setq pui-selected-packages
            (delete pkg-sym pui-selected-packages)))
     (pui-update-package-display extent pkg-sym)))
-  
+
 
 (defun pui-toggle-package-delete-key ()
   "Select/unselect package for removal, using the keyboard."
@@ -331,7 +331,7 @@ and whether or not it is up-to-date."
 (defun pui-install-selected-packages ()
   "Install selected packages."
   (interactive)
-  (let ((tmpbuf "*Packages-To-Remove*") 
+  (let ((tmpbuf "*Packages-To-Remove*")
        do-delete)
     (when pui-deleted-packages
       (save-window-excursion
@@ -345,7 +345,7 @@ and whether or not it is up-to-date."
        (setq tmpbuf (get-buffer-create tmpbuf))
        (display-buffer tmpbuf)
        (setq do-delete (yes-or-no-p "Remove these packages? "))
-       (kill-buffer tmpbuf))       
+       (kill-buffer tmpbuf))
       (when do-delete
        (message "Deleting selected packages ...") (sit-for 0)
        (mapcar (lambda (pkg)
@@ -353,8 +353,8 @@ and whether or not it is up-to-date."
                   pkg (package-admin-get-install-dir pkg)))
                (nreverse pui-deleted-packages))
        (message "Packages deleted"))))
-        
-  (let ((tmpbuf "*Packages-To-Install*") 
+
+  (let ((tmpbuf "*Packages-To-Install*")
        do-install)
     (if pui-selected-packages
        (progn
@@ -385,7 +385,7 @@ and whether or not it is up-to-date."
                (if (catch 'done
                      (mapcar (lambda (pkg)
                                (if (not (package-get pkg nil nil
-                                                      pui-package-install-dest-dir))
+                                                     pui-package-install-dest-dir))
                                    (throw 'done nil)))
                              (nreverse pui-selected-packages))
                      t)
@@ -404,26 +404,26 @@ and whether or not it is up-to-date."
   (let ((tmpbuf "*Required-Packages*") do-select)
     (if pui-selected-packages
        (let ((dependencies
-               (delq nil (mapcar
-                          (lambda (pkg)
-                            (let ((installed
-                                   (package-get-key pkg :version))
-                                  (current
-                                   (package-get-info-prop
-                                    (package-get-info-version
-                                     (package-get-info-find-package
-                                      package-get-base pkg) nil)
-                                    'version)))
-                              (if (or (null installed)
-                                     (< (if (stringp installed)
-                                         (string-to-number installed)
-                                       installed)
-                                     (if (stringp current)
-                                         (string-to-number current)
-                                       current)))
-                                  pkg
-                                nil)))
-                          (package-get-dependencies pui-selected-packages)))))
+              (delq nil (mapcar
+                         (lambda (pkg)
+                           (let ((installed
+                                  (package-get-key pkg :version))
+                                 (current
+                                  (package-get-info-prop
+                                   (package-get-info-version
+                                    (package-get-info-find-package
+                                     package-get-base pkg) nil)
+                                   'version)))
+                             (if (or (null installed)
+                                    (< (if (stringp installed)
+                                        (string-to-number installed)
+                                      installed)
+                                    (if (stringp current)
+                                        (string-to-number current)
+                                      current)))
+                                 pkg
+                               nil)))
+                         (package-get-dependencies pui-selected-packages)))))
          ;; Don't change window config when asking the user if he really
          ;; wants to add the packages.  We do this to avoid messing up
          ;; the window configuration if errors occur (we don't want to
@@ -433,7 +433,7 @@ and whether or not it is up-to-date."
            (with-output-to-temp-buffer tmpbuf
              (display-completion-list (sort
                                        (mapcar #'(lambda (pkg)
-                                                    (symbol-name pkg))
+                                                   (symbol-name pkg))
                                                dependencies)
                                        'string<)
                                       :activate-callback nil
@@ -444,13 +444,13 @@ and whether or not it is up-to-date."
            (setq do-select (y-or-n-p "Select these packages? "))
            (kill-buffer tmpbuf))
          (if do-select
-              (progn
-                (setq pui-selected-packages
-                      (union pui-selected-packages dependencies))
-                (map-extents #'(lambda (extent maparg)
-                                 (pui-update-package-display extent))
-                             nil nil nil nil nil 'pui)
-                (message "added dependencies"))
+             (progn
+               (setq pui-selected-packages
+                     (union pui-selected-packages dependencies))
+               (map-extents #'(lambda (extent maparg)
+                                (pui-update-package-display extent))
+                            nil nil nil nil nil 'pui)
+               (message "added dependencies"))
              (clear-message)))
       (error 'invalid-operation
             "No packages have been selected!"))))
@@ -481,11 +481,11 @@ Installed Upstream Ver: %s  Available Upstream Ver: %s
 Maintainer : %s
 Released : %s
 Required Packages : %s\n\n"
-                                     pkg-sym inst-auth-ver auth-ver maintainer 
+                                     pkg-sym inst-auth-ver auth-ver maintainer
                                      date req))
                (set-extent-property extent 'balloon-help balloon)))
-         (format 
-          "Installed upstream ver: %s  Available upstream ver: %s" 
+         (format
+          "Installed upstream ver: %s  Available upstream ver: %s"
           inst-auth-ver auth-ver)))))
 
 (defun pui-display-info (&optional no-error event)
@@ -495,7 +495,7 @@ Designed to be called interactively (from a keypress)."
   (let (extent)
     (save-excursion
       (beginning-of-line)
-      (if (setq extent         (extent-at (point) (current-buffer) 'pui))
+      (if (setq extent (extent-at (point) (current-buffer) 'pui))
          (message (pui-help-echo extent t))
        (if no-error
            (clear-message nil)
@@ -509,7 +509,7 @@ Designed to be called interactively (from a keypress)."
        info maintainer)
     (save-excursion
       (beginning-of-line)
-      (if (setq extent         (extent-at (point) (current-buffer) 'pui))
+      (if (setq extent (extent-at (point) (current-buffer) 'pui))
          (progn
            (setq ;pkg-sym (extent-property extent 'pui-package)
             info (extent-property extent 'pui-info)
@@ -598,10 +598,10 @@ select packages for installation via the keyboard or mouse."
     (unless package-get-remote
       (insert "
 Warning: No download sites specified.  Package index may be out of date.
-         If you intend to install packages, specify download sites first.
+        If you intend to install packages, specify download sites first.
 
 "))
-    
+
     (if pui-list-verbose
        (insert "                       Latest Installed
   Package name         Vers.  Vers.   Description
@@ -637,7 +637,7 @@ Warning: No download sites specified.  Package index may be out of date.
                   (setq current-vers (format "%.2f" current-vers))))
                 (insert
                  (format "%s %-20s %-5.2f  %-5s  %s\n"
-                         (car disp) pkg-sym 
+                         (car disp) pkg-sym
                          (if (stringp version)
                              (string-to-number version)
                            version)
index 8d82d65..34a555c 100644 (file)
@@ -181,8 +181,8 @@ to the specified name LIBRARY.
 If the optional third arg PATH is specified, that list of directories
 is used instead of `load-path'."
   (interactive (list (read-library-name "Locate library: ")
-                     nil nil
-                     t))
+                    nil nil
+                    t))
   (let ((result
         (locate-file
          library
@@ -342,7 +342,7 @@ This function is basically a wrapper over `locate-file'."
   ;; make sure paths-find-version-directory and paths-find-site-directory
   ;; don't both pick up version-independent directories ...
   (let ((version-directory (paths-find-version-archindep-directory
-                            roots base nil nil t))
+                           roots base nil nil t))
        (site-directory (paths-find-site-archindep-directory roots base)))
     (paths-uniq-append
      (and version-directory (list version-directory))
index 1f41213..929455b 100644 (file)
@@ -76,7 +76,7 @@ thus marking a page other than the one point was originally in."
   (if (> arg 0)
       (forward-page arg)
     (if (< arg 0)
-        (forward-page (1- arg))))
+       (forward-page (1- arg))))
   (forward-page)
   (push-mark nil t t)
   (forward-page -1))
index 17f4e37..4a423d7 100644 (file)
@@ -55,10 +55,10 @@ only considered as a candidate to match `paragraph-start' or
 
 Prefix argument says to turn mode on if positive, off if negative.
 When the mode is turned on, if there are newlines in the buffer but no hard
-newlines, ask the user whether to mark as hard any newlines preceding a 
+newlines, ask the user whether to mark as hard any newlines preceding a
 `paragraph-start' line.  From a program, second arg INSERT specifies whether
 to do this; it can be `never' to change nothing, t or `always' to force
-marking, `guess' to try to do the right thing with no questions, nil 
+marking, `guess' to try to do the right thing with no questions, nil
 or anything else to ask the user.
 
 Newlines not marked hard are called \"soft\", and are always internal
@@ -192,7 +192,7 @@ to which the end of the previous line belongs, or the end of the buffer."
        (while (and (not (bobp))
                    (progn (move-to-left-margin)
                           (looking-at paragraph-separate)))
-         (forward-line -1)) 
+         (forward-line -1))
        (if (bobp)
            nil
          ;; Go to end of the previous (non-separating) line.
index fdcefbd..4056841 100644 (file)
@@ -30,7 +30,7 @@
 
 ;;; Commentary:
 
-;; This code provides the picture-mode commands documented in the Emacs 
+;; This code provides the picture-mode commands documented in the Emacs
 ;; manual.  The screen is treated as a semi-infinite quarter-plane with
 ;; support for rectangle operations and `etch-a-sketch' character
 ;; insertion in any of eight directions.
@@ -425,10 +425,10 @@ prefix argument, the rectangle is actually killed, shifting remaining text."
   (let ((column (current-column))
        (indent-tabs-mode nil))
     (prog1 (save-excursion
-             (if killp
-                 (delete-extract-rectangle start end)
-               (prog1 (extract-rectangle start end)
-                      (clear-rectangle start end))))
+            (if killp
+                (delete-extract-rectangle start end)
+              (prog1 (extract-rectangle start end)
+                     (clear-rectangle start end))))
           (move-to-column-force column)
           ;; XEmacs addition:
           (setq zmacs-region-stays nil))))
index df29374..fd46bee 100644 (file)
@@ -226,7 +226,7 @@ Changes made are recorded internally."
         (props
          (condition-case err
              (make-dialog-box 'page-setup :device d
-                              :properties (declare-boundp 
+                              :properties (declare-boundp
                                            default-msprinter-frame-plist))
            (error
             (Printer-clear-device)
@@ -297,16 +297,16 @@ of how the buffer should be printed.
 
 PROPS, if given, is typically the plist returned from the call to
 `make-dialog-box' that displayed the Print box.  It contains properties
-relevant to us when we print.  
+relevant to us when we print.
 
 Recognized properties are the same as those in `make-dialog-box':
 
   name       Printer device name.  If omitted, the current system-selected
-             printer will be used.
+            printer will be used.
   from-page  First page to print, 1-based. If omitted, printing starts from
-             the beginning.
+            the beginning.
   to-page    Last page to print, inclusive, If omitted, printing ends at
-             the end.
+            the end.
   copies     Number of copies to print.  If omitted, one copy is printed."
   (cond ((valid-specifier-tag-p 'msprinter)
         ;; loop, printing one copy of document per loop.  kill and
index 93cd616..f556089 100644 (file)
@@ -102,10 +102,10 @@ If you quit, the process is killed with SIGINT, or SIGKILL if you
              (setq infile (expand-file-name infile))
              (setq inbuf (generate-new-buffer "*call-process*"))
              (with-current-buffer inbuf
-               ;; Make sure this works with jka-compr
-               (let ((file-name-handler-alist nil))
-                 (insert-file-contents-internal infile nil nil nil nil
-                                                'binary))))
+              ;; Make sure this works with jka-compr
+              (let ((file-name-handler-alist nil))
+                (insert-file-contents-internal infile nil nil nil nil
+                                               'binary))))
            (let ((stderr (if (consp buffer) (second buffer) t)))
              (if (consp buffer) (setq buffer (car buffer)))
              (setq buffer
@@ -201,8 +201,8 @@ If you quit, the process is killed with SIGINT, or SIGKILL if you
   (apply 'call-process-internal program infile buffer displayp args))
 
 (defun call-process-region (start end program
-                            &optional deletep buffer displayp
-                            &rest args)
+                           &optional deletep buffer displayp
+                           &rest args)
   "Send text from START to END to a synchronous process running PROGRAM.
 Delete the text if fourth arg DELETEP is non-nil.
 
@@ -279,7 +279,7 @@ In either case, the output is inserted after point (leaving mark after it)."
              (error
               'unimplemented
               "backgrounding a shell command requires package `background'")))
-           
+
        (shell-command-on-region (point) (point) command output-buffer)))))
 
 ;; We have a sentinel to prevent insertion of a termination message
@@ -436,9 +436,9 @@ are usually fine.)  Note further that UDP protocol does not guard against
 lost packets."
   (open-network-stream-internal name buffer host service protocol))
 
-(defun open-network-server-stream 
+(defun open-network-server-stream
   (name buffer host service &optional
-        protocol acceptor filter sentinel)
+       protocol acceptor filter sentinel)
   "Returns a process object to represent the listening connection. When a
 new connection request arrives, it is automatically accepted. A
 network-stream process is automatically created for that
@@ -446,9 +446,9 @@ connection. If needed a new buffer is also created. If given the
 acceptor function is called. If defined filter and sentinel are set
 for the new connection process .
 
-Input and output work as for subprocesses; `delete-process' closes it.  
+Input and output work as for subprocesses; `delete-process' closes it.
 
-Args are NAME BUFFER HOST SERVICE &optional PROTOCOL ACCEPTOR .  
+Args are NAME BUFFER HOST SERVICE &optional PROTOCOL ACCEPTOR .
 
 NAME is name for process.  It is modified if necessary to make it
 unique.
@@ -458,10 +458,10 @@ BUFFER is the buffer (or buffer-name) to associate with the process.
  specify an output stream or filter function to handle the output. No
  real process output of listening process is expected. However the
  name of this buffer will be used as a base for generating a new
- buffer name for the accepted connections.  
+ buffer name for the accepted connections.
  The BUFFER may be also nil, meaning that this process is not
  associated with any buffer. In this case a filter should be specified
- otherwise there will be no way to retrieve the process output.  
+ otherwise there will be no way to retrieve the process output.
  BUFFER may also be 'auto in which case a buffer is automatically
  created for the accepted connection.
 
@@ -478,7 +478,7 @@ Sixt argument ACCEPTOR is a function which will be called upon connection
  acceptance with the accepted connection process as the single argument.
 Seventh argument FILTER is a function which will be set as filter for
  the accepted connections automatically. See `set-process-filter' for
- more details.  
+ more details.
 Eight argument SENTINEL is a function which will be set as sentinel
  the accepted connections automatically. see `set-process-sentinel'
  for more details.
@@ -496,7 +496,7 @@ buffers. If sentinels and/or filters are set in the ACCEPTOR they
 will override the FILTER and SENTINEL args to this function.
 "
   (open-network-server-stream-internal name buffer host service
-                                       protocol acceptor filter sentinel))
+                                      protocol acceptor filter sentinel))
 
 (defun shell-quote-argument (argument)
   "Quote an argument for passing as argument to an inferior shell."
index 1ced83a..dbffc5a 100644 (file)
@@ -306,7 +306,7 @@ When called from a program, the rectangle's corners are START and END."
   (interactive "*r\nsString rectangle: ")
   (defvar pending-delete-mode)
   (apply-on-rectangle 'string-rectangle-line start end string
-                      (and (boundp 'pending-delete-mode) pending-delete-mode)))
+                     (and (boundp 'pending-delete-mode) pending-delete-mode)))
 
 ;;;###autoload
 (defun replace-rectangle (start end string)
index fc0d02c..ccc34d3 100644 (file)
 ;; For example:
 ;;
 ;; (let ((strings '("cond" "if" "when" "unless" "while"
-;;                 "let" "let*" "progn" "prog1" "prog2"
-;;                 "save-restriction" "save-excursion" "save-window-excursion"
-;;                 "save-current-buffer" "save-match-data"
-;;                 "catch" "throw" "unwind-protect" "condition-case")))
+;;                 "let" "let*" "progn" "prog1" "prog2"
+;;                 "save-restriction" "save-excursion" "save-window-excursion"
+;;                 "save-current-buffer" "save-match-data"
+;;                 "catch" "throw" "unwind-protect" "condition-case")))
 ;;   (concat "(" (regexp-opt strings t) "\\>"))
 ;;  => "(\\(c\\(?:atch\\|ond\\(?:ition-case\\)?\\)\\|if\\|let\\*?\\|prog[12n]\\|save-\\(?:current-buffer\\|excursion\\|match-data\\|restriction\\|window-excursion\\)\\|throw\\|un\\(?:less\\|wind-protect\\)\\|wh\\(?:en\\|ile\\)\\)\\>"
 ;;
@@ -114,20 +114,20 @@ by \\=\\< and \\>."
 
 (defconst regexp-opt-not-groupie*-re
   (let* ((harmless-ch "[^\\\\[]")
-         (esc-pair-not-lp "\\\\[^(]")
-         (class-harmless-ch "[^][]")
-         (class-lb-harmless "[^]:]")
-         (class-lb-colon-maybe-charclass ":\\([a-z]+:]\\)?")
-         (class-lb (concat "\\[\\(" class-lb-harmless
-                           "\\|" class-lb-colon-maybe-charclass "\\)"))
-         (class
-          (concat "\\[^?]?"
-                  "\\(" class-harmless-ch
-                  "\\|" class-lb "\\)*"
-                  "\\[?]"))         ; special handling for bare [ at end of re
-         (shy-lp "\\\\(\\?:"))
+        (esc-pair-not-lp "\\\\[^(]")
+        (class-harmless-ch "[^][]")
+        (class-lb-harmless "[^]:]")
+        (class-lb-colon-maybe-charclass ":\\([a-z]+:]\\)?")
+        (class-lb (concat "\\[\\(" class-lb-harmless
+                          "\\|" class-lb-colon-maybe-charclass "\\)"))
+        (class
+         (concat "\\[^?]?"
+                 "\\(" class-harmless-ch
+                 "\\|" class-lb "\\)*"
+                 "\\[?]"))         ; special handling for bare [ at end of re
+        (shy-lp "\\\\(\\?:"))
     (concat "\\(" harmless-ch "\\|" esc-pair-not-lp
-            "\\|" class "\\|" shy-lp "\\)*"))
+           "\\|" class "\\|" shy-lp "\\)*"))
   "Matches any part of a regular expression EXCEPT for non-shy \"\\\\(\"s")
 
 ;;;###autoload
@@ -141,11 +141,11 @@ in REGEXP."
     ;; Count the number of open parentheses in REGEXP.
     (let ((count 0) start)
       (while
-          (progn
-            (string-match regexp-opt-not-groupie*-re regexp start)
-            (setq start ( + (match-end 0) 2))  ; +2 for "\\(" after match-end.
-            (<= start (length regexp)))
-        (setq count (1+ count)))
+         (progn
+           (string-match regexp-opt-not-groupie*-re regexp start)
+           (setq start ( + (match-end 0) 2))  ; +2 for "\\(" after match-end.
+           (<= start (length regexp)))
+       (setq count (1+ count)))
       count)))
 \f
 ;;; Workhorse functions.
index 4aa70d7..ba9718f 100644 (file)
@@ -145,7 +145,7 @@ If NUMBER is nil, a decimal number is read from the buffer starting
 at point, and point moves to the end of that number.
 Interactively, NUMBER is the prefix arg (none means nil)."
   (interactive "P\ncNumber to register: ")
-  (set-register register 
+  (set-register register
                (if number
                    (prefix-numeric-value number)
                  (if (looking-at "\\s-*-?[0-9]+")
index d79ab0c..45a3e6d 100644 (file)
@@ -415,7 +415,7 @@ It serves as a menu to find any of the occurrences in this buffer.
                     (read-from-minibuffer
                      (format "List lines matching regexp (default `%s'): "
                              default) nil nil nil 'regexp-history nil
-                              default)
+                             default)
                   (read-from-minibuffer
                    "List lines matching regexp: "
                    nil nil nil
@@ -440,7 +440,7 @@ It serves as a menu to find any of the occurrences in this buffer.
        (prevpos (point-min))
        ;; The rest of this function is very different from FSF.
        ;; Presumably that's due to Jamie's misfeature
-        (final-context-start (make-marker)))
+       (final-context-start (make-marker)))
     (if (not list-matching-lines-whole-buffer)
        (save-excursion
          (beginning-of-line)
@@ -614,7 +614,7 @@ The valid answers include `act', `skip', `act-and-show',
     (next-command-event event)))
 
 (defun perform-replace (from-string replacements
-                       query-flag regexp-flag delimited-flag
+                       query-flag regexp-flag delimited-flag
                        &optional repeat-count map)
   "Subroutine of `query-replace'.  Its complexity handles interactive queries.
 Don't use this in your own program unless you want to query and set the mark
@@ -863,8 +863,8 @@ Zero means the entire text matched by the whole regexp or whole string.
 STRING should be given if the last search was by `string-match' on STRING."
   (if (match-beginning num)
       (if string
-          (substring string (match-beginning num) (match-end num))
-        (buffer-substring (match-beginning num) (match-end num)))))
+         (substring string (match-beginning num) (match-end num))
+       (buffer-substring (match-beginning num) (match-end num)))))
 
 (defmacro save-match-data (&rest body)
   "Execute BODY forms, restoring the global value of the match data."
index 297cb98..e07180c 100644 (file)
@@ -184,10 +184,10 @@ respectively."
       0
     (save-excursion
       (save-restriction
-        (widen)
+       (widen)
        (narrow-to-region start end)
        (goto-char start)
-        (vertical-motion (buffer-size))))))
+       (vertical-motion (buffer-size))))))
 
 \f
 ;; Resize the minibuffer window to contain the minibuffer's contents.
index 91837cc..e200ac8 100644 (file)
@@ -387,8 +387,8 @@ suitable internal representation otherwise."
   (when value
     (let ((handler-fn (cdr (assq type selection-converter-in-alist))))
       (if handler-fn
-          (apply handler-fn (list selection type value))
-        value))))
+         (apply handler-fn (list selection type value))
+       value))))
 
 (defun select-convert-out (selection type value)
   "Attempt to convert the specified internal VALUE for the specified DATA-TYPE
@@ -669,9 +669,9 @@ nil if this is impossible, or a suitable representation otherwise."
 
 (defun select-convert-from-ip-address (selection type value)
   (if (and (stringp value)
-           (= (length value) 4))
+          (= (length value) 4))
       (format "%d.%d.%d.%d"
-              (aref value 0) (aref value 1) (aref value 2) (aref value 3))))
+             (aref value 0) (aref value 1) (aref value 2) (aref value 3))))
 
 (defun select-convert-to-atom (selection type value)
   (and (symbolp value) value))
index 2cc01bc..ad3ed76 100644 (file)
@@ -65,8 +65,8 @@
 (defun paths-find-site-module-directory (roots)
   "Find the site modules directory of the XEmacs hierarchy."
   (paths-find-site-archdep-directory roots "site-modules"
-                                       nil
-                                       configure-site-module-directory))
+                                      nil
+                                      configure-site-module-directory))
 
 (defun paths-find-lisp-directory (roots)
   "Find the main Lisp directory of the XEmacs hierarchy."
@@ -85,7 +85,7 @@
        (if (paths-file-readable-directory-p guess)
            guess
          (paths-find-version-archindep-directory
-           roots "mule-lisp" nil configure-mule-lisp-directory)))))
+          roots "mule-lisp" nil configure-mule-lisp-directory)))))
 
 (defun paths-find-ffi-lisp-directory (roots &optional lisp-directory)
   "Find the FFI Lisp directory of the SXEmacs hierarchy."
        (if (paths-file-readable-directory-p guess)
            guess
          (or (paths-find-version-archdep-directory
-               roots "ffi-lisp" nil)
-              (paths-find-version-archindep-directory
-               roots "ffi-lisp" nil))))))
+              roots "ffi-lisp" nil)
+             (paths-find-version-archindep-directory
+              roots "ffi-lisp" nil))))))
 
 (defun paths-find-module-directory (roots)
   "Find the main modules directory of the SXEmacs hierarchy."
-  (or 
+  (or
    ;; for inplace stuff
    (paths-find-emacs-directory roots "" "modules"
-                               nil configure-module-directory)
+                              nil configure-module-directory)
    (paths-find-architecture-directory roots "modules"
-                                      nil configure-module-directory)))
+                                     nil configure-module-directory)))
 
 (defun paths-construct-module-load-path
   (root module-directory &optional site-module-directory)
@@ -135,7 +135,7 @@ down."
     (let* ((user-path
            (and system-configuration
                 user-init-directory
-                (paths-find-recursive-load-path 
+                (paths-find-recursive-load-path
                  (list (paths-construct-path
                         (list system-configuration "modules") user-init-directory))
                  paths-module-load-path-depth)))
@@ -168,8 +168,8 @@ down."
          (and mule-lisp-directory
               (paths-find-recursive-load-path (list mule-lisp-directory)
                                               paths-mule-load-path-depth)))
-        (ffi-lisp-load-path
-         (and ffi-lisp-directory
+        (ffi-lisp-load-path
+         (and ffi-lisp-directory
               (paths-find-recursive-load-path (list ffi-lisp-directory)
                                               paths-ffi-load-path-depth)))
         (lisp-load-path
@@ -180,11 +180,11 @@ down."
          (and module-directory
               (paths-construct-module-load-path roots module-directory
                                                 site-module-directory)))
-         (root-load-path
-          (paths-find-recursive-load-path
-           (mapcar #'(lambda (root)
-                       (expand-file-name "lisp" root))
-                   roots) 1)))
+        (root-load-path
+         (paths-find-recursive-load-path
+          (mapcar #'(lambda (root)
+                      (expand-file-name "lisp" root))
+                  roots) 1)))
 
     (append env-load-path
            emod-load-path
@@ -193,7 +193,7 @@ down."
            mule-lisp-load-path
            ffi-lisp-load-path
            lisp-load-path
-            root-load-path
+           root-load-path
            last-package-load-path)))
 
 (defun paths-construct-info-path (roots early-packages late-packages last-packages)
@@ -204,9 +204,9 @@ down."
       (list (paths-find-emacs-directory roots "share/" "info" nil configure-info-directory))
       (let ((info-directory
             (or (paths-find-version-archindep-directory
-                  roots "info" nil configure-info-directory)
-                 (paths-find-version-archdep-directory
-                  roots "info" nil configure-info-directory))))
+                 roots "info" nil configure-info-directory)
+                (paths-find-version-archdep-directory
+                 roots "info" nil configure-info-directory))))
        (and info-directory
             (list info-directory)))
       (packages-find-package-info-path early-packages)
@@ -238,7 +238,7 @@ down."
 (defun paths-find-exec-directory (roots)
   "Find the binary directory."
   (paths-find-architecture-directory roots "lib-src"
-                                     nil configure-exec-directory))
+                                    nil configure-exec-directory))
 
 (defun paths-construct-exec-path (roots exec-directory
                                  early-packages late-packages last-packages)
index 93f3e6c..1d5fd96 100644 (file)
@@ -63,7 +63,7 @@ the file in position 2i+1.  Emacs Lisp file suffixes \(.el and .elc\)
 are stripped from the file names in the list.
 
 See the documentation for `list-load-path-shadows' for further information."
-  
+
   (let (shadows                                ; List of shadowings, to be returned.
        dir                             ; The dir being currently scanned.
        curr-files                      ; This dir's Emacs Lisp files.
@@ -75,7 +75,7 @@ See the documentation for `list-load-path-shadows' for further information."
        (files-seen-this-dir            ; Files seen so far in this dir.
         (make-hash-table :size 100 :test 'equal))
        )
-  
+
     (dolist (path-elt (or path load-path))
 
       (setq dir (file-truename (or path-elt ".")))
@@ -93,11 +93,11 @@ See the documentation for `list-load-path-shadows' for further information."
        (puthash dir t true-names)
        (setq dir (or path-elt "."))
        (setq curr-files (if (file-accessible-directory-p dir)
-                               (directory-files dir nil ".\\.elc?$" t)))
+                              (directory-files dir nil ".\\.elc?$" t)))
        (and curr-files
             (not noninteractive)
             (message "Checking %d files in %s..." (length curr-files) dir))
-       
+
        (clrhash files-seen-this-dir)
 
        (dolist (file curr-files)
@@ -127,7 +127,7 @@ See the documentation for `list-load-path-shadows' for further information."
            ;; This test prevents us declaring that XXX.el shadows
            ;; XXX.elc (or vice-versa) when they are in the same directory.
            (puthash file t files-seen-this-dir)
-             
+
            (if (setq orig-dir (gethash file file-dirs))
                ;; This file was seen before, we have a shadowing.
                (setq shadows
@@ -183,7 +183,7 @@ considered to shadow a later file XXX.el, and vice-versa.
 When run interactively, the shadowings \(if any\) are displayed in a
 buffer called `*Shadows*'.  Shadowings are located by calling the
 \(non-interactive\) companion function, `find-emacs-lisp-shadows'."
-  
+
   (interactive)
   (let* ((path (copy-sequence load-path))
        (tem path)
index 22b08fa..a524213 100644 (file)
@@ -118,9 +118,9 @@ since they have special meaning in a regexp."
 is non-nil, and if STRING (either a string or a regular expression according
 to REGEXP-FLAG) contains uppercase letters."
   `(let ((case-fold-search
-          (if (and case-fold-search search-caps-disable-folding)
-              (no-upper-case-p ,string ,regexp-flag)
-            case-fold-search)))
+         (if (and case-fold-search search-caps-disable-folding)
+             (no-upper-case-p ,string ,regexp-flag)
+           case-fold-search)))
      ,@body))
 (put 'with-search-caps-disable-folding 'lisp-indent-function 2)
 (put 'with-search-caps-disable-folding 'edebug-form-spec
@@ -133,8 +133,8 @@ function called interactively."
   `(let ((case-fold-search
          (if (and (interactive-p)
                   case-fold-search search-caps-disable-folding)
-              (no-upper-case-p ,string ,regexp-flag)
-            case-fold-search)))
+             (no-upper-case-p ,string ,regexp-flag)
+           case-fold-search)))
      ,@body))
 (put 'with-interactive-search-caps-disable-folding 'lisp-indent-function 2)
 (put 'with-interactive-search-caps-disable-folding 'edebug-form-spec
@@ -576,14 +576,14 @@ Don't use this command in Lisp programs!
                        (/ (* size (prefix-numeric-value arg)) 10)))
                 (point-max)))
     (cond (arg
-           ;; If we went to a place in the middle of the buffer,
-           ;; adjust it to the beginning of a line.
-           (forward-line 1))
+          ;; If we went to a place in the middle of the buffer,
+          ;; adjust it to the beginning of a line.
+          (forward-line 1))
          ;; XEmacs change
          (scroll-to-end
-           ;; If the end of the buffer is not already on the screen,
-           ;; then scroll specially to put it near, but not at, the bottom.
-           (recenter -3)))))
+          ;; If the end of the buffer is not already on the screen,
+          ;; then scroll specially to put it near, but not at, the bottom.
+          (recenter -3)))))
 
 ;; XEmacs (not in FSF)
 (defun mark-beginning-of-buffer (&optional arg)
@@ -597,8 +597,8 @@ With arg N, push mark N/10 of the way from the true beginning."
                        (/ (buffer-size) 10))
                   (/ (+ 10 (* (buffer-size) (prefix-numeric-value arg))) 10))
               (point-min))
-             nil
-             t))
+            nil
+            t))
 (define-function 'mark-bob 'mark-beginning-of-buffer)
 
 ;; XEmacs (not in FSF)
@@ -613,9 +613,9 @@ With arg N, push mark N/10 of the way from the true end."
                        (* (prefix-numeric-value arg)
                           (/ (buffer-size) 10))
                      (/ (* (buffer-size) (prefix-numeric-value arg)) 10)))
-                 (point-max))
-             nil
-             t))
+                (point-max))
+            nil
+            t))
 (define-function 'mark-eob 'mark-end-of-buffer)
 
 (defun mark-whole-buffer ()
@@ -678,7 +678,7 @@ BUFFER defaults to the current buffer."
   (with-current-buffer (or buffer (current-buffer))
     (let ((cnt (count-lines (point-min) (point-max))))
       (message "Buffer has %d lines, %d characters"
-               cnt (- (point-max) (point-min)))
+              cnt (- (point-max) (point-min)))
       cnt)))
 
 ;;; Modified by Bob Weiner, 8/24/95, to print narrowed line number also.
@@ -781,7 +781,7 @@ See also `line-number'."
   (let* ((char (char-after (point))) ; XEmacs
         (beg (point-min))
         (end (point-max))
-         (pos (point))
+        (pos (point))
         (total (buffer-size))
         (percent (if (> total 50000)
                      ;; Avoid overflow from multiplying by 100!
@@ -1454,24 +1454,24 @@ visual feedback indicating the extent of the region being copied."
            ;; Inhibit quitting so we can make a quit here
            ;; look like a C-g typed as a command.
            (inhibit-quit t)
-            (win (selected-window))
-            (buf (current-buffer)))
+           (win (selected-window))
+           (buf (current-buffer)))
        (if (pos-visible-in-window-p other-end win)
            (progn
              ;; FSF (I'm not sure what this does -sb)
              ;; Swap point and mark.
              (with-selected-window win
-                (with-current-buffer buf
-                  (goto-char other-end)))
-              (sit-for 1)
+               (with-current-buffer buf
+                 (goto-char other-end)))
+             (sit-for 1)
              ;; Swap back.
              (with-selected-window win
-                (with-current-buffer buf
-                  (goto-char opoint)))
-              ;; If user quit, deactivate the mark
+               (with-current-buffer buf
+                 (goto-char opoint)))
+             ;; If user quit, deactivate the mark
              ;; as C-g would as a command.
              (and quit-flag (mark)
-                   (zmacs-deactivate-region)))))))
+                  (zmacs-deactivate-region)))))))
 
 (defun append-next-kill ()
   "Cause following command, if it kills, to append to previous kill."
@@ -1825,13 +1825,13 @@ purposes.  See the documentation of `set-mark' for more information."
               (not (eq (marker-buffer (car global-mark-ring)) buffer))))
       ;; The last global mark pushed wasn't in this same buffer.
       (progn
-        (setq global-mark-ring (cons (copy-marker (mark-marker t buffer))
-                                     global-mark-ring))
-        (if (> (length global-mark-ring) global-mark-ring-max)
-            (progn
-              (move-marker (car (nthcdr global-mark-ring-max global-mark-ring))
-                           nil buffer)
-              (setcdr (nthcdr (1- global-mark-ring-max) global-mark-ring) nil)))))
+       (setq global-mark-ring (cons (copy-marker (mark-marker t buffer))
+                                    global-mark-ring))
+       (if (> (length global-mark-ring) global-mark-ring-max)
+           (progn
+             (move-marker (car (nthcdr global-mark-ring-max global-mark-ring))
+                          nil buffer)
+             (setcdr (nthcdr (1- global-mark-ring-max) global-mark-ring) nil)))))
   (setq dont-record-current-mark
        (not (not (or (and in-shifted-motion-command
                           (memq 'shifted-motion-commands
@@ -2432,8 +2432,8 @@ The goal column is stored in the variable `goal-column'."
   (interactive "_P") ; XEmacs
   (if column
       (progn
-        (setq goal-column nil)
-        (display-message 'command "No goal column"))
+       (setq goal-column nil)
+       (display-message 'command "No goal column"))
     (setq goal-column (current-column))
     (lmessage 'command
        "Goal column %d (use %s with a prefix arg to unset it)"
@@ -2725,8 +2725,8 @@ comment.  Comments starting in column 0 are not moved."
                     (skip-syntax-backward "^ " (match-beginning 0)))))
        (setq begpos (point))
        ;; Compute desired indent.
-        ;; XEmacs change: Preserve indentation of comments starting in
-        ;; column 0, as documented.
+       ;; XEmacs change: Preserve indentation of comments starting in
+       ;; column 0, as documented.
        (cond
         ((= (current-column) 0)
          (goto-char begpos))
@@ -2820,7 +2820,7 @@ not end the comment.  Blank lines do not get comments."
     (save-restriction
       (let ((cs comment-start) (ce comment-end)
            numarg)
-        (if (consp arg) (setq numarg t)
+       (if (consp arg) (setq numarg t)
          (setq numarg (prefix-numeric-value arg))
          ;; For positive arg > 1, replicate the comment delims now,
          ;; then insert the replicated strings just once.
@@ -2829,10 +2829,10 @@ not end the comment.  Blank lines do not get comments."
                  ce (concat ce comment-end))
            (setq numarg (1- numarg))))
        ;; Loop over all lines from START to END.
-        (narrow-to-region start end)
-        (goto-char start)
-        (while (not (eobp))
-          (if (or (eq numarg t) (< numarg 0))
+       (narrow-to-region start end)
+       (goto-char start)
+       (while (not (eobp))
+         (if (or (eq numarg t) (< numarg 0))
              (progn
                ;; Delete comment start from beginning of line.
                (if (eq numarg t)
@@ -2843,7 +2843,7 @@ not end the comment.  Blank lines do not get comments."
                                (looking-at (regexp-quote cs)))
                      (delete-char (length cs)))))
                ;; Delete comment end from end of line.
-                (if (string= "" ce)
+               (if (string= "" ce)
                    nil
                  (if (eq numarg t)
                      (progn
@@ -2869,12 +2869,12 @@ not end the comment.  Blank lines do not get comments."
                              (delete-char (length ce))))))))
                (forward-line 1))
            ;; Insert at beginning and at end.
-            (if (looking-at "[ \t]*$") ()
-              (insert cs)
-              (if (string= "" ce) ()
-                (end-of-line)
-                (insert ce)))
-            (search-forward "\n" nil 'move)))))))
+           (if (looking-at "[ \t]*$") ()
+             (insert cs)
+             (if (string= "" ce) ()
+               (end-of-line)
+               (insert ce)))
+           (search-forward "\n" nil 'move)))))))
 
 ;; XEmacs
 (defun prefix-region (prefix)
@@ -2882,13 +2882,13 @@ not end the comment.  Blank lines do not get comments."
   (interactive "sPrefix string: ")
   (if prefix
       (let ((count (count-lines (mark) (point))))
-       (goto-char (min (mark) (point)))
-       (while (> count 0)
-          (setq count (1- count))
-         (beginning-of-line 1)
-         (insert prefix)
-         (end-of-line 1)
-         (forward-char 1)))))
+       (goto-char (min (mark) (point)))
+       (while (> count 0)
+         (setq count (1- count))
+         (beginning-of-line 1)
+         (insert prefix)
+         (end-of-line 1)
+         (forward-char 1)))))
 
 \f
 (defun backward-word (&optional count buffer)
@@ -2953,26 +2953,26 @@ if you a newlines is reached first, move forward instead."
       (if (and (eq start oldpoint) (eq end oldpoint))
          ;; Point is neither within nor adjacent to a word.
          (and (not strict)
-               (progn
-                 ;; Look for preceding word in same line.
-                 (skip-syntax-backward "^w_"
-                                       (save-excursion
-                                         (beginning-of-line) (point)))
-                 (if (bolp)
+              (progn
+                ;; Look for preceding word in same line.
+                (skip-syntax-backward "^w_"
+                                      (save-excursion
+                                        (beginning-of-line) (point)))
+                (if (bolp)
                     ;; No preceding word in same line.
                     ;; Look for following word in same line.
-                     (progn
-                       (skip-syntax-forward "^w_"
+                    (progn
+                      (skip-syntax-forward "^w_"
                                            (save-excursion
-                                              (end-of-line) (point)))
-                       (setq start (point))
-                       (skip-syntax-forward "w_")
-                       (setq end (point)))
-                     (setq end (point))
-                     (skip-syntax-backward "w_")
-                     (setq start (point)))
+                                             (end-of-line) (point)))
+                      (setq start (point))
+                      (skip-syntax-forward "w_")
+                      (setq end (point)))
+                    (setq end (point))
+                    (skip-syntax-backward "w_")
+                    (setq start (point)))
                 (buffer-substring start end)))
-          (buffer-substring start end)))))
+         (buffer-substring start end)))))
 \f
 (defcustom fill-prefix nil
   "*String for filling to insert at front of new line, or nil for none.
@@ -4004,8 +4004,8 @@ See the variable `zmacs-regions'.")
   (and zmacs-regions zmacs-region-active-p
        (or (marker-buffer (mark-marker t))
           (and (extent-live-p zmacs-region-extent)
-               (buffer-live-p (extent-object zmacs-region-extent))
-               (extent-object zmacs-region-extent)))))
+               (buffer-live-p (extent-object zmacs-region-extent))
+               (extent-object zmacs-region-extent)))))
 
 (defun zmacs-activate-region ()
   "Make the region between `point' and `mark' be active (highlighted),
@@ -4650,8 +4650,8 @@ The C code calls this periodically, right before redisplay."
       (setq warning-marker (make-marker))
       (set-marker warning-marker 1 buffer))
     (if temp-buffer-show-function
-        (progn
-          (funcall temp-buffer-show-function buffer)
+       (progn
+         (funcall temp-buffer-show-function buffer)
          (mapc #'(lambda (win) (set-window-start win warning-marker))
                (windows-of-buffer buffer nil t)))
       (set-window-start (display-buffer buffer) warning-marker))
index c18afe6..9a48ea2 100644 (file)
@@ -40,7 +40,7 @@
 This variable should be set by `site-load-package-file'.")
 
 ;; Load site specific packages for dumping with the XEmacs binary.
-(when (file-exists-p site-load-package-file) 
+(when (file-exists-p site-load-package-file)
   (let ((file))
     (load site-load-package-file t t t)
     ;; The `pureload' macro is provided as a clue that a package is
index 98a07c8..4048093 100644 (file)
 ;; #### It is now :) -hroptatyr
 (defcustom sound-extension-list (cond ((eq system-type 'linux)
                                       '(".wav" ".au" ".mp3" ".mka" ".ogg"
-                                         ".aac" ".ac3" ".mp4" ".flac"
-                                         ".mpc" ".mpa"))
+                                        ".aac" ".ac3" ".mp4" ".flac"
+                                        ".mpc" ".mpa"))
                                      (t
                                       '(".au")))
   "List of filename extensions to complete sound file name with."
@@ -137,10 +137,10 @@ when an explicit volume parameter is omitted.")
   "Search for FILENAME in `default-sound-directory-list'
 with respect to the extensions given by `sound-extension-list'."
   (let ((exts (cond ((listp sound-extension-list)
-                     sound-extension-list)
-                    ((stringp sound-extension-list)
-                     (split-string sound-extension-list ":"))
-                    (t nil))))
+                    sound-extension-list)
+                   ((stringp sound-extension-list)
+                    (split-string sound-extension-list ":"))
+                   (t nil))))
 
     (cond ((file-exists-p filename)
           (expand-file-name filename))
@@ -158,9 +158,9 @@ with respect to the extensions given by `sound-extension-list'."
 (defun make-sound-alist-item (filename sound-name &optional volume)
   "Return an item suitable for `sound-alist'."
   (let* ((file (locate-sound-file filename))
-         ;; let's create media-streams
-         (stream (make-media-stream :file file))
-         (data))
+        ;; let's create media-streams
+        (stream (make-media-stream :file file))
+        (data))
 
     (unless file
       (error "Couldn't load sound file %s" filename))
@@ -178,11 +178,11 @@ with respect to the extensions given by `sound-extension-list'."
 ;;       (and buf (kill-buffer buf)))
 
     (nconc (list sound-name)
-           (if (and volume (not (eq 0 volume)))
-               (list ':volume volume))
-           (if data
-               (list ':sound data))
-           (list ':stream stream))))
+          (if (and volume (not (eq 0 volume)))
+              (list ':volume volume))
+          (if data
+              (list ':sound data))
+          (list ':stream stream))))
 
 ;;;###autoload
 (defun load-sound-file (filename sound-name &optional volume)
@@ -202,11 +202,11 @@ nVolume (0 for default): ")
     (error "volume not an integer or nil"))
 
   (let ((item (make-sound-alist-item filename sound-name volume))
-        (old (assq sound-name sound-alist)))
+       (old (assq sound-name sound-alist)))
 
       ;; some conses in sound-alist might have been dumped with emacs.
       (when old
-        (setq sound-alist (delq old (copy-sequence sound-alist))))
+       (setq sound-alist (delq old (copy-sequence sound-alist))))
 
       (setq sound-alist (cons item sound-alist)))
   sound-name)
@@ -274,8 +274,8 @@ See `play-media-stream-synchronously' and
 `play-media-stream&'."
   (let* ((vol (or volume default-media-stream-volume)))
     (if (and (fboundp #'play-media-stream&)
-             (not synchronous-sounds))
-        (play-media-stream& stream device sentinel vol)
+            (not synchronous-sounds))
+       (play-media-stream& stream device sentinel vol)
       (play-media-stream-synchronously stream device sentinel vol))))
 
 ;;;###autoload
@@ -300,13 +300,13 @@ only valid symbol is 'finished\).  See `set-media-thread-sentinel'."
   (let ((data (cdr-safe (assq sound sound-alist))))
     (when (and data default-audio-device)
       (let ((ms (or (plist-get data :stream)
-                    (let ((s (plist-get data :sound)))
-                      (and (stringp s)
-                           (make-media-stream :data s)))))
-            (vol
-             (plist-get data :volume
-                        (or volume default-media-stream-volume bell-volume))))
-        (when ms
-          (play-media-stream ms device sentinel vol))))))
+                   (let ((s (plist-get data :sound)))
+                     (and (stringp s)
+                          (make-media-stream :data s)))))
+           (vol
+            (plist-get data :volume
+                       (or volume default-media-stream-volume bell-volume))))
+       (when ms
+         (play-media-stream ms device sentinel vol))))))
 
 ;;; sound.el ends here.
index fade7c3..0111f01 100644 (file)
@@ -109,7 +109,7 @@ otherwise return t."
              (valid-instantiator-p (cdr inst-pair) specifier-type))
         ;; case (c)
         inst-pair)
-        
+
        (t
         (if noerror t
           (signal 'error (list "Invalid specifier tag set"
@@ -434,11 +434,11 @@ applied like above and the resulting specification is added."
       (add-spec-list-to-specifier specifier spec-list))
      (force
       (set-specifier specifier
-                     (apply func
-                            (or (and (valid-specifier-domain-p locale)
-                                     (specifier-instance specifier))
-                                default) args)
-                     locale tag-set)))))
+                    (apply func
+                           (or (and (valid-specifier-domain-p locale)
+                                    (specifier-instance specifier))
+                               default) args)
+                    locale tag-set)))))
 
 (defmacro let-specifier (specifier-list &rest body)
   "Add specifier specs, evaluate forms in BODY and restore the specifiers.
@@ -599,7 +599,7 @@ detail in the doc string for `current-display-table'."
 (or (valid-specifier-tag-p 'tty)
     (define-specifier-tag 'tty (lambda (dev) (eq (device-type dev) 'tty))))
 (or (valid-specifier-tag-p 'mswindows)
-    (define-specifier-tag 'mswindows (lambda (dev) 
+    (define-specifier-tag 'mswindows (lambda (dev)
                                       (eq (device-type dev) 'mswindows))))
 
 ;; Add special tag for use by initialization code.  Code that
index 6a878b8..1423533 100644 (file)
@@ -206,11 +206,11 @@ In addition, the")
     (princ " following options are accepted:
   -sd                   Show dump ID.  Ignored when configured without --pdump.
   -nd                   Don't load the dump file.  Roughly like old temacs.
-                        Ignored when configured without --pdump.
+                       Ignored when configured without --pdump.
   -t <device>           Use TTY <device> instead of the terminal for input
-                        and output.  This implies the -nw option.
+                       and output.  This implies the -nw option.
   -nw                   Inhibit the use of any window-system-specific
-                        display code: use the current tty.
+                       display code: use the current tty.
   -batch                Execute noninteractively (messages go to stderr).
   -debug-init           Enter the debugger if an error in the init file occurs.
   -unmapped             Do not map the initial frame.
@@ -239,8 +239,8 @@ In addition, the")
                        (princ " ")
                        (incf len))))))
       (while l
-        (let ((name (car (car l)))
-              (fn (cdr (car l)))
+       (let ((name (car (car l)))
+             (fn (cdr (car l)))
              doc arg cons)
          (cond
           ((and (symbolp fn) (get fn 'undocumented)) nil)
@@ -261,7 +261,7 @@ In addition, the")
              (funcall insert name))
            (princ doc)
            (terpri))))
-        (setq l (cdr l))))
+       (setq l (cdr l))))
     (princ (concat "+N <file>             Start displaying <file> at line N.
 
 Anything else is considered a file name, and is placed into a buffer for
@@ -388,11 +388,11 @@ Type ^H^H^H (Control-h Control-h Control-h) to get more help options.\n")
                                                invocation-name))
 
       (when debug-paths
-        (princ (format "invocation: p:%S n:%S\n"
-                       invocation-directory invocation-name)
-               'external-debugging-output)
-        (princ (format "emacs-roots:\n%S\n" emacs-roots)
-               'external-debugging-output))
+       (princ (format "invocation: p:%S n:%S\n"
+                      invocation-directory invocation-name)
+              'external-debugging-output)
+       (princ (format "emacs-roots:\n%S\n" emacs-roots)
+              'external-debugging-output))
 
       (if (null emacs-roots)
          (startup-find-roots-warning))
@@ -438,7 +438,7 @@ Type ^H^H^H (Control-h Control-h Control-h) to get more help options.\n")
       (setq window-setup-hook nil)
       (if error-data
          ;; re-signal, and don't allow continuation as that will probably
-          ;; wipe out the user's .emacs if she hasn't migrated yet!
+         ;; wipe out the user's .emacs if she hasn't migrated yet!
          ;; Not applicable to SXEmacs --SY.
          (signal-error (car error-data) (cdr error-data))))
 
@@ -496,7 +496,7 @@ Type ^H^H^H (Control-h Control-h Control-h) to get more help options.\n")
        ((string= arg "-user-init-directory")
        (setq user-init-directory (file-name-as-directory (pop args))))
        ((or (string= arg "-u")
-           (string= arg "-user"))
+           (string= arg "-user"))
        (let* ((user (pop args))
               (home-user (concat "~" user)))
          (setq user-init-directory (file-name-as-directory
@@ -524,13 +524,13 @@ Type ^H^H^H (Control-h Control-h Control-h) to get more help options.\n")
 
     (nreverse new-args)))
 
-(defconst initial-scratch-message 
+(defconst initial-scratch-message
   ";; This buffer is for notes you don't want to save, and for Lisp evaluation.
 ;; If you want to create a file, first visit that file with C-x C-f,
 ;; then enter the text in that file's own buffer.
 ;;
-;; In \"SXEmacs-speak\", `C-char' and `M-char' are abbreviations that mean 
-;; `Control+char' and `Meta+char' (hold down the Control or Meta key while 
+;; In \"SXEmacs-speak\", `C-char' and `M-char' are abbreviations that mean
+;; `Control+char' and `Meta+char' (hold down the Control or Meta key while
 ;; pressing `char').
 ;;
 ;; For Lisp evaluation, type an expression, move to the end and hit C-j.
@@ -694,7 +694,7 @@ If this is nil, no message will be displayed.")
              (if load-user-init-file-p
                  (load-user-init-file))
              (setq init-file-had-error nil))
-          (error
+         (error
           (message "Error in init file: %s" (error-message-string error))
           (display-warning 'initialization
             (format "An error has occurred while loading %s:
@@ -831,12 +831,12 @@ a new format, when variables have changed, etc."
   (interactive)
   (let ((e last-command-event))
     (and (button-press-event-p e)
-         (setq e (extent-at (event-point e)
-                            (event-buffer e)
-                            'startup-presentation-hack))
-         (setq e (extent-property e 'startup-presentation-hack))
-         (if (consp e)
-             (apply (car e) (cdr e))
+        (setq e (extent-at (event-point e)
+                           (event-buffer e)
+                           'startup-presentation-hack))
+        (setq e (extent-property e 'startup-presentation-hack))
+        (if (consp e)
+            (apply (car e) (cdr e))
           (while (keymapp (indirect-function e))
             (let ((map e)
                   (overriding-local-map (indirect-function e)))
@@ -864,44 +864,44 @@ a new format, when variables have changed, etc."
 (defun splash-frame-present-hack (e v)
   ;;   (set-extent-property e 'mouse-face 'highlight)
   ;;   (set-extent-property e 'keymap
-  ;;                          startup-presentation-hack-keymap)
+  ;;                  startup-presentation-hack-keymap)
   ;;   (set-extent-property e 'startup-presentation-hack v)
   ;;   (set-extent-property e 'help-echo
-  ;;                          'startup-presentation-hack-help)
+  ;;                  'startup-presentation-hack-help)
   )
 
 (defun splash-frame-present (l)
   (cond ((stringp l)
-         (insert l))
-        ((eq (car-safe l) 'face)
-         ;; (face name string)
-         (let ((p (point)))
-           (splash-frame-present (elt l 2))
-           (if (fboundp 'set-extent-face)
-               (set-extent-face (make-extent p (point))
-                                (elt l 1)))))
-        ((eq (car-safe l) 'key)
-         (let* ((c (elt l 1))
-                (p (point))
-                (k (where-is-internal c nil t)))
-           (insert (if k (key-description k)
+        (insert l))
+       ((eq (car-safe l) 'face)
+        ;; (face name string)
+        (let ((p (point)))
+          (splash-frame-present (elt l 2))
+          (if (fboundp 'set-extent-face)
+              (set-extent-face (make-extent p (point))
+                               (elt l 1)))))
+       ((eq (car-safe l) 'key)
+        (let* ((c (elt l 1))
+               (p (point))
+               (k (where-is-internal c nil t)))
+          (insert (if k (key-description k)
                     (format "M-x %s" c)))
-           (if (fboundp 'set-extent-face)
-               (let ((e (make-extent p (point))))
-                 (set-extent-face e 'bold)
-                 (splash-frame-present-hack e c)))))
-        ((eq (car-safe l) 'funcall)
-         ;; (funcall (fun . args) string)
-         (let ((p (point)))
-           (splash-frame-present (elt l 2))
-           (if (fboundp 'set-extent-face)
-               (splash-frame-present-hack (make-extent p (point))
+          (if (fboundp 'set-extent-face)
+              (let ((e (make-extent p (point))))
+                (set-extent-face e 'bold)
+                (splash-frame-present-hack e c)))))
+       ((eq (car-safe l) 'funcall)
+        ;; (funcall (fun . args) string)
+        (let ((p (point)))
+          (splash-frame-present (elt l 2))
+          (if (fboundp 'set-extent-face)
+              (splash-frame-present-hack (make-extent p (point))
                                          (elt l 1)))))
        ((consp l)
         (mapcar 'splash-frame-present l))
-        (t
-         (backtrace 'external-debugging-output)
-         (error "WTF!?"))))
+       (t
+        (backtrace 'external-debugging-output)
+        (error "WTF!?"))))
 
 (defun startup-center-spaces (glyph)
   ;; Return the number of spaces to insert in order to center
@@ -1015,7 +1015,7 @@ Copyright (C) 2004 - 2009 Steve Youngs\n"))
 (defun display-splash-frame ()
   (let ((logo sxemacs-logo)
        (buffer-read-only nil)
-        (cramped-p (eq 'tty (console-type))))
+       (cramped-p (eq 'tty (console-type))))
     (unless cramped-p (insert "\n"))
     (indent-to (startup-center-spaces logo))
     (set-extent-begin-glyph (make-extent (point) (point)) logo)
@@ -1028,9 +1028,9 @@ Copyright (C) 2004 - 2009 Steve Youngs\n"))
           (client-data `[ 1 ,(point) ,(current-buffer) ,elements ])
           tmout)
       (if (listp  elements) ;; A single element to display
-          (splash-frame-present (splash-frame-body))
+         (splash-frame-present (splash-frame-body))
        ;; several elements to rotate
-        (splash-frame-present (aref elements 0))
+       (splash-frame-present (aref elements 0))
        (setq tmout (add-timeout splash-frame-timeout
                                 'circulate-splash-frame-elements
                                 client-data splash-frame-timeout)))
@@ -1079,11 +1079,11 @@ It's idempotent, so call this as often as you like!"
          (packages-compute-package-locations user-init-directory)))
 
   (setq early-package-load-path
-        (packages-find-package-load-path early-packages)
-        late-package-load-path
-        (packages-find-package-load-path late-packages)
-        last-package-load-path
-        (packages-find-package-load-path last-packages))
+       (packages-find-package-load-path early-packages)
+       late-package-load-path
+       (packages-find-package-load-path late-packages)
+       last-package-load-path
+       (packages-find-package-load-path last-packages))
 
   (if debug-paths
       (progn
@@ -1117,20 +1117,20 @@ It's idempotent, so call this as often as you like!"
     (setq mule-lisp-directory '()))
 
   (setq ffi-lisp-directory
-        (when (fboundp #'ffi-defun)
-          (paths-find-ffi-lisp-directory roots
-                                         lisp-directory)))
+       (when (fboundp #'ffi-defun)
+         (paths-find-ffi-lisp-directory roots
+                                        lisp-directory)))
 
   ;; Modules
   (setq module-directory (paths-find-module-directory roots))
   (if debug-paths
       (princ (format "module-directory:\n%S\n" module-directory)
-            'external-debugging-output))
+            'external-debugging-output))
   (setq site-module-directory (and (null inhibit-site-modules)
                                   (paths-find-site-module-directory roots)))
   (if (and debug-paths (null inhibit-site-modules))
       (princ (format "site-module-directory:\n%S\n" site-module-directory)
-            'external-debugging-output))
+            'external-debugging-output))
 
   (setq load-path (paths-construct-load-path roots
                                             early-package-load-path
@@ -1139,7 +1139,7 @@ It's idempotent, so call this as often as you like!"
                                             lisp-directory
                                             nil
                                             mule-lisp-directory
-                                             ffi-lisp-directory))
+                                            ffi-lisp-directory))
 
   (setq Info-directory-list
        (paths-construct-info-path roots
@@ -1177,10 +1177,10 @@ It's idempotent, so call this as often as you like!"
             'external-debugging-output))
 
   (setq data-directory-list
-        (paths-construct-data-directory-list data-directory
-                                             early-packages
-                                             late-packages
-                                             last-packages))
+       (paths-construct-data-directory-list data-directory
+                                            early-packages
+                                            late-packages
+                                            last-packages))
   (if debug-paths
       (princ (format "data-directory-list:\n%S\n" data-directory-list)
             'external-debugging-output)))
@@ -1221,7 +1221,7 @@ It's idempotent, so call this as often as you like!"
          (setq warnings (cdr warnings)))
        (insert "Perhaps some directories don't exist, "
                "or the SXEmacs executable,\n"
-                (concat invocation-directory invocation-name)
+               (concat invocation-directory invocation-name)
                "\nis in a strange place?")
 
        (princ "\nWARNING:\n" 'external-debugging-output)
@@ -1234,33 +1234,33 @@ It's idempotent, so call this as often as you like!"
   "Load autoloads from known locations."
 
   (when (and (not inhibit-autoloads)
-             (or lisp-directory module-directory))
+            (or lisp-directory module-directory))
     ;; ordinary auto-autoloads in lisp/
     (let ((aalfile (file-name-sans-extension autoload-file-name)))
 
       (condition-case nil
-          (load (expand-file-name aalfile lisp-directory) nil t)
-        (error . nil))
+         (load (expand-file-name aalfile lisp-directory) nil t)
+       (error . nil))
 
       ;; just load them all
       (mapc-internal
        #'(lambda (root)
-           (condition-case nil
-               (load (expand-file-name (concat "lisp/" aalfile) root) nil t)
-             (error . nil)))
+          (condition-case nil
+              (load (expand-file-name (concat "lisp/" aalfile) root) nil t)
+            (error . nil)))
        emacs-roots)
 
       (when (featurep 'mule)
-        (load (expand-file-name aalfile
-                                (expand-file-name "mule" lisp-directory))
-              t t))
+       (load (expand-file-name aalfile
+                               (expand-file-name "mule" lisp-directory))
+             t t))
       (when (featurep 'modules)
-        (load (expand-file-name aalfile module-directory) t t))
+       (load (expand-file-name aalfile module-directory) t t))
 
       (when (fboundp #'ffi-defun)
-        (load (expand-file-name aalfile
-                                (expand-file-name "ffi" lisp-directory))
-              t t))))
+       (load (expand-file-name aalfile
+                               (expand-file-name "ffi" lisp-directory))
+             t t))))
 
   (unless inhibit-autoloads
     (unless inhibit-early-packages
@@ -1268,7 +1268,7 @@ It's idempotent, so call this as often as you like!"
     (if (and (not inhibit-early-packages) (not warn-early-package-shadows))
        (let ((early-path (mapcar 'file-basename early-package-load-path))
              late-load-path)
-         (mapc (lambda (path) 
+         (mapc (lambda (path)
                  (unless (member (file-basename path) early-path)
                    (setq late-load-path (append late-load-path (list path)))))
                late-package-load-path)
index e662dd0..a1b4959 100644 (file)
@@ -408,7 +408,7 @@ is a single function, it is changed to a list of functions.
 You can remove this hook yourself using `remove-hook-list'.
 
 See also `add-hook`, `remove-hook` and `add-one-shot-hook'."
-  (mapc (lambda (hook) 
+  (mapc (lambda (hook)
          (add-hook hook function append local))
        hook-list))
 
@@ -424,7 +424,7 @@ the hook's buffer-local value rather than its default value.
 This makes the hook buffer-local if needed.
 To make a hook variable buffer-local, always use
 `make-local-hook', not `make-local-variable'."
-  (mapc (lambda (hook) 
+  (mapc (lambda (hook)
          (remove-hook hook function local))
        hook-list))
 
@@ -444,9 +444,9 @@ other hooks, such as major mode hooks, can do the job."
   (if (member element (symbol-value list-var))
       (symbol-value list-var)
     (set list-var
-         (if append
-             (append (symbol-value list-var) (list element))
-           (cons element (symbol-value list-var))))))
+        (if append
+            (append (symbol-value list-var) (list element))
+          (cons element (symbol-value list-var))))))
 
 ;; END SYNCHED WITH FSF 21.2
 
@@ -556,7 +556,7 @@ See also `with-temp-buffer'."
               (with-current-buffer ,temp-buffer
                 ,@forms)
             (with-current-buffer ,temp-buffer
-               (widen)
+              (widen)
               (write-region (point-min) (point-max) ,temp-file nil 0)))
         (and (buffer-name ,temp-buffer)
              (kill-buffer ,temp-buffer))))))
@@ -635,7 +635,7 @@ See also `with-temp-file' and `with-output-to-string'."
 ;   (declare (indent 0) (debug t))
 ;   `(unwind-protect
 ;        (let ((combine-after-change-calls t))
-;       . ,body)
+;       . ,body)
 ;      (combine-after-change-execute)))
 
 
@@ -716,8 +716,8 @@ Zero means the entire text matched by the whole regexp or whole string.
 STRING should be given if the last search was by `string-match' on STRING."
   (if (match-beginning num)
       (if string
-          (substring string (match-beginning num) (match-end num))
-        (buffer-substring (match-beginning num) (match-end num)))))
+         (substring string (match-beginning num) (match-end num))
+       (buffer-substring (match-beginning num) (match-end num)))))
 
 (defun match-string-no-properties (num &optional string)
   "Return string of text matched by last search, without text properties.
@@ -1267,11 +1267,11 @@ error
       invalid-read-syntax
       invalid-regexp
       structure-formation-error
-        list-formation-error
-          malformed-list
-            malformed-property-list
-          circular-list
-            circular-property-list
+       list-formation-error
+         malformed-list
+           malformed-property-list
+         circular-list
+           circular-property-list
     invalid-function
     no-catch
     undefined-keystroke-sequence
@@ -1301,20 +1301,20 @@ error
       buffer-read-only
     io-error
       file-error
-        file-already-exists
-        file-locked
-        file-supersession
-        end-of-file
+       file-already-exists
+       file-locked
+       file-supersession
+       end-of-file
       process-error
       network-error
       gui-error
-        dialog-box-error
+       dialog-box-error
       sound-error
       conversion-error
-        text-conversion-error
-        image-conversion-error
-        base64-conversion-error
-        selection-conversion-error
+       text-conversion-error
+       image-conversion-error
+       base64-conversion-error
+       selection-conversion-error
     arith-error
       range-error
       domain-error
@@ -1593,10 +1593,10 @@ properties to add to the result."
     (progn
       (setq abbrev-table-name-list '())
       (fset 'define-abbrev-table (function (lambda (name defs)
-                                   ;; These are fixed-up when abbrev.el loads.
-                                   (setq abbrev-table-name-list
-                                         (cons (cons name defs)
-                                               abbrev-table-name-list)))))))
+                                  ;; These are fixed-up when abbrev.el loads.
+                                  (setq abbrev-table-name-list
+                                        (cons (cons name defs)
+                                              abbrev-table-name-list)))))))
 
 ;;; `functionp' has been moved into C.
 
@@ -1755,7 +1755,7 @@ one is kept."
 
 ;; define-mail-user-agent is in simple.el.
 
-;; XEmacs; added. 
+;; XEmacs; added.
 (defun skip-chars-quote (string)
   "Return a string that means all characters in STRING will be skipped,
 if passed to `skip-chars-forward' or `skip-chars-backward'.
index 068cdd9..7061250 100644 (file)
@@ -69,7 +69,7 @@
 ;; -- avoided consing if at all possible.
 ;; -- didn't slow down operations on non-magic variables (therefore,
 ;;    storing the magic information using `put' is ruled out).
-;; 
+;;
 
 ;;; Code:
 
@@ -169,7 +169,7 @@ each of the handlers."
      (apply fun 'teach-extended-commands-p args)
      (apply fun 'teach-extended-commands-timeout args)))
 
-(set-magic-variable-handler 
+(set-magic-variable-handler
  'suggest-key-bindings 'other-predicate
  #'(lambda (sym fun args harg)
      (and (apply fun 'teach-extended-commands-p args)
index 9739859..346dcf1 100644 (file)
@@ -66,7 +66,7 @@ If CODE is invalid, return nil."
     (if (consp code)
        (setq code (car code)))
     (if (or (not (integerp code))
-            (> (logand code 127) (length codes)))
+           (> (logand code 127) (length codes)))
        nil
       (with-output-to-string
        (let* ((spec (elt codes (logand code 127)))
@@ -102,41 +102,41 @@ STRING should be something acceptable as the second argument to
 `modify-syntax-entry'.
 If STRING is invalid, signal an error."
   (let* ((bflag nil)
-         (b3 0)
-         (ch0 (aref string 0))
-         (len (length string))
-         (code (string-match (regexp-quote (char-to-string ch0))
-                             (syntax-designator-chars)))
-         (i 2)
-         ch)
+        (b3 0)
+        (ch0 (aref string 0))
+        (len (length string))
+        (code (string-match (regexp-quote (char-to-string ch0))
+                            (syntax-designator-chars)))
+        (i 2)
+        ch)
     (or code
-        (error "Invalid syntax designator: %S" string))
+       (error "Invalid syntax designator: %S" string))
     (while (< i len)
       (setq ch (aref string i))
       (incf i)
       (case ch
-        (?1 (setq b3 (logior b3 128)))
-        (?2 (setq b3 (logior b3  32)))
-        (?3 (setq b3 (logior b3   8)))
-        (?4 (setq b3 (logior b3   2)))
-        (?5 (setq b3 (logior b3  64)))
-        (?6 (setq b3 (logior b3  16)))
-        (?7 (setq b3 (logior b3   4)))
-        (?8 (setq b3 (logior b3   1)))
-        (?a (case ch0
-              (?< (setq b3 (logior b3 128)))
-              (?> (setq b3 (logior b3   8)))))
-        (?b (case ch0
-              (?< (setq b3 (logior b3  64) bflag t))
-              (?> (setq b3 (logior b3   4) bflag t))))
-        (?p (setq code (logior code (lsh 1 7))))
-        (?\  nil) ;; ignore for compatibility
-        (otherwise
-         (error "Invalid syntax description flag: %S" string))))
+       (?1 (setq b3 (logior b3 128)))
+       (?2 (setq b3 (logior b3  32)))
+       (?3 (setq b3 (logior b3   8)))
+       (?4 (setq b3 (logior b3   2)))
+       (?5 (setq b3 (logior b3  64)))
+       (?6 (setq b3 (logior b3  16)))
+       (?7 (setq b3 (logior b3   4)))
+       (?8 (setq b3 (logior b3   1)))
+       (?a (case ch0
+             (?< (setq b3 (logior b3 128)))
+             (?> (setq b3 (logior b3   8)))))
+       (?b (case ch0
+             (?< (setq b3 (logior b3  64) bflag t))
+             (?> (setq b3 (logior b3   4) bflag t))))
+       (?p (setq code (logior code (lsh 1 7))))
+       (?\  nil) ;; ignore for compatibility
+       (otherwise
+        (error "Invalid syntax description flag: %S" string))))
     ;; default single char style if `b' has not been seen
     (if (not bflag)
-        (case ch0
-          (?< (setq b3 (logior b3 128)))
+       (case ch0
+         (?< (setq b3 (logior b3 128)))
          (?> (setq b3 (logior b3   8)))))
     (setq code (logior code (lsh b3 16)))
     (if (and (> len 1)
@@ -324,14 +324,14 @@ This is similar to `map-char-table', but works only on syntax tables, and
        (invalid (gettext "**invalid**")) ;(empty "") ;constants
        (standard-output (or stream standard-output))
        ;; #### I18N3 should temporarily set buffer to output-translatable
-        (in #'(lambda (string)
-                (princ ",\n\t\t\t\t ")
-                (princ string)))
+       (in #'(lambda (string)
+               (princ ",\n\t\t\t\t ")
+               (princ string)))
        (syntax-string (syntax-code-to-string code)))
     (if (consp code)
        (setq code (car code)))
     (if (null syntax-string)
-        (princ invalid)
+       (princ invalid)
       (princ syntax-string)
       (princ "\tmeaning: ")
       (princ (aref ["whitespace" "punctuation" "word-constituent"
index 2b94a93..cd30615 100644 (file)
@@ -631,7 +631,7 @@ the other window."
   (bind-apollo-mouse-button "M1D" 'apollo-mouse-move-point
                            'apollo-mouse-move-point) ;MOUSE LEFT DOWN
   (bind-apollo-mouse-button "M1U" 'apollo-mouse-move-mark
-                           'apollo-mouse-copy) ;MOUSE LEFT UP 
+                           'apollo-mouse-copy) ;MOUSE LEFT UP
   (bind-apollo-mouse-button "M2D" 'sm-depress
                            'sm-depress-meta) ;MOUSE MIDDLE DOWN
   (bind-apollo-mouse-button "M2U" 'smart-key-mouse
index beb84b2..003a201 100644 (file)
@@ -45,7 +45,7 @@
 ;; country code.
 (let* ((i 128)
       (modify (function
-              (lambda (ch sy) 
+              (lambda (ch sy)
                 (modify-syntax-entry ch sy text-mode-syntax-table)
                 (if-boundp 'tex-mode-syntax-table
                     (modify-syntax-entry ch sy tex-mode-syntax-table))
index 7648252..223d5e4 100644 (file)
@@ -76,4 +76,3 @@
 (define-key function-key-map "\eOP" [kp-numlock])
 
 ;;; linux.el ends here
-
index 53d40b3..1eecdd7 100644 (file)
@@ -75,9 +75,9 @@ MOUSE-LIST is a list of atoms specifying a mouse hit according to these rules:
   * One of these atoms specifies the active region of the definition.
        text, scrollbar, modeline, minibuffer
   * One or two or these atoms specify the button or button combination.
-        left, middle, right, double
+       left, middle, right, double
   * Any combination of these atoms specify the active shift keys.
-        control, shift, meta
+       control, shift, meta
   * With a single unshifted button, you can add
        up
     to indicate an up-click.
index 9c8176e..d50a824 100644 (file)
@@ -64,7 +64,7 @@ on modeline               on \"scroll bar\"   in minibuffer
  L scroll-up               line to top         execute-extended-command
  C proportional goto-char   line to middle     mouse-help
  R scroll-down             line to bottom      eval-expression"
-  
+
   (interactive)
   (let*
 ;; expect a string of <esc>:<buttons>;<x-pos>;<y-pos>c
@@ -148,7 +148,7 @@ on modeline             on \"scroll bar\"   in minibuffer
                 ((= buttons mouse-left)
                  (call-interactively 'execute-extended-command))
                 ((= buttons mouse-center)
-                 (describe-function 'sup-mouse-report)); silly self help 
+                 (describe-function 'sup-mouse-report)); silly self help
                 ))
          (t                            ;in another window
           (select-window window)
index 0f9cc3c..c8056dd 100644 (file)
@@ -113,7 +113,7 @@ With no argument, toggle between the two possible modes.
 With a positive argument, select alternate keypad mode.
 With a negative argument, select numeric keypad mode."
   (interactive "P")
-  (setq tvi970-keypad-numeric 
+  (setq tvi970-keypad-numeric
        (if (null arg)
            (not tvi970-keypad-numeric)
          (> (prefix-numeric-value arg) 0)))
index 53621c0..9e96030 100644 (file)
@@ -44,7 +44,7 @@
 With positive argument, switch to 132-column mode.
 With negative argument, switch to 80-column mode."
  (interactive "P")
- (setq vt100-wide-mode 
+ (setq vt100-wide-mode
        (if (null arg) (not vt100-wide-mode)
          (> (prefix-numeric-value arg) 0)))
  (send-string-to-terminal (if vt100-wide-mode "\e[?3h" "\e[?3l"))
index c9cb125..31f64a0 100644 (file)
@@ -4,4 +4,3 @@
 
 ;; Make F11 an escape key.
 (define-key function-key-map "\e[23~" [?\e])
-
index c9cb125..31f64a0 100644 (file)
@@ -4,4 +4,3 @@
 
 ;; Make F11 an escape key.
 (define-key function-key-map "\e[23~" [?\e])
-
index 8bbd5a4..18b4e2d 100644 (file)
@@ -176,7 +176,7 @@ The argument NLINES says how many lines to center."
        (delete-horizontal-space)
        (setq line-length (current-column))
        (if (> (- fill-column lm line-length) 0)
-           (indent-line-to 
+           (indent-line-to
             (+ lm (/ (- fill-column lm line-length) 2))))))
     (cond ((null nlines)
           (setq nlines 0))
index 63a87f2..68e2ea0 100644 (file)
@@ -59,7 +59,7 @@
 (defcustom toolbar-open-function 'find-file
   "*Function to call when the open icon is selected."
   :type '(radio (function-item find-file)
-                (function :tag "Other"))
+               (function :tag "Other"))
   :group 'toolbar)
 
 (defun toolbar-open ()
@@ -69,7 +69,7 @@
 (defcustom toolbar-dired-function 'dired
   "*Function to call when the dired icon is selected."
   :type '(radio (function-item dired)
-                (function :tag "Other"))
+               (function :tag "Other"))
   :group 'toolbar)
 
 (defun toolbar-dired (dir)
@@ -79,7 +79,7 @@
 (defcustom toolbar-save-function 'save-buffer
   "*Function to call when the save icon is selected."
   :type '(radio (function-item save-buffer)
-                (function :tag "Other"))
+               (function :tag "Other"))
   :group 'toolbar)
 
 (defun toolbar-save ()
@@ -89,7 +89,7 @@
 (defcustom toolbar-print-function 'lpr-buffer
   "*Function to call when the print icon is selected."
   :type '(radio (function-item lpr-buffer)
-                (function :tag "Other"))
+               (function :tag "Other"))
   :group 'toolbar)
 
 (defun toolbar-print ()
@@ -99,7 +99,7 @@
 (defcustom toolbar-cut-function 'kill-primary-selection
   "*Function to call when the cut icon is selected."
   :type '(radio (function-item kill-primary-selection)
-                (function :tag "Other"))
+               (function :tag "Other"))
   :group 'toolbar)
 
 (defun toolbar-cut ()
 (defcustom toolbar-copy-function 'copy-primary-selection
   "*Function to call when the copy icon is selected."
   :type '(radio (function-item copy-primary-selection)
-                (function :tag "Other"))
+               (function :tag "Other"))
   :group 'toolbar)
 
 (defun toolbar-copy ()
 (defcustom toolbar-paste-function 'yank-clipboard-selection
   "*Function to call when the paste icon is selected."
   :type '(radio (function-item yank-clipboard-selection)
-                (function :tag "Other"))
+               (function :tag "Other"))
   :group 'toolbar)
 
 (defun toolbar-paste ()
 (defcustom toolbar-undo-function 'undo
   "*Function to call when the undo icon is selected."
   :type '(radio (function-item undo)
-                (function :tag "Other"))
+               (function :tag "Other"))
   :group 'toolbar)
 
 (defun toolbar-undo ()
 (defcustom toolbar-replace-function 'query-replace
   "*Function to call when the replace icon is selected."
   :type '(radio (function-item query-replace)
-                (function :tag "Other"))
+               (function :tag "Other"))
   :group 'toolbar)
 
 (defun toolbar-replace ()
@@ -214,7 +214,7 @@ Mail readers known by default are vm, gnus, rmail, mh, pine, elm,
                 (const vm) (const gnus) (const rmail) (const mh)
                 (const pine) (const elm) (const mutt) (const exmh)
                 (const netscape)
-                 (const send)
+                (const send)
                 (symbol :tag "Other"
                         :validate (lambda (wid)
                                     (if (assq (widget-value wid)
@@ -443,7 +443,7 @@ Newsreaders known by default are gnus, rn, nn, trn, xrn, slrn, pine
   ;; do this now because errors will occur if the icon symbols
   ;; are not initted
   (set-specifier default-toolbar initial-toolbar-spec))
-  
+
 (defun toolbar-add-item-data ( icon-list &optional icon-dir )
   (if (eq icon-dir nil)
       (setq icon-dir toolbar-icon-directory))
@@ -468,7 +468,7 @@ Newsreaders known by default are gnus, rn, nn, trn, xrn, slrn, pine
               (concat prefix "-xx.xbm"))))))
    icon-list))
 
-(defvar toolbar-vector-open 
+(defvar toolbar-vector-open
   [toolbar-file-icon            toolbar-open   t       "Open a file"]
   "Define the vector for the \"Open\" toolbar button")
 
@@ -505,7 +505,7 @@ Newsreaders known by default are gnus, rn, nn, trn, xrn, slrn, pine
   "Define the vector for the \"Spell\" toolbar button")
 
 (defvar toolbar-vector-replace
-  [toolbar-replace-icon                toolbar-replace t       "Search & Replace"]  
+  [toolbar-replace-icon                toolbar-replace t       "Search & Replace"]
   "Define the vector for the \"Replace\" toolbar button")
 
 (defvar toolbar-vector-mail
index 5851204..f92eff2 100644 (file)
 (defvar tty-win-initted nil)
 
 (defun tty-color-list (&optional registered-only)
-  "Returns the list of colors the tty can handle. Since the tty will do color 
+  "Returns the list of colors the tty can handle. Since the tty will do color
 approximation, it will return all colors.
-When argument REGISTERED-ONLY is t `tty-color-list' will return only the 
+When argument REGISTERED-ONLY is t `tty-color-list' will return only the
 registered colors of the terminal."
   (if registered-only
       (tty-registered-color-list)
-    (nconc (tty-registered-color-list) 
+    (nconc (tty-registered-color-list)
           (x-color-list))))
 
 (defun init-tty-win ()
index 34c22b4..8751d2d 100644 (file)
 
     ;; We descend recursively
     (let ((dirs (directory-files dir t nil t 'subdir))
-          dir)
+         dir)
       (while (setq dir (pop dirs))
-        (when (and (not (member (file-name-nondirectory dir)
+       (when (and (not (member (file-name-nondirectory dir)
                                update-elc-ignored-dirs))
-                   (file-directory-p dir))
-          (do-update-elc-2 dir compile-stage-p seen))))
+                  (file-directory-p dir))
+         (do-update-elc-2 dir compile-stage-p seen))))
 
     )))
 
index 403e7cd..eca0f19 100644 (file)
@@ -71,9 +71,9 @@
 (load "dump-paths.el")
 
 (let ((autol (packages-list-autoloads
-              (if (getenv "BUILD_TREE_ROOT")
-                  (expand-file-name "lisp" (getenv "BUILD_TREE_ROOT"))
-                (concat default-directory "../lisp")))))
+             (if (getenv "BUILD_TREE_ROOT")
+                 (expand-file-name "lisp" (getenv "BUILD_TREE_ROOT"))
+               (concat default-directory "../lisp")))))
 
   ;;(print (prin1-to-string autol))
   (while autol
@@ -88,8 +88,8 @@
 
 (let (preloaded-file-list site-load-packages need-to-dump dumped-exe)
   (load (if (getenv "SOURCE_TREE_ROOT")
-            (expand-file-name "lisp/dumped-lisp.el" (getenv "SOURCE_TREE_ROOT"))
-          (concat default-directory "../lisp/dumped-lisp.el")))
+           (expand-file-name "lisp/dumped-lisp.el" (getenv "SOURCE_TREE_ROOT"))
+         (concat default-directory "../lisp/dumped-lisp.el")))
 
   (setq dumped-exe
        (cond ((file-exists-p "../src/sxemacs") "../src/sxemacs")
   ;; Path setup
   (let ((package-preloaded-file-list
         (packages-collect-package-dumped-lisps late-package-load-path)))
+
     (setq preloaded-file-list
-         (append package-preloaded-file-list
-                 preloaded-file-list
+         (append package-preloaded-file-list
+                 preloaded-file-list
                  '("bytecomp")
-                 packages-hardcoded-lisp)))
+                 packages-hardcoded-lisp)))
 
   (load (concat default-directory "../site-packages") t t)
   (setq preloaded-file-list
               arg)))
            (when (and dumped-exe
                       (or (let ((frobel
-                                  (if (getenv "SOURCE_TREE_ROOT")
-                                      (expand-file-name
-                                       (concat "lisp/" frob ".el")
-                                       (getenv "SOURCE_TREE_ROOT"))
-                                    (concat "../lisp/" frob ".el"))))
-                             (and (file-exists-p frobel)
-                                  (file-newer-than-file-p frobel dumped-exe)))
-                           (let ((frobelc
-                                  (if (getenv "BUILD_TREE_ROOT")
-                                      (expand-file-name
-                                       (concat "lisp/" frob ".elc")
-                                       (getenv "BUILD_TREE_ROOT"))
-                                    (concat "../lisp/" frob ".elc"))))
-                             (and (file-exists-p frobelc)
-                                  (file-newer-than-file-p frobelc dumped-exe)))))
+                                 (if (getenv "SOURCE_TREE_ROOT")
+                                     (expand-file-name
+                                      (concat "lisp/" frob ".el")
+                                      (getenv "SOURCE_TREE_ROOT"))
+                                   (concat "../lisp/" frob ".el"))))
+                            (and (file-exists-p frobel)
+                                 (file-newer-than-file-p frobel dumped-exe)))
+                          (let ((frobelc
+                                 (if (getenv "BUILD_TREE_ROOT")
+                                     (expand-file-name
+                                      (concat "lisp/" frob ".elc")
+                                      (getenv "BUILD_TREE_ROOT"))
+                                   (concat "../lisp/" frob ".elc"))))
+                            (and (file-exists-p frobelc)
+                                 (file-newer-than-file-p frobelc dumped-exe)))))
              (setq need-to-dump t)))
 
 ;      (if (null (member (file-name-nondirectory arg)
index 6322480..598845b 100644 (file)
@@ -41,7 +41,7 @@
        (let ((tem (let ((inhibit-quit t)
                         (cursor-in-echo-area t))
                     (prog1 (downcase (read-char))
-                           (setq quit-flag nil)))))
+                           (setq quit-flag nil)))))
          (if (= tem help-char)
              (ask-user-about-lock-help)
            (setq answer (assoc tem '((?s . t)
@@ -80,7 +80,7 @@ You can <q>uit; don't modify this file.")
     (let (answer)
       (while (null answer)
        (message "%s changed on disk; really edit the buffer? (y, n, r or C-h) "
-                 (file-name-nondirectory filename))
+                (file-name-nondirectory filename))
        (let ((tem (downcase (let ((cursor-in-echo-area t))
                               (read-char)))))
          (setq answer
@@ -107,7 +107,7 @@ You can <q>uit; don't modify this file.")
                 (signal 'file-supersession
                         (list "File changed on disk" filename))))))
       (message
-        "File on disk now will become a backup file if you save these changes.")
+       "File on disk now will become a backup file if you save these changes.")
       (setq buffer-backed-up nil))))
 
 (defun ask-user-about-supersession-help ()
index 8f999b1..6991be1 100644 (file)
@@ -53,16 +53,16 @@ Warning, this variable did not exist in XEmacs versions prior to 20.3")
 ;; +  (or (string-match "\\([0-9]+\\)\\.\\([0-9]+\\)" emacs-version)
 ;;        (error "dired does not work with emacs version %s" emacs-version))
 ;;    (setq ver (string-to-int (substring emacs-version (match-beginning 1)
-;;                                   (match-end 1)))
+;;                                   (match-end 1)))
 ;; @@ -6617,7 +6617,7 @@
-;; 
+;;
 ;;  (let ((lucid-p (string-match "XEmacs" emacs-version))
 ;;        ver)
 ;; -  (or (string-match "^\\([0-9]+\\)\\." emacs-version)
 ;; +  (or (string-match "\\([0-9]+\\)\\." emacs-version)
 ;;        (error "Weird emacs version %s" emacs-version))
 ;;    (setq ver (string-to-int (substring emacs-version (match-beginning 1)
-;;                                   (match-end 1))))
+;;                                   (match-end 1))))
 
 (if (featurep 'infodock)
     (require 'id-vers))
@@ -80,7 +80,7 @@ to the system configuration; look at `system-configuration' instead."
   (interactive "p")
   (save-match-data
     (let ((version-string
-          (format 
+          (format
            "SXEmacs: %s, built %s on %s"
            sxemacs-git-version
            emacs-build-time
index d1fce9f..4308531 100644 (file)
 
 (defvar widget-browse-mode-map nil
   "Keymap for `widget-browse-mode'.")
-  
+
 (unless widget-browse-mode-map
   (setq widget-browse-mode-map (make-sparse-keymap))
   (set-keymap-parent widget-browse-mode-map widget-keymap)
   (define-key widget-browse-mode-map "q" 'bury-buffer))
 
-(easy-menu-define widget-browse-mode-customize-menu 
+(easy-menu-define widget-browse-mode-customize-menu
     widget-browse-mode-map
   "Menu used in widget browser buffers."
   (customize-menu-create 'widgets))
 
-(easy-menu-define widget-browse-mode-menu 
+(easy-menu-define widget-browse-mode-menu
     widget-browse-mode-map
   "Menu used in widget browser buffers."
   '("Widget"
@@ -108,7 +108,7 @@ if that value is non-nil."
 ;;;###autoload
 (defun widget-browse (widget)
   "Create a widget browser for WIDGET."
-  (interactive (list (completing-read "Widget: " 
+  (interactive (list (completing-read "Widget: "
                                      obarray
                                      (lambda (symbol)
                                        (get symbol 'widget-type))
@@ -128,7 +128,7 @@ if that value is non-nil."
     (kill-buffer (get-buffer-create "*Browse Widget*"))
     (switch-to-buffer (get-buffer-create "*Browse Widget*")))
   (widget-browse-mode)
-  
+
   ;; Quick way to get out.
 ;;  (widget-create 'push-button
 ;;              :action (lambda (widget &optional event)
@@ -191,7 +191,7 @@ The :value of the widget shuld be the widget to be browsed."
   :action 'widget-browse-action)
 
 (defun widget-browse-action (widget &optional event)
-  ;; Create widget browser for WIDGET's :value. 
+  ;; Create widget browser for WIDGET's :value.
   (widget-browse (widget-get widget :value)))
 
 (defun widget-browse-value-create (widget)
@@ -289,7 +289,7 @@ With arg, turn widget mode on if and only if arg is positive."
 
 (add-to-list 'minor-mode-alist '(widget-minor-mode " Widget"))
 
-(add-to-list 'minor-mode-map-alist 
+(add-to-list 'minor-mode-map-alist
             (cons 'widget-minor-mode widget-minor-mode-map))
 
 ;;; The End:
index 8637175..c1345c1 100644 (file)
@@ -330,7 +330,7 @@ menu will be used, otherwise the minibuffer is used."
   (mouse-set-point event)
   (let ((pos (event-point event)))
     (if (and pos (get-char-property pos 'button))
-        (widget-button-click event))))
+       (widget-button-click event))))
 \f
 ;;; Widget text specifications.
 ;;
@@ -419,7 +419,7 @@ invoking `widget-setup'."
     (when secret
       (let ((begin (widget-field-start field))
            (end (widget-field-end field)))
-       (when size 
+       (when size
          (while (and (> end begin)
                      (eq (char-after (1- end)) ?\ ))
            (setq end (1- end))))
@@ -591,15 +591,15 @@ Suitable for use with `map-extents'."
 (defun widget-specify-active (widget)
   "Make WIDGET active for user modifications."
   (let ((inactive (widget-get widget :inactive))
-        (from (widget-get widget :from))
-        (to (widget-get widget :to)))
+       (from (widget-get widget :from))
+       (to (widget-get widget :to)))
     (when (and inactive (not (extent-detached-p inactive)))
       ;; Reactivate the buttons and fields covered by the extent.
       (map-extents 'widget-activation-widget-mapper
-                   nil from to :activate nil 'button-or-field)
+                  nil from to :activate nil 'button-or-field)
       ;; Reactivate the glyphs.
       (map-extents 'widget-activation-glyph-mapper
-                   nil from to :activate nil 'end-glyph)
+                  nil from to :activate nil 'end-glyph)
       (delete-extent inactive)
       (widget-put widget :inactive nil))))
 
@@ -723,10 +723,10 @@ ARGS are passed as extra arguments to the function."
   ;; of the widget type by `widget-prompt-value'.
   (unless prompt
     (setq prompt (or (and (widget-get widget :tag)
-                          (replace-in-string (widget-get widget :tag)
-                                             "^[ \t]+" "" t))
-                     default-prompt
-                     "Value")))
+                         (replace-in-string (widget-get widget :tag)
+                                            "^[ \t]+" "" t))
+                    default-prompt
+                    "Value")))
   (widget-prompt-spaceify prompt))
 
 ;;;###autoload
@@ -739,10 +739,10 @@ The current value is assumed to be VALUE, unless UNBOUND is non-nil."
   (setq widget (widget-convert widget))
   (let ((answer (widget-apply widget
                              :prompt-value
-                              (format "%s[%s]"
-                                      (widget-prompt widget prompt)
-                                      (widget-type widget))
-                              value unbound)))
+                             (format "%s[%s]"
+                                     (widget-prompt widget prompt)
+                                     (widget-type widget))
+                             value unbound)))
     (while (not (widget-apply widget :match answer))
       (setq answer (signal 'error (list "Answer does not match type"
                                        answer (widget-type widget)))))
@@ -1811,11 +1811,11 @@ If that does not exists, call the value of `widget-complete-field'."
            (lambda ()                  ;?\]
              (setq button-end (point-marker))
              (set-marker-insertion-type button-end nil))
-           (lambda ()                  ;?\{ 
+           (lambda ()                  ;?\{
              (setq sample-begin (point)))
            (lambda ()                  ;?\}
              (setq sample-end (point)))
-           (lambda ()                  ;?n 
+           (lambda ()                  ;?n
              (when (widget-get widget :indent)
                (insert ?\n)
                (insert-char ?\  (widget-get widget :indent))))
@@ -2734,21 +2734,21 @@ Return an alist of (TYPE MATCH)."
 (defun widget-checklist-prompt-value (widget prompt value unbound)
   ;; Prompt for items to be selected, and the prompt for their value
   (let* ((args (widget-get widget :args))
-         (choices (mapcar (lambda (elt)
-                            (cons (widget-get elt :tag) elt))
-                          args))
-         (continue t)
-         value)
+        (choices (mapcar (lambda (elt)
+                           (cons (widget-get elt :tag) elt))
+                         args))
+        (continue t)
+        value)
     (while continue
       (setq continue (completing-read
-                      (concat (widget-prompt-spaceify prompt)
-                              "select [ret. when done]: ")
-                      choices nil t))
+                     (concat (widget-prompt-spaceify prompt)
+                             "select [ret. when done]: ")
+                     choices nil t))
       (if (string= continue "")
-          (setq continue nil)
-        (push (widget-prompt-value (cdr (assoc continue choices))
-                                   prompt nil t)
-              value)))
+         (setq continue nil)
+       (push (widget-prompt-value (cdr (assoc continue choices))
+                                  prompt nil t)
+             value)))
     (nreverse value)))
 
 (defun widget-checklist-validate (widget)
@@ -3203,29 +3203,29 @@ The parent of several `radio-button' widgets, one for each option."
     (widget-apply
      widget :value-to-external
      (if unbound
-         (mapcar #'(lambda (arg)
-                     (widget-prompt-value
-                      arg
-                      (concat (widget-prompt-spaceify prompt)
-                              (widget-prompt arg nil ""))
-                      nil t))
-                 args)
+        (mapcar #'(lambda (arg)
+                    (widget-prompt-value
+                     arg
+                     (concat (widget-prompt-spaceify prompt)
+                             (widget-prompt arg nil ""))
+                     nil t))
+                args)
        ;; If VALUE is bound, the situation is a bit more complex because we
        ;; have to split it into a list of default values for every child. Oh,
        ;; boy, do I miss 'cl here... -- dvl
        (let ((children args)
-             (defaults (widget-apply widget
+            (defaults (widget-apply widget
 :value-to-internal value))
-             child default result)
-         (while (setq child (pop children))
-           (setq default (pop defaults))
-           (push
-            (widget-prompt-value
-             child
-             (concat (widget-prompt-spaceify prompt)
-                     (widget-prompt child nil ""))
-             default) result))
-         (nreverse result))))))
+            child default result)
+        (while (setq child (pop children))
+          (setq default (pop defaults))
+          (push
+           (widget-prompt-value
+            child
+            (concat (widget-prompt-spaceify prompt)
+                    (widget-prompt child nil ""))
+            default) result))
+        (nreverse result))))))
 
 (defun widget-group-match (widget values)
   ;; Match if the components match.
@@ -3915,7 +3915,7 @@ Either the `:match' or the `:match-alternatives' property must be defined."
       ;; If VALUE is invalid (it doesn't match any choice), discard it by
       ;; considering it unbound:
       (unless old
-        (setq unbound t)))
+       (setq unbound t)))
     ;; Now offer the choice, providing the given default value when/where
     ;; appropriate:
     (while args
@@ -3926,22 +3926,22 @@ Either the `:match' or the `:match-alternatives' property must be defined."
                        current)
                  choices)))
     (setq current
-          (let ((val (completing-read (concat prompt ": ") choices nil t
-                                      (when old
-                                        (widget-apply old :menu-tag-get)))))
-            (if (stringp val) ;; #### is this really needed ? --dvl
+         (let ((val (completing-read (concat prompt ": ") choices nil t
+                                     (when old
+                                       (widget-apply old :menu-tag-get)))))
+           (if (stringp val) ;; #### is this really needed ? --dvl
                (let ((try (try-completion val choices)))
                  (when (stringp try) ;; #### and this ? --dvl
                    (setq val try))
                  (cdr (assoc val choices)))
              nil)))
     (if current
-        (widget-prompt-value current
-                             (concat (widget-prompt-spaceify prompt)
-                                     (widget-get current :tag))
-                             (unless unbound
-                               (when (eq current old) value))
-                             (or unbound (not (eq current old))))
+       (widget-prompt-value current
+                            (concat (widget-prompt-spaceify prompt)
+                                    (widget-get current :tag))
+                            (unless unbound
+                              (when (eq current old) value))
+                            (or unbound (not (eq current old))))
       (and (not unbound) value))))
 
 (define-widget 'radio 'radio-button-choice
@@ -4085,8 +4085,8 @@ Here we attempt to define my-list as a choice of either the constant
 nil, or a cons-cell containing a sexp and my-lisp.  This will not work
 because the `choice' widget does not allow recursion.
 
-Using the `lazy' widget you can overcome this problem, as in this 
-example: 
+Using the `lazy' widget you can overcome this problem, as in this
+example:
 
   (define-widget 'sexp-list 'lazy
     \"A list of sexps.\"
@@ -4095,7 +4095,7 @@ example:
   :format "%{%t%}: %v"
   ;; We don't convert :type because we want to allow recursive
   ;; datastructures.  This is slow, so we should not create speed
-  ;; critical widgets by deriving from this. 
+  ;; critical widgets by deriving from this.
   :convert-widget 'widget-value-convert-widget
   :value-create 'widget-type-value-create
   :value-delete 'widget-children-value-delete
@@ -4124,10 +4124,10 @@ Store the newly created widget in the :children attribute.
 The value of the :type attribute should be an unconverted widget type."
   (let ((value (widget-get widget :value))
        (type (widget-get widget :type)))
-    (widget-put widget :children 
-                (list (widget-create-child-value widget 
-                                                 (widget-convert type)
-                                                 value)))))
+    (widget-put widget :children
+               (list (widget-create-child-value widget
+                                                (widget-convert type)
+                                                value)))))
 
 (defun widget-type-default-get (widget)
   "Get default value from the :type attribute of WIDGET.
index 5de4e7e..247081f 100644 (file)
@@ -620,11 +620,11 @@ Returns the window displaying BUFFER."
                                                 2)
                                              (window-height upper))
                                           nil upper))
-                       ;; Klaus Berndl <klaus.berndl@sdm.de>: Only in
-                       ;; this situation we shrink-to-fit but we can do
-                       ;; this first after we have displayed buffer in
-                       ;; window (s.b. (set-window-buffer window buffer))
-                       (setq shrink-it shrink-to-fit))))
+                      ;; Klaus Berndl <klaus.berndl@sdm.de>: Only in
+                      ;; this situation we shrink-to-fit but we can do
+                      ;; this first after we have displayed buffer in
+                      ;; window (s.b. (set-window-buffer window buffer))
+                      (setq shrink-it shrink-to-fit))))
 
               (setq window (get-lru-window target-frame)))
 
@@ -637,11 +637,11 @@ Returns the window displaying BUFFER."
 
             (set-window-buffer window buffer)
 
-             ;; Now window's previous buffer has been brought to the top
-             ;; of the MRU chain and window displays buffer - now we can
-             ;; shrink-to-fit if necessary
-             (if shrink-it
-                 (shrink-window-if-larger-than-buffer window))
+            ;; Now window's previous buffer has been brought to the top
+            ;; of the MRU chain and window displays buffer - now we can
+            ;; shrink-to-fit if necessary
+            (if shrink-it
+                (shrink-window-if-larger-than-buffer window))
 
             (display-buffer-1 window)))))
     (or (equal wconfig (current-window-configuration))
index 0f23596..9933a2a 100644 (file)
@@ -159,7 +159,7 @@ even if it is inactive."
   "Make all visible windows the same height (approximately)."
   (interactive)
   (let ((count -1) levels newsizes size)
-        ;FSFmacs
+       ;FSFmacs
        ;;; Don't count the lines that are above the uppermost windows.
        ;;; (These are the menu bar lines, if any.)
        ;(mbl (nth 1 (window-edges (frame-first-window (selected-frame))))))
@@ -168,8 +168,8 @@ even if it is inactive."
     (save-window-excursion
       (let (tops (prev-top -2))
        (walk-windows (function (lambda (w)
-                        (setq tops (cons (nth 1 (window-pixel-edges w))
-                                         tops))))
+                       (setq tops (cons (nth 1 (window-pixel-edges w))
+                                        tops))))
                      'nomini)
        (setq tops (sort tops '<))
        (while tops
@@ -184,17 +184,17 @@ even if it is inactive."
     (setq size (/ (window-pixel-height (frame-root-window)) count))
     (walk-windows (function
                   (lambda (w)
-                    (select-window w)
-                    (let ((newtop (cdr (assq (nth 1 (window-pixel-edges))
-                                             levels)))
-                          (newbot (or (cdr (assq
+                   (select-window w)
+                   (let ((newtop (cdr (assq (nth 1 (window-pixel-edges))
+                                            levels)))
+                         (newbot (or (cdr (assq
                                            (+ (window-pixel-height)
                                               (nth 1 (window-pixel-edges)))
                                            levels))
-                                      count)))
-                      (setq newsizes
-                            (cons (cons w (* size (- newbot newtop)))
-                                  newsizes)))))
+                                     count)))
+                     (setq newsizes
+                           (cons (cons w (* size (- newbot newtop)))
+                                 newsizes)))))
                  'nomini)
     (walk-windows (function (lambda (w)
                              (select-window w)
@@ -202,7 +202,7 @@ even if it is inactive."
                                (enlarge-window
                                 (/ (- newsize (window-pixel-height))
                                    (face-height 'default))))))
-                  'nomini)))
+                 'nomini)))
 \f
 ;;; I think this should be the default; I think people will prefer it--rms.
 (defcustom split-window-keep-point t
@@ -363,8 +363,8 @@ If `window-system', search all devices on window-system consoles.
 Any other non-nil value means search all devices."
   (let ((wins nil))
     (walk-windows (lambda (win)
-                    (push win wins))
-                  minibuf which-frames which-devices)
+                   (push win wins))
+                 minibuf which-frames which-devices)
     wins))
 
 ;;; window.el ends here
index 9cc1c9a..4f3cf1c 100644 (file)
 
 (defun x-read-color-completion-table ()
   "Color table for interactive completion"
-  (unless (and (skiplistp x-color-slist) 
+  (unless (and (skiplistp x-color-slist)
               (> (skiplist-size x-color-slist) 0))
     (x-color-read-system-colors))
   (let ((res))
-    (map-skiplist #'(lambda (key val) 
-                     (setq res (nconc res (list (list (format "%s" key)))))) 
+    (map-skiplist #'(lambda (key val)
+                     (setq res (nconc res (list (list (format "%s" key))))))
                  x-color-slist)
     res))
 
 (defun x-color-list ()
   "Color list"
-  (unless (and (skiplistp x-color-slist) 
+  (unless (and (skiplistp x-color-slist)
               (> (skiplist-size x-color-slist) 0))
     (x-color-read-system-colors))
   (let ((res))
-    (map-skiplist #'(lambda (key val) 
+    (map-skiplist #'(lambda (key val)
                      (setq res (nconc res (list (format "%s" key)))))
                  x-color-slist)
     res))
   "Retrieve the color by NAME"
   (interactive)
   (x-color-rgb-components name))
-  
+
 (defun x-find-color-rgb (name &optional nearest)
   "Retrieve the color by NAME"
-  (unless (or (symbolp name) 
+  (unless (or (symbolp name)
              (stringp name)
              (x-rgb-color-p name))
     (error 'wrong-type-argument name))
-  (unless (and (skiplistp x-color-slist) 
+  (unless (and (skiplistp x-color-slist)
               (> (skiplist-size x-color-slist) 0))
     (x-color-read-system-colors))
   (if (x-rgb-color-p name)
@@ -94,7 +94,7 @@
           (color-sym (intern color-name))
           (color-lc-sym (intern (downcase color-name)))
           (color-ns-sym (intern (replace-in-string color-name " " "")))
-          (color-lcns-sym (intern (replace-in-string 
+          (color-lcns-sym (intern (replace-in-string
                                    (downcase color-name)
                                    " " ""))))
       (or (get-skiplist x-color-slist color-sym)
   "Parse RGB color specification and return a list of integers (R G B).
 #FEFEFE and rgb:fe/fe/fe style specifications are parsed.
 Returns NIL if RGB color specification is invalid."
-  (let ((case-fold-search t) 
+  (let ((case-fold-search t)
        matches)
-    (if (string-match #r"\([0-9.]+\)\s-+\([0-9.]+\)\s-+\([0-9.]+\)" 
+    (if (string-match #r"\([0-9.]+\)\s-+\([0-9.]+\)\s-+\([0-9.]+\)"
                      color)
        ;; recurse and parse hexadecimal color
-       (x-color-parse-rgb-components 
-        (apply 'format "#%02X%02X%02X" 
+       (x-color-parse-rgb-components
+        (apply 'format "#%02X%02X%02X"
                (mapcar #'(lambda (c) (if (floatp c) c (* 255 c)))
                        (mapcar #'(lambda (i)
-                                   (let ((m 
-                                          (string-to-number 
+                                   (let ((m
+                                          (string-to-number
                                            (match-string i color))))
                                      (if (<= 0 m 1)
                                          (* 255 m)
@@ -139,7 +139,7 @@ Returns NIL if RGB color specification is invalid."
       (setq matches (mapcar #'(lambda (i) (match-string i color))
                            '(1 2 3)))
       ;; Make sure all components have at most 4 hex digits
-      (when (eval 
+      (when (eval
             (append '(and)
                     (mapcar #'(lambda (component)
                                 (> 5 (length component) 0))
@@ -189,7 +189,7 @@ Returns NIL if RGB color specification is invalid."
 into their components.
 RGB values for color names are looked up using 'x-find-color-rgb'."
   (let ((case-fold-search t)
-       (color-rgb 
+       (color-rgb
         (cond ((x-rgb-color-p color)
                (mapcar #'(lambda (f)
                            (funcall f color))
@@ -205,20 +205,20 @@ RGB values for color names are looked up using 'x-find-color-rgb'."
                     (= 3 (length color)))
                color))))
     (cond ((and color-rgb
-               (eval (append '(and) 
-                             (mapcar #'(lambda (c) 
+               (eval (append '(and)
+                             (mapcar #'(lambda (c)
                                          (and (numberp c) (<= 0 c 1)))
                                      color))))
           (mapcar #'(lambda (c) (* 65535 c)) color))
          ((and color-rgb
-               (eval (append '(and) 
-                             (mapcar #'(lambda (c) 
+               (eval (append '(and)
+                             (mapcar #'(lambda (c)
                                          (and (numberp c) (<= 0 c 255)))
                                      color))))
           (mapcar #'(lambda (c) (lsh c 8)) color))
          ((and color-rgb
-               (eval (append '(or) 
-                             (mapcar #'(lambda (c) 
+               (eval (append '(or)
+                             (mapcar #'(lambda (c)
                                          (and (numberp c) (<= 0 c 65535)))
                                      color))))
           color)
@@ -233,7 +233,7 @@ RGB values for color names are looked up using 'x-find-color-rgb'."
 (defun x-read-rgb-file (filename)
   "Read the colors from FILENAME. The file is expected to have the same
 format as X11 rgb.txt"
-  (let ((rgb-regex 
+  (let ((rgb-regex
         #r"^\s-*\([0-9]+\)\s-+\([0-9]+\)\s-+\([0-9]+\)\s-+\([a-zA-Z0-9 ]+\)\s-*$"))
     (unless (skiplistp x-color-slist)
       (setq x-color-slist (make-skiplist)))
@@ -250,21 +250,21 @@ format as X11 rgb.txt"
            (widen)
            (goto-char (point-min))
            (while (re-search-forward rgb-regex nil t)
-             (let ((rgb-matches 
-                    (mapcar #'(lambda (i) 
+             (let ((rgb-matches
+                    (mapcar #'(lambda (i)
                                 (lsh (read (match-string i)) 8))
                             '(1 2 3)))
                    (color-name (match-string 4)))
                (mapc #'(lambda (name)
                          (put-skiplist x-color-slist
-                                       (intern name) 
+                                       (intern name)
                                        rgb-matches))
-                     (list color-name 
+                     (list color-name
                            (downcase color-name)
                            (replace-in-string color-name " " "")
-                           (replace-in-string (downcase color-name) 
+                           (replace-in-string (downcase color-name)
                                               " " "")))))))))))
-  
+
 (defun x-color-read-system-colors ()
   "Read the system colors"
   (when (locate-data-file "rgb.txt")
@@ -304,7 +304,7 @@ of gray, thus the name."
          (dB (- (caddr color1) (caddr color2))))
       (+ (* dR dR) (* dG dG) (* dB dB)))))
 
-    
+
 (defsubst x-color-distance-1 (color1 color2)
   "Return the color cube distance between the two colors.
 Assumes COLOR1 is an 8 bit rgb tupple. "
@@ -321,7 +321,7 @@ Assumes COLOR1 is an 8 bit rgb tupple. "
 
 (defvar x-nearest-color-favor-non-gray-threshold 0.065
   "If the approximated color is not close enough to the
-gray diagonal of the RGB cube, favor non-gray colors. 
+gray diagonal of the RGB cube, favor non-gray colors.
 The default number 0.065 is an empirical ad-hoc'ery")
 
 (defun x-nearest-color (color &optional colorlist) "
@@ -329,14 +329,14 @@ Return the nearest COLOR in COLORLIST.
 COLOR can be a color name, an '(r g b) tuple or a color specification.
 #FEFEFE and rgb:fe/fe/fe style specifications are parsed.
 COLORLIST is a list of colors in the same acceptable formats as COLOR.
-Returns NIL if color specification is invalid, or no colors 
+Returns NIL if color specification is invalid, or no colors
 close enough are found."
   (let (color-rgb)
     (when (or (stringp color) (symbolp color))
       (setq color-rgb (x-rgb-to-8bits (find-color-rgb color))))
     (when (not color-rgb)
       (error 'invalid-argument color))
-    (let ((favor-non-gray (>= (apply 'x-color-off-gray-diag color-rgb) 
+    (let ((favor-non-gray (>= (apply 'x-color-off-gray-diag color-rgb)
                              x-nearest-color-favor-non-gray-threshold))
          (best-distance 195076)        ;; Max possible distance: 3 * 255^2 + 15
          best-color)
@@ -349,8 +349,8 @@ close enough are found."
                        (< distance best-distance)
                        ;; The candidate color is on the gray diagonal
                        ;; if its RGB components are all equal.
-                       (or (/= (x-rgb-color-red cand-rgb) 
-                               (x-rgb-color-green cand-rgb)) 
+                       (or (/= (x-rgb-color-red cand-rgb)
+                               (x-rgb-color-green cand-rgb))
                            (/= (x-rgb-color-green cand-rgb)
                                (x-rgb-color-blue cand-rgb))
                            (not favor-non-gray)))
index abc9461..eb9d8cc 100644 (file)
@@ -73,9 +73,9 @@
 
 ;;; Regexps matching font names in "Host Portable Character Representation."
 ;;;
-(let ((-               "[-?]")
+(let ((-               "[-?]")
       (foundry         "[^-]*")
-      (family          "[^-]*")
+      (family          "[^-]*")
       (weight          #r"\(bold\|demibold\|medium\|black\)")  ; 1
 ;     (weight\?                "\\(\\*\\|bold\\|demibold\\|medium\\|\\)")      ; 1
       (weight\?                #r"\([^-]*\)")                                  ; 1
index 254d5e8..b9a7844 100644 (file)
@@ -72,7 +72,7 @@ It must be set at run-time.")
 This is run the first time that a font-menu is needed for each device.
 If you don't like the lazy invocation of this function, you can add it to
 `create-device-hook' and that will make the font menus respond more quickly
-when they are selected for the first time.  If you add fonts to your system, 
+when they are selected for the first time.  If you add fonts to your system,
 or if you change your font path, you can call this to re-initialize the menus."
   ;; by Stig@hackvan.com
   ;; #### - this should implement a `menus-only' option, which would
@@ -135,11 +135,11 @@ or if you change your font path, you can call this to re-initialize the menus."
             (setq sizes (cons (car common) sizes)))
            (setq common (cdr common)))
          (setq sizes (delq 0 sizes))))
-    
+
     (setq families (sort families 'string-lessp)
          weights  (sort weights 'string-lessp)
          sizes    (sort sizes '<))
-    
+
     (dolist (entry cache)
       (aset entry 1 (sort (aref entry 1) 'string-lessp))
       (aset entry 2 (sort (aref entry 2) '<)))
@@ -202,18 +202,18 @@ or if you change your font path, you can call this to re-initialize the menus."
       (setq entry  (vassoc family (aref dcache 0))))
     (when (null entry)
       (return-from x-font-menu-font-data (make-vector 5 nil)))
-    
+
     (when (string-match x-font-regexp name)
       (setq weight (capitalize    (match-string 1 name)))
       (setq size   (string-to-int (match-string 6 name))))
-      
+
     (when (string-match x-font-regexp truename)
       (when (not (member weight (aref entry 1)))
        (setq weight (capitalize (match-string 1 truename))))
       (when (not (member size   (aref entry 2)))
        (setq size (string-to-int (match-string 6 truename))))
       (setq slant (capitalize (match-string 2 truename))))
-      
+
     (vector entry family size weight slant)))
 
 (defun x-font-menu-load-font (family weight size slant resolution)
index 0aaf4b0..ddde8aa 100644 (file)
               ;; is managing, so assume all MIT displays are Suns...  HA HA!
               (string-equal "MIT X Consortium" vendor)
               (string-equal "X Consortium" vendor))
-           ;; Ok, we think this could be a Sun keyboard.  Run the Sun code.
+          ;; Ok, we think this could be a Sun keyboard.  Run the Sun code.
           (x-win-init-sun))
-          ((string-match "XFree86" vendor)
-           ;; Those XFree86 people do some weird keysym stuff, too.
+         ((string-match "XFree86" vendor)
+          ;; Those XFree86 people do some weird keysym stuff, too.
           (x-win-init-xfree86)))))
 
 \f
     (setq character-set-property 'x-iso8859/1) ; see x-iso8859-1.el
 
     (setq initial-frame-plist (if initial-frame-unmapped-p
-                                  '(initially-unmapped t)
-                                nil))
+                                 '(initially-unmapped t)
+                               nil))
     (setq pre-x-win-initted t)))
 
 (defvar x-win-initted nil)
     ;; Open the X display when this file is loaded
     ;; (Note that the first frame is created later.)
     (setq x-initial-argv-list (cons (car command-line-args)
-                                    command-line-args-left))
+                                   command-line-args-left))
     ;; Locate the app-defaults directory
     (when (and (boundp 'x-app-defaults-directory)
               (null x-app-defaults-directory))
     ;; because the icon initialization needs to access the display to get
     ;; any toolbar-related color resources.
     (if (and (not (featurep 'infodock)) (featurep 'toolbar))
-        (init-x-toolbar))
+       (init-x-toolbar))
     (if (and (featurep 'infodock) (featurep 'toolbar))
        (require 'id-x-toolbar))
     (if (featurep 'gutter) (init-gutter))
index 085404e..ddce62d 100644 (file)
@@ -52,7 +52,7 @@
 (defconst iso8859/1-code-to-x-keysym-table nil
   "Maps iso8859/1 to an X keysym name which corresponds to it.
 There may be more than one X name for this keycode; this returns the first one.
-Note that this is X specific; one should avoid using this table whenever 
+Note that this is X specific; one should avoid using this table whenever
 possible, in the interest of portability.")
 
 ;; (This esoteric little construct is how you do MACROLET in elisp.  It
@@ -67,7 +67,7 @@ possible, in the interest of portability.")
        ;;
        ;; First emit code that puts the `x-iso8859/1' property on all of
        ;; the keysym symbols.
-       ;; 
+       ;;
        (mapcar '(lambda (sym-and-code)
                  (list 'put (list 'quote (car sym-and-code))
                        ''x-iso8859/1 (car (cdr sym-and-code))))
@@ -75,7 +75,7 @@ possible, in the interest of portability.")
        ;;
        ;; Then emit code that binds all of those keysym symbols to
        ;; `self-insert-command'.
-       ;; 
+       ;;
        (mapcar '(lambda (sym-and-code)
                  (list 'global-set-key (list 'quote (car sym-and-code))
                        ''self-insert-command))
@@ -112,7 +112,7 @@ possible, in the interest of portability.")
  (currency             ?\244)
  (yen                  ?\245)
  (brokenbar            ?\246)
- (section              ?\247)
+ (section              ?\247)
  (diaeresis            ?\250)
  (copyright            ?\251)
  (ordfeminine          ?\252)
@@ -125,10 +125,10 @@ possible, in the interest of portability.")
  (plusminus            ?\261)
  (twosuperior          ?\262)
  (threesuperior                ?\263)
- (acute                        ?\264)  ; Why is there an acute keysym that is 
- (mu                   ?\265)  ; distinct from apostrophe/quote, but 
+ (acute                        ?\264)  ; Why is there an acute keysym that is
+ (mu                   ?\265)  ; distinct from apostrophe/quote, but
  (paragraph            ?\266)  ; no grave keysym that is distinct from
- (periodcentered       ?\267)  ; backquote? 
+ (periodcentered       ?\267)  ; backquote?
  (cedilla              ?\270)  ; I've added the grave keysym, because it's
  (onesuperior          ?\271)  ; used in x-compose (Heiko Muenkel).
  (masculine            ?\272)
index cb8dfde..5f262d1 100644 (file)
@@ -82,7 +82,7 @@ to the cut buffer."
       (x-store-cutbuffer
        (mapconcat
        #'identity
-       (declare-fboundp 
+       (declare-fboundp
         (extract-rectangle
          (extent-start-position (car primary-selection-extent))
          (extent-end-position (car (reverse primary-selection-extent)))))
index 0581e6c..ea28940 100644 (file)
@@ -52,7 +52,7 @@
       (x-init-specifier-from-resources
        (specifier-fallback scrollbar-width) 'natnum locale
        '("scrollbar.width" . "ScrollBar.Width")))
-      
+
   ;; lather, rinse, repeat.
   (x-init-specifier-from-resources
    (specifier-fallback scrollbar-height) 'natnum locale