Thread View: gnu.epoch.misc
2 messages
2 total messages
Started by J. Chapman
Wed, 18 Sep 1991 15:30
mailing list .. etc
Author: J. Chapman
Date: Wed, 18 Sep 1991 15:30
Date: Wed, 18 Sep 1991 15:30
70 lines
4100 bytes
4100 bytes
I am using the epoch program on a DECstation 3100 and find it delightful. I'm an Emacs user and have been for several years. I would like to be on the mailing list for information regarding epoch. I have a preference for keyprogramming and have utilized the key associations that are possible with both emacs and epoch. In this regard I have duplicated below a message I sent to some DEC people regarding the use of epoch on the DECstation. As you will see it is the only frustration I have with epoch and it has nothing to do with epoch but with the consequence of DEC mucking around with the X system. If anyone there knows a work around for this problem, I would be delighted to know about it. J. Chapman (for info: "finger chapman@bubba.physics.lsa.umich.edu") Date: Wed, 18 Sep 91 19:17:17 -0400 From: chapman (J. Chapman) This is both an opportunity to vent my frustrations and a plea for anyone who knows a solution to a long standing irritant that has plagued me regarding the use of this otherwise delightful DECstation 3100 that sits on my desk. The frustration derives from my preference to use the Emacs editor and its X-window implementation. I am now using the special implementation for X called "epoch". The program works well and provides essentially "everything anyone could want from an editor" including very flexible key programming. It's this latter facility that has occupied many (~15 or so) hours of my time. It is possible with Emacs or epoch to assign functions to the escape sequences of the keys from the keyboard and I prefer to do so for the heavily used functions. My difficulty is that I cannot get the keys: Prev Screen Next Screen Remove PF1-PF4 to output anything at all to the program. These keys function in a DECterm window so it is clear that DECterm startup initializes the keyboard differently than the standard X startup. I find no means of setting the system wide keyboard defaults at all so I have studied the epoch startup and looked for the standard X initializations without finding anything that looks promissing. It appears that DEC has significantly modified the X initialization proceedure and disabled much of the standard. For example, there is not routine xrdb anywhere I can find to set or examine the defaults. The reason for all this mucking around with the standard is not clear to me and my opinion of it is not important either so I will turn to my question: "How do I get the above keys to send their escape sequences to an X application?" If that can be done easily, I would be delighted if a second keyboard feature could also be enabled for standard x-applications like epoch. This is: "How do I get these standard X applications to start up with the keypad in applicationKeypadMode on." The escape sequences from the keypad are very useful for program association with special editing functions. Extra copies of the numbers are not useful. As with the above keys, I have been unable to find in files or manuals any indication of how to get an application to start with the keypad set for escape sequences. I am very surprised that no one seems to care if all these special keys do anything more useful than duplicate the numbers. I could really love this machine if! J. Chapman
Re: mailing list .. etc
Author: pms
Date: Wed, 18 Sep 1991 17:03
Date: Wed, 18 Sep 1991 17:03
211 lines
7893 bytes
7893 bytes
re:
>
> I am using the epoch program on a DECstation 3100 and find it
...
> facility that has occupied many (~15 or so) hours of my time. It is
> possible with Emacs or epoch to assign functions to the escape
> sequences of the keys from the keyboard and I prefer to do so for the
> heavily used functions. My difficulty is that I cannot get the keys:
>
> Prev Screen
> Next Screen
> Remove
> PF1-PF4
I use most of those keys in epoch on a DECstation 5000 (and occasionally
a 3100). The trick is to turn off escape mapping for the function
keys. Below is what I use to map Prev Screen (called "Prior")
and Next Screen (called "Next"), plus the the keypad function
keys KP_F1 through KP_F4.
Pat Sherry
pms@arbortext.com
-------------------
;; function keymapping based on Alan Carroll's contrib/amc.el
;;
;; Conventions:
;; Rebound keys start with control-\. (was control-^ in amc version)
;; Keypad keys are "k" followed by the keypad symbol.
;; kp_f1 is "kA", kp_f2 is "kB", kp_f3 is "kC", kp_f4 is "kD".
;; Functions keys are the function letter ("r","l", or "f") followed by the
;; number mod 10. The letter is uppercase if the function number is >9.
;;
;; Modifiers are "S" for shift, "C" for control, "M" for meta, and "A" for alt.
;; special keys
(setq epoch::function-key-mapping nil) ;turn off ESC mapping for function keys
;;; Sun keyboard specials
(rebind-key "Help" 0 "\C-h")
(rebind-key "R6" 0 "\C-\\r6")
;;; keypad bindings
(rebind-key "KP_Multiply" 0 "\C-\\k*")
(rebind-key "KP_Subtract" 0 "\C-\\k-")
(rebind-key "KP_Subtract" 0 "\C-\\k.")
(rebind-key "KP_Add" 0 "\C-\\k+")
(rebind-key "KP_F1" 0 "\C-\\kA")
(rebind-key "KP_F1" 'meta "\C-\\MkA")
(rebind-key "KP_F2" 0 "\C-\\kB")
(rebind-key "KP_F2" 'meta "\C-\\MkB")
(rebind-key "KP_F3" 0 "\C-\\kC")
(rebind-key "KP_F3" 'meta "\C-\\MkC")
(rebind-key "KP_F4" 0 "\C-\\kD")
(rebind-key "KP_F4" 'meta "\C-\\MkD")
;;; General bindings
;;; Insert
(rebind-key "Insert" 0 "\C-\\k0")
(rebind-key "Insert" 'meta "\C-\\Mk0")
;;; Find
(rebind-key "Find" 0 "\C-\\kf")
(rebind-key "Find" 'shift "\C-\\Skf")
(rebind-key "Find" 'meta "\C-\\Mkf")
;;; Home
(rebind-key "Home" 0 "\C-\\k7")
(rebind-key "R7" 0 "\C-\\k7")
(rebind-key "Home" 'shift "\C-\\Sk7")
(rebind-key "R7" 'shift "\C-\\Sk7")
(rebind-key "KP_7" 'shift "\C-\\Sk7")
(rebind-key "Home" 'control "\C-\\Ck7")
(rebind-key "R7" 'control "\C-\\Ck7")
;;; Up arrow
(rebind-key "Up" 0 "\C-\\k8")
(rebind-key "R8" 'shift "\C-\\Sk8")
(rebind-key "Up" 'shift "\C-\\Sk8")
(rebind-key "KP_8" 'shift "\C-\\Sk8")
(rebind-key "Up" 'control "\C-\\Ck8")
(rebind-key "Up" 'meta "\C-\\Mk8")
;;; Page Up
(rebind-key "Prior" 0 "\C-\\k9")
(rebind-key "R9" 0 "\C-\\k9")
(rebind-key "Prior" 'shift "\C-\\Sk9")
(rebind-key "R9" 'shift "\C-\\Sk9")
(rebind-key "KP_9" 'shift "\C-\\Sk9")
(rebind-key "Prior" 'control "\C-\\Ck9")
(rebind-key "R9" 'control "\C-\\Ck9")
(rebind-key "Prior" 'meta "\C-\\Mk9")
(rebind-key "R9" 'meta "\C-\\Mk9")
;;; Left arrow
(rebind-key "Left" 0 "\C-\\k4")
(rebind-key "R10" 'shift "\C-\\Sk4")
(rebind-key "Left" 'shift "\C-\\Sk4")
(rebind-key "KP_4" 'shift "\C-\\Sk4")
(rebind-key "Left" 'meta "\C-\\Mk4")
(rebind-key "Left" 'control "\C-\\Ck4")
;;; keypad center
(rebind-key "R11" 0 "\C-\\k5")
(rebind-key "KP_5" 0 "\C-\\k5")
(rebind-key "R11" 'control "\C-\\Ck5")
(rebind-key "KP_5" 'control "\C-\\Ck5")
;;; right arrow
(rebind-key "Right" 0 "\C-\\k6")
(rebind-key "R12" 'shift "\C-\\Sk6")
(rebind-key "Right" 'shift "\C-\\Sk6")
(rebind-key "KP_6" 'shift "\C-\\Sk6")
(rebind-key "Right" 'control "\C-\\Ck6")
(rebind-key "Right" 'meta "\C-\\Mk6")
;;; end
(rebind-key "End" 0 "\C-\\k1")
(rebind-key "R13" 0 "\C-\\k1")
(rebind-key "R13" 'shift "\C-\\Sk1")
(rebind-key "KP_1" 'shift "\C-\\Sk1")
(rebind-key "End" 'control "\C-\\Ck1")
(rebind-key "R13" 'control "\C-\\Ck1")
;;; Down arrow
(rebind-key "Down" 0 "\C-\\k2")
(rebind-key "R14" 'shift "\C-\\Sk2")
(rebind-key "Down" 'shift "\C-\\Sk2")
(rebind-key "KP_2" 'shift "\C-\\Sk2")
(rebind-key "Down" 'control "\C-\\Ck2")
(rebind-key "Down" 'meta "\C-\\Mk2")
;;; Page Down
(rebind-key "R15" 0 "\C-\\k3")
(rebind-key "Next" 0 "\C-\\k3")
(rebind-key "R15" 'shift "\C-\\Sk3")
(rebind-key "Next" 'shift "\C-\\Sk3")
(rebind-key "KP_3" 'shift "\C-\\Sk3")
(rebind-key "Next" 'control "\C-\\Ck3")
(rebind-key "R15" 'control "\C-\\Ck3")
(rebind-key "Next" 'meta "\C-\\Mk3")
(rebind-key "R15" 'meta "\C-\\Mk3")
;;; -------------------------------------------------------------------------
;;; Now, the bindings to function
;;;
(global-set-key "\C-\\r6" 'undo) ; keypad * on new suns
(global-set-key "\C-\\k*" 'undo) ; keypad * on '386
(global-set-key "\C-\\k0" 'yank) ; insert
(global-set-key "\C-\\Mk0" 'yank-pop) ; Meta-insert
;; Normal cursor keys move characters and lines
(global-set-key "\C-\\k8" 'previous-line) ; up arrow
(global-set-key "\C-\\k2" 'next-line) ; down arrow
(global-set-key "\C-\\k4" 'backward-char) ; left arrow
(global-set-key "\C-\\k6" 'forward-char) ; right arrow
;; Shifted horizontal goes words
(global-set-key "\C-\\Sk6" 'forward-word) ; shift right arrow
(global-set-key "\C-\\Sk4" 'backward-word) ; shift left arrow
(global-set-key "\C-\\Sk8" (definteractive (scroll-down 1))) ; shift up arrow
(global-set-key "\C-\\Sk2" (definteractive (scroll-up 1))) ; shift down arrow
;; control page switches screens
(global-set-key "\C-\\Ck9"
(definteractive (select-screen (raise-screen (next-screen))))
)
;control page-up
(global-set-key "\C-\\Ck3"
(definteractive (select-screen (raise-screen (prev-screen))))
)
;control page-down
(global-set-key "\C-\\Ck8" (definteractive (select-window (next-window))))
;control up arrow
(global-set-key "\C-\\Ck2" (definteractive (select-window (previous-window))))
;control down arrow
(global-set-key "\C-\\Sk9" (definteractive (raise-screen))) ;shift page-up
(global-set-key "\C-\\Sk3" (definteractive (lower-screen))) ;shift page-down
;;;
(global-set-key "\C-\\k7" 'beginning-of-line) ; Home
(global-set-key "\C-\\k5" 'recenter) ; Center
(global-set-key "\C-\\k1" 'end-of-line) ; End
(global-set-key "\C-\\Ck7" 'beginning-of-buffer) ; control Home
(global-set-key "\C-\\Ck1" 'end-of-buffer) ; control End
(global-set-key "\C-\\Ck5" 'exchange-point-and-mark) ; control center
(global-set-key "\C-\\C=" 'split-window-vertically) ;control =
(global-set-key "\C-\\C-" 'delete-other-windows) ;control -
(global-set-key "\C-\\k9" 'scroll-down) ; Page Up
(global-set-key "\C-\\k3" 'scroll-up) ; Page Down
;; Find key
(global-set-key "\C-\\kf" 'search-forward)
(global-set-key "\C-\\Skf" 'search-backward)
(global-set-key "\C-\\Mkf" 're-search-forward)
;; Keypad function keys
(global-set-key "\C-\\kA" 'replace-string) ; KP_F1
(global-set-key "\C-\\MkA" 'replace-regexp) ; Meta-KP_F1
(global-set-key "\C-\\kB" 'revert-buffer) ; KP_F2
(global-set-key "\C-\\kC" 'print-buffer) ; KP_F3
(global-set-key "\C-\\MkC" 'print-region) ; Meta-KP_F3
(global-set-key "\C-\\kD" 'insert-file) ; KP_F4
(global-set-key "\C-\\MkD" 'write-file) ; Meta-KP_F4
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