Article View: gnu.epoch.misc
Article #1527Re: Re: SKY-mouse and Epoch 4
From: Tom Emerson
Date: Wed, 18 Mar 1992 15:59
Date: Wed, 18 Mar 1992 15:59
130 lines
5614 bytes
5614 bytes
bosch@loria.fr (Guido Bosch) writes:
Guido> Did anybody succeded in using the SKY mouse package with Epoch 4? I
Guido> loaded the SKY mouse package for Epoch 3.2 but it complained with
Guido> "Symbol's value as variable is void: drag-button"
Guido> whenever I click with the mouse.
Yes, this is because with the release of Epoch 4.0 beta buttons were renamed
to zones. I patched epoch-mouse-base to take these name changes into account,
and fixed another small bug that crept in between 3.2 and 4.0 . I posted the
diffs to the epoch-design list, but didn't post them here. They follow at the
end of this message.
Tom
#! /bin/sh
# This is a shell archive. Remove anything before this line, then unpack
# it by saving it into a file and typing "sh file". To overwrite existing
# files, type "sh file -c". You can also feed this as standard input via
# unshar, or by typing "sh <file", e.g.. If this archive is complete, you
# will see the following message at the end:
# "End of shell archive."
# Contents: epoch-mouse-base.diff
# Wrapped by tree@newton on Wed Mar 18 10:59:09 1992
PATH=/bin:/usr/bin:/usr/ucb ; export PATH
if test -f 'epoch-mouse-base.diff' -a "${1}" != "-c" ; then
echo shar: Will not clobber existing file \"'epoch-mouse-base.diff'\"
else
echo shar: Extracting \"'epoch-mouse-base.diff'\" \(2818 characters\)
sed "s/^X//" >'epoch-mouse-base.diff' <<'END_OF_FILE'
X*** epoch-mouse-base.el.orig Mon Feb 4 18:57:40 1991
X--- epoch-mouse-base.el Wed Feb 19 09:59:43 1992
X***************
X*** 15,18 ****
X--- 15,24 ----
X ;;;* rebinds mouse-keys and set C-h z to mouse help.
X ;;;* HISTORY:
X+ ;;;* Feb 19 08:23 1992 (tree@uvm.edu): made appropriate changed to function
X+ ;;;* names to coincide with the renaming of epoch buttons to zones
X+ ;;;* (Epoch 4.0b0).
X+ ;;;* Oct 31 12:06 1991 (tree@uvm.edu): made a minor modification for Epoch 4.0
X+ ;;;* alpha (PL1) to explicitly define the style for highlighting
X+ ;;;* (mark-region).
X ;;;* Jan 25 17:57 1991 (hws): check mouse handling also when thrown out of
X ;;;* motion handling.
X***************
X*** 181,185 ****
X (save-excursion-info)
X (goto-char (car arg))
X! (if (null drag-button) (set-mouse-marker))
X (mark-region (mark) (point))
X (extend-mouse-drag arg)
X--- 187,191 ----
X (save-excursion-info)
X (goto-char (car arg))
X! (if (null drag-zone) (set-mouse-marker))
X (mark-region (mark) (point))
X (extend-mouse-drag arg)
X***************
X*** 197,201 ****
X (progn
X (setq mouse::downp nil)
X! (mouse::copy-button drag-button)
X (goto-char (car arg)))
X (while (not done)
X--- 203,207 ----
X (progn
X (setq mouse::downp nil)
X! (mouse::copy-zone drag-zone)
X (goto-char (car arg)))
X (while (not done)
X***************
X*** 214,217 ****
X--- 220,231 ----
X (current-screen))))
X
X+ ;;; This was hacked by Tree, 21.10.91 to work with Epoch4.0a1.
X+ ;;; Evidently we need to explicitly set the style to be used for
X+ ;;; underlining in epoch::mark-region. This seems to work.
X+ (setq underline-style (epoch::make-style))
X+ (epoch::set-style-foreground underline-style (foreground))
X+ (epoch::set-style-background underline-style (background))
X+ (epoch::set-style-underline underline-style (foreground))
X+
X (defun mark-region (from to)
X "Mark the current region and put the region contents into
X***************
X*** 219,231 ****
X ;; mark only if necessary
X (when (/= from to)
X! (cond (drag-button
X! (epoch::move-button drag-button from to))
X (t
X! (setq drag-button (epoch::add-button from to 1 nil))))
X (epoch::redisplay-screen)))
X
X (defun forget-region ()
X! (epoch::delete-button drag-button)
X! (setq drag-button nil))
X
X (fset 'get-cut-buffer (function epoch::get-cut-buffer))
X--- 233,245 ----
X ;; mark only if necessary
X (when (/= from to)
X! (cond (drag-zone
X! (epoch::move-zone drag-zone from to))
X (t
X! (setq drag-zone (epoch::add-zone from to underline-style nil))))
X (epoch::redisplay-screen)))
X
X (defun forget-region ()
X! (epoch::delete-zone drag-zone)
X! (setq drag-zone nil))
X
X (fset 'get-cut-buffer (function epoch::get-cut-buffer))
END_OF_FILE
if test 2818 -ne `wc -c <'epoch-mouse-base.diff'`; then
echo shar: \"'epoch-mouse-base.diff'\" unpacked with wrong size!
fi
# end of 'epoch-mouse-base.diff'
fi
echo shar: End of shell archive.
exit 0
--
\ Systems Programmer --- EMBA Computer Facilty
Thomas Emerson \ University of Vermont, Burlington VT 05405 USA
tree@uvm.edu /\ "Magic is real, unless declared integer"
/ \ (in-package "std-disclaimer")
Technical Details
Message-ID:
<TREE.92Mar18105932@newton.uvm.edu>Path:
arc1-ca.pugleaf.net!sparky!uunet!bonnie.concordia.ca!IRO.UMontreal.CA!matrox!emba-news.uvm.edu!emba-news.uvm.edu!treeReferences:
<BOSCH.92Mar14121250@moebius.loria.fr>Show Full Headers
Complete Article Headers
X-Google-Language: ENGLISH,ASCII-7-bit X-Google-Thread: fc7ee,126896c6c1a42a2a X-Google-Attributes: gidfc7ee,public X-Google-ArrivalTime: 1992-03-18 14:48:32 PST Path: arc1-ca.pugleaf.net!sparky!uunet!bonnie.concordia.ca!IRO.UMontreal.CA!matrox!emba-news.uvm.edu!emba-news.uvm.edu!tree From: tree@newton.uvm.edu (Tom Emerson) Newsgroups: gnu.epoch.misc Subject: Re: Re: SKY-mouse and Epoch 4 Message-ID: <TREE.92Mar18105932@newton.uvm.edu> Date: 18 Mar 92 15:59:32 GMT References: <BOSCH.92Mar14121250@moebius.loria.fr> Sender: news@uvm.edu Distribution: gnu Organization: Division of EMBA, University of Vermont Lines: 130 In-Reply-To: bosch@loria.fr's message of 14 Mar 92 11: 12:50 GMT