Commit dbc4e1c1 authored by Jim Blandy's avatar Jim Blandy

JimB's changes since January 18th

parent 72766144
......@@ -231,7 +231,6 @@ lib-src/Makefile: ${srcdir}/lib-src/Makefile.in Makefile
-e 's|^LOADLIBES *=.*$$|LOADLIBES='"${libsrc_libs}"'|' \
-e '/^# DIST: /d') > lib-src/Makefile.tmp
${srcdir}/move-if-change lib-src/Makefile.tmp lib-src/Makefile
# Remind people not to edit this.
chmod -w lib-src/Makefile
src/Makefile: ${srcdir}/src/Makefile.in Makefile
......@@ -248,7 +247,6 @@ src/Makefile: ${srcdir}/src/Makefile.in Makefile
-e 's|^CONFIG_CFLAGS *=.*$$|CONFIG_CFLAGS='"${CONFIG_CFLAGS}"'|' \
-e '/^# DIST: /d') > src/Makefile.tmp
${srcdir}/move-if-change src/Makefile.tmp src/Makefile
# Remind people not to edit this.
chmod -w src/Makefile
oldXMenu/Makefile: ${srcdir}/oldXMenu/Makefile Makefile
......@@ -262,10 +260,10 @@ Makefile:
# ==================== Installation ====================
## If we let lib-src do its own installation, that means we
## don't have to duplicate the list of utilities to install in
## this Makefile as well.
install: all mkdir
## If we let lib-src do its own installation, that means we
## don't have to duplicate the list of utilities to install in
## this Makefile as well.
(cd lib-src; $(MAKE) install ${MFLAGS} bindir=${bindir} libdir=${libdir})
-set ${COPYDESTS} ; \
for dir in ${COPYDIR} ; do \
......@@ -297,10 +295,10 @@ install: all mkdir
-rm -f ${bindir}/emacs
ln ${bindir}/emacs-${version} ${bindir}/emacs
## If we let lib-src do its own installation, that means we
## don't have to duplicate the list of utilities to install in
## this Makefile as well.
install.sysv: all mkdir
## If we let lib-src do its own installation, that means we
## don't have to duplicate the list of utilities to install in
## this Makefile as well.
(cd lib-src; $(MAKE) install ${MFLAGS} bindir=${bindir} libdir=${libdir})
-set ${COPYDESTS} ; \
for dir in ${COPYDIR} ; do \
......@@ -330,10 +328,10 @@ install.sysv: all mkdir
-cpset src/emacs ${bindir}/emacs-${version} 1755 bin bin
-ln ${bindir}/emacs-${version} ${bindir}/emacs
## If we let lib-src do its own installation, that means we
## don't have to duplicate the list of utilities to install in
## this Makefile as well.
install.xenix: all mkdir
## If we let lib-src do its own installation, that means we
## don't have to duplicate the list of utilities to install in
## this Makefile as well.
(cd lib-src; $(MAKE) install ${MFLAGS} bindir=${bindir} libdir=${libdir})
-set ${COPYDESTS} ; \
for dir in ${COPYDIR} ; do \
......@@ -368,10 +366,10 @@ install.xenix: all mkdir
chmod 1755 ${bindir}/emacs
-rm -f ${bindir}/emacs.old
## If we let lib-src do its own installation, that means we
## don't have to duplicate the list of utilities to install in
## this Makefile as well.
install.aix: all mkdir
## If we let lib-src do its own installation, that means we
## don't have to duplicate the list of utilities to install in
## this Makefile as well.
(cd lib-src; $(MAKE) install ${MFLAGS} bindir=${bindir} libdir=${libdir})
-set ${COPYDESTS} ; \
for dir in ${COPYDIR} ; do \
......
......@@ -1091,7 +1091,7 @@ it just adds completion characters to the end of the filename."
(let ((ch (read-char)))
(if (= ch ?\ )
(set-window-configuration conf)
(setq unread-command-event ch))))))))
(setq unread-command-events (list ch)))))))))
;;; Converting process modes to use comint mode
;;; ===========================================================================
......
......@@ -63,8 +63,8 @@ Calls value of `electric-buffer-menu-mode-hook' on entry if non-nil.
(setq select
(catch 'electric-buffer-menu-select
(message "<<< Press Space to bury the buffer list >>>")
(if (= (setq unread-command-event (read-char)) ?\ )
(progn (setq unread-command-event nil)
(if (= (setq unread-command-events (list (read-char))) ?\ )
(progn (setq unread-command-events nil)
(throw 'electric-buffer-menu-select nil)))
(let ((first (progn (goto-char (point-min))
(forward-line 2)
......@@ -196,7 +196,7 @@ electric-buffer-menu-mode-hook if it is non-nil."
(defun Electric-buffer-menu-exit ()
(interactive)
(setq unread-command-event last-input-char)
(setq unread-command-events (list last-input-char))
;; for robustness
(condition-case ()
(throw 'electric-buffer-menu-select nil)
......
......@@ -119,8 +119,8 @@ BUFFER is put into `default-major-mode' (or `fundamental-mode') when we exit"
(catch 'exit
(if (pos-visible-in-window-p (point-max))
(progn (message "<<< Press Space to bury the help buffer >>>")
(if (= (setq unread-command-event (read-char)) ?\ )
(progn (setq unread-command-event nil)
(if (= (setq unread-command-events (list (read-char))) ?\ )
(progn (setq unread-command-events nil)
(throw 'exit t)))))
(let (up down both neither
(standard (and (eq (key-binding " ")
......
......@@ -85,7 +85,7 @@
cmd this-command)
(if (or (prog1 quit-flag (setq quit-flag nil))
(= last-input-char ?\C-g))
(progn (setq unread-command-event nil
(progn (setq unread-command-events nil
prefix-arg nil)
;; If it wasn't cancelling a prefix character, then quit.
(if (or (= (length (this-command-keys)) 1)
......@@ -101,7 +101,7 @@
(setq last-command this-command)
(if (or (prog1 quit-flag (setq quit-flag nil))
(= last-input-char ?\C-g))
(progn (setq unread-command-event nil)
(progn (setq unread-command-events nil)
(if (not inhibit-quit)
(progn (ding)
(message "Quit")
......
......@@ -41,6 +41,7 @@
(defvar disassemble-recursive-indent 3 "*")
;;;###autoload
(defun disassemble (object &optional buffer indent interactive-p)
"Print disassembled code for OBJECT in (optional) BUFFER.
OBJECT can be a symbol defined as a function, or a function itself
......@@ -136,7 +137,7 @@ redefine OBJECT if it is a symbol."
(insert "\n"))))
(cond ((and (consp obj) (assq 'byte-code obj))
(disassemble-1 (assq 'byte-code obj) indent))
((compiled-function-p obj)
((byte-code-function-p obj)
(disassemble-1 obj indent))
(t
(insert "Uncompiled body: ")
......@@ -195,14 +196,14 @@ OBJ should be a call to BYTE-CODE generated by the byte compiler."
(setq arg (car arg))
;; but if the value of the constant is compiled code, then
;; recursively disassemble it.
(cond ((or (compiled-function-p arg)
(cond ((or (byte-code-function-p arg)
(and (eq (car-safe arg) 'lambda)
(assq 'byte-code arg))
(and (eq (car-safe arg) 'macro)
(or (compiled-function-p (cdr arg))
(or (byte-code-function-p (cdr arg))
(and (eq (car-safe (cdr arg)) 'lambda)
(assq 'byte-code (cdr arg))))))
(cond ((compiled-function-p arg)
(cond ((byte-code-function-p arg)
(insert "<compiled-function>\n"))
((eq (car-safe arg) 'lambda)
(insert "<compiled lambda>"))
......
......@@ -1480,7 +1480,7 @@ Should be 0 at the top level.")
(last-command last-command)
(this-command this-command)
(last-input-char last-input-char)
;; Assume no edebug command sets unread-command-char.
;; Assume no edebug command sets unread-command-events.
;; (unread-command-char -1)
(debug-on-error debug-on-error)
......
......@@ -2910,7 +2910,7 @@ SPC, it is ignored; if it is anything else, it is processed as a command."
(enlarge-window 1))
(let ((c (read-char)))
(if (/= c 32)
(setq unread-command-event c))))))))
(setq unread-command-events (list c)))))))))
;; Improved auto-save file names.
;; This function fixes many problems with the standard auto-save file names:
......
......@@ -333,9 +333,9 @@ vi mode. ARG is used as the prefix value for the executed command. If
CHAR is given it becomes the first character of the command."
(interactive "P")
(let (com (buff (current-buffer)) (first t))
(if char (setq unread-command-event char))
(if char (setq unread-command-events (list char)))
(setq prefix-arg arg)
(while (or first unread-command-event)
(while (or first unread-command-events)
;; this while loop is executed until unread command char will be
;; exhausted.
(setq first nil)
......@@ -393,7 +393,7 @@ obtained so far, and COM is the command part obtained so far."
(while (= char ?U)
(vip-describe-arg prefix-arg)
(setq char (read-char)))
(setq unread-command-event char))
(setq unread-command-events (list char)))
(defun vip-prefix-arg-com (char value com)
"Vi operator as prefix argument."
......@@ -447,7 +447,7 @@ obtained so far, and COM is the command part obtained so far."
(while (= char ?U)
(vip-describe-arg prefix-arg)
(setq char (read-char)))
(setq unread-command-event char))
(setq unread-command-events (list char)))
;; as com is non-nil, this means that we have a command to execute
(if (or (= (car com) ?r) (= (car com) ?R))
;; execute apropriate region command.
......
......@@ -113,7 +113,7 @@ These supercede the values given in default-frame-alist.")
;;; need to see if it should go away or change. Create a text frame
;;; here.
(defun frame-notice-user-settings ()
(if (live-frame-p frame-initial-frame)
(if (frame-live-p frame-initial-frame)
(progn
;; If the user wants a minibuffer-only frame, we'll have to
;; make a new one; you can't remove or add a root window to/from
......
......@@ -2287,7 +2287,7 @@ If argument UNREAD is non-nil, only unread article is selected."
(let ((char (read-char)))
(if (= char cmd)
(gnus-Subject-next-group nil)
(setq unread-command-event char))))
(setq unread-command-events (list char)))))
)
))
)))
......
......@@ -293,7 +293,7 @@ C-w print information on absence of warranty for GNU Emacs."
(princ (cond ((stringp def) "a keyboard macro.")
((subrp def)
(concat beg "built-in function."))
((compiled-function-p def)
((byte-code-function-p def)
(concat beg "compiled Lisp function."))
((symbolp def)
(format "alias for `%s'." def))
......
......@@ -768,7 +768,7 @@ N is the digit argument used to invoke this command."
(message (if flag "Type Space to see more"
"Type Space to return to Info"))
(if (/= ?\ (setq ch (read-char)))
(progn (setq unread-command-event ch) nil)
(progn (setq unread-command-events (list ch)) nil)
flag))
(scroll-up)))))
......
......@@ -4,7 +4,7 @@
;; LCD Archive Entry:
;; isearch-mode|Daniel LaLiberte|liberte@cs.uiuc.edu
;; |A minor mode replacement for isearch.el.
;; |$Date: 1992/11/07 06:17:04 $|$Revision: 1.15 $|~/modes/isearch-mode.el
;; |$Date: 1992/11/16 01:37:06 $|$Revision: 1.16 $|~/modes/isearch-mode.el
;; This file is not yet part of GNU Emacs, but it is based almost
;; entirely on isearch.el which is part of GNU Emacs.
......@@ -88,8 +88,15 @@
;;;====================================================================
;;; Change History
;;; $Header: /home/gd/gnu/emacs/19.0/lisp/RCS/isearch-mode.el,v 1.15 1992/11/07 06:17:04 jimb Exp jimb $
;;; $Header: /home/gd/gnu/emacs/19.0/lisp/RCS/isearch-mode.el,v 1.16 1992/11/16 01:37:06 jimb Exp jimb $
;;; $Log: isearch-mode.el,v $
; Revision 1.16 1992/11/16 01:37:06 jimb
; * bytecomp.el: Declare unread-command-char an obsolete variable.
; * vip.el (vip-escape-to-emacs, vip-prefix-arg-value,
; vip-prefix-arg-com): Use unread-command-event instead of
; unread-command-char; respect its new semantics.
; * isearch-mode.el (isearch-update, isearch-unread): Same.
;
; Revision 1.15 1992/11/07 06:17:04 jimb
; * isearch.el (isearch-frames-exist): This isn't what we want -
; replaced by...
......@@ -557,7 +564,7 @@ is treated as a regexp. See \\[isearch-forward] for more info."
(if (if isearch-event-data-type
(null unread-command-event)
(if isearch-gnu-emacs-events
(null unread-command-event)
(null unread-command-events)
(< unread-command-char 0)))
(progn
(if (not (input-pending-p))
......@@ -1413,6 +1420,7 @@ have special meaning in a regexp."
;; To quiet the byte-compiler.
(defvar unread-command-event)
(defvar unread-command-events)
(defvar last-command-event)
(defun isearch-char-to-string (c)
......@@ -1429,7 +1437,7 @@ have special meaning in a regexp."
(isearch-event-data-type
(setq unread-command-event char-or-event))
(isearch-gnu-emacs-events
(setq unread-command-event char-or-event))
(setq unread-command-events (list char-or-event)))
(t
(setq unread-command-char char-or-event))))
......
......@@ -100,7 +100,7 @@ the current %s and exit."
prompt char elt tail
(next (if (or (symbolp list)
(subrp list)
(compiled-function-p list)
(byte-code-function-p list)
(and (consp list)
(eq (car list) 'lambda)))
(function (lambda ()
......@@ -157,7 +157,7 @@ the current %s and exit."
(funcall actor elt)
(setq actions (1+ actions))))))
((= ?? char)
(setq unread-command-event help-char)
(setq unread-command-events (list help-char))
(setq next (` (lambda ()
(setq next '(, next))
'(, elt)))))
......
;;; mouse.el --- window system-independent mouse support.
;;; Copyright (C) 1988, 1992 Free Software Foundation, Inc.
;;; Copyright (C) 1988, 1992, 1993 Free Software Foundation, Inc.
;; Maintainer: FSF
;; Keywords: hardware
......@@ -40,11 +40,12 @@ The `posn-' functions access elements of such lists."
(nth 1 event))
(defsubst event-end (event)
"Return the ending location of EVENT. EVENT should be a drag event.
"Return the ending location of EVENT. EVENT should be a click or drag event.
If EVENT is a click event, this function is the same as `event-start'.
The return value is of the form
(WINDOW BUFFER-POSITION (COL . ROW) TIMESTAMP)
The `posn-' functions access elements of such lists."
(nth 2 event))
(nth (1- (length event)) event))
(defsubst posn-window (position)
"Return the window in POSITION.
......@@ -113,7 +114,7 @@ This command must be bound to a mouse click."
The window is split at the column clicked on.
This command must be bound to a mouse click."
(interactive "@e")
(split-window-horizontally (1+ (car (mouse-coords click)))))
(split-window-horizontally (1+ (car (posn-col-row (event-end click))))))
(defun mouse-set-point (click)
"Move point to the position clicked on with the mouse.
......@@ -173,6 +174,14 @@ This does not delete the region; it acts like \\[kill-ring-save]."
(mouse-set-mark click)
(call-interactively 'kill-ring-save))
;;; This function used to delete the text between point and the mouse
;;; whenever it was equal to the front of the kill ring, but some
;;; people found that confusing.
;;; A list (TEXT START END), describing the text and position of the last
;;; invocation of mouse-save-then-kill.
(defvar mouse-save-then-kill-posn nil)
(defun mouse-save-then-kill (click)
"Save text to point in kill ring; the second time, kill the text.
If the text between point and the mouse is the same as what's
......@@ -181,18 +190,24 @@ Otherwise, it adds the text to the kill ring, like \\[kill-ring-save],
which prepares for a second click to delete the text."
(interactive "e")
(let ((click-posn (posn-point (event-start click))))
(if (string= (buffer-substring (point) click-posn) (car kill-ring))
;; If this text was already saved in kill ring,
;; now delete it from the buffer.
(if (and (eq last-command 'kill-region)
mouse-save-then-kill-posn
(eq (car mouse-save-then-kill-posn) (car kill-ring))
(equal (cdr mouse-save-then-kill-posn) (list (point) click-posn)))
;; If this is the second time we've called
;; mouse-save-then-kill, delete the text from the buffer.
(progn
(let ((buffer-undo-list t))
(delete-region (point) (mark)))
;; Make the undo list by hand so it is shared.
(setq buffer-undo-list
(cons (cons (car kill-ring) (point)) buffer-undo-list)))
(if (not (eq buffer-undo-list t))
(setq buffer-undo-list
(cons (cons (car kill-ring) (point)) buffer-undo-list))))
;; Otherwise, save this region.
(mouse-set-mark click)
(call-interactively 'kill-ring-save))))
(call-interactively 'kill-ring-save)
(setq mouse-save-then-kill-posn
(list (car kill-ring) (point) click-posn)))))
(defun mouse-buffer-menu (event)
"Pop up a menu of buffers for selection with the mouse.
......@@ -225,329 +240,331 @@ and selects that window."
(select-window window)
(switch-to-buffer buf))))))
;; Commands for the scroll bar.
(defun mouse-scroll-down (click)
(interactive "@e")
(scroll-down (1+ (cdr (mouse-coords click)))))
(defun mouse-scroll-up (click)
(interactive "@e")
(scroll-up (1+ (cdr (mouse-coords click)))))
(defun mouse-scroll-down-full ()
(interactive "@")
(scroll-down nil))
(defun mouse-scroll-up-full ()
(interactive "@")
(scroll-up nil))
(defun mouse-scroll-move-cursor (click)
(interactive "@e")
(move-to-window-line (1+ (cdr (mouse-coords click)))))
(defun mouse-scroll-absolute (event)
(interactive "@e")
(let* ((pos (car event))
(position (car pos))
(length (car (cdr pos))))
(if (<= length 0) (setq length 1))
(let* ((scale-factor (max 1 (/ length (/ 8000000 (buffer-size)))))
(newpos (* (/ (* (/ (buffer-size) scale-factor)
position)
length)
scale-factor)))
(goto-char newpos)
(recenter '(4)))))
(defun mouse-scroll-left (click)
(interactive "@e")
(scroll-left (1+ (car (mouse-coords click)))))
(defun mouse-scroll-right (click)
(interactive "@e")
(scroll-right (1+ (car (mouse-coords click)))))
(defun mouse-scroll-left-full ()
(interactive "@")
(scroll-left nil))
(defun mouse-scroll-right-full ()
(interactive "@")
(scroll-right nil))
(defun mouse-scroll-move-cursor-horizontally (click)
(interactive "@e")
(move-to-column (1+ (car (mouse-coords click)))))
(defun mouse-scroll-absolute-horizontally (event)
(interactive "@e")
(let* ((pos (car event))
(position (car pos))
(length (car (cdr pos))))
(set-window-hscroll (selected-window) 33)))
(global-set-key [scroll-bar mouse-1] 'mouse-scroll-up)
(global-set-key [scroll-bar mouse-2] 'mouse-scroll-absolute)
(global-set-key [scroll-bar mouse-3] 'mouse-scroll-down)
(global-set-key [vertical-slider mouse-1] 'mouse-scroll-move-cursor)
(global-set-key [vertical-slider mouse-2] 'mouse-scroll-move-cursor)
(global-set-key [vertical-slider mouse-3] 'mouse-scroll-move-cursor)
(global-set-key [thumbup mouse-1] 'mouse-scroll-up-full)
(global-set-key [thumbup mouse-2] 'mouse-scroll-up-full)
(global-set-key [thumbup mouse-3] 'mouse-scroll-up-full)
(global-set-key [thumbdown mouse-1] 'mouse-scroll-down-full)
(global-set-key [thumbdown mouse-2] 'mouse-scroll-down-full)
(global-set-key [thumbdown mouse-3] 'mouse-scroll-down-full)
(global-set-key [horizontal-scroll-bar mouse-1] 'mouse-scroll-left)
(global-set-key [horizontal-scroll-bar mouse-2]
'mouse-scroll-absolute-horizontally)
(global-set-key [horizontal-scroll-bar mouse-3] 'mouse-scroll-right)
(global-set-key [horizontal-slider mouse-1]
'mouse-scroll-move-cursor-horizontally)
(global-set-key [horizontal-slider mouse-2]
'mouse-scroll-move-cursor-horizontally)
(global-set-key [horizontal-slider mouse-3]
'mouse-scroll-move-cursor-horizontally)
(global-set-key [thumbleft mouse-1] 'mouse-scroll-left-full)
(global-set-key [thumbleft mouse-2] 'mouse-scroll-left-full)
(global-set-key [thumbleft mouse-3] 'mouse-scroll-left-full)
(global-set-key [thumbright mouse-1] 'mouse-scroll-right-full)
(global-set-key [thumbright mouse-2] 'mouse-scroll-right-full)
(global-set-key [thumbright mouse-3] 'mouse-scroll-right-full)
(global-set-key [horizontal-scroll-bar S-mouse-2]
'mouse-split-window-horizontally)
(global-set-key [mode-line S-mouse-2]
'mouse-split-window-horizontally)
(global-set-key [vertical-scroll-bar S-mouse-2]
'mouse-split-window)
;;; These need to be rewritten for the new scrollbar implementation.
;;;!! ;; Commands for the scroll bar.
;;;!!
;;;!! (defun mouse-scroll-down (click)
;;;!! (interactive "@e")
;;;!! (scroll-down (1+ (cdr (mouse-coords click)))))
;;;!!
;;;!! (defun mouse-scroll-up (click)
;;;!! (interactive "@e")
;;;!! (scroll-up (1+ (cdr (mouse-coords click)))))
;;;!!
;;;!! (defun mouse-scroll-down-full ()
;;;!! (interactive "@")
;;;!! (scroll-down nil))
;;;!!
;;;!! (defun mouse-scroll-up-full ()
;;;!! (interactive "@")
;;;!! (scroll-up nil))
;;;!!
;;;!! (defun mouse-scroll-move-cursor (click)
;;;!! (interactive "@e")
;;;!! (move-to-window-line (1+ (cdr (mouse-coords click)))))
;;;!!
;;;!! (defun mouse-scroll-absolute (event)
;;;!! (interactive "@e")
;;;!! (let* ((pos (car event))
;;;!! (position (car pos))
;;;!! (length (car (cdr pos))))
;;;!! (if (<= length 0) (setq length 1))
;;;!! (let* ((scale-factor (max 1 (/ length (/ 8000000 (buffer-size)))))
;;;!! (newpos (* (/ (* (/ (buffer-size) scale-factor)
;;;!! position)
;;;!! length)
;;;!! scale-factor)))
;;;!! (goto-char newpos)
;;;!! (recenter '(4)))))
;;;!!
;;;!! (defun mouse-scroll-left (click)
;;;!! (interactive "@e")
;;;!! (scroll-left (1+ (car (mouse-coords click)))))
;;;!!
;;;!! (defun mouse-scroll-right (click)
;;;!! (interactive "@e")
;;;!! (scroll-right (1+ (car (mouse-coords click)))))
;;;!!
;;;!! (defun mouse-scroll-left-full ()
;;;!! (interactive "@")
;;;!! (scroll-left nil))
;;;!!
;;;!! (defun mouse-scroll-right-full ()
;;;!! (interactive "@")
;;;!! (scroll-right nil))
;;;!!
;;;!! (defun mouse-scroll-move-cursor-horizontally (click)
;;;!! (interactive "@e")
;;;!! (move-to-column (1+ (car (mouse-coords click)))))
;;;!!
;;;!! (defun mouse-scroll-absolute-horizontally (event)
;;;!! (interactive "@e")
;;;!! (let* ((pos (car event))
;;;!! (position (car pos))
;;;!! (length (car (cdr pos))))
;;;!! (set-window-hscroll (selected-window) 33)))
;;;!!
;;;!! (global-set-key [scroll-bar mouse-1] 'mouse-scroll-up)
;;;!! (global-set-key [scroll-bar mouse-2] 'mouse-scroll-absolute)
;;;!! (global-set-key [scroll-bar mouse-3] 'mouse-scroll-down)
;;;!!
;;;!! (global-set-key [vertical-slider mouse-1] 'mouse-scroll-move-cursor)
;;;!! (global-set-key [vertical-slider mouse-2] 'mouse-scroll-move-cursor)
;;;!! (global-set-key [vertical-slider mouse-3] 'mouse-scroll-move-cursor)
;;;!!
;;;!! (global-set-key [thumbup mouse-1] 'mouse-scroll-up-full)
;;;!! (global-set-key [thumbup mouse-2] 'mouse-scroll-up-full)
;;;!! (global-set-key [thumbup mouse-3] 'mouse-scroll-up-full)
;;;!!
;;;!! (global-set-key [thumbdown mouse-1] 'mouse-scroll-down-full)
;;;!! (global-set-key [thumbdown mouse-2] 'mouse-scroll-down-full)
;;;!! (global-set-key [thumbdown mouse-3] 'mouse-scroll-down-full)
;;;!!
;;;!! (global-set-key [horizontal-scroll-bar mouse-1] 'mouse-scroll-left)
;;;!! (global-set-key [horizontal-scroll-bar mouse-2]
;;;!! 'mouse-scroll-absolute-horizontally)
;;;!! (global-set-key [horizontal-scroll-bar mouse-3] 'mouse-scroll-right)
;;;!!
;;;!! (global-set-key [horizontal-slider mouse-1]
;;;!! 'mouse-scroll-move-cursor-horizontally)
;;;!! (global-set-key [horizontal-slider mouse-2]
;;;!! 'mouse-scroll-move-cursor-horizontally)
;;;!! (global-set-key [horizontal-slider mouse-3]
;;;!! 'mouse-scroll-move-cursor-horizontally)
;;;!!
;;;!! (global-set-key [thumbleft mouse-1] 'mouse-scroll-left-full)
;;;!! (global-set-key [thumbleft mouse-2] 'mouse-scroll-left-full)
;;;!! (global-set-key [thumbleft mouse-3] 'mouse-scroll-left-full)
;;;!!
;;;!! (global-set-key [thumbright mouse-1] 'mouse-scroll-right-full)
;;;!! (global-set-key [thumbright mouse-2] 'mouse-scroll-right-full)
;;;!! (global-set-key [thumbright mouse-3] 'mouse-scroll-right-full)
;;;!!
;;;!! (global-set-key [horizontal-scroll-bar S-mouse-2]
;;;!! 'mouse-split-window-horizontally)
;;;!! (global-set-key [mode-line S-mouse-2]
;;;!! 'mouse-split-window-horizontally)
;;;!! (global-set-key [vertical-scroll-bar S-mouse-2]
;;;!! 'mouse-split-window)
;;;;
;;;; Here are experimental things being tested. Mouse events
;;;; are of the form:
;;;; ((x y) window screen-part key-sequence timestamp)
;;
;;;;
;;;; Dynamically track mouse coordinates
;;;;
;;
;;(defun track-mouse (event)
;; "Track the coordinates, absolute and relative, of the mouse."
;; (interactive "@e")
;; (while mouse-grabbed
;; (let* ((pos (read-mouse-position (selected-screen)))
;; (abs-x (car pos))
;; (abs-y (cdr pos))
;; (relative-coordinate (coordinates-in-window-p
;; (list (car pos) (cdr pos))
;; (selected-window))))
;; (if (consp relative-coordinate)
;; (message "mouse: [%d %d], (%d %d)" abs-x abs-y
;; (car relative-coordinate)
;; (car (cdr relative-coordinate)))
;; (message "mouse: [%d %d]" abs-x abs-y)))))
;;
;; Dynamically put a box around the line indicated by point
;;
;;
;;(require 'backquote)
;;
;;(defun mouse-select-buffer-line (event)
;; (interactive "@e")
;; (let ((relative-coordinate
;; (coordinates-in-window-p (car event) (selected-window)))
;; (abs-y (car (cdr (car event)))))
;; (if (consp relative-coordinate)
;; (progn
;; (save-excursion
;; (move-to-window-line (car (cdr relative-coordinate)))
;; (x-draw-rectangle
;; (selected-screen)
;; abs-y 0
;; (save-excursion
;; (move-to-window-line (car (cdr relative-coordinate)))
;; (end-of-line)
;; (push-mark nil t)
;; (beginning-of-line)
;; (- (region-end) (region-beginning))) 1))
;; (sit-for 1)
;; (x-erase-rectangle (selected-screen))))))
;;
;;(defvar last-line-drawn nil)
;;(defvar begin-delim "[^ \t]")
;;(defvar end-delim "[^ \t]")
;;
;;(defun mouse-boxing (event)
;; (interactive "@e")
;; (save-excursion
;; (let ((screen (selected-screen)))
;; (while (= (x-mouse-events) 0)
;; (let* ((pos (read-mouse-position screen))
;; (abs-x (car pos))
;; (abs-y (cdr pos))
;; (relative-coordinate
;; (coordinates-in-window-p (` ((, abs-x) (, abs-y)))
;; (selected-window)))
;; (begin-reg nil)
;; (end-reg nil)
;; (end-column nil)
;; (begin-column nil))
;; (if (and (consp relative-coordinate)
;; (or (not last-line-drawn)
;; (not (= last-line-drawn abs-y))))