Mercurial > emacs
comparison lisp/hexl.el @ 91073:4bc33ffdda1a
Merge from emacs--devo--0
Patches applied:
* emacs--devo--0 (patch 902-908)
- Update from CVS
- Merge from emacs--rel--22
* emacs--rel--22 (patch 131-137)
- Update from CVS
- Merge from gnus--rel--5.10
* gnus--rel--5.10 (patch 261-262)
- Update from CVS
Revision: emacs@sv.gnu.org/emacs--unicode--0--patch-278
author | Miles Bader <miles@gnu.org> |
---|---|
date | Sat, 27 Oct 2007 09:12:07 +0000 |
parents | f55f9811f5d7 4e282ea90733 |
children | 606f2d163a64 |
comparison
equal
deleted
inserted
replaced
91072:74ab3ea909f9 | 91073:4bc33ffdda1a |
---|---|
455 "Return buffer position for ADDRESS." | 455 "Return buffer position for ADDRESS." |
456 (interactive "nAddress: ") | 456 (interactive "nAddress: ") |
457 (+ (* (/ address 16) 68) 10 (point-min) (/ (* (% address 16) 5) 2))) | 457 (+ (* (/ address 16) 68) 10 (point-min) (/ (* (% address 16) 5) 2))) |
458 | 458 |
459 (defun hexl-goto-address (address) | 459 (defun hexl-goto-address (address) |
460 "Goto hexl-mode (decimal) address ADDRESS. | 460 "Go to hexl-mode (decimal) address ADDRESS. |
461 Signal error if ADDRESS is out of range." | 461 Signal error if ADDRESS is out of range." |
462 (interactive "nAddress: ") | 462 (interactive "nAddress: ") |
463 (if (or (< address 0) (> address hexl-max-address)) | 463 (if (or (< address 0) (> address hexl-max-address)) |
464 (error "Out of hexl region")) | 464 (error "Out of hexl region")) |
465 (goto-char (hexl-address-to-marker address))) | 465 (goto-char (hexl-address-to-marker address))) |
1102 (define-key hexl-mode-map "\C-x]" 'hexl-end-of-1k-page) | 1102 (define-key hexl-mode-map "\C-x]" 'hexl-end-of-1k-page) |
1103 (define-key hexl-mode-map "\C-x\C-p" 'undefined) | 1103 (define-key hexl-mode-map "\C-x\C-p" 'undefined) |
1104 (define-key hexl-mode-map "\C-x\C-s" 'hexl-save-buffer) | 1104 (define-key hexl-mode-map "\C-x\C-s" 'hexl-save-buffer) |
1105 (define-key hexl-mode-map "\C-x\C-t" 'undefined)) | 1105 (define-key hexl-mode-map "\C-x\C-t" 'undefined)) |
1106 | 1106 |
1107 (easy-menu-define hexl-menu hexl-mode-map "Hexl Mode menu" | |
1108 `("Hexl" | |
1109 :help "Hexl-specific Features" | |
1110 | |
1111 ["Backward short" hexl-backward-short | |
1112 :help "Move to left a short"] | |
1113 ["Forward short" hexl-forward-short | |
1114 :help "Move to right a short"] | |
1115 ["Backward word" hexl-backward-short | |
1116 :help "Move to left a word"] | |
1117 ["Forward word" hexl-forward-short | |
1118 :help "Move to right a word"] | |
1119 "-" | |
1120 ["Beginning of 512b page" hexl-beginning-of-512b-page | |
1121 :help "Go to beginning of 512 byte boundary"] | |
1122 ["End of 512b page" hexl-end-of-512b-page | |
1123 :help "Go to end of 512 byte boundary"] | |
1124 ["Beginning of 1K page" hexl-beginning-of-1k-page | |
1125 :help "Go to beginning of 1KB boundary"] | |
1126 ["End of 1K page" hexl-end-of-1k-page | |
1127 :help "Go to end of 1KB boundary"] | |
1128 "-" | |
1129 ["Go to address" hexl-goto-address | |
1130 :help "Go to hexl-mode (decimal) address"] | |
1131 ["Go to address" hexl-goto-hex-address | |
1132 :help "Go to hexl-mode (hex string) address"] | |
1133 "-" | |
1134 ["Insert decimal char" hexl-insert-decimal-char | |
1135 :help "Insert a character given by its decimal code"] | |
1136 ["Insert hex char" hexl-insert-hex-char | |
1137 :help "Insert a character given by its hexadecimal code"] | |
1138 ["Insert octal char" hexl-insert-octal-char | |
1139 :help "Insert a character given by its octal code"] | |
1140 "-" | |
1141 ["Exit hexl mode" hexl-mode-exit | |
1142 :help "Exit hexl mode returning to previous mode"])) | |
1143 | |
1107 (provide 'hexl) | 1144 (provide 'hexl) |
1108 | 1145 |
1109 ;; arch-tag: d5a7aa8a-9bce-480b-bcff-6c4c7ca5ea4a | 1146 ;; arch-tag: d5a7aa8a-9bce-480b-bcff-6c4c7ca5ea4a |
1110 ;;; hexl.el ends here | 1147 ;;; hexl.el ends here |