Run rmail on a new screen.

Run rmail on a new screen.

Post by Steve » Sun, 09 Aug 1992 02:25:03

  Last time I post an article asking how to run rmail on a new screen.
Thanks for Sandy Wiss at umass, Gerd Hoeren at ims, Marc Andreessen at
uiuc and John Vasta at hp, we have many good suggestion.

**  Here is John's suggestion:


>(defun rmail-other-screen ()
>  "Create another screen and run rmail in it."
>  (interactive)
>  (let*
>      ((bname (concat "RMAIL" (sys-name)))
>       (new-screen
>        (select-screen
>          (epoch::create-screen
>            nil
>            (list (cons 'title bname)
>                  (cons 'icon-name bname))))))
>    (on-map-do new-screen (function (lambda (s) (cursor-to-screen s))))
>    (mapraised-screen new-screen)
>    (kill-buffer (current-buffer))
>    (rmail)))

>  And I bind this with
>  (global-set-key "\C-z\C-r" 'rmail-other-screen)

** Gerd gives an other one: F4 - RMAIL

Quote:>   (define-key function-key-map "F4"
>       '(lambda () (interactive)
>                    (select-screen
>                      (create-screen
>                        ""
>                        (list
>                           (cons 'title "RMail")
>                           (cons 'icon-name "RMail"))))
>                    (rmail)))

** And Sandy suggests the following

>(defun make-vm-reader ()
>  (require 'vm)
>  (interactive)
>  (setq tmp-screen (current-screen))
>  (select-screen
>    (create-screen "*scratch*" (list (cons 'title "Mail Reader")
>                                     (cons 'icon-name "Mail Reader")
>                                     (cons 'geometry' "80x30"))))
>  (vm)
>  (select-screen tmp-screen))

which we can change vm to rmail would do the job.

** Gerd also kindly provid the following information.

- Show quoted text -

Quote:>We also use the following definitions on the mouse to create new
>screens from dired:

>The following functions assign the right mouse button to create a new
>screen and open a file by the name that was being pointed to.  We use
>this mainly with "dired", but it works anytime there is a file name in
>the buffer.

>;; Mouse button assignments (GerdH 26-May-92):
>;;  Left:     - Mark
>;;  Shift/Left        - Extend Mark
>;;  Middle        - Paste
>;;  Shift/Middle  - Cut
>;;  Right     - Create window/edit file
>;;  Shift/Right       - Remove window/kill buffer

>;; Use mouse to bring up a file
>(defun pointer-get-filename ()
>  "Return name of file pointed to on this line.
>Value returned normally includes the default directory name.
>If the name pointed to starts with a slash, then name is
>returned as is."
>  (interactive)
>  (save-excursion
>      (skip-chars-backward "^ \*\"<(\n\t")
>      (let ((beg (point)))
>         (skip-chars-forward "^ \*\">)\n\t")
>         (if (equal (substring (buffer-substring beg (point)) 0 1) "/")
>             (buffer-substring beg (point))
>             (concat default-directory  (buffer-substring beg (point)))))))

>;; This function creates a new screen when finding a file.
>(defun my-find-file (filename)
>  "Edit file FILENAME.
>Switch to a buffer visiting file FILENAME,
>creating one if none already exists."
>  (interactive "FFind file: ")
>  (select-screen
>   (create-screen
>    filename
>    (list
>     (cons 'title filename)
>     (cons 'icon-name (file-name-nondirectory filename)))))
>  (switch-to-buffer (find-file-noselect filename)))

>;; Change extended selection to shift left mouse
>(global-set-mouse mouse-left mouse-shift 'extend-mouse-drag)
>(global-set-mouse mouse-left mouse-shift-up 'end-mouse-drag)

>;; Assign right mouse to view a file
>(global-set-mouse mouse-right mouse-down
>        '(lambda (arg) (mouse::set-point arg)))
>(global-set-mouse mouse-right mouse-up
>        '(lambda (arg) (my-find-file (pointer-get-filename))))

>;; Shift/Middle is "Cut"
>(global-set-mouse mouse-middle mouse-shift-up
>        '(lambda (arg) (interactive)
>             (message "%d lines cut to clipboard"
>             (count-lines (point) (mark)))
>             (copy-to-register 116 (region-beginning) (region-end) t)))

>;; Shift/Right mouse is kill buffer / delete screen
>(global-set-mouse mouse-right mouse-shift-up
>        '(lambda (arg) (interactive)
>             (kill-buffer (current-buffer))
>             (delete-screen)))


                       |=|   \    /   |=| the sky...   Smoke on the water.

                      Deep purple, the best

1. How can I run Rmail in an other screen?

  Hi, I am using Epoch 4.0p2, how can I start rmail in a new screen? I
am a kind of able to do it by setting rmail-mode-hook with
(create-screen "RMAIL"). It works but rmail is also run at the current
screen too. How can I avoid it?

  I'll post summery after I got replies.



                       |=|   \    /   |=| the sky...   Smoke on the water.

                      Deep purple, the best

2. Nominees requested for Provost at Duke University

3. Running full screen program like vi from xemacs shell window

4. DNS Queries and ISDN line

5. Why are my new VM screens screwed up by icons' column?

6. Virtual Firewall / MSN Messenger (resubmit)

7. New screen for find file?

8. HELP!!!!!!!

9. New Screen Fontify

10. New screen not accepting input until clicked in

11. how to make gnuclient use existing screen rather than new one?

12. rmail-output-to-rmail-file appends raw text to .gz Rmail file

13. Loading a file as a new buffer into running xemacs