Thread View: gnu.epoch.misc
4 messages
4 total messages
Started by Jaeho Lee
Wed, 19 May 1993 15:34
shrink or enlarge window
Author: Jaeho Lee
Date: Wed, 19 May 1993 15:34
Date: Wed, 19 May 1993 15:34
7 lines
891 bytes
891 bytes
Is there any implementation of mouse-based shrink-window and enlarge-window in epoch? It would be great if I can point the mode-line (the mode-line spliting two windows) and drag it to enlarge or shrink the window. Thanks. -- --Jaeho
Re: shrink or enlarge window
Author: Jan Rekers
Date: Wed, 19 May 1993 21:43
Date: Wed, 19 May 1993 21:43
11 lines
1345 bytes
1345 bytes
In article <JAEHO.93May19153426@poas.engin.umich.edu>, jaeho@engin.umich.edu (Jaeho Lee) writes: |> Is there any implementation of mouse-based shrink-window and |> enlarge-window in epoch? It would be great if I can point the |> mode-line (the mode-line spliting two windows) and drag it to enlarge |> or shrink the window. According to me, the biggest advantage of epoch over emacs is the fact that you can use a separate X window for every buffer. This allows you to use your windowmanager for these kind of things. Regards, Jan Rekers
Re: shrink or enlarge window
Author: Kermit Tensmeyer
Date: Fri, 21 May 1993 20:22
Date: Fri, 21 May 1993 20:22
97 lines
4335 bytes
4335 bytes
In article <C7An0u.1Kzu@hawnews.watson.ibm.com> rekers@watson.ibm.com (Jan Rekers) writes:
>In article <JAEHO.93May19153426@poas.engin.umich.edu>, jaeho@engin.umich.edu (Jaeho Lee) writes:
>|> Is there any implementation of mouse-based shrink-window and
>|> enlarge-window in epoch? It would be great if I can point the
>|> mode-line (the mode-line spliting two windows) and drag it to enlarge
>|> or shrink the window.
>
>According to me, the biggest advantage of epoch over emacs is the fact
>that you can use a separate X window for every buffer. This allows you
>to use your windowmanager for these kind of things.
>
there is also a package called m-modeline that require basic Epoch functions
also include here for you use...
------------Cut Here--------
;;; Modeline drag support, extracted from Imouse package.
(require 'cl)
(require 'motion)
(require 'drag)
(defvar simplemouse::drag-scroll-start nil
"Where mouse-drag-scroll started.")
(defvar simplemouse::drag-scroll-win nil
"The window where mouse-drag-scroll started.")
(defvar simplemouse::drag-scroll-crs nil
"The cursor used before mouse-drag-scroll started.")
(defvar drag-modeline-glyph 116
"*The cursor glyph used to indicate drag scrolling.")
(defun eval-in-window (window &rest forms)
"Switch to WINDOW, evaluate FORMS, return to original window."
(` (let ((OriginallySelectedWindow (selected-window)))
(unwind-protect
(progn
(select-window (, window))
(,@ forms))
(select-window OriginallySelectedWindow)))))
(put 'eval-in-window 'lisp-indent-hook 1)
(defun mouse-move-modeline (mdata)
"Shrink or stretch a window by dragging its modeline."
(setq mouse::downp nil)
(setq simplemouse::drag-scroll-win (nth 2 mdata))
(setq simplemouse::drag-scroll-crs (epoch::cursor-glyph nil))
(let ((modeline (nth 3 (window-pixedges simplemouse::drag-scroll-win))))
(epoch::warp-pointer (/ (window-pixwidth simplemouse::drag-scroll-win) 2)
(- modeline 3)))
(setq simplemouse::drag-scroll-start (epoch::query-pointer))
(epoch::cursor-glyph drag-modeline-glyph)
(message "Hold button down to shrink or stretch window, release it when done."))
(defun mouse-move-modeline-terminate (mdata)
"The up click handler that goes with mouse-move-modeline.
This actually resizes the window in one fell swoop"
(unwind-protect
(let* ((drag-scroll-end (epoch::query-pointer))
(delta-y (- (nth 1 simplemouse::drag-scroll-start)
(nth 1 drag-scroll-end)))
(pixheight (window-pixheight simplemouse::drag-scroll-win))
(height (window-height simplemouse::drag-scroll-win)))
(unless (< (abs delta-y) 2)
(eval-in-window simplemouse::drag-scroll-win
(move-modeline-up (/ (* delta-y height) pixheight)))))
;; Restore normal environment.
(epoch::cursor-glyph simplemouse::drag-scroll-crs)
(message "width: %d, height: %d"
(window-width simplemouse::drag-scroll-win)
(window-height simplemouse::drag-scroll-win)))
)
(defun simplemouse-do-bindings ()
"Bind the mouse keys according to Simplemouse's preferences."
(let ((MODE-MODIFY (+ mouse-middle mouse-mode -1))
(DOWN mouse-down)
(UP mouse-up))
(global-set-mouse MODE-MODIFY DOWN 'mouse-move-modeline)
(global-set-mouse MODE-MODIFY UP 'mouse-move-modeline-terminate)
))
(simplemouse-do-bindings)
--------- Cut Here -----------
--
Kermit Tensmeyer | Intergraph Corporation
kltensme@kt8127.b23a.ingr.com | Deep in Dixie
Re: shrink or enlarge window
Author: Bob Weiner
Date: Sat, 22 May 1993 04:02
Date: Sat, 22 May 1993 04:02
23 lines
2017 bytes
2017 bytes
> In article <JAEHO.93May19153426@poas.engin.umich.edu>, jaeho@engin.umich.edu (Jaeho Lee) writes: > |> Is there any implementation of mouse-based shrink-window and > |> enlarge-window in epoch? It would be great if I can point the > |> mode-line (the mode-line spliting two windows) and drag it to enlarge > |> or shrink the window. The Hyperbole package does this among many other things, by default. You just install it according to the README instructions and you are off. It is also window-system and Emacs independent, so your standard mouse keys work the same way under Epoch, Emacs V18 and V19, Lucid Emacs, the X window system, NEXTSTEP, SunView, Apollo's DM. You get the picture. See "/anonymous@wilma.cs.brown.edu:pub/hyperbole/README" for instructions on how to the just released version of Hyperbole, V3.07, which does all this. Bob Weiner Motorola Inc. I will be out of e-mail contact for the next 2 weeks. -- Bob Weiner, Motorola, 1500 NW 22nd Ave, MS-108, Boynton Beach, FL 33426-8753 Work: 407-364-2091 Fax: 407-364-3329 INTERNET: <bob_weiner@pts.mot.com> Mot X.400: <EBW002@email.corp.mot.com>
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads