diff options
| author | Kenichi Handa | 2012-09-30 23:39:46 +0900 |
|---|---|---|
| committer | Kenichi Handa | 2012-09-30 23:39:46 +0900 |
| commit | c194970e15b6d6efa07697679a25dfab3aa76442 (patch) | |
| tree | 49aec8be9d2dcc74ad3c81f562e48308d8e27b75 /lisp/textmodes | |
| parent | 95402d5faa114a311cabfb8c64cf22a93787a066 (diff) | |
| parent | dd946752ab8810149a66a3eff469eb128709972d (diff) | |
| download | emacs-c194970e15b6d6efa07697679a25dfab3aa76442.tar.gz emacs-c194970e15b6d6efa07697679a25dfab3aa76442.zip | |
merge trunk
Diffstat (limited to 'lisp/textmodes')
| -rw-r--r-- | lisp/textmodes/bibtex.el | 32 | ||||
| -rw-r--r-- | lisp/textmodes/reftex-cite.el | 5 | ||||
| -rw-r--r-- | lisp/textmodes/reftex-index.el | 4 | ||||
| -rw-r--r-- | lisp/textmodes/reftex-sel.el | 8 | ||||
| -rw-r--r-- | lisp/textmodes/reftex.el | 4 | ||||
| -rw-r--r-- | lisp/textmodes/rst.el | 7 | ||||
| -rw-r--r-- | lisp/textmodes/sgml-mode.el | 5 | ||||
| -rw-r--r-- | lisp/textmodes/tex-mode.el | 4 | ||||
| -rw-r--r-- | lisp/textmodes/text-mode.el | 23 |
9 files changed, 47 insertions, 45 deletions
diff --git a/lisp/textmodes/bibtex.el b/lisp/textmodes/bibtex.el index 31656918fad..e0d93b68056 100644 --- a/lisp/textmodes/bibtex.el +++ b/lisp/textmodes/bibtex.el | |||
| @@ -1002,6 +1002,7 @@ See `bibtex-generate-autokey' for details." | |||
| 1002 | ("\\\\`\\|\\\\'\\|\\\\\\^\\|\\\\~\\|\\\\=\\|\\\\\\.\\|\\\\u\\|\\\\v\\|\\\\H\\|\\\\t\\|\\\\c\\|\\\\d\\|\\\\b" . "") | 1002 | ("\\\\`\\|\\\\'\\|\\\\\\^\\|\\\\~\\|\\\\=\\|\\\\\\.\\|\\\\u\\|\\\\v\\|\\\\H\\|\\\\t\\|\\\\c\\|\\\\d\\|\\\\b" . "") |
| 1003 | ;; braces, quotes, concatenation. | 1003 | ;; braces, quotes, concatenation. |
| 1004 | ("[`'\"{}#]" . "") | 1004 | ("[`'\"{}#]" . "") |
| 1005 | ("\\\\-" . "") ; \- -> | ||
| 1005 | ;; spaces | 1006 | ;; spaces |
| 1006 | ("\\\\?[ \t\n]+\\|~" . " ")) | 1007 | ("\\\\?[ \t\n]+\\|~" . " ")) |
| 1007 | "Alist of (OLD-REGEXP . NEW-STRING) pairs. | 1008 | "Alist of (OLD-REGEXP . NEW-STRING) pairs. |
| @@ -4893,21 +4894,22 @@ If mark is active reformat entries in region, if not in whole buffer." | |||
| 4893 | (if use-previous-options | 4894 | (if use-previous-options |
| 4894 | bibtex-reformat-previous-options | 4895 | bibtex-reformat-previous-options |
| 4895 | (setq bibtex-reformat-previous-options | 4896 | (setq bibtex-reformat-previous-options |
| 4896 | (mapcar (lambda (option) | 4897 | (delq nil |
| 4897 | (if (y-or-n-p (car option)) (cdr option))) | 4898 | (mapcar (lambda (option) |
| 4898 | `(("Realign entries (recommended)? " . 'realign) | 4899 | (if (y-or-n-p (car option)) (cdr option))) |
| 4899 | ("Remove empty optional and alternative fields? " . 'opts-or-alts) | 4900 | `(("Realign entries (recommended)? " . realign) |
| 4900 | ("Remove delimiters around pure numerical fields? " . 'numerical-fields) | 4901 | ("Remove empty optional and alternative fields? " . opts-or-alts) |
| 4901 | (,(concat (if bibtex-comma-after-last-field "Insert" "Remove") | 4902 | ("Remove delimiters around pure numerical fields? " . numerical-fields) |
| 4902 | " comma at end of entry? ") . 'last-comma) | 4903 | (,(concat (if bibtex-comma-after-last-field "Insert" "Remove") |
| 4903 | ("Replace double page dashes by single ones? " . 'page-dashes) | 4904 | " comma at end of entry? ") . last-comma) |
| 4904 | ("Delete whitespace at the beginning and end of fields? " . 'whitespace) | 4905 | ("Replace double page dashes by single ones? " . page-dashes) |
| 4905 | ("Inherit booktitle? " . 'inherit-booktitle) | 4906 | ("Delete whitespace at the beginning and end of fields? " . whitespace) |
| 4906 | ("Force delimiters? " . 'delimiters) | 4907 | ("Inherit booktitle? " . inherit-booktitle) |
| 4907 | ("Unify case of entry types and field names? " . 'unify-case) | 4908 | ("Force delimiters? " . delimiters) |
| 4908 | ("Enclose parts of field entries by braces? " . 'braces) | 4909 | ("Unify case of entry types and field names? " . unify-case) |
| 4909 | ("Replace parts of field entries by string constants? " . 'strings) | 4910 | ("Enclose parts of field entries by braces? " . braces) |
| 4910 | ("Sort fields? " . 'sort-fields)))))) | 4911 | ("Replace parts of field entries by string constants? " . strings) |
| 4912 | ("Sort fields? " . sort-fields))))))) | ||
| 4911 | ;; Do not include required-fields because `bibtex-reformat' | 4913 | ;; Do not include required-fields because `bibtex-reformat' |
| 4912 | ;; cannot handle the error messages of `bibtex-format-entry'. | 4914 | ;; cannot handle the error messages of `bibtex-format-entry'. |
| 4913 | ;; Use `bibtex-validate' to check for required fields. | 4915 | ;; Use `bibtex-validate' to check for required fields. |
diff --git a/lisp/textmodes/reftex-cite.el b/lisp/textmodes/reftex-cite.el index 31001c78e54..229d12b2906 100644 --- a/lisp/textmodes/reftex-cite.el +++ b/lisp/textmodes/reftex-cite.el | |||
| @@ -542,10 +542,7 @@ | |||
| 542 | (t "")))) | 542 | (t "")))) |
| 543 | (setq authors (reftex-truncate authors 30 t t)) | 543 | (setq authors (reftex-truncate authors 30 t t)) |
| 544 | (when (reftex-use-fonts) | 544 | (when (reftex-use-fonts) |
| 545 | (put-text-property 0 (length key) 'face | 545 | (put-text-property 0 (length key) 'face reftex-label-face |
| 546 | (reftex-verified-face reftex-label-face | ||
| 547 | 'font-lock-constant-face | ||
| 548 | 'font-lock-reference-face) | ||
| 549 | key) | 546 | key) |
| 550 | (put-text-property 0 (length authors) 'face reftex-bib-author-face | 547 | (put-text-property 0 (length authors) 'face reftex-bib-author-face |
| 551 | authors) | 548 | authors) |
diff --git a/lisp/textmodes/reftex-index.el b/lisp/textmodes/reftex-index.el index 2d395fe3df2..1d15dfbed7e 100644 --- a/lisp/textmodes/reftex-index.el +++ b/lisp/textmodes/reftex-index.el | |||
| @@ -585,9 +585,7 @@ SPC=view TAB=goto RET=goto+hide [e]dit [q]uit [r]escan [f]ollow [?]Help | |||
| 585 | (if (memq reftex-highlight-selection '(mouse both)) | 585 | (if (memq reftex-highlight-selection '(mouse both)) |
| 586 | reftex-mouse-selected-face | 586 | reftex-mouse-selected-face |
| 587 | nil)) | 587 | nil)) |
| 588 | (index-face (reftex-verified-face reftex-label-face | 588 | (index-face reftex-label-face) |
| 589 | 'font-lock-constant-face | ||
| 590 | 'font-lock-reference-face)) | ||
| 591 | sublist cell from to first-char) | 589 | sublist cell from to first-char) |
| 592 | 590 | ||
| 593 | ;; Make the sublist and sort it | 591 | ;; Make the sublist and sort it |
diff --git a/lisp/textmodes/reftex-sel.el b/lisp/textmodes/reftex-sel.el index 627dfba0071..1a400436311 100644 --- a/lisp/textmodes/reftex-sel.el +++ b/lisp/textmodes/reftex-sel.el | |||
| @@ -245,12 +245,8 @@ During a selection process, these are the local bindings. | |||
| 245 | (if (memq reftex-highlight-selection '(mouse both)) | 245 | (if (memq reftex-highlight-selection '(mouse both)) |
| 246 | reftex-mouse-selected-face | 246 | reftex-mouse-selected-face |
| 247 | nil)) | 247 | nil)) |
| 248 | (label-face (reftex-verified-face reftex-label-face | 248 | (label-face reftex-label-face) |
| 249 | 'font-lock-constant-face | 249 | (index-face reftex-index-face) |
| 250 | 'font-lock-reference-face)) | ||
| 251 | (index-face (reftex-verified-face reftex-index-face | ||
| 252 | 'font-lock-constant-face | ||
| 253 | 'font-lock-reference-face)) | ||
| 254 | all cell text label typekey note comment master-dir-re | 250 | all cell text label typekey note comment master-dir-re |
| 255 | prev-inserted offset from to index-tag docstruct-symbol) | 251 | prev-inserted offset from to index-tag docstruct-symbol) |
| 256 | 252 | ||
diff --git a/lisp/textmodes/reftex.el b/lisp/textmodes/reftex.el index 8584c496a97..8318dc0d5f3 100644 --- a/lisp/textmodes/reftex.el +++ b/lisp/textmodes/reftex.el | |||
| @@ -2311,9 +2311,7 @@ IGNORE-WORDS List of words which should be removed from the string." | |||
| 2311 | ;; Return the first valid face in FACES, or nil if none is valid. | 2311 | ;; Return the first valid face in FACES, or nil if none is valid. |
| 2312 | ;; Also, when finding a nil element in FACES, return nil. This | 2312 | ;; Also, when finding a nil element in FACES, return nil. This |
| 2313 | ;; function is just a safety net to catch name changes of builtin | 2313 | ;; function is just a safety net to catch name changes of builtin |
| 2314 | ;; fonts. Currently it is only used for reftex-label-face, which has | 2314 | ;; fonts. Currently it is only used for reftex-label-face. |
| 2315 | ;; as default font-lock-reference-face, which was recently renamed | ||
| 2316 | ;; to font-lock-constant-face. | ||
| 2317 | (let (face) | 2315 | (let (face) |
| 2318 | (catch 'exit | 2316 | (catch 'exit |
| 2319 | (while (setq face (pop faces)) | 2317 | (while (setq face (pop faces)) |
diff --git a/lisp/textmodes/rst.el b/lisp/textmodes/rst.el index eeafe586c27..869da63064a 100644 --- a/lisp/textmodes/rst.el +++ b/lisp/textmodes/rst.el | |||
| @@ -118,7 +118,8 @@ | |||
| 118 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | 118 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| 119 | ;; Support for `testcover' | 119 | ;; Support for `testcover' |
| 120 | 120 | ||
| 121 | (when (boundp 'testcover-1value-functions) | 121 | (when (and (boundp 'testcover-1value-functions) |
| 122 | (boundp 'testcover-compose-functions)) | ||
| 122 | ;; Below `lambda' is used in a loop with varying parameters and is thus not | 123 | ;; Below `lambda' is used in a loop with varying parameters and is thus not |
| 123 | ;; 1valued. | 124 | ;; 1valued. |
| 124 | (setq testcover-1value-functions | 125 | (setq testcover-1value-functions |
| @@ -217,7 +218,7 @@ and before TAIL-RE and DELIM-RE in VAR or DEFAULT for no match." | |||
| 217 | ;; Use CVSHeader to really get information from CVS and not other version | 218 | ;; Use CVSHeader to really get information from CVS and not other version |
| 218 | ;; control systems. | 219 | ;; control systems. |
| 219 | (defconst rst-cvs-header | 220 | (defconst rst-cvs-header |
| 220 | "$CVSHeader: sm/rst_el/rst.el,v 1.327.2.1 2012-09-22 09:06:56 stefan Exp $") | 221 | "$CVSHeader: sm/rst_el/rst.el,v 1.327.2.2 2012-09-23 14:44:25 stefan Exp $") |
| 221 | (defconst rst-cvs-rev | 222 | (defconst rst-cvs-rev |
| 222 | (rst-extract-version "\\$" "CVSHeader: \\S + " "[0-9]+\\(?:\\.[0-9]+\\)+" | 223 | (rst-extract-version "\\$" "CVSHeader: \\S + " "[0-9]+\\(?:\\.[0-9]+\\)+" |
| 223 | " .*" rst-cvs-header "0.0") | 224 | " .*" rst-cvs-header "0.0") |
| @@ -246,7 +247,7 @@ SVN revision is the upstream (docutils) revision.") | |||
| 246 | "Official version of the package.") | 247 | "Official version of the package.") |
| 247 | (defconst rst-official-cvs-rev | 248 | (defconst rst-official-cvs-rev |
| 248 | (rst-extract-version "[%$]" "Revision: " "[0-9]+\\(?:\\.[0-9]+\\)+" " " | 249 | (rst-extract-version "[%$]" "Revision: " "[0-9]+\\(?:\\.[0-9]+\\)+" " " |
| 249 | "$Revision: 1.327.2.1 $") | 250 | "$Revision: 1.327.2.2 $") |
| 250 | "CVS revision of this file in the official version.") | 251 | "CVS revision of this file in the official version.") |
| 251 | 252 | ||
| 252 | (defconst rst-version | 253 | (defconst rst-version |
diff --git a/lisp/textmodes/sgml-mode.el b/lisp/textmodes/sgml-mode.el index 67d7f8c01f9..46c65b25b37 100644 --- a/lisp/textmodes/sgml-mode.el +++ b/lisp/textmodes/sgml-mode.el | |||
| @@ -34,7 +34,6 @@ | |||
| 34 | 34 | ||
| 35 | (eval-when-compile | 35 | (eval-when-compile |
| 36 | (require 'skeleton) | 36 | (require 'skeleton) |
| 37 | (require 'outline) | ||
| 38 | (require 'cl-lib)) | 37 | (require 'cl-lib)) |
| 39 | 38 | ||
| 40 | (defgroup sgml nil | 39 | (defgroup sgml nil |
| @@ -1938,6 +1937,10 @@ This takes effect when first loading the library.") | |||
| 1938 | ("wbr" . "Enable <br> within <nobr>")) | 1937 | ("wbr" . "Enable <br> within <nobr>")) |
| 1939 | "Value of `sgml-tag-help' for HTML mode.") | 1938 | "Value of `sgml-tag-help' for HTML mode.") |
| 1940 | 1939 | ||
| 1940 | (defvar outline-regexp) | ||
| 1941 | (defvar outline-heading-end-regexp) | ||
| 1942 | (defvar outline-level) | ||
| 1943 | |||
| 1941 | 1944 | ||
| 1942 | ;;;###autoload | 1945 | ;;;###autoload |
| 1943 | (define-derived-mode html-mode sgml-mode '(sgml-xml-mode "XHTML" "HTML") | 1946 | (define-derived-mode html-mode sgml-mode '(sgml-xml-mode "XHTML" "HTML") |
diff --git a/lisp/textmodes/tex-mode.el b/lisp/textmodes/tex-mode.el index 620a1da633e..a324daa9283 100644 --- a/lisp/textmodes/tex-mode.el +++ b/lisp/textmodes/tex-mode.el | |||
| @@ -860,10 +860,6 @@ START is the position of the \\ and DELIM is the delimiter char." | |||
| 860 | (set-keymap-parent map text-mode-map) | 860 | (set-keymap-parent map text-mode-map) |
| 861 | (tex-define-common-keys map) | 861 | (tex-define-common-keys map) |
| 862 | (define-key map "\"" 'tex-insert-quote) | 862 | (define-key map "\"" 'tex-insert-quote) |
| 863 | (define-key map "(" 'skeleton-pair-insert-maybe) | ||
| 864 | (define-key map "{" 'skeleton-pair-insert-maybe) | ||
| 865 | (define-key map "[" 'skeleton-pair-insert-maybe) | ||
| 866 | (define-key map "$" 'skeleton-pair-insert-maybe) | ||
| 867 | (define-key map "\n" 'tex-terminate-paragraph) | 863 | (define-key map "\n" 'tex-terminate-paragraph) |
| 868 | (define-key map "\M-\r" 'latex-insert-item) | 864 | (define-key map "\M-\r" 'latex-insert-item) |
| 869 | (define-key map "\C-c}" 'up-list) | 865 | (define-key map "\C-c}" 'up-list) |
diff --git a/lisp/textmodes/text-mode.el b/lisp/textmodes/text-mode.el index 30e5390a3e1..301f69f45be 100644 --- a/lisp/textmodes/text-mode.el +++ b/lisp/textmodes/text-mode.el | |||
| @@ -80,18 +80,29 @@ Turning on Paragraph-Indent Text mode runs the normal hooks | |||
| 80 | :abbrev-table nil :syntax-table nil | 80 | :abbrev-table nil :syntax-table nil |
| 81 | (paragraph-indent-minor-mode)) | 81 | (paragraph-indent-minor-mode)) |
| 82 | 82 | ||
| 83 | (defun paragraph-indent-minor-mode () | 83 | (define-minor-mode paragraph-indent-minor-mode |
| 84 | "Minor mode for editing text, with leading spaces starting a paragraph. | 84 | "Minor mode for editing text, with leading spaces starting a paragraph. |
| 85 | In this mode, you do not need blank lines between paragraphs when the | 85 | In this mode, you do not need blank lines between paragraphs when the |
| 86 | first line of the following paragraph starts with whitespace, as with | 86 | first line of the following paragraph starts with whitespace, as with |
| 87 | `paragraph-indent-text-mode'. | 87 | `paragraph-indent-text-mode'. |
| 88 | Turning on Paragraph-Indent minor mode runs the normal hook | 88 | Turning on Paragraph-Indent minor mode runs the normal hook |
| 89 | `paragraph-indent-text-mode-hook'." | 89 | `paragraph-indent-text-mode-hook'." |
| 90 | (interactive) | 90 | :initial-value nil |
| 91 | (set (make-local-variable 'paragraph-start) | 91 | ;; Change the definition of a paragraph start. |
| 92 | (concat "[ \t\n\f]\\|" paragraph-start)) | 92 | (let ((ps-re "[ \t\n\f]\\|")) |
| 93 | (set (make-local-variable 'indent-line-function) 'indent-to-left-margin) | 93 | (if (eq t (compare-strings ps-re nil nil |
| 94 | (run-hooks 'paragraph-indent-text-mode-hook)) | 94 | paragraph-start nil (length ps-re))) |
| 95 | (if (not paragraph-indent-minor-mode) | ||
| 96 | (set (make-local-variable 'paragraph-start) | ||
| 97 | (substring paragraph-start (length ps-re)))) | ||
| 98 | (if paragraph-indent-minor-mode | ||
| 99 | (set (make-local-variable 'paragraph-start) | ||
| 100 | (concat ps-re paragraph-start))))) | ||
| 101 | ;; Change the indentation function. | ||
| 102 | (if paragraph-indent-minor-mode | ||
| 103 | (set (make-local-variable 'indent-line-function) 'indent-to-left-margin) | ||
| 104 | (if (eq indent-line-function 'indent-to-left-margin) | ||
| 105 | (set (make-local-variable 'indent-line-function) 'indent-region)))) | ||
| 95 | 106 | ||
| 96 | (defalias 'indented-text-mode 'text-mode) | 107 | (defalias 'indented-text-mode 'text-mode) |
| 97 | 108 | ||