Mercurial > hg > xemacs-beta
comparison lisp/psgml/psgml.el @ 203:850242ba4a81 r20-3b28
Import from CVS: tag r20-3b28
author | cvs |
---|---|
date | Mon, 13 Aug 2007 10:02:21 +0200 |
parents | eb5470882647 |
children |
comparison
equal
deleted
inserted
replaced
202:61eefc8fc970 | 203:850242ba4a81 |
---|---|
1 ;;; psgml.el --- SGML-editing mode with parsing support | 1 ;;; psgml.el --- SGML-editing mode with parsing support |
2 ;; $Id: psgml.el,v 1.9 1997/10/05 01:15:30 steve Exp $ | 2 ;; $Id: psgml.el,v 1.10 1997/10/12 01:39:52 steve Exp $ |
3 | 3 |
4 ;; Copyright (C) 1993, 1994, 1995, 1996 Lennart Staflin | 4 ;; Copyright (C) 1993, 1994, 1995, 1996 Lennart Staflin |
5 ;; Copyright (C) 1992 Free Software Foundation, Inc. | 5 ;; Copyright (C) 1992 Free Software Foundation, Inc. |
6 | 6 |
7 ;; Author: Lennart Staflin <lenst@lysator.liu.se> | 7 ;; Author: Lennart Staflin <lenst@lysator.liu.se> |
840 () | 840 () |
841 (setq sgml-mode-map (make-sparse-keymap))) | 841 (setq sgml-mode-map (make-sparse-keymap))) |
842 | 842 |
843 ;;; Key commands | 843 ;;; Key commands |
844 | 844 |
845 (define-key sgml-mode-map "\t" 'sgml-indent-or-tab) | 845 (define-key sgml-mode-map [(tab)] 'sgml-indent-or-tab) |
846 ;(define-key sgml-mode-map "<" 'sgml-insert-tag) | 846 ;;;(define-key sgml-mode-map [(?<)] 'sgml-insert-tag) |
847 (define-key sgml-mode-map ">" 'sgml-close-angle) | 847 (define-key sgml-mode-map [(?>)] 'sgml-close-angle) |
848 (define-key sgml-mode-map "/" 'sgml-slash) | 848 (define-key sgml-mode-map [(?/)] 'sgml-slash) |
849 (define-key sgml-mode-map "\C-c#" 'sgml-make-character-reference) | 849 (define-key sgml-mode-map [(control ?c) (?#)] 'sgml-make-character-reference) |
850 (define-key sgml-mode-map "\C-c-" 'sgml-untag-element) | 850 (define-key sgml-mode-map [(control ?c) (?-)] 'sgml-untag-element) |
851 (define-key sgml-mode-map "\C-c+" 'sgml-insert-attribute) | 851 (define-key sgml-mode-map [(control ?c) (?+)] 'sgml-insert-attribute) |
852 (define-key sgml-mode-map "\C-c/" 'sgml-insert-end-tag) | 852 (define-key sgml-mode-map [(control ?c) (?/)] 'sgml-insert-end-tag) |
853 (define-key sgml-mode-map "\C-c<" 'sgml-insert-tag) | 853 (define-key sgml-mode-map [(control ?c) (?<)] 'sgml-insert-tag) |
854 (define-key sgml-mode-map "\C-c=" 'sgml-change-element-name) | 854 (define-key sgml-mode-map [(control ?c) (?=)] 'sgml-change-element-name) |
855 (define-key sgml-mode-map "\C-c\C-a" 'sgml-edit-attributes) | 855 (define-key sgml-mode-map [(control ?c) (control ?a)] 'sgml-edit-attributes) |
856 (define-key sgml-mode-map "\C-c\C-c" 'sgml-show-context) | 856 (define-key sgml-mode-map [(control ?c) (control ?c)] 'sgml-show-context) |
857 (define-key sgml-mode-map "\C-c\C-d" 'sgml-next-data-field) | 857 (define-key sgml-mode-map [(control ?c) (control ?d)] 'sgml-next-data-field) |
858 (define-key sgml-mode-map "\C-c\C-e" 'sgml-insert-element) | 858 (define-key sgml-mode-map [(control ?c) (control ?e)] 'sgml-insert-element) |
859 (define-key sgml-mode-map "\C-c\C-k" 'sgml-kill-markup) | 859 (define-key sgml-mode-map [(control ?c) (control ?k)] 'sgml-kill-markup) |
860 (define-key sgml-mode-map "\C-c\C-l" 'sgml-show-or-clear-log) | 860 (define-key sgml-mode-map [(control ?c) (control ?l)] 'sgml-show-or-clear-log) |
861 (define-key sgml-mode-map "\C-c\C-n" 'sgml-up-element) | 861 (define-key sgml-mode-map [(control ?c) (control ?n)] 'sgml-up-element) |
862 (define-key sgml-mode-map "\C-c\C-o" 'sgml-next-trouble-spot) | 862 (define-key sgml-mode-map [(control ?c) (control ?o)] 'sgml-next-trouble-spot) |
863 (define-key sgml-mode-map "\C-c\C-p" 'sgml-parse-prolog) | 863 (define-key sgml-mode-map [(control ?c) (control ?p)] 'sgml-parse-prolog) |
864 (define-key sgml-mode-map "\C-c\C-q" 'sgml-fill-element) | 864 (define-key sgml-mode-map [(control ?c) (control ?q)] 'sgml-fill-element) |
865 (define-key sgml-mode-map "\C-c\C-r" 'sgml-tag-region) | 865 (define-key sgml-mode-map [(control ?c) (control ?r)] 'sgml-tag-region) |
866 (define-key sgml-mode-map "\C-c\C-s" 'sgml-unfold-line) | 866 (define-key sgml-mode-map [(control ?c) (control ?s)] 'sgml-unfold-line) |
867 (define-key sgml-mode-map "\C-c\C-t" 'sgml-list-valid-tags) | 867 (define-key sgml-mode-map [(control ?c) (control ?t)] 'sgml-list-valid-tags) |
868 (define-key sgml-mode-map "\C-c\C-v" 'sgml-validate) | 868 (define-key sgml-mode-map [(control ?c) (control ?v)] 'sgml-validate) |
869 (define-key sgml-mode-map "\C-c\C-w" 'sgml-what-element) | 869 (define-key sgml-mode-map [(control ?c) (control ?w)] 'sgml-what-element) |
870 (define-key sgml-mode-map "\C-c\C-z" 'sgml-trim-and-leave-element) | 870 (define-key sgml-mode-map [(control ?c) (control ?z)] 'sgml-trim-and-leave-element) |
871 (define-key sgml-mode-map "\C-c\C-f\C-e" 'sgml-fold-element) | 871 (define-key sgml-mode-map [(control ?c) (control ?f) (control ?e)] 'sgml-fold-element) |
872 (define-key sgml-mode-map "\C-c\C-f\C-r" 'sgml-fold-region) | 872 (define-key sgml-mode-map [(control ?c) (control ?f) (control ?r)] 'sgml-fold-region) |
873 (define-key sgml-mode-map "\C-c\C-f\C-s" 'sgml-fold-subelement) | 873 (define-key sgml-mode-map [(control ?c) (control ?f) (control ?s)] 'sgml-fold-subelement) |
874 (define-key sgml-mode-map "\C-c\C-f\C-x" 'sgml-expand-element) | 874 (define-key sgml-mode-map [(control ?c) (control ?f) (control ?x)] 'sgml-expand-element) |
875 (define-key sgml-mode-map "\C-c\r" 'sgml-split-element) | 875 (define-key sgml-mode-map [(meta control ?O)] 'sgml-split-element) |
876 (define-key sgml-mode-map "\C-c\C-u\C-e" 'sgml-unfold-element) | 876 (define-key sgml-mode-map [(control ?c) (control ?u) (control ?e)] 'sgml-unfold-element) |
877 (define-key sgml-mode-map "\C-c\C-u\C-a" 'sgml-unfold-all) | 877 (define-key sgml-mode-map [(control ?c) (control ?u) (control ?a)] 'sgml-unfold-all) |
878 (define-key sgml-mode-map "\C-c\C-u\C-l" 'sgml-unfold-line) | 878 (define-key sgml-mode-map [(control ?c) (control ?u) (control ?l)] 'sgml-unfold-line) |
879 (define-key sgml-mode-map "\C-c\C-u\C-d" 'sgml-custom-dtd) | 879 (define-key sgml-mode-map [(control ?c) (control ?u) (control ?d)] 'sgml-custom-dtd) |
880 (define-key sgml-mode-map "\C-c\C-u\C-m" 'sgml-custom-markup) | 880 (define-key sgml-mode-map [(control ?c) (control ?u) (control ?m)] 'sgml-custom-markup) |
881 | 881 |
882 (define-key sgml-mode-map "\e\C-a" 'sgml-beginning-of-element) | 882 (define-key sgml-mode-map [(meta control ?a)] 'sgml-beginning-of-element) |
883 (define-key sgml-mode-map "\e\C-e" 'sgml-end-of-element) | 883 (define-key sgml-mode-map [(meta control ?e)] 'sgml-end-of-element) |
884 (define-key sgml-mode-map "\e\C-f" 'sgml-forward-element) | 884 (define-key sgml-mode-map [(meta control ?f)] 'sgml-forward-element) |
885 (define-key sgml-mode-map "\e\C-b" 'sgml-backward-element) | 885 (define-key sgml-mode-map [(meta control ?b)] 'sgml-backward-element) |
886 (define-key sgml-mode-map "\e\C-d" 'sgml-down-element) | 886 (define-key sgml-mode-map [(meta control ?d)] 'sgml-down-element) |
887 (define-key sgml-mode-map "\e\C-u" 'sgml-backward-up-element) | 887 (define-key sgml-mode-map [(meta control ?u)] 'sgml-backward-up-element) |
888 (define-key sgml-mode-map "\e\C-k" 'sgml-kill-element) | 888 (define-key sgml-mode-map [(meta control ?k)] 'sgml-kill-element) |
889 (define-key sgml-mode-map "\e\C-@" 'sgml-mark-element) | 889 (define-key sgml-mode-map [(meta control ?@)] 'sgml-mark-element) |
890 ;;(define-key sgml-mode-map [?\M-\C-\ ] 'sgml-mark-element) | 890 (define-key sgml-mode-map [(meta control ?h)] 'sgml-mark-current-element) |
891 (define-key sgml-mode-map "\e\C-h" 'sgml-mark-current-element) | 891 (define-key sgml-mode-map [(meta control ?t)] 'sgml-transpose-element) |
892 (define-key sgml-mode-map [(meta backspace)] (lookup-key (current-global-map) [(meta backspace)])) | 892 (define-key sgml-mode-map [(meta tab)] 'sgml-complete) |
893 (define-key sgml-mode-map "\e\C-t" 'sgml-transpose-element) | |
894 (define-key sgml-mode-map "\M-\t" 'sgml-complete) | |
895 | 893 |
896 ;;;; Menu bar | 894 ;;;; Menu bar |
897 | 895 |
898 (easy-menu-define | 896 (easy-menu-define |
899 sgml-dtd-menu sgml-mode-map "DTD menu" | 897 sgml-dtd-menu sgml-mode-map "DTD menu" |