yatex
annotate yatexhie.el @ 52:5d94deabb9f9
Set YaTeX-indent-line to 'indent-line-function.
Revise fill features.
author | yuuji |
---|---|
date | Sun, 22 Jan 1995 14:20:46 +0000 |
parents | |
children | 5f4b18da14b3 |
rev | line source |
---|---|
yuuji@52 | 1 ;;; -*- Emacs-Lisp -*- |
yuuji@52 | 2 ;;; YaTeX hierarchy browser. |
yuuji@52 | 3 ;;; yatexhie.el |
yuuji@52 | 4 ;;; (c )1995 by HIROSE Yuuji [yuuji@ae.keio.ac.jp] |
yuuji@52 | 5 ;;; Last modified Sun Jan 22 23:15:25 1995 on landcruiser |
yuuji@52 | 6 ;;; $Id$ |
yuuji@52 | 7 |
yuuji@52 | 8 ;; ----- Customizable variables ----- |
yuuji@52 | 9 (defvar YaTeX-hierarchy-inspect-mode t |
yuuji@52 | 10 "*Non-nil inspects the contents of file of cursor position.") |
yuuji@52 | 11 |
yuuji@52 | 12 |
yuuji@52 | 13 ;; ----- General variables ----- |
yuuji@52 | 14 (defvar YaTeX-default-TeX-extensions "\\.\\(tex\\|sty\\)") |
yuuji@52 | 15 (defvar YaTeX-hierarchy-current-main nil) |
yuuji@52 | 16 (defvar YaTeX-hierarchy-buffer-message |
yuuji@52 | 17 (concat |
yuuji@52 | 18 "n)ext p)rev N)extsamelev P)revsamelev u)p K)ill-buffer RET)select" |
yuuji@52 | 19 (if (and YaTeX-emacs-19 window-system) " Mouse2)select" ""))) |
yuuji@52 | 20 (defvar YaTeX-hierarchy-saved-wc nil "Saved window configuration.") |
yuuji@52 | 21 |
yuuji@52 | 22 ;; ----- Functions for parsing hierarchy ----- |
yuuji@52 | 23 |
yuuji@52 | 24 (defun YaTeX-all-included-files (&optional file) |
yuuji@52 | 25 "Return all included files from FILE as a list. |
yuuji@52 | 26 If FILE is nil, use current buffer." |
yuuji@52 | 27 (save-excursion |
yuuji@52 | 28 (let ((include-regex (concat YaTeX-ec-regexp |
yuuji@52 | 29 "\\(\\(input\\)\\|" ;match#2 |
yuuji@52 | 30 "\\(include\\)\\)\\b")) ;match#3 |
yuuji@52 | 31 list file (cb (current-buffer))) |
yuuji@52 | 32 (if file (set-buffer (YaTeX-switch-to-buffer file t))) |
yuuji@52 | 33 (goto-char (point-min)) |
yuuji@52 | 34 (while (YaTeX-re-search-active-forward |
yuuji@52 | 35 include-regex YaTeX-comment-prefix nil t) |
yuuji@52 | 36 (cond |
yuuji@52 | 37 ((match-beginning 2) ;\input, {} is optional, 1 argument |
yuuji@52 | 38 (skip-chars-forward " {") |
yuuji@52 | 39 (setq file (buffer-substring |
yuuji@52 | 40 (point) |
yuuji@52 | 41 (progn |
yuuji@52 | 42 (skip-chars-forward |
yuuji@52 | 43 (concat "^ \t\n\r" YaTeX-ec-regexp "{}")) |
yuuji@52 | 44 (point))))) |
yuuji@52 | 45 ((match-beginning 3) |
yuuji@52 | 46 (skip-chars-forward "{") |
yuuji@52 | 47 (setq file (buffer-substring |
yuuji@52 | 48 (point) |
yuuji@52 | 49 (progn |
yuuji@52 | 50 (forward-char -1) (forward-list 1) (1- (point))))))) |
yuuji@52 | 51 (or (string-match YaTeX-default-TeX-extensions file) |
yuuji@52 | 52 (setq file (concat file ".tex"))) |
yuuji@52 | 53 (setq list (cons file list))) |
yuuji@52 | 54 (set-buffer cb) |
yuuji@52 | 55 (nreverse list)))) |
yuuji@52 | 56 |
yuuji@52 | 57 (defun YaTeX-document-hierarchy (&optional file) |
yuuji@52 | 58 "Return the document hierarchy beginning from FILE as a list. |
yuuji@52 | 59 If FILE is nil, beginning with current buffer's file." |
yuuji@52 | 60 (setq file (or file buffer-file-name)) |
yuuji@52 | 61 (message "Parsing [%s]..." (file-name-nondirectory file)) |
yuuji@52 | 62 (prog1 |
yuuji@52 | 63 (save-excursion |
yuuji@52 | 64 (if (or (file-exists-p file) (null file)) |
yuuji@52 | 65 (progn |
yuuji@52 | 66 (if file |
yuuji@52 | 67 (let ((parent buffer-file-name)) |
yuuji@52 | 68 (YaTeX-switch-to-buffer file t) ;set buffer to file |
yuuji@52 | 69 (or YaTeX-parent-file |
yuuji@52 | 70 (YaTeX-get-builtin "!") |
yuuji@52 | 71 (setq YaTeX-parent-file parent)))) |
yuuji@52 | 72 (cons (buffer-file-name (current-buffer)) |
yuuji@52 | 73 (mapcar 'YaTeX-document-hierarchy ;return value |
yuuji@52 | 74 (YaTeX-all-included-files)))))) |
yuuji@52 | 75 (message "Parsing [%s]...done" (file-name-nondirectory file)))) |
yuuji@52 | 76 |
yuuji@52 | 77 ;; ----- Functions for displaying hierarchy ----- |
yuuji@52 | 78 |
yuuji@52 | 79 (defun YaTeX-hierarchy-get-file-heading (file) |
yuuji@52 | 80 "Get a FILE's heading." |
yuuji@52 | 81 (save-excursion |
yuuji@52 | 82 (set-buffer (find-file-noselect file)) |
yuuji@52 | 83 (save-excursion |
yuuji@52 | 84 (goto-char (point-min)) |
yuuji@52 | 85 (cond |
yuuji@52 | 86 ((and |
yuuji@52 | 87 (YaTeX-re-search-active-forward |
yuuji@52 | 88 (concat YaTeX-ec-regexp YaTeX-sectioning-regexp) |
yuuji@52 | 89 YaTeX-comment-prefix nil t) |
yuuji@52 | 90 (re-search-forward "{\\([^}]+\\)}" nil t)) |
yuuji@52 | 91 (goto-char (match-beginning 1)) |
yuuji@52 | 92 (skip-chars-forward " \t\n") |
yuuji@52 | 93 (buffer-substring (point) |
yuuji@52 | 94 (min (point-end-of-line) |
yuuji@52 | 95 (match-end 1)))) |
yuuji@52 | 96 ((re-search-forward "^ *%\\([^#]\\)" nil t) |
yuuji@52 | 97 (goto-char (match-beginning 1)) |
yuuji@52 | 98 (skip-chars-forward " \t") |
yuuji@52 | 99 (buffer-substring (point) (point-end-of-line))) |
yuuji@52 | 100 (t ""))))) |
yuuji@52 | 101 |
yuuji@52 | 102 (defun YaTeX-display-a-hierachy (hier level) |
yuuji@52 | 103 "Put a HIER of document hierarchy. |
yuuji@52 | 104 LEVEL is including depth." |
yuuji@52 | 105 (message "Formatting hierarchy buffer...") |
yuuji@52 | 106 (let ((lastatomcol 0) list i p) |
yuuji@52 | 107 (cond |
yuuji@52 | 108 ((listp hier) |
yuuji@52 | 109 (setq list hier) |
yuuji@52 | 110 (while list |
yuuji@52 | 111 (YaTeX-display-a-hierachy (car list) (1+ level)) |
yuuji@52 | 112 (setq list (cdr list)))) |
yuuji@52 | 113 ((stringp hier) ;is an atom |
yuuji@52 | 114 (insert " ") |
yuuji@52 | 115 (setq i level) |
yuuji@52 | 116 (while (> i 2) |
yuuji@52 | 117 (insert "| ") |
yuuji@52 | 118 (setq i (1- i))) |
yuuji@52 | 119 (if (> level 1) (insert "+---")) |
yuuji@52 | 120 (setq p (point)) |
yuuji@52 | 121 (insert (or (buffer-name (get-file-buffer hier)) |
yuuji@52 | 122 (file-name-nondirectory hier))) |
yuuji@52 | 123 (if (and window-system YaTeX-emacs-19) |
yuuji@52 | 124 (put-text-property p (point) 'mouse-face 'underline)) |
yuuji@52 | 125 (insert " ") |
yuuji@52 | 126 (indent-to-column (1- (/ (window-width) 2))) |
yuuji@52 | 127 (insert "% " (YaTeX-hierarchy-get-file-heading hier)) |
yuuji@52 | 128 (insert "\n")))) |
yuuji@52 | 129 (message "Formatting hierarchy buffer...")) |
yuuji@52 | 130 |
yuuji@52 | 131 (defun YaTeX-display-hierarchy (file &optional use-default) |
yuuji@52 | 132 "Display document hierarchy that is beginning from FILE." |
yuuji@52 | 133 (interactive "P") |
yuuji@52 | 134 (setq YaTeX-hierarchy-saved-wc |
yuuji@52 | 135 (list (current-window-configuration) |
yuuji@52 | 136 (and (featurep 'windows) |
yuuji@52 | 137 (boundp 'win:current-config) |
yuuji@52 | 138 win:current-config))) |
yuuji@52 | 139 (let*((b-in (YaTeX-get-builtin "!")) |
yuuji@52 | 140 (default (or YaTeX-parent-file |
yuuji@52 | 141 (and b-in (YaTeX-guess-parent b-in)) |
yuuji@52 | 142 buffer-file-name))) |
yuuji@52 | 143 ;;む・踉擦鵙髟阡鮫このへんの仕様どう瘢雹したらいいか良く分からん... |
yuuji@52 | 144 (if default (setq default (expand-file-name default))) |
yuuji@52 | 145 (YaTeX-visit-main t) ;move to parent file |
yuuji@52 | 146 (setq file |
yuuji@52 | 147 (or (if use-default default file) |
yuuji@52 | 148 (read-file-name |
yuuji@52 | 149 (format |
yuuji@52 | 150 "Main .tex file%s: " |
yuuji@52 | 151 (if default |
yuuji@52 | 152 (format "(default %s)"(file-name-nondirectory default)) |
yuuji@52 | 153 "")) |
yuuji@52 | 154 "" default 1)))) |
yuuji@52 | 155 (setq file (expand-file-name file)) |
yuuji@52 | 156 (setq YaTeX-hierarchy-current-main file) |
yuuji@52 | 157 (let ((dbuf "*document hierarchy*")) |
yuuji@52 | 158 (YaTeX-showup-buffer dbuf nil t) |
yuuji@52 | 159 (set-buffer (get-buffer dbuf)) |
yuuji@52 | 160 (setq truncate-lines t) |
yuuji@52 | 161 (let ((buffer-read-only nil)) |
yuuji@52 | 162 (erase-buffer) |
yuuji@52 | 163 (YaTeX-display-a-hierachy (YaTeX-document-hierarchy file) 0)) |
yuuji@52 | 164 (goto-char (point-min)) |
yuuji@52 | 165 (YaTeX-hierarchy-next 0) |
yuuji@52 | 166 (set-buffer-modified-p nil) |
yuuji@52 | 167 (YaTeX-hierarchy-mode) |
yuuji@52 | 168 )) |
yuuji@52 | 169 |
yuuji@52 | 170 (defun YaTeX-display-hierarchy-directly () |
yuuji@52 | 171 "Same as YaTeX-display-hierarchy. Call from mouse." |
yuuji@52 | 172 (interactive) |
yuuji@52 | 173 (YaTeX-display-hierarchy nil t)) |
yuuji@52 | 174 |
yuuji@52 | 175 (defun YaTeX-hierarchy-mode () |
yuuji@52 | 176 "Major mode to browse and select document hierarchy. |
yuuji@52 | 177 |
yuuji@52 | 178 \\[YaTeX-hierarchy-next] next line |
yuuji@52 | 179 \\[YaTeX-hierarchy-prev] previous line |
yuuji@52 | 180 \\[YaTeX-hierarchy-forward] move forward in same level |
yuuji@52 | 181 \\[YaTeX-hierarchy-backward] move backward in same level |
yuuji@52 | 182 \\[YaTeX-hierarchy-up-document] move to parent file |
yuuji@52 | 183 \\[delete-other-windows] delete other windows |
yuuji@52 | 184 \\[other-window] other window |
yuuji@52 | 185 \\[YaTeX-hierarchy-show] show buffer contents in the next window |
yuuji@52 | 186 \\[YaTeX-hierarchy-select] select file |
yuuji@52 | 187 \\[YaTeX-hierarchy-mouse-select] select |
yuuji@52 | 188 " |
yuuji@52 | 189 (setq major-mode 'YaTeX-hierarchy-mode |
yuuji@52 | 190 mode-name "YaTeX hier") |
yuuji@52 | 191 (use-local-map YaTeX-hierarchy-mode-map) |
yuuji@52 | 192 (setq buffer-read-only t) |
yuuji@52 | 193 (message YaTeX-hierarchy-buffer-message)) |
yuuji@52 | 194 |
yuuji@52 | 195 ;; ----- Subfunctions for interactive functions ----- |
yuuji@52 | 196 (defun YaTeX-hierarchy-get-current-file-buffer () |
yuuji@52 | 197 "Return the buffer associated with current line's file." |
yuuji@52 | 198 (let ((file (buffer-substring |
yuuji@52 | 199 (point) |
yuuji@52 | 200 (save-excursion |
yuuji@52 | 201 (skip-chars-forward "^ \t" (point-end-of-line)) (point)))) |
yuuji@52 | 202 (hilit-auto-highlight) buffer) |
yuuji@52 | 203 (set-buffer (find-file-noselect YaTeX-hierarchy-current-main)) |
yuuji@52 | 204 (if (get-buffer file) ;buffer is active |
yuuji@52 | 205 (setq buffer (get-buffer file)) ;may contain `<2>' |
yuuji@52 | 206 (if (string-match "<[2-9]>$" file) |
yuuji@52 | 207 (setq file (substring file 0 -3))) |
yuuji@52 | 208 (save-excursion |
yuuji@52 | 209 (setq buffer (YaTeX-switch-to-buffer file t)))))) ; open it! |
yuuji@52 | 210 |
yuuji@52 | 211 ;; ----- Interactive functions ----- |
yuuji@52 | 212 (defun YaTeX-hierarchy-next (arg &optional quiet) |
yuuji@52 | 213 "Move to next line's file in YaTeX document hierarchy buffer." |
yuuji@52 | 214 (interactive "p") |
yuuji@52 | 215 (forward-line arg) |
yuuji@52 | 216 (skip-chars-forward "- +\\|") |
yuuji@52 | 217 (if (and (/= arg 0) YaTeX-hierarchy-inspect-mode (not quiet)) |
yuuji@52 | 218 (YaTeX-hierarchy-select t)) |
yuuji@52 | 219 (message YaTeX-hierarchy-buffer-message)) |
yuuji@52 | 220 |
yuuji@52 | 221 (defun YaTeX-hierarchy-prev (arg) |
yuuji@52 | 222 "Move to previous line's file in YaTeX document hierarchy buffer." |
yuuji@52 | 223 (interactive "p") |
yuuji@52 | 224 (YaTeX-hierarchy-next (- arg))) |
yuuji@52 | 225 |
yuuji@52 | 226 (defun YaTeX-hierarchy-next-line (arg) |
yuuji@52 | 227 (interactive "p") |
yuuji@52 | 228 (YaTeX-hierarchy-next arg t)) |
yuuji@52 | 229 |
yuuji@52 | 230 (defun YaTeX-hierarchy-prev-line (arg) |
yuuji@52 | 231 (interactive "p") |
yuuji@52 | 232 (YaTeX-hierarchy-next (- arg) t)) |
yuuji@52 | 233 |
yuuji@52 | 234 (defun YaTeX-hierarchy-forward (arg) |
yuuji@52 | 235 "Move to forward file in same hierarchy level." |
yuuji@52 | 236 (interactive "p") |
yuuji@52 | 237 (YaTeX-hierarchy-next 0) |
yuuji@52 | 238 (let ((p (point))(column (current-column)) (i (if (> arg 0) arg (- arg)))) |
yuuji@52 | 239 (if (= column 0) (error "Not on file line.")) |
yuuji@52 | 240 (while (> i 0) |
yuuji@52 | 241 (if (catch 'found |
yuuji@52 | 242 (while (and (not (eobp)) (not (bobp))) |
yuuji@52 | 243 (forward-line (if (> arg 0) 1 -1)) |
yuuji@52 | 244 (move-to-column column) |
yuuji@52 | 245 (if (looking-at "[- +\\|]") nil |
yuuji@52 | 246 (YaTeX-hierarchy-next 0) |
yuuji@52 | 247 (if (= (current-column) column) (throw 'found t))) |
yuuji@52 | 248 (beginning-of-line))) |
yuuji@52 | 249 nil |
yuuji@52 | 250 (goto-char p) |
yuuji@52 | 251 (error "No same level file.")) |
yuuji@52 | 252 (setq i (1- i))))) |
yuuji@52 | 253 |
yuuji@52 | 254 (defun YaTeX-hierarchy-backward (arg) |
yuuji@52 | 255 "Move to backward file in same hierarchy level." |
yuuji@52 | 256 (interactive "p") |
yuuji@52 | 257 (YaTeX-hierarchy-forward (- arg))) |
yuuji@52 | 258 |
yuuji@52 | 259 (defun YaTeX-hierarchy-up-document () |
yuuji@52 | 260 "Up level, that is, move to parent file position." |
yuuji@52 | 261 (interactive) |
yuuji@52 | 262 (YaTeX-hierarchy-next 0) ;adjust column |
yuuji@52 | 263 (let ((p (point)) (line (count-lines (point-min) (point))) column) |
yuuji@52 | 264 (if (or (<= line 1) (< (current-column) 6)) |
yuuji@52 | 265 (message "No more parent") |
yuuji@52 | 266 (backward-char 1) |
yuuji@52 | 267 (or (= (char-after (point)) ?-) (error "Unexpected hierarchy buffer")) |
yuuji@52 | 268 (setq column (current-column)) |
yuuji@52 | 269 (while (and (> line 1) (looking-at "[- +\\|]")) |
yuuji@52 | 270 (forward-line -1) |
yuuji@52 | 271 (move-to-column column)) |
yuuji@52 | 272 (YaTeX-hierarchy-next 0) |
yuuji@52 | 273 (push-mark p t) |
yuuji@52 | 274 (message "Mark set to last position")))) |
yuuji@52 | 275 |
yuuji@52 | 276 (defun YaTeX-hierarchy-kill-buffer (arg) |
yuuji@52 | 277 "Kill buffer associated with current line's file." |
yuuji@52 | 278 (interactive "p") |
yuuji@52 | 279 (YaTeX-hierarchy-next 0) ;move to file name column |
yuuji@52 | 280 (if (bolp) (error "Not on file name line")) |
yuuji@52 | 281 (let ((file (buffer-substring (point) (point-end-of-line)))) |
yuuji@52 | 282 (YaTeX-hierarchy-next arg) |
yuuji@52 | 283 (cond |
yuuji@52 | 284 ((get-buffer file) |
yuuji@52 | 285 (kill-buffer (get-buffer file)) |
yuuji@52 | 286 (message "Buffer [%s] was killed" file)) |
yuuji@52 | 287 (t (message "Buffer [%s] is not active." file))))) |
yuuji@52 | 288 |
yuuji@52 | 289 (defun YaTeX-hierarchy-select (arg) |
yuuji@52 | 290 "Select current line's file in YaTeX document hierarchy buffer. |
yuuji@52 | 291 If ARG is non-nil, show the buffer in the next window." |
yuuji@52 | 292 (interactive "P") |
yuuji@52 | 293 (beginning-of-line) |
yuuji@52 | 294 (skip-chars-forward "- +\\|") |
yuuji@52 | 295 (or (eolp) |
yuuji@52 | 296 (let ((buffer (YaTeX-hierarchy-get-current-file-buffer))) |
yuuji@52 | 297 (if buffer ;if file was found |
yuuji@52 | 298 (if arg |
yuuji@52 | 299 (YaTeX-showup-buffer buffer nil) |
yuuji@52 | 300 (if (and YaTeX-emacs-19 window-system |
yuuji@52 | 301 (get-buffer-window buffer t)) |
yuuji@52 | 302 (goto-buffer-window buffer) ;select currently displaying |
yuuji@52 | 303 (YaTeX-switch-to-buffer-other-window buffer))))))) |
yuuji@52 | 304 |
yuuji@52 | 305 (defun YaTeX-hierarchy-show () |
yuuji@52 | 306 "Show current line's file in the next window." |
yuuji@52 | 307 (interactive) |
yuuji@52 | 308 (YaTeX-hierarchy-select t)) |
yuuji@52 | 309 |
yuuji@52 | 310 (defun YaTeX-hierarchy-mouse-select (event) |
yuuji@52 | 311 (interactive "e") |
yuuji@52 | 312 (mouse-set-point event) |
yuuji@52 | 313 (YaTeX-hierarchy-select nil)) |
yuuji@52 | 314 |
yuuji@52 | 315 (defun YaTeX-hierarchy-quit () |
yuuji@52 | 316 "Quit from YaTeX-hierarchy buffer and restore window configuration." |
yuuji@52 | 317 (interactive) |
yuuji@52 | 318 (if (or (not (featurep 'windows)) |
yuuji@52 | 319 (car YaTeX-hierarchy-saved-wc) |
yuuji@52 | 320 (and (= (car (cdr YaTeX-hierarchy-saved-wc)) win:current-config))) |
yuuji@52 | 321 (set-window-configuration (car YaTeX-hierarchy-saved-wc)) |
yuuji@52 | 322 (bury-buffer nil))) |
yuuji@52 | 323 |
yuuji@52 | 324 (defun YaTeX-hierarchy-toggle-inspection (arg) |
yuuji@52 | 325 "Toggle inspection mode of YaTeX-hierarchy buffer." |
yuuji@52 | 326 (interactive "P") |
yuuji@52 | 327 (setq YaTeX-hierarchy-inspect-mode |
yuuji@52 | 328 (or arg (not YaTeX-hierarchy-inspect-mode))) |
yuuji@52 | 329 (message "YaTeX hierarchy inspection mode %s" |
yuuji@52 | 330 (if YaTeX-hierarchy-inspect-mode "ON" "OFF"))) |
yuuji@52 | 331 |
yuuji@52 | 332 ;; ----- Setting up keymap ----- |
yuuji@52 | 333 (defvar YaTeX-hierarchy-mode-map nil "Keymap used in YaTeX-hierarchy-mode.") |
yuuji@52 | 334 (if YaTeX-hierarchy-mode-map nil |
yuuji@52 | 335 (setq YaTeX-hierarchy-mode-map (make-sparse-keymap)) |
yuuji@52 | 336 (define-key YaTeX-hierarchy-mode-map "n" 'YaTeX-hierarchy-next) |
yuuji@52 | 337 (define-key YaTeX-hierarchy-mode-map "p" 'YaTeX-hierarchy-prev) |
yuuji@52 | 338 (define-key YaTeX-hierarchy-mode-map "j" 'YaTeX-hierarchy-next-line) |
yuuji@52 | 339 (define-key YaTeX-hierarchy-mode-map "k" 'YaTeX-hierarchy-prev-line) |
yuuji@52 | 340 (substitute-all-key-definition |
yuuji@52 | 341 'next-line 'YaTeX-hierarchy-next-line YaTeX-hierarchy-mode-map) |
yuuji@52 | 342 (substitute-all-key-definition |
yuuji@52 | 343 'previous-line 'YaTeX-hierarchy-prev-line YaTeX-hierarchy-mode-map) |
yuuji@52 | 344 (define-key YaTeX-hierarchy-mode-map "N" 'YaTeX-hierarchy-forward) |
yuuji@52 | 345 (define-key YaTeX-hierarchy-mode-map "P" 'YaTeX-hierarchy-backward) |
yuuji@52 | 346 (define-key YaTeX-hierarchy-mode-map "u" 'YaTeX-hierarchy-up-document) |
yuuji@52 | 347 (define-key YaTeX-hierarchy-mode-map "K" 'YaTeX-hierarchy-kill-buffer) |
yuuji@52 | 348 (define-key YaTeX-hierarchy-mode-map "1" 'delete-other-windows) |
yuuji@52 | 349 (define-key YaTeX-hierarchy-mode-map "o" 'other-window) |
yuuji@52 | 350 (define-key YaTeX-hierarchy-mode-map "." 'YaTeX-hierarchy-show) |
yuuji@52 | 351 (define-key YaTeX-hierarchy-mode-map "\C-m" 'YaTeX-hierarchy-select) |
yuuji@52 | 352 (define-key YaTeX-hierarchy-mode-map ";" 'YaTeX-hierarchy-toggle-inspection) |
yuuji@52 | 353 (define-key YaTeX-hierarchy-mode-map "q" 'YaTeX-hierarchy-quit) |
yuuji@52 | 354 (define-key YaTeX-hierarchy-mode-map "?" 'describe-mode) |
yuuji@52 | 355 (if (and YaTeX-emacs-19 window-system) |
yuuji@52 | 356 (define-key YaTeX-hierarchy-mode-map |
yuuji@52 | 357 [mouse-2] 'YaTeX-hierarchy-mouse-select)) |
yuuji@52 | 358 ) |
yuuji@52 | 359 |
yuuji@52 | 360 (provide 'yatexhie) |
yuuji@52 | 361 ;;end of yatexhie.el |