From 65e10478884e9f4a3ed55d55c7545efab1c2e9cd Mon Sep 17 00:00:00 2001 From: Roland Winkler Date: Wed, 9 Jan 2008 01:37:50 +0000 Subject: [PATCH 001/439] (bibtex-initialize): New autoloaded command. Rename from function bibtex-files-expand. New optional arg select. (bibtex-flash-head): Allow blink-matching-delay being zero. (bibtex-clean-entry): Use atomic-change-group. (bibtex-format-entry): Check presence of required fields only after formatting of fields. Use member-ignore-case. Do not use bibtex-parse-entry. Do not use booktitle field to set a missing title. (bibtex-autofill-entry): Do not call undo-boundary. (bibtex-lessp): Handle crossref keys that point to another bibtex file. (bibtex-sort-buffer, bibtex-prepare-new-entry, bibtex-validate): Parse keys if necessary. --- lisp/ChangeLog | 17 +++ lisp/textmodes/bibtex.el | 259 ++++++++++++++++++++------------------- 2 files changed, 152 insertions(+), 124 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ae32b19e7b3..cc79ba3b156 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,20 @@ +2008-01-08 Roland Winkler + + * textmodes/bibtex.el (bibtex-initialize): New autoloaded + command. Rename from function bibtex-files-expand. New optional + arg select. + (bibtex-flash-head): Allow blink-matching-delay being zero. + (bibtex-clean-entry): Use atomic-change-group. + (bibtex-format-entry): Check presence of required fields only + after formatting of fields. Use member-ignore-case. Do not use + bibtex-parse-entry. Do not use booktitle field to set a missing + title. + (bibtex-autofill-entry): Do not call undo-boundary. + (bibtex-lessp): Handle crossref keys that point to another bibtex + file. + (bibtex-sort-buffer, bibtex-prepare-new-entry, bibtex-validate): + Parse keys if necessary. + 2008-01-08 Nick Roberts * progmodes/gdb-ui.el (gdb-var-list-children-1): Put varnum in diff --git a/lisp/textmodes/bibtex.el b/lisp/textmodes/bibtex.el index 9cdd3082168..1544e4fd24f 100644 --- a/lisp/textmodes/bibtex.el +++ b/lisp/textmodes/bibtex.el @@ -119,6 +119,7 @@ inherit-booktitle If entry contains a crossref field and the booktitle realign Realign entries, so that field texts and perhaps equal signs (depending on the value of `bibtex-align-at-equal-sign') begin in the same column. + Also fill fields. last-comma Add or delete comma on end of last field in entry, according to value of `bibtex-comma-after-last-field'. delimiters Change delimiters according to variables @@ -1085,6 +1086,7 @@ Used by `bibtex-find-crossref' and for font-locking." "--" ["Convert Alien Buffer" bibtex-convert-alien t]) ("Operating on Multiple Buffers" + ["(Re)Initialize BibTeX Buffers" bibtex-initialize t] ["Validate Entries" bibtex-validate-globally t]))) (easy-menu-define @@ -1782,7 +1784,7 @@ If FLAG is nil, a message is echoed if point was incremented at least ")")) (defun bibtex-flash-head (prompt) - "Flash at BibTeX entry head before point, if exists." + "Flash at BibTeX entry head before point, if it exists." (let ((case-fold-search t) (pnt (point))) (save-excursion @@ -1790,7 +1792,8 @@ If FLAG is nil, a message is echoed if point was incremented at least (when (and (looking-at bibtex-any-entry-maybe-empty-head) (< (point) pnt)) (goto-char (match-beginning bibtex-type-in-head)) - (if (pos-visible-in-window-p (point)) + (if (and (< 0 blink-matching-delay) + (pos-visible-in-window-p (point))) (sit-for blink-matching-delay) (message "%s%s" prompt (buffer-substring-no-properties (point) (match-end bibtex-key-in-head)))))))) @@ -1875,38 +1878,42 @@ Optional arg COMMA is as in `bibtex-enclosing-field'." (defun bibtex-format-entry () "Helper function for `bibtex-clean-entry'. Formats current entry according to variable `bibtex-entry-format'." + ;; initialize `bibtex-field-braces-opt' if necessary + (if (and bibtex-field-braces-alist (not bibtex-field-braces-opt)) + (setq bibtex-field-braces-opt + (bibtex-field-re-init bibtex-field-braces-alist 'braces))) + ;; initialize `bibtex-field-strings-opt' if necessary + (if (and bibtex-field-strings-alist (not bibtex-field-strings-opt)) + (setq bibtex-field-strings-opt + (bibtex-field-re-init bibtex-field-strings-alist 'strings))) + (save-excursion (save-restriction (bibtex-narrow-to-entry) (let ((case-fold-search t) (format (if (eq bibtex-entry-format t) - '(realign opts-or-alts required-fields - numerical-fields - last-comma page-dashes delimiters - unify-case inherit-booktitle) + '(realign opts-or-alts required-fields numerical-fields + page-dashes whitespace inherit-booktitle + last-comma delimiters unify-case braces + strings) bibtex-entry-format)) - crossref-key bounds alternatives-there non-empty-alternative - entry-list req-field-list field-list) + bounds crossref-key req-field-list default-field-list field-list) - ;; Initialize `bibtex-field-braces-opt' and `bibtex-field-strings-opt' - ;; if necessary. - (unless bibtex-field-braces-opt - (setq bibtex-field-braces-opt - (bibtex-field-re-init bibtex-field-braces-alist 'braces))) - (unless bibtex-field-strings-opt - (setq bibtex-field-strings-opt - (bibtex-field-re-init bibtex-field-strings-alist 'strings))) + ;; There are more elegant high-level functions for several tasks + ;; done by `bibtex-format-entry'. However, they contain some + ;; redundancy compared with what we need to do anyway. + ;; So for speed-up we avoid using them. + ;; (`bibtex-format-entry' is called many times by `bibtex-reformat'.) ;; identify entry type (goto-char (point-min)) (or (re-search-forward bibtex-entry-type nil t) (error "Not inside a BibTeX entry")) - (let ((beg-type (1+ (match-beginning 0))) - (end-type (match-end 0))) - (setq entry-list (assoc-string (buffer-substring-no-properties + (let* ((beg-type (1+ (match-beginning 0))) + (end-type (match-end 0)) + (entry-list (assoc-string (buffer-substring-no-properties beg-type end-type) - bibtex-entry-field-alist - t)) + bibtex-entry-field-alist t))) ;; unify case of entry name (when (memq 'unify-case format) @@ -1918,35 +1925,24 @@ Formats current entry according to variable `bibtex-entry-format'." (goto-char end-type) (skip-chars-forward " \t\n") (delete-char 1) - (insert (bibtex-entry-left-delimiter)))) + (insert (bibtex-entry-left-delimiter))) - ;; determine if entry has crossref field and if at least - ;; one alternative is non-empty - (goto-char (point-min)) - (let* ((fields-alist (bibtex-parse-entry t)) - (field (assoc-string "crossref" fields-alist t))) - (setq crossref-key (and field - (not (equal "" (cdr field))) - (cdr field)) - req-field-list (if crossref-key - (nth 0 (nth 2 entry-list)) ; crossref part - (nth 0 (nth 1 entry-list)))) ; required part + ;; Do we have a crossref key? + (goto-char (point-min)) + (if (setq bounds (bibtex-search-forward-field "crossref")) + (let ((text (bibtex-text-in-field-bounds bounds t))) + (unless (equal "" text) + (setq crossref-key text)))) - (dolist (rfield req-field-list) - (when (nth 3 rfield) ; we should have an alternative - (setq alternatives-there t - field (assoc-string (car rfield) fields-alist t)) - (if (and field - (not (equal "" (cdr field)))) - (cond ((not non-empty-alternative) - (setq non-empty-alternative t)) - ((memq 'required-fields format) - (error "More than one non-empty alternative"))))))) - - (if (and alternatives-there - (not non-empty-alternative) - (memq 'required-fields format)) - (error "All alternatives are empty")) + ;; list of required fields appropriate for an entry with + ;; or without crossref key. + (setq req-field-list (if (and crossref-key (nth 2 entry-list)) + (car (nth 2 entry-list)) + (car (nth 1 entry-list))) + ;; default list of fields that may appear in this entry + default-field-list (append (nth 0 (nth 1 entry-list)) + (nth 1 (nth 1 entry-list)) + bibtex-user-optional-fields))) ;; process all fields (bibtex-beginning-first-field (point-min)) @@ -1965,25 +1961,18 @@ Formats current entry according to variable `bibtex-entry-format'." (empty-field (equal "" (bibtex-text-in-field-bounds bounds t))) deleted) - ;; We have more elegant high-level functions for several - ;; tasks done by `bibtex-format-entry'. However, they contain - ;; quite some redundancy compared with what we need to do - ;; anyway. So for speed-up we avoid using them. - (if (memq 'opts-or-alts format) + ;; delete empty optional and alternative fields + ;; (but keep empty required fields) (cond ((and empty-field (or opt-alt (let ((field (assoc-string field-name req-field-list t))) (or (not field) ; OPT field (nth 3 field))))) ; ALT field - ;; Either it is an empty ALT field. Then we have checked - ;; already that we have one non-empty alternative. Or it - ;; is an empty OPT field that we do not miss anyway. - ;; So we can safely delete this field. (delete-region beg-field end-field) (setq deleted t)) - ;; otherwise: not empty, delete "OPT" or "ALT" + ;; otherwise nonempty field: delete "OPT" or "ALT" (opt-alt (goto-char beg-name) (delete-char 3)))) @@ -2087,16 +2076,7 @@ Formats current entry according to variable `bibtex-entry-format'." (goto-char (1+ beg-text)) (insert title)))) - ;; Use booktitle to set a missing title. - (if (and empty-field - (bibtex-string= field-name "title")) - (let ((booktitle (bibtex-text-in-field "booktitle"))) - (when booktitle - (setq empty-field nil) - (goto-char (1+ beg-text)) - (insert booktitle)))) - - ;; if empty field, complain + ;; if empty field is a required field, complain (if (and empty-field (memq 'required-fields format) (assoc-string field-name req-field-list t)) @@ -2104,12 +2084,8 @@ Formats current entry according to variable `bibtex-entry-format'." ;; unify case of field name (if (memq 'unify-case format) - (let ((fname (car (assoc-string - field-name - (append (nth 0 (nth 1 entry-list)) - (nth 1 (nth 1 entry-list)) - bibtex-user-optional-fields) - t)))) + (let ((fname (car (assoc-string field-name + default-field-list t)))) (if fname (progn (delete-region beg-name end-name) @@ -2123,23 +2099,21 @@ Formats current entry according to variable `bibtex-entry-format'." ;; check whether all required fields are present (if (memq 'required-fields format) - (let ((found 0) altlist) + (let ((found 0) alt-list) (dolist (fname req-field-list) - (if (nth 3 fname) - (push (car fname) altlist)) - (unless (or (member (car fname) field-list) - (nth 3 fname)) - (error "Mandatory field `%s' is missing" (car fname)))) - (when altlist - (dolist (fname altlist) - (if (member fname field-list) - (setq found (1+ found)))) - (cond ((= found 0) - (error "Alternative mandatory field `%s' is missing" - altlist)) - ((> found 1) - (error "Alternative fields `%s' are defined %s times" - altlist found)))))) + (cond ((nth 3 fname) ; t if field has alternative flag + (push (car fname) alt-list) + (if (member-ignore-case (car fname) field-list) + (setq found (1+ found)))) + ((not (member-ignore-case (car fname) field-list)) + (error "Mandatory field `%s' is missing" (car fname))))) + (if alt-list + (cond ((= found 0) + (error "Alternative mandatory field `%s' is missing" + alt-list)) + ((> found 1) + (error "Alternative fields `%s' are defined %s times" + alt-list found)))))) ;; update comma after last field (if (memq 'last-comma format) @@ -2158,7 +2132,7 @@ Formats current entry according to variable `bibtex-entry-format'." (delete-char 1) (insert (bibtex-entry-right-delimiter))) - ;; fill entry + ;; realign and fill entry (if (memq 'realign format) (bibtex-fill-entry)))))) @@ -2426,7 +2400,7 @@ Concatenate the key: (apply 'append (mapcar (lambda (buf) (with-current-buffer buf bibtex-reference-keys)) - (bibtex-files-expand t))) + (bibtex-initialize t))) bibtex-reference-keys)) (defun bibtex-read-key (prompt &optional key global) @@ -2606,14 +2580,22 @@ Parsing initializes `bibtex-reference-keys' and `bibtex-strings'." (setq bibtex-buffer-last-parsed-tick (buffer-modified-tick))))) (setq buffers (cdr buffers)))))) -(defun bibtex-files-expand (&optional current force) - "Return an expanded list of BibTeX buffers based on `bibtex-files'. +;;;###autoload +(defun bibtex-initialize (&optional current force select) + "(Re)Initialize BibTeX buffers. +Visit the BibTeX files defined by `bibtex-files' and return a list +of corresponding buffers. Initialize in these buffers `bibtex-reference-keys' if not yet set. List of BibTeX buffers includes current buffer if CURRENT is non-nil. If FORCE is non-nil, (re)initialize `bibtex-reference-keys' even if -already set." +already set. If SELECT is non-nil interactively select a BibTeX buffer. +When called interactively, FORCE is t, CURRENT is t if current buffer uses +`bibtex-mode', and SELECT is t if current buffer does not use `bibtex-mode'," + (interactive (list (eq major-mode 'bibtex-mode) t + (not (eq major-mode 'bibtex-mode)))) (let ((file-path (split-string (or bibtex-file-path default-directory) ":+")) file-list dir-list buffer-list) + ;; generate list of BibTeX files (dolist (file bibtex-files) (cond ((eq file 'bibtex-file-path) (setq dir-list (append dir-list file-path))) @@ -2624,34 +2606,46 @@ already set." (file-name-absolute-p file)) (push file file-list)) (t - (let (fullfilename found) + (let (expanded-file-name found) (dolist (dir file-path) (when (file-readable-p - (setq fullfilename (expand-file-name file dir))) - (push fullfilename file-list) + (setq expanded-file-name (expand-file-name file dir))) + (push expanded-file-name file-list) (setq found t))) (unless found - (error "File %s not in paths defined via bibtex-file-path" + (error "File `%s' not in paths defined via bibtex-file-path" file)))))) (dolist (file file-list) (unless (file-readable-p file) - (error "BibTeX file %s not found" file))) + (error "BibTeX file `%s' not found" file))) ;; expand dir-list (dolist (dir dir-list) (setq file-list (append file-list (directory-files dir t "\\.bib\\'" t)))) (delete-dups file-list) + ;; visit files in FILE-LIST (dolist (file file-list) - (when (file-readable-p file) - (push (find-file-noselect file) buffer-list) - (with-current-buffer (car buffer-list) - (if (or force (not (listp bibtex-reference-keys))) - (bibtex-parse-keys))))) + (if (file-readable-p file) + (push (find-file-noselect file) buffer-list))) + ;; include current buffer iff we want it (cond ((and current (not (memq (current-buffer) buffer-list))) - (push (current-buffer) buffer-list) - (if force (bibtex-parse-keys))) + (push (current-buffer) buffer-list)) ((and (not current) (memq (current-buffer) buffer-list)) (setq buffer-list (delq (current-buffer) buffer-list)))) + ;; parse keys + (dolist (buffer buffer-list) + (with-current-buffer buffer + (if (or force (nlistp bibtex-reference-keys)) + (bibtex-parse-keys)))) + ;; select BibTeX buffer + (if select + (if buffer-list + (switch-to-buffer + (completing-read "Switch to BibTeX buffer: " + (mapcar 'buffer-name buffer-list) + nil t + (if current (buffer-name (current-buffer))))) + (message "No BibTeX buffers defined"))) buffer-list)) (defun bibtex-complete-internal (completions) @@ -3130,7 +3124,6 @@ field contents of the neighboring entry. Finally try to update the text based on the difference between the keys of the neighboring and the current entry (for example, the year parts of the keys)." (interactive) - (undo-boundary) ;So you can easily undo it, if it didn't work right. (bibtex-beginning-of-entry) (when (looking-at bibtex-entry-head) (let ((type (bibtex-type-in-head)) @@ -3413,13 +3406,18 @@ If its value is nil use plain sorting." (cond ((not index1) (not index2)) ; indices can be nil ((not index2) nil) ((eq bibtex-maintain-sorted-entries 'crossref) - (if (nth 1 index1) - (if (nth 1 index2) + ;; CROSSREF-KEY may be nil or it can point to an entry + ;; in another BibTeX file. In both cases we ignore CROSSREF-KEY. + (if (and (nth 1 index1) + (cdr (assoc-string (nth 1 index1) bibtex-reference-keys))) + (if (and (nth 1 index2) + (cdr (assoc-string (nth 1 index2) bibtex-reference-keys))) (or (string-lessp (nth 1 index1) (nth 1 index2)) (and (string-equal (nth 1 index1) (nth 1 index2)) (string-lessp (nth 0 index1) (nth 0 index2)))) (not (string-lessp (nth 0 index2) (nth 1 index1)))) - (if (nth 1 index2) + (if (and (nth 1 index2) + (cdr (assoc-string (nth 1 index2) bibtex-reference-keys))) (string-lessp (nth 0 index1) (nth 1 index2)) (string-lessp (nth 0 index1) (nth 0 index2))))) ((eq bibtex-maintain-sorted-entries 'entry-class) @@ -3444,6 +3442,9 @@ are ignored." (interactive) (bibtex-beginning-of-first-entry) ; Needed by `sort-subr' (bibtex-init-sort-entry-class-alist) ; Needed by `bibtex-lessp'. + (if (and (eq bibtex-maintain-sorted-entries 'crossref) + (nlistp bibtex-reference-keys)) + (bibtex-parse-keys)) ; Needed by `bibtex-lessp'. (sort-subr nil 'bibtex-skip-to-valid-entry ; NEXTREC function 'bibtex-end-of-entry ; ENDREC function @@ -3539,7 +3540,7 @@ Otherwise, use `set-buffer'. DISPLAY is t when called interactively." (interactive (list (bibtex-read-key "Find key: " nil current-prefix-arg) current-prefix-arg nil t)) (if (and global bibtex-files) - (let ((buffer-list (bibtex-files-expand t)) + (let ((buffer-list (bibtex-initialize t)) buffer found) (while (and (not found) (setq buffer (pop buffer-list))) @@ -3581,6 +3582,9 @@ search to look for place for KEY. This requires that buffer is sorted, see `bibtex-validate'. Return t if preparation was successful or nil if entry KEY already exists." (bibtex-init-sort-entry-class-alist) ; Needed by `bibtex-lessp'. + (if (and (eq bibtex-maintain-sorted-entries 'crossref) + (nlistp bibtex-reference-keys)) + (bibtex-parse-keys)) ; Needed by `bibtex-lessp'. (let ((key (nth 0 index)) key-exist) (cond ((or (null key) @@ -3671,6 +3675,9 @@ Return t if test was successful, nil otherwise." (setq syntax-error t) ;; Check for duplicate keys and correct sort order + (bibtex-init-sort-entry-class-alist) ; Needed by `bibtex-lessp'. + (bibtex-parse-keys) ; Possibly needed by `bibtex-lessp'. + ; Always needed by subsequent global key check. (let (previous current key-list) (bibtex-progress-message "Checking for duplicate keys") (bibtex-map-entries @@ -3692,9 +3699,12 @@ Return t if test was successful, nil otherwise." (bibtex-progress-message 'done)) ;; Check for duplicate keys in `bibtex-files'. - (bibtex-parse-keys) + ;; `bibtex-validate' only compares keys in current buffer with keys + ;; in `bibtex-files'. `bibtex-validate-globally' compares keys for + ;; each file in `bibtex-files' with keys of all other files in + ;; `bibtex-files'. ;; We don't want to be fooled by outdated `bibtex-reference-keys'. - (dolist (buffer (bibtex-files-expand nil t)) + (dolist (buffer (bibtex-initialize nil t)) (dolist (key (with-current-buffer buffer bibtex-reference-keys)) (when (and (cdr key) (cdr (assoc-string (car key) bibtex-reference-keys))) @@ -3792,7 +3802,7 @@ Return t if test was successful, nil otherwise." With optional prefix arg STRINGS, check for duplicate strings, too. Return t if test was successful, nil otherwise." (interactive "P") - (let ((buffer-list (bibtex-files-expand t)) + (let ((buffer-list (bibtex-initialize t)) buffer-key-list current-buf current-keys error-list) ;; Check for duplicate keys within BibTeX buffer (dolist (buffer buffer-list) @@ -4133,14 +4143,15 @@ At end of the cleaning process, the functions in (error "Not inside a BibTeX entry"))) (entry-type (bibtex-type-in-head)) (key (bibtex-key-in-head))) - ;; formatting - (cond ((bibtex-string= entry-type "preamble") - ;; (bibtex-format-preamble) - (error "No clean up of @Preamble entries")) - ((bibtex-string= entry-type "string") - (setq entry-type 'string)) - ;; (bibtex-format-string) - (t (bibtex-format-entry))) + ;; formatting (undone if error occurs) + (atomic-change-group + (cond ((bibtex-string= entry-type "preamble") + ;; (bibtex-format-preamble) + (error "No clean up of @Preamble entries")) + ((bibtex-string= entry-type "string") + (setq entry-type 'string)) + ;; (bibtex-format-string) + (t (bibtex-format-entry)))) ;; set key (when (or new-key (not key)) (setq key (bibtex-generate-autokey)) @@ -4184,7 +4195,7 @@ At end of the cleaning process, the functions in (bibtex-find-entry key nil end)))) (if error (error "New inserted entry yields duplicate key")) - (dolist (buffer (bibtex-files-expand)) + (dolist (buffer (bibtex-initialize)) (with-current-buffer buffer (if (cdr (assoc-string key bibtex-reference-keys)) (error "Duplicate key in %s" (buffer-file-name))))) From c5578d5fff348216e1e25ef7153efb16ae1b17f5 Mon Sep 17 00:00:00 2001 From: Roland Winkler Date: Wed, 9 Jan 2008 01:43:14 +0000 Subject: [PATCH 002/439] *** empty log message *** --- etc/NEWS | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/etc/NEWS b/etc/NEWS index 90cc3efaf8d..881077c0899 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -313,13 +313,15 @@ tex-suscript-height-minimum. ** BibTeX mode: +*** New command `bibtex-initialize' (re)initializes BibTeX buffers. + *** New `bibtex-entry-format' options `whitespace', `braces', and `string', disabled by default. *** New variable `bibtex-cite-matcher-alist' contains rules to identify cited keys in BibTeX entries, used by `bibtex-find-crossref'. -*** Command `bibtex-url' now allows multiple URLs per entry. +*** Command `bibtex-url' allows multiple URLs per entry. +++ ** Tramp From ea27e496b7a188df399087219b7c717cf3f6316d Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Wed, 9 Jan 2008 02:16:47 +0000 Subject: [PATCH 003/439] (ffap-read-file-or-url): Don't use let-binding to temporarily add a file-name handler. --- lisp/ChangeLog | 28 ++++++++++++++-------------- lisp/ffap.el | 33 +++++++++++++++++++-------------- 2 files changed, 33 insertions(+), 28 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index cc79ba3b156..029a81975fa 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,20 +1,22 @@ +2008-01-09 Stefan Monnier + + * ffap.el (ffap-read-file-or-url): Don't use let-binding to temporarily + add a file-name handler. + 2008-01-08 Roland Winkler - * textmodes/bibtex.el (bibtex-initialize): New autoloaded - command. Rename from function bibtex-files-expand. New optional - arg select. + * textmodes/bibtex.el (bibtex-initialize): New autoloaded command. + Rename from function bibtex-files-expand. New optional arg select. (bibtex-flash-head): Allow blink-matching-delay being zero. (bibtex-clean-entry): Use atomic-change-group. (bibtex-format-entry): Check presence of required fields only after formatting of fields. Use member-ignore-case. Do not use - bibtex-parse-entry. Do not use booktitle field to set a missing - title. + bibtex-parse-entry. Do not use booktitle field to set a missing title. (bibtex-autofill-entry): Do not call undo-boundary. - (bibtex-lessp): Handle crossref keys that point to another bibtex - file. + (bibtex-lessp): Handle crossref keys that point to another bibtex file. (bibtex-sort-buffer, bibtex-prepare-new-entry, bibtex-validate): Parse keys if necessary. - + 2008-01-08 Nick Roberts * progmodes/gdb-ui.el (gdb-var-list-children-1): Put varnum in @@ -22,8 +24,8 @@ 2008-01-08 Nick Roberts - * progmodes/gdb-ui.el (gud-gdb-command-name): Explain - "--annotate=3" option is necessary for the Graphical Interface. + * progmodes/gdb-ui.el (gud-gdb-command-name): + Explain "--annotate=3" option is necessary for the Graphical Interface. 2008-01-08 Nick Roberts @@ -91,10 +93,8 @@ * time-stamp.el (time-stamp-time-zone): * whitespace.el (whitespace-check-buffer-leading) - (whitespace-check-buffer-trailing) - (whitespace-check-buffer-indent) - (whitespace-check-buffer-spacetab) - (whitespace-check-buffer-ateol): + (whitespace-check-buffer-trailing, whitespace-check-buffer-indent) + (whitespace-check-buffer-spacetab, whitespace-check-buffer-ateol): * progmodes/sh-script.el (sh-indentation): * textmodes/ispell.el (ispell-local-pdict): Add safe-local-variable properties. diff --git a/lisp/ffap.el b/lisp/ffap.el index 52fb372b8cd..fa5e70e860b 100644 --- a/lisp/ffap.el +++ b/lisp/ffap.el @@ -1263,20 +1263,25 @@ which may actually result in an url rather than a filename." (setq dir (file-name-directory guess)))) (let ((minibuffer-completing-file-name t) (completion-ignore-case read-file-name-completion-ignore-case) - ;; because of `rfn-eshadow-update-overlay'. - (file-name-handler-alist - (cons (cons ffap-url-regexp 'url-file-handler) - file-name-handler-alist))) - (setq guess - (completing-read - prompt - 'ffap-read-file-or-url-internal - dir - nil - (if dir (cons guess (length dir)) guess) - (list 'file-name-history) - (and buffer-file-name - (abbreviate-file-name buffer-file-name))))) + (fnh-elem (cons ffap-url-regexp 'url-file-handler))) + ;; Explain to `rfn-eshadow' that we can use URLs here. + (push fnh-elem file-name-handler-alist) + (unwind-protect + (setq guess + (completing-read + prompt + 'ffap-read-file-or-url-internal + dir + nil + (if dir (cons guess (length dir)) guess) + (list 'file-name-history) + (and buffer-file-name + (abbreviate-file-name buffer-file-name)))) + ;; Remove the special handler manually. We used to just let-bind + ;; file-name-handler-alist to preserve its value, but that caused + ;; other modifications to be lost (e.g. when Tramp gets loaded + ;; during the completing-read call). + (setq file-name-handler-alist (delq fnh-elem file-name-handler-alist)))) ;; Do file substitution like (interactive "F"), suggested by MCOOK. (or (ffap-url-p guess) (setq guess (substitute-in-file-name guess))) ;; Should not do it on url's, where $ is a common (VMS?) character. From 2b0afe2a199e4568f455138e3cf8e51932a60521 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Wed, 9 Jan 2008 02:54:16 +0000 Subject: [PATCH 004/439] Fix face attributes recognition --- lisp/ChangeLog | 8 ++++++++ lisp/ps-print.el | 24 ++++++++++++++++++------ 2 files changed, 26 insertions(+), 6 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 029a81975fa..8990c2bb026 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2008-01-09 Vinicius Jose Latorre + + * ps-print.el: Some face attributes (like :strike-through) was not + being recognised. Reported by Leo . + (ps-print-version): New version 6.8.2. + (ps-face-strikout-p, ps-face-overline-p, ps-face-box-p): New funs. + (ps-screen-to-bit-face): Fix code. + 2008-01-09 Stefan Monnier * ffap.el (ffap-read-file-or-url): Don't use let-binding to temporarily diff --git a/lisp/ps-print.el b/lisp/ps-print.el index 487332f6323..a6a2f4e4302 100644 --- a/lisp/ps-print.el +++ b/lisp/ps-print.el @@ -10,11 +10,11 @@ ;; Maintainer: Kenichi Handa (multi-byte characters) ;; Vinicius Jose Latorre ;; Keywords: wp, print, PostScript -;; Version: 6.8.1 +;; Version: 6.8.2 ;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre -(defconst ps-print-version "6.8.1" - "ps-print.el, v 6.8.1 <2007/11/21 vinicius> +(defconst ps-print-version "6.8.2" + "ps-print.el, v 6.8.2 <2008/01/08 vinicius> Vinicius's last change version -- this file may have been edited as part of Emacs without changes to the version number. When reporting bugs, please also @@ -3996,6 +3996,15 @@ It can be retrieved with `(ps-get ALIST-SYM KEY)'." (or (face-italic-p face) (memq face ps-italic-faces)))) +(defun ps-face-strikeout-p (face) + (eq (face-attribute face :strike-through) t)) + +(defun ps-face-overline-p (face) + (eq (face-attribute face :overline) t)) + +(defun ps-face-box-p (face) + (not (memq (face-attribute face :box) '(nil unspecified)))) + (defvar ps-print-color-scale 1.0) (defun ps-color-scale (color) @@ -6585,9 +6594,12 @@ If FACE is not a valid face name, use default face." (defun ps-screen-to-bit-face (face) (cons face - (vector (logior (if (ps-face-bold-p face) 1 0) ; bold - (if (ps-face-italic-p face) 2 0) ; italic - (if (ps-face-underlined-p face) 4 0)) ; underline + (vector (logior (if (ps-face-bold-p face) 1 0) ; bold + (if (ps-face-italic-p face) 2 0) ; italic + (if (ps-face-underlined-p face) 4 0) ; underline + (if (ps-face-strikeout-p face) 8 0) ; strikeout + (if (ps-face-overline-p face) 16 0) ; overline + (if (ps-face-box-p face) 64 0)) ; box (ps-face-foreground-name face) (ps-face-background-name face)))) From 4277a0ecc25c7199dcf4e547402c8e451f6088c1 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Wed, 9 Jan 2008 03:45:04 +0000 Subject: [PATCH 005/439] Fix face attributes recognition --- lisp/ChangeLog | 7 +++++++ lisp/ps-print.el | 24 +++++++++++++++++++++--- 2 files changed, 28 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4e750cb14c0..8870cfd3947 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2008-01-09 Vinicius Jose Latorre + + * ps-print.el: Some face attributes (like :strike-through) was not + being recognised. Reported by Leo . + (ps-face-strikout-p, ps-face-overline-p, ps-face-box-p): New funs. + (ps-screen-to-bit-face): Fix code. + 2008-01-08 Kevin Ryde * progmodes/compile.el (compilation-error-regexp-alist-alist): diff --git a/lisp/ps-print.el b/lisp/ps-print.el index 6cc57a12ee8..4ee58a8ce29 100644 --- a/lisp/ps-print.el +++ b/lisp/ps-print.el @@ -3923,6 +3923,12 @@ It can be retrieved with `(ps-get ALIST-SYM KEY)'." (or (ps-xemacs-face-kind-p face 'ANGLE_NAME "i\\|o") (ps-xemacs-face-kind-p face 'SLANT "i\\|o") (memq face ps-italic-faces))) ; Kludge-compatible + + (defalias 'ps-face-strikeout-p 'ignore) + + (defalias 'ps-face-overline-p 'ignore) + + (defalias 'ps-face-box-p 'ignore) ) (t ; Emacs @@ -3943,6 +3949,15 @@ It can be retrieved with `(ps-get ALIST-SYM KEY)'." (defun ps-face-italic-p (face) (or (ps-e-face-italic-p face) (memq face ps-italic-faces))) + + (defun ps-face-strikeout-p (face) + (eq (face-attribute face :strike-through) t)) + + (defun ps-face-overline-p (face) + (eq (face-attribute face :overline) t)) + + (defun ps-face-box-p (face) + (not (memq (face-attribute face :box) '(nil unspecified)))) )) @@ -6508,9 +6523,12 @@ If FACE is not a valid face name, use default face." (defun ps-screen-to-bit-face (face) (cons face - (vector (logior (if (ps-face-bold-p face) 1 0) ; bold - (if (ps-face-italic-p face) 2 0) ; italic - (if (ps-face-underlined-p face) 4 0)) ; underline + (vector (logior (if (ps-face-bold-p face) 1 0) ; bold + (if (ps-face-italic-p face) 2 0) ; italic + (if (ps-face-underlined-p face) 4 0) ; underline + (if (ps-face-strikeout-p face) 8 0) ; strikeout + (if (ps-face-overline-p face) 16 0) ; overline + (if (ps-face-box-p face) 64 0)) ; box (ps-face-foreground-name face) (ps-face-background-name face)))) From 3f548a7c94280c08fd3780e5412a793d67d5637c Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:08:35 +0000 Subject: [PATCH 006/439] Add 2008 to copyright years. --- man/Makefile.in | 2 +- man/abbrevs.texi | 2 +- man/ack.texi | 2 +- man/ada-mode.texi | 2 +- man/anti.texi | 2 +- man/arevert-xtra.texi | 2 +- man/autotype.texi | 4 ++-- man/basic.texi | 2 +- man/buffers.texi | 2 +- man/building.texi | 2 +- man/cal-xtra.texi | 2 +- man/calc.texi | 4 ++-- man/calendar.texi | 2 +- man/cc-mode.texi | 2 +- man/cl.texi | 2 +- man/cmdargs.texi | 2 +- man/commands.texi | 2 +- man/custom.texi | 2 +- man/dired-x.texi | 2 +- man/dired-xtra.texi | 2 +- man/dired.texi | 2 +- man/display.texi | 2 +- man/ebrowse.texi | 2 +- man/ediff.texi | 2 +- man/emacs-mime.texi | 2 +- man/emacs-xtra.texi | 2 +- man/emacs.texi | 4 ++-- man/emerge-xtra.texi | 2 +- man/entering.texi | 2 +- man/erc.texi | 2 +- man/eshell.texi | 2 +- man/eudc.texi | 2 +- man/faq.texi | 2 +- man/files.texi | 2 +- man/fixit.texi | 2 +- man/flymake.texi | 2 +- man/forms.texi | 2 +- man/fortran-xtra.texi | 2 +- man/frames.texi | 2 +- man/glossary.texi | 2 +- man/gnu.texi | 4 ++-- man/gnus-faq.texi | 3 ++- man/gnus.texi | 2 +- man/help.texi | 2 +- man/idlwave.texi | 4 ++-- man/indent.texi | 2 +- man/info.texi | 2 +- man/killing.texi | 2 +- man/kmacro.texi | 2 +- man/m-x.texi | 2 +- man/macos.texi | 2 +- man/maintaining.texi | 2 +- man/major.texi | 2 +- man/makefile.w32-in | 2 +- man/mark.texi | 2 +- man/message.texi | 2 +- man/mh-e.texi | 2 +- man/mini.texi | 2 +- man/misc.texi | 2 +- man/msdog-xtra.texi | 2 +- man/msdog.texi | 2 +- man/mule.texi | 2 +- man/newsticker.texi | 2 +- man/org.texi | 2 +- man/pcl-cvs.texi | 4 ++-- man/pgg.texi | 4 ++-- man/picture-xtra.texi | 2 +- man/programs.texi | 2 +- man/rcirc.texi | 2 +- man/reftex.texi | 2 +- man/regs.texi | 2 +- man/rmail.texi | 2 +- man/sc.texi | 2 +- man/screen.texi | 2 +- man/search.texi | 2 +- man/sending.texi | 2 +- man/ses.texi | 2 +- man/sieve.texi | 2 +- man/smtpmail.texi | 3 ++- man/speedbar.texi | 2 +- man/texinfo.tex | 2 +- man/text.texi | 2 +- man/tramp.texi | 2 +- man/trampver.texi | 2 +- man/trouble.texi | 2 +- man/url.texi | 4 ++-- man/vc-xtra.texi | 2 +- man/vc1-xtra.texi | 2 +- man/vc2-xtra.texi | 2 +- man/vip.texi | 2 +- man/viper.texi | 2 +- man/widget.texi | 2 +- man/windows.texi | 2 +- man/woman.texi | 2 +- man/xresources.texi | 2 +- 95 files changed, 105 insertions(+), 103 deletions(-) diff --git a/man/Makefile.in b/man/Makefile.in index 00088b74b51..f6e5b27ae01 100644 --- a/man/Makefile.in +++ b/man/Makefile.in @@ -1,7 +1,7 @@ #### Makefile for the Emacs Manual and other documentation. # Copyright (C) 1994, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, -# 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +# 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # This file is part of GNU Emacs. diff --git a/man/abbrevs.texi b/man/abbrevs.texi index 585e28318e7..1dc4f62cb00 100644 --- a/man/abbrevs.texi +++ b/man/abbrevs.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, 2003, -@c 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Abbrevs @chapter Abbrevs diff --git a/man/ack.texi b/man/ack.texi index d5dbf1ae8ca..1eec6e55bd4 100644 --- a/man/ack.texi +++ b/man/ack.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1994, 1995, 1996, 1997, 1999, 2000, 2001, 2002, 2003, -@c 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @node Acknowledgments, Screen, Concept Index, Top diff --git a/man/ada-mode.texi b/man/ada-mode.texi index 241149803e8..1d40b406be3 100644 --- a/man/ada-mode.texi +++ b/man/ada-mode.texi @@ -4,7 +4,7 @@ @copying Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/anti.texi b/man/anti.texi index ebff1c7677f..01893df542e 100644 --- a/man/anti.texi +++ b/man/anti.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Antinews, Mac OS, X Resources, Top diff --git a/man/arevert-xtra.texi b/man/arevert-xtra.texi index c2b1ddc2ffe..f7682f897be 100644 --- a/man/arevert-xtra.texi +++ b/man/arevert-xtra.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @c This file is included either in emacs-xtra.texi (when producing the diff --git a/man/autotype.texi b/man/autotype.texi index 7b51f3115ac..7120baff0a5 100644 --- a/man/autotype.texi +++ b/man/autotype.texi @@ -1,7 +1,7 @@ \input texinfo @c This is an annex of the Emacs manual. @c Copyright (C) 1994, 1995, 2001, 2002, 2003, 2004, -@c 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c Author: Daniel.Pfeiffer@Informatik.START.dbp.de, fax (+49 69) 7588-2389 @setfilename ../info/autotype @c @node Autotypist, Picture, Abbrevs, Top @@ -13,7 +13,7 @@ @copying Copyright @copyright{} 1994, 1995, 1999, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/basic.texi b/man/basic.texi index 7c65eba2f01..da096f530b2 100644 --- a/man/basic.texi +++ b/man/basic.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Basic, Minibuffer, Exiting, Top @chapter Basic Editing Commands diff --git a/man/buffers.texi b/man/buffers.texi index b43d72b1067..0cb4f596d9c 100644 --- a/man/buffers.texi +++ b/man/buffers.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Buffers, Windows, Files, Top @chapter Using Multiple Buffers diff --git a/man/building.texi b/man/building.texi index 3a52182724d..3bc4ac31e7c 100644 --- a/man/building.texi +++ b/man/building.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Building, Maintaining, Programs, Top @chapter Compiling and Testing Programs diff --git a/man/cal-xtra.texi b/man/cal-xtra.texi index 61d519cbd12..f6a4af0499b 100644 --- a/man/cal-xtra.texi +++ b/man/cal-xtra.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @c This file is included either in emacs-xtra.texi (when producing the diff --git a/man/calc.texi b/man/calc.texi index e7aa34f8fec..9615aa028bc 100644 --- a/man/calc.texi +++ b/man/calc.texi @@ -84,7 +84,7 @@ This file documents Calc, the GNU Emacs calculator. Copyright @copyright{} 1990, 1991, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document @@ -119,7 +119,7 @@ Software Foundation raise funds for GNU development.'' @vskip 0pt plus 1filll Copyright @copyright{} 1990, 1991, 2001, 2002, 2003, 2004, - 2005, 2006, 2007 Free Software Foundation, Inc. + 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @insertcopying @end titlepage diff --git a/man/calendar.texi b/man/calendar.texi index e330d6f2f48..a1b26039ef9 100644 --- a/man/calendar.texi +++ b/man/calendar.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Calendar/Diary, Gnus, Dired, Top @chapter The Calendar and the Diary diff --git a/man/cc-mode.texi b/man/cc-mode.texi index 61c2a1c493e..471dca56087 100644 --- a/man/cc-mode.texi +++ b/man/cc-mode.texi @@ -160,7 +160,7 @@ CC Mode This manual is for CC Mode in Emacs. Copyright @copyright{} 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/cl.texi b/man/cl.texi index 0a09caee98e..663fb131288 100644 --- a/man/cl.texi +++ b/man/cl.texi @@ -5,7 +5,7 @@ @copying This file documents the GNU Emacs Common Lisp emulation package. -Copyright @copyright{} 1993, 2001, 2002, 2003, 2004, 2005, 2006, 2007 +Copyright @copyright{} 1993, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation diff --git a/man/cmdargs.texi b/man/cmdargs.texi index 28bad72f0bf..ffef18e5449 100644 --- a/man/cmdargs.texi +++ b/man/cmdargs.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Emacs Invocation, X Resources, GNU Free Documentation License, Top @appendix Command Line Arguments for Emacs Invocation diff --git a/man/commands.texi b/man/commands.texi index d2daffe00bb..717a87b419b 100644 --- a/man/commands.texi +++ b/man/commands.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @iftex @chapter Characters, Keys and Commands diff --git a/man/custom.texi b/man/custom.texi index 8ce0ef9f487..135c939a55c 100644 --- a/man/custom.texi +++ b/man/custom.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Customization, Quitting, Amusements, Top @chapter Customization diff --git a/man/dired-x.texi b/man/dired-x.texi index bf2d5288abc..0bb9c91caa6 100644 --- a/man/dired-x.texi +++ b/man/dired-x.texi @@ -26,7 +26,7 @@ @copying Copyright @copyright{} 1994, 1995, 1999, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/dired-xtra.texi b/man/dired-xtra.texi index e8fdf8ab468..2827ff3cdea 100644 --- a/man/dired-xtra.texi +++ b/man/dired-xtra.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @c This file is included either in emacs-xtra.texi (when producing the diff --git a/man/dired.texi b/man/dired.texi index 5088be21827..7e07e72f08e 100644 --- a/man/dired.texi +++ b/man/dired.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Dired, Calendar/Diary, Rmail, Top @chapter Dired, the Directory Editor diff --git a/man/display.texi b/man/display.texi index 5e1e0056592..5f06458dae1 100644 --- a/man/display.texi +++ b/man/display.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Display, Search, Registers, Top @chapter Controlling the Display diff --git a/man/ebrowse.texi b/man/ebrowse.texi index c04f99f954c..0888f0a015d 100644 --- a/man/ebrowse.texi +++ b/man/ebrowse.texi @@ -11,7 +11,7 @@ This file documents Ebrowse, a C++ class browser for GNU Emacs. Copyright @copyright{} 2000, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/ediff.texi b/man/ediff.texi index 6bb2605e0c6..ac3af798b87 100644 --- a/man/ediff.texi +++ b/man/ediff.texi @@ -26,7 +26,7 @@ This file documents Ediff, a comprehensive visual interface to Unix diff and patch utilities. Copyright (C) 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, -2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/emacs-mime.texi b/man/emacs-mime.texi index 0f3c141c792..2f647679f8f 100644 --- a/man/emacs-mime.texi +++ b/man/emacs-mime.texi @@ -10,7 +10,7 @@ This file documents the Emacs MIME interface functionality. Copyright @copyright{} 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, -2006, 2007 Free Software Foundation, Inc. +2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/emacs-xtra.texi b/man/emacs-xtra.texi index 841c62a527f..39591f5ef9f 100644 --- a/man/emacs-xtra.texi +++ b/man/emacs-xtra.texi @@ -10,7 +10,7 @@ @copying This manual describes specialized features of Emacs. -Copyright @copyright{} 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +Copyright @copyright{} 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/emacs.texi b/man/emacs.texi index b2fdb973039..7addd7f83a7 100644 --- a/man/emacs.texi +++ b/man/emacs.texi @@ -12,8 +12,8 @@ This is the @value{EDITION} edition of the @cite{GNU Emacs Manual},@* updated for Emacs version @value{EMACSVER}. Copyright @copyright{} 1985, 1986, 1987, 1993, 1994, 1995, 1996, 1997, -1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software -Foundation, Inc. +1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 +Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/emerge-xtra.texi b/man/emerge-xtra.texi index e78f17e59d6..a2141ec02e1 100644 --- a/man/emerge-xtra.texi +++ b/man/emerge-xtra.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @c This file is included either in emacs-xtra.texi (when producing the diff --git a/man/entering.texi b/man/entering.texi index e338a6a8619..3c79a69c084 100644 --- a/man/entering.texi +++ b/man/entering.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 2001, 2002, 2003, -@c 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Entering Emacs, Exiting, Text Characters, Top @chapter Entering and Exiting Emacs diff --git a/man/erc.texi b/man/erc.texi index 3e52bb42c92..40d4e133d59 100644 --- a/man/erc.texi +++ b/man/erc.texi @@ -14,7 +14,7 @@ @copying This manual is for ERC version 5.2. -Copyright @copyright{} 2005, 2006, 2007 Free Software Foundation, Inc. +Copyright @copyright{} 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/eshell.texi b/man/eshell.texi index 3a4b705d2c9..aebcaf6cffa 100644 --- a/man/eshell.texi +++ b/man/eshell.texi @@ -9,7 +9,7 @@ This manual is for Eshell, the Emacs shell. Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/eudc.texi b/man/eudc.texi index 7a8dbbee524..1501ce5b0cf 100644 --- a/man/eudc.texi +++ b/man/eudc.texi @@ -12,7 +12,7 @@ EUDC is the Emacs Unified Directory Client, a common interface to directory servers using various protocols such as LDAP or the CCSO white pages directory system (PH/QI) -Copyright @copyright{} 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 +Copyright @copyright{} 1998, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation diff --git a/man/faq.texi b/man/faq.texi index 787a85443fc..e750956436a 100644 --- a/man/faq.texi +++ b/man/faq.texi @@ -14,7 +14,7 @@ @c appreciate a notice if you do). @copying -Copyright @copyright{} 2001, 2002, 2003, 2004, 2005, 2006, 2007 +Copyright @copyright{} 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc.@* Copyright 1994,1995,1996,1997,1998,1999,2000 Reuven M. Lerner@* Copyright 1992,1993 Steven Byrnes@* diff --git a/man/files.texi b/man/files.texi index bc865db1067..de7195417a6 100644 --- a/man/files.texi +++ b/man/files.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 1999, 2000, -@c 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Files, Buffers, Keyboard Macros, Top @chapter File Handling diff --git a/man/fixit.texi b/man/fixit.texi index d1577e2f528..069a2e86770 100644 --- a/man/fixit.texi +++ b/man/fixit.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Fixit, Keyboard Macros, Search, Top @chapter Commands for Fixing Typos diff --git a/man/flymake.texi b/man/flymake.texi index b5ad634c803..a47d4e8fa05 100644 --- a/man/flymake.texi +++ b/man/flymake.texi @@ -11,7 +11,7 @@ This manual is for GNU Flymake (version @value{VERSION}, @value{UPDATED}), which is a universal on-the-fly syntax checker for GNU Emacs. -Copyright @copyright{} 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +Copyright @copyright{} 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/forms.texi b/man/forms.texi index 4114453df6c..54b38121e7d 100644 --- a/man/forms.texi +++ b/man/forms.texi @@ -19,7 +19,7 @@ This file documents Forms mode, a form-editing major mode for GNU Emacs. Copyright @copyright{} 1989, 1997, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/fortran-xtra.texi b/man/fortran-xtra.texi index 9249f5f006c..c443c2def70 100644 --- a/man/fortran-xtra.texi +++ b/man/fortran-xtra.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @c This file is included either in emacs-xtra.texi (when producing the diff --git a/man/frames.texi b/man/frames.texi index a45b582b455..8d9315d042e 100644 --- a/man/frames.texi +++ b/man/frames.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 1999, 2000, -@c 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Frames, International, Windows, Top @chapter Frames and Graphical Displays diff --git a/man/glossary.texi b/man/glossary.texi index a9109de667b..1403916e409 100644 --- a/man/glossary.texi +++ b/man/glossary.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Glossary, Key Index, Intro, Top @unnumbered Glossary diff --git a/man/gnu.texi b/man/gnu.texi index 1cf85f41c3c..8640612dbb4 100644 --- a/man/gnu.texi +++ b/man/gnu.texi @@ -1,13 +1,13 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1995, 2001, 2002, 2003, 2004, -@c 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @ifclear justgnu @node Manifesto,, Microsoft Windows, Top @unnumbered The GNU Manifesto @end ifclear @ifset justgnu Copyright @copyright{} 1985, 1993, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or diff --git a/man/gnus-faq.texi b/man/gnus-faq.texi index 2415a7fa01e..c8c8b38d45c 100644 --- a/man/gnus-faq.texi +++ b/man/gnus-faq.texi @@ -1,7 +1,8 @@ @c \input texinfo @c -*-texinfo-*- @c Uncomment 1st line before texing this file alone. @c %**start of header -@c Copyright (C) 1995, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 1995, 2001, 2002, 2003, 2004, 2005, 2006, 2007, +@c 2008 Free Software Foundation, Inc. @c @c Do not modify this file, it was generated from gnus-faq.xml, available from @c . diff --git a/man/gnus.texi b/man/gnus.texi index 747421959cb..ca5cdc417a3 100644 --- a/man/gnus.texi +++ b/man/gnus.texi @@ -8,7 +8,7 @@ @copying Copyright @copyright{} 1995, 1996, 1997, 1998, 1999, 2000, 2001, -2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/help.texi b/man/help.texi index fe7c2a85ffa..3e5ed5a90ff 100644 --- a/man/help.texi +++ b/man/help.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Help, Mark, M-x, Top @chapter Help diff --git a/man/idlwave.texi b/man/idlwave.texi index 4f216ac87b8..85f83bb9615 100644 --- a/man/idlwave.texi +++ b/man/idlwave.texi @@ -27,7 +27,7 @@ This is edition @value{EDITION} of the IDLWAVE User Manual for IDLWAVE @value{VERSION} Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005, - 2006, 2007 Free Software Foundation, Inc. + 2006, 2007, 2008 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or @@ -58,7 +58,7 @@ This is edition @value{EDITION} of the @cite{IDLWAVE User Manual} for IDLWAVE version @value{VERSION}, @value{DATE}. @sp 2 Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005, - 2006, 2007 Free Software Foundation, Inc. + 2006, 2007, 2008 Free Software Foundation, Inc. @sp 2 @cindex Copyright, of IDLWAVE Permission is granted to copy, distribute and/or modify this document diff --git a/man/indent.texi b/man/indent.texi index 568b54897fa..ec94816c4c3 100644 --- a/man/indent.texi +++ b/man/indent.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Indentation, Text, Major Modes, Top @chapter Indentation diff --git a/man/info.texi b/man/info.texi index de586a65507..7d618b26b3f 100644 --- a/man/info.texi +++ b/man/info.texi @@ -15,7 +15,7 @@ This file describes how to use Info, the on-line, menu-driven GNU documentation system. Copyright @copyright{} 1989, 1992, 1996, 1997, 1998, 1999, 2000, 2001, -2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/killing.texi b/man/killing.texi index b626bfab385..f4a4a185a66 100644 --- a/man/killing.texi +++ b/man/killing.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Killing, Yanking, Mark, Top diff --git a/man/kmacro.texi b/man/kmacro.texi index 16526e1a2b8..a154ba35cce 100644 --- a/man/kmacro.texi +++ b/man/kmacro.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Keyboard Macros, Files, Fixit, Top @chapter Keyboard Macros diff --git a/man/m-x.texi b/man/m-x.texi index 7a5b80fd348..e4c00eeda56 100644 --- a/man/m-x.texi +++ b/man/m-x.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node M-x, Help, Minibuffer, Top @chapter Running Commands by Name diff --git a/man/macos.texi b/man/macos.texi index 28d7f43df8e..d4673794d3c 100644 --- a/man/macos.texi +++ b/man/macos.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 2000, 2001, 2002, 2003, 2004, -@c 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Mac OS, Microsoft Windows, Antinews, Top @appendix Emacs and Mac OS diff --git a/man/maintaining.texi b/man/maintaining.texi index df0210b571e..90e5131cfc0 100644 --- a/man/maintaining.texi +++ b/man/maintaining.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 1999, 2000, -@c 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Maintaining, Abbrevs, Building, Top @chapter Maintaining Large Programs diff --git a/man/major.texi b/man/major.texi index 1cb76ee5fdf..10049ec4667 100644 --- a/man/major.texi +++ b/man/major.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Major Modes, Indentation, International, Top @chapter Major Modes diff --git a/man/makefile.w32-in b/man/makefile.w32-in index 7e3723c1949..c7c8a90c609 100644 --- a/man/makefile.w32-in +++ b/man/makefile.w32-in @@ -1,6 +1,6 @@ #### -*- Makefile -*- for the Emacs Manual and other documentation. -# Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +# Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # This file is part of GNU Emacs. diff --git a/man/mark.texi b/man/mark.texi index be446ab6bfc..2c8ee05201b 100644 --- a/man/mark.texi +++ b/man/mark.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Mark, Killing, Help, Top @chapter The Mark and the Region diff --git a/man/message.texi b/man/message.texi index 2bca4b046e5..6d5bc34dd4e 100644 --- a/man/message.texi +++ b/man/message.texi @@ -9,7 +9,7 @@ This file documents Message, the Emacs message composition mode. Copyright @copyright{} 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, -2004, 2005, 2006, 2007 Free Software Foundation, Inc. +2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/mh-e.texi b/man/mh-e.texi index a6341e80465..cb06981cfc8 100644 --- a/man/mh-e.texi +++ b/man/mh-e.texi @@ -24,7 +24,7 @@ This is version @value{VERSION}@value{EDITION} of @cite{The MH-E Manual}, last updated @value{UPDATED}. -Copyright @copyright{} 1995, 2001, 2002, 2003, 2005, 2006, 2007 Free +Copyright @copyright{} 1995, 2001, 2002, 2003, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation diff --git a/man/mini.texi b/man/mini.texi index b57e79420b6..afccc3225be 100644 --- a/man/mini.texi +++ b/man/mini.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Minibuffer, M-x, Basic, Top @chapter The Minibuffer diff --git a/man/misc.texi b/man/misc.texi index 82e48bfe13b..fcec9710d6e 100644 --- a/man/misc.texi +++ b/man/misc.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @iftex @chapter Miscellaneous Commands diff --git a/man/msdog-xtra.texi b/man/msdog-xtra.texi index 432f28888f6..3dc8e667415 100644 --- a/man/msdog-xtra.texi +++ b/man/msdog-xtra.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @c This file is included either in emacs-xtra.texi (when producing the diff --git a/man/msdog.texi b/man/msdog.texi index 0ed15229b7c..81dc126ea17 100644 --- a/man/msdog.texi +++ b/man/msdog.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Microsoft Windows, Manifesto, Mac OS, Top @appendix Emacs and Microsoft Windows/MS-DOS diff --git a/man/mule.texi b/man/mule.texi index 018521dff42..3b3d8094ff3 100644 --- a/man/mule.texi +++ b/man/mule.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1997, 1999, 2000, 2001, 2002, 2003, 2004, -@c 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node International, Major Modes, Frames, Top @chapter International Character Set Support diff --git a/man/newsticker.texi b/man/newsticker.texi index 48d7f992667..bb1748a2064 100644 --- a/man/newsticker.texi +++ b/man/newsticker.texi @@ -13,7 +13,7 @@ This manual is for Newsticker (version @value{VERSION}, @value{UPDATED}). @noindent -Copyright @copyright{} 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +Copyright @copyright{} 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/org.texi b/man/org.texi index aacc2929d13..667f67c9c2b 100644 --- a/man/org.texi +++ b/man/org.texi @@ -35,7 +35,7 @@ @copying This manual is for Org-mode (version @value{VERSION}). -Copyright @copyright{} 2004, 2005, 2006, 2007 Free Software Foundation +Copyright @copyright{} 2004, 2005, 2006, 2007, 2008 Free Software Foundation @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/pcl-cvs.texi b/man/pcl-cvs.texi index 93bd54eb456..b66a4d8ca42 100644 --- a/man/pcl-cvs.texi +++ b/man/pcl-cvs.texi @@ -7,8 +7,8 @@ @copying Copyright @copyright{} 1991, 1992, 1993, 1994, 1995, 1996, 1997, 1998, -1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software -Foundation, Inc. +1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 +Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/pgg.texi b/man/pgg.texi index 6a175db4cb9..16c404001e5 100644 --- a/man/pgg.texi +++ b/man/pgg.texi @@ -8,8 +8,8 @@ @copying This file describes PGG, an Emacs interface to various PGP implementations. -Copyright @copyright{} 2001, 2003, 2004, 2005, 2006, 2007 Free Software -Foundation, Inc. +Copyright @copyright{} 2001, 2003, 2004, 2005, 2006, 2007, 2008 +Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/picture-xtra.texi b/man/picture-xtra.texi index ad3b9f27cc5..0001f41abda 100644 --- a/man/picture-xtra.texi +++ b/man/picture-xtra.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @c This file is included either in emacs-xtra.texi (when producing the diff --git a/man/programs.texi b/man/programs.texi index 2472d7daabe..b1c196ba077 100644 --- a/man/programs.texi +++ b/man/programs.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 1999, 2000, -@c 2001, 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Programs, Building, Text, Top @chapter Editing Programs diff --git a/man/rcirc.texi b/man/rcirc.texi index 6d5319cef4e..1071ce3087f 100644 --- a/man/rcirc.texi +++ b/man/rcirc.texi @@ -5,7 +5,7 @@ @c %**end of header @copying -Copyright @copyright{} 2006, 2007 Free Software Foundation, Inc. +Copyright @copyright{} 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/reftex.texi b/man/reftex.texi index a2c0a9689b2..203878656b7 100644 --- a/man/reftex.texi +++ b/man/reftex.texi @@ -28,7 +28,7 @@ This is edition @value{EDITION} of the @b{Ref@TeX{}} User Manual for @b{Ref@TeX{}} @value{VERSION} Copyright @copyright{} 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/regs.texi b/man/regs.texi index 475a3b7b1b5..6be26123a65 100644 --- a/man/regs.texi +++ b/man/regs.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Registers, Display, CUA Bindings, Top @chapter Registers diff --git a/man/rmail.texi b/man/rmail.texi index 9ccdffedca1..7c1c2dd5160 100644 --- a/man/rmail.texi +++ b/man/rmail.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Rmail, Dired, Sending Mail, Top @chapter Reading Mail with Rmail diff --git a/man/sc.texi b/man/sc.texi index 5ac3b882ccd..de2b35fe15e 100644 --- a/man/sc.texi +++ b/man/sc.texi @@ -16,7 +16,7 @@ attributing the replies for various GNU Emacs mail and news reading subsystems. Copyright @copyright{} 1993, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/screen.texi b/man/screen.texi index 87b037849ce..ba3b85d297f 100644 --- a/man/screen.texi +++ b/man/screen.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Screen, User Input, Acknowledgments, Top @chapter The Organization of the Screen diff --git a/man/search.texi b/man/search.texi index 48af28fa441..64dee038ae9 100644 --- a/man/search.texi +++ b/man/search.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Search, Fixit, Display, Top @chapter Searching and Replacement diff --git a/man/sending.texi b/man/sending.texi index 5d6a7c83f3e..1d1e13af22f 100644 --- a/man/sending.texi +++ b/man/sending.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Sending Mail @chapter Sending Mail diff --git a/man/ses.texi b/man/ses.texi index 089e13a9cc0..1327c9f9180 100644 --- a/man/ses.texi +++ b/man/ses.texi @@ -11,7 +11,7 @@ @copying This file documents SES: the Simple Emacs Spreadsheet. -Copyright @copyright{} 2002, 2003, 2004, 2005, 2006, 2007 +Copyright @copyright{} 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation diff --git a/man/sieve.texi b/man/sieve.texi index 4b7a95be952..7d4f32d0a70 100644 --- a/man/sieve.texi +++ b/man/sieve.texi @@ -9,7 +9,7 @@ @copying This file documents the Emacs Sieve package, for server-side mail filtering. -Copyright @copyright{} 2001, 2002, 2003, 2004, 2005, 2006, 2007 +Copyright @copyright{} 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation diff --git a/man/smtpmail.texi b/man/smtpmail.texi index 644cd061b74..875179050ef 100644 --- a/man/smtpmail.texi +++ b/man/smtpmail.texi @@ -3,7 +3,8 @@ @settitle Emacs SMTP Library @syncodeindex vr fn @copying -Copyright @copyright{} 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +Copyright @copyright{} 2003, 2004, 2005, 2006, 2007, 2008 +Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/speedbar.texi b/man/speedbar.texi index 2a05993f569..4a1c87a6b4d 100644 --- a/man/speedbar.texi +++ b/man/speedbar.texi @@ -6,7 +6,7 @@ @copying Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, -2007 Free Software Foundation, Inc. +2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/texinfo.tex b/man/texinfo.tex index d3107f9fc33..f7bab248026 100644 --- a/man/texinfo.tex +++ b/man/texinfo.tex @@ -7,7 +7,7 @@ % % Copyright (C) 1985, 1986, 1988, 1990, 1991, 1992, 1993, 1994, 1995, % 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, -% 2007 Free Software Foundation, Inc. +% 2007, 2008 Free Software Foundation, Inc. % % This texinfo.tex file is free software; you can redistribute it and/or % modify it under the terms of the GNU General Public License as diff --git a/man/text.texi b/man/text.texi index 5365a2062e1..dffd80930ae 100644 --- a/man/text.texi +++ b/man/text.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Text, Programs, Indentation, Top @chapter Commands for Human Languages diff --git a/man/tramp.texi b/man/tramp.texi index 67b0647787c..c4f2cc88f6e 100644 --- a/man/tramp.texi +++ b/man/tramp.texi @@ -25,7 +25,7 @@ @end macro @copying -Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007 +Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation diff --git a/man/trampver.texi b/man/trampver.texi index 6c770dc8ad1..f60b8ccb565 100644 --- a/man/trampver.texi +++ b/man/trampver.texi @@ -2,7 +2,7 @@ @c texi/trampver.texi. Generated from trampver.texi.in by configure. @c This is part of the Emacs manual. -@c Copyright (C) 2003, 2004, 2005, 2006, 2007 +@c Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 @c Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. diff --git a/man/trouble.texi b/man/trouble.texi index 494637c8eeb..4ea53ee9b08 100644 --- a/man/trouble.texi +++ b/man/trouble.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2001, 2002, -@c 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @iftex @chapter Dealing with Common Problems diff --git a/man/url.texi b/man/url.texi index 0fc6b08acdc..d6910697bdc 100644 --- a/man/url.texi +++ b/man/url.texi @@ -22,7 +22,7 @@ This file documents the URL loading package. Copyright @copyright{} 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2002, -2004, 2005, 2006, 2007 Free Software Foundation, Inc. +2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or @@ -50,7 +50,7 @@ License.'' @page @vskip 0pt plus 1filll Copyright @copyright{} 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2002, -2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or diff --git a/man/vc-xtra.texi b/man/vc-xtra.texi index 6ec69d60896..46a66d7c386 100644 --- a/man/vc-xtra.texi +++ b/man/vc-xtra.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @c This file is included in emacs-xtra.texi when producing the printed diff --git a/man/vc1-xtra.texi b/man/vc1-xtra.texi index 6d5df78848c..bfccec966a4 100644 --- a/man/vc1-xtra.texi +++ b/man/vc1-xtra.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @c This file is included either in vc-xtra.texi (when producing the diff --git a/man/vc2-xtra.texi b/man/vc2-xtra.texi index 5a8d131705a..273a01d12f7 100644 --- a/man/vc2-xtra.texi +++ b/man/vc2-xtra.texi @@ -1,5 +1,5 @@ @c This is part of the Emacs manual. -@c Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @c @c This file is included either in vc-xtra.texi (when producing the diff --git a/man/vip.texi b/man/vip.texi index a3f4a447f82..d5a422828d0 100644 --- a/man/vip.texi +++ b/man/vip.texi @@ -5,7 +5,7 @@ @copying Copyright @copyright{} 1987, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/viper.texi b/man/viper.texi index 55c97f18c9c..14dacf546d5 100644 --- a/man/viper.texi +++ b/man/viper.texi @@ -8,7 +8,7 @@ @copying Copyright @copyright{} 1995, 1996, 1997, 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/widget.texi b/man/widget.texi index 47d86f43349..31c9f6bce2d 100644 --- a/man/widget.texi +++ b/man/widget.texi @@ -11,7 +11,7 @@ @copying Copyright @copyright{} 2000, 2001, 2002, 2003, 2004, 2005, -2006, 2007 Free Software Foundation, Inc. +2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/windows.texi b/man/windows.texi index fa9cadc1351..110c732f61b 100644 --- a/man/windows.texi +++ b/man/windows.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1985, 1986, 1987, 1993, 1994, 1995, 1997, 2000, 2001, -@c 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node Windows, Frames, Buffers, Top @chapter Multiple Windows diff --git a/man/woman.texi b/man/woman.texi index 868bb510f50..4d681f0ac55 100644 --- a/man/woman.texi +++ b/man/woman.texi @@ -18,7 +18,7 @@ This file documents WoMan: A program to browse Unix manual pages `W.O. (without) man'. Copyright @copyright{} 2001, 2002, 2003, 2004, -2005, 2006, 2007 Free Software Foundation, Inc. +2005, 2006, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/man/xresources.texi b/man/xresources.texi index c402ec89f88..9173de21a54 100644 --- a/man/xresources.texi +++ b/man/xresources.texi @@ -1,6 +1,6 @@ @c This is part of the Emacs manual. @c Copyright (C) 1987, 1993, 1994, 1995, 1997, 2001, 2002, 2003, -@c 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +@c 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c See file emacs.texi for copying conditions. @node X Resources, Antinews, Emacs Invocation, Top @appendix X Options and Resources From 5507b8088f20778a7657cb9939d81721252fd07e Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:13:56 +0000 Subject: [PATCH 007/439] *** empty log message *** --- admin/FOR-RELEASE | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index d58915318ec..8ac97232def 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -50,6 +50,9 @@ http://lists.gnu.org/archive/html/bug-gnu-emacs/2007-09/msg00055.html * BUGS +** schierlm@gmx.de, 25 Dec: Crash when buffer is edited while save-buffer asks for coding system +http://lists.gnu.org/archive/html/bug-gnu-emacs/2007-12/msg00134.html + ** bojohan+news@dd.chalmers.se, 19 Nov: appointment display during isearch replaces buffer contents with history element. http://lists.gnu.org/archive/html/bug-gnu-emacs/2008-01/msg00005.html (patch) @@ -59,6 +62,11 @@ http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00589.html ** pot@gnu.org, 17 Dec: strange From line maker rmail-reply loop http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00460.html +reproducible? + +** nico@ngolde.de, 7 Jan: some code issues +some unsafe code in pop.c +http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00654.html * DOCUMENTATION From 9a8eebc2da77b386670232e867402130881e737d Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:15:13 +0000 Subject: [PATCH 008/439] Add 2008 to copyright years. --- man/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/man/ChangeLog b/man/ChangeLog index 6159a91c8fa..c8dd0cf1fda 100644 --- a/man/ChangeLog +++ b/man/ChangeLog @@ -8196,7 +8196,7 @@ ;; End: Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002, - 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. + 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This file is part of GNU Emacs. From f134080ea2506aed5b4806359633bd8371bc9a06 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:17:04 +0000 Subject: [PATCH 009/439] (ffap-string-at-point-mode-alist): Add `\' to file entry, for Windows. --- lisp/ChangeLog | 5 +++++ lisp/ffap.el | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8870cfd3947..555c941d2e4 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-09 Glenn Morris + + * ffap.el (ffap-string-at-point-mode-alist): Add `\' to file + entry, for Windows. + 2008-01-09 Vinicius Jose Latorre * ps-print.el: Some face attributes (like :strike-through) was not diff --git a/lisp/ffap.el b/lisp/ffap.el index 881766d92ca..3e62f2351c6 100644 --- a/lisp/ffap.el +++ b/lisp/ffap.el @@ -969,7 +969,7 @@ If t, `ffap-tex-init' will initialize this when needed.") ;; Slightly controversial decisions: ;; * strip trailing "@" and ":" ;; * no commas (good for latex) - (file "--:$+<>@-Z_[:lower:]~*?" "<@" "@>;.,!:") + (file "--:\\\\$+<>@-Z_[:lower:]~*?" "<@" "@>;.,!:") ;; An url, or maybe a email/news message-id: (url "--:=&?$+@-Z_[:lower:]~#,%;*" "^[:alnum:]" ":;.,!?") ;; Find a string that does *not* contain a colon: From d65fc712a6b4529758435536d8d3a87715ed51f3 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:17:56 +0000 Subject: [PATCH 010/439] (ffap-string-at-point-mode-alist): Add `\' to file entry, for Windows. --- lisp/ChangeLog | 9 +++++++++ lisp/ffap.el | 2 +- 2 files changed, 10 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8990c2bb026..b24807e36b4 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,12 @@ +2008-01-09 Glenn Morris + + * ffap.el (ffap-string-at-point-mode-alist): Add `\' to file + entry, for Windows. + +2008-01-09 Tom Tromey + + * play/blackbox.el (blackbox-mode-map): Add `q' and [return] bindings. + 2008-01-09 Vinicius Jose Latorre * ps-print.el: Some face attributes (like :strike-through) was not diff --git a/lisp/ffap.el b/lisp/ffap.el index fa5e70e860b..27cdd9cf512 100644 --- a/lisp/ffap.el +++ b/lisp/ffap.el @@ -969,7 +969,7 @@ If t, `ffap-tex-init' will initialize this when needed.") ;; Slightly controversial decisions: ;; * strip trailing "@" and ":" ;; * no commas (good for latex) - (file "--:$+<>@-Z_[:lower:]~*?" "<@" "@>;.,!:") + (file "--:\\\\$+<>@-Z_[:lower:]~*?" "<@" "@>;.,!:") ;; An url, or maybe a email/news message-id: (url "--:=&?$+@-Z_[:lower:]~#,%;*" "^[:alnum:]" ":;.,!?") ;; Find a string that does *not* contain a colon: From c14bb1fb7c692bd466ea09132b2711ecda37931f Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:18:27 +0000 Subject: [PATCH 011/439] Tom Tromey (blackbox-mode-map): Add `q' and [return] bindings. --- lisp/play/blackbox.el | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lisp/play/blackbox.el b/lisp/play/blackbox.el index e54dad675a8..f8ed471beb7 100644 --- a/lisp/play/blackbox.el +++ b/lisp/play/blackbox.el @@ -106,7 +106,9 @@ (blackbox-redefine-key map 'move-end-of-line 'bb-eol) (blackbox-redefine-key map 'move-beginning-of-line 'bb-bol) (define-key map " " 'bb-romp) + (define-key map "q" 'bury-buffer) (define-key map [insert] 'bb-romp) + (define-key map [return] 'bb-done) (blackbox-redefine-key map 'newline 'bb-done) map)) From 20234d96d061496be71fbb0d504f49c2b3f2ddeb Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:19:33 +0000 Subject: [PATCH 012/439] Add @copying section. --- doc/misc/ChangeLog | 6 +++++- doc/misc/nxml-mode.texi | 27 +++++++++++++++++++++++++++ 2 files changed, 32 insertions(+), 1 deletion(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index 975b65dfc37..12ec5d31242 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,7 @@ +2008-01-09 Glenn Morris + + * nxml-mode.texi: Add @copying section. + 2008-01-05 Reiner Steib * message.texi (Mail Variables): Add some text from "(gnus)Posting @@ -4673,7 +4677,7 @@ ;; End: Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002, - 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. + 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This file is part of GNU Emacs. diff --git a/doc/misc/nxml-mode.texi b/doc/misc/nxml-mode.texi index c79a552959f..6a47e8892f7 100644 --- a/doc/misc/nxml-mode.texi +++ b/doc/misc/nxml-mode.texi @@ -4,6 +4,33 @@ @settitle nXML Mode @c %**end of header +@copying + +This manual documents nxml-mode, an Emacs major mode for editing +XML with RELAX NG support. + +Copyright @copyright{} 2007, 2008 Free Software Foundation, Inc. + +@quotation +Permission is granted to copy, distribute and/or modify this document +under the terms of the GNU Free Documentation License, Version 1.2 or +any later version published by the Free Software Foundation; with no +Invariant Sections, with the Front-Cover texts being ``A GNU +Manual,'' and with the Back-Cover Texts as in (a) below. A copy of the +license is included in the section entitled ``GNU Free Documentation +License'' in the Emacs manual. + +(a) The FSF's Back-Cover Text is: ``You have freedom to copy and modify +this GNU Manual, like GNU software. Copies published by the Free +Software Foundation raise funds for GNU development.'' + +This document is part of a collection distributed under the GNU Free +Documentation License. If you want to distribute this document +separately from the collection, you can do so by adding a copy of the +license to the document, as described in section 6 of the license. +@end quotation +@end copying + @dircategory Emacs @direntry * nXML Mode: (nxml-mode). XML editing mode with RELAX NG support. From cf6f71ac502ab825e2d34b729e734efff09d8abf Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:19:59 +0000 Subject: [PATCH 013/439] Add 2008 to copyright years. Add license text. --- admin/notes/lel-TODO | 22 +++++++++++++++++++++- 1 file changed, 21 insertions(+), 1 deletion(-) diff --git a/admin/notes/lel-TODO b/admin/notes/lel-TODO index f5254d7a956..9246f1dc8c2 100644 --- a/admin/notes/lel-TODO +++ b/admin/notes/lel-TODO @@ -1,5 +1,7 @@ Some lisp/emacs-lisp/ Features and Where They Are Documented -Copyright (C) 2007 Free Software Foundation, Inc. + +Copyright (C) 2007, 2008 Free Software Foundation, Inc. +See the end of the file for license conditions. * Status Key @@ -102,6 +104,24 @@ Copyright (C) 2007 Free Software Foundation, Inc. * Etc + +This file is part of GNU Emacs. + +GNU Emacs is free software; you can redistribute it and/or modify +it under the terms of the GNU General Public License as published by +the Free Software Foundation; either version 3, or (at your option) +any later version. + +GNU Emacs is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU General Public License for more details. + +You should have received a copy of the GNU General Public License +along with GNU Emacs; see the file COPYING. If not, write to the +Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +Boston, MA 02110-1301, USA. + Local variables: mode: outline End: From 9c6b35b29ab8eba9fd471fa783637158e51136d3 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:21:32 +0000 Subject: [PATCH 014/439] Remove copyright from author with assignment and merge years into FSF years. Add 2008 to copyright years. --- doc/misc/sasl.texi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/doc/misc/sasl.texi b/doc/misc/sasl.texi index 9cd465abb26..193eb8f16b7 100644 --- a/doc/misc/sasl.texi +++ b/doc/misc/sasl.texi @@ -14,8 +14,8 @@ @ifinfo This file describes the Emacs SASL library. -Copyright @copyright{} 2004, 2005, 2006 Free Software Foundation, Inc. -Copyright @copyright{} 2000 Daiki Ueno. +Copyright @copyright{} 2000, 2004, 2005, 2006, 2007, 2008 +Free Software Foundation, Inc. Permission is granted to copy, distribute and/or modify this document under the terms of the GNU Free Documentation License, Version 1.2 or From dcb8ac09ea4b4a500da0b9a72e230bd94f59bd3d Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:31:51 +0000 Subject: [PATCH 015/439] Add 2008 to copyright years. --- doc/emacs/ChangeLog | 2 +- doc/man/ChangeLog | 2 +- doc/misc/gnus-coding.texi | 2 +- doc/misc/gnus-news.el | 4 ++-- doc/misc/gnus-news.texi | 2 +- doc/misc/remember.texi | 3 ++- etc/NEWS | 2 +- etc/emacs3.py | 2 +- etc/images/icons/README | 5 +++-- etc/images/smilies/grayscale/README | 2 +- etc/images/smilies/medium/README | 2 +- etc/refcards/Makefile | 2 +- etc/refcards/README | 2 +- lisp/ChangeLog.12 | 2 +- lisp/calc/calc-menu.el | 2 +- lisp/calc/calc-nlfit.el | 2 +- lisp/emacs-lisp/avl-tree.el | 2 +- lisp/emacs-lisp/check-declare.el | 2 +- lisp/gnus/ecomplete.el | 2 +- lisp/gnus/gnus-bookmark.el | 2 +- lisp/gnus/spam-wash.el | 2 +- lisp/isearch-multi.el | 2 +- lisp/mail/hashcash.el | 2 +- lisp/mb-depth.el | 2 +- lisp/md4.el | 2 +- lisp/net/hmac-def.el | 2 +- lisp/net/hmac-md5.el | 2 +- lisp/net/ntlm.el | 2 +- lisp/net/sasl-cram.el | 2 +- lisp/net/sasl-digest.el | 2 +- lisp/net/sasl-ntlm.el | 2 +- lisp/net/sasl.el | 2 +- lisp/net/tramp-cache.el | 2 +- lisp/net/tramp-cmds.el | 2 +- lisp/net/tramp-compat.el | 2 +- lisp/net/tramp-fish.el | 2 +- lisp/net/tramp-gw.el | 2 +- lisp/nxml/nxml-enc.el | 2 +- lisp/nxml/nxml-glyph.el | 2 +- lisp/nxml/nxml-maint.el | 2 +- lisp/nxml/nxml-mode.el | 2 +- lisp/nxml/nxml-ns.el | 2 +- lisp/nxml/nxml-outln.el | 2 +- lisp/nxml/nxml-parse.el | 2 +- lisp/nxml/nxml-rap.el | 2 +- lisp/nxml/nxml-uchnm.el | 2 +- lisp/nxml/nxml-util.el | 2 +- lisp/nxml/rng-cmpct.el | 2 +- lisp/nxml/rng-dt.el | 2 +- lisp/nxml/rng-loc.el | 2 +- lisp/nxml/rng-maint.el | 2 +- lisp/nxml/rng-match.el | 2 +- lisp/nxml/rng-nxml.el | 2 +- lisp/nxml/rng-parse.el | 2 +- lisp/nxml/rng-pttrn.el | 2 +- lisp/nxml/rng-uri.el | 2 +- lisp/nxml/rng-util.el | 2 +- lisp/nxml/rng-valid.el | 2 +- lisp/nxml/rng-xsd.el | 2 +- lisp/nxml/xmltok.el | 2 +- lisp/nxml/xsd-regexp.el | 2 +- lisp/password-cache.el | 2 +- lisp/play/bubbles.el | 2 +- lisp/ps-print.el | 2 +- lisp/term/w32console.el | 2 +- lisp/textmodes/org-export-latex.el | 2 +- lisp/textmodes/org-publish.el | 2 +- lisp/textmodes/remember.el | 4 ++-- src/ChangeLog.10 | 4 ++-- src/terminal.c | 2 +- 70 files changed, 76 insertions(+), 74 deletions(-) diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index bd5c2258b3c..282ca6f1d52 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -5096,7 +5096,7 @@ ;; End: Copyright (C) 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2001, 2002, - 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. + 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This file is part of GNU Emacs. diff --git a/doc/man/ChangeLog b/doc/man/ChangeLog index 8d4b9aaab52..fb96e021996 100644 --- a/doc/man/ChangeLog +++ b/doc/man/ChangeLog @@ -22,7 +22,7 @@ ;; add-log-time-zone-rule: t ;; End: - Copyright (C) 2007 Free Software Foundation, Inc. + Copyright (C) 2007, 2008 Free Software Foundation, Inc. This file is part of GNU Emacs. diff --git a/doc/misc/gnus-coding.texi b/doc/misc/gnus-coding.texi index 1fead8c9b80..b6dc3148da2 100644 --- a/doc/misc/gnus-coding.texi +++ b/doc/misc/gnus-coding.texi @@ -7,7 +7,7 @@ @syncodeindex pg cp @copying -Copyright (c) 2004, 2005, 2007 Free Software Foundation, Inc. +Copyright (C) 2004, 2005, 2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/doc/misc/gnus-news.el b/doc/misc/gnus-news.el index 9f31513e435..5e8999a80dd 100644 --- a/doc/misc/gnus-news.el +++ b/doc/misc/gnus-news.el @@ -1,5 +1,5 @@ ;;; gnus-news.el --- a hack to create GNUS-NEWS from texinfo source -;; Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc. +;; Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. ;; Author: Reiner Steib ;; Keywords: tools @@ -29,7 +29,7 @@ "GNUS NEWS -- history of user-visible changes. Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, - 2006, 2007 Free Software Foundation, Inc. + 2006, 2007, 2008 Free Software Foundation, Inc. See the end of the file for license conditions. Please send Gnus bug reports to bugs@gnus.org. diff --git a/doc/misc/gnus-news.texi b/doc/misc/gnus-news.texi index 0c08a93883b..e9549779232 100644 --- a/doc/misc/gnus-news.texi +++ b/doc/misc/gnus-news.texi @@ -1,6 +1,6 @@ @c -*-texinfo-*- -@c Copyright (C) 2004, 2005, 2006 Free Software Foundation, Inc. +@c Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @c Permission is granted to anyone to make or distribute verbatim copies @c of this document as received, in any medium, provided that the diff --git a/doc/misc/remember.texi b/doc/misc/remember.texi index d93774c5850..d653339ce6a 100644 --- a/doc/misc/remember.texi +++ b/doc/misc/remember.texi @@ -14,7 +14,8 @@ @copying This manual is for Remember Mode, version 1.9 -Copyright @copyright{} 2001, 2004, 2005, 2007 Free Software Foundation, Inc. +Copyright @copyright{} 2001, 2004, 2005, 2007, 2008 +Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/etc/NEWS b/etc/NEWS index 881077c0899..076bde31b32 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -1,6 +1,6 @@ GNU Emacs NEWS -- history of user-visible changes. -Copyright (C) 2007 Free Software Foundation, Inc. +Copyright (C) 2007, 2008 Free Software Foundation, Inc. See the end of the file for license conditions. Please send Emacs bug reports to emacs-pretest-bug@gnu.org. diff --git a/etc/emacs3.py b/etc/emacs3.py index 96e8ebbfb8b..7160eb27a8c 100644 --- a/etc/emacs3.py +++ b/etc/emacs3.py @@ -5,7 +5,7 @@ """Definitions used by commands sent to inferior Python in python.el.""" -# Copyright (C) 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +# Copyright (C) 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # Author: Dave Love # This file is part of GNU Emacs. diff --git a/etc/images/icons/README b/etc/images/icons/README index 1fcf871a5b2..78b0b86097b 100644 --- a/etc/images/icons/README +++ b/etc/images/icons/README @@ -1,6 +1,7 @@ COPYRIGHT AND LICENSE INFORMATION FOR IMAGE FILES -Files: hicolor/16x16/apps/emacs.png hicolor/24x24/apps/emacs.png hicolor/32x32/apps/emacs.png hicolor/48x48/apps/emacs.png +Files: hicolor/16x16/apps/emacs.png hicolor/24x24/apps/emacs.png + hicolor/32x32/apps/emacs.png hicolor/48x48/apps/emacs.png Author: Andrew Zhilin Copyright (C) 2005, 2006, 2007, 2008 Free Software Foundation, Inc. License: GNU General Public License version 3 or later (see COPYING) @@ -8,5 +9,5 @@ License: GNU General Public License version 3 or later (see COPYING) Files: emacs16_mac.png emacs24_mac.png emacs32_mac.png emacs48_mac.png emacs256_mac.png emacs512_mac.png Author: Kentaro Ohkouchi -Copyright (C) 2007 Free Software Foundation, Inc. +Copyright (C) 2007, 2008 Free Software Foundation, Inc. License: GNU General Public License version 3 or later (see COPYING) diff --git a/etc/images/smilies/grayscale/README b/etc/images/smilies/grayscale/README index 10c3e3cc272..d2e635a2277 100644 --- a/etc/images/smilies/grayscale/README +++ b/etc/images/smilies/grayscale/README @@ -2,5 +2,5 @@ Files: blink.xpm braindamaged.xpm cry.xpm dead.xpm evil.xpm forced.xpm frown.xpm grin.xpm indifferent.xpm reverse-smile.xpm sad.xpm smile.xpm wry.xpm Author: Adam Sjøgren -Copyright (C) 2007 Free Software Foundation, Inc. +Copyright (C) 2007, 2008 Free Software Foundation, Inc. License: GNU General Public License version 3 or later (see COPYING) diff --git a/etc/images/smilies/medium/README b/etc/images/smilies/medium/README index 10c3e3cc272..d2e635a2277 100644 --- a/etc/images/smilies/medium/README +++ b/etc/images/smilies/medium/README @@ -2,5 +2,5 @@ Files: blink.xpm braindamaged.xpm cry.xpm dead.xpm evil.xpm forced.xpm frown.xpm grin.xpm indifferent.xpm reverse-smile.xpm sad.xpm smile.xpm wry.xpm Author: Adam Sjøgren -Copyright (C) 2007 Free Software Foundation, Inc. +Copyright (C) 2007, 2008 Free Software Foundation, Inc. License: GNU General Public License version 3 or later (see COPYING) diff --git a/etc/refcards/Makefile b/etc/refcards/Makefile index 8ac87d26d75..4d3527eba97 100644 --- a/etc/refcards/Makefile +++ b/etc/refcards/Makefile @@ -1,7 +1,7 @@ ### Makefile for Emacs refcards ## Copyright (C) 1993, 1994, 2001, 2002, 2003, 2004, 2005, 2006, -## 2007 Free Software Foundation, Inc. +## 2007, 2008 Free Software Foundation, Inc. ## This file is part of GNU Emacs. diff --git a/etc/refcards/README b/etc/refcards/README index c9ae93a276a..278d02db1dc 100644 --- a/etc/refcards/README +++ b/etc/refcards/README @@ -12,6 +12,6 @@ it is reproduced here for convenience. File: gnus-logo.eps, gnus-logo.pdf Author: Luis Fernandes - Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007 + Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. License: GNU General Public License version 3 or later (see COPYING) diff --git a/lisp/ChangeLog.12 b/lisp/ChangeLog.12 index 2c6111f3ec3..cd89281256e 100644 --- a/lisp/ChangeLog.12 +++ b/lisp/ChangeLog.12 @@ -33364,7 +33364,7 @@ See ChangeLog.11 for earlier changes. ;; add-log-time-zone-rule: t ;; End: - Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc. + Copyright (C) 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This file is part of GNU Emacs. diff --git a/lisp/calc/calc-menu.el b/lisp/calc/calc-menu.el index ca67b65abfa..973a6a0c9d2 100644 --- a/lisp/calc/calc-menu.el +++ b/lisp/calc/calc-menu.el @@ -1,6 +1,6 @@ ;;; calc-menu.el --- a menu for Calc -;; Copyright (C) 2007 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. ;; Maintainer: Jay Belanger diff --git a/lisp/calc/calc-nlfit.el b/lisp/calc/calc-nlfit.el index 4019058a567..4eb1093af18 100644 --- a/lisp/calc/calc-nlfit.el +++ b/lisp/calc/calc-nlfit.el @@ -1,6 +1,6 @@ ;;; calc-nlfit.el --- nonlinear curve fitting for Calc -;; Copyright (C) 2007 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. ;; Maintainer: Jay Belanger diff --git a/lisp/emacs-lisp/avl-tree.el b/lisp/emacs-lisp/avl-tree.el index b8cf8362386..f2eb06710e1 100644 --- a/lisp/emacs-lisp/avl-tree.el +++ b/lisp/emacs-lisp/avl-tree.el @@ -1,6 +1,6 @@ ;;; avl-tree.el --- balanced binary trees, AVL-trees -;; Copyright (C) 1995, 2007 Free Software Foundation, Inc. +;; Copyright (C) 1995, 2007, 2008 Free Software Foundation, Inc. ;; Author: Per Cederqvist ;; Inge Wallin diff --git a/lisp/emacs-lisp/check-declare.el b/lisp/emacs-lisp/check-declare.el index fe7f774c7e9..9f81cebaca8 100644 --- a/lisp/emacs-lisp/check-declare.el +++ b/lisp/emacs-lisp/check-declare.el @@ -1,6 +1,6 @@ ;;; check-declare.el --- Check declare-function statements -;; Copyright (C) 2007 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. ;; Author: Glenn Morris ;; Keywords: lisp, tools, maint diff --git a/lisp/gnus/ecomplete.el b/lisp/gnus/ecomplete.el index 285aca4270a..e0b759c33eb 100644 --- a/lisp/gnus/ecomplete.el +++ b/lisp/gnus/ecomplete.el @@ -1,6 +1,6 @@ ;;; ecomplete.el --- electric completion of addresses and the like -;; Copyright (C) 2006, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2006, 2007, 2008 Free Software Foundation, Inc. ;; Author: Lars Magne Ingebrigtsen ;; Keywords: mail diff --git a/lisp/gnus/gnus-bookmark.el b/lisp/gnus/gnus-bookmark.el index 41f9dd0baca..ddfc559e12e 100644 --- a/lisp/gnus/gnus-bookmark.el +++ b/lisp/gnus/gnus-bookmark.el @@ -1,6 +1,6 @@ ;;; gnus-bookmark.el --- Bookmarks in Gnus -;; Copyright (C) 2006, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2006, 2007, 2008 Free Software Foundation, Inc. ;; Author: Bastien Guerry ;; Keywords: news diff --git a/lisp/gnus/spam-wash.el b/lisp/gnus/spam-wash.el index be9a822dd2f..70192e06c1a 100644 --- a/lisp/gnus/spam-wash.el +++ b/lisp/gnus/spam-wash.el @@ -1,6 +1,6 @@ ;;; spam-wash.el --- wash spam before analysis -;; Copyright (C) 2004, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2004, 2007, 2008 Free Software Foundation, Inc. ;; Author: Andrew Cohen ;; Keywords: mail diff --git a/lisp/isearch-multi.el b/lisp/isearch-multi.el index 9161ef82c7e..1cac7bb9b9e 100644 --- a/lisp/isearch-multi.el +++ b/lisp/isearch-multi.el @@ -1,6 +1,6 @@ ;;; isearch-multi.el --- isearch extensions for multi-buffer search -;; Copyright (C) 2007 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. ;; Author: Juri Linkov ;; Keywords: matching diff --git a/lisp/mail/hashcash.el b/lisp/mail/hashcash.el index 36cd17fe6fc..5b292961b98 100644 --- a/lisp/mail/hashcash.el +++ b/lisp/mail/hashcash.el @@ -1,6 +1,6 @@ ;;; hashcash.el --- Add hashcash payments to email -;; Copyright (C) 2003, 2004, 2005, 2007 Free Software Foundation +;; Copyright (C) 2003, 2004, 2005, 2007, 2008 Free Software Foundation ;; Written by: Paul Foley (1997-2002) ;; Maintainer: Paul Foley diff --git a/lisp/mb-depth.el b/lisp/mb-depth.el index c1fd0780730..d85380ea64c 100644 --- a/lisp/mb-depth.el +++ b/lisp/mb-depth.el @@ -1,6 +1,6 @@ ;;; mb-depth.el --- Indicate minibuffer-depth in prompt ;; -;; Copyright (C) 2006, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2006, 2007, 2008 Free Software Foundation, Inc. ;; ;; Author: Miles Bader ;; Keywords: convenience diff --git a/lisp/md4.el b/lisp/md4.el index 7ccb22a20fe..13435097b71 100644 --- a/lisp/md4.el +++ b/lisp/md4.el @@ -1,6 +1,6 @@ ;;; md4.el --- MD4 Message Digest Algorithm. -;; Copyright (C) 2001, 2004, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2001, 2004, 2007, 2008 Free Software Foundation, Inc. ;; Author: Taro Kawagishi ;; Keywords: MD4 diff --git a/lisp/net/hmac-def.el b/lisp/net/hmac-def.el index bfff7282adf..6b7cb7ddecc 100644 --- a/lisp/net/hmac-def.el +++ b/lisp/net/hmac-def.el @@ -1,6 +1,6 @@ ;;; hmac-def.el --- A macro for defining HMAC functions. -;; Copyright (C) 1999, 2001, 2007 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2001, 2007, 2008 Free Software Foundation, Inc. ;; Author: Shuhei KOBAYASHI ;; Keywords: HMAC, RFC 2104 diff --git a/lisp/net/hmac-md5.el b/lisp/net/hmac-md5.el index 186708446f0..50a2d2742b7 100644 --- a/lisp/net/hmac-md5.el +++ b/lisp/net/hmac-md5.el @@ -1,6 +1,6 @@ ;;; hmac-md5.el --- Compute HMAC-MD5. -;; Copyright (C) 1999, 2001, 2007 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2001, 2007, 2008 Free Software Foundation, Inc. ;; Author: Shuhei KOBAYASHI ;; Keywords: HMAC, RFC 2104, HMAC-MD5, MD5, KEYED-MD5, CRAM-MD5 diff --git a/lisp/net/ntlm.el b/lisp/net/ntlm.el index 126f6688f0d..2418338228b 100644 --- a/lisp/net/ntlm.el +++ b/lisp/net/ntlm.el @@ -1,6 +1,6 @@ ;;; ntlm.el --- NTLM (NT LanManager) authentication support -;; Copyright (C) 2001, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2001, 2007, 2008 Free Software Foundation, Inc. ;; Author: Taro Kawagishi ;; Keywords: NTLM, SASL diff --git a/lisp/net/sasl-cram.el b/lisp/net/sasl-cram.el index 32f1e69f81f..911c8fe1805 100644 --- a/lisp/net/sasl-cram.el +++ b/lisp/net/sasl-cram.el @@ -1,6 +1,6 @@ ;;; sasl-cram.el --- CRAM-MD5 module for the SASL client framework -;; Copyright (C) 2000, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2000, 2007, 2008 Free Software Foundation, Inc. ;; Author: Daiki Ueno ;; Kenichi OKADA diff --git a/lisp/net/sasl-digest.el b/lisp/net/sasl-digest.el index 6c544518e7f..85417dff31e 100644 --- a/lisp/net/sasl-digest.el +++ b/lisp/net/sasl-digest.el @@ -1,6 +1,6 @@ ;;; sasl-digest.el --- DIGEST-MD5 module for the SASL client framework -;; Copyright (C) 2000, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2000, 2007, 2008 Free Software Foundation, Inc. ;; Author: Daiki Ueno ;; Kenichi OKADA diff --git a/lisp/net/sasl-ntlm.el b/lisp/net/sasl-ntlm.el index cd8304db70a..699fd125270 100644 --- a/lisp/net/sasl-ntlm.el +++ b/lisp/net/sasl-ntlm.el @@ -1,6 +1,6 @@ ;;; sasl-ntlm.el --- NTLM (NT Lan Manager) module for the SASL client framework -;; Copyright (C) 2000, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2000, 2007, 2008 Free Software Foundation, Inc. ;; Author: Taro Kawagishi ;; Keywords: SASL, NTLM diff --git a/lisp/net/sasl.el b/lisp/net/sasl.el index 9118d288da4..000bca51040 100644 --- a/lisp/net/sasl.el +++ b/lisp/net/sasl.el @@ -1,6 +1,6 @@ ;;; sasl.el --- SASL client framework -;; Copyright (C) 2000, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2000, 2007, 2008 Free Software Foundation, Inc. ;; Author: Daiki Ueno ;; Keywords: SASL diff --git a/lisp/net/tramp-cache.el b/lisp/net/tramp-cache.el index b28c20263f4..68c29a50982 100644 --- a/lisp/net/tramp-cache.el +++ b/lisp/net/tramp-cache.el @@ -1,6 +1,6 @@ ;;; tramp-cache.el --- file information caching for Tramp -;; Copyright (C) 2000, 2005, 2006, 2007 by Free Software Foundation, Inc. +;; Copyright (C) 2000, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. ;; Author: Daniel Pittman ;; Michael Albinus diff --git a/lisp/net/tramp-cmds.el b/lisp/net/tramp-cmds.el index 7cf2bf3d923..d76e27e443c 100644 --- a/lisp/net/tramp-cmds.el +++ b/lisp/net/tramp-cmds.el @@ -1,6 +1,6 @@ ;;; tramp-cmds.el --- Interactive commands for Tramp -;; Copyright (C) 2007 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. ;; Author: Michael Albinus ;; Keywords: comm, processes diff --git a/lisp/net/tramp-compat.el b/lisp/net/tramp-compat.el index b63b8c1e2fb..fcd8ba112b5 100644 --- a/lisp/net/tramp-compat.el +++ b/lisp/net/tramp-compat.el @@ -1,6 +1,6 @@ ;;; tramp-compat.el --- Tramp compatibility functions -;; Copyright (C) 2007 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. ;; Author: Michael Albinus ;; Keywords: comm, processes diff --git a/lisp/net/tramp-fish.el b/lisp/net/tramp-fish.el index 95091c276bc..f6f455b1823 100644 --- a/lisp/net/tramp-fish.el +++ b/lisp/net/tramp-fish.el @@ -1,6 +1,6 @@ ;;; tramp-fish.el --- Tramp access functions for FISH protocol -;; Copyright (C) 2006, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2006, 2007, 2008 Free Software Foundation, Inc. ;; Author: Michael Albinus ;; Keywords: comm, processes diff --git a/lisp/net/tramp-gw.el b/lisp/net/tramp-gw.el index fa2e9ba68b0..498112c66b1 100644 --- a/lisp/net/tramp-gw.el +++ b/lisp/net/tramp-gw.el @@ -1,6 +1,6 @@ ;;; tramp-gw.el --- Tramp utility functions for HTTP tunnels and SOCKS gateways -;; Copyright (C) 2007 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. ;; Author: Michael Albinus ;; Keywords: comm, processes diff --git a/lisp/nxml/nxml-enc.el b/lisp/nxml/nxml-enc.el index 115db17ad70..2210f76ccf5 100644 --- a/lisp/nxml/nxml-enc.el +++ b/lisp/nxml/nxml-enc.el @@ -1,6 +1,6 @@ ;;; nxml-enc.el --- XML encoding auto-detection -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/nxml-glyph.el b/lisp/nxml/nxml-glyph.el index 47d7086f246..8e608a32fdc 100644 --- a/lisp/nxml/nxml-glyph.el +++ b/lisp/nxml/nxml-glyph.el @@ -1,6 +1,6 @@ ;;; nxml-glyph.el --- glyph-handling for nxml-mode -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/nxml-maint.el b/lisp/nxml/nxml-maint.el index 7df2bc99f35..d9ba6fff90a 100644 --- a/lisp/nxml/nxml-maint.el +++ b/lisp/nxml/nxml-maint.el @@ -1,6 +1,6 @@ ;;; nxml-maint.el --- commands for maintainers of nxml-*.el -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/nxml-mode.el b/lisp/nxml/nxml-mode.el index 973197242f3..824d52a0102 100644 --- a/lisp/nxml/nxml-mode.el +++ b/lisp/nxml/nxml-mode.el @@ -1,6 +1,6 @@ ;;; nxml-mode.el --- a new XML mode -;; Copyright (C) 2003, 2004, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2004, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/nxml-ns.el b/lisp/nxml/nxml-ns.el index 0d1b1543b45..f9f5656211d 100644 --- a/lisp/nxml/nxml-ns.el +++ b/lisp/nxml/nxml-ns.el @@ -1,6 +1,6 @@ ;;; nxml-ns.el --- XML namespace processing -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/nxml-outln.el b/lisp/nxml/nxml-outln.el index 96d8cebf5dc..3363daae15b 100644 --- a/lisp/nxml/nxml-outln.el +++ b/lisp/nxml/nxml-outln.el @@ -1,6 +1,6 @@ ;;; nxml-outln.el --- outline support for nXML mode -;; Copyright (C) 2004, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2004, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/nxml-parse.el b/lisp/nxml/nxml-parse.el index 267c18cf887..bad7710a3d5 100644 --- a/lisp/nxml/nxml-parse.el +++ b/lisp/nxml/nxml-parse.el @@ -1,6 +1,6 @@ ;;; nxml-parse.el --- XML parser, sharing infrastructure with nxml-mode -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/nxml-rap.el b/lisp/nxml/nxml-rap.el index 907812be4cb..095fe11ff44 100644 --- a/lisp/nxml/nxml-rap.el +++ b/lisp/nxml/nxml-rap.el @@ -1,6 +1,6 @@ ;;; nxml-rap.el --- low-level support for random access parsing for nXML mode -;; Copyright (C) 2003, 2004, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2004, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/nxml-uchnm.el b/lisp/nxml/nxml-uchnm.el index 9514a7de476..bfa671eb894 100644 --- a/lisp/nxml/nxml-uchnm.el +++ b/lisp/nxml/nxml-uchnm.el @@ -1,6 +1,6 @@ ;;; nxml-uchnm.el --- support for Unicode standard cha names in nxml-mode -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/nxml-util.el b/lisp/nxml/nxml-util.el index 73b8354ddf6..7ea52f34fde 100644 --- a/lisp/nxml/nxml-util.el +++ b/lisp/nxml/nxml-util.el @@ -1,6 +1,6 @@ ;;; nxml-util.el --- utility functions for nxml-*.el -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/rng-cmpct.el b/lisp/nxml/rng-cmpct.el index a83af6ad077..a1915b1d7fe 100644 --- a/lisp/nxml/rng-cmpct.el +++ b/lisp/nxml/rng-cmpct.el @@ -1,6 +1,6 @@ ;;; rng-cmpct.el --- parsing of RELAX NG Compact Syntax schemas -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/rng-dt.el b/lisp/nxml/rng-dt.el index 2ed8e19c7d9..700c53407d4 100644 --- a/lisp/nxml/rng-dt.el +++ b/lisp/nxml/rng-dt.el @@ -1,6 +1,6 @@ ;;; rng-dt.el --- datatype library interface for RELAX NG -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/rng-loc.el b/lisp/nxml/rng-loc.el index 5646a262068..bae99ff8be6 100644 --- a/lisp/nxml/rng-loc.el +++ b/lisp/nxml/rng-loc.el @@ -1,6 +1,6 @@ ;;; rng-loc.el --- locate the schema to use for validation -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/rng-maint.el b/lisp/nxml/rng-maint.el index d535c45691a..e273a536156 100644 --- a/lisp/nxml/rng-maint.el +++ b/lisp/nxml/rng-maint.el @@ -1,6 +1,6 @@ ;;; rng-maint.el --- commands for RELAX NG maintainers -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/rng-match.el b/lisp/nxml/rng-match.el index eb79d999634..1f7501d9f2a 100644 --- a/lisp/nxml/rng-match.el +++ b/lisp/nxml/rng-match.el @@ -1,6 +1,6 @@ ;;; rng-match.el --- matching of RELAX NG patterns against XML events -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/rng-nxml.el b/lisp/nxml/rng-nxml.el index 5b3f2a7baf8..cb040c96311 100644 --- a/lisp/nxml/rng-nxml.el +++ b/lisp/nxml/rng-nxml.el @@ -1,6 +1,6 @@ ;;; rng-nxml.el --- make nxml-mode take advantage of rng-validate-mode -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/rng-parse.el b/lisp/nxml/rng-parse.el index e9d10e03f21..bf8df6314db 100644 --- a/lisp/nxml/rng-parse.el +++ b/lisp/nxml/rng-parse.el @@ -1,6 +1,6 @@ ;;; rng-parse.el --- parse an XML file and validate it against a schema -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/rng-pttrn.el b/lisp/nxml/rng-pttrn.el index 2ed87943160..bbf28b2b516 100644 --- a/lisp/nxml/rng-pttrn.el +++ b/lisp/nxml/rng-pttrn.el @@ -1,6 +1,6 @@ ;;; rng-pttrn.el --- RELAX NG patterns -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/rng-uri.el b/lisp/nxml/rng-uri.el index f18012abcfe..8f454213c12 100644 --- a/lisp/nxml/rng-uri.el +++ b/lisp/nxml/rng-uri.el @@ -1,6 +1,6 @@ ;;; rng-uri.el --- URI parsing and manipulation -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/rng-util.el b/lisp/nxml/rng-util.el index 7ae75f8a607..545ad425fdf 100644 --- a/lisp/nxml/rng-util.el +++ b/lisp/nxml/rng-util.el @@ -1,6 +1,6 @@ ;;; rng-util.el --- utility functions for RELAX NG library -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/rng-valid.el b/lisp/nxml/rng-valid.el index 9b6500e002a..3df0e0e30d2 100644 --- a/lisp/nxml/rng-valid.el +++ b/lisp/nxml/rng-valid.el @@ -1,6 +1,6 @@ ;;; rng-valid.el --- real-time validation of XML using RELAX NG -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/rng-xsd.el b/lisp/nxml/rng-xsd.el index 782627c4205..bc9e8a9538e 100644 --- a/lisp/nxml/rng-xsd.el +++ b/lisp/nxml/rng-xsd.el @@ -1,6 +1,6 @@ ;;; rng-xsd.el --- W3C XML Schema datatypes library for RELAX NG -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, RelaxNG diff --git a/lisp/nxml/xmltok.el b/lisp/nxml/xmltok.el index add55bf9840..2fa741c8832 100644 --- a/lisp/nxml/xmltok.el +++ b/lisp/nxml/xmltok.el @@ -1,6 +1,6 @@ ;;; xmltok.el --- XML tokenization -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML diff --git a/lisp/nxml/xsd-regexp.el b/lisp/nxml/xsd-regexp.el index a698ce71e60..185be58388d 100644 --- a/lisp/nxml/xsd-regexp.el +++ b/lisp/nxml/xsd-regexp.el @@ -1,6 +1,6 @@ ;;; xsd-regexp.el --- translate W3C XML Schema regexps to Emacs regexps -;; Copyright (C) 2003, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2007, 2008 Free Software Foundation, Inc. ;; Author: James Clark ;; Keywords: XML, regexp diff --git a/lisp/password-cache.el b/lisp/password-cache.el index eeaa31b9a31..e937c45a8b6 100644 --- a/lisp/password-cache.el +++ b/lisp/password-cache.el @@ -1,6 +1,6 @@ ;;; password-cache.el --- Read passwords, possibly using a password cache. -;; Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007 +;; Copyright (C) 1999, 2000, 2003, 2004, 2005, 2006, 2007, 2008 ;; Free Software Foundation, Inc. ;; Author: Simon Josefsson diff --git a/lisp/play/bubbles.el b/lisp/play/bubbles.el index 5f8709d17b7..b4997ce4d57 100644 --- a/lisp/play/bubbles.el +++ b/lisp/play/bubbles.el @@ -1,6 +1,6 @@ ;;; bubbles.el --- Puzzle game for Emacs. -;; Copyright (C) 2007 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. ;; Author: Ulf Jasper ;; URL: http://ulf.epplejasper.de/ diff --git a/lisp/ps-print.el b/lisp/ps-print.el index a6a2f4e4302..d7fa07136b4 100644 --- a/lisp/ps-print.el +++ b/lisp/ps-print.el @@ -7167,7 +7167,7 @@ If FACE is not a valid face name, use default face." ;;;### (autoloads (ps-mule-begin-page ps-mule-begin-job ps-mule-encode-header-string ;;;;;; ps-mule-initialize ps-mule-plot-composition ps-mule-plot-string ;;;;;; ps-mule-set-ascii-font ps-mule-prepare-ascii-font ps-multibyte-buffer) -;;;;;; "ps-mule" "ps-mule.el" "586d0a4deeb89be9b80cc01def34481c") +;;;;;; "ps-mule" "ps-mule.el" "e4095a5bcfad44435e57bc157c6eed49") ;;; Generated autoloads from ps-mule.el (defvar ps-multibyte-buffer nil "\ diff --git a/lisp/term/w32console.el b/lisp/term/w32console.el index f45d7e0ad7a..c5f34a668b0 100644 --- a/lisp/term/w32console.el +++ b/lisp/term/w32console.el @@ -1,6 +1,6 @@ ;;; w32console.el -- Setup w32 console keys and colors. -;; Copyright (C) 2007 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. ;; Author: FSF ;; Keywords: terminals diff --git a/lisp/textmodes/org-export-latex.el b/lisp/textmodes/org-export-latex.el index eef1c10e5b6..d320a166f2b 100644 --- a/lisp/textmodes/org-export-latex.el +++ b/lisp/textmodes/org-export-latex.el @@ -1,6 +1,6 @@ ;;; org-export-latex.el --- LaTeX exporter for org-mode ;; -;; Copyright (C) 2007 Free Software Foundation, Inc. +;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. ;; ;; Emacs Lisp Archive Entry ;; Filename: org-export-latex.el diff --git a/lisp/textmodes/org-publish.el b/lisp/textmodes/org-publish.el index 807a844c425..66e0dd5d6fb 100644 --- a/lisp/textmodes/org-publish.el +++ b/lisp/textmodes/org-publish.el @@ -1,6 +1,6 @@ ;;; org-publish.el --- publish related org-mode files as a website -;; Copyright (C) 2006, 2007 Free Software Foundation, Inc. +;; Copyright (C) 2006, 2007, 2008 Free Software Foundation, Inc. ;; Author: David O'Toole ;; Keywords: hypermedia, outlines diff --git a/lisp/textmodes/remember.el b/lisp/textmodes/remember.el index 0790bee55ae..58027f2b478 100644 --- a/lisp/textmodes/remember.el +++ b/lisp/textmodes/remember.el @@ -1,7 +1,7 @@ ;;; remember --- a mode for quickly jotting down things to remember -;; Copyright (C) 1999, 2000, 2001, 2003, 2004, 2005, 2006, -;; 2007 Free Software Foundation, Inc. +;; Copyright (C) 1999, 2000, 2001, 2003, 2004, 2005, 2006, 2007, +;; 2008 Free Software Foundation, Inc. ;; Author: John Wiegley ;; Created: 29 Mar 1999 diff --git a/src/ChangeLog.10 b/src/ChangeLog.10 index b7187263257..577f1be615d 100644 --- a/src/ChangeLog.10 +++ b/src/ChangeLog.10 @@ -27916,8 +27916,8 @@ See ChangeLog.9 for earlier changes. ;; add-log-time-zone-rule: t ;; End: - Copyright (C) 2001, 2002, 2003, 2004, 2005, - 2006, 2007 Free Software Foundation, Inc. + Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, + 2008 Free Software Foundation, Inc. This file is part of GNU Emacs. diff --git a/src/terminal.c b/src/terminal.c index 46ffb3c2dc8..ba141706b06 100644 --- a/src/terminal.c +++ b/src/terminal.c @@ -1,5 +1,5 @@ /* Functions related to terminal devices. - Copyright (C) 2005, 2006, 2007 Free Software Foundation, Inc. + Copyright (C) 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This file is part of GNU Emacs. From 355a326e54a2b1e3982a93f26ec0146fa0816774 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:36:57 +0000 Subject: [PATCH 016/439] Daniel Hackney (tiny change) (set_socket): Add trailing newline to socket error message. --- lib-src/emacsclient.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib-src/emacsclient.c b/lib-src/emacsclient.c index 9de812d1c73..ddb4ad10a2c 100644 --- a/lib-src/emacsclient.c +++ b/lib-src/emacsclient.c @@ -1266,7 +1266,7 @@ set_socket () s = set_local_socket (); if ((s != INVALID_SOCKET) || alternate_editor) return s; - message (TRUE, "%s: error accessing socket \"%s\"", + message (TRUE, "%s: error accessing socket \"%s\"\n", progname, socket_name); exit (EXIT_FAILURE); } From 78da39c6e7c532cc847367187c3c87ad92b25ef7 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:40:14 +0000 Subject: [PATCH 017/439] Add missing final newlines to message calls. --- lib-src/ChangeLog | 8 ++++++++ lib-src/emacsclient.c | 12 ++++++------ 2 files changed, 14 insertions(+), 6 deletions(-) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index 8cdce18bd87..16cca0959b3 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,11 @@ +2008-01-09 Glenn Morris + + * emacsclient.c: Add missing final newlines to message calls. + +2008-01-09 Daniel Hackney (tiny change) + + * emacsclient.c (set_socket): Add final newline to socket error message. + 2008-01-04 Glenn Morris * ebrowse.c (version) : New variable. diff --git a/lib-src/emacsclient.c b/lib-src/emacsclient.c index ddb4ad10a2c..4fcd3398bd2 100644 --- a/lib-src/emacsclient.c +++ b/lib-src/emacsclient.c @@ -882,7 +882,7 @@ initialize_sockets () if (WSAStartup (MAKEWORD (2, 0), &wsaData)) { - message (TRUE, "%s: error initializing WinSock2", progname); + message (TRUE, "%s: error initializing WinSock2\n", progname); exit (EXIT_FAILURE); } @@ -939,7 +939,7 @@ get_server_config (server, authentication) } else { - message (TRUE, "%s: invalid configuration info", progname); + message (TRUE, "%s: invalid configuration info\n", progname); exit (EXIT_FAILURE); } @@ -949,7 +949,7 @@ get_server_config (server, authentication) if (! fread (authentication, AUTH_KEY_LENGTH, 1, config)) { - message (TRUE, "%s: cannot read authentication info", progname); + message (TRUE, "%s: cannot read authentication info\n", progname); exit (EXIT_FAILURE); } @@ -1167,7 +1167,7 @@ set_local_socket () strcpy (server.sun_path, socket_name); else { - message (TRUE, "%s: socket-name %s too long", + message (TRUE, "%s: socket-name %s too long\n", progname, socket_name); fail (); } @@ -1202,7 +1202,7 @@ set_local_socket () strcpy (server.sun_path, socket_name); else { - message (TRUE, "%s: socket-name %s too long", + message (TRUE, "%s: socket-name %s too long\n", progname, socket_name); exit (EXIT_FAILURE); } @@ -1282,7 +1282,7 @@ set_socket () if ((s != INVALID_SOCKET) || alternate_editor) return s; - message (TRUE, "%s: error accessing server file \"%s\"", + message (TRUE, "%s: error accessing server file \"%s\"\n", progname, server_file); exit (EXIT_FAILURE); } From d0c4023834ca067ed7a462fcee9f46db027f8f5a Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:53:35 +0000 Subject: [PATCH 018/439] gnome icons are GPLv2 or later. http://lists.gnu.org/archive/html/emacs-devel/2007-12/msg01306.html --- etc/images/gnus/README | 2 +- etc/images/mail/README | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/etc/images/gnus/README b/etc/images/gnus/README index c0ed4f72552..c92dc392558 100644 --- a/etc/images/gnus/README +++ b/etc/images/gnus/README @@ -30,7 +30,7 @@ but distributed and used by Emacs. Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco Pesenti Gritti - License: GNU General Public License version 2 + License: GNU General Public License version 2 or later toggle-subscription.xpm (GNOME stock/document/stock_task-recurring) kill-group.pbm and kill-group.xpm are converted from close.xpm diff --git a/etc/images/mail/README b/etc/images/mail/README index c7fcecc6885..dc9a83a27fb 100644 --- a/etc/images/mail/README +++ b/etc/images/mail/README @@ -8,7 +8,7 @@ but distributed and used by Emacs. Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco Pesenti Gritti - License: GNU General Public License version 2 + License: GNU General Public License version 2 or later Emacs images and their GNOME source (GNOME icons are from stock/net/ directory unless otherwise stated): From 8cd8671965f54b3a1b536ca3998a16a485cb4c56 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:55:19 +0000 Subject: [PATCH 019/439] gnome icons are GPLv2 or later. gtk icons are LGPLv2 or later. http://lists.gnu.org/archive/html/emacs-devel/2007-12/msg01306.html Correct gtk copyright holders based on makecopyright in gtk tarball. --- etc/images/README | 35 +++++++++++++++++++---------------- 1 file changed, 19 insertions(+), 16 deletions(-) diff --git a/etc/images/README b/etc/images/README index e7d19506439..a1df3a0b4f8 100644 --- a/etc/images/README +++ b/etc/images/README @@ -25,28 +25,31 @@ Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 License: GNU General Public License version 3 or later (see COPYING) -The following icons are from GTK+ 2.x and GNOME 2.x. They are not -part of Emacs, but distributed and used by Emacs. +The following icons are from GTK+ 2.x. They are not part of Emacs, but +distributed and used by Emacs. + + Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + License: GNU Library General Public License version 2 or later. + + close.xpm copy.xpm cut.xpm help.xpm home.xpm index.xpm info.pbm + info.xpm jump-to.xpm left-arrow.xpm new.xpm open.xpm paste.xpm + preferences.xpm print.xpm refresh.xpm right-arrow.xpm save.xpm + saveas.xpm search.xpm sort-ascending.xpm sort-descending.xpm + spell.xpm undo.xpm up-arrow.xpm + + back-arrow.xpm and fwd-arrow.xpm are slightly modified undo and redo. + diropen.xpm is file-manager.png from Gnome hicolor theme. + + +The following icons are from GNOME 2.x. They are not part of Emacs, +but distributed and used by Emacs. Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 Tuomas Kuosmanen, Rodney Dawes, Jakub Steiner, Alexander Larsson, Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco Pesenti Gritti - License: GNU General Public License version 2 - -* From GTK+ 2.x: - - close.xpm copy.xpm cut.xpm help.xpm home.xpm index.xpm info.pbm - info.xpm jump-to.xpm left-arrow.xpm new.xpm open.xpm paste.xpm - preferences.xpm print.xpm refresh.xpm right-arrow.xpm save.xpm - saveas.xpm search.xpm sort-ascending.xpm sort-descending.xpm - spell.xpm undo.xpm up-arrow.xpm - - back-arrow.xpm and fwd-arrow.xpm are slightly modified undo and redo. - diropen.xpm is file-manager.png from Gnome hicolor theme. - -* From GNOME 2.x: + License: GNU General Public License version 2 or later. Emacs images and their source in the GNOME icons stock/ directory: From 14066941b76fae661818099de9d7b335fbe205ef Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:57:51 +0000 Subject: [PATCH 020/439] gnome icons are GPLv2 or later. gtk icons are LGPLv2 or later. http://lists.gnu.org/archive/html/emacs-devel/2007-12/msg01306.html Correct gtk copyright holders based on makecopyright in gtk tarball. --- etc/images/README | 35 +++++++++++++++++++---------------- 1 file changed, 19 insertions(+), 16 deletions(-) diff --git a/etc/images/README b/etc/images/README index 34b882bcd07..ccc690d7832 100644 --- a/etc/images/README +++ b/etc/images/README @@ -34,28 +34,31 @@ Files: splash.pbm, splash.xpm, splash8.xpm, gnus.pbm License: GNU General Public License version 3 or later (see COPYING) -* The following icons are from GTK+ 2.x and GNOME 2.x. They are not -part of Emacs, but distributed and used by Emacs. +The following icons are from GTK+ 2.x. They are not part of Emacs, but +distributed and used by Emacs. + + Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald + License: GNU Library General Public License version 2 or later. + + close.xpm copy.xpm cut.xpm help.xpm home.xpm index.xpm info.pbm + info.xpm jump-to.xpm left-arrow.xpm new.xpm open.xpm paste.xpm + preferences.xpm print.xpm refresh.xpm right-arrow.xpm save.xpm + saveas.xpm search.xpm sort-ascending.xpm sort-descending.xpm + spell.xpm undo.xpm up-arrow.xpm + + back-arrow.xpm and fwd-arrow.xpm are slightly modified undo and redo. + diropen.xpm is file-manager.png from Gnome hicolor theme. + + +The following icons are from GNOME 2.x. They are not part of Emacs, +but distributed and used by Emacs. Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 Tuomas Kuosmanen, Rodney Dawes, Jakub Steiner, Alexander Larsson, Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco Pesenti Gritti - License: GNU General Public License version 2 - -* From GTK+ 2.x: - - close.xpm copy.xpm cut.xpm help.xpm home.xpm index.xpm info.pbm - info.xpm jump-to.xpm left-arrow.xpm new.xpm open.xpm paste.xpm - preferences.xpm print.xpm refresh.xpm right-arrow.xpm save.xpm - saveas.xpm search.xpm sort-ascending.xpm sort-descending.xpm - spell.xpm undo.xpm up-arrow.xpm - - back-arrow.xpm and fwd-arrow.xpm are slightly modified undo and redo. - diropen.xpm is file-manager.png from Gnome hicolor theme. - -* From GNOME 2.x: + License: GNU General Public License version 2 or later. Emacs images and their source in the GNOME icons stock/ directory: From 85032f0f3ca0355dcf7a4f76e94fc4440c0b7558 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 9 Jan 2008 04:59:00 +0000 Subject: [PATCH 021/439] gnome icons are GPLv2 or later. http://lists.gnu.org/archive/html/emacs-devel/2007-12/msg01306.html --- etc/images/gnus/README | 2 +- etc/images/mail/README | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/etc/images/gnus/README b/etc/images/gnus/README index c0ed4f72552..c92dc392558 100644 --- a/etc/images/gnus/README +++ b/etc/images/gnus/README @@ -30,7 +30,7 @@ but distributed and used by Emacs. Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco Pesenti Gritti - License: GNU General Public License version 2 + License: GNU General Public License version 2 or later toggle-subscription.xpm (GNOME stock/document/stock_task-recurring) kill-group.pbm and kill-group.xpm are converted from close.xpm diff --git a/etc/images/mail/README b/etc/images/mail/README index c7fcecc6885..dc9a83a27fb 100644 --- a/etc/images/mail/README +++ b/etc/images/mail/README @@ -8,7 +8,7 @@ but distributed and used by Emacs. Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco Pesenti Gritti - License: GNU General Public License version 2 + License: GNU General Public License version 2 or later Emacs images and their GNOME source (GNOME icons are from stock/net/ directory unless otherwise stated): From 15b18fea8169cce339f2f792ce1eee44d2de03e0 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 9 Jan 2008 05:15:07 +0000 Subject: [PATCH 022/439] * vc-hg.el (vc-hg-dir-status): Don't pass -A to "hg status". --- lisp/ChangeLog | 4 ++++ lisp/vc-hg.el | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b24807e36b4..eac75b01c7f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-09 Tom Tromey + + * vc-hg.el (vc-hg-dir-status): Don't pass -A to "hg status". + 2008-01-09 Glenn Morris * ffap.el (ffap-string-at-point-mode-alist): Add `\' to file diff --git a/lisp/vc-hg.el b/lisp/vc-hg.el index 597c49aaa3f..fe441d984f7 100644 --- a/lisp/vc-hg.el +++ b/lisp/vc-hg.el @@ -485,7 +485,7 @@ REV is the revision to check out into WORKFILE." (defun vc-hg-dir-status (dir) "Return a list of conses (file . state) for DIR." (with-temp-buffer - (vc-hg-command (current-buffer) nil dir "status" "-A") + (vc-hg-command (current-buffer) nil dir "status") (goto-char (point-min)) (let ((status-char nil) (file nil) From ca8dfeda7c6edcfeacb95a2e2d3b5dcb3841886c Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 9 Jan 2008 05:19:04 +0000 Subject: [PATCH 023/439] * vc.el (vc-status-headers): Rename from vc-status-insert-headers. Just return header. (vc-status-move-to-goal-column): New function. (vc-status-mode-map): Define more keys. (vc-status-mode): Use vc-status-refresh. Now 'special. (vc-status-refresh): New function. (vc-status-next-line): Likewise. (vc-status-previous-line): Likewise. (vc-status-mark-file): Use vc-status-next-line. (vc-status-unmark-file): Use vc-status-previous-line. (vc-status-unmark-file-up): New function. (vc-status-register): Likewise. (vc-status-find-file): Likewise. (vc-status-find-file-other-window): Likewise. (vc-status-current-file): Likewise. (vc-ensure-vc-buffer): Understand vc-status mode. --- lisp/ChangeLog | 17 +++++++ lisp/vc.el | 128 ++++++++++++++++++++++++++++++++++++++++++------- 2 files changed, 127 insertions(+), 18 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index eac75b01c7f..686852c7dd0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,22 @@ 2008-01-09 Tom Tromey + * vc.el (vc-status-headers): Rename from + vc-status-insert-headers. Just return header. + (vc-status-move-to-goal-column): New function. + (vc-status-mode-map): Define more keys. + (vc-status-mode): Use vc-status-refresh. Now 'special. + (vc-status-refresh): New function. + (vc-status-next-line): Likewise. + (vc-status-previous-line): Likewise. + (vc-status-mark-file): Use vc-status-next-line. + (vc-status-unmark-file): Use vc-status-previous-line. + (vc-status-unmark-file-up): New function. + (vc-status-register): Likewise. + (vc-status-find-file): Likewise. + (vc-status-find-file-other-window): Likewise. + (vc-status-current-file): Likewise. + (vc-ensure-vc-buffer): Understand vc-status mode. + * vc-hg.el (vc-hg-dir-status): Don't pass -A to "hg status". 2008-01-09 Glenn Morris diff --git a/lisp/vc.el b/lisp/vc.el index 61a2c67d9d4..6e170ab1464 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -1307,8 +1307,12 @@ Otherwise, throw an error." (defun vc-ensure-vc-buffer () "Make sure that the current buffer visits a version-controlled file." - (if vc-dired-mode - (set-buffer (find-file-noselect (dired-get-filename))) + (cond + (vc-dired-mode + (set-buffer (find-file-noselect (dired-get-filename)))) + ((eq major-mode 'vc-status-mode) + (set-buffer (find-file-noselect (vc-status-current-file)))) + (t (while (and vc-parent-buffer (buffer-live-p vc-parent-buffer) ;; Avoid infinite looping when vc-parent-buffer and @@ -1318,7 +1322,7 @@ Otherwise, throw an error." (if (not buffer-file-name) (error "Buffer %s is not associated with a file" (buffer-name)) (if (not (vc-backend buffer-file-name)) - (error "File %s is not under version control" buffer-file-name))))) + (error "File %s is not under version control" buffer-file-name)))))) ;;; Support for the C-x v v command. This is where all the single-file-oriented ;;; code from before the fileset rewrite lives. @@ -2512,19 +2516,26 @@ With prefix arg READ-SWITCHES, specify a value to override (defvar vc-status nil) -(defun vc-status-insert-headers (backend dir) - (insert (format "VC backend :%s\n" backend)) - (insert "Repository : The repository goes here\n") - (insert (format "Working dir: %s\n\n\n" dir))) +(defun vc-status-headers (backend dir) + (concat + (format "VC backend : %s\n" backend) + "Repository : The repository goes here\n" + (format "Working dir: %s\n" dir))) (defun vc-status-printer (fileentry) "Pretty print FILEENTRY." (insert + ;; If you change this, change vc-status-move-to-goal-column. (format "%c %-20s %s" (if (vc-status-fileinfo->marked fileentry) ?* ? ) (vc-status-fileinfo->state fileentry) (vc-status-fileinfo->name fileentry)))) +(defun vc-status-move-to-goal-column () + (beginning-of-line) + ;; Must be in sync with vc-status-printer. + (forward-char 25)) + (defun vc-status (dir) "Show the VC status for DIR." (interactive "DVC status for directory: ") @@ -2534,9 +2545,30 @@ With prefix arg READ-SWITCHES, specify a value to override (vc-status-mode)) (defvar vc-status-mode-map - (let ((map (make-sparse-keymap))) + (let ((map (make-keymap))) + (suppress-keymap map) + ;; Marking. (define-key map "m" 'vc-status-mark-file) (define-key map "u" 'vc-status-unmark-file) + (define-key map "\C-?" 'vc-status-unmark-file-up) + ;; Movement. + (define-key map "n" 'vc-status-next-line) + (define-key map " " 'vc-status-next-line) + (define-key map "\t" 'vc-status-next-line) + (define-key map "p" 'vc-status-previous-line) + (define-key map [backtab] 'vc-status-previous-line) + ;; VC commands. + (define-key map "=" 'vc-diff) + (define-key map "a" 'vc-status-register) + ;; Can't be "g" (as in vc map), so "A" for "Annotate". + (define-key map "A" 'vc-annotate) + ;; vc-print-log uses the current buffer, not a file. + ;; (define-key map "l" 'vc-status-print-log) + ;; The remainder. + (define-key map "f" 'vc-status-find-file) + (define-key map "o" 'vc-status-find-file-other-window) + (define-key map "q" 'bury-buffer) + (define-key map "g" 'vc-status-refresh) map) "Keymap for VC status") @@ -2552,30 +2584,90 @@ With prefix arg READ-SWITCHES, specify a value to override entries) (erase-buffer) (set (make-local-variable 'vc-status) - (ewoc-create #'vc-status-printer)) - (vc-status-insert-headers backend default-directory) - (setq entries (vc-call-backend backend 'dir-status default-directory)) - (dolist (entry entries) - (ewoc-enter-last - vc-status (vc-status-create-fileinfo (cdr entry) (car entry)))))) + (ewoc-create #'vc-status-printer + (vc-status-headers backend default-directory))) + (vc-status-refresh))) + +(put 'vc-status-mode 'mode-class 'special) + +(defun vc-status-refresh () + "Refresh the contents of the VC status buffer." + (interactive) + ;; This is not very efficient; ewoc could use a new function here. + (ewoc-filter vc-status (lambda (node) nil)) + (let ((backend (vc-responsible-backend default-directory))) + (dolist (entry (vc-call-backend backend 'dir-status default-directory)) + (ewoc-enter-last vc-status + (vc-status-create-fileinfo (cdr entry) (car entry))))) + (ewoc-goto-node vc-status (ewoc-nth vc-status 0))) + +(defun vc-status-next-line (arg) + "Go to the next line. +If a prefix argument is given, move by that many lines." + (interactive "p") + (ewoc-goto-next vc-status arg) + (vc-status-move-to-goal-column)) + +(defun vc-status-previous-line (arg) + "Go to the previous line. +If a prefix argument is given, move by that many lines." + (interactive "p") + (ewoc-goto-prev vc-status arg) + (vc-status-move-to-goal-column)) (defun vc-status-mark-file () - "Mark the current file." + "Mark the current file and move to the next line." (interactive) (let* ((crt (ewoc-locate vc-status)) (file (ewoc-data crt))) (setf (vc-status-fileinfo->marked file) t) (ewoc-invalidate vc-status crt) - (ewoc-goto-next vc-status 1))) + (vc-status-next-line 1))) (defun vc-status-unmark-file () - "Mark the current file." + "Unmark the current file and move to the next line." (interactive) (let* ((crt (ewoc-locate vc-status)) (file (ewoc-data crt))) (setf (vc-status-fileinfo->marked file) nil) (ewoc-invalidate vc-status crt) - (ewoc-goto-next vc-status 1))) + (vc-status-next-line 1))) + +(defun vc-status-unmark-file-up () + "Move to the previous line and unmark the file." + (interactive) + ;; If we're on the first line, we won't move up, but we will still + ;; remove the mark. This seems a bit odd but it is what buffer-menu + ;; does. + (let* ((prev (ewoc-goto-prev vc-status 1)) + (file (ewoc-data prev))) + (setf (vc-status-fileinfo->marked file) nil) + (ewoc-invalidate vc-status prev) + (vc-status-move-to-goal-column))) + +(defun vc-status-register () + "Register the marked files, or the current file if no marks." + (interactive) + (let ((files (or (vc-status-marked-files) + (list (vc-status-current-file))))) + (dolist (file files) + (vc-register file)))) + +(defun vc-status-find-file () + "Find the file on the current line." + (interactive) + (find-file (vc-status-current-file))) + +(defun vc-status-find-file-other-window () + "Find the file on the current line, in another window." + (interactive) + (find-file-other-window (vc-status-current-file))) + +(defun vc-status-current-file () + (let ((node (ewoc-locate vc-status))) + (unless node + (error "No file available.")) + (expand-file-name (vc-status-fileinfo->name (ewoc-data node))))) (defun vc-status-marked-files () "Return the list of marked files" From 36a04480a59ed8a3dccdab99620b4d73cb67ab66 Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Wed, 9 Jan 2008 06:05:23 +0000 Subject: [PATCH 024/439] (detect_coding_iso2022): New arg latin_extra_code_state. Allow Latin extra codes only when *latin_extra_code_state is nonzero. (detect_coding_mask): If there is a NULL byte, detect the encoding as UTF-16 or binary. If there is a Latin extra code, detect the encoding as ISO-2022 only when no other proper encoding is found. --- src/coding.c | 113 ++++++++++++++++++++++++++++++++++++++++----------- 1 file changed, 89 insertions(+), 24 deletions(-) diff --git a/src/coding.c b/src/coding.c index 0e8a75647a2..4e4147370cb 100644 --- a/src/coding.c +++ b/src/coding.c @@ -1406,12 +1406,17 @@ enum iso_code_class_type iso_code_class[256]; CODING_CATEGORY_MASK_ISO_7_ELSE CODING_CATEGORY_MASK_ISO_8_ELSE are set. If a code which should never appear in ISO2022 is found, - returns 0. */ + returns 0. + + If *latin_extra_code_state is zero and Latin extra codes are found, + set *latin_extra_code_state to 1 and return 0. If it is nonzero, + accept Latin extra codes. */ static int -detect_coding_iso2022 (src, src_end, multibytep) +detect_coding_iso2022 (src, src_end, multibytep, latin_extra_code_state) unsigned char *src, *src_end; int multibytep; + int *latin_extra_code_state; { int mask = CODING_CATEGORY_MASK_ISO; int mask_found = 0; @@ -1574,6 +1579,11 @@ detect_coding_iso2022 (src, src_end, multibytep) if (VECTORP (Vlatin_extra_code_table) && !NILP (XVECTOR (Vlatin_extra_code_table)->contents[c])) { + if (! *latin_extra_code_state) + { + *latin_extra_code_state = 1; + return 0; + } if (coding_system_table[CODING_CATEGORY_IDX_ISO_8_1]->flags & CODING_FLAG_ISO_LATIN_EXTRA) newmask |= CODING_CATEGORY_MASK_ISO_8_1; @@ -1600,6 +1610,11 @@ detect_coding_iso2022 (src, src_end, multibytep) { int newmask = 0; + if (! *latin_extra_code_state) + { + *latin_extra_code_state = 1; + return 0; + } if (coding_system_table[CODING_CATEGORY_IDX_ISO_8_1]->flags & CODING_FLAG_ISO_LATIN_EXTRA) newmask |= CODING_CATEGORY_MASK_ISO_8_1; @@ -4127,6 +4142,8 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) unsigned char *src = source, *src_end = source + src_bytes; unsigned int mask, utf16_examined_p, iso2022_examined_p; int i; + int null_byte_found; + int latin_extra_code_state = 1; /* At first, skip all ASCII characters and control characters except for three ISO2022 specific control characters. */ @@ -4135,21 +4152,32 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) ascii_skip_code[ISO_CODE_ESC] = 0; label_loop_detect_coding: - while (src < src_end && ascii_skip_code[*src]) src++; + null_byte_found = 0; + while (src < src_end && ascii_skip_code[*src]) + null_byte_found |= (! *src++); + if (! null_byte_found) + { + unsigned char *p = src + 1; + while (p < src_end) + null_byte_found |= (! *p++); + } *skip = src - source; if (src >= src_end) - /* We found nothing other than ASCII. There's nothing to do. */ + /* We found nothing other than ASCII (and NULL byte). There's + nothing to do. */ return 0; c = *src; /* The text seems to be encoded in some multilingual coding system. Now, try to find in which coding system the text is encoded. */ - if (c < 0x80) + if (! null_byte_found && c < 0x80) { /* i.e. (c == ISO_CODE_ESC || c == ISO_CODE_SI || c == ISO_CODE_SO) */ /* C is an ISO2022 specific control code of C0. */ - mask = detect_coding_iso2022 (src, src_end, multibytep); + latin_extra_code_state = 1; + mask = detect_coding_iso2022 (src, src_end, multibytep, + &latin_extra_code_state); if (mask == 0) { /* No valid ISO2022 code follows C. Try again. */ @@ -4177,21 +4205,27 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) if (multibytep && c == LEADING_CODE_8_BIT_CONTROL) c = src[1] - 0x20; - if (c < 0xA0) + if (null_byte_found) + { + try = (CODING_CATEGORY_MASK_UTF_16_BE + | CODING_CATEGORY_MASK_UTF_16_LE); + } + else if (c < 0xA0) { /* C is the first byte of SJIS character code, or a leading-code of Emacs' internal format (emacs-mule), or the first byte of UTF-16. */ try = (CODING_CATEGORY_MASK_SJIS - | CODING_CATEGORY_MASK_EMACS_MULE - | CODING_CATEGORY_MASK_UTF_16_BE - | CODING_CATEGORY_MASK_UTF_16_LE); + | CODING_CATEGORY_MASK_EMACS_MULE + | CODING_CATEGORY_MASK_UTF_16_BE + | CODING_CATEGORY_MASK_UTF_16_LE); /* Or, if C is a special latin extra code, or is an ISO2022 specific control code of C1 (SS2 or SS3), or is an ISO2022 control-sequence-introducer (CSI), we should also consider the possibility of ISO2022 codings. */ - if ((VECTORP (Vlatin_extra_code_table) + if ((latin_extra_code_state + && VECTORP (Vlatin_extra_code_table) && !NILP (XVECTOR (Vlatin_extra_code_table)->contents[c])) || (c == ISO_CODE_SS2 || c == ISO_CODE_SS3) || (c == ISO_CODE_CSI @@ -4201,7 +4235,7 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) && src + 1 < src_end && src[1] == ']'))))) try |= (CODING_CATEGORY_MASK_ISO_8_ELSE - | CODING_CATEGORY_MASK_ISO_8BIT); + | CODING_CATEGORY_MASK_ISO_8BIT); } else /* C is a character of ISO2022 in graphic plane right, @@ -4209,29 +4243,36 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) or the first byte of BIG5's 2-byte code, or the first byte of UTF-8/16. */ try = (CODING_CATEGORY_MASK_ISO_8_ELSE - | CODING_CATEGORY_MASK_ISO_8BIT - | CODING_CATEGORY_MASK_SJIS - | CODING_CATEGORY_MASK_BIG5 - | CODING_CATEGORY_MASK_UTF_8 - | CODING_CATEGORY_MASK_UTF_16_BE - | CODING_CATEGORY_MASK_UTF_16_LE); + | CODING_CATEGORY_MASK_ISO_8BIT + | CODING_CATEGORY_MASK_SJIS + | CODING_CATEGORY_MASK_BIG5 + | CODING_CATEGORY_MASK_UTF_8 + | CODING_CATEGORY_MASK_UTF_16_BE + | CODING_CATEGORY_MASK_UTF_16_LE); /* Or, we may have to consider the possibility of CCL. */ - if (coding_system_table[CODING_CATEGORY_IDX_CCL] + if (! null_byte_found + && coding_system_table[CODING_CATEGORY_IDX_CCL] && (coding_system_table[CODING_CATEGORY_IDX_CCL] ->spec.ccl.valid_codes)[c]) try |= CODING_CATEGORY_MASK_CCL; mask = 0; - utf16_examined_p = iso2022_examined_p = 0; if (priorities) { + /* At first try detection with Latin extra codes not-allowed. + If no proper coding system is found because of Latin extra + codes, try detection with Latin extra codes allowed. */ + latin_extra_code_state = 0; + label_retry: + utf16_examined_p = iso2022_examined_p = 0; for (i = 0; i < CODING_CATEGORY_IDX_MAX; i++) { if (!iso2022_examined_p && (priorities[i] & try & CODING_CATEGORY_MASK_ISO)) { - mask |= detect_coding_iso2022 (src, src_end, multibytep); + mask |= detect_coding_iso2022 (src, src_end, multibytep, + &latin_extra_code_state); iso2022_examined_p = 1; } else if (priorities[i] & try & CODING_CATEGORY_MASK_SJIS) @@ -4252,16 +4293,40 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) else if (priorities[i] & try & CODING_CATEGORY_MASK_CCL) mask |= detect_coding_ccl (src, src_end, multibytep); else if (priorities[i] & CODING_CATEGORY_MASK_RAW_TEXT) - mask |= CODING_CATEGORY_MASK_RAW_TEXT; + { + if (latin_extra_code_state == 1) + { + /* Detection of ISO-2022 based coding system + failed because of Latin extra codes. Before + falling back to raw-text, try again with + Latin extra codes allowed. */ + latin_extra_code_state = 2; + try = (mask | CODING_CATEGORY_MASK_ISO_8_ELSE + | CODING_CATEGORY_MASK_ISO_8BIT); + goto label_retry; + } + mask |= CODING_CATEGORY_MASK_RAW_TEXT; + } else if (priorities[i] & CODING_CATEGORY_MASK_BINARY) - mask |= CODING_CATEGORY_MASK_BINARY; + { + if (latin_extra_code_state == 1) + { + /* See the above comment. */ + latin_extra_code_state = 2; + try = (mask | CODING_CATEGORY_MASK_ISO_8_ELSE + | CODING_CATEGORY_MASK_ISO_8BIT); + goto label_retry; + } + mask |= CODING_CATEGORY_MASK_BINARY; + } if (mask & priorities[i]) return priorities[i]; } return CODING_CATEGORY_MASK_RAW_TEXT; } if (try & CODING_CATEGORY_MASK_ISO) - mask |= detect_coding_iso2022 (src, src_end, multibytep); + mask |= detect_coding_iso2022 (src, src_end, multibytep, + &latin_extra_code_state); if (try & CODING_CATEGORY_MASK_SJIS) mask |= detect_coding_sjis (src, src_end, multibytep); if (try & CODING_CATEGORY_MASK_BIG5) From 218b3b7634bd5638c6f7b3fdb26c552127288bc6 Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Wed, 9 Jan 2008 06:15:40 +0000 Subject: [PATCH 025/439] *** empty log message *** --- src/ChangeLog | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index e942fc32eeb..6433adaee13 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,13 @@ +2008-01-09 Kenichi Handa + + * coding.c (detect_coding_iso2022): New arg + latin_extra_code_state. Allow Latin extra codes only + when *latin_extra_code_state is nonzero. + (detect_coding_mask): If there is a NULL byte, detect the encoding + as UTF-16 or binary. If Latin extra codes exist, detect the + encoding as ISO-2022 only when there's no other proper encoding is + found. + 2008-01-08 YAMAMOTO Mitsuharu * frame.c (Fmake_terminal_frame): Use #ifdef MAC_OS8 instead of From 65efc5388d0c270796027bff3c4bb4b0b85dac16 Mon Sep 17 00:00:00 2001 From: Michael Kifer Date: Wed, 9 Jan 2008 06:16:07 +0000 Subject: [PATCH 026/439] 2008-01-09 Michael Kifer * ediff*.el: commented out declare-function. "make bootstrap" stops with an error and emacs does not compile with those things in. Besides, declare-function is not defined in XEmacs. * ediff-util (eqiff-quit): autoraise minibuffer. * ediff-diff (ediff-convert-fine-diffs-to-overlays): make it a defin * viper*.el: commented out declare-function -- not defined in XEmacs. * viper-ex.el (viper-info-on-file): take care of indiret buffers. * viper.el (viper-set-hooks, set-cursor-color): set viper-vi-state-cursor-color. --- lisp/ChangeLog | 16 ++++++++++++++++ lisp/ediff-diff.el | 2 +- lisp/ediff-util.el | 9 +++++++-- lisp/ediff-wind.el | 5 +++-- lisp/ediff.el | 7 ++++--- lisp/emulation/viper-cmd.el | 19 +++++++++++++------ lisp/emulation/viper-ex.el | 8 +++++--- lisp/emulation/viper-keym.el | 7 ++++--- lisp/emulation/viper-util.el | 5 +++-- lisp/emulation/viper.el | 7 +++++-- 10 files changed, 61 insertions(+), 24 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 686852c7dd0..dd955494b77 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,19 @@ +2008-01-09 Michael Kifer + + * ediff*.el: commented out declare-function. "make bootstrap" + stops with an error and emacs does not compile with those things in. + Besides, declare-function is not defined in XEmacs. + + * ediff-util (eqiff-quit): autoraise minibuffer. + + * ediff-diff (ediff-convert-fine-diffs-to-overlays): make it a defin + + * viper*.el: commented out declare-function -- not defined in XEmacs. + + * viper-ex.el (viper-info-on-file): take care of indiret buffers. + + * viper.el (viper-set-hooks, set-cursor-color): set viper-vi-state-cursor-color. + 2008-01-09 Tom Tromey * vc.el (vc-status-headers): Rename from diff --git a/lisp/ediff-diff.el b/lisp/ediff-diff.el index 685543b5369..b690bfbe4e1 100644 --- a/lisp/ediff-diff.el +++ b/lisp/ediff-diff.el @@ -948,7 +948,7 @@ delimiter regions")) ))) -(defsubst ediff-convert-fine-diffs-to-overlays (diff-list region-num) +(defun ediff-convert-fine-diffs-to-overlays (diff-list region-num) (ediff-set-fine-overlays-in-one-buffer 'A diff-list region-num) (ediff-set-fine-overlays-in-one-buffer 'B diff-list region-num) (if ediff-3way-job diff --git a/lisp/ediff-util.el b/lisp/ediff-util.el index dd844c9a542..94e0d87bf9c 100644 --- a/lisp/ediff-util.el +++ b/lisp/ediff-util.el @@ -2406,7 +2406,9 @@ If it is t, they will be preserved unconditionally. A prefix argument, temporarily reverses the meaning of this variable." (interactive "P") (ediff-barf-if-not-control-buffer) - (let ((ctl-buf (current-buffer))) + (let ((ctl-buf (current-buffer)) + (ctl-frm (selected-frame)) + (minibuffer-auto-raise t)) (if (y-or-n-p (format "Quit this Ediff session%s? " (if (ediff-buffer-live-p ediff-meta-buffer) " & show containing session group" ""))) @@ -2414,6 +2416,8 @@ temporarily reverses the meaning of this variable." (message "") (set-buffer ctl-buf) (ediff-really-quit reverse-default-keep-variants)) + (select-frame ctl-frm) + (raise-frame ctl-frm) (message "")))) @@ -2818,7 +2822,8 @@ up an appropriate window config." ;; ediff-barf-if-not-control-buffer ensures only called from ediff. -(declare-function ediff-version "ediff" ()) +;; declare-function does not exist in XEmacs +;;(declare-function ediff-version "ediff" ())) (defun ediff-status-info () "Show the names of the buffers or files being operated on by Ediff. diff --git a/lisp/ediff-wind.el b/lisp/ediff-wind.el index c5a53b47b3b..7e5eff6392e 100644 --- a/lisp/ediff-wind.el +++ b/lisp/ediff-wind.el @@ -147,9 +147,10 @@ In this case, Ediff will use those frames to display these buffers." :type 'function :group 'ediff-window) +;; declare-function does not exist in XEmacs ;; Definitions hidden from the compiler by compat wrappers. -(declare-function ediff-display-pixel-width "ediff-init") -(declare-function ediff-display-pixel-height "ediff-init") +;;(declare-function ediff-display-pixel-width "ediff-init") +;;(declare-function ediff-display-pixel-height "ediff-init") (defconst ediff-control-frame-parameters (list diff --git a/lisp/ediff.el b/lisp/ediff.el index 353c6a14d47..2caa3715f48 100644 --- a/lisp/ediff.el +++ b/lisp/ediff.el @@ -8,7 +8,7 @@ ;; Keywords: comparing, merging, patching, tools, unix (defconst ediff-version "2.81.2" "The current version of Ediff") -(defconst ediff-date "August 18, 2007" "Date of last update") +(defconst ediff-date "January 09, 2008" "Date of last update") ;; This file is part of GNU Emacs. @@ -361,7 +361,8 @@ (list (cons 'ediff-job-name job-name)) merge-buffer-file))) -(declare-function diff-latest-backup-file "diff" (fn)) +;; declare-function does not exist in XEmacs +;;(declare-function diff-latest-backup-file "diff" (fn))) ;;;###autoload (defalias 'ediff 'ediff-files) @@ -1427,7 +1428,7 @@ When called interactively, displays the version." (format "Ediff %s of %s" ediff-version ediff-date))) ;; info is run first, and will autoload info.el. -(declare-function Info-goto-node "info" (nodename &optional fork)) +;;(declare-function Info-goto-node "info" (nodename &optional fork)) ;;;###autoload (defun ediff-documentation (&optional node) diff --git a/lisp/emulation/viper-cmd.el b/lisp/emulation/viper-cmd.el index 3d74286589c..fbebacb16b5 100644 --- a/lisp/emulation/viper-cmd.el +++ b/lisp/emulation/viper-cmd.el @@ -2773,7 +2773,9 @@ On reaching beginning of line, stop and signal error." (defun viper-next-line-carefully (arg) (condition-case nil ;; do not use forward-line! need to keep column - (with-no-warnings (next-line arg)) + (if (featurep 'emacs) + (with-no-warnings (next-line arg)) + (next-line arg)) (error nil))) @@ -3073,15 +3075,18 @@ On reaching beginning of line, stop and signal error." (com (viper-getCom arg))) (if com (viper-move-marker-locally 'viper-com-point (point))) ;; do not use forward-line! need to keep column - (with-no-warnings (next-line val)) + (if (featurep 'emacs) + (with-no-warnings (next-line val)) + (next-line val)) (if viper-ex-style-motion (if (and (eolp) (not (bolp))) (backward-char 1))) (setq this-command 'next-line) (if com (viper-execute-com 'viper-next-line val com)))) -(declare-function widget-type "wid-edit" (widget)) -(declare-function widget-button-press "wid-edit" (pos &optional event)) -(declare-function viper-set-hooks "viper" ()) +;; declare-function is not defined in XEmacs +;;(declare-function widget-type "wid-edit" (widget)) +;;(declare-function widget-button-press "wid-edit" (pos &optional event)) +;;(declare-function viper-set-hooks "viper" ()) (defun viper-next-line-at-bol (arg) "Next line at beginning of line. @@ -3120,7 +3125,9 @@ If point is on a widget or a button, simulate clicking on that widget/button." (com (viper-getCom arg))) (if com (viper-move-marker-locally 'viper-com-point (point))) ;; do not use forward-line! need to keep column - (with-no-warnings (previous-line val)) + (if (featurep 'emacs) + (with-no-warnings (previous-line val)) + (previous-line val)) (if viper-ex-style-motion (if (and (eolp) (not (bolp))) (backward-char 1))) (setq this-command 'previous-line) diff --git a/lisp/emulation/viper-ex.el b/lisp/emulation/viper-ex.el index 6ce34852235..8e19a0b50bd 100644 --- a/lisp/emulation/viper-ex.el +++ b/lisp/emulation/viper-ex.el @@ -2216,9 +2216,11 @@ Type 'mak ' (including the space) to run make with no args." (pos2 (viper-line-pos 'end)) lines file info) (setq lines (count-lines (point-min) (viper-line-pos 'end)) - file (if (buffer-file-name) - (concat (viper-abbreviate-file-name (buffer-file-name)) ":") - (concat (buffer-name) " [Not visiting any file]:")) + file (cond ((buffer-file-name) + (concat (viper-abbreviate-file-name (buffer-file-name)) ":")) + ((buffer-file-name (buffer-base-buffer)) + (concat (viper-abbreviate-file-name (buffer-file-name (buffer-base-buffer))) " (indirect buffer):")) + (t (concat (buffer-name) " [Not visiting any file]:"))) info (format "line=%d/%d pos=%d/%d col=%d %s" (if (= pos1 pos2) (1+ lines) diff --git a/lisp/emulation/viper-keym.el b/lisp/emulation/viper-keym.el index f76a9310518..02df3fe3084 100644 --- a/lisp/emulation/viper-keym.el +++ b/lisp/emulation/viper-keym.el @@ -37,9 +37,10 @@ (require 'viper-util) -(declare-function viper-ex "viper-ex" (arg &optional string)) -(declare-function viper-normalize-minor-mode-map-alist "viper-cmd" ()) -(declare-function viper-set-mode-vars-for "viper-cmd" (state)) +;; declare-function is not defined in XEmacs +;;(declare-function viper-ex "viper-ex" (arg &optional string)) +;;(declare-function viper-normalize-minor-mode-map-alist "viper-cmd" ()) +;;(declare-function viper-set-mode-vars-for "viper-cmd" (state)) ;;; Variables diff --git a/lisp/emulation/viper-util.el b/lisp/emulation/viper-util.el index 33061565196..2bd2a3e276a 100644 --- a/lisp/emulation/viper-util.el +++ b/lisp/emulation/viper-util.el @@ -374,7 +374,8 @@ -(declare-function viper-forward-Word "viper-cmd" (arg)) +;; declare-function is not defined in XEmacs +;;(declare-function viper-forward-Word "viper-cmd" (arg)) ;;; Support for :e, :r, :w file globbing @@ -713,7 +714,7 @@ (not (memq (vc-state file) '(edited needs-merge))) (not (stringp (vc-state file)))) ;; XEmacs has no vc-state - (if (featurep 'xemacs)(not (vc-locking-user file)))) + (if (featurep 'xemacs) (not (vc-locking-user file)))) )) ;; checkout if visited file is checked in diff --git a/lisp/emulation/viper.el b/lisp/emulation/viper.el index 19d3a7f018a..9d2acac4ce7 100644 --- a/lisp/emulation/viper.el +++ b/lisp/emulation/viper.el @@ -9,7 +9,7 @@ ;; Author: Michael Kifer ;; Keywords: emulations -(defconst viper-version "3.14 of August 18, 2007" +(defconst viper-version "3.14 of January 09, 2008" "The current version of Viper") ;; This file is part of GNU Emacs. @@ -857,7 +857,9 @@ It also can't undo some Viper settings." (modify-frame-parameters (selected-frame) (list (cons 'viper-vi-state-cursor-color - (viper-get-cursor-color)))))) + (viper-get-cursor-color)))) + (setq viper-vi-state-cursor-color (viper-get-cursor-color)) + )) ;; Tell vc-diff to put *vc* in Vi mode (if (featurep 'vc) @@ -900,6 +902,7 @@ It also can't undo some Viper settings." (modify-frame-parameters (selected-frame) (list (cons 'viper-vi-state-cursor-color (ad-get-arg 0)))) + (setq viper-vi-state-cursor-color (ad-get-arg 0)) ) (when (and (fboundp 'add-to-ordered-list) (boundp 'emulation-mode-map-alists)) From 606180397c8553af5dcc8efead1c4d1073ebcd57 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 9 Jan 2008 06:30:58 +0000 Subject: [PATCH 027/439] (top-level): Fix spacing. (verilog-mode-version, verilog-mode-release-date): Update version number. (verilog-mode-release-emacs): New variable. (compile-command, reporter-prompt-for-summary-p): Define for byte compiler. (verilog-startup-message-lines) (verilog-startup-message-displayed) (verilog-display-startup-message): Remove. (verilog-highlight-p1800-keywords): Improve docstring. (sigs-in, sigs-out, got-sig, got-rvalue, uses-delayed) (vector-skip-list): Only defvar at compile time. (verilog-highlight-translate-off, verilog-indent-level) (verilog-indent-level-module, verilog-indent-level-declaration) (verilog-indent-declaration-macros, verilog-indent-lists) (verilog-indent-level-behavioral) (verilog-indent-level-directive, verilog-cexp-indent) (verilog-case-indent, verilog-auto-newline) (verilog-auto-indent-on-newline, verilog-tab-always-indent) (verilog-tab-to-comment, verilog-indent-begin-after-if) (verilog-align-ifelse, verilog-minimum-comment-distance) (verilog-auto-lineup, verilog-highlight-p1800-keywords) (verilog-auto-endcomments, verilog-auto-read-includes) (verilog-auto-star-expand, verilog-auto-star-save) (verilog-library-flags, verilog-library-directories) (verilog-library-files, verilog-library-extensions) (verilog-active-low-regexp, verilog-auto-sense-include-inputs) (verilog-auto-sense-defines-constant, verilog-auto-reset-widths) (verilog-assignment-delay, verilog-auto-inst-vector) (verilog-auto-inst-template-numbers) (verilog-auto-input-ignore-regexp) (verilog-auto-inout-ignore-regexp) (verilog-auto-output-ignore-regexp) (verilog-auto-unused-ignore-regexp, verilog-typedef-regexp): Add safe-local-variable properties. (verilog-statement-menu, verilog-company) (verilog-re-search-forward, verilog-re-search-backward) (verilog-error-regexp-add, verilog-end-block-re) (verilog-emacs-features, verilog-populate-syntax-table) (verilog-setup-dual-comments, verilog-type-font-keywords) (verilog-inside-comment-p, electric-verilog-backward-sexp) (verilog-backward-sexp, verilog-forward-sexp) (verilog-font-lock-init, verilog-mode) (electric-verilog-terminate-line, electric-verilog-semi) (electric-verilog-tab, verilog-insert-1, ) (verilog-insert-indices, verilog-generate-numbers) (verilog-comment-region, verilog-label-be) (verilog-beg-of-statement, verilog-in-case-region-p) (verilog-in-struct-region-p, verilog-in-generate-region-p) (verilog-in-fork-region-p, verilog-backward-case-item) (verilog-set-auto-endcomments, verilog-get-expr) (verilog-expand-vector-internal, verilog-surelint-off) (verilog-batch-execute-func, verilog-calculate-indent) (verilog-calc-1, verilog-calculate-indent-directive) (verilog-leap-to-head, verilog-continued-line) (verilog-backward-token, verilog-backward-syntactic-ws) (verilog-forward-syntactic-ws, verilog-backward-ws&directives) (verilog-forward-ws&directives, verilog-at-constraint-p) (verilog-skip-backward-comments, verilog-indent-line-relative) (verilog-do-indent, verilog-indent-comment) (verilog-more-comment, verilog-pretty-declarations) (verilog-pretty-expr, verilog-just-one-space) (verilog-indent-declaration, verilog-get-completion-decl) (verilog-goto-defun, verilog-showscopes, verilog-header) (verilog-signals-combine-bus, verilog-read-decls) (verilog-read-always-signals-recurse, verilog-read-instants) (verilog-read-auto-template, verilog-set-define) (verilog-read-defines, verilog-read-signals, verilog-getopt) (verilog-is-number, verilog-expand-dirnames) (verilog-modi-lookup, verilog-modi-cache-results) (verilog-insert-one-definition, verilog-make-width-expression) (verilog-delete-autos-lined, verilog-auto-save-check) (verilog-auto-arg, verilog-auto-inst-port, verilog-auto-inst) (verilog-auto-inst-param, verilog-auto-reg) (verilog-auto-reg-input, verilog-auto-wire, ) (verilog-auto-output, verilog-auto-output-every) (verilog-auto-input, verilog-auto-inout) (verilog-auto-inout-module, verilog-auto-sense) (verilog-auto-reset, verilog-auto-tieoff, verilog-auto-unused) (verilog-auto-ascii-enum, verilog-auto) (verilog-sk-define-signal, verilog-mode-mouse-map) (verilog-load-file-at-mouse, verilog-load-file-at-point) (verilog-library-files): Cleanup spacing of )'s they should not be on unique lines. Fix checkdoc warnings. --- lisp/ChangeLog | 87 ++++ lisp/progmodes/verilog-mode.el | 866 ++++++++++++++------------------- 2 files changed, 440 insertions(+), 513 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 555c941d2e4..69274fa24ff 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,90 @@ +2008-01-09 Wilson Snyder + + * progmodes/verilog-mode.el (top-level): Fix spacing. + (verilog-mode-version, verilog-mode-release-date): Update version + number. + (verilog-mode-release-emacs): New variable. + (compile-command, reporter-prompt-for-summary-p): Define for byte + compiler. + (verilog-startup-message-lines) + (verilog-startup-message-displayed) + (verilog-display-startup-message): Remove. + (verilog-highlight-p1800-keywords): Improve docstring. + (sigs-in, sigs-out, got-sig, got-rvalue, uses-delayed) + (vector-skip-list): Only defvar at compile time. + (verilog-highlight-translate-off, verilog-indent-level) + (verilog-indent-level-module, verilog-indent-level-declaration) + (verilog-indent-declaration-macros, verilog-indent-lists) + (verilog-indent-level-behavioral) + (verilog-indent-level-directive, verilog-cexp-indent) + (verilog-case-indent, verilog-auto-newline) + (verilog-auto-indent-on-newline, verilog-tab-always-indent) + (verilog-tab-to-comment, verilog-indent-begin-after-if) + (verilog-align-ifelse, verilog-minimum-comment-distance) + (verilog-auto-lineup, verilog-highlight-p1800-keywords) + (verilog-auto-endcomments, verilog-auto-read-includes) + (verilog-auto-star-expand, verilog-auto-star-save) + (verilog-library-flags, verilog-library-directories) + (verilog-library-files, verilog-library-extensions) + (verilog-active-low-regexp, verilog-auto-sense-include-inputs) + (verilog-auto-sense-defines-constant, verilog-auto-reset-widths) + (verilog-assignment-delay, verilog-auto-inst-vector) + (verilog-auto-inst-template-numbers) + (verilog-auto-input-ignore-regexp) + (verilog-auto-inout-ignore-regexp) + (verilog-auto-output-ignore-regexp) + (verilog-auto-unused-ignore-regexp, verilog-typedef-regexp): Add + safe-local-variable properties. + (verilog-statement-menu, verilog-company) + (verilog-re-search-forward, verilog-re-search-backward) + (verilog-error-regexp-add, verilog-end-block-re) + (verilog-emacs-features, verilog-populate-syntax-table) + (verilog-setup-dual-comments, verilog-type-font-keywords) + (verilog-inside-comment-p, electric-verilog-backward-sexp) + (verilog-backward-sexp, verilog-forward-sexp) + (verilog-font-lock-init, verilog-mode) + (electric-verilog-terminate-line, electric-verilog-semi) + (electric-verilog-tab, verilog-insert-1, ) + (verilog-insert-indices, verilog-generate-numbers) + (verilog-comment-region, verilog-label-be) + (verilog-beg-of-statement, verilog-in-case-region-p) + (verilog-in-struct-region-p, verilog-in-generate-region-p) + (verilog-in-fork-region-p, verilog-backward-case-item) + (verilog-set-auto-endcomments, verilog-get-expr) + (verilog-expand-vector-internal, verilog-surelint-off) + (verilog-batch-execute-func, verilog-calculate-indent) + (verilog-calc-1, verilog-calculate-indent-directive) + (verilog-leap-to-head, verilog-continued-line) + (verilog-backward-token, verilog-backward-syntactic-ws) + (verilog-forward-syntactic-ws, verilog-backward-ws&directives) + (verilog-forward-ws&directives, verilog-at-constraint-p) + (verilog-skip-backward-comments, verilog-indent-line-relative) + (verilog-do-indent, verilog-indent-comment) + (verilog-more-comment, verilog-pretty-declarations) + (verilog-pretty-expr, verilog-just-one-space) + (verilog-indent-declaration, verilog-get-completion-decl) + (verilog-goto-defun, verilog-showscopes, verilog-header) + (verilog-signals-combine-bus, verilog-read-decls) + (verilog-read-always-signals-recurse, verilog-read-instants) + (verilog-read-auto-template, verilog-set-define) + (verilog-read-defines, verilog-read-signals, verilog-getopt) + (verilog-is-number, verilog-expand-dirnames) + (verilog-modi-lookup, verilog-modi-cache-results) + (verilog-insert-one-definition, verilog-make-width-expression) + (verilog-delete-autos-lined, verilog-auto-save-check) + (verilog-auto-arg, verilog-auto-inst-port, verilog-auto-inst) + (verilog-auto-inst-param, verilog-auto-reg) + (verilog-auto-reg-input, verilog-auto-wire, ) + (verilog-auto-output, verilog-auto-output-every) + (verilog-auto-input, verilog-auto-inout) + (verilog-auto-inout-module, verilog-auto-sense) + (verilog-auto-reset, verilog-auto-tieoff, verilog-auto-unused) + (verilog-auto-ascii-enum, verilog-auto) + (verilog-sk-define-signal, verilog-mode-mouse-map) + (verilog-load-file-at-mouse, verilog-load-file-at-point) + (verilog-library-files): Cleanup spacing of )'s they should not be + on unique lines. Fix checkdoc warnings. + 2008-01-09 Glenn Morris * ffap.el (ffap-string-at-point-mode-alist): Add `\' to file diff --git a/lisp/progmodes/verilog-mode.el b/lisp/progmodes/verilog-mode.el index 54a3f0f6f80..59d5ea83475 100644 --- a/lisp/progmodes/verilog-mode.el +++ b/lisp/progmodes/verilog-mode.el @@ -11,6 +11,12 @@ ;; http://www.veripool.com ;; Keywords: languages +;; This code supports Emacs 21.1 and later +;; And XEmacs 21.1 and later +;; Please do not make changes that break Emacs 21. Thanks! +;; +;; + ;; This file is part of GNU Emacs. ;; GNU Emacs is free software; you can redistribute it and/or modify @@ -30,12 +36,12 @@ ;;; Commentary: -;; This mode borrows heavily from the Pascal-mode and the cc-mode of emacs +;; This mode borrows heavily from the Pascal-mode and the cc-mode of Emacs ;; USAGE ;; ===== -;; A major mode for editing Verilog HDL source code. When you have +;; A major mode for editing Verilog HDL source code. When you have ;; entered Verilog mode, you may get more info by pressing C-h m. You ;; may also get online help describing various functions by: C-h f ;; @@ -44,8 +50,8 @@ ;; ======================= ;; Verilog is a rapidly evolving language, and hence this mode is -;; under continuous development. Hence this is beta code, and likely -;; has bugs. Please report any and all bugs to me at mac@verilog.com. +;; under continuous development. Hence this is beta code, and likely +;; has bugs. Please report any and all bugs to me at mac@verilog.com. ;; Please use verilog-submit-bug-report to submit a report; type C-c ;; C-b to invoke this and as a result I will have a much easier time ;; of reproducing the bug you find, and hence fixing it. @@ -55,7 +61,7 @@ ;; An older version of this mode may be already installed as a part of ;; your environment, and one method of updating would be to update -;; your emacs environment. Sometimes this is difficult for local +;; your Emacs environment. Sometimes this is difficult for local ;; political/control reasons, and hence you can always install a ;; private copy (or even a shared copy) which overrides the system ;; default. @@ -74,7 +80,7 @@ ;; If you want to customize Verilog mode to fit your needs better, ;; you may add these lines (the values of the variables presented -;; here are the defaults). Note also that if you use an emacs that +;; here are the defaults). Note also that if you use an Emacs that ;; supports custom, it's probably better to use the custom menu to ;; edit these. ;; @@ -102,15 +108,19 @@ ;; ;;; History: -;; -;; +;; +;; See commit history at http://www.veripool.com/verilog-mode.html +;; (This section is required to appease checkdoc.) + ;;; Code: ;; This variable will always hold the version number of the mode -(defconst verilog-mode-version "377" - "Version of this verilog mode.") -(defconst verilog-mode-release-date "2007-12-07" +(defconst verilog-mode-version "383" "Version of this verilog mode.") +(defconst verilog-mode-release-date "2008-01-07-GNU" + "Release date of this verilog mode.") +(defconst verilog-mode-release-emacs t + "If non-nil, this version of verilog mode was released with Emacs itself.") (defun verilog-version () "Inform caller of the version of this file." @@ -118,7 +128,10 @@ (message "Using verilog-mode version %s" verilog-mode-version)) ;; Insure we have certain packages, and deal with it if we don't +;; Be sure to note which Emacs flavor and version added each feature. (eval-when-compile + ;; The below were disabled when GNU Emacs 22 was released; + ;; perhaps some still need to be there to support Emacs 21. (when (featurep 'xemacs) (condition-case nil (require 'easymenu) @@ -181,8 +194,8 @@ STRING should be given if the last search was by `string-match' on STRING." result) (buffer-substring-no-properties (match-beginning num) (match-end num) - (current-buffer) - ))))) + (current-buffer))))) + ) (error nil)) (if (and (featurep 'custom) (fboundp 'custom-declare-variable)) nil ;; We've got what we needed @@ -210,6 +223,8 @@ STRING should be given if the last search was by `string-match' on STRING." ;; Provide a regular expression optimization routine, using regexp-opt ;; if provided by the user's elisp libraries (eval-and-compile + ;; The below were disabled when GNU Emacs 22 was released; + ;; perhaps some still need to be there to support Emacs 21. (if (featurep 'xemacs) (if (fboundp 'regexp-opt) ;; regexp-opt is defined, does it take 3 or 2 arguments? @@ -222,8 +237,7 @@ STRING should be given if the last search was by `string-match' on STRING." (defun verilog-regexp-opt (a b) "Deal with differing number of required arguments for `regexp-opt'. Call 'regexp-opt' on A and B." - (regexp-opt a b 't) - ) + (regexp-opt a b 't)) (error nil)) ) ((eq args 2) ;; It takes 2 @@ -290,6 +304,7 @@ you type \\[compile]. When the compile completes, \\[next-error] will take you to the next lint error." :type 'string :group 'verilog-mode-actions) +;; We don't mark it safe, as it's used as a shell command (defcustom verilog-coverage "echo 'No verilog-coverage set, see \"M-x describe-variable verilog-coverage\"'" @@ -299,6 +314,7 @@ you type \\[compile]. When the compile completes, \\[next-error] will take you to the next lint error." :type 'string :group 'verilog-mode-actions) +;; We don't mark it safe, as it's used as a shell command (defcustom verilog-simulator "echo 'No verilog-simulator set, see \"M-x describe-variable verilog-simulator\"'" @@ -308,6 +324,7 @@ you type \\[compile]. When the compile completes, \\[next-error] will take you to the next lint error." :type 'string :group 'verilog-mode-actions) +;; We don't mark it safe, as it's used as a shell command (defcustom verilog-compiler "echo 'No verilog-compiler set, see \"M-x describe-variable verilog-compiler\"'" @@ -317,6 +334,7 @@ you type \\[compile]. When the compile completes, \\[next-error] will take you to the next lint error." :type 'string :group 'verilog-mode-actions) +;; We don't mark it safe, as it's used as a shell command (defvar verilog-tool 'verilog-linter "Which tool to use for building compiler-command. @@ -336,11 +354,14 @@ Note: Activate the new setting in a Verilog buffer by re-fontifying it (menu entry \"Fontify Buffer\"). XEmacs: turn off and on font locking." :type 'boolean :group 'verilog-mode-indent) +;; Note we don't use :safe, as that would break on Emacsen before 22.0. +(put 'verilog-highlight-translate-off 'safe-local-variable 'booleanp) (defcustom verilog-indent-level 3 "*Indentation of Verilog statements with respect to containing block." :group 'verilog-mode-indent :type 'integer) +(put 'verilog-indent-level 'safe-local-variable 'integerp) (defcustom verilog-indent-level-module 3 "*Indentation of Module level Verilog statements. (eg always, initial) @@ -348,12 +369,14 @@ Set to 0 to get initial and always statements lined up on the left side of your screen." :group 'verilog-mode-indent :type 'integer) +(put 'verilog-indent-level-module 'safe-local-variable 'integerp) (defcustom verilog-indent-level-declaration 3 "*Indentation of declarations with respect to containing block. Set to 0 to get them list right under containing block." :group 'verilog-mode-indent :type 'integer) +(put 'verilog-indent-level-declaration 'safe-local-variable 'integerp) (defcustom verilog-indent-declaration-macros nil "*How to treat macro expansions in a declaration. @@ -367,6 +390,7 @@ If non nil, treat as: output c;" :group 'verilog-mode-indent :type 'boolean) +(put 'verilog-indent-declaration-macros 'safe-local-variable 'booleanp) (defcustom verilog-indent-lists t "*How to treat indenting items in a list. @@ -379,62 +403,73 @@ If nil, treat as: reset ) begin" :group 'verilog-mode-indent :type 'boolean) +(put 'verilog-indent-lists 'safe-local-variable 'booleanp) (defcustom verilog-indent-level-behavioral 3 "*Absolute indentation of first begin in a task or function block. Set to 0 to get such code to start at the left side of the screen." :group 'verilog-mode-indent :type 'integer) +(put 'verilog-indent-level-behavioral 'safe-local-variable 'integerp) (defcustom verilog-indent-level-directive 1 "*Indentation to add to each level of `ifdef declarations. Set to 0 to have all directives start at the left side of the screen." :group 'verilog-mode-indent :type 'integer) +(put 'verilog-indent-level-directive 'safe-local-variable 'integerp) (defcustom verilog-cexp-indent 2 "*Indentation of Verilog statements split across lines." :group 'verilog-mode-indent :type 'integer) +(put 'verilog-cexp-indent 'safe-local-variable 'integerp) (defcustom verilog-case-indent 2 "*Indentation for case statements." :group 'verilog-mode-indent :type 'integer) +(put 'verilog-case-indent 'safe-local-variable 'integerp) (defcustom verilog-auto-newline t "*True means automatically newline after semicolons." :group 'verilog-mode-indent :type 'boolean) +(put 'verilog-auto-newline 'safe-local-variable 'booleanp) (defcustom verilog-auto-indent-on-newline t "*True means automatically indent line after newline." :group 'verilog-mode-indent :type 'boolean) +(put 'verilog-auto-indent-on-newline 'safe-local-variable 'booleanp) (defcustom verilog-tab-always-indent t "*True means TAB should always re-indent the current line. Nil means TAB will only reindent when at the beginning of the line." :group 'verilog-mode-indent :type 'boolean) +(put 'verilog-tab-always-indent 'safe-local-variable 'booleanp) (defcustom verilog-tab-to-comment nil "*True means TAB moves to the right hand column in preparation for a comment." :group 'verilog-mode-actions :type 'boolean) +(put 'verilog-tab-to-comment 'safe-local-variable 'booleanp) (defcustom verilog-indent-begin-after-if t "*If true, indent begin statements following if, else, while, for and repeat. Otherwise, line them up." :group 'verilog-mode-indent - :type 'boolean ) + :type 'boolean) +(put 'verilog-indent-begin-after-if 'safe-local-variable 'booleanp) (defcustom verilog-align-ifelse nil "*If true, align `else' under matching `if'. Otherwise else is lined up with first character on line holding matching if." :group 'verilog-mode-indent - :type 'boolean ) + :type 'boolean) +(put 'verilog-align-ifelse 'safe-local-variable 'booleanp) (defcustom verilog-minimum-comment-distance 10 "*Minimum distance (in lines) between begin and end required before a comment. @@ -442,6 +477,7 @@ Setting this variable to zero results in every end acquiring a comment; the default avoids too many redundant comments in tight quarters" :group 'verilog-mode-indent :type 'integer) +(put 'verilog-minimum-comment-distance 'safe-local-variable 'integerp) (defcustom verilog-auto-lineup '(declaration) "*Algorithm for lining up statements on multiple lines. @@ -481,23 +517,26 @@ would become ; :group 'verilog-mode-indent - :type 'list ) + :type 'list) +(put 'verilog-auto-lineup 'safe-local-variable 'listp) (defcustom verilog-highlight-p1800-keywords nil - "*If true highlight words newly reserved by IEEE-1800 in -verilog-font-lock-p1800-face in order to gently suggest changing where -these words are used as variables to something else. Nil means highlight -these words as appropriate for the SystemVerilog IEEE-1800 standard. Note -that changing this will require restarting emacs to see the effect as font -color choices are cached by emacs" + "*True means highlight words newly reserved by IEEE-1800. +These will appear in `verilog-font-lock-p1800-face' in order to gently +suggest changing where these words are used as variables to something else. +Nil means highlight these words as appropriate for the SystemVerilog +IEEE-1800 standard. Note that changing this will require restarting Emacs +to see the effect as font color choices are cached by Emacs" :group 'verilog-mode-indent :type 'boolean) +(put 'verilog-highlight-p1800-keywords 'safe-local-variable 'booleanp) (defcustom verilog-auto-endcomments t "*True means insert a comment /* ... */ after 'end's. The name of the function or case will be set between the braces." :group 'verilog-mode-actions - :type 'boolean ) + :type 'boolean) +(put 'verilog-auto-endcomments 'safe-local-variable 'booleanp) (defcustom verilog-auto-read-includes nil "*True means to automatically read includes before AUTOs. @@ -506,7 +545,8 @@ each AUTO expansion. This makes it easier to embed defines and includes, but can result in very slow reading times if there are many or large include files." :group 'verilog-mode-actions - :type 'boolean ) + :type 'boolean) +(put 'verilog-auto-read-includes 'safe-local-variable 'booleanp) (defcustom verilog-auto-save-policy nil "*Non-nil indicates action to take when saving a Verilog buffer with AUTOs. @@ -527,6 +567,7 @@ They will be expanded in the same way as if there was a AUTOINST in the instantiation. See also `verilog-auto-star' and `verilog-auto-star-save'." :group 'verilog-mode-actions :type 'boolean) +(put 'verilog-auto-star-expand 'safe-local-variable 'booleanp) (defcustom verilog-auto-star-save nil "*Non-nil indicates to save to disk SystemVerilog .* instance expansions. @@ -537,6 +578,7 @@ Instead of setting this, you may want to use /*AUTOINST*/, which will always be saved." :group 'verilog-mode-actions :type 'boolean) +(put 'verilog-auto-star-save 'safe-local-variable 'booleanp) (defvar verilog-auto-update-tick nil "Modification tick at which autos were last performed.") @@ -624,8 +666,7 @@ always be saved." ("In file \\([^ \t]+\\)[ \t]+line[ \t]+\\([0-9]+\\):\n[^\n]*\n[^\n]*\n\\[\\(Warning\\|Error\\|Failure\\)\\][^\n]*" 1 bold t) ("In file \\([^ \t]+\\)[ \t]+line[ \t]+\\([0-9]+\\):\n[^\n]*\n[^\n]*\n\\[\\(Warning\\|Error\\|Failure\\)\\][^\n]*" 2 bold t) ) - "*Keywords to also highlight in Verilog *compilation* buffers." - ) + "*Keywords to also highlight in Verilog *compilation* buffers.") (defcustom verilog-library-flags '("") "*List of standard Verilog arguments to use for /*AUTOINST*/. @@ -656,6 +697,7 @@ have problems, use \\[find-alternate-file] RET to have these take effect. See also the variables mentioned above." :group 'verilog-mode-auto :type '(repeat string)) +(put 'verilog-library-flags 'safe-local-variable 'listp) (defcustom verilog-library-directories '(".") "*List of directories when looking for files for /*AUTOINST*/. @@ -678,9 +720,11 @@ See also `verilog-library-flags', `verilog-library-files' and `verilog-library-extensions'." :group 'verilog-mode-auto :type '(repeat file)) +(put 'verilog-library-directories 'safe-local-variable 'listp) (defcustom verilog-library-files '() - "*List of files to search for modules when looking for AUTOINST files. + "*List of files to search for modules. +AUTOINST will use this when it needs to resolve a module name. This is a complete path, usually to a technology file with many standard cells defined in it. @@ -698,12 +742,14 @@ have problems, use \\[find-alternate-file] RET to have these take effect. See also `verilog-library-flags', `verilog-library-directories'." :group 'verilog-mode-auto :type '(repeat directory)) +(put 'verilog-library-files 'safe-local-variable 'listp) (defcustom verilog-library-extensions '(".v") "*List of extensions to use when looking for files for /*AUTOINST*/. See also `verilog-library-flags', `verilog-library-directories'." :type '(repeat string) :group 'verilog-mode-auto) +(put 'verilog-library-extensions 'safe-local-variable 'listp) (defcustom verilog-active-low-regexp nil "*If set, treat signals matching this regexp as active low. @@ -711,21 +757,24 @@ This is used for AUTORESET and AUTOTIEOFF. For proper behavior, you will probably also need `verilog-auto-reset-widths' set." :group 'verilog-mode-auto :type 'string) +(put 'verilog-active-low-regexp 'safe-local-variable 'stringp) (defcustom verilog-auto-sense-include-inputs nil "*If true, AUTOSENSE should include all inputs. If nil, only inputs that are NOT output signals in the same block are included." - :type 'boolean - :group 'verilog-mode-auto) + :group 'verilog-mode-auto + :type 'boolean) +(put 'verilog-auto-sense-include-inputs 'safe-local-variable 'booleanp) (defcustom verilog-auto-sense-defines-constant nil "*If true, AUTOSENSE should assume all defines represent constants. When true, the defines will not be included in sensitivity lists. To maintain compatibility with other sites, this should be set at the bottom of each verilog file that requires it, rather than being set globally." - :type 'boolean - :group 'verilog-mode-auto) + :group 'verilog-mode-auto + :type 'boolean) +(put 'verilog-auto-sense-defines-constant 'safe-local-variable 'booleanp) (defcustom verilog-auto-reset-widths t "*If true, AUTORESET should determine the width of signals. @@ -735,11 +784,13 @@ the constant zero. This may result in ugly code when parameters determine the MSB or LSB of a signal inside a AUTORESET." :type 'boolean :group 'verilog-mode-auto) +(put 'verilog-auto-reset-widths 'safe-local-variable 'booleanp) (defcustom verilog-assignment-delay "" "*Text used for delays in delayed assignments. Add a trailing space if set." - :type 'string - :group 'verilog-mode-auto) + :group 'verilog-mode-auto + :type 'string) +(put 'verilog-assignment-delay 'safe-local-variable 'stringp) (defcustom verilog-auto-inst-vector t "*If true, when creating default ports with AUTOINST, use bus subscripts. @@ -748,7 +799,8 @@ the module (AUTOWIRE signals always are subscripted, you must manually declare the wire to have the subscripts removed.) Nil may speed up some simulators, but is less general and harder to read, so avoid." :group 'verilog-mode-auto - :type 'boolean ) + :type 'boolean) +(put 'verilog-auto-inst-vector 'safe-local-variable 'booleanp) (defcustom verilog-auto-inst-template-numbers nil "*If true, when creating templated ports with AUTOINST, add a comment. @@ -756,7 +808,8 @@ The comment will add the line number of the template that was used for that port declaration. Setting this aids in debugging, but nil is suggested for regular use to prevent large numbers of merge conflicts." :group 'verilog-mode-auto - :type 'boolean ) + :type 'boolean) +(put 'verilog-auto-inst-template-numbers 'safe-local-variable 'booleanp) (defvar verilog-auto-inst-column 40 "Column number for first part of auto-inst.") @@ -765,31 +818,36 @@ regular use to prevent large numbers of merge conflicts." "*If set, when creating AUTOINPUT list, ignore signals matching this regexp. See the \\[verilog-faq] for examples on using this." :group 'verilog-mode-auto - :type 'string ) + :type 'string) +(put 'verilog-auto-input-ignore-regexp 'safe-local-variable 'stringp) (defcustom verilog-auto-inout-ignore-regexp nil "*If set, when creating AUTOINOUT list, ignore signals matching this regexp. See the \\[verilog-faq] for examples on using this." :group 'verilog-mode-auto - :type 'string ) + :type 'string) +(put 'verilog-auto-inout-ignore-regexp 'safe-local-variable 'stringp) (defcustom verilog-auto-output-ignore-regexp nil "*If set, when creating AUTOOUTPUT list, ignore signals matching this regexp. See the \\[verilog-faq] for examples on using this." :group 'verilog-mode-auto - :type 'string ) + :type 'string) +(put 'verilog-auto-output-ignore-regexp 'safe-local-variable 'stringp) (defcustom verilog-auto-unused-ignore-regexp nil "*If set, when creating AUTOUNUSED list, ignore signals matching this regexp. See the \\[verilog-faq] for examples on using this." :group 'verilog-mode-auto - :type 'string ) + :type 'string) +(put 'verilog-auto-unused-ignore-regexp 'safe-local-variable 'stringp) (defcustom verilog-typedef-regexp nil "*If non-nil, regular expression that matches Verilog-2001 typedef names. For example, \"_t$\" matches typedefs named with _t, as in the C language." :group 'verilog-mode-auto - :type 'string ) + :type 'string) +(put 'verilog-typedef-regexp 'safe-local-variable 'stringp) (defcustom verilog-mode-hook 'verilog-set-compile-command "*Hook (List of functions) run after verilog mode is loaded." @@ -798,33 +856,33 @@ For example, \"_t$\" matches typedefs named with _t, as in the C language." (defcustom verilog-auto-hook nil "*Hook run after `verilog-mode' updates AUTOs." - :type 'hook - :group 'verilog-mode-auto) + :group 'verilog-mode-auto + :type 'hook) (defcustom verilog-before-auto-hook nil "*Hook run before `verilog-mode' updates AUTOs." - :type 'hook - :group 'verilog-mode-auto) + :group 'verilog-mode-auto + :type 'hook) (defcustom verilog-delete-auto-hook nil "*Hook run after `verilog-mode' deletes AUTOs." - :type 'hook - :group 'verilog-mode-auto) + :group 'verilog-mode-auto + :type 'hook) (defcustom verilog-before-delete-auto-hook nil "*Hook run before `verilog-mode' deletes AUTOs." - :type 'hook - :group 'verilog-mode-auto) + :group 'verilog-mode-auto + :type 'hook) (defcustom verilog-getopt-flags-hook nil "*Hook run after `verilog-getopt-flags' determines the Verilog option lists." - :type 'hook - :group 'verilog-mode-auto) + :group 'verilog-mode-auto + :type 'hook) (defcustom verilog-before-getopt-flags-hook nil "*Hook run before `verilog-getopt-flags' determines the Verilog option lists." - :type 'hook - :group 'verilog-mode-auto) + :group 'verilog-mode-auto + :type 'hook) (defvar verilog-imenu-generic-expression '((nil "^\\s-*\\(\\(m\\(odule\\|acromodule\\)\\)\\|primitive\\)\\s-+\\([a-zA-Z0-9_.:]+\\)" 4) @@ -843,13 +901,11 @@ format (e.g. 09/17/1997) is not supported.") (defvar verilog-company nil "*Default name of Company for verilog header. If set will become buffer local.") - (make-variable-buffer-local 'verilog-company) (defvar verilog-project nil "*Default name of Project for verilog header. If set will become buffer local.") - (make-variable-buffer-local 'verilog-project) (defvar verilog-mode-map @@ -1025,8 +1081,7 @@ If set will become buffer local.") ["Casex" verilog-sk-casex t] ["Casez" verilog-sk-casez t] ) - "Menu for statement templates in Verilog." - ) + "Menu for statement templates in Verilog.") (easy-menu-define verilog-menu verilog-mode-map "Menu for Verilog mode" verilog-xemacs-menu) @@ -1072,8 +1127,7 @@ will break, as the o's continuously replace. xa -> x works ok though." (store-match-data '(nil nil)) (if BOUND (< (point) BOUND) - t) - )))) + t))))) (match-end 0)) (defsubst verilog-re-search-backward (REGEXP BOUND NOERROR) @@ -1087,8 +1141,7 @@ will break, as the o's continuously replace. xa -> x works ok though." (store-match-data '(nil nil)) (if BOUND (> (point) BOUND) - t) - )))) + t))))) (match-end 0)) (defsubst verilog-re-search-forward-quick (regexp bound noerror) @@ -1130,6 +1183,8 @@ so there may be a large up front penalty for the first search." (save-excursion (nth 3 (parse-partial-sexp (verilog-get-beg-of-line) (point))))) +(defvar compile-command) + ;; compilation program (defun verilog-set-compile-command () "Function to compute shell command to compile verilog. @@ -1201,8 +1256,7 @@ find the errors." (setq compilation-error-regexp-alist (default-value 'compilation-error-regexp-alist)) (set (make-local-variable 'compilation-error-regexp-alist) - (default-value 'compilation-error-regexp-alist)) - ))) + (default-value 'compilation-error-regexp-alist))))) (add-hook 'compilation-mode-hook 'verilog-error-regexp-add) @@ -1330,8 +1384,7 @@ find the errors." "endprogram" "endsequence" "endclocking" - ) - ))) + )))) (defconst verilog-endcomment-reason-re @@ -1667,11 +1720,11 @@ find the errors." (and (or (not major) (not minor)) (string-match "\\([0-9]+\\).\\([0-9]+\\)" emacs-version) (setq major (string-to-number (substring emacs-version - (match-beginning 1) - (match-end 1))) + (match-beginning 1) + (match-end 1))) minor (string-to-number (substring emacs-version - (match-beginning 2) - (match-end 2))))) + (match-beginning 2) + (match-end 2))))) (if (not (and major minor)) (error "Cannot figure out the major and minor version numbers")) ;; calculate the major version @@ -1706,8 +1759,7 @@ find the errors." ;; Emacs 19.30 and beyond are known to be 1-bit ((eq flavor 'FSF) (setq comments '1-bit)) ;; Don't know what this is - (t (error "Couldn't figure out syntax table format")) - )) + (t (error "Couldn't figure out syntax table format")))) ;; Emacs 18 has no support for dual comments (setq comments 'no-dual-comments)) ;; determine whether to use old or new font lock syntax @@ -1724,8 +1776,7 @@ find the errors." ;; Emacs before 19.6 had bugs (and (eq major 'v19) (eq flavor 'XEmacs) (< minor 6)) ;; Emacs 19 before 19.21 has known bugs - (and (eq major 'v19) (eq flavor 'FSF) (< minor 21)) - ) + (and (eq major 'v19) (eq flavor 'FSF) (< minor 21))) (with-output-to-temp-buffer "*verilog-mode warnings*" (print (format "The version of Emacs that you are running, %s, @@ -1785,8 +1836,7 @@ supported list, along with the values for this variable: (modify-syntax-entry ?| "." table) (modify-syntax-entry ?` "w" table) (modify-syntax-entry ?_ "w" table) - (modify-syntax-entry ?\' "." table) -) + (modify-syntax-entry ?\' "." table)) (defun verilog-setup-dual-comments (table) "Set up TABLE to handle block and line style comments." @@ -1795,15 +1845,12 @@ supported list, along with the values for this variable: ;; XEmacs (formerly Lucid) has the best implementation (modify-syntax-entry ?/ ". 1456" table) (modify-syntax-entry ?* ". 23" table) - (modify-syntax-entry ?\n "> b" table) - ) + (modify-syntax-entry ?\n "> b" table)) ((memq '1-bit verilog-emacs-features) ;; Emacs 19 does things differently, but we can work with it (modify-syntax-entry ?/ ". 124b" table) (modify-syntax-entry ?* ". 23" table) - (modify-syntax-entry ?\n "> b" table) - ) - )) + (modify-syntax-entry ?\n "> b" table)))) (defvar verilog-mode-syntax-table nil "Syntax table used in `verilog-mode' buffers.") @@ -1961,8 +2008,7 @@ See also `verilog-font-lock-extra-types'.") 'font-lock-type-face)) ;; Fontify Verilog-AMS keywords (cons (concat "\\<\\(" verilog-ams-keywords "\\)\\>") - 'verilog-font-lock-ams-face) - )) + 'verilog-font-lock-ams-face))) (setq verilog-font-lock-keywords-1 (append verilog-font-lock-keywords @@ -1976,15 +2022,12 @@ See also `verilog-font-lock-extra-types'.") (list (concat "\\\\s-+\\(integer\\|real\\(time\\)?\\|time\\)\\s-+\\(\\sw+\\)" ) '(1 font-lock-keyword-face) - '(3 font-lock-reference-face prepend) - ) + '(3 font-lock-reference-face prepend)) '("\\\\s-+\\(\\[[^]]+\\]\\)\\s-+\\(\\sw+\\)" (1 font-lock-keyword-face) - (2 font-lock-reference-face append) - ) + (2 font-lock-reference-face append)) '("\\\\s-+\\(\\sw+\\)" - 1 'font-lock-reference-face append) - ))) + 1 'font-lock-reference-face append)))) (setq verilog-font-lock-keywords-2 (append verilog-font-lock-keywords-1 @@ -2002,7 +2045,6 @@ See also `verilog-font-lock-extra-types'.") 0 font-lock-type-face append) ;; Fontify instantiation names '("\\([A-Za-z][A-Za-z0-9_]+\\)\\s-*(" 1 font-lock-function-name-face) - ))) (setq verilog-font-lock-keywords-3 @@ -2015,15 +2057,14 @@ See also `verilog-font-lock-extra-types'.") ))))) - (defun verilog-inside-comment-p () "Check if point inside a nested comment." (save-excursion (let ((st-point (point)) hitbeg) (or (search-backward "//" (verilog-get-beg-of-line) t) (if (progn - ;; This is for tricky case //*, we keep searching if /* is - ;; proceeded by // on same line. + ;; This is for tricky case //*, we keep searching if /* + ;; is proceeded by // on same line. (while (and (setq hitbeg (search-backward "/*" nil t)) (progn @@ -2048,14 +2089,14 @@ Use filename, if current buffer being edited shorten to just buffer name." "Move backward over a sexp." (interactive) ;; before that see if we are in a comment - (verilog-backward-sexp) -) + (verilog-backward-sexp)) + (defun electric-verilog-forward-sexp () "Move backward over a sexp." (interactive) ;; before that see if we are in a comment - (verilog-forward-sexp) -) + (verilog-forward-sexp)) + ;;;used by hs-minor-mode (defun verilog-forward-sexp-function (arg) (if (< arg 0) @@ -2067,19 +2108,16 @@ Use filename, if current buffer being edited shorten to just buffer name." (let ((reg) (elsec 1) (found nil) - (st (point)) - ) + (st (point))) (if (not (looking-at "\\<")) (forward-word -1)) (cond - ((verilog-skip-backward-comment-or-string) - ) + ((verilog-skip-backward-comment-or-string)) ((looking-at "\\") (setq reg (concat verilog-end-block-re "\\|\\(\\\\)" - "\\|\\(\\\\)" - )) + "\\|\\(\\\\)")) (while (and (not found) (verilog-re-search-backward reg nil 'move)) (cond @@ -2094,11 +2132,7 @@ Use filename, if current buffer being edited shorten to just buffer name." (setq elsec (1- elsec)) (if (= 0 elsec) ;; Now previous line describes syntax - (setq found 't) - )) - ) - ) - ) + (setq found 't)))))) ((looking-at verilog-end-block-re) (verilog-leap-to-head)) ((looking-at "\\(endmodule\\>\\)\\|\\(\\\\)\\|\\(\\\\)\\|\\(\\\\)\\|\\(\\\\)\\|\\(\\\\)") @@ -2120,9 +2154,7 @@ Use filename, if current buffer being edited shorten to just buffer name." (backward-sexp 1)))) (t (goto-char st) - (backward-sexp)) - ) ;; cond - )) + (backward-sexp))))) (defun verilog-forward-sexp () (let ((reg) @@ -2132,8 +2164,7 @@ Use filename, if current buffer being edited shorten to just buffer name." (forward-word -1)) (cond ((verilog-skip-forward-comment-or-string) - (verilog-forward-syntactic-ws) - ) + (verilog-forward-syntactic-ws)) ((looking-at verilog-beg-block-re-ordered);; begin|case|fork|class|table|specify|function|task|generate|covergroup|property|sequence|clocking (cond ((match-end 1) ; end @@ -2141,8 +2172,7 @@ Use filename, if current buffer being edited shorten to just buffer name." (setq reg "\\(\\\\)\\|\\(\\\\)" )) ((match-end 2) ; endcase ;; Search forward for matching case - (setq reg "\\(\\\\|\\(\\\\s-+\\|\\\\s-+\\)?\\[^:]\\)\\|\\(\\\\)" ) - ) + (setq reg "\\(\\\\|\\(\\\\s-+\\|\\\\s-+\\)?\\[^:]\\)\\|\\(\\\\)" )) ((match-end 3) ; join ;; Search forward for matching fork (setq reg "\\(\\\\)\\|\\(\\\\)" )) @@ -2173,12 +2203,10 @@ Use filename, if current buffer being edited shorten to just buffer name." ((match-end 12) ; endsequence ;; Search forward for matching sequence (setq reg "\\(\\<\\(rand\\)?sequence\\>\\)\\|\\(\\\\)" ) - (setq md 3) ; 3 to get to endsequence in the reg above - ) + (setq md 3)) ; 3 to get to endsequence in the reg above ((match-end 13) ; endclocking ;; Search forward for matching clocking - (setq reg "\\(\\\\)\\|\\(\\\\)" )) - ) + (setq reg "\\(\\\\)\\|\\(\\\\)" ))) (if (forward-word 1) (catch 'skip (let ((nest 1)) @@ -2189,9 +2217,7 @@ Use filename, if current buffer being edited shorten to just buffer name." (if (= 0 nest) ; we are out! (throw 'skip 1))) ((match-end 1) ; the opener in reg, so we are deeper now - (setq nest (1+ nest))))) - ))) - ) + (setq nest (1+ nest))))))))) ((looking-at (concat "\\(\\<\\(macro\\)?module\\>\\)\\|" "\\(\\\\)\\|" @@ -2221,9 +2247,7 @@ Use filename, if current buffer being edited shorten to just buffer name." (goto-char st) (if (= (following-char) ?\) ) (forward-char 1) - (forward-sexp 1))) - ) ;; cond - )) + (forward-sexp 1)))))) (defun verilog-declaration-beg () (verilog-re-search-backward verilog-declaration-re (bobp) t)) @@ -2238,8 +2262,7 @@ Use filename, if current buffer being edited shorten to just buffer name." (list ;; Fontify things in translate off regions '(verilog-match-translate-off - (0 'verilog-font-lock-translate-off-face prepend)) - )))) + (0 'verilog-font-lock-translate-off-face prepend)))))) (put 'verilog-mode 'font-lock-defaults '((verilog-font-lock-keywords verilog-font-lock-keywords-1 @@ -2253,23 +2276,7 @@ Use filename, if current buffer being edited shorten to just buffer name." ;; initialize fontification for Verilog Mode (verilog-font-lock-init) -;; start up message -(defconst verilog-startup-message-lines - '("Please use \\[verilog-submit-bug-report] to report bugs." - "Visit http://www.verilog.com to check for updates" - )) -(defvar verilog-startup-message-displayed t) -(defun verilog-display-startup-message () - (if (not verilog-startup-message-displayed) - (if (sit-for 5) - (let ((lines verilog-startup-message-lines)) - (message "verilog-mode version %s, released %s; type \\[describe-mode] for help" - verilog-mode-version verilog-mode-release-date) - (setq verilog-startup-message-displayed t) - (while (and (sit-for 4) lines) - (message (substitute-command-keys (car lines))) - (setq lines (cdr lines))))) - (message ""))) + ;; ;; ;; Mode @@ -2411,9 +2418,9 @@ Key bindings specific to `verilog-mode-map' are: (setq local-abbrev-table verilog-mode-abbrev-table) (setq verilog-mode-syntax-table (make-syntax-table)) (verilog-populate-syntax-table verilog-mode-syntax-table) - (set (make-local-variable 'beginning-of-defun-function) + (set (make-local-variable 'beginning-of-defun-function) 'verilog-beg-of-defun) - (set (make-local-variable 'end-of-defun-function) + (set (make-local-variable 'end-of-defun-function) 'verilog-end-of-defun) ;; add extra comment syntax (verilog-setup-dual-comments verilog-mode-syntax-table) @@ -2444,8 +2451,8 @@ Key bindings specific to `verilog-mode-map' are: (not (assoc "Verilog" current-menubar))) ;; (set-buffer-menubar (copy-sequence current-menubar)) (add-submenu nil verilog-xemacs-menu) - (add-submenu nil verilog-stmt-menu) - )) + (add-submenu nil verilog-stmt-menu))) + ;; Stuff for GNU emacs (set (make-local-variable 'font-lock-defaults) '((verilog-font-lock-keywords verilog-font-lock-keywords-1 @@ -2472,8 +2479,6 @@ Key bindings specific to `verilog-mode-map' are: (cons '(verilog-mode-mode "\\" "\\" nil verilog-forward-sexp-function) hs-special-modes-alist))) - ;; Display version splash information. - (verilog-display-startup-message) ;; Stuff for autos (add-hook 'write-contents-hooks 'verilog-auto-save-check) ; already local @@ -2527,27 +2532,19 @@ With optional ARG, remove existing end of line comments." (progn (end-of-line) (delete-horizontal-space) - 't - ) - ) - ) + 't))) ;; see if we should line up assignments (progn (if (or (memq 'all verilog-auto-lineup) (memq 'assignments verilog-auto-lineup)) - (verilog-pretty-expr) - ) - (newline) - ) - (forward-line 1) - ) + (verilog-pretty-expr)) + (newline)) + (forward-line 1)) ;; Indent next line (if verilog-auto-indent-on-newline - (verilog-indent-line)) - ) + (verilog-indent-line))) (t - (newline)) - ))) + (newline))))) (defun electric-verilog-terminate-and-indent () "Insert a newline and indent for the next statement." @@ -2565,8 +2562,7 @@ With optional ARG, remove existing end of line comments." (save-excursion (beginning-of-line) (verilog-forward-ws&directives) - (verilog-indent-line) - ) + (verilog-indent-line)) (if (and verilog-auto-newline (not (verilog-parenthesis-depth))) (electric-verilog-terminate-line)))) @@ -2648,9 +2644,7 @@ With optional ARG, remove existing end of line comments." (re-search-forward comment-start-skip oldpnt 'move) (goto-char (match-beginning 0)) (skip-chars-backward " \t") - (kill-region (point) oldpnt) - )))) - ) + (kill-region (point) oldpnt)))))) (progn (insert "\t")))) @@ -2690,7 +2684,7 @@ To call this from the command line, see \\[verilog-batch-indent]." (insert " * ")) (defun verilog-insert-1 (fmt max) - "Insert integers 0 to MAX-1 according to format string FMT. + "Use format string FMT to insert integers 0 to MAX - 1. Inserts one integer per line, at the current column. Stops early if it reaches the end of the buffer." (let ((col (current-column)) @@ -2724,7 +2718,7 @@ located after the first 'a' gives: a = b a[ 7] = b a = b a[ 8] = b" - (interactive "NMAX? ") + (interactive "NMAX: ") (verilog-insert-1 "[%3d]" max)) (defun verilog-generate-numbers (max) @@ -2744,7 +2738,7 @@ following code fragment: buf buf buf buf007 buf buf buf buf008" - (interactive "NMAX? ") + (interactive "NMAX: ") (verilog-insert-1 "%3.3d" max)) (defun verilog-mark-defun () @@ -2792,8 +2786,7 @@ The commented area starts with `verilog-exclude-str-start', and ends with (save-excursion (let ((s+1 (1+ start))) (while (re-search-backward "/\\*" s+1 t) - (replace-match "/-*" t t)))) - )) + (replace-match "/-*" t t)))))) (defun verilog-uncomment-region () "Uncomment a commented area; change deformed comments back to normal. @@ -2869,8 +2862,7 @@ With ARG, first kill any existing labels." (point-marker))) (e (progn (verilog-end-of-defun) - (point-marker))) - ) + (point-marker)))) (goto-char (marker-position b)) (if (> (- e b) 200) (message "Relabeling module...")) @@ -2885,18 +2877,15 @@ With ARG, first kill any existing labels." (let ((indent-str (verilog-indent-line))) (verilog-set-auto-endcomments indent-str 't) (end-of-line) - (delete-horizontal-space) - ) + (delete-horizontal-space)) (setq cnt (1+ cnt)) (if (= 9 (% cnt 10)) - (message "%d..." cnt)) - ) + (message "%d..." cnt))) (goto-char oldpos) (if (or (> (- e b) 200) (> cnt 20)) - (message "%d lines auto commented" cnt)) - )) + (message "%d lines auto commented" cnt)))) (defun verilog-beg-of-statement () "Move backward to beginning of statement." @@ -2919,15 +2908,13 @@ With ARG, first kill any existing labels." (looking-at verilog-extended-complete-re) (not (save-excursion (verilog-backward-token) - (looking-at verilog-extended-complete-re))) - ) + (looking-at verilog-extended-complete-re)))) (looking-at verilog-basic-complete-re) (save-excursion (verilog-backward-token) (or (looking-at verilog-end-block-re) - (looking-at verilog-preprocessor-re))) - )) + (looking-at verilog-preprocessor-re))))) (verilog-backward-syntactic-ws) (verilog-backward-token)) ;; Now point is where the previous line ended. @@ -3011,9 +2998,9 @@ more specifically, point @ in the line foo : @ begin" (throw 'found 1)) (setq nest (1- nest))) (t - (throw 'found (= nest 0))) - )))) + (throw 'found (= nest 0))))))) nil))) + (defun verilog-in-struct-region-p () "Return TRUE if in a struct region; more specifically, in a list after a struct|union keyword" @@ -3024,20 +3011,14 @@ more specifically, in a list after a struct|union keyword" (if depth (progn (backward-up-list depth) (verilog-beg-of-statement) - (looking-at "\\?\\s-*\\") - ) - ) - ) - ) - ) + (looking-at "\\?\\s-*\\")))))) (defun verilog-in-generate-region-p () "Return TRUE if in a generate region; more specifically, after a generate and before an endgenerate" (interactive) (let ((lim (save-excursion (verilog-beg-of-defun) (point))) - (nest 1) - ) + (nest 1)) (save-excursion (while (and (/= nest 0) @@ -3046,17 +3027,14 @@ more specifically, after a generate and before an endgenerate" ((match-end 1) ; generate (setq nest (1- nest))) ((match-end 2) ; endgenerate - (setq nest (1+ nest))) - )) - )) + (setq nest (1+ nest))))))) (= nest 0) )) ; return nest (defun verilog-in-fork-region-p () "Return true if between a fork and join." (interactive) (let ((lim (save-excursion (verilog-beg-of-defun) (point))) - (nest 1) - ) + (nest 1)) (save-excursion (while (and (/= nest 0) @@ -3065,9 +3043,7 @@ more specifically, after a generate and before an endgenerate" ((match-end 1) ; fork (setq nest (1- nest))) ((match-end 2) ; join - (setq nest (1+ nest))) - )) - )) + (setq nest (1+ nest))))))) (= nest 0) )) ; return nest (defun verilog-backward-case-item (lim) @@ -3099,8 +3075,7 @@ Limit search to point LIM." (setq colon (1- colon))) ((match-end 3) ;; : - (setq colon (1+ colon))) - )) + (setq colon (1+ colon))))) ;; Skip back to beginning of case item (skip-chars-backward "\t ") (verilog-skip-backward-comment-or-string) @@ -3123,10 +3098,8 @@ Limit search to point LIM." (t (goto-char (match-end 0)) (verilog-forward-ws&directives) - (point)) - )) - (error "Malformed case item") - ))) + (point)))) + (error "Malformed case item")))) (setq str (buffer-substring b e)) (if (setq e @@ -3178,8 +3151,7 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter (search-backward "//" (verilog-get-beg-of-line) t))))) (let ((nest 1) b e m - (else (if (match-end 2) "!" " ")) - ) + (else (if (match-end 2) "!" " "))) (end-of-line) (if kill-existing-comment (verilog-kill-existing-comment)) @@ -3199,8 +3171,7 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter ((match-end 4) ; `ifdef (setq nest (1- nest))) ((match-end 5) ; `ifndef - (setq nest (1- nest))) - )) + (setq nest (1- nest))))) (if (match-end 0) (setq m (buffer-substring @@ -3212,15 +3183,13 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter (point)) e (progn (skip-chars-forward "a-zA-Z0-9_") - (point) - )))) + (point))))) (if b (if (> (count-lines (point) b) verilog-minimum-comment-distance) (insert (concat " // " else m " " (buffer-substring b e)))) (progn (insert " // unmatched `else or `endif") - (ding 't)) - ))) + (ding 't))))) (; Comment close case/class/function/task/module and named block (and (looking-at "\\\\)\\|\\(\\\\)\\|\\(\\\\)") - ) + ( reg "\\(\\\\)\\|\\(\\\\)\\|\\(\\\\)")) (catch 'skip (while (verilog-re-search-backward reg nil 'move) (cond @@ -3353,16 +3318,13 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter (setq err nil) (setq str (verilog-get-expr)) (setq str (concat " // else: !if" str )) - (throw 'skip 1)) - ))) - )))) + (throw 'skip 1))))))))) (;- end else (match-end 5) (goto-char there) (let ((nest 0) - ( reg "\\(\\\\)\\|\\(\\\\)\\|\\(\\\\)") - ) + (reg "\\(\\\\)\\|\\(\\\\)\\|\\(\\\\)")) (catch 'skip (while (verilog-re-search-backward reg nil 'move) (cond @@ -3378,9 +3340,7 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter (setq err nil) (setq str (verilog-get-expr)) (setq str (concat " // else: !if" str )) - (throw 'skip 1)) - ))) - )))) + (throw 'skip 1))))))))) (;- task/function/initial et cetera t @@ -3392,8 +3352,7 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter (setq str (concat " // " cntx str ))) (;-- otherwise... - (setq str " // auto-endcomment confused ")) - )) + (setq str " // auto-endcomment confused ")))) ((and (verilog-in-case-region-p) ;-- handle case item differently @@ -3431,9 +3390,8 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter (match-end 11) ;; of verilog-end-block-ordered-re ;;(goto-char there) (let ((nest 0) - ( reg "\\<\\(class\\)\\|\\(endclass\\)\\|\\(package\\|primitive\\|\\(macro\\)?module\\)\\>") - string - ) + (reg "\\<\\(class\\)\\|\\(endclass\\)\\|\\(package\\|primitive\\|\\(macro\\)?module\\)\\>") + string) (save-excursion (catch 'skip (while (verilog-re-search-backward reg nil 'move) @@ -3463,8 +3421,7 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter (throw 'skip 1)))) )))) (end-of-line) - (insert (concat " // " string ))) - ) + (insert (concat " // " string )))) (;- this is end{function,generate,task,module,primitive,table,generate} ;- which can not be nested. @@ -3479,8 +3436,7 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter (cond ((match-end 5) ;; of verilog-end-block-ordered-re (setq reg "\\(\\\\)\\|\\(\\<\\(endfunction\\|task\\|\\(macro\\)?module\\|primitive\\)\\>\\)") - (setq width "\\(\\s-*\\(\\[[^]]*\\]\\)\\|\\(real\\(time\\)?\\)\\|\\(integer\\)\\|\\(time\\)\\)?") - ) + (setq width "\\(\\s-*\\(\\[[^]]*\\]\\)\\|\\(real\\(time\\)?\\)\\|\\(integer\\)\\|\\(time\\)\\)?")) ((match-end 6) ;; of verilog-end-block-ordered-re (setq reg "\\(\\\\)\\|\\(\\<\\(endtask\\|function\\|\\(macro\\)?module\\|primitive\\)\\>\\)")) ((match-end 7) ;; of verilog-end-block-ordered-re @@ -3502,8 +3458,7 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter ((match-end 15) ;; of verilog-end-block-ordered-re (setq reg "\\(\\\\)\\|\\")) - (t (error "Problem in verilog-set-auto-endcomments")) - ) + (t (error "Problem in verilog-set-auto-endcomments"))) (let (b e) (save-excursion (verilog-re-search-backward reg nil 'move) @@ -3515,8 +3470,7 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter (if (and width (looking-at width)) (progn (goto-char (match-end 0)) - (verilog-forward-ws&directives) - )) + (verilog-forward-ws&directives))) (point)) e (progn (skip-chars-forward "a-zA-Z0-9_") @@ -3577,8 +3531,7 @@ Insert `// NAME ' if this line ends a function, task, module, primitive or inter b) ('t (skip-chars-forward "^: \t\n\f") - (point) - )))) + (point))))) (str (buffer-substring b e))) (if (setq e (string-match "[ \t]*\\(\\(\n\\)\\|\\(//\\)\\|\\(/\\*\\)\\)" str)) (setq str (concat (substring str 0 e) "..."))) @@ -3601,8 +3554,8 @@ Useful for creating tri's and other expanded fields." (concat "\\(.*\\)" (regexp-quote bra) "\\([0-9]*\\)\\(:[0-9]*\\|\\)\\(::[0-9---]*\\|\\)" - (regexp-quote ket) - "\\(.*\\)$") signal-string) + (regexp-quote ket) + "\\(.*\\)$") signal-string) (let* ((sig-head (match-string 1 signal-string)) (vec-start (string-to-number (match-string 2 signal-string))) (vec-end (if (= (match-beginning 3) (match-end 3)) @@ -3765,8 +3718,7 @@ becomes: ))) ((verilog-in-star-comment-p) (re-search-backward "/\*") - (insert (format " // surefire lint_off_line %6s" code )) - ) + (insert (format " // surefire lint_off_line %6s" code ))) (t (insert (format " // surefire lint_off_line %6s" code )) ))))))))) @@ -3823,11 +3775,11 @@ This lets programs calling batch mode to easily extract error messages." (setq default-major-mode `verilog-mode) ;; Ditto files already read in (mapc (lambda (buf) - (when (buffer-file-name buf) - (save-excursion - (set-buffer buf) - (verilog-mode)))) - (buffer-list)) + (when (buffer-file-name buf) + (save-excursion + (set-buffer buf) + (verilog-mode)))) + (buffer-list)) ;; Process the files (mapcar '(lambda (buf) (when (buffer-file-name buf) @@ -3943,8 +3895,7 @@ type. Return a list of two elements: (INDENT-TYPE INDENT-LEVEL)." (not (verilog-in-coverage)) (verilog-in-paren)) (progn (setq par 1) - (throw 'nesting 'block)) - ) + (throw 'nesting 'block))) ;; See if we are continuing a previous line (while t @@ -4026,8 +3977,7 @@ type. Return a list of two elements: (INDENT-TYPE INDENT-LEVEL)." (setq reg "\\(\\\\)\\|\\(\\\\)" )) ((match-end 12) ; covergroup ;; Search back for matching covergroup - (setq reg "\\(\\\\)\\|\\(\\\\)" )) - ) + (setq reg "\\(\\\\)\\|\\(\\\\)" ))) (catch 'skip (while (verilog-re-search-backward reg nil 'move) (cond @@ -4037,11 +3987,8 @@ type. Return a list of two elements: (INDENT-TYPE INDENT-LEVEL)." (throw 'skip 1))) ((match-end 2) ; end (setq nest (1+ nest))))) - ) - )) - )))) - (throw 'nesting (verilog-calc-1)) - ) + ))))))) + (throw 'nesting (verilog-calc-1))) );; catch nesting );; type ) @@ -4058,8 +4005,8 @@ type. Return a list of two elements: (INDENT-TYPE INDENT-LEVEL)." ((eq type 'defun) (list type 0)) (t - (list type (verilog-current-indent-level))))) - ))) + (list type (verilog-current-indent-level)))))))) + (defun verilog-wai () "Show matching nesting block for debugging." (interactive) @@ -4073,8 +4020,7 @@ type. Return a list of two elements: (INDENT-TYPE INDENT-LEVEL)." (cond ((equal (char-after) ?\{) (if (verilog-at-constraint-p) - (throw 'nesting 'block) - )) + (throw 'nesting 'block))) ((equal (char-after) ?\}) (let ((there (verilog-at-close-constraint-p))) @@ -4133,8 +4079,7 @@ type. Return a list of two elements: (INDENT-TYPE INDENT-LEVEL)." For speed, the searcher looks at the last directive, not the indent of the appropriate enclosing block." (let ((base -1) ;; Indent of the line that determines our indentation - (ind 0) ;; Relative offset caused by other directives (like `endif on same line as `else) - ) + (ind 0)) ;; Relative offset caused by other directives (like `endif on same line as `else) ;; Start at current location, scan back for another directive (save-excursion @@ -4142,8 +4087,7 @@ of the appropriate enclosing block." (while (and (< base 0) (verilog-re-search-backward verilog-directive-re nil t)) (cond ((save-excursion (skip-chars-backward " \t") (bolp)) - (setq base (current-indentation)) - )) + (setq base (current-indentation)))) (cond ((and (looking-at verilog-directive-end) (< base 0)) ;; Only matters when not at BOL (setq ind (- ind verilog-indent-level-directive))) ((and (looking-at verilog-directive-middle) (>= base 0)) ;; Only matters when at BOL @@ -4223,8 +4167,7 @@ from endcase to matching case, and so on." (setq reg "\\(\\<\\(rand\\)?sequence\\>\\)\\|\\(\\\\)" )) ((looking-at "\\") ;; 12: Search back for matching clocking - (setq reg "\\(\\\\)" )) - ) + (setq reg "\\(\\\\)" ))) (if reg (catch 'skip (let (sreg) @@ -4268,9 +4211,7 @@ Set point to where line starts" (save-excursion (skip-chars-backward " \t") (not (bolp)))) - (setq continued (verilog-backward-token)) - ) ;; while - )) + (setq continued (verilog-backward-token))))) (setq continued nil)) continued)) @@ -4289,15 +4230,13 @@ Set point to where line starts" (= (preceding-char) ?\}) (progn (backward-char) - (verilog-at-close-constraint-p)) - ) + (verilog-at-close-constraint-p))) (;-- constraint foo { a = b } ; is a complete statement. *sigh* (= (preceding-char) ?\{) (progn (backward-char) - (not (verilog-at-constraint-p))) - ) + (not (verilog-at-constraint-p)))) (;-- Could be 'case (foo)' or 'always @(bar)' which is complete ; also could be simply '@(foo)' ; or foo u1 #(a=8) @@ -4322,10 +4261,8 @@ Set point to where line starts" (verilog-backward-token) (not (looking-at "\\<\\(always\\(_latch\\|_ff\\|_comb\\)?\\|initial\\|while\\)\\>")))) ((= (preceding-char) ?\#) - (backward-char) - ) - (t t)) - ))))) + (backward-char)) + (t t))))))) (;-- any of begin|initial|while are complete statements; 'begin : foo' is also complete t @@ -4346,8 +4283,7 @@ Set point to where line starts" (backward-sexp) (if (looking-at verilog-nameable-item-re ) nil - t) - ) + t)) ((= (preceding-char) ?\#) (backward-char) t) @@ -4357,8 +4293,7 @@ Set point to where line starts" (t (goto-char back) - t) - ))))))) + t)))))))) (defun verilog-backward-syntactic-ws (&optional bound) "Backward skip over syntactic whitespace for Emacs 19. @@ -4370,9 +4305,7 @@ Optional BOUND limits search." (narrow-to-region bound (point)) (while (/= here (point)) (setq here (point)) - (verilog-skip-backward-comments) - ))) - )) + (verilog-skip-backward-comments)))))) t) (defun verilog-forward-syntactic-ws (&optional bound) @@ -4380,16 +4313,13 @@ Optional BOUND limits search." Optional BOUND limits search." (save-restriction (let* ((bound (or bound (point-max))) - (here bound) - ) + (here bound)) (if (> bound (point)) (progn (narrow-to-region (point) bound) (while (/= here (point)) (setq here (point)) - (forward-comment (buffer-size)) - ))) - ))) + (forward-comment (buffer-size)))))))) (defun verilog-backward-ws&directives (&optional bound) "Backward skip over syntactic whitespace and compiler directives for Emacs 19. @@ -4423,9 +4353,7 @@ Optional BOUND limits search." (point)) (t nil)))) - (if p (goto-char p)) - ))) - ))) + (if p (goto-char p)))))))) (defun verilog-forward-ws&directives (&optional bound) "Forward skip over syntactic whitespace and compiler directives for Emacs 19. @@ -4433,8 +4361,7 @@ Optional BOUND limits search." (save-restriction (let* ((bound (or bound (point-max))) (here bound) - jump - ) + jump) (if (> bound (point)) (progn (let ((state @@ -4455,9 +4382,7 @@ Optional BOUND limits search." (if (looking-at verilog-directive-re-1) (setq jump t))) (if jump - (beginning-of-line 2)) - ))) - ))) + (beginning-of-line 2)))))))) (defun verilog-in-comment-p () "Return true if in a star or // comment." @@ -4537,14 +4462,11 @@ Optional BOUND limits search." (forward-list) (progn (backward-char 1) (verilog-backward-ws&directives) - (equal (char-before) ?\;)) - )) + (equal (char-before) ?\;)))) ;; maybe (verilog-re-search-backward "\\" nil 'move) ;; not - nil - ) - ) + nil)) (defun verilog-parenthesis-depth () "Return non zero if in parenthetical-expression." @@ -4608,8 +4530,7 @@ Optional BOUND limits search." t) ((and (not (bobp)) (= (char-before) ?\/) - (= (char-before (1- (point))) ?\*) - ) + (= (char-before (1- (point))) ?\*)) (goto-char (- (point) 2)) t) (t @@ -4650,8 +4571,8 @@ Only look at a few lines to determine indent level." (if (verilog-continued-line) (progn (goto-char sp) - (setq - indent-str (list 'statement (verilog-current-indent-level)))) + (setq indent-str + (list 'statement (verilog-current-indent-level)))) (goto-char sp1) (setq indent-str (list 'block (verilog-current-indent-level))))) (goto-char sp)) @@ -4701,16 +4622,13 @@ Only look at a few lines to determine indent level." (progn (forward-char 1) (backward-up-list -1) - (skip-chars-forward " \t"))) - ) + (skip-chars-forward " \t")))) (current-column)) (progn (goto-char fst) - (+ (current-column) verilog-cexp-indent)) - )))) + (+ (current-column) verilog-cexp-indent)))))) (goto-char here) - (indent-line-to val)) - ) + (indent-line-to val))) ((= (preceding-char) ?\) ) (goto-char here) (let ((val (eval (cdr (assoc type verilog-indent-alist))))) @@ -4724,8 +4642,7 @@ Only look at a few lines to determine indent level." (setq val (current-column)) (setq val (eval (cdr (assoc type verilog-indent-alist))))) (goto-char here) - (indent-line-to val))) - ))) + (indent-line-to val)))))) (; handle inside parenthetical expressions (eq type 'cparenexp) @@ -4737,8 +4654,7 @@ Only look at a few lines to determine indent level." (indent-line-to val) (if (and (not (verilog-in-struct-region-p)) (looking-at verilog-declaration-re)) - (verilog-indent-declaration ind)) - )) + (verilog-indent-declaration ind)))) (;-- Handle the ends (or @@ -4774,8 +4690,8 @@ Only look at a few lines to determine indent level." (;-- Everything else t (let ((val (eval (cdr (assoc type verilog-indent-alist))))) - (indent-line-to val))) - ) + (indent-line-to val)))) + (if (looking-at "[ \t]+$") (skip-chars-forward " \t")) indent-str ; Return indent data @@ -4823,8 +4739,7 @@ Do not count named blocks or case-statements." (t (save-excursion (re-search-backward "//" nil t) - (current-column))) - ))) + (current-column)))))) (indent-line-to stcol) stcol)) @@ -4843,8 +4758,7 @@ Do not count named blocks or case-statements." (t (save-excursion (re-search-backward "//" nil t) - (current-column))) - ))) + (current-column)))))) (progn (indent-to stcol) (if (and star @@ -4912,8 +4826,7 @@ ARG is ignored, for `comment-indent-function' compatibility." (goto-char start) (verilog-do-indent (verilog-calculate-indent)) (verilog-forward-ws&directives) - (current-column))) - ) + (current-column)))) (goto-char end) (goto-char start) (if (> (- end start) 100) @@ -4927,15 +4840,12 @@ ARG is ignored, for `comment-indent-function' compatibility." (verilog-forward-ws&directives) (indent-line-to base-ind) (verilog-forward-ws&directives) - (verilog-re-search-forward "[ \t\n\f]" e 'move) - ) + (verilog-re-search-forward "[ \t\n\f]" e 'move)) (t (just-one-space) - (verilog-re-search-forward "[ \t\n\f]" e 'move) - ) - ) + (verilog-re-search-forward "[ \t\n\f]" e 'move))) + ;;(forward-line) ) - ;;(forward-line)) ;; Now find biggest prefix (setq ind (verilog-get-lineup-indent start edpos)) ;; Now indent each line. @@ -4960,21 +4870,19 @@ ARG is ignored, for `comment-indent-function' compatibility." (indent-to ind)) (progn (just-one-space) - (indent-to ind)) - ))) + (indent-to ind))))) ((verilog-continued-line-1 start) (goto-char e) (indent-line-to ind)) (t ; Must be comment or white space (goto-char e) (verilog-forward-ws&directives) - (forward-line -1)) - ) + (forward-line -1))) (forward-line 1)) (message ""))))) (defun verilog-pretty-expr (&optional myre) - "Line up expressions around point." + "Line up expressions around point, or optional regexp MYRE." (interactive "sRegular Expression: ((<|:)?=) ") (save-excursion (if (or (eq myre nil) @@ -4995,8 +4903,7 @@ ARG is ignored, for `comment-indent-function' compatibility." (beginning-of-line) (while (and (not (looking-at (concat "^\\s-*" verilog-complete-reg))) (looking-at myre) - (not (bobp)) - ) + (not (bobp))) (setq e (point)) (verilog-backward-syntactic-ws) (beginning-of-line) @@ -5015,12 +4922,10 @@ ARG is ignored, for `comment-indent-function' compatibility." (end-of-line) (setq e (point)) (verilog-forward-syntactic-ws) - (beginning-of-line) - ) + (beginning-of-line)) e)) (edpos (set-marker (make-marker) end)) - (ind) - ) + (ind)) (goto-char start) (verilog-do-indent (verilog-calculate-indent)) (if (> (- end start) 100) @@ -5031,8 +4936,7 @@ ARG is ignored, for `comment-indent-function' compatibility." (beginning-of-line) (verilog-just-one-space myre) (end-of-line) - (verilog-forward-syntactic-ws) - ) + (verilog-forward-syntactic-ws)) ;; Now find biggest prefix (setq ind (verilog-get-lineup-indent-2 myre start edpos)) @@ -5049,20 +4953,16 @@ ARG is ignored, for `comment-indent-function' compatibility." (goto-char (match-end 1)) (if (eq (char-after) ?=) (indent-to (1+ ind)) ; line up the = of the <= with surrounding = - (indent-to ind) - ) - ) + (indent-to ind))) ((verilog-continued-line-1 start) (goto-char e) (indent-line-to ind)) (t ; Must be comment or white space (goto-char e) (verilog-forward-ws&directives) - (forward-line -1)) - ) + (forward-line -1))) (forward-line 1)) - (message "") - )))) + (message ""))))) (defun verilog-just-one-space (myre) "Remove extra spaces around regular expression MYRE." @@ -5073,12 +4973,10 @@ ARG is ignored, for `comment-indent-function' compatibility." (p2 (match-end 2))) (progn (goto-char p2) - (if (looking-at "\\s-") (just-one-space) ) + (if (looking-at "\\s-") (just-one-space)) (goto-char p1) (forward-char -1) - (if (looking-at "\\s-") (just-one-space)) - ) - )) + (if (looking-at "\\s-") (just-one-space))))) (message "")) (defun verilog-indent-declaration (baseind) @@ -5093,8 +4991,7 @@ BASEIND is the base indent to offset everything." (point))) (ind) (val) - (m1 (make-marker)) - ) + (m1 (make-marker))) (setq val (+ baseind (eval (cdr (assoc 'declaration verilog-indent-alist))))) (indent-line-to val) @@ -5125,13 +5022,11 @@ BASEIND is the base indent to offset everything." (just-one-space) (goto-char (marker-position m1)) (just-one-space) - (indent-to ind) - ) + (indent-to ind)) (if (/= (current-column) ind) (progn (just-one-space) - (indent-to ind)) - ))) + (indent-to ind))))) (if (looking-at verilog-declaration-re-2-no-macro) (let ((p (match-end 0))) (set-marker m1 p) @@ -5362,11 +5257,8 @@ for matches of `str' and adding the occurrence tp `all' through point END." (if (or (null verilog-pred) (funcall verilog-pred match)) (setq verilog-all (cons match verilog-all))))) - (forward-line 1) - ) - ) - verilog-all - ) + (forward-line 1))) + verilog-all) (defun verilog-type-completion () "Calculate all possible completions for types." @@ -5663,8 +5555,7 @@ If search fails, other files are checked based on (goto-char pt) (beginning-of-line)) pt) - (verilog-goto-defun-file label) - ))) + (verilog-goto-defun-file label)))) ;; Eliminate compile warning (eval-when-compile @@ -5680,8 +5571,7 @@ If search fails, other files are checked based on (first 1) (prevpos (point-min)) (final-context-start (make-marker)) - (regexp "\\(module\\s-+\\w+\\s-*(\\)\\|\\(\\w+\\s-+\\w+\\s-*(\\)") - ) + (regexp "\\(module\\s-+\\w+\\s-*(\\)\\|\\(\\w+\\s-+\\w+\\s-*(\\)")) (with-output-to-temp-buffer "*Occur*" (save-excursion (message (format "Searching for %s ..." regexp)) @@ -5854,8 +5744,7 @@ Bound search by LIMIT. Adapted from (search-forward "") (replace-match string t t) (search-backward "") - (replace-match "" t t) - ))) + (replace-match "" t t)))) ;; verilog-header Uses the verilog-insert-date function @@ -5994,8 +5883,7 @@ Duplicate signals are also removed. For example A[2] and A[1] become A[2:1]." sv-type (verilog-sig-type sig) sv-multidim (verilog-sig-multidim sig) combo "" - buswarn "" - )) + buswarn "")) ;; Extract bus details (setq bus (verilog-sig-bits sig)) (cond ((and bus @@ -6043,16 +5931,15 @@ Duplicate signals are also removed. For example A[2] and A[1] become A[2:1]." (if sv-highbit (concat "[" (int-to-string sv-highbit) ":" (int-to-string sv-lowbit) "]"))) - (concat sv-comment combo buswarn) - sv-memory sv-enum sv-signed sv-type sv-multidim) - out-list) - sv-name nil))) - ) + (concat sv-comment combo buswarn) + sv-memory sv-enum sv-signed sv-type sv-multidim) + out-list) + sv-name nil)))) ;; out-list)) (defun verilog-sig-tieoff (sig &optional no-width) - "Return tieoff expression for given SIGNAL, with appropriate width. + "Return tieoff expression for given SIG, with appropriate width. Ignore width if optional NO-WIDTH is set." (let* ((width (if no-width nil (verilog-sig-width sig)))) (concat @@ -6189,8 +6076,7 @@ Return a array of [outputs inouts inputs wire reg assign const]." (forward-char 1) (when (< paren sig-paren) (setq expect-signal nil)) ; ) that ends variables inside v2k arg list - t) - ))) + t)))) ((looking-at "\\s-*\\(\\[[^]]+\\]\\)") (goto-char (match-end 0)) (cond (newsig ; Memory, not just width. Patch last signal added's memory (nth 3) @@ -6272,12 +6158,15 @@ Return a array of [outputs inouts inputs wire reg assign const]." (nreverse sigs-reg) (nreverse sigs-assign) (nreverse sigs-const) - (nreverse sigs-gparam) - )))) + (nreverse sigs-gparam))))) -(defvar sigs-in) ; Prevent compile warning -(defvar sigs-inout) ; Prevent compile warning -(defvar sigs-out) ; Prevent compile warning +(eval-when-compile + ;; Prevent compile warnings; these are let's, not globals + ;; Do not remove the eval-when-compile + ;; - we want a error when we are debugging this code if they are refed. + (defvar sigs-in) + (defvar sigs-inout) + (defvar sigs-out)) (defsubst verilog-modi-get-decls (modi) @@ -6524,10 +6413,16 @@ For example if declare A A (.B(SIG)) then B will be included in the list." (end-pt (point))) (eval-region beg-pt end-pt nil))))) -;; These are passed in a let, not global -(defvar got-sig) -(defvar got-rvalue) -(defvar uses-delayed) +(eval-when-compile + ;; Prevent compile warnings; these are let's, not globals + ;; Do not remove the eval-when-compile + ;; - we want a error when we are debugging this code if they are refed. + (defvar sigs-in) + (defvar sigs-out) + (defvar got-sig) + (defvar got-rvalue) + (defvar uses-delayed) + (defvar vector-skip-list)) (defun verilog-read-always-signals-recurse (exit-keywd rvalue ignore-next) @@ -6653,8 +6548,7 @@ IGNORE-NEXT is true to ignore next token, fake from inside case statement." (t (forward-char 1))) ;; End of non-comment token - (setq last-keywd keywd) - )) + (setq last-keywd keywd))) (skip-syntax-forward " ")) ;; Append the final pending signal (when got-sig @@ -6700,8 +6594,7 @@ IGNORE-NEXT is true to ignore next token, fake from inside case statement." (instant (match-string 2))) (if (not (member module verilog-keywords)) (setq instants-list (cons (list module instant) instants-list))))) - (forward-line 1) - )) + (forward-line 1))) instants-list)) @@ -6776,8 +6669,7 @@ list of ( (signal_name connection_name)... )" (t (error "%s: AUTO_TEMPLATE parsing error: %s" (verilog-point-text) - (progn (looking-at ".*$") (match-string 0)))) - )) + (progn (looking-at ".*$") (match-string 0)))))) ;; Return (vector tpl-regexp (list tpl-sig-list tpl-wild-list))) @@ -6799,8 +6691,7 @@ Optionally associate it with the specified enumeration ENUMNAME." (let ((enumvar (intern (concat "venum-" enumname)))) ;;(message "Define %s=%s" defname defvalue) (sleep-for 1) (make-variable-buffer-local enumvar) - (add-to-list enumvar defname))) - )) + (add-to-list enumvar defname))))) (defun verilog-read-defines (&optional filename recurse subcall) "Read `defines and parameters for the current file, or optional FILENAME. @@ -6884,8 +6775,7 @@ warning message, you need to add to your .emacs file: (while (looking-at "\\s-*,?\\s-*\\([a-zA-Z0-9_$]+\\)\\s-*=\\s-*\\([^;,]*\\),?\\s-*") (verilog-set-define (match-string-no-properties 1) (match-string-no-properties 2) origbuf enumname) (goto-char (match-end 0)) - (forward-comment 999)))) - ))) + (forward-comment 999))))))) (defun verilog-read-includes () "Read `includes for the current file. @@ -6950,8 +6840,7 @@ Some macros and such are also found and included. For dinotrace.el" (or (member keywd verilog-keywords) (member keywd sigs-all) (setq sigs-all (cons keywd sigs-all)))) - (t (forward-char 1))) - ) + (t (forward-char 1)))) ;; Return list sigs-all))) @@ -7019,10 +6908,7 @@ Some macros and such are also found and included. For dinotrace.el" ((string-match "^[^-+]" arg) (verilog-add-list-unique `verilog-library-files arg)) ;; Default - ignore; no warning - ) - ) - ) - ) + )))) ;;(verilog-getopt (list "+libext+.a+.b" "+incdir+foodir" "+define+a+aval" "-f" "otherf" "-v" "library" "-y" "dir")) (defun verilog-getopt-file (filename) @@ -7096,8 +6982,7 @@ Allows version control to check out the file if need be." "Return true if SYMBOL is number-like." (or (string-match "^[0-9 \t:]+$" symbol) (string-match "^[---]*[0-9]+$" symbol) - (string-match "^[0-9 \t]+'s?[hdxbo][0-9a-fA-F_xz? \t]*$" symbol) - )) + (string-match "^[0-9 \t]+'s?[hdxbo][0-9a-fA-F_xz? \t]*$" symbol))) (defun verilog-symbol-detick (symbol wing-it) "Return a expanded SYMBOL name without any defines. @@ -7185,13 +7070,11 @@ Or, just the existing dirnames themselves if there are no wildcards." (setq dirfile (expand-file-name (concat (car dirfiles) rest)) dirfiles (cdr dirfiles)) (if (file-directory-p dirfile) - (setq dirlist (cons dirfile dirlist)))) - ) + (setq dirlist (cons dirfile dirlist))))) ;; Defaults (t (if (file-directory-p dirname) - (setq dirlist (cons dirname dirlist)))) - )) + (setq dirlist (cons dirname dirlist)))))) dirlist)) ;;(verilog-expand-dirnames (list "." ".." "nonexist" "../*" "/home/wsnyder/*/v")) @@ -7295,13 +7178,11 @@ Return modi if successful, else print message unless IGNORE-ERROR is true." "") "\n Check the verilog-library-directories variable." "\n I looked in (if not listed, doesn't exist):\n\t" - (mapconcat 'concat orig-filenames "\n\t"))))) - ) + (mapconcat 'concat orig-filenames "\n\t")))))) (setq verilog-modi-lookup-last-mod module verilog-modi-lookup-last-current current verilog-modi-lookup-last-tick (buffer-modified-tick))))) - verilog-modi-lookup-last-modi - )) + verilog-modi-lookup-last-modi)) (defsubst verilog-modi-name (modi) (aref modi 0)) @@ -7370,8 +7251,7 @@ Cache the output of function so next call may have faster access." (buffer-modified-tick) (visited-file-modtime) func-returns) - verilog-modi-cache-list))) - )) + verilog-modi-cache-list))))) ;; func-returns)) @@ -7483,7 +7363,7 @@ and invalidating the cache." (funcall func)))) (defun verilog-insert-one-definition (sig type indent-pt) - "Print out a definition for SIGNAL of the given TYPE, + "Print out a definition for SIG of the given TYPE, with appropriate INDENT-PT indentation." (indent-to indent-pt) (insert type) @@ -7594,9 +7474,8 @@ This repairs those mis-inserted by a AUTOARG." (string-to-number (match-string 2 range-exp))))))) ((string-match "^\\(.*\\)\\s *:\\s *\\(.*\\)\\s *$" range-exp) (concat "(1+(" (match-string 1 range-exp) ")" - (if (equal "0" (match-string 2 range-exp)) - ;; Don't bother with -(0) - "" + (if (equal "0" (match-string 2 range-exp)) + "" ;; Don't bother with -(0) (concat "-(" (match-string 2 range-exp) ")")) ")")) (t nil))))) @@ -7621,8 +7500,7 @@ This repairs those mis-inserted by a AUTOARG." ;; End exists (end-of-line) (delete-region pt (point)) - (forward-line 1)) - )) + (forward-line 1)))) (defun verilog-forward-close-paren () "Find the close parenthesis that match the current point, @@ -7897,8 +7775,7 @@ Typing \\[verilog-inject-auto] will make this into: (when (yes-or-no-p "AUTO statements not recomputed, do it now? ") (verilog-auto)) ;; Don't ask again if didn't update - (set (make-local-variable 'verilog-auto-update-tick) (buffer-modified-tick)) - )) + (set (make-local-variable 'verilog-auto-update-tick) (buffer-modified-tick)))) (when (not verilog-auto-star-save) (verilog-delete-auto-star-implicit)) nil) ;; Always return nil -- we don't write the file ourselves @@ -8008,13 +7885,11 @@ Avoid declaring ports manually, as it makes code harder to maintain." (verilog-repair-close-comma) (unless (eq (char-before) ?/ ) (insert "\n")) - (indent-to verilog-indent-level-declaration) - ))) + (indent-to verilog-indent-level-declaration)))) (defun verilog-auto-inst-port-map (port-st) nil) -(defvar vector-skip-list nil) ; Prevent compile warning (defvar vl-cell-type nil "See `verilog-auto-inst'.") ; Prevent compile warning (defvar vl-cell-name nil "See `verilog-auto-inst'.") ; Prevent compile warning (defvar vl-name nil "See `verilog-auto-inst'.") ; Prevent compile warning @@ -8025,7 +7900,8 @@ Avoid declaring ports manually, as it makes code harder to maintain." "Print out a instantiation connection for this PORT-ST. Insert to INDENT-PT, use template TPL-LIST. @ are instantiation numbers, replaced with TPL-NUM. -@\"(expression @)\" are evaluated, with @ as a variable." +@\"(expression @)\" are evaluated, with @ as a variable. +If FOR-STAR add comment it is a .* expansion." (let* ((port (verilog-sig-name port-st)) (tpl-ass (or (assoc port (car tpl-list)) (verilog-auto-inst-port-map port-st))) @@ -8072,13 +7948,11 @@ Insert to INDENT-PT, use template TPL-LIST. (prin1 (eval (car (read-from-string expr))) (lambda (ch) ()))))) (if (numberp value) (setq value (number-to-string value))) - value - )) + value)) (substring tpl-net (match-end 0)))))) ;; Replace @ and [] magic variables in final output (setq tpl-net (verilog-string-replace-matches "@" tpl-num nil nil tpl-net)) - (setq tpl-net (verilog-string-replace-matches "\\[\\]" vl-bits nil nil tpl-net)) - ) + (setq tpl-net (verilog-string-replace-matches "\\[\\]" vl-bits nil nil tpl-net))) (indent-to indent-pt) (insert "." port) (indent-to verilog-auto-inst-column) @@ -8462,9 +8336,7 @@ Lisp Templates: (if (search-forward ")" nil t) ;; From user, moved up a line (delete-backward-char 1)) (if (search-forward ";" nil t) ;; Don't error if user had syntax error and forgot it - (delete-backward-char 1)) - ))) - )))) + (delete-backward-char 1))))))))) (defun verilog-auto-inst-param () "Expand AUTOINSTPARAM statements, as part of \\[verilog-auto]. @@ -8566,9 +8438,7 @@ Templates: (search-forward "\n") ;; Added by inst-port (delete-backward-char 1) (if (search-forward ")" nil t) ;; From user, moved up a line - (delete-backward-char 1)) - ))) - )))) + (delete-backward-char 1))))))))) (defun verilog-auto-reg () "Expand AUTOREG statements, as part of \\[verilog-auto]. @@ -8612,15 +8482,13 @@ Typing \\[verilog-auto] will make this into: (verilog-modi-get-consts modi) (verilog-modi-get-gparams modi) (verilog-modi-get-sub-outputs modi) - (verilog-modi-get-sub-inouts modi) - )))) + (verilog-modi-get-sub-inouts modi))))) (forward-line 1) (when sig-list (verilog-insert-indent "// Beginning of automatic regs (for this module's undeclared outputs)\n") (verilog-insert-definition sig-list "reg" indent-pt nil) (verilog-modi-cache-add-regs modi sig-list) - (verilog-insert-indent "// End of automatics\n")) - ))) + (verilog-insert-indent "// End of automatics\n"))))) (defun verilog-auto-reg-input () "Expand AUTOREGINPUT statements, as part of \\[verilog-auto]. @@ -8665,15 +8533,13 @@ Typing \\[verilog-auto] will make this into: (verilog-signals-not-in (append (verilog-modi-get-sub-inputs modi) (verilog-modi-get-sub-inouts modi)) - (verilog-modi-get-signals modi) - )))) + (verilog-modi-get-signals modi))))) (forward-line 1) (when sig-list (verilog-insert-indent "// Beginning of automatic reg inputs (for undeclared instantiated-module inputs)\n") (verilog-insert-definition sig-list "reg" indent-pt nil) (verilog-modi-cache-add-regs modi sig-list) - (verilog-insert-indent "// End of automatics\n")) - ))) + (verilog-insert-indent "// End of automatics\n"))))) (defun verilog-auto-wire () "Expand AUTOWIRE statements, as part of \\[verilog-auto]. @@ -8726,8 +8592,7 @@ Typing \\[verilog-auto] will make this into: (verilog-signals-not-in (append (verilog-modi-get-sub-outputs modi) (verilog-modi-get-sub-inouts modi)) - (verilog-modi-get-signals modi) - )))) + (verilog-modi-get-signals modi))))) (forward-line 1) (when sig-list (verilog-insert-indent "// Beginning of automatic wires (for undeclared instantiated-module outputs)\n") @@ -8739,8 +8604,7 @@ Typing \\[verilog-auto] will make this into: (setq pnt (point)) (verilog-pretty-declarations) (goto-char pnt) - (verilog-pretty-expr "//"))) - ))) + (verilog-pretty-expr "//")))))) (defun verilog-auto-output () "Expand AUTOOUTPUT statements, as part of \\[verilog-auto]. @@ -8793,8 +8657,7 @@ Typing \\[verilog-auto] will make this into: (append (verilog-modi-get-outputs modi) (verilog-modi-get-inouts modi) (verilog-modi-get-sub-inputs modi) - (verilog-modi-get-sub-inouts modi) - )))) + (verilog-modi-get-sub-inouts modi))))) (setq sig-list (verilog-signals-not-matching-regexp sig-list verilog-auto-output-ignore-regexp)) (forward-line 1) @@ -8804,8 +8667,7 @@ Typing \\[verilog-auto] will make this into: (verilog-insert-definition sig-list "output" indent-pt v2k) (verilog-modi-cache-add-outputs modi sig-list) (verilog-insert-indent "// End of automatics\n")) - (when v2k (verilog-repair-close-comma)) - ))) + (when v2k (verilog-repair-close-comma))))) (defun verilog-auto-output-every () "Expand AUTOOUTPUTEVERY statements, as part of \\[verilog-auto]. @@ -8847,8 +8709,7 @@ Typing \\[verilog-auto] will make this into: (sig-list (verilog-signals-combine-bus (verilog-signals-not-in (verilog-modi-get-signals modi) - (verilog-modi-get-ports modi) - )))) + (verilog-modi-get-ports modi))))) (forward-line 1) (when v2k (verilog-repair-open-comma)) (when sig-list @@ -8856,8 +8717,7 @@ Typing \\[verilog-auto] will make this into: (verilog-insert-definition sig-list "output" indent-pt v2k) (verilog-modi-cache-add-outputs modi sig-list) (verilog-insert-indent "// End of automatics\n")) - (when v2k (verilog-repair-close-comma)) - ))) + (when v2k (verilog-repair-close-comma))))) (defun verilog-auto-input () "Expand AUTOINPUT statements, as part of \\[verilog-auto]. @@ -8913,8 +8773,7 @@ Typing \\[verilog-auto] will make this into: (verilog-modi-get-consts modi) (verilog-modi-get-gparams modi) (verilog-modi-get-sub-outputs modi) - (verilog-modi-get-sub-inouts modi) - )))) + (verilog-modi-get-sub-inouts modi))))) (setq sig-list (verilog-signals-not-matching-regexp sig-list verilog-auto-input-ignore-regexp)) (forward-line 1) @@ -8924,8 +8783,7 @@ Typing \\[verilog-auto] will make this into: (verilog-insert-definition sig-list "input" indent-pt v2k) (verilog-modi-cache-add-inputs modi sig-list) (verilog-insert-indent "// End of automatics\n")) - (when v2k (verilog-repair-close-comma)) - ))) + (when v2k (verilog-repair-close-comma))))) (defun verilog-auto-inout () "Expand AUTOINOUT statements, as part of \\[verilog-auto]. @@ -8978,8 +8836,7 @@ Typing \\[verilog-auto] will make this into: (verilog-modi-get-inouts modi) (verilog-modi-get-inputs modi) (verilog-modi-get-sub-inputs modi) - (verilog-modi-get-sub-outputs modi) - )))) + (verilog-modi-get-sub-outputs modi))))) (setq sig-list (verilog-signals-not-matching-regexp sig-list verilog-auto-inout-ignore-regexp)) (forward-line 1) @@ -8989,8 +8846,7 @@ Typing \\[verilog-auto] will make this into: (verilog-insert-definition sig-list "inout" indent-pt v2k) (verilog-modi-cache-add-inouts modi sig-list) (verilog-insert-indent "// End of automatics\n")) - (when v2k (verilog-repair-close-comma)) - ))) + (when v2k (verilog-repair-close-comma))))) (defun verilog-auto-inout-module () "Expand AUTOINOUTMODULE statements, as part of \\[verilog-auto]. @@ -9062,8 +8918,7 @@ Typing \\[verilog-auto] will make this into: (verilog-modi-cache-add-outputs modi sig-list-o) (verilog-modi-cache-add-inouts modi sig-list-io) (verilog-insert-indent "// End of automatics\n")) - (when v2k (verilog-repair-close-comma)) - ))))) + (when v2k (verilog-repair-close-comma))))))) (defun verilog-auto-sense-sigs (modi presense-sigs) "Return list of signals for current AUTOSENSE block." @@ -9164,8 +9019,7 @@ Typing \\[verilog-auto] will make this into: (not-first (insert " or "))) (insert (verilog-sig-name (car sig-list))) (setq sig-list (cdr sig-list) - not-first t)) - ))) + not-first t))))) (defun verilog-auto-reset () "Expand AUTORESET statements, as part of \\[verilog-auto]. @@ -9260,8 +9114,7 @@ Typing \\[verilog-auto] will make this into: ";\n") (indent-to indent-pt) (setq sig-list (cdr sig-list)))) - (insert "// End of automatics")) - ))) + (insert "// End of automatics"))))) (defun verilog-auto-tieoff () "Expand AUTOTIEOFF statements, as part of \\[verilog-auto]. @@ -9316,8 +9169,7 @@ Typing \\[verilog-auto] will make this into: (verilog-modi-get-consts modi) (verilog-modi-get-gparams modi) (verilog-modi-get-sub-outputs modi) - (verilog-modi-get-sub-inouts modi) - )))) + (verilog-modi-get-sub-inouts modi))))) (when sig-list (forward-line 1) (verilog-insert-indent "// Beginning of automatic tieoffs (for this module's unterminated outputs)\n") @@ -9330,8 +9182,7 @@ Typing \\[verilog-auto] will make this into: (insert "= " (verilog-sig-tieoff sig) ";\n") (setq sig-list (cdr sig-list)))) - (verilog-insert-indent "// End of automatics\n") - )))) + (verilog-insert-indent "// End of automatics\n"))))) (defun verilog-auto-unused () "Expand AUTOUNUSED statements, as part of \\[verilog-auto]. @@ -9395,8 +9246,7 @@ Typing \\[verilog-auto] will make this into: (append (verilog-modi-get-inputs modi) (verilog-modi-get-inouts modi)) (append (verilog-modi-get-sub-inputs modi) - (verilog-modi-get-sub-inouts modi) - )))) + (verilog-modi-get-sub-inouts modi))))) (setq sig-list (verilog-signals-not-matching-regexp sig-list verilog-auto-unused-ignore-regexp)) (when sig-list @@ -9408,8 +9258,7 @@ Typing \\[verilog-auto] will make this into: (indent-to indent-pt) (insert (verilog-sig-name sig) ",\n") (setq sig-list (cdr sig-list)))) - (verilog-insert-indent "// End of automatics\n") - )))) + (verilog-insert-indent "// End of automatics\n"))))) (defun verilog-enum-ascii (signm elim-regexp) "Convert a enum name SIGNM to a ascii string for insertion. @@ -9543,8 +9392,7 @@ Typing \\[verilog-auto] will make this into: (verilog-insert-indent "endcase\n") (setq indent-pt (- indent-pt verilog-indent-level)) (verilog-insert-indent "end\n" - "// End of automatics\n") - ))) + "// End of automatics\n")))) (defun verilog-auto-templated-rel () "Replace Templated relative line numbers with absolute line numbers. @@ -9694,8 +9542,7 @@ Wilson Snyder (wsnyder@wsnyder.org), and/or see http://www.veripool.com." ;; Must be after all inputs outputs are generated (verilog-auto-search-do "/*AUTOARG*/" 'verilog-auto-arg) ;; Fix line numbers (comments only) - (verilog-auto-templated-rel) - ) + (verilog-auto-templated-rel)) ;; (run-hooks 'verilog-auto-hook) ;; @@ -9709,14 +9556,13 @@ Wilson Snyder (wsnyder@wsnyder.org), and/or see http://www.veripool.com." ;; Unwind forms (progn ;; Restore font-lock - (when fontlocked (font-lock-mode t))) - ))) + (when fontlocked (font-lock-mode t)))))) ;; ;; Skeleton based code insertion ;; -(defvar verilog-template-map +(defvar verilog-template-map (let ((map (make-sparse-keymap))) (define-key map "a" 'verilog-sk-always) (define-key map "b" 'verilog-sk-begin) @@ -9985,16 +9831,14 @@ and the case items." (defun verilog-sk-define-signal () "Insert a definition of signal under point at top of module." (interactive "*") - (let* ( - (sig-re "[a-zA-Z0-9_]*") + (let* ((sig-re "[a-zA-Z0-9_]*") (v1 (buffer-substring (save-excursion (skip-chars-backward sig-re) (point)) (save-excursion (skip-chars-forward sig-re) - (point)))) - ) + (point))))) (if (not (member v1 verilog-keywords)) (save-excursion (setq verilog-sk-signal v1) @@ -10003,10 +9847,7 @@ and the case items." (verilog-forward-syntactic-ws) (verilog-sk-def-reg) (message "signal at point is %s" v1)) - (message "object at point (%s) is a keyword" v1)) - ) - ) - + (message "object at point (%s) is a keyword" v1)))) (define-skeleton verilog-sk-wire "Insert a wire definition." @@ -10109,7 +9950,7 @@ and the case items." "^`include\\s-+\"\\([^\n\"]*\\)\"" "Regexp that matches the include file.") -(defvar verilog-mode-mouse-map +(defvar verilog-mode-mouse-map (let ((map (make-sparse-keymap))) ; as described in info pages, make a map (set-keymap-parent map verilog-mode-map) ;; mouse button bindings @@ -10189,8 +10030,7 @@ Files are checked based on `verilog-library-directories'." (progn (message "File '%s' isn't readable, use shift-mouse2 to paste in this field" - (match-string 1)))) - ))) + (match-string 1))))))) ;; ffap isn't useable for verilog mode. It uses library paths. ;; so define this function to do more or less the same as ffap @@ -10208,8 +10048,7 @@ Files are checked based on `verilog-library-directories'." (file-readable-p (car (verilog-library-filenames (match-string 1) (buffer-file-name))))) (find-file (car (verilog-library-filenames - (match-string 1) (buffer-file-name)))))) - )) + (match-string 1) (buffer-file-name)))))))) ;; @@ -10230,6 +10069,7 @@ Files are checked based on `verilog-library-directories'." (princ "\n"))) (autoload 'reporter-submit-bug-report "reporter") +(defvar reporter-prompt-for-summary-p) (defun verilog-submit-bug-report () "Submit via mail a bug report on verilog-mode.el." From e11c1d937fc41f228d261576ccdcc76308e1118a Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 9 Jan 2008 07:21:08 +0000 Subject: [PATCH 028/439] (vc-deduce-fileset): Return the currently selected file if no files are selected when using vc-status. --- lisp/ChangeLog | 17 +++++++++++------ lisp/vc.el | 9 ++++++--- 2 files changed, 17 insertions(+), 9 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index dd955494b77..e72275e9010 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,19 +1,24 @@ +2008-01-09 Dan Nicolaescu + + * vc.el (vc-deduce-fileset): Return the currently selected file if + no files are selected when using vc-status. + 2008-01-09 Michael Kifer * ediff*.el: commented out declare-function. "make bootstrap" stops with an error and emacs does not compile with those things in. Besides, declare-function is not defined in XEmacs. - + * ediff-util (eqiff-quit): autoraise minibuffer. - + * ediff-diff (ediff-convert-fine-diffs-to-overlays): make it a defin - + * viper*.el: commented out declare-function -- not defined in XEmacs. - + * viper-ex.el (viper-info-on-file): take care of indiret buffers. - + * viper.el (viper-set-hooks, set-cursor-color): set viper-vi-state-cursor-color. - + 2008-01-09 Tom Tromey * vc.el (vc-status-headers): Rename from diff --git a/lisp/vc.el b/lisp/vc.el index 6e170ab1464..5966cfb7a7e 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -1276,9 +1276,12 @@ Otherwise, throw an error." (unless (eq (vc-backend f) firstbackend) (error "All members of a fileset must be under the same version-control system.")))) marked)) - ((eq major-mode 'vc-status-mode) - (vc-status-marked-files)) - ((vc-backend buffer-file-name) + ((eq major-mode 'vc-status-mode) + (let ((marked (vc-status-marked-files))) + (if marked + marked + (list (vc-status-current-file))))) + ((vc-backend buffer-file-name) (list buffer-file-name)) ((and vc-parent-buffer (or (buffer-file-name vc-parent-buffer) (with-current-buffer vc-parent-buffer From f5e070d6011dd2c4a7f187976f6a1f2d35cce743 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 9 Jan 2008 07:40:37 +0000 Subject: [PATCH 029/439] *** empty log message *** --- admin/FOR-RELEASE | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index 0aa75f301a8..40ac2dc1c9d 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -119,6 +119,11 @@ X11 frame, the tty frame gets confused, it thinks it is an X11 frame when trying to do a C-z. This worked with server.el version 1.136, it broke after that. http://lists.gnu.org/archive/html/emacs-devel/2007-12/msg00545.html +Also emacsclient does not work on Windows, it also worked with +server.el version 1.136. +http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00710.html + + * DOCUMENTATION From 09c5aa7c300919c1a21827d78e1e55cdf02d5a12 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 9 Jan 2008 08:49:59 +0000 Subject: [PATCH 030/439] (vc-hg-diff): Don't pass an empty string. --- lisp/ChangeLog | 4 ++++ lisp/vc-hg.el | 3 +-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 69274fa24ff..2d959beb28a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-09 Dan Nicolaescu + + * vc-hg.el (vc-hg-diff): Don't pass an empty string. + 2008-01-09 Wilson Snyder * progmodes/verilog-mode.el (top-level): Fix spacing. diff --git a/lisp/vc-hg.el b/lisp/vc-hg.el index 9e76a67e8ae..77a52611ca7 100644 --- a/lisp/vc-hg.el +++ b/lisp/vc-hg.el @@ -286,8 +286,7 @@ (if oldvers (if newvers (list "-r" oldvers "-r" newvers) - (list "-r" oldvers)) - (list "")))))) + (list "-r" oldvers))))))) (defun vc-hg-revision-table (file) (let ((default-directory (file-name-directory file))) From 622face2db67129761aa128450c132aa48386a84 Mon Sep 17 00:00:00 2001 From: Tassilo Horn Date: Wed, 9 Jan 2008 10:25:17 +0000 Subject: [PATCH 031/439] 2008-01-09 Tassilo Horn * doc-view.el (doc-view-mode-p): Add EPS as supported type. (doc-view-mode): Support document files inside archives. --- lisp/ChangeLog | 5 +++++ lisp/doc-view.el | 13 ++++++++++++- 2 files changed, 17 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e72275e9010..b6f0a0f57bf 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-09 Tassilo Horn + + * doc-view.el (doc-view-mode-p): Add EPS as supported type. + (doc-view-mode): Support document files inside archives. + 2008-01-09 Dan Nicolaescu * vc.el (vc-deduce-fileset): Return the currently selected file if diff --git a/lisp/doc-view.el b/lisp/doc-view.el index 9c153dc584f..83f9be53ae3 100644 --- a/lisp/doc-view.el +++ b/lisp/doc-view.el @@ -476,7 +476,7 @@ Image types are symbols like `dvi', `postscript' or `pdf'." (and (doc-view-mode-p 'pdf) doc-view-dvipdfm-program (executable-find doc-view-dvipdfm-program))) - ((or (eq type 'postscript) (eq type 'ps) + ((or (eq type 'postscript) (eq type 'ps) (eq type 'eps) (eq type 'pdf)) (and doc-view-ghostscript-program (executable-find doc-view-ghostscript-program))) @@ -930,6 +930,7 @@ You can use \\\\[doc-view-toggle-display] to toggle between displaying the document or editing it as text." (interactive) (if jka-compr-really-do-compress + ;; This is a compressed file uncompressed by auto-compression-mode. (when (y-or-n-p (concat "DocView: Cannot convert compressed file. " "Save it uncompressed first? ")) @@ -940,11 +941,21 @@ toggle between displaying the document or editing it as text." (kill-buffer nil) (find-file file) (doc-view-mode))) + + ;; When opening a pdf/ps/dvi that's inside an archive (tar, zip, ...) the + ;; file buffer-file-name doesn't exist, so create the directory and save + ;; the file. + (when (not (file-exists-p (file-name-directory buffer-file-name))) + (dired-create-directory (file-name-directory buffer-file-name))) + (when (not (file-exists-p buffer-file-name)) + (write-file buffer-file-name)) + (let* ((prev-major-mode (if (eq major-mode 'doc-view-mode) doc-view-previous-major-mode major-mode))) (kill-all-local-variables) (set (make-local-variable 'doc-view-previous-major-mode) prev-major-mode)) + (make-local-variable 'doc-view-current-files) (make-local-variable 'doc-view-current-image) (make-local-variable 'doc-view-current-page) From 6870e775305e94e3d9a3adcb4da3616c703c90a3 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Wed, 9 Jan 2008 12:48:42 +0000 Subject: [PATCH 032/439] Fix code of ps-face-strikeout-p, ps-face-overline-p and ps-face-box-p --- lisp/ps-print.el | 12 +++++++++--- 1 file changed, 9 insertions(+), 3 deletions(-) diff --git a/lisp/ps-print.el b/lisp/ps-print.el index d7fa07136b4..061b9106c1e 100644 --- a/lisp/ps-print.el +++ b/lisp/ps-print.el @@ -3997,13 +3997,19 @@ It can be retrieved with `(ps-get ALIST-SYM KEY)'." (memq face ps-italic-faces)))) (defun ps-face-strikeout-p (face) - (eq (face-attribute face :strike-through) t)) + (if (featurep 'xemacs) + nil + (eq (face-attribute face :strike-through) t))) (defun ps-face-overline-p (face) - (eq (face-attribute face :overline) t)) + (if (featurep 'xemacs) + nil + (eq (face-attribute face :overline) t))) (defun ps-face-box-p (face) - (not (memq (face-attribute face :box) '(nil unspecified)))) + (if (featurep 'xemacs) + nil + (not (memq (face-attribute face :box) '(nil unspecified))))) (defvar ps-print-color-scale 1.0) From 6e69aa4d01211c82fbc568bc2d44cc8d2347b6ed Mon Sep 17 00:00:00 2001 From: "Eric S. Raymond" Date: Wed, 9 Jan 2008 16:21:29 +0000 Subject: [PATCH 033/439] * testmodes/sgml-mode.el (sgml-tag-syntax-table): Initialize this constant with a computation on sgml-specials rather than a literal list. Without this change the syntax table is generated incorrectly, and the mode will think it's in a comment following any instance of the string "--". --- lisp/ChangeLog | 8 ++++++++ lisp/textmodes/sgml-mode.el | 2 +- 2 files changed, 9 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b6f0a0f57bf..9e793bacc5c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2008-01-09 Eric S. Raymond + + * testmodes/sgml-mode.el (sgml-tag-syntax-table): Initialize this + constant with a computation on sgml-specials rather than a literal + list. Without this change the syntax table is generated + incorrectly, and the mode will think it's in a comment following + any instance of the string "--". + 2008-01-09 Tassilo Horn * doc-view.el (doc-view-mode-p): Add EPS as supported type. diff --git a/lisp/textmodes/sgml-mode.el b/lisp/textmodes/sgml-mode.el index 0c361463022..e8975252b15 100644 --- a/lisp/textmodes/sgml-mode.el +++ b/lisp/textmodes/sgml-mode.el @@ -159,7 +159,7 @@ This takes effect when first loading the `sgml-mode' library.") "Syntax table used in SGML mode. See also `sgml-specials'.") (defconst sgml-tag-syntax-table - (let ((table (sgml-make-syntax-table '(?- ?\" ?\')))) + (let ((table (sgml-make-syntax-table sgml-specials))) (dolist (char '(?\( ?\) ?\{ ?\} ?\[ ?\] ?$ ?% ?& ?* ?+ ?/)) (modify-syntax-entry char "." table)) table) From eaf7efe9bae6b11fbd77d10c9ada51541548892d Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 9 Jan 2008 17:04:59 +0000 Subject: [PATCH 034/439] * progmodes/verilog-mode.el (verilog-booleanp): New function for backward compatibility. Replace all uses of booleanp with verilog-booleanp. --- lisp/ChangeLog | 6 +++++ lisp/progmodes/verilog-mode.el | 44 +++++++++++++++++++--------------- 2 files changed, 31 insertions(+), 19 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2d959beb28a..4fb16ba4cc9 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-09 Wilson Snyder + + * progmodes/verilog-mode.el (verilog-booleanp): New function for + backward compatibility. Replace all uses of booleanp with + verilog-booleanp. + 2008-01-09 Dan Nicolaescu * vc-hg.el (vc-hg-diff): Don't pass an empty string. diff --git a/lisp/progmodes/verilog-mode.el b/lisp/progmodes/verilog-mode.el index 59d5ea83475..a1611b0eada 100644 --- a/lisp/progmodes/verilog-mode.el +++ b/lisp/progmodes/verilog-mode.el @@ -275,6 +275,12 @@ STRING should be given if the last search was by `string-match' on STRING." (if (fboundp 'customize-apropos) (customize-apropos "font-lock-*" 'faces))) +(defun verilog-booleanp (value) + "Return t if VALUE is boolean. + This implements GNU Emacs 22.1's `booleanp' function in earlier Emacs. + This function may be removed when Emacs 21 is no longer supported." + (or (equal value t) (equal value nil))) + (defgroup verilog-mode nil "Facilitates easy editing of Verilog source text" :group 'languages) @@ -355,7 +361,7 @@ entry \"Fontify Buffer\"). XEmacs: turn off and on font locking." :type 'boolean :group 'verilog-mode-indent) ;; Note we don't use :safe, as that would break on Emacsen before 22.0. -(put 'verilog-highlight-translate-off 'safe-local-variable 'booleanp) +(put 'verilog-highlight-translate-off 'safe-local-variable 'verilog-booleanp) (defcustom verilog-indent-level 3 "*Indentation of Verilog statements with respect to containing block." @@ -390,7 +396,7 @@ If non nil, treat as: output c;" :group 'verilog-mode-indent :type 'boolean) -(put 'verilog-indent-declaration-macros 'safe-local-variable 'booleanp) +(put 'verilog-indent-declaration-macros 'safe-local-variable 'verilog-booleanp) (defcustom verilog-indent-lists t "*How to treat indenting items in a list. @@ -403,7 +409,7 @@ If nil, treat as: reset ) begin" :group 'verilog-mode-indent :type 'boolean) -(put 'verilog-indent-lists 'safe-local-variable 'booleanp) +(put 'verilog-indent-lists 'safe-local-variable 'verilog-booleanp) (defcustom verilog-indent-level-behavioral 3 "*Absolute indentation of first begin in a task or function block. @@ -435,33 +441,33 @@ Set to 0 to have all directives start at the left side of the screen." "*True means automatically newline after semicolons." :group 'verilog-mode-indent :type 'boolean) -(put 'verilog-auto-newline 'safe-local-variable 'booleanp) +(put 'verilog-auto-newline 'safe-local-variable 'verilog-booleanp) (defcustom verilog-auto-indent-on-newline t "*True means automatically indent line after newline." :group 'verilog-mode-indent :type 'boolean) -(put 'verilog-auto-indent-on-newline 'safe-local-variable 'booleanp) +(put 'verilog-auto-indent-on-newline 'safe-local-variable 'verilog-booleanp) (defcustom verilog-tab-always-indent t "*True means TAB should always re-indent the current line. Nil means TAB will only reindent when at the beginning of the line." :group 'verilog-mode-indent :type 'boolean) -(put 'verilog-tab-always-indent 'safe-local-variable 'booleanp) +(put 'verilog-tab-always-indent 'safe-local-variable 'verilog-booleanp) (defcustom verilog-tab-to-comment nil "*True means TAB moves to the right hand column in preparation for a comment." :group 'verilog-mode-actions :type 'boolean) -(put 'verilog-tab-to-comment 'safe-local-variable 'booleanp) +(put 'verilog-tab-to-comment 'safe-local-variable 'verilog-booleanp) (defcustom verilog-indent-begin-after-if t "*If true, indent begin statements following if, else, while, for and repeat. Otherwise, line them up." :group 'verilog-mode-indent :type 'boolean) -(put 'verilog-indent-begin-after-if 'safe-local-variable 'booleanp) +(put 'verilog-indent-begin-after-if 'safe-local-variable 'verilog-booleanp) (defcustom verilog-align-ifelse nil @@ -469,7 +475,7 @@ Otherwise, line them up." Otherwise else is lined up with first character on line holding matching if." :group 'verilog-mode-indent :type 'boolean) -(put 'verilog-align-ifelse 'safe-local-variable 'booleanp) +(put 'verilog-align-ifelse 'safe-local-variable 'verilog-booleanp) (defcustom verilog-minimum-comment-distance 10 "*Minimum distance (in lines) between begin and end required before a comment. @@ -529,14 +535,14 @@ IEEE-1800 standard. Note that changing this will require restarting Emacs to see the effect as font color choices are cached by Emacs" :group 'verilog-mode-indent :type 'boolean) -(put 'verilog-highlight-p1800-keywords 'safe-local-variable 'booleanp) +(put 'verilog-highlight-p1800-keywords 'safe-local-variable 'verilog-booleanp) (defcustom verilog-auto-endcomments t "*True means insert a comment /* ... */ after 'end's. The name of the function or case will be set between the braces." :group 'verilog-mode-actions :type 'boolean) -(put 'verilog-auto-endcomments 'safe-local-variable 'booleanp) +(put 'verilog-auto-endcomments 'safe-local-variable 'verilog-booleanp) (defcustom verilog-auto-read-includes nil "*True means to automatically read includes before AUTOs. @@ -546,7 +552,7 @@ but can result in very slow reading times if there are many or large include files." :group 'verilog-mode-actions :type 'boolean) -(put 'verilog-auto-read-includes 'safe-local-variable 'booleanp) +(put 'verilog-auto-read-includes 'safe-local-variable 'verilog-booleanp) (defcustom verilog-auto-save-policy nil "*Non-nil indicates action to take when saving a Verilog buffer with AUTOs. @@ -567,7 +573,7 @@ They will be expanded in the same way as if there was a AUTOINST in the instantiation. See also `verilog-auto-star' and `verilog-auto-star-save'." :group 'verilog-mode-actions :type 'boolean) -(put 'verilog-auto-star-expand 'safe-local-variable 'booleanp) +(put 'verilog-auto-star-expand 'safe-local-variable 'verilog-booleanp) (defcustom verilog-auto-star-save nil "*Non-nil indicates to save to disk SystemVerilog .* instance expansions. @@ -578,7 +584,7 @@ Instead of setting this, you may want to use /*AUTOINST*/, which will always be saved." :group 'verilog-mode-actions :type 'boolean) -(put 'verilog-auto-star-save 'safe-local-variable 'booleanp) +(put 'verilog-auto-star-save 'safe-local-variable 'verilog-booleanp) (defvar verilog-auto-update-tick nil "Modification tick at which autos were last performed.") @@ -765,7 +771,7 @@ If nil, only inputs that are NOT output signals in the same block are included." :group 'verilog-mode-auto :type 'boolean) -(put 'verilog-auto-sense-include-inputs 'safe-local-variable 'booleanp) +(put 'verilog-auto-sense-include-inputs 'safe-local-variable 'verilog-booleanp) (defcustom verilog-auto-sense-defines-constant nil "*If true, AUTOSENSE should assume all defines represent constants. @@ -774,7 +780,7 @@ maintain compatibility with other sites, this should be set at the bottom of each verilog file that requires it, rather than being set globally." :group 'verilog-mode-auto :type 'boolean) -(put 'verilog-auto-sense-defines-constant 'safe-local-variable 'booleanp) +(put 'verilog-auto-sense-defines-constant 'safe-local-variable 'verilog-booleanp) (defcustom verilog-auto-reset-widths t "*If true, AUTORESET should determine the width of signals. @@ -784,7 +790,7 @@ the constant zero. This may result in ugly code when parameters determine the MSB or LSB of a signal inside a AUTORESET." :type 'boolean :group 'verilog-mode-auto) -(put 'verilog-auto-reset-widths 'safe-local-variable 'booleanp) +(put 'verilog-auto-reset-widths 'safe-local-variable 'verilog-booleanp) (defcustom verilog-assignment-delay "" "*Text used for delays in delayed assignments. Add a trailing space if set." @@ -800,7 +806,7 @@ declare the wire to have the subscripts removed.) Nil may speed up some simulators, but is less general and harder to read, so avoid." :group 'verilog-mode-auto :type 'boolean) -(put 'verilog-auto-inst-vector 'safe-local-variable 'booleanp) +(put 'verilog-auto-inst-vector 'safe-local-variable 'verilog-booleanp) (defcustom verilog-auto-inst-template-numbers nil "*If true, when creating templated ports with AUTOINST, add a comment. @@ -809,7 +815,7 @@ port declaration. Setting this aids in debugging, but nil is suggested for regular use to prevent large numbers of merge conflicts." :group 'verilog-mode-auto :type 'boolean) -(put 'verilog-auto-inst-template-numbers 'safe-local-variable 'booleanp) +(put 'verilog-auto-inst-template-numbers 'safe-local-variable 'verilog-booleanp) (defvar verilog-auto-inst-column 40 "Column number for first part of auto-inst.") From f9adf05bac8484b01da84f18e6053a074509384b Mon Sep 17 00:00:00 2001 From: Tassilo Horn Date: Wed, 9 Jan 2008 20:16:14 +0000 Subject: [PATCH 035/439] 2008-01-09 Tassilo Horn * doc-view.el (doc-view-mode): Support tramp, compressed files and files inside archives uniformly. --- lisp/ChangeLog | 5 +++ lisp/doc-view.el | 101 +++++++++++++++++++++++------------------------ 2 files changed, 54 insertions(+), 52 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9e793bacc5c..798ed9ec3a6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-09 Tassilo Horn + + * doc-view.el (doc-view-mode): Support tramp, compressed files and + files inside archives uniformly. + 2008-01-09 Eric S. Raymond * testmodes/sgml-mode.el (sgml-tag-syntax-table): Initialize this diff --git a/lisp/doc-view.el b/lisp/doc-view.el index 83f9be53ae3..92159776269 100644 --- a/lisp/doc-view.el +++ b/lisp/doc-view.el @@ -929,60 +929,57 @@ If BACKWARD is non-nil, jump to the previous match." You can use \\\\[doc-view-toggle-display] to toggle between displaying the document or editing it as text." (interactive) - (if jka-compr-really-do-compress + ;; Handle compressed files, TRAMP files, files inside archives + (cond + (jka-compr-really-do-compress + (let ((file (expand-file-name + (file-name-nondirectory + (file-name-sans-extension buffer-file-name)) + doc-view-cache-directory))) + (write-region nil nil file) + (setq buffer-file-name file))) + ((or + (not (file-exists-p buffer-file-name)) + (tramp-tramp-file-p buffer-file-name)) + (let ((file (expand-file-name + (file-name-nondirectory buffer-file-name) + doc-view-cache-directory))) + (write-region nil nil file) + (setq buffer-file-name file)))) - ;; This is a compressed file uncompressed by auto-compression-mode. - (when (y-or-n-p (concat "DocView: Cannot convert compressed file. " - "Save it uncompressed first? ")) - (let ((file (read-file-name - "File: " - (file-name-directory buffer-file-name)))) - (write-region (point-min) (point-max) file) - (kill-buffer nil) - (find-file file) - (doc-view-mode))) + (let* ((prev-major-mode (if (eq major-mode 'doc-view-mode) + doc-view-previous-major-mode + major-mode))) + (kill-all-local-variables) + (set (make-local-variable 'doc-view-previous-major-mode) prev-major-mode)) - ;; When opening a pdf/ps/dvi that's inside an archive (tar, zip, ...) the - ;; file buffer-file-name doesn't exist, so create the directory and save - ;; the file. - (when (not (file-exists-p (file-name-directory buffer-file-name))) - (dired-create-directory (file-name-directory buffer-file-name))) - (when (not (file-exists-p buffer-file-name)) - (write-file buffer-file-name)) - - (let* ((prev-major-mode (if (eq major-mode 'doc-view-mode) - doc-view-previous-major-mode - major-mode))) - (kill-all-local-variables) - (set (make-local-variable 'doc-view-previous-major-mode) prev-major-mode)) - - (make-local-variable 'doc-view-current-files) - (make-local-variable 'doc-view-current-image) - (make-local-variable 'doc-view-current-page) - (make-local-variable 'doc-view-current-converter-process) - (make-local-variable 'doc-view-current-timer) - (make-local-variable 'doc-view-current-slice) - (make-local-variable 'doc-view-current-cache-dir) - (make-local-variable 'doc-view-current-info) - (make-local-variable 'doc-view-current-search-matches) - (set (make-local-variable 'doc-view-current-overlay) - (make-overlay (point-min) (point-max) nil t)) - (add-hook 'change-major-mode-hook - (lambda () (delete-overlay doc-view-current-overlay)) - nil t) - (set (make-local-variable 'mode-line-position) - '(" P" (:eval (number-to-string doc-view-current-page)) - "/" (:eval (number-to-string (length doc-view-current-files))))) - (set (make-local-variable 'cursor-type) nil) - (use-local-map doc-view-mode-map) - (set (make-local-variable 'after-revert-hook) 'doc-view-reconvert-doc) - (set (make-local-variable 'bookmark-make-cell-function) - 'doc-view-bookmark-make-cell) - (setq mode-name "DocView" - buffer-read-only t - major-mode 'doc-view-mode) - (doc-view-initiate-display) - (run-mode-hooks 'doc-view-mode-hook))) + (make-local-variable 'doc-view-current-files) + (make-local-variable 'doc-view-current-image) + (make-local-variable 'doc-view-current-page) + (make-local-variable 'doc-view-current-converter-process) + (make-local-variable 'doc-view-current-timer) + (make-local-variable 'doc-view-current-slice) + (make-local-variable 'doc-view-current-cache-dir) + (make-local-variable 'doc-view-current-info) + (make-local-variable 'doc-view-current-search-matches) + (set (make-local-variable 'doc-view-current-overlay) + (make-overlay (point-min) (point-max) nil t)) + (add-hook 'change-major-mode-hook + (lambda () (delete-overlay doc-view-current-overlay)) + nil t) + (set (make-local-variable 'mode-line-position) + '(" P" (:eval (number-to-string doc-view-current-page)) + "/" (:eval (number-to-string (length doc-view-current-files))))) + (set (make-local-variable 'cursor-type) nil) + (use-local-map doc-view-mode-map) + (set (make-local-variable 'after-revert-hook) 'doc-view-reconvert-doc) + (set (make-local-variable 'bookmark-make-cell-function) + 'doc-view-bookmark-make-cell) + (setq mode-name "DocView" + buffer-read-only t + major-mode 'doc-view-mode) + (doc-view-initiate-display) + (run-mode-hooks 'doc-view-mode-hook)) ;;;###autoload (define-minor-mode doc-view-minor-mode From f262b5b80f61f2232fe08eb8b0f8a24ad08f7943 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 10 Jan 2008 01:55:24 +0000 Subject: [PATCH 036/439] (select-safe-coding-system): When a buffer is modified, cancel the writing. --- lisp/international/mule-cmds.el | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lisp/international/mule-cmds.el b/lisp/international/mule-cmds.el index 06473497c2e..ad9f73bcb43 100644 --- a/lisp/international/mule-cmds.el +++ b/lisp/international/mule-cmds.el @@ -966,6 +966,7 @@ It is highly recommended to fix it before writing to a file." (let ((codings (find-coding-systems-region from to)) (coding-system nil) + (tick (if (not (stringp from)) (buffer-modified-tick))) safe rejected unsafe) (if (eq (car codings) 'undecided) ;; Any coding system is ok. @@ -1030,6 +1031,8 @@ It is highly recommended to fix it before writing to a file." %s specified by file contents. Really save (else edit coding cookies \ and try again)? " coding-system auto-cs)) (error "Save aborted")))) + (when (and tick (/= tick (buffer-modified-tick))) + (error "Cancelled because the buffer was modified")) coding-system))) (setq select-safe-coding-system-function 'select-safe-coding-system) From 373d0f24eaa782efd2fbd36f0148808dc45f4f22 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 10 Jan 2008 02:07:04 +0000 Subject: [PATCH 037/439] *** empty log message *** --- lisp/ChangeLog | 21 +++++++++++++-------- 1 file changed, 13 insertions(+), 8 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4fb16ba4cc9..a09ef67b8ea 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,7 +1,12 @@ -2008-01-09 Wilson Snyder +2008-01-10 Kenichi Handa + + * international/mule-cmds.el (select-safe-coding-system): + When a buffer is modified, cancel the writing. + +2008-01-09 Wilson Snyder * progmodes/verilog-mode.el (verilog-booleanp): New function for - backward compatibility. Replace all uses of booleanp with + backward compatibility. Replace all uses of booleanp with verilog-booleanp. 2008-01-09 Dan Nicolaescu @@ -1641,7 +1646,7 @@ 2007-09-05 Jason Rumney - * frame.el (focus-follows-mouse): Doc-fix. Change default on w32. + * frame.el (focus-follows-mouse): Doc-fix. Change default on w32. 2007-09-02 Richard Stallman @@ -3536,7 +3541,7 @@ 2007-04-15 Roland Winkler * textmodes/bibtex.el (bibtex-field-list): Use functionp. - (bibtex-make-field): Check that INIT is a string. Use functionp. + (bibtex-make-field): Check that INIT is a string. Use functionp. 2007-04-14 Glenn Morris @@ -4500,7 +4505,7 @@ * progmodes/idlw-help.el (idlwave-do-context-help1): Don't visit special help topics for keywords. (idlwave-help-assistant-command): Include ".exe" for ms-dos - etc. Assistant command. + etc. Assistant command. 2007-03-08 Chong Yidong @@ -5419,7 +5424,7 @@ (newsticker--decode-iso8601-date): Bugfix for datestrings without days. (newsticker--buffer-do-insert-text): Fix. - (newsticker--buffer-insert-enclosure): Fix. length might be missing. + (newsticker--buffer-insert-enclosure): Fix. Length might be missing. (newsticker--buffer-make-item-completely-visible): `switch-to-buffer' not necessary. @@ -8651,7 +8656,7 @@ After 5.3, 5.4: (cperl-facemenu-add-face-function): Add docs, fix U<>. Copyright message updated. - (cperl-init-faces): Work around a bug in `font-lock'. May slow + (cperl-init-faces): Work around a bug in `font-lock'. May slow facification down a bit. Misprint for my|our|local for old `font-lock' "our" was not fontified same as "my|local". @@ -9167,7 +9172,7 @@ 2006-09-26 Vinicius Jose Latorre - * progmodes/ebnf2ps.el: Doc fix. Implement arrow spacing and scaling. + * progmodes/ebnf2ps.el: Doc fix. Implement arrow spacing and scaling. (ebnf-version): New version 4.3. (ebnf-arrow-extra-width, ebnf-arrow-scale): New options. (ebnf-prologue): Adjust PostScript programming. From 712e2b05e11b9f48e02f16890f916aa76a66ba50 Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Thu, 10 Jan 2008 03:51:14 +0000 Subject: [PATCH 038/439] ERC: Sync changes from upstream. --- lisp/erc/ChangeLog | 15 +++++++++ lisp/erc/erc-backend.el | 71 ++++++++++++++++++---------------------- lisp/erc/erc-services.el | 15 ++++++--- 3 files changed, 56 insertions(+), 45 deletions(-) diff --git a/lisp/erc/ChangeLog b/lisp/erc/ChangeLog index b7d1d1bfe30..2e8fb250018 100644 --- a/lisp/erc/ChangeLog +++ b/lisp/erc/ChangeLog @@ -3,6 +3,21 @@ * erc-ibuffer.el (erc-channel-modes): Pass mode-name through format-mode-line +2007-12-16 Diane Murray + + * erc-services.el (erc-nickserv-alist): Removed autodetect regexp, + added identified regexp for OFTC. + (erc-nickserv-identification-autodetect): Make sure success-regex + is non-nil. + (erc-nickserv-identify-autodetect): Make sure identify-regex is + non-nil. Doc fix. + +2007-12-13 Diane Murray + + * erc-backend.el (PRIVMSG, QUIT, TOPIC, WALLOPS, 376, 004, 221) + (312, 315, 319, 330, 331, 333, 367, 368, 391, 405, 406, 412) + (421, 432, 433, 437, 442, 461, 474, 477, 482, 431): Doc fix. + 2007-12-09 Michael Olson * erc-services.el (erc-nickserv-alist): Fix regexps for GRnet. diff --git a/lisp/erc/erc-backend.el b/lisp/erc/erc-backend.el index 0fead116d8f..5fe0efd1c94 100644 --- a/lisp/erc/erc-backend.el +++ b/lisp/erc/erc-backend.el @@ -1349,7 +1349,7 @@ add things to `%s' instead." (erc-update-mode-line)))) (define-erc-response-handler (PRIVMSG NOTICE) - nil nil + "Handle private messages, including messages in channels." nil (let ((sender-spec (erc-response.sender parsed)) (cmd (erc-response.command parsed)) (tgt (car (erc-response.command-args parsed))) @@ -1413,7 +1413,7 @@ add things to `%s' instead." (add-hook 'erc-server-PRIVMSG-functions 'erc-auto-query) (define-erc-response-handler (QUIT) - nil nil + "Another user has quit IRC." nil (let ((reason (erc-response.contents parsed)) bufs) (multiple-value-bind (nick login host) @@ -1426,7 +1426,7 @@ add things to `%s' instead." ?h host ?r reason)))) (define-erc-response-handler (TOPIC) - nil nil + "The channel topic has changed." nil (let* ((ch (first (erc-response.command-args parsed))) (topic (erc-trim-string (erc-response.contents parsed))) (time (format-time-string "%T %m/%d/%y" (current-time)))) @@ -1439,7 +1439,7 @@ add things to `%s' instead." ?c ch ?T topic)))) (define-erc-response-handler (WALLOPS) - nil nil + "Display a WALLOPS message." nil (let ((message (erc-response.contents parsed))) (multiple-value-bind (nick login host) (erc-parse-user (erc-response.sender parsed)) @@ -1465,12 +1465,12 @@ add things to `%s' instead." (erc-response.contents parsed))) (define-erc-response-handler (376 422) - nil nil + "End of MOTD/MOTD is missing." nil (erc-server-MOTD proc parsed) (erc-connection-established proc parsed)) (define-erc-response-handler (004) - nil nil + "Display the server's identification." nil (multiple-value-bind (server-name server-version) (cdr (erc-response.command-args parsed)) (setq erc-server-version server-version) @@ -1510,7 +1510,7 @@ A server may send more than one 005 message." (erc-display-message parsed 'notice proc line))) (define-erc-response-handler (221) - nil nil + "Display the current user modes." nil (let* ((nick (first (erc-response.command-args parsed))) (modes (mapconcat 'identity (cdr (erc-response.command-args parsed)) " "))) @@ -1596,7 +1596,7 @@ See `erc-display-server-message'." nil ?n nick ?f fname ?u user ?h host)))) (define-erc-response-handler (312) - nil nil + "Server name response in WHOIS." nil (multiple-value-bind (nick server-host) (cdr (erc-response.command-args parsed)) (erc-display-message @@ -1614,7 +1614,7 @@ See `erc-display-server-message'." nil ;; 318 - End of WHOIS list ;; 323 - End of channel LIST ;; 369 - End of WHOWAS - nil nil + "End of WHO/WHOIS/LIST/WHOWAS notices." nil (ignore proc parsed)) (define-erc-response-handler (317) @@ -1635,7 +1635,7 @@ See `erc-display-server-message'." nil ?n nick ?i (erc-sec-to-time (string-to-number seconds-idle)))))) (define-erc-response-handler (319) - nil nil + "Channel names in WHOIS response." nil (erc-display-message parsed 'notice 'active 's319 ?n (second (erc-response.command-args parsed)) @@ -1683,7 +1683,7 @@ See `erc-display-server-message'." nil 's329 ?c channel ?t (format-time-string "%A %Y/%m/%d %X" time)))) (define-erc-response-handler (330) - nil nil + "Nick is authed as (on Quakenet network)." nil ;; FIXME: I don't know what the magic numbers mean. Mummy, make ;; the magic numbers go away. ;; No seriously, I have no clue about the format of this command, @@ -1699,10 +1699,9 @@ See `erc-display-server-message'." nil ?n nick ?a authmsg ?i authaccount))) (define-erc-response-handler (331) - "Channel topic." nil + "No topic set for channel." nil (let ((channel (second (erc-response.command-args parsed))) (topic (erc-response.contents parsed))) - ;; FIXME: why don't we do anything with the topic? -- Lawrence 2004/05/10 (erc-display-message parsed 'notice (erc-get-buffer channel proc) 's331 ?c channel))) @@ -1715,8 +1714,7 @@ See `erc-display-server-message'." nil 's332 ?c channel ?T topic))) (define-erc-response-handler (333) - ;; Who set the topic, and when - nil nil + "Who set the topic, and when." nil (multiple-value-bind (channel nick time) (cdr (erc-response.command-args parsed)) (setq time (format-time-string "%T %Y/%m/%d" @@ -1766,7 +1764,7 @@ See `erc-display-server-message'." nil (erc-channel-end-receiving-names))) (define-erc-response-handler (367) - "Channel ban list entries" nil + "Channel ban list entries." nil (multiple-value-bind (channel banmask setter time) (cdr (erc-response.command-args parsed)) ;; setter and time are not standard @@ -1781,7 +1779,7 @@ See `erc-display-server-message'." nil ?b banmask)))) (define-erc-response-handler (368) - "End of channel ban list" nil + "End of channel ban list." nil (let ((channel (second (erc-response.command-args parsed)))) (erc-display-message parsed 'notice 'active 's368 ?c channel))) @@ -1797,7 +1795,7 @@ See `erc-display-server-message'." nil 's379 ?c from ?f to))) (define-erc-response-handler (391) - "Server's time string" nil + "Server's time string." nil (erc-display-message parsed 'notice 'active 's391 ?s (second (erc-response.command-args parsed)) @@ -1824,56 +1822,47 @@ See `erc-display-server-message'." nil (define-erc-response-handler (405) - ;; Can't join that many channels. - nil nil + "Can't join that many channels." nil (erc-display-message parsed '(notice error) 'active 's405 ?c (second (erc-response.command-args parsed)))) (define-erc-response-handler (406) - ;; No such nick - nil nil + "No such nick." nil (erc-display-message parsed '(notice error) 'active 's406 ?n (second (erc-response.command-args parsed)))) (define-erc-response-handler (412) - ;; No text to send - nil nil + "No text to send." nil (erc-display-message parsed '(notice error) 'active 's412)) (define-erc-response-handler (421) - ;; Unknown command - nil nil + "Unknown command." nil (erc-display-message parsed '(notice error) 'active 's421 ?c (second (erc-response.command-args parsed)))) (define-erc-response-handler (432) - ;; Bad nick. - nil nil + "Bad nick." nil (erc-display-message parsed '(notice error) 'active 's432 ?n (second (erc-response.command-args parsed)))) (define-erc-response-handler (433) - ;; Login-time "nick in use" - nil nil + "Login-time \"nick in use\"." nil (erc-nickname-in-use (second (erc-response.command-args parsed)) "already in use")) (define-erc-response-handler (437) - ;; Nick temporarily unavailable (IRCnet) - nil nil + "Nick temporarily unavailable (on IRCnet)." nil (let ((nick/channel (second (erc-response.command-args parsed)))) (unless (erc-channel-p nick/channel) (erc-nickname-in-use nick/channel "temporarily unavailable")))) (define-erc-response-handler (442) - ;; Not on channel - nil nil + "Not on channel." nil (erc-display-message parsed '(notice error) 'active 's442 ?c (second (erc-response.command-args parsed)))) (define-erc-response-handler (461) - ;; Not enough params for command. - nil nil + "Not enough parameters for command." nil (erc-display-message parsed '(notice error) 'active 's461 ?c (second (erc-response.command-args parsed)) ?m (erc-response.contents parsed))) @@ -1887,7 +1876,7 @@ See `erc-display-server-message'." nil (erc-response.contents parsed))) (define-erc-response-handler (474) - "Banned from channel errors" nil + "Banned from channel errors." nil (erc-display-message parsed '(notice error) nil (intern (format "s%s" (erc-response.command parsed))) @@ -1906,14 +1895,14 @@ See `erc-display-server-message'." nil (erc-cmd-JOIN channel key))))) (define-erc-response-handler (477) - nil nil + "Channel doesn't support modes." nil (let ((channel (second (erc-response.command-args parsed))) (message (erc-response.contents parsed))) (erc-display-message parsed 'notice (erc-get-buffer channel proc) (format "%s: %s" channel message)))) (define-erc-response-handler (482) - nil nil + "You need to be a channel operator to do that." nil (let ((channel (second (erc-response.command-args parsed))) (message (erc-response.contents parsed))) (erc-display-message parsed '(error notice) 'active 's482 @@ -1935,7 +1924,9 @@ See `erc-display-server-message'." nil ;; 491 - No O-lines for your host ;; 501 - Unknown MODE flag ;; 502 - Cannot change mode for other users - nil nil + "Generic display of server error messages. + +See `erc-display-error-notice'." nil (erc-display-error-notice parsed (intern (format "s%s" (erc-response.command parsed))))) diff --git a/lisp/erc/erc-services.el b/lisp/erc/erc-services.el index ac57de9cd15..028d358ad39 100644 --- a/lisp/erc/erc-services.el +++ b/lisp/erc/erc-services.el @@ -227,6 +227,8 @@ Example of use: "IDENTIFY" nil nil nil) (freenode "NickServ!NickServ@services." + ;; freenode also accepts a password at login, see the `erc' + ;; :password argument. "/msg\\s-NickServ\\s-IDENTIFY\\s-" "NickServ" "IDENTIFY" nil nil @@ -249,9 +251,11 @@ Example of use: "IDENTIFY" nil "SQUERY" nil) (OFTC "NickServ!services@services.oftc.net" - "type\\s-/msg\\s-NickServ\\s-IDENTIFY\\s-password." + ;; OFTC's NickServ doesn't ask you to identify anymore. + nil "NickServ" - "IDENTIFY" nil nil nil) + "IDENTIFY" nil nil + "You\\s-are\\s-successfully\\s-identified\\s-as\\s-") (QuakeNet nil nil "Q@CServe.quakenet.org" @@ -334,15 +338,15 @@ If this is the case, run `erc-nickserv-identified-hook'." ;; continue only if we're sure it's the real nickserv for this network ;; and it's told us we've successfully identified (when (and sender (equal sspec sender) + success-regex (string-match success-regex msg)) (erc-log "NickServ IDENTIFY success notification detected") (run-hook-with-args 'erc-nickserv-identified-hook network nick) nil))) (defun erc-nickserv-identify-autodetect (proc parsed) - "Check for a NickServ identify request everytime a notice is received. -Make sure it is the real NickServ for this network and that it has -specifically asked the user to IDENTIFY. + "Identify to NickServ when an identify request is received. +Make sure it is the real NickServ for this network. If `erc-prompt-for-nickserv-password' is non-nil, prompt the user for the password for this nickname, otherwise try to send it automatically." (unless (and (null erc-nickserv-passwords) @@ -356,6 +360,7 @@ password for this nickname, otherwise try to send it automatically." ;; continue only if we're sure it's the real nickserv for this network ;; and it's asked us to identify (when (and sender (equal sspec sender) + identify-regex (string-match identify-regex msg)) (erc-log "NickServ IDENTIFY request detected") (erc-nickserv-call-identify-function nick) From 0a9f2dcf33e8c7131548ddd51c459c98d05493c2 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 10 Jan 2008 04:04:46 +0000 Subject: [PATCH 039/439] (shell-dirtrack-verbose, shell-mode) (shell-directory-tracker, shell-dirtrack-mode): Doc fix. (dirtrack-toggle, dirtrack-mode): No longer alias to shell-dirtrack-mode. --- lisp/ChangeLog | 7 +++++++ lisp/shell.el | 20 +++++++++++++------- 2 files changed, 20 insertions(+), 7 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index a09ef67b8ea..b26216ab59d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2008-01-10 Glenn Morris + + * shell.el (shell-dirtrack-verbose, shell-mode) + (shell-directory-tracker, shell-dirtrack-mode): Doc fix. + (dirtrack-toggle, dirtrack-mode): No longer alias to + shell-dirtrack-mode. + 2008-01-10 Kenichi Handa * international/mule-cmds.el (select-safe-coding-system): diff --git a/lisp/shell.el b/lisp/shell.el index 5cc4862c891..45ef23e98c3 100644 --- a/lisp/shell.el +++ b/lisp/shell.el @@ -93,7 +93,7 @@ ;; m-c-f shell-forward-command Forward a shell command ;; m-c-b shell-backward-command Backward a shell command ;; dirs Resync the buffer's dir stack -;; dirtrack-mode Turn dir tracking on/off +;; shell-dirtrack-mode Turn dir tracking on/off ;; comint-strip-ctrl-m Remove trailing ^Ms from output ;; ;; The shell mode hook is shell-mode-hook @@ -263,7 +263,9 @@ This mirrors the optional behavior of tcsh." (defcustom shell-dirtrack-verbose t "If non-nil, show the directory stack following directory change. -This is effective only if directory tracking is enabled." +This is effective only if directory tracking is enabled. +The `dirtrack' package provides an alternative implementation of this feature - +see the function `dirtrack-mode'." :type 'boolean :group 'shell-directories) @@ -398,7 +400,9 @@ While directory tracking is enabled, the shell's working directory is displayed by \\[list-buffers] or \\[mouse-buffer-menu] in the `File' field. \\[dirs] queries the shell and resyncs Emacs' idea of what the current directory stack is. -\\[dirtrack-mode] turns directory tracking on and off. +\\[shell-dirtrack-mode] turns directory tracking on and off. +\(The `dirtrack' package provides an alternative implementation of this +feature.) \\{shell-mode-map} Customization: Entry to this mode runs the hooks on `comint-mode-hook' and @@ -615,8 +619,10 @@ This function is called on each input passed to the shell. It watches for cd, pushd and popd commands and sets the buffer's default directory to track these commands. -You may toggle this tracking on and off with \\[dirtrack-mode]. +You may toggle this tracking on and off with \\[shell-dirtrack-mode]. If Emacs gets confused, you can resync with the shell with \\[dirs]. +\(The `dirtrack' package provides an alternative implementation of this +feature - see the function `dirtrack-mode'.) See variables `shell-cd-regexp', `shell-chdrive-regexp', `shell-pushd-regexp', and `shell-popd-regexp', while `shell-pushd-tohome', `shell-pushd-dextract', @@ -772,7 +778,9 @@ Environment variables are expanded, see function `substitute-in-file-name'." (defvaralias 'shell-dirtrack-mode 'shell-dirtrackp) (define-minor-mode shell-dirtrack-mode - "Turn directory tracking on and off in a shell buffer." + "Turn directory tracking on and off in a shell buffer. +The `dirtrack' package provides an alternative implementation of this +feature - see the function `dirtrack-mode'." nil nil nil (setq list-buffers-directory (if shell-dirtrack-mode default-directory)) (if shell-dirtrack-mode @@ -781,8 +789,6 @@ Environment variables are expanded, see function `substitute-in-file-name'." ;; For your typing convenience: (defalias 'shell-dirtrack-toggle 'shell-dirtrack-mode) ;??Convenience?? -(defalias 'dirtrack-toggle 'shell-dirtrack-mode) -(defalias 'dirtrack-mode 'shell-dirtrack-mode) (defun shell-cd (dir) "Do normal `cd' to DIR, and set `list-buffers-directory'." From 511e35591a60d2577e5d0ed7199c5bdfb5f9ba83 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 10 Jan 2008 04:05:45 +0000 Subject: [PATCH 040/439] Add Incompatible Lisp Changes section with shell.el dirtrack stuff. --- etc/NEWS | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/etc/NEWS b/etc/NEWS index 8e8a0506496..b6d2cee7b8c 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -112,6 +112,13 @@ This can be used to add menu entries for backend specific functions. *** VC has some support for Git. +* Incompatible Lisp Changes in Emacs 22.2 + +** shell.el no longer defines the aliases `dirtrack-toggle' and +`dirtrack-mode' for `shell-dirtrack-mode'. These names were removed +because they clash with commands provided by dirtrack.el. Use +`shell-dirtrack-mode' instead. + * Lisp Changes in Emacs 22.2. ** Frame-local variables are deprecated and are slated for removal. From 86a6434d770818b9f29e9c42629d3257f5062a15 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 10 Jan 2008 04:06:13 +0000 Subject: [PATCH 041/439] shell.el dirtrack stuff moved to 22.2. --- etc/NEWS | 5 ----- 1 file changed, 5 deletions(-) diff --git a/etc/NEWS b/etc/NEWS index 076bde31b32..7e01829ac34 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -421,11 +421,6 @@ checking/manipulating elements directly, use the new functions `byte-compile-warning-enabled-p', `byte-compile-disable-warning', and `byte-compile-enable-warning.' -** shell.el no longer defines the aliases `dirtrack-toggle' and -`dirtrack-mode' for `shell-dirtrack-mode'. These names were removed -because they clash with commands provided by dirtrack.el. Use -`shell-dirtrack-mode' instead. - * Lisp Changes in Emacs 23.1 From c0323133334f70c2e25f4ace22084e3696bf2a5a Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 10 Jan 2008 04:08:55 +0000 Subject: [PATCH 042/439] Chong Yidong (wait_reading_process_output): Check for window changes caused by timers. --- src/ChangeLog | 5 +++++ src/process.c | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 6433adaee13..18b1e04a1d7 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-01-10 Chong Yidong + + * process.c (wait_reading_process_output): Check for window + changes caused by timers. + 2008-01-09 Kenichi Handa * coding.c (detect_coding_iso2022): New arg diff --git a/src/process.c b/src/process.c index 5812660e85a..a48e5435837 100644 --- a/src/process.c +++ b/src/process.c @@ -4718,6 +4718,7 @@ wait_reading_process_output (time_limit, microsecs, read_kbd, do_display, { int old_timers_run = timers_run; struct buffer *old_buffer = current_buffer; + Lisp_Object old_window = selected_window; int leave = 0; if (detect_input_pending_run_timers (do_display)) @@ -4731,7 +4732,8 @@ wait_reading_process_output (time_limit, microsecs, read_kbd, do_display, an alike. Make read_key_sequence aware of that. */ if (timers_run != old_timers_run && waiting_for_user_input_p == -1 - && old_buffer != current_buffer) + && (old_buffer != current_buffer + || !EQ (old_window, selected_window))) record_asynch_buffer_change (); if (leave) From 63dbe8da55f83719acaf0dbd74d6273137334c6f Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 10 Jan 2008 04:09:49 +0000 Subject: [PATCH 043/439] Chong Yidong (wait_reading_process_output): Check for window changes caused by timers. --- admin/FOR-RELEASE | 9 +-------- src/ChangeLog | 5 +++++ src/process.c | 4 +++- 3 files changed, 9 insertions(+), 9 deletions(-) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index 8ac97232def..4f1d8d3a6c3 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -50,13 +50,6 @@ http://lists.gnu.org/archive/html/bug-gnu-emacs/2007-09/msg00055.html * BUGS -** schierlm@gmx.de, 25 Dec: Crash when buffer is edited while save-buffer asks for coding system -http://lists.gnu.org/archive/html/bug-gnu-emacs/2007-12/msg00134.html - -** bojohan+news@dd.chalmers.se, 19 Nov: appointment display during isearch replaces buffer contents with history element. -http://lists.gnu.org/archive/html/bug-gnu-emacs/2008-01/msg00005.html -(patch) - ** eric@openbsd.org, 24 Nov: c-mode syntactic analysis regression in emacs-22.1 http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00589.html @@ -65,7 +58,7 @@ http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00460.html reproducible? ** nico@ngolde.de, 7 Jan: some code issues -some unsafe code in pop.c +some unsafe code in pop.c, etags.c http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00654.html * DOCUMENTATION diff --git a/src/ChangeLog b/src/ChangeLog index 7efd990fc0f..287959462be 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-01-10 Chong Yidong + + * process.c (wait_reading_process_output): Check for window + changes caused by timers. + 2008-01-08 Glenn Morris * emacs.c (main): Set copyright year to 2008. diff --git a/src/process.c b/src/process.c index bf974352a29..f7abc7993d3 100644 --- a/src/process.c +++ b/src/process.c @@ -4697,6 +4697,7 @@ wait_reading_process_output (time_limit, microsecs, read_kbd, do_display, { int old_timers_run = timers_run; struct buffer *old_buffer = current_buffer; + Lisp_Object old_window = selected_window; int leave = 0; if (detect_input_pending_run_timers (do_display)) @@ -4710,7 +4711,8 @@ wait_reading_process_output (time_limit, microsecs, read_kbd, do_display, an alike. Make read_key_sequence aware of that. */ if (timers_run != old_timers_run && waiting_for_user_input_p == -1 - && old_buffer != current_buffer) + && (old_buffer != current_buffer + || !EQ (old_window, selected_window))) record_asynch_buffer_change (); if (leave) From acb93bb2a68eac61448a2da39e9f7f0b14d6869b Mon Sep 17 00:00:00 2001 From: Michael Kifer Date: Thu, 10 Jan 2008 06:54:12 +0000 Subject: [PATCH 044/439] 2008-01-10 Michael Kifer * ediff*.el: uncommented declare-function. * viper*.el: uncommented declare-function. --- lisp/ChangeLog | 6 ++++++ lisp/ediff-util.el | 7 ++++--- lisp/ediff-wind.el | 10 +++++++--- lisp/ediff.el | 8 +++++--- lisp/emulation/viper-cmd.el | 10 ++++++---- lisp/emulation/viper-keym.el | 10 ++++++---- lisp/emulation/viper-util.el | 6 ++++-- 7 files changed, 38 insertions(+), 19 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 798ed9ec3a6..e0244aa5d4b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-10 Michael Kifer + + * ediff*.el: uncommented declare-function. + + * viper*.el: uncommented declare-function. + 2008-01-09 Tassilo Horn * doc-view.el (doc-view-mode): Support tramp, compressed files and diff --git a/lisp/ediff-util.el b/lisp/ediff-util.el index 94e0d87bf9c..058e20f6a19 100644 --- a/lisp/ediff-util.el +++ b/lisp/ediff-util.el @@ -41,6 +41,9 @@ (defvar ediff-after-quit-hook-internal nil) +(eval-and-compile + (unless (fboundp 'declare-function) (defmacro declare-function (&rest r)))) + (eval-when-compile (let ((load-path (cons (expand-file-name ".") load-path))) (provide 'ediff-util) ; to break recursive load cycle @@ -2820,10 +2823,8 @@ up an appropriate window config." (message "To resume, type M-x eregistry and select the desired Ediff session")) - ;; ediff-barf-if-not-control-buffer ensures only called from ediff. -;; declare-function does not exist in XEmacs -;;(declare-function ediff-version "ediff" ())) +(declare-function ediff-version "ediff" ()) (defun ediff-status-info () "Show the names of the buffers or files being operated on by Ediff. diff --git a/lisp/ediff-wind.el b/lisp/ediff-wind.el index 7e5eff6392e..26aa19f38a4 100644 --- a/lisp/ediff-wind.el +++ b/lisp/ediff-wind.el @@ -40,6 +40,11 @@ (defvar frame-icon-title-format) (defvar ediff-diff-status) +;; declare-function does not exist in XEmacs +(eval-and-compile + (unless (fboundp 'declare-function) (defmacro declare-function (&rest r)))) + + (eval-when-compile (let ((load-path (cons (expand-file-name ".") load-path))) (or (featurep 'ediff-init) @@ -147,10 +152,9 @@ In this case, Ediff will use those frames to display these buffers." :type 'function :group 'ediff-window) -;; declare-function does not exist in XEmacs ;; Definitions hidden from the compiler by compat wrappers. -;;(declare-function ediff-display-pixel-width "ediff-init") -;;(declare-function ediff-display-pixel-height "ediff-init") +(declare-function ediff-display-pixel-width "ediff-init") +(declare-function ediff-display-pixel-height "ediff-init") (defconst ediff-control-frame-parameters (list diff --git a/lisp/ediff.el b/lisp/ediff.el index 2caa3715f48..cdfb66d9c00 100644 --- a/lisp/ediff.el +++ b/lisp/ediff.el @@ -113,6 +113,9 @@ (defvar ediff-last-dir-patch) (defvar ediff-patch-default-directory) +(eval-and-compile + (unless (fboundp 'declare-function) (defmacro declare-function (&rest r)))) + (eval-when-compile (and noninteractive @@ -361,8 +364,7 @@ (list (cons 'ediff-job-name job-name)) merge-buffer-file))) -;; declare-function does not exist in XEmacs -;;(declare-function diff-latest-backup-file "diff" (fn))) +(declare-function diff-latest-backup-file "diff" (fn)) ;;;###autoload (defalias 'ediff 'ediff-files) @@ -1428,7 +1430,7 @@ When called interactively, displays the version." (format "Ediff %s of %s" ediff-version ediff-date))) ;; info is run first, and will autoload info.el. -;;(declare-function Info-goto-node "info" (nodename &optional fork)) +(declare-function Info-goto-node "info" (nodename &optional fork)) ;;;###autoload (defun ediff-documentation (&optional node) diff --git a/lisp/emulation/viper-cmd.el b/lisp/emulation/viper-cmd.el index fbebacb16b5..68116cde092 100644 --- a/lisp/emulation/viper-cmd.el +++ b/lisp/emulation/viper-cmd.el @@ -47,6 +47,9 @@ (defvar initial) (defvar undo-beg-posn) (defvar undo-end-posn) + +(eval-and-compile + (unless (fboundp 'declare-function) (defmacro declare-function (&rest r)))) ;; end pacifier @@ -3083,10 +3086,9 @@ On reaching beginning of line, stop and signal error." (setq this-command 'next-line) (if com (viper-execute-com 'viper-next-line val com)))) -;; declare-function is not defined in XEmacs -;;(declare-function widget-type "wid-edit" (widget)) -;;(declare-function widget-button-press "wid-edit" (pos &optional event)) -;;(declare-function viper-set-hooks "viper" ()) +(declare-function widget-type "wid-edit" (widget)) +(declare-function widget-button-press "wid-edit" (pos &optional event)) +(declare-function viper-set-hooks "viper" ()) (defun viper-next-line-at-bol (arg) "Next line at beginning of line. diff --git a/lisp/emulation/viper-keym.el b/lisp/emulation/viper-keym.el index 02df3fe3084..05c90f995ab 100644 --- a/lisp/emulation/viper-keym.el +++ b/lisp/emulation/viper-keym.el @@ -33,14 +33,16 @@ (defvar viper-expert-level) (defvar viper-ex-style-editing) (defvar viper-ex-style-motion) + +(eval-and-compile + (unless (fboundp 'declare-function) (defmacro declare-function (&rest r)))) ;; end pacifier (require 'viper-util) -;; declare-function is not defined in XEmacs -;;(declare-function viper-ex "viper-ex" (arg &optional string)) -;;(declare-function viper-normalize-minor-mode-map-alist "viper-cmd" ()) -;;(declare-function viper-set-mode-vars-for "viper-cmd" (state)) +(declare-function viper-ex "viper-ex" (arg &optional string)) +(declare-function viper-normalize-minor-mode-map-alist "viper-cmd" ()) +(declare-function viper-set-mode-vars-for "viper-cmd" (state)) ;;; Variables diff --git a/lisp/emulation/viper-util.el b/lisp/emulation/viper-util.el index 2bd2a3e276a..b838d8ce80e 100644 --- a/lisp/emulation/viper-util.el +++ b/lisp/emulation/viper-util.el @@ -44,6 +44,9 @@ (require 'ring) +(eval-and-compile + (unless (fboundp 'declare-function) (defmacro declare-function (&rest r)))) + ;; end pacifier (require 'viper-init) @@ -374,8 +377,7 @@ -;; declare-function is not defined in XEmacs -;;(declare-function viper-forward-Word "viper-cmd" (arg)) +(declare-function viper-forward-Word "viper-cmd" (arg)) ;;; Support for :e, :r, :w file globbing From e1776067924d2a8095dffe6d07733ba04f00b9f6 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Thu, 10 Jan 2008 07:05:10 +0000 Subject: [PATCH 045/439] (verilog-mode-map): Don't bind C-M-a, C-M-e and C-M-h for emacs, they work by default. (verilog-emacs-features): Remove. (verilog-setup-dual-comments, verilog-populate-syntax-table): Remove. Move syntax table initialization ... (verilog-mode-syntax-table): ... here. (verilog-mode): Don't initialize the syntax table here. (verilog-mark-defun): Only do something useful for XEmacs, emacs does not need it. --- lisp/ChangeLog | 12 ++ lisp/progmodes/verilog-mode.el | 206 ++++++++------------------------- 2 files changed, 60 insertions(+), 158 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b26216ab59d..38b2d418ff3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,15 @@ +2008-01-10 Dan Nicolaescu + + * progmodes/verilog-mode.el (verilog-mode-map): Don't bind C-M-a, + C-M-e and C-M-h for emacs, they work by default. + (verilog-emacs-features): Remove. + (verilog-setup-dual-comments, verilog-populate-syntax-table): + Remove. Move syntax table initialization ... + (verilog-mode-syntax-table): ... here. + (verilog-mode): Don't initialize the syntax table here. + (verilog-mark-defun): Only do something useful for XEmacs, emacs + does not need it. + 2008-01-10 Glenn Morris * shell.el (shell-dirtrack-verbose, shell-mode) diff --git a/lisp/progmodes/verilog-mode.el b/lisp/progmodes/verilog-mode.el index a1611b0eada..c177ca1b184 100644 --- a/lisp/progmodes/verilog-mode.el +++ b/lisp/progmodes/verilog-mode.el @@ -933,7 +933,6 @@ If set will become buffer local.") (define-key map "\M-\r" `electric-verilog-terminate-and-indent) (define-key map "\M-\t" 'verilog-complete-word) (define-key map "\M-?" 'verilog-show-completions) - (define-key map [(meta control h)] 'verilog-mark-defun) (define-key map "\C-c\`" 'verilog-lint-off) (define-key map "\C-c\*" 'verilog-delete-auto-star-implicit) (define-key map "\C-c\C-r" 'verilog-label-be) @@ -943,8 +942,10 @@ If set will become buffer local.") (define-key map "\M-*" 'verilog-star-comment) (define-key map "\C-c\C-c" 'verilog-comment-region) (define-key map "\C-c\C-u" 'verilog-uncomment-region) - (define-key map "\M-\C-a" 'verilog-beg-of-defun) - (define-key map "\M-\C-e" 'verilog-end-of-defun) + (when (featurep 'xemacs) + (define-key map [(meta control h)] 'verilog-mark-defun) + (define-key map "\M-\C-a" 'verilog-beg-of-defun) + (define-key map "\M-\C-e" 'verilog-end-of-defun)) (define-key map "\C-c\C-d" 'verilog-goto-defun) (define-key map "\C-c\C-k" 'verilog-delete-auto) (define-key map "\C-c\C-a" 'verilog-auto) @@ -957,7 +958,7 @@ If set will become buffer local.") ;; menus (defvar verilog-xemacs-menu - '("Verilog" + `("Verilog" ("Choose Compilation Action" ["None" (progn @@ -991,9 +992,15 @@ If set will become buffer local.") :selected (equal verilog-tool `verilog-compiler)] ) ("Move" - ["Beginning of function" verilog-beg-of-defun t] - ["End of function" verilog-end-of-defun t] - ["Mark function" verilog-mark-defun t] + ,(if (featurep 'xemacs) + (progn + ["Beginning of function" verilog-beg-of-defun t] + ["End of function" verilog-end-of-defun t] + ["Mark function" verilog-mark-defun t]) + ["Beginning of function" beginning-of-defun t] + ["End of function" end-of-defun t] + ["Mark function" mark-defun t]) + ["Goto function/module" verilog-goto-defun t] ["Move to beginning of block" electric-verilog-backward-sexp t] ["Move to end of block" electric-verilog-forward-sexp t] @@ -1714,151 +1721,37 @@ find the errors." ) "List of Verilog keywords.") - -(defconst verilog-emacs-features - ;; Documentation at the bottom - (let ((major (and (boundp 'emacs-major-version) - emacs-major-version)) - (minor (and (boundp 'emacs-minor-version) - emacs-minor-version)) - flavor comments flock-syntax) - ;; figure out version numbers if not already discovered - (and (or (not major) (not minor)) - (string-match "\\([0-9]+\\).\\([0-9]+\\)" emacs-version) - (setq major (string-to-number (substring emacs-version - (match-beginning 1) - (match-end 1))) - minor (string-to-number (substring emacs-version - (match-beginning 2) - (match-end 2))))) - (if (not (and major minor)) - (error "Cannot figure out the major and minor version numbers")) - ;; calculate the major version - (cond - ((= major 4) (setq major 'v18)) ;Epoch 4 - ((= major 18) (setq major 'v18)) ;Emacs 18 - ((= major 19) (setq major 'v19 ;Emacs 19 - flavor (if (or (string-match "Lucid" emacs-version) - (string-match "XEmacs" emacs-version)) - 'XEmacs 'FSF))) - ((> major 19) (setq major 'v20 - flavor (if (or (string-match "Lucid" emacs-version) - (string-match "XEmacs" emacs-version)) - 'XEmacs 'FSF))) - ;; I don't know - (t (error "Cannot recognize major version number: %s" major))) - ;; XEmacs 19 uses 8-bit modify-syntax-entry flags, as do all - ;; patched Emacs 19, Emacs 18, Epoch 4's. Only Emacs 19 uses a - ;; 1-bit flag. Let's be as smart as we can about figuring this - ;; out. - (if (or (eq major 'v20) (eq major 'v19)) - (let ((table (copy-syntax-table))) - (modify-syntax-entry ?a ". 12345678" table) - (cond - ;; XEmacs pre 20 and Emacs pre 19.30 use vectors for syntax tables. - ((vectorp table) - (if (= (logand (lsh (aref table ?a) -16) 255) 255) - (setq comments '8-bit) - (setq comments '1-bit))) - ;; XEmacs 20 is known to be 8-bit - ((eq flavor 'XEmacs) (setq comments '8-bit)) - ;; Emacs 19.30 and beyond are known to be 1-bit - ((eq flavor 'FSF) (setq comments '1-bit)) - ;; Don't know what this is - (t (error "Couldn't figure out syntax table format")))) - ;; Emacs 18 has no support for dual comments - (setq comments 'no-dual-comments)) - ;; determine whether to use old or new font lock syntax - ;; We can assume 8-bit syntax table emacsen support new syntax, otherwise - ;; look for version > 19.30 - (setq flock-syntax - (if (or (equal comments '8-bit) - (equal major 'v20) - (and (equal major 'v19) (> minor 30))) - 'flock-syntax-after-1930 - 'flock-syntax-before-1930)) - ;; lets do some minimal sanity checking. - (if (or - ;; Emacs before 19.6 had bugs - (and (eq major 'v19) (eq flavor 'XEmacs) (< minor 6)) - ;; Emacs 19 before 19.21 has known bugs - (and (eq major 'v19) (eq flavor 'FSF) (< minor 21))) - (with-output-to-temp-buffer "*verilog-mode warnings*" - (print (format - "The version of Emacs that you are running, %s, -has known bugs in its syntax parsing routines which will affect the -performance of verilog-mode. You should strongly consider upgrading to the -latest available version. verilog-mode may continue to work, after a -fashion, but strange indentation errors could be encountered." - emacs-version)))) - ;; Emacs 18, with no patch is not too good - (if (and (eq major 'v18) (eq comments 'no-dual-comments)) - (with-output-to-temp-buffer "*verilog-mode warnings*" - (print (format - "The version of Emacs 18 you are running, %s, -has known deficiencies in its ability to handle the dual verilog -\(and C++) comments, (e.g. the // and /* */ comments). This will -not be much of a problem for you if you only use the /* */ comments, -but you really should strongly consider upgrading to one of the latest -Emacs 19's. In Emacs 18, you may also experience performance degradations. -Emacs 19 has some new built-in routines which will speed things up for you. -Because of these inherent problems, verilog-mode is not supported -on emacs-18." - emacs-version)))) - ;; Emacs 18 with the syntax patches are no longer supported - (if (and (eq major 'v18) (not (eq comments 'no-dual-comments))) - (with-output-to-temp-buffer "*verilog-mode warnings*" - (print (format - "You are running a syntax patched Emacs 18 variant. While this should -work for you, you may want to consider upgrading to Emacs 19. -The syntax patches are no longer supported either for verilog-mode.")))) - (list major comments flock-syntax)) - "A list of features extant in the Emacs you are using. -There are many flavors of Emacs out there, each with different -features supporting those needed by `verilog-mode'. Here's the current -supported list, along with the values for this variable: - - Vanilla Emacs 18/Epoch 4: (v18 no-dual-comments flock-syntax-before-1930) - Emacs 18/Epoch 4 (patch2): (v18 8-bit flock-syntax-after-1930) - XEmacs (formerly Lucid) 19: (v19 8-bit flock-syntax-after-1930) - XEmacs 20: (v20 8-bit flock-syntax-after-1930) - Emacs 19.1-19.30: (v19 8-bit flock-syntax-before-1930) - Emacs 19.31-19.xx: (v19 8-bit flock-syntax-after-1930) - Emacs20 : (v20 1-bit flock-syntax-after-1930).") - (defconst verilog-comment-start-regexp "//\\|/\\*" "Dual comment value for `comment-start-regexp'.") -(defun verilog-populate-syntax-table (table) - "Populate the syntax TABLE." - (modify-syntax-entry ?\\ "\\" table) - (modify-syntax-entry ?+ "." table) - (modify-syntax-entry ?- "." table) - (modify-syntax-entry ?= "." table) - (modify-syntax-entry ?% "." table) - (modify-syntax-entry ?< "." table) - (modify-syntax-entry ?> "." table) - (modify-syntax-entry ?& "." table) - (modify-syntax-entry ?| "." table) - (modify-syntax-entry ?` "w" table) - (modify-syntax-entry ?_ "w" table) - (modify-syntax-entry ?\' "." table)) +(defvar verilog-mode-syntax-table + (let ((table (make-syntax-table))) + ;; Populate the syntax TABLE. + (modify-syntax-entry ?\\ "\\" table) + (modify-syntax-entry ?+ "." table) + (modify-syntax-entry ?- "." table) + (modify-syntax-entry ?= "." table) + (modify-syntax-entry ?% "." table) + (modify-syntax-entry ?< "." table) + (modify-syntax-entry ?> "." table) + (modify-syntax-entry ?& "." table) + (modify-syntax-entry ?| "." table) + (modify-syntax-entry ?` "w" table) + (modify-syntax-entry ?_ "w" table) + (modify-syntax-entry ?\' "." table) -(defun verilog-setup-dual-comments (table) - "Set up TABLE to handle block and line style comments." - (cond - ((memq '8-bit verilog-emacs-features) - ;; XEmacs (formerly Lucid) has the best implementation - (modify-syntax-entry ?/ ". 1456" table) - (modify-syntax-entry ?* ". 23" table) - (modify-syntax-entry ?\n "> b" table)) - ((memq '1-bit verilog-emacs-features) - ;; Emacs 19 does things differently, but we can work with it - (modify-syntax-entry ?/ ". 124b" table) - (modify-syntax-entry ?* ". 23" table) - (modify-syntax-entry ?\n "> b" table)))) - -(defvar verilog-mode-syntax-table nil + ;; Set up TABLE to handle block and line style comments. + (if (featurep 'xemacs) + (progn + ;; XEmacs (formerly Lucid) has the best implementation + (modify-syntax-entry ?/ ". 1456" table) + (modify-syntax-entry ?* ". 23" table) + (modify-syntax-entry ?\n "> b" table)) + ;; Emacs 19 does things differently, but we can work with it + (modify-syntax-entry ?/ ". 124b" table) + (modify-syntax-entry ?* ". 23" table) + (modify-syntax-entry ?\n "> b" table)) + table) "Syntax table used in `verilog-mode' buffers.") (defvar verilog-font-lock-keywords nil @@ -2422,14 +2315,10 @@ Key bindings specific to `verilog-mode-map' are: (setq major-mode 'verilog-mode) (setq mode-name "Verilog") (setq local-abbrev-table verilog-mode-abbrev-table) - (setq verilog-mode-syntax-table (make-syntax-table)) - (verilog-populate-syntax-table verilog-mode-syntax-table) (set (make-local-variable 'beginning-of-defun-function) 'verilog-beg-of-defun) (set (make-local-variable 'end-of-defun-function) 'verilog-end-of-defun) - ;; add extra comment syntax - (verilog-setup-dual-comments verilog-mode-syntax-table) (set-syntax-table verilog-mode-syntax-table) (make-local-variable 'indent-line-function) (setq indent-line-function 'verilog-indent-line-relative) @@ -2751,12 +2640,13 @@ following code fragment: "Mark the current verilog function (or procedure). This puts the mark at the end, and point at the beginning." (interactive) - (push-mark (point)) - (verilog-end-of-defun) - (push-mark (point)) - (verilog-beg-of-defun) - (if (fboundp 'zmacs-activate-region) - (zmacs-activate-region))) + (when (featurep 'xemacs) + (push-mark (point)) + (verilog-end-of-defun) + (push-mark (point)) + (verilog-beg-of-defun) + (if (fboundp 'zmacs-activate-region) + (zmacs-activate-region)))) (defun verilog-comment-region (start end) ; checkdoc-params: (start end) From b6fe5b19b12215ed6ad04d57e8ea4c6b2331744e Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Thu, 10 Jan 2008 07:51:25 +0000 Subject: [PATCH 046/439] * vc.el (vc-status-unmark-all-files): New function. (vc-status-unmark-all-files): Likewise. (vc-status-mode-map): Add bindings. --- lisp/ChangeLog | 12 +++++++++--- lisp/vc.el | 22 ++++++++++++++++++++++ 2 files changed, 31 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e0244aa5d4b..9afc7d600d5 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,9 +1,15 @@ +2008-01-10 Tom Tromey + + * vc.el (vc-status-unmark-all-files): New function. + (vc-status-unmark-all-files): Likewise. + (vc-status-mode-map): Add bindings. + 2008-01-10 Michael Kifer - + * ediff*.el: uncommented declare-function. - + * viper*.el: uncommented declare-function. - + 2008-01-09 Tassilo Horn * doc-view.el (doc-view-mode): Support tramp, compressed files and diff --git a/lisp/vc.el b/lisp/vc.el index 5966cfb7a7e..88915f3715f 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -2552,8 +2552,10 @@ With prefix arg READ-SWITCHES, specify a value to override (suppress-keymap map) ;; Marking. (define-key map "m" 'vc-status-mark-file) + (define-key map "M" 'vc-status-mark-all-files) (define-key map "u" 'vc-status-unmark-file) (define-key map "\C-?" 'vc-status-unmark-file-up) + (define-key map "\M-\C-?" 'vc-status-unmark-all-files) ;; Movement. (define-key map "n" 'vc-status-next-line) (define-key map " " 'vc-status-next-line) @@ -2627,6 +2629,16 @@ If a prefix argument is given, move by that many lines." (ewoc-invalidate vc-status crt) (vc-status-next-line 1))) +(defun vc-status-mark-all-files () + "Mark all files." + (interactive) + (ewoc-map + (lambda (file) + (unless (vc-status-fileinfo->marked file) + (setf (vc-status-fileinfo->marked file) t) + t)) + vc-status)) + (defun vc-status-unmark-file () "Unmark the current file and move to the next line." (interactive) @@ -2648,6 +2660,16 @@ If a prefix argument is given, move by that many lines." (ewoc-invalidate vc-status prev) (vc-status-move-to-goal-column))) +(defun vc-status-unmark-all-files () + "Unmark all files." + (interactive) + (ewoc-map + (lambda (file) + (when (vc-status-fileinfo->marked file) + (setf (vc-status-fileinfo->marked file) nil) + t)) + vc-status)) + (defun vc-status-register () "Register the marked files, or the current file if no marks." (interactive) From 20aa98dd7126b53d13fee75be26459d9a2b7505e Mon Sep 17 00:00:00 2001 From: Nick Roberts Date: Thu, 10 Jan 2008 10:25:15 +0000 Subject: [PATCH 047/439] *** empty log message *** --- lisp/ChangeLog | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 38b2d418ff3..9e50b27135f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2008-01-10 Nick Roberts + + * progmodes/gdb-ui.el (gdb-dequeue-input): Make doubly sure + session doesn't hang because gdb-pending-triggers is non-nil. + (gdb-frame-handler): Use buffer-file-name instead of + buffer-name in case of duplicate file names. + 2008-01-10 Dan Nicolaescu * progmodes/verilog-mode.el (verilog-mode-map): Don't bind C-M-a, From 78971dff706c88562bdd848d2aea623401dc7049 Mon Sep 17 00:00:00 2001 From: Nick Roberts Date: Thu, 10 Jan 2008 10:27:02 +0000 Subject: [PATCH 048/439] (gdb-dequeue-input): Make doubly sure session doesn't hang because gdb-pending-triggers is non-nil. (gdb-frame-handler): Use buffer-file-name instead of buffer-name in case of duplicate file names. --- lisp/progmodes/gdb-ui.el | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/lisp/progmodes/gdb-ui.el b/lisp/progmodes/gdb-ui.el index ef11668f022..d85bf23c7c5 100644 --- a/lisp/progmodes/gdb-ui.el +++ b/lisp/progmodes/gdb-ui.el @@ -1214,10 +1214,12 @@ This filter may simply queue input for a later time." (defun gdb-dequeue-input () (let ((queue gdb-input-queue)) - (and queue - (let ((last (car (last queue)))) - (unless (nbutlast queue) (setq gdb-input-queue '())) - last)))) + (if queue + (let ((last (car (last queue)))) + (unless (nbutlast queue) (setq gdb-input-queue '())) + last) + ;; This should be nil here anyway but set it just to make sure. + (setq gdb-pending-triggers nil)))) (defun gdb-send-item (item) (setq gdb-flush-pending-output nil) @@ -3442,7 +3444,8 @@ BUFFER nil or omitted means use the current buffer." (let ((buffer (marker-buffer gud-overlay-arrow-position)) (position (marker-position gud-overlay-arrow-position))) (when (and buffer - (string-equal (buffer-name buffer) + (string-equal (file-name-nondirectory + (buffer-file-name buffer)) (file-name-nondirectory (match-string 3)))) (with-current-buffer buffer (setq fringe-indicator-alist From dae8c7842c9703fc13ab118317fd7c2e76a3c767 Mon Sep 17 00:00:00 2001 From: Nick Roberts Date: Thu, 10 Jan 2008 11:26:42 +0000 Subject: [PATCH 049/439] *** empty log message *** --- lisp/ChangeLog | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9e50b27135f..c54e9abec57 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,7 @@ 2008-01-10 Nick Roberts + * comint.el (comint-insert-input): Set point first. + * progmodes/gdb-ui.el (gdb-dequeue-input): Make doubly sure session doesn't hang because gdb-pending-triggers is non-nil. (gdb-frame-handler): Use buffer-file-name instead of From d1497e8d4d6842e8f47333360f155164196f0d66 Mon Sep 17 00:00:00 2001 From: Nick Roberts Date: Thu, 10 Jan 2008 11:28:33 +0000 Subject: [PATCH 050/439] (comint-insert-input): Set point first. --- lisp/comint.el | 1 + 1 file changed, 1 insertion(+) diff --git a/lisp/comint.el b/lisp/comint.el index b666ff42f37..0a22cdba5c9 100644 --- a/lisp/comint.el +++ b/lisp/comint.el @@ -820,6 +820,7 @@ buffer. The hook `comint-exec-hook' is run after each exec." If there is no previous input at point, run the command specified by the global keymap (usually `mouse-yank-at-point')." (interactive "e") + (mouse-set-point event) (let ((pos (posn-point (event-end event))) field input) (with-selected-window (posn-window (event-end event)) From 0e8356fe05318a591743e7457e223968eba89f1b Mon Sep 17 00:00:00 2001 From: Tassilo Horn Date: Thu, 10 Jan 2008 11:29:41 +0000 Subject: [PATCH 051/439] 2008-01-10 Tassilo Horn * doc-view.el (tramp): Require tramp because we use tramp-tramp-file-p. --- lisp/ChangeLog | 5 +++++ lisp/doc-view.el | 1 + 2 files changed, 6 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9afc7d600d5..fc938a89929 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-10 Tassilo Horn + + * doc-view.el (tramp): Require tramp because we use + tramp-tramp-file-p. + 2008-01-10 Tom Tromey * vc.el (vc-status-unmark-all-files): New function. diff --git a/lisp/doc-view.el b/lisp/doc-view.el index 92159776269..f2bfb1c70fd 100644 --- a/lisp/doc-view.el +++ b/lisp/doc-view.el @@ -135,6 +135,7 @@ (require 'dired) (require 'image-mode) (require 'jka-compr) +(require 'tramp) ;; would be better to make tramp-tramp-file-p autoloaded ;;;; Customization Options From 146b3daf07f58412b21d44b95e43d48c9719c78b Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Thu, 10 Jan 2008 14:01:13 +0000 Subject: [PATCH 052/439] (safe-local-eval-forms): Mark (add-hook 'write-file-hooks 'time-stamp) as safe. --- lisp/ChangeLog | 7 ++++++- lisp/files.el | 4 ++-- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c54e9abec57..389f7b70fb7 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,10 +1,15 @@ +2008-01-10 Dan Nicolaescu + + * files.el (safe-local-eval-forms): Mark + (add-hook 'write-file-hooks 'time-stamp) as safe. + 2008-01-10 Nick Roberts * comint.el (comint-insert-input): Set point first. * progmodes/gdb-ui.el (gdb-dequeue-input): Make doubly sure session doesn't hang because gdb-pending-triggers is non-nil. - (gdb-frame-handler): Use buffer-file-name instead of + (gdb-frame-handler): Use buffer-file-name instead of buffer-name in case of duplicate file names. 2008-01-10 Dan Nicolaescu diff --git a/lisp/files.el b/lisp/files.el index aa6e7f1082a..ea327f48f2c 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -2418,13 +2418,13 @@ symbol and VAL is a value that is considered safe." :group 'find-file :type 'alist) -(defcustom safe-local-eval-forms nil +(defcustom safe-local-eval-forms '((add-hook 'write-file-hooks 'time-stamp)) "Expressions that are considered safe in an `eval:' local variable. Add expressions to this list if you want Emacs to evaluate them, when they appear in an `eval' local variable specification, without first asking you for confirmation." :group 'find-file - :version "22.1" + :version "22.2" :type '(repeat sexp)) ;; Risky local variables: From 11f6a31de4d94c6151cfbcc9f78eccfb82de6113 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Thu, 10 Jan 2008 14:17:06 +0000 Subject: [PATCH 053/439] (vc-svn-registered): Return the correct value for ignored and unregistered files. --- lisp/ChangeLog | 5 +++++ lisp/vc-svn.el | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index fc938a89929..dbba47e0883 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-10 Dan Nicolaescu + + * vc-svn.el (vc-svn-registered): Return the correct value for + ignored and unregistered files. + 2008-01-10 Tassilo Horn * doc-view.el (tramp): Require tramp because we use diff --git a/lisp/vc-svn.el b/lisp/vc-svn.el index f50d5ab5dee..e387b57d4fe 100644 --- a/lisp/vc-svn.el +++ b/lisp/vc-svn.el @@ -132,7 +132,8 @@ If you want to force an empty list of arguments, use t." ;; an `error' by vc-do-command. (error nil)))) (when (eq 0 status) - (vc-svn-parse-status file)))))) + (not (memq (vc-svn-parse-status file) + '(ignored unregistered)))))))) (defun vc-svn-state (file &optional localp) "SVN-specific version of `vc-state'." From 95838435c8ab907e292852a706a7727c8437c59a Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Thu, 10 Jan 2008 14:18:23 +0000 Subject: [PATCH 054/439] Merge from gnus--devo--0 Revision: emacs@sv.gnu.org/emacs--devo--0--patch-992 --- doc/misc/ChangeLog | 7 +++ doc/misc/gnus.texi | 17 ++++-- lisp/gnus/ChangeLog | 36 ++++++++++++ lisp/gnus/gnus-art.el | 118 +++++++++++++++++++++++++++------------- lisp/gnus/gnus-group.el | 92 ++++++++++++++++++++++++------- 5 files changed, 206 insertions(+), 64 deletions(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index 12ec5d31242..0fd7a5dbe8c 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,10 @@ +2008-01-09 Katsumi Yamaoka + + * gnus.texi (Article Keymap): Add + gnus-article-wide-reply-with-original; fix descriptions of + gnus-article-reply-with-original and + gnus-article-followup-with-original. + 2008-01-09 Glenn Morris * nxml-mode.texi: Add @copying section. diff --git a/doc/misc/gnus.texi b/doc/misc/gnus.texi index 690c63e4460..ba61fd72247 100644 --- a/doc/misc/gnus.texi +++ b/doc/misc/gnus.texi @@ -11900,17 +11900,22 @@ Go to the previous button, if any (@code{gnus-article-prev-button}). @kindex R (Article) @findex gnus-article-reply-with-original Send a reply to the current article and yank the current article -(@code{gnus-article-reply-with-original}). If given a prefix, make a -wide reply. If the region is active, only yank the text in the -region. +(@code{gnus-article-reply-with-original}). If the region is active, +only yank the text in the region. + +@item S W +@kindex S W (Article) +@findex gnus-article-wide-reply-with-original +Send a wide reply to the current article and yank the current article +(@code{gnus-article-wide-reply-with-original}). If the region is +active, only yank the text in the region. @item F @kindex F (Article) @findex gnus-article-followup-with-original Send a followup to the current article and yank the current article -(@code{gnus-article-followup-with-original}). If given a prefix, make -a wide reply. If the region is active, only yank the text in the -region. +(@code{gnus-article-followup-with-original}). If the region is active, +only yank the text in the region. @end table diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 728ea9a424a..e3d4fcb0abc 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog @@ -1,3 +1,39 @@ +2008-01-10 Katsumi Yamaoka + + * gnus-art.el (gnus-article-read-summary-keys): Work for `C-h' on + XEmacs. + (gnus-article-describe-key, gnus-article-describe-key-briefly): Protect + against non-character events. + + * lpath.el: Fbind map-keymap for Emacs 21. + +2008-01-09 Reiner Steib + + * gnus-group.el (gnus-group-read-ephemeral-gmane-group-url): New + command. + (gnus-group-read-ephemeral-gmane-group): Use optional argument RANGE + instead of END. Change name of the temp file. + (gnus-group-gmane-group-download-format): Add doc string. Make it + customizable. + +2008-01-09 Katsumi Yamaoka + + * gnus-art.el (gnus-article-send-map): New keymap for `S' prefix keys; + bind `S W' to gnus-article-wide-reply-with-original; set default + binding to gnus-article-read-summary-send-keys. + (gnus-article-read-summary-keys): Fix the order of keys; display + continuation keys correctly in the echo area; describe bindings + correctly when keys end with `C-h'. + (gnus-article-read-summary-send-keys): New function. + (gnus-article-describe-key, gnus-article-describe-key-briefly): Work + for gnus-article-read-summary-send-keys; display continuation keys + correctly in the echo area. + (gnus-article-reply-with-original): Ignore prefix argument. + (gnus-article-wide-reply-with-original): New function. + + * lpath.el: Fbind character-to-event and set-keymap-default-binding for + Emacs 21. + 2008-01-08 Katsumi Yamaoka * gnus-bookmark.el (gnus-bookmark-mouse-available-p): Don't test for diff --git a/lisp/gnus/gnus-art.el b/lisp/gnus/gnus-art.el index fda62bc79aa..f34f8f7376a 100644 --- a/lisp/gnus/gnus-art.el +++ b/lisp/gnus/gnus-art.el @@ -4225,6 +4225,13 @@ If variable `gnus-use-long-file-name' is non-nil, it is (substitute-key-definition 'undefined 'gnus-article-read-summary-keys gnus-article-mode-map) +(gnus-define-keys (gnus-article-send-map "S" gnus-article-mode-map) + "W" gnus-article-wide-reply-with-original) +(if (featurep 'xemacs) + (set-keymap-default-binding gnus-article-send-map + 'gnus-article-read-summary-send-keys) + (define-key gnus-article-send-map [t] 'gnus-article-read-summary-send-keys)) + (defun gnus-article-make-menu-bar () (unless (boundp 'gnus-article-commands-menu) (gnus-summary-make-menu-bar)) @@ -6243,17 +6250,37 @@ not have a face in `gnus-article-boring-faces'." (save-excursion (set-buffer gnus-article-current-summary) (let (gnus-pick-mode) - (push (or key last-command-event) unread-command-events) - (setq keys (if (featurep 'xemacs) - (events-to-keys (read-key-sequence nil)) - (read-key-sequence nil))))) + (setq unread-command-events (nconc unread-command-events + (list (or key last-command-event))) + keys (if (featurep 'xemacs) + (events-to-keys (read-key-sequence nil t)) + (read-key-sequence nil t))))) (message "") (cond ((eq (aref keys (1- (length keys))) ?\C-h) - (with-current-buffer gnus-article-current-summary - (describe-bindings (substring keys 0 -1)))) + (if (featurep 'xemacs) + (let ((keymap (with-current-buffer gnus-article-current-summary + (copy-keymap (current-local-map))))) + (map-keymap + (lambda (key def) + (define-key keymap (vector ?S key) def)) + gnus-article-send-map) + (with-temp-buffer + (setq major-mode 'gnus-article-mode) + (use-local-map keymap) + (describe-bindings (substring keys 0 -1)))) + (let ((keymap (make-sparse-keymap)) + (map (copy-keymap gnus-article-send-map))) + (define-key keymap "S" map) + (define-key map [t] nil) + (set-keymap-parent keymap + (with-current-buffer gnus-article-current-summary + (current-local-map))) + (with-temp-buffer + (use-local-map keymap) + (describe-bindings (substring keys 0 -1)))))) ((or (member keys nosaves) (member keys nosave-but-article) (member keys nosave-in-article)) @@ -6339,53 +6366,63 @@ not have a face in `gnus-article-boring-faces'." (signal (car err) (cdr err)) (ding)))))))) +(defun gnus-article-read-summary-send-keys () + (interactive) + (let ((unread-command-events (list (if (featurep 'xemacs) + (character-to-event ?S) + ?S)))) + (gnus-article-read-summary-keys))) + (defun gnus-article-describe-key (key) - "Display documentation of the function invoked by KEY. KEY is a string." - (interactive "kDescribe key: ") + "Display documentation of the function invoked by KEY. +KEY is a string or a vector." + (interactive (list (let ((cursor-in-echo-area t)) ;; better for XEmacs. + (read-key-sequence "Describe key: ")))) (gnus-article-check-buffer) - (if (eq (key-binding key) 'gnus-article-read-summary-keys) + (if (memq (key-binding key t) '(gnus-article-read-summary-keys + gnus-article-read-summary-send-keys)) (save-excursion (set-buffer gnus-article-current-summary) - (let (gnus-pick-mode) - (if (featurep 'xemacs) - (progn - (push (elt key 0) unread-command-events) - (setq key (events-to-keys - (read-key-sequence "Describe key: ")))) - (setq unread-command-events - (mapcar - (lambda (x) (if (>= x 128) (list 'meta (- x 128)) x)) - (string-to-list key))) - (setq key (read-key-sequence "Describe key: ")))) - (describe-key key)) + (setq unread-command-events + (if (featurep 'xemacs) + (append key nil) + (mapcar (lambda (x) (if (and (integerp x) (>= x 128)) + (list 'meta (- x 128)) + x)) + key))) + (let ((cursor-in-echo-area t) + gnus-pick-mode) + (describe-key (read-key-sequence nil t)))) (describe-key key))) (defun gnus-article-describe-key-briefly (key &optional insert) - "Display documentation of the function invoked by KEY. KEY is a string." - (interactive "kDescribe key: \nP") + "Display documentation of the function invoked by KEY. +KEY is a string or a vector." + (interactive (list (let ((cursor-in-echo-area t)) ;; better for XEmacs. + (read-key-sequence "Describe key: ")) + current-prefix-arg)) (gnus-article-check-buffer) - (if (eq (key-binding key) 'gnus-article-read-summary-keys) + (if (memq (key-binding key t) '(gnus-article-read-summary-keys + gnus-article-read-summary-send-keys)) (save-excursion (set-buffer gnus-article-current-summary) - (let (gnus-pick-mode) - (if (featurep 'xemacs) - (progn - (push (elt key 0) unread-command-events) - (setq key (events-to-keys - (read-key-sequence "Describe key: ")))) - (setq unread-command-events - (mapcar - (lambda (x) (if (>= x 128) (list 'meta (- x 128)) x)) - (string-to-list key))) - (setq key (read-key-sequence "Describe key: ")))) - (describe-key-briefly key insert)) + (setq unread-command-events + (if (featurep 'xemacs) + (append key nil) + (mapcar (lambda (x) (if (and (integerp x) (>= x 128)) + (list 'meta (- x 128)) + x)) + key))) + (let ((cursor-in-echo-area t) + gnus-pick-mode) + (describe-key-briefly (read-key-sequence nil t) insert))) (describe-key-briefly key insert))) (defun gnus-article-reply-with-original (&optional wide) "Start composing a reply mail to the current message. The text in the region will be yanked. If the region isn't active, the entire article will be yanked." - (interactive "P") + (interactive) (let ((article (cdr gnus-article-current)) contents) (if (not (gnus-region-active-p)) @@ -6400,6 +6437,13 @@ the entire article will be yanked." (gnus-summary-reply (list (list article contents)) wide))))) +(defun gnus-article-wide-reply-with-original () + "Start composing a wide reply mail to the current message. +The text in the region will be yanked. If the region isn't active, +the entire article will be yanked." + (interactive) + (gnus-article-reply-with-original t)) + (defun gnus-article-followup-with-original () "Compose a followup to the current article. The text in the region will be yanked. If the region isn't active, diff --git a/lisp/gnus/gnus-group.el b/lisp/gnus/gnus-group.el index 2be0b6e5c80..ee5068e980d 100644 --- a/lisp/gnus/gnus-group.el +++ b/lisp/gnus/gnus-group.el @@ -2320,44 +2320,94 @@ Return the name of the group if selection was successful." (message "Quit reading the ephemeral group") nil))))) -(defvar gnus-group-gmane-group-download-format - "http://download.gmane.org/%s/%s/%s") +(defcustom gnus-group-gmane-group-download-format + "http://download.gmane.org/%s/%s/%s" + "URL for downloading mbox files. +It must contain three \"%s\". They correspond to the group, the +minimal and maximal article numbers, respectively." + :group 'gnus-group-foreign + :version "23.0" ;; No Gnus + :type 'string) + (autoload 'url-insert-file-contents "url-handlers") +;; FIXME: +;; - Add documentation, menu, key bindings, ... -;; FIXME: Make gnus-group-gmane-group-download-format customizable. Add -;; documentation, menu, key bindings... - -(defun gnus-group-read-ephemeral-gmane-group (group start end) +(defun gnus-group-read-ephemeral-gmane-group (group start &optional range) "Read articles from Gmane group GROUP as an ephemeral group. -START and END specify the articles range. The articles are -downloaded via HTTP using the URL specified by -`gnus-group-gmane-group-download-format'." +START is the first article. RANGE specifies how many articles +are fetched. The articles are downloaded via HTTP using the URL +specified by `gnus-group-gmane-group-download-format'." ;; See for more information. (interactive (list (gnus-group-completing-read "Gmane group: ") (read-number "Start article number: ") - (read-number "End article number: "))) - (when (< (- end start) 0) - (error "Invalid range.")) - (when (> (- end start) - (min (or gnus-large-ephemeral-newsgroup 100) 100)) - (unless (y-or-n-p - (format "Large range (%s to %s), continue anyway? " - start end)) - (error "Range too large. Aborted."))) - (let ((tmpfile (make-temp-file "gmane.gnus-temp-group-"))) + (read-number "How many articles: "))) + (unless range (setq range 500)) + (when (< range 1) + (error "Invalid range: %s" range)) + (let ((tmpfile (make-temp-file + (format "%s.start-%s.range-%s." group start range))) + (gnus-thread-sort-functions '(gnus-thread-sort-by-number))) (with-temp-file tmpfile (url-insert-file-contents (format gnus-group-gmane-group-download-format - group start end)) + group start (+ start range))) (write-region (point-min) (point-max) tmpfile) (gnus-group-read-ephemeral-group - "rs-gnus-read-gmane" + (format "%s.start-%s.range-%s" group start range) `(nndoc ,tmpfile (nndoc-article-type guess)))) (delete-file tmpfile))) +(defun gnus-group-read-ephemeral-gmane-group-url (url) + "Create an ephemeral Gmane group from URL. + +Valid input formats include: +\"http://thread.gmane.org/gmane.foo.bar/12300/focus=12399\", +\"http://thread.gmane.org/gmane.foo.bar/12345/\", +\"http://article.gmane.org/gmane.foo.bar/12345/\", +\"http://news.gmane.org/group/gmane.foo.bar/thread=12345\"" + ;; - Feel free to add other useful Gmane URLs here! Maybe the URLs should + ;; be customizable? + ;; - The URLs should be added to `gnus-button-alist'. Probably we should + ;; prompt the user to decide: "View via `browse-url' or in Gnus? " + ;; (`gnus-group-read-ephemeral-gmane-group-url') + (interactive + (list (gnus-group-completing-read "Gmane URL: "))) + (let (group start range) + (cond + ;; URLs providing `group', `start' and `range': + ((string-match + ;; http://thread.gmane.org/gmane.emacs.devel/86326/focus=86525 + "^http://thread\.gmane\.org/\\([^/]+\\)/\\([0-9]+\\)/focus=\\([0-9]+\\)$" + url) + (setq group (match-string 1 url) + start (string-to-number (match-string 2 url)) + ;; Ensure that `range' is large enough to ensure focus article is + ;; included. + range (- (string-to-number (match-string 3 url)) + start -1))) + ;; URLs providing `group' and `start': + ((or (string-match + ;; http://article.gmane.org/gmane.comp.gnu.make.bugs/3584 + "^http://\\(?:thread\\|article\\)\.gmane\.org/\\([^/]+\\)/\\([0-9]+\\)" + url) + (string-match + ;; Don't advertize these in the doc string yet: + "^\\(?:nntp\\|news\\)://news\.gmane\.org/\\([^/]+\\)/\\([0-9]+\\)" + url) + (string-match + ;; http://news.gmane.org/group/gmane.emacs.gnus.general/thread=65099/force_load=t + "^http://news\.gmane\.org/group/\\([^/]+\\)/thread=\\([0-9]+\\)" + url)) + (setq group (match-string 1 url) + start (string-to-number (match-string 2 url)))) + (t + (error "Can't parse URL %s" url))) + (gnus-group-read-ephemeral-gmane-group group start range))) + (defun gnus-group-jump-to-group (group &optional prompt) "Jump to newsgroup GROUP. From 39a402e3d9bd05c1bdba2527f5130c0653101526 Mon Sep 17 00:00:00 2001 From: Tassilo Horn Date: Thu, 10 Jan 2008 15:08:34 +0000 Subject: [PATCH 055/439] 2008-01-10 Tassilo Horn * doc-view.el (doc-view-buffer-file-name): New variable. (doc-view-convert-current-doc, doc-view-search) (doc-view-current-cache-dir, doc-view-initiate-display) (doc-view-mode): Use it. (doc-view-bookmark-make-cell): Use variable buffer-file-name instead of function. --- lisp/ChangeLog | 9 ++++++ lisp/doc-view.el | 76 ++++++++++++++++++++++++++---------------------- 2 files changed, 51 insertions(+), 34 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index dbba47e0883..118ce1a24a8 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,12 @@ +2008-01-10 Tassilo Horn + + * doc-view.el (doc-view-buffer-file-name): New variable. + (doc-view-convert-current-doc, doc-view-search) + (doc-view-current-cache-dir, doc-view-initiate-display) + (doc-view-mode): Use it. + (doc-view-bookmark-make-cell): Use variable buffer-file-name + instead of function. + 2008-01-10 Dan Nicolaescu * vc-svn.el (vc-svn-registered): Return the correct value for diff --git a/lisp/doc-view.el b/lisp/doc-view.el index f2bfb1c70fd..23bf4096e93 100644 --- a/lisp/doc-view.el +++ b/lisp/doc-view.el @@ -135,7 +135,6 @@ (require 'dired) (require 'image-mode) (require 'jka-compr) -(require 'tramp) ;; would be better to make tramp-tramp-file-p autoloaded ;;;; Customization Options @@ -248,6 +247,14 @@ has finished." (defvar doc-view-previous-major-mode nil "Only used internally.") +(defvar doc-view-buffer-file-name nil + "Only used internally. +The file name used for conversion. Normally it's the same as +`buffer-file-name', but for remote files, compressed files and +files inside an archive it is a temporary copy of +the (uncompressed, extracted) file residing in +`doc-view-cache-directory'.") + ;;;; DocView Keymaps (defvar doc-view-mode-map @@ -451,12 +458,12 @@ It's a subdirectory of `doc-view-cache-directory'." (setq doc-view-current-cache-dir (file-name-as-directory (expand-file-name - (let ((doc buffer-file-name)) - (concat (file-name-nondirectory doc) - "-" - (with-temp-buffer - (insert-file-contents-literally doc) - (md5 (current-buffer))))) + (concat (file-name-nondirectory buffer-file-name) + "-" + (let ((file doc-view-buffer-file-name)) + (with-temp-buffer + (insert-file-contents-literally file) + (md5 (current-buffer))))) doc-view-cache-directory))))) (defun doc-view-remove-if (predicate list) @@ -621,7 +628,7 @@ Should be invoked when the cached images aren't up-to-date." (process-put doc-view-current-converter-process 'pdf-file pdf)) (defun doc-view-convert-current-doc () - "Convert `buffer-file-name' to a set of png files, one file per page. + "Convert `doc-view-buffer-file-name' to a set of png files, one file per page. Those files are saved in the directory given by the function `doc-view-current-cache-dir'." ;; Let stale files still display while we recompute the new ones, so only @@ -633,12 +640,12 @@ Those files are saved in the directory given by the function (let ((png-file (expand-file-name "page-%d.png" (doc-view-current-cache-dir)))) (make-directory (doc-view-current-cache-dir)) - (if (not (string= (file-name-extension buffer-file-name) "dvi")) + (if (not (string= (file-name-extension doc-view-buffer-file-name) "dvi")) ;; Convert to PNG images. - (doc-view-pdf/ps->png buffer-file-name png-file) + (doc-view-pdf/ps->png doc-view-buffer-file-name png-file) ;; DVI files have to be converted to PDF before Ghostscript can process ;; it. - (doc-view-dvi->pdf buffer-file-name + (doc-view-dvi->pdf doc-view-buffer-file-name (expand-file-name "doc.pdf" doc-view-current-cache-dir))))) @@ -848,15 +855,15 @@ If BACKWARD is non-nil, jump to the previous match." ;; We must convert to TXT first! (if doc-view-current-converter-process (message "DocView: please wait till conversion finished.") - (let ((ext (file-name-extension buffer-file-name))) + (let ((ext (file-name-extension doc-view-buffer-file-name))) (cond ((string= ext "pdf") ;; Doc is a PDF, so convert it to TXT - (doc-view-pdf->txt buffer-file-name txt)) + (doc-view-pdf->txt doc-view-buffer-file-name txt)) ((string= ext "ps") ;; Doc is a PS, so convert it to PDF (which will be converted to ;; TXT thereafter). - (doc-view-ps->pdf buffer-file-name + (doc-view-ps->pdf doc-view-buffer-file-name (expand-file-name "doc.pdf" (doc-view-current-cache-dir)))) ((string= ext "dvi") @@ -901,7 +908,7 @@ If BACKWARD is non-nil, jump to the previous match." (defun doc-view-initiate-display () ;; Switch to image display if possible - (if (doc-view-mode-p (intern (file-name-extension buffer-file-name))) + (if (doc-view-mode-p (intern (file-name-extension doc-view-buffer-file-name))) (progn (doc-view-buffer-message) (setq doc-view-current-page (or doc-view-current-page 1)) @@ -919,7 +926,7 @@ If BACKWARD is non-nil, jump to the previous match." "%s" (substitute-command-keys (concat "No image (png) support available or some conversion utility for " - (file-name-extension buffer-file-name)" files is missing. " + (file-name-extension doc-view-buffer-file-name)" files is missing. " "Type \\[doc-view-toggle-display] to switch to an editing mode."))))) (defvar bookmark-make-cell-function) @@ -930,23 +937,6 @@ If BACKWARD is non-nil, jump to the previous match." You can use \\\\[doc-view-toggle-display] to toggle between displaying the document or editing it as text." (interactive) - ;; Handle compressed files, TRAMP files, files inside archives - (cond - (jka-compr-really-do-compress - (let ((file (expand-file-name - (file-name-nondirectory - (file-name-sans-extension buffer-file-name)) - doc-view-cache-directory))) - (write-region nil nil file) - (setq buffer-file-name file))) - ((or - (not (file-exists-p buffer-file-name)) - (tramp-tramp-file-p buffer-file-name)) - (let ((file (expand-file-name - (file-name-nondirectory buffer-file-name) - doc-view-cache-directory))) - (write-region nil nil file) - (setq buffer-file-name file)))) (let* ((prev-major-mode (if (eq major-mode 'doc-view-mode) doc-view-previous-major-mode @@ -954,6 +944,24 @@ toggle between displaying the document or editing it as text." (kill-all-local-variables) (set (make-local-variable 'doc-view-previous-major-mode) prev-major-mode)) + ;; Handle compressed files, remote files, files inside archives + (set (make-local-variable 'doc-view-buffer-file-name) + (cond + (jka-compr-really-do-compress + (expand-file-name + (file-name-nondirectory + (file-name-sans-extension buffer-file-name)) + doc-view-cache-directory)) + ((or + (not (file-exists-p buffer-file-name)) + (file-remote-p buffer-file-name)) + (expand-file-name + (file-name-nondirectory buffer-file-name) + doc-view-cache-directory)) + (t buffer-file-name))) + (when (not (string= doc-view-buffer-file-name buffer-file-name)) + (write-region nil nil doc-view-buffer-file-name)) + (make-local-variable 'doc-view-current-files) (make-local-variable 'doc-view-current-image) (make-local-variable 'doc-view-current-page) @@ -1012,7 +1020,7 @@ See the command `doc-view-mode' for more information on this mode." (defun doc-view-bookmark-make-cell (annotation &rest args) (let ((the-record - `((filename . ,(buffer-file-name)) + `((filename . ,buffer-file-name) (page . ,doc-view-current-page) (handler . doc-view-bookmark-jump)))) From 8bbd01a23bddaec425fba5a2395df611969771b2 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Thu, 10 Jan 2008 15:24:58 +0000 Subject: [PATCH 056/439] * pop.c (pop_stat, pop_last): Check validity of string-to-integer conversion. Mistakes spotted by Nico Golde. --- lib-src/ChangeLog | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index 6a6887f6d96..2bb60522966 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,8 @@ +2008-01-10 Chong Yidong + + * pop.c (pop_stat, pop_last): Check validity of string-to-integer + conversion. Mistakes spotted by Nico Golde. + 2008-01-04 Glenn Morris * ebrowse.c (version): Just use current year for short copyright; From 8ef147bd83a442e501b39d0452c4be2412a1b4e1 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Thu, 10 Jan 2008 15:25:28 +0000 Subject: [PATCH 057/439] (pop_stat, pop_last): Check validity of string-to-integer conversion. Mistakes spotted by Nico Golde. --- lib-src/pop.c | 32 +++++++++++++++++++++++++++++--- 1 file changed, 29 insertions(+), 3 deletions(-) diff --git a/lib-src/pop.c b/lib-src/pop.c index e8cf42b320a..5dc5de75583 100644 --- a/lib-src/pop.c +++ b/lib-src/pop.c @@ -352,6 +352,7 @@ pop_stat (server, count, size) int *size; { char *fromserver; + char *end_ptr; if (server->in_multi) { @@ -377,7 +378,15 @@ pop_stat (server, count, size) return (-1); } - *count = atoi (&fromserver[4]); + errno = 0; + *count = strtol (&fromserver[4], &end_ptr, 10); + /* Check validity of string-to-integer conversion. */ + if (fromserver[4] == 0 || *end_ptr != 0 || errno) + { + strcpy (pop_error, "Unexpected response from POP server in pop_stat"); + pop_trash (server); + return (-1); + } fromserver = index (&fromserver[4], ' '); if (! fromserver) @@ -388,7 +397,14 @@ pop_stat (server, count, size) return (-1); } - *size = atoi (fromserver + 1); + errno = 0; + *size = strtol (fromserver + 1, &end_ptr, 10); + if (*(fromserver + 1) == 0 || *end_ptr != 0 || errno) + { + strcpy (pop_error, "Unexpected response from POP server in pop_stat"); + pop_trash (server); + return (-1); + } return (0); } @@ -913,7 +929,17 @@ pop_last (server) } else { - return (atoi (&fromserver[4])); + char *end_ptr; + int count; + errno = 0; + count = strtol (&fromserver[4], &end_ptr, 10); + if (fromserver[4] == 0 || *end_ptr != 0 || errno) + { + strcpy (pop_error, "Unexpected response from server in pop_last"); + pop_trash (server); + return (-1); + } + return count; } } From 6eae3ad4eeb2cee3276091c9ef88f1f5f1882ae6 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Thu, 10 Jan 2008 15:31:25 +0000 Subject: [PATCH 058/439] * pop.c (pop_stat, pop_last): Check validity of string-to-integer conversion. Mistakes spotted by Nico Golde. --- lib-src/ChangeLog | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index 16cca0959b3..c7c6d3076cc 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,8 @@ +2008-01-10 Chong Yidong + + * pop.c (pop_stat, pop_last): Check validity of string-to-integer + conversion. Mistakes spotted by Nico Golde. + 2008-01-09 Glenn Morris * emacsclient.c: Add missing final newlines to message calls. From 0b074993158942d393feebc2c237bfe6df1da31e Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Thu, 10 Jan 2008 15:33:52 +0000 Subject: [PATCH 059/439] (pop_stat, pop_last): Check validity of string-to-integer conversion. Mistakes spotted by Nico Golde. --- lib-src/pop.c | 32 +++++++++++++++++++++++++++++--- 1 file changed, 29 insertions(+), 3 deletions(-) diff --git a/lib-src/pop.c b/lib-src/pop.c index 61c90abe2bf..814575f06d5 100644 --- a/lib-src/pop.c +++ b/lib-src/pop.c @@ -352,6 +352,7 @@ pop_stat (server, count, size) int *size; { char *fromserver; + char *end_ptr; if (server->in_multi) { @@ -377,7 +378,15 @@ pop_stat (server, count, size) return (-1); } - *count = atoi (&fromserver[4]); + errno = 0; + *count = strtol (&fromserver[4], &end_ptr, 10); + /* Check validity of string-to-integer conversion. */ + if (fromserver[4] == 0 || *end_ptr != 0 || errno) + { + strcpy (pop_error, "Unexpected response from POP server in pop_stat"); + pop_trash (server); + return (-1); + } fromserver = index (&fromserver[4], ' '); if (! fromserver) @@ -388,7 +397,14 @@ pop_stat (server, count, size) return (-1); } - *size = atoi (fromserver + 1); + errno = 0; + *size = strtol (fromserver + 1, &end_ptr, 10); + if (*(fromserver + 1) == 0 || *end_ptr != 0 || errno) + { + strcpy (pop_error, "Unexpected response from POP server in pop_stat"); + pop_trash (server); + return (-1); + } return (0); } @@ -913,7 +929,17 @@ pop_last (server) } else { - return (atoi (&fromserver[4])); + char *end_ptr; + int count; + errno = 0; + count = strtol (&fromserver[4], &end_ptr, 10); + if (fromserver[4] == 0 || *end_ptr != 0 || errno) + { + strcpy (pop_error, "Unexpected response from server in pop_last"); + pop_trash (server); + return (-1); + } + return count; } } From 965f51768ebf8e5fd89aa1d9d4d773e7dce9b72f Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Thu, 10 Jan 2008 15:39:02 +0000 Subject: [PATCH 060/439] ** nico@ngolde.de, 7 Jan: some code issues Fixed. --- admin/FOR-RELEASE | 4 ---- 1 file changed, 4 deletions(-) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index 4f1d8d3a6c3..b70dffd8439 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -57,10 +57,6 @@ http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00589.html http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00460.html reproducible? -** nico@ngolde.de, 7 Jan: some code issues -some unsafe code in pop.c, etags.c -http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00654.html - * DOCUMENTATION ** Check the Emacs Tutorial. From ce460dceb2c8117f18615c4ff7b4371ed1d179dd Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 10 Jan 2008 17:45:15 +0000 Subject: [PATCH 061/439] Remove python.el entry duplicated when merging from EMACS_22_BASE. --- lisp/ChangeLog | 42 +++++++++++++++--------------------------- 1 file changed, 15 insertions(+), 27 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 118ce1a24a8..fef1f8eb449 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -14,8 +14,7 @@ 2008-01-10 Tassilo Horn - * doc-view.el (tramp): Require tramp because we use - tramp-tramp-file-p. + * doc-view.el (tramp): Require tramp because we use tramp-tramp-file-p. 2008-01-10 Tom Tromey @@ -25,9 +24,9 @@ 2008-01-10 Michael Kifer - * ediff*.el: uncommented declare-function. + * ediff*.el: Uncomment declare-function. - * viper*.el: uncommented declare-function. + * viper*.el: Uncomment declare-function. 2008-01-09 Tassilo Horn @@ -36,7 +35,7 @@ 2008-01-09 Eric S. Raymond - * testmodes/sgml-mode.el (sgml-tag-syntax-table): Initialize this + * testmodes/sgml-mode.el (sgml-tag-syntax-table): Initialize this constant with a computation on sgml-specials rather than a literal list. Without this change the syntax table is generated incorrectly, and the mode will think it's in a comment following @@ -54,24 +53,25 @@ 2008-01-09 Michael Kifer - * ediff*.el: commented out declare-function. "make bootstrap" - stops with an error and emacs does not compile with those things in. + * ediff*.el: Comment out declare-function. "make bootstrap" + stops with an error and Emacs does not compile with those things in. Besides, declare-function is not defined in XEmacs. - * ediff-util (eqiff-quit): autoraise minibuffer. + * ediff-util (eqiff-quit): Autoraise minibuffer. - * ediff-diff (ediff-convert-fine-diffs-to-overlays): make it a defin + * ediff-diff (ediff-convert-fine-diffs-to-overlays): Make it a defun. - * viper*.el: commented out declare-function -- not defined in XEmacs. + * viper*.el: Comment out declare-function -- not defined in XEmacs. - * viper-ex.el (viper-info-on-file): take care of indiret buffers. + * viper-ex.el (viper-info-on-file): Take care of indirect buffers. - * viper.el (viper-set-hooks, set-cursor-color): set viper-vi-state-cursor-color. + * viper.el (viper-set-hooks, set-cursor-color): + Set viper-vi-state-cursor-color. 2008-01-09 Tom Tromey - * vc.el (vc-status-headers): Rename from - vc-status-insert-headers. Just return header. + * vc.el (vc-status-headers): Rename from vc-status-insert-headers. + Just return header. (vc-status-move-to-goal-column): New function. (vc-status-mode-map): Define more keys. (vc-status-mode): Use vc-status-refresh. Now 'special. @@ -100,7 +100,7 @@ 2008-01-09 Vinicius Jose Latorre - * ps-print.el: Some face attributes (like :strike-through) was not + * ps-print.el: Some face attributes (like :strike-through) were not being recognised. Reported by Leo . (ps-print-version): New version 6.8.2. (ps-face-strikout-p, ps-face-overline-p, ps-face-box-p): New funs. @@ -7247,18 +7247,6 @@ * net/browse-url.el (browse-url-encode-url): Use copy-sequence. Reported by Jan Dj,Ad(Brv . -2007-09-10 Stefan Monnier - - * progmodes/python.el: Merge changes from Dave Love's v2007-Sep-10. - (python-font-lock-keywords): Update to the 2.5 version of the language. - (python-quote-syntax): Let-bind font-lock-syntactic-keywords to nil. - (python-backspace): Only behave funny in code. - (python-compilation-regexp-alist): Add PDB stack trace regexp. - (inferior-python-mode): Add PDB prompt regexp. - (python-fill-paragraph): Refine the fenced-string regexp. - (python-find-imports): Handle imports spanning several lines. - (python-mode): Add `class' to hideshow support. - 2007-09-10 Dave Love * outline.el (outline-4, outline-5, outline-7): From f78a91b3bda495d90731d2403229f18c3a5b1f26 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Thu, 10 Jan 2008 18:44:27 +0000 Subject: [PATCH 062/439] (fringe-mode-explicit): New variable. (set-fringe-mode): Don't alter default-frame-alist when just loading this file. --- lisp/fringe.el | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/lisp/fringe.el b/lisp/fringe.el index e2eb5d2d98b..2762dbe617a 100644 --- a/lisp/fringe.el +++ b/lisp/fringe.el @@ -93,6 +93,10 @@ (defvar fringe-mode) +(defvar fringe-mode-explicit nil + "Non-nil means `set-fringe-mode' should really do something. +This is nil while loading `fringe.el', and t afterward.") + (defun set-fringe-mode-1 (ignore value) "Call `set-fringe-mode' with VALUE. See `fringe-mode' for valid values and their effect. @@ -104,13 +108,14 @@ This is usually invoked when setting `fringe-mode' via customize." See `fringe-mode' for possible values and their effect." (setq fringe-mode value) - (modify-all-frames-parameters - (list (cons 'left-fringe (if (consp fringe-mode) - (car fringe-mode) - fringe-mode)) - (cons 'right-fringe (if (consp fringe-mode) - (cdr fringe-mode) - fringe-mode))))) + (when fringe-mode-explicit + (modify-all-frames-parameters + (list (cons 'left-fringe (if (consp fringe-mode) + (car fringe-mode) + fringe-mode)) + (cons 'right-fringe (if (consp fringe-mode) + (cdr fringe-mode) + fringe-mode)))))) ;; For initialization of fringe-mode, take account of changes ;; made explicitly to default-frame-alist. @@ -159,6 +164,10 @@ you can use the interactive function `set-fringe-style'." :initialize 'fringe-mode-initialize :set 'set-fringe-mode-1) +;; We just set fringe-mode, but that was the default. +;; If it is set again, that is for real. +(setq fringe-mode-explicit t) + (defun fringe-query-style (&optional all-frames) "Query user for fringe style. Returns values suitable for left-fringe and right-fringe frame parameters. From fedcb5ffc0e5ce3f89cb9e92cd04e3177c189ea5 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Thu, 10 Jan 2008 18:49:31 +0000 Subject: [PATCH 063/439] (ada-set-syntax-table-properties): Bind buffer-file-name and buffer-file-truename. --- lisp/ChangeLog | 9 +++++++++ lisp/progmodes/ada-mode.el | 3 ++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index fef1f8eb449..42e81111208 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,12 @@ +2008-01-10 Martin Rudalics + + * progmodes/ada-mode.el (ada-set-syntax-table-properties): + Bind buffer-file-name and buffer-file-truename. + + * fringe.el (fringe-mode-explicit): New variable. + (set-fringe-mode): Don't alter default-frame-alist when just + loading this file. + 2008-01-10 Tassilo Horn * doc-view.el (doc-view-buffer-file-name): New variable. diff --git a/lisp/progmodes/ada-mode.el b/lisp/progmodes/ada-mode.el index 2c3acdda176..1673bb3f69a 100644 --- a/lisp/progmodes/ada-mode.el +++ b/lisp/progmodes/ada-mode.el @@ -930,7 +930,8 @@ are treated as numbers instead of gnatprep comments." (buffer-undo-list t) (inhibit-read-only t) (inhibit-point-motion-hooks t) - (inhibit-modification-hooks t)) + (inhibit-modification-hooks t) + buffer-file-name buffer-file-truename) (remove-text-properties (point-min) (point-max) '(syntax-table nil)) (goto-char (point-min)) (while (re-search-forward From c616830f5e344ca1db92486fccc5674b8186612a Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 11 Jan 2008 04:55:32 +0000 Subject: [PATCH 064/439] (elmo-msgdb-overview-get-entity, wl-summary-buffer-msgdb): Declare as funtions. --- lisp/textmodes/org.el | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lisp/textmodes/org.el b/lisp/textmodes/org.el index 15ad87f4f23..38038ec6720 100644 --- a/lisp/textmodes/org.el +++ b/lisp/textmodes/org.el @@ -3944,6 +3944,9 @@ If it is less than 8, the level-1 face gets re-used for level N+1 etc." (declare-function elmo-folder-exists-p "ext:elmo" (folder) t) (declare-function elmo-message-entity-field "ext:elmo-msgdb" (entity field &optional type)) (declare-function elmo-message-field "ext:elmo" (folder number field &optional type) t) +;; In old (2003) versions of Wanderlust without elmo-message-entity. +(declare-function elmo-msgdb-overview-get-entity "ext:elmo-msgdb") +(declare-function wl-summary-buffer-msgdb "ext:wl-summary") (declare-function vm-beginning-of-message "ext:vm-page" ()) (declare-function vm-follow-summary-cursor "ext:vm-motion" ()) (declare-function vm-get-header-contents "ext:vm-summary" (message header-name-regexp &optional clump-sep)) From a690c0715a02f6093f33e8562338350b7f794925 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 11 Jan 2008 04:56:27 +0000 Subject: [PATCH 065/439] (big5-to-flat-code, flat-code-to-big5, euc-to-flat-code, flat-code-to-euc): Declare as functions. --- lisp/ChangeLog | 7 +++++++ lisp/language/china-util.el | 7 +++++++ 2 files changed, 14 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 42e81111208..6028276f6df 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2008-01-11 Glenn Morris + + * language/china-util.el (big5-to-flat-code, flat-code-to-big5) + (euc-to-flat-code, flat-code-to-euc): + * textmodes/org.el (elmo-msgdb-overview-get-entity) + (wl-summary-buffer-msgdb): Declare as funtions. + 2008-01-10 Martin Rudalics * progmodes/ada-mode.el (ada-set-syntax-table-properties): diff --git a/lisp/language/china-util.el b/lisp/language/china-util.el index 6eaa3b5e76e..6d628c62c11 100644 --- a/lisp/language/china-util.el +++ b/lisp/language/china-util.el @@ -175,6 +175,13 @@ Return the length of resulting text." ;; Many kudos to Himi! The used code has been adapted from his ;; mule-ucs package. +;; Silence the compiler, which otherwise warns that these functions +;; might not be defined at runtime. They are only used when compiling. +(declare-function big5-to-flat-code "china-util" (num)) +(declare-function flat-code-to-big5 "china-util" (num)) +(declare-function euc-to-flat-code "china-util" (num)) +(declare-function flat-code-to-euc "china-util" (num)) + (eval-when-compile (defun big5-to-flat-code (num) "Convert NUM in Big 5 encoding to a `flat code'. From d31dcb1196027caddddd1b45fccc553f15738c05 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Fri, 11 Jan 2008 09:56:04 +0000 Subject: [PATCH 066/439] (all): Add missing version entries. --- lisp/ChangeLog | 4 ++++ lisp/cus-start.el | 24 +++++++++++++----------- 2 files changed, 17 insertions(+), 11 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 389f7b70fb7..3b5a19197bc 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-11 Martin Rudalics + + * cus-start.el (all): Add missing version entries. + 2008-01-10 Dan Nicolaescu * files.el (safe-local-eval-forms): Mark diff --git a/lisp/cus-start.el b/lisp/cus-start.el index d18df475247..8c95f9af65f 100644 --- a/lisp/cus-start.el +++ b/lisp/cus-start.el @@ -98,7 +98,8 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of (scroll-down-aggressively windows (choice (const :tag "off" nil) number) "21.1") - (line-spacing display (choice (const :tag "none" nil) integer)) + (line-spacing display (choice (const :tag "none" nil) integer) + "22.1") ;; callint.c (mark-even-if-inactive editing-basics boolean) ;; callproc.c @@ -128,7 +129,7 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of :match (lambda (widget value) (and value (not (functionp value))))) (function :value ignore)))) - (selection-coding-system mule coding-system) + (selection-coding-system mule coding-system "22.1") ;; dired.c (completion-ignored-extensions dired (repeat (string :format "%v"))) @@ -175,7 +176,8 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of (sexp :tag "Value")))) (mouse-highlight mouse (choice (const :tag "disabled" nil) (const :tag "always shown" t) - (other :tag "hidden by keypress" 1))) + (other :tag "hidden by keypress" 1)) + "22.1") ;; fringe.c (overflow-newline-into-fringe fringe boolean) ;; indent.c @@ -189,7 +191,7 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of (polling-period keyboard integer) (double-click-time mouse (restricted-sexp :match-alternatives (integerp 'nil 't))) - (double-click-fuzz mouse integer) + (double-click-fuzz mouse integer "22.1") (inhibit-local-menu-bar-menus menu boolean) (help-char keyboard character) (help-event-list keyboard (repeat (sexp :format "%v"))) @@ -247,9 +249,9 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of (completion-auto-help minibuffer boolean) (enable-recursive-minibuffers minibuffer boolean) (history-length minibuffer - (choice (const :tag "Infinite" t) - integer)) - (history-delete-duplicates minibuffer boolean) + (choice (const :tag "Infinite" t) integer) + "22.1") + (history-delete-duplicates minibuffer boolean "22.1") (minibuffer-prompt-properties minibuffer (list @@ -346,7 +348,7 @@ since it could result in memory overflow and make Emacs crash." windows (choice (const :tag "Off (nil)" :value nil) (const :tag "Full screen (t)" :value t) - (other :tag "Always" 1))) + (other :tag "Always" 1)) "22.1") (display-buffer-reuse-frames windows boolean "21.1") ;; xdisp.c (scroll-step windows integer) @@ -360,7 +362,7 @@ since it could result in memory overflow and make Emacs crash." (line-number-display-limit display (choice integer (const :tag "No limit" nil))) - (line-number-display-limit-width display integer) + (line-number-display-limit-width display integer "22.1") (highlight-nonselected-windows display boolean) (message-log-max debug (choice (const :tag "Disable" nil) (integer :menu-tag "lines" @@ -375,7 +377,7 @@ since it could result in memory overflow and make Emacs crash." (const :tag "Immediate" :value t) (number :tag "Delay by secs" :value 0.5)) "22.1") ;; xfaces.c - (scalable-fonts-allowed display boolean) + (scalable-fonts-allowed display boolean "22.1") ;; xfns.c (x-bitmap-file-path installation (repeat (directory :format "%v"))) @@ -466,5 +468,5 @@ since it could result in memory overflow and make Emacs crash." (unless purify-flag (provide 'cus-start)) -;;; arch-tag: 4502730d-bcb3-4f5e-99a3-a86f2d54af60 +;; arch-tag: 4502730d-bcb3-4f5e-99a3-a86f2d54af60 ;;; cus-start.el ends here From 6671cab318609084ef86f02878da836107ceaee8 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Fri, 11 Jan 2008 09:59:48 +0000 Subject: [PATCH 067/439] (all): Add missing version entries. --- lisp/ChangeLog | 4 ++++ lisp/cus-start.el | 27 +++++++++++++++------------ 2 files changed, 19 insertions(+), 12 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6028276f6df..f8836078458 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-11 Martin Rudalics + + * cus-start.el (all): Add missing version entries. + 2008-01-11 Glenn Morris * language/china-util.el (big5-to-flat-code, flat-code-to-big5) diff --git a/lisp/cus-start.el b/lisp/cus-start.el index 7c0d538e735..2e49f5e8a73 100644 --- a/lisp/cus-start.el +++ b/lisp/cus-start.el @@ -95,7 +95,8 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of (scroll-down-aggressively windows (choice (const :tag "off" nil) number) "21.1") - (line-spacing display (choice (const :tag "none" nil) integer)) + (line-spacing display (choice (const :tag "none" nil) integer) + "22.1") ;; callint.c (mark-even-if-inactive editing-basics boolean) ;; callproc.c @@ -125,7 +126,7 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of :match (lambda (widget value) (and value (not (functionp value))))) (function :value ignore)))) - (selection-coding-system mule coding-system) + (selection-coding-system mule coding-system "22.1") ;; dired.c (completion-ignored-extensions dired (repeat (string :format "%v"))) @@ -141,7 +142,7 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of (max-lisp-eval-depth limits integer) (max-mini-window-height limits (choice (const :tag "quarter screen" nil) - number)) + number) "23.1") (stack-trace-on-error debug (choice (const :tag "off") (repeat :menu-tag "When" @@ -175,7 +176,8 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of (sexp :tag "Value")))) (mouse-highlight mouse (choice (const :tag "disabled" nil) (const :tag "always shown" t) - (other :tag "hidden by keypress" 1))) + (other :tag "hidden by keypress" 1)) + "22.1") ;; fringe.c (overflow-newline-into-fringe fringe boolean) ;; indent.c @@ -189,7 +191,7 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of (polling-period keyboard integer) (double-click-time mouse (restricted-sexp :match-alternatives (integerp 'nil 't))) - (double-click-fuzz mouse integer) + (double-click-fuzz mouse integer "22.1") (inhibit-local-menu-bar-menus menu boolean) (help-char keyboard character) (help-event-list keyboard (repeat (sexp :format "%v"))) @@ -247,9 +249,9 @@ Leaving \"Default\" unchecked is equivalent with specifying a default of (completion-auto-help minibuffer boolean) (enable-recursive-minibuffers minibuffer boolean) (history-length minibuffer - (choice (const :tag "Infinite" t) - integer)) - (history-delete-duplicates minibuffer boolean) + (choice (const :tag "Infinite" t) integer) + "22.1") + (history-delete-duplicates minibuffer boolean "22.1") (minibuffer-prompt-properties minibuffer (list @@ -348,14 +350,15 @@ since it could result in memory overflow and make Emacs crash." ;; and shape of the window. (const :tag "horizontally" (lambda (window) - (split-window window nil 'horiz))))) + (split-window window nil 'horiz)))) + "23.1") (window-min-height windows integer) (window-min-width windows integer) (scroll-preserve-screen-position windows (choice (const :tag "Off (nil)" :value nil) (const :tag "Full screen (t)" :value t) - (other :tag "Always" 1))) + (other :tag "Always" 1)) "22.1") (display-buffer-reuse-frames windows boolean "21.1") ;; xdisp.c (scroll-step windows integer) @@ -369,7 +372,7 @@ since it could result in memory overflow and make Emacs crash." (line-number-display-limit display (choice integer (const :tag "No limit" nil))) - (line-number-display-limit-width display integer) + (line-number-display-limit-width display integer "22.1") (highlight-nonselected-windows display boolean) (message-log-max debug (choice (const :tag "Disable" nil) (integer :menu-tag "lines" @@ -384,7 +387,7 @@ since it could result in memory overflow and make Emacs crash." (const :tag "Immediate" :value t) (number :tag "Delay by secs" :value 0.5)) "22.1") ;; xfaces.c - (scalable-fonts-allowed display boolean) + (scalable-fonts-allowed display boolean "22.1") ;; xfns.c (x-bitmap-file-path installation (repeat (directory :format "%v"))) From 5ee4de5319f07e1da96835eece3d8a79cdae3da2 Mon Sep 17 00:00:00 2001 From: YAMAMOTO Mitsuharu Date: Fri, 11 Jan 2008 10:29:07 +0000 Subject: [PATCH 068/439] (mac_emacs_pid) [MAC_OSX]: New variable. [MAC_OSX] (init_mac_osx_environment): Initialize it. [MAC_OSX] (mac_try_close_socket) [SELECT_USE_CFSOCKET]: Return 0 when used on child processes. --- src/ChangeLog | 7 +++++++ src/mac.c | 7 ++++++- 2 files changed, 13 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 287959462be..25b994e3ab8 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,10 @@ +2008-01-11 YAMAMOTO Mitsuharu + + * mac.c (mac_emacs_pid) [MAC_OSX]: New variable. + [MAC_OSX] (init_mac_osx_environment): Initialize it. + [MAC_OSX] (mac_try_close_socket) [SELECT_USE_CFSOCKET]: Return 0 + when used on child processes. + 2008-01-10 Chong Yidong * process.c (wait_reading_process_output): Check for window diff --git a/src/mac.c b/src/mac.c index e8cb6a15402..dace8864320 100644 --- a/src/mac.c +++ b/src/mac.c @@ -5013,6 +5013,9 @@ extern int noninteractive; sys_select. */ static CFMutableDictionaryRef cfsockets_for_select; +/* Process ID of Emacs. */ +static pid_t mac_emacs_pid; + static void socket_callback (s, type, address, data, info) CFSocketRef s; @@ -5092,7 +5095,7 @@ mac_try_close_socket (fd) int fd; { #if SELECT_USE_CFSOCKET - if (cfsockets_for_select) + if (getpid () == mac_emacs_pid && cfsockets_for_select) { void *key = (void *) fd; CFSocketRef socket = @@ -5329,6 +5332,8 @@ init_mac_osx_environment () char *p, *q; struct stat st; + mac_emacs_pid = getpid (); + /* Initialize locale related variables. */ mac_system_script_code = (ScriptCode) GetScriptManagerVariable (smSysScript); From 81cd7687abd636f4c9b4cc380909ab6a69b88d74 Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Fri, 11 Jan 2008 11:30:25 +0000 Subject: [PATCH 069/439] (detect_coding_mask): Fix previous change. --- src/ChangeLog | 4 ++++ src/coding.c | 10 +++++++--- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 18b1e04a1d7..d56550fb1a3 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-11 Kenichi Handa + + * coding.c (detect_coding_mask): Fix previous change. + 2008-01-10 Chong Yidong * process.c (wait_reading_process_output): Check for window diff --git a/src/coding.c b/src/coding.c index 4e4147370cb..dda3f0f854c 100644 --- a/src/coding.c +++ b/src/coding.c @@ -4153,12 +4153,16 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) label_loop_detect_coding: null_byte_found = 0; - while (src < src_end && ascii_skip_code[*src]) + /* We stop this loop before the last byte because it may be a NULL + anchor byte. */ + while (src < src_end - 1 && ascii_skip_code[*src]) null_byte_found |= (! *src++); - if (! null_byte_found) + if (ascii_skip_code[*src]) + src++; + else if (! null_byte_found) { unsigned char *p = src + 1; - while (p < src_end) + while (p < src_end - 1) null_byte_found |= (! *p++); } *skip = src - source; From 07b312cf3c2e26482d1f5cf4d2c0d57d762f78fd Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 11 Jan 2008 14:23:39 +0000 Subject: [PATCH 070/439] Add david.reitter@gmail.com, 27 dec: pos-visible-in-window-p at ellipsis. --- admin/FOR-RELEASE | 2 ++ 1 file changed, 2 insertions(+) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index b70dffd8439..503947e74c9 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -57,6 +57,8 @@ http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00589.html http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00460.html reproducible? +** david.reitter@gmail.com, 27 dec: pos-visible-in-window-p at ellipsis + * DOCUMENTATION ** Check the Emacs Tutorial. From cf1917060aa30a20ef40aa296497c4a4ebeeb9f1 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 11 Jan 2008 14:44:15 +0000 Subject: [PATCH 071/439] (atomic-change-group): Prevent undo list truncation. --- lisp/ChangeLog | 4 ++++ lisp/subr.el | 4 ++++ 2 files changed, 8 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3b5a19197bc..69f537f916c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-11 Richard Stallman + + * subr.el (atomic-change-group): Prevent undo list truncation. + 2008-01-11 Martin Rudalics * cus-start.el (all): Add missing version entries. diff --git a/lisp/subr.el b/lisp/subr.el index a9674bbba36..b4bd4a0150c 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -1802,6 +1802,10 @@ user can undo the change normally." (let ((handle (make-symbol "--change-group-handle--")) (success (make-symbol "--change-group-success--"))) `(let ((,handle (prepare-change-group)) + ;; Don't truncate any undo data in the middle of this. + (undo-outer-limit nil) + (undo-limit most-positive-fixnum) + (undo-strong-limit most-positive-fixnum) (,success nil)) (unwind-protect (progn From 6bd1e22385435e770354764e3c45ee4bac1215fe Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Fri, 11 Jan 2008 15:12:17 +0000 Subject: [PATCH 072/439] (nxml-mode): Call rng-nxml-mode-init directly. Update doc string and commentary. --- lisp/ChangeLog | 5 +++++ lisp/nxml/nxml-mode.el | 9 ++++----- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index f8836078458..7e4c616572e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-11 Jason Rumney + + * nxml/nxml-mode.el (nxml-mode): Call rng-nxml-mode-init directly. + Update doc string and commentary. + 2008-01-11 Martin Rudalics * cus-start.el (all): Add missing version entries. diff --git a/lisp/nxml/nxml-mode.el b/lisp/nxml/nxml-mode.el index 824d52a0102..d45c1ded786 100644 --- a/lisp/nxml/nxml-mode.el +++ b/lisp/nxml/nxml-mode.el @@ -24,8 +24,6 @@ ;;; Commentary: -;; To use this include rng-auto.el in your .emacs. - ;; See nxml-rap.el for description of parsing strategy. ;; The font locking here is independent of font-lock.el. We want to @@ -479,9 +477,9 @@ instead of C-c. Validation is provided by the related minor-mode `rng-validate-mode'. This also makes completion schema- and context- sensitive. Element names, attribute names, attribute values and namespace URIs can all be -completed. By default, `rng-validate-mode' is automatically enabled by -`rng-nxml-mode-init' which is normally added to `nxml-mode-hook'. You -can toggle it using \\[rng-validate-mode]. +completed. By default, `rng-validate-mode' is automatically enabled. You +can toggle it using \\[rng-validate-mode] or change the default by +customizing `rng-nxml-auto-validate-flag'. \\[indent-for-tab-command] indents the current line appropriately. This can be customized using the variable `nxml-child-indent' @@ -555,6 +553,7 @@ Many aspects this mode can be customized using (setq buffer-file-coding-system nxml-default-buffer-file-coding-system)) (when nxml-auto-insert-xml-declaration-flag (nxml-insert-xml-declaration))) + (rng-nxml-mode-init) (run-hooks 'nxml-mode-hook)) (defun nxml-degrade (context err) From 7a10d292714ad6330bfcb87d651a68e5302c090e Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Fri, 11 Jan 2008 16:00:09 +0000 Subject: [PATCH 073/439] (nxml-internal-unicode-char-name-sets-enabled): Rename from nxml-enable-unicode-char-name-sets-flag. (nxml-enable-unicode-char-name-sets-1): Merge into nxml-enable-unicode-char-name-sets. (nxml-enable-unicode-char-name-sets): Don't unconditionally set nxml-char-name-ignore-case here. --- lisp/nxml/nxml-uchnm.el | 17 ++++++----------- 1 file changed, 6 insertions(+), 11 deletions(-) diff --git a/lisp/nxml/nxml-uchnm.el b/lisp/nxml/nxml-uchnm.el index bfa671eb894..09ae310403d 100644 --- a/lisp/nxml/nxml-uchnm.el +++ b/lisp/nxml/nxml-uchnm.el @@ -28,9 +28,6 @@ ;; Standard. The use of the names can be controlled on a per-block ;; basis, so as both to reduce memory usage and loading time, ;; and to make completion work better. -;; The main entry point is `nxml-enable-unicode-char-name-sets'. Typically, -;; this is added to `nxml-mode-hook' (rng-auto.el does this already). -;; To customize the blocks for which names are used ;;; Code: @@ -213,7 +210,9 @@ by a hyphen." data-directory))) nxml-unicode-blocks) -(defvar nxml-enable-unicode-char-name-sets-flag nil) +;; Internal flag to control whether customize reloads the character tables. +;; Should be set the first time the +(defvar nxml-internal-unicode-char-name-sets-enabled nil) (defcustom nxml-enabled-unicode-blocks nxml-enabled-unicode-blocks-default "List of Unicode blocks for which Unicode character names are enabled. @@ -222,8 +221,8 @@ of the block by downcasing and replacing each space by a hyphen." :group 'nxml :set (lambda (sym value) (set-default 'nxml-enabled-unicode-blocks value) - (when nxml-enable-unicode-char-name-sets-flag - (nxml-enable-unicode-char-name-sets-1))) + (when nxml-internal-unicode-char-name-sets-enabled + (nxml-enable-unicode-char-name-sets))) :type (cons 'set (mapcar (lambda (block) `(const :tag ,(format "%s (%04X-%04X)" @@ -240,11 +239,7 @@ of the block by downcasing and replacing each space by a hyphen." The Unicode blocks for which names are enabled is controlled by the variable `nxml-enabled-unicode-blocks'." (interactive) - (setq nxml-char-name-ignore-case t) - (setq nxml-enable-unicode-char-name-sets-flag t) - (nxml-enable-unicode-char-name-sets-1)) - -(defun nxml-enable-unicode-char-name-sets-1 () + (setq nxml-internal-unicode-char-name-sets-enabled t) (mapc (lambda (block) (nxml-disable-char-name-set (nxml-unicode-block-char-name-set (car block)))) From b85b660458e1aefb0c84b028234d9c202b2176bc Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Fri, 11 Jan 2008 16:01:26 +0000 Subject: [PATCH 074/439] (nxml-char-name-ignore-case): Change default value. (nxml-mode): Call nxml-enable-unicode-char-name-sets directly. --- lisp/ChangeLog | 9 +++++++++ lisp/nxml/nxml-mode.el | 3 ++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7e4c616572e..8732275ee38 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,7 +1,16 @@ 2008-01-11 Jason Rumney + * nxml/nxml-uchnm.el (nxml-internal-unicode-char-name-sets-enabled): + Rename from nxml-enable-unicode-char-name-sets-flag. + (nxml-enable-unicode-char-name-sets-1): Merge into + nxml-enable-unicode-char-name-sets. + (nxml-enable-unicode-char-name-sets): Don't unconditionally set + nxml-char-name-ignore-case here. + * nxml/nxml-mode.el (nxml-mode): Call rng-nxml-mode-init directly. Update doc string and commentary. + (nxml-char-name-ignore-case): Change default value. + (nxml-mode): Call nxml-enable-unicode-char-name-sets directly. 2008-01-11 Martin Rudalics diff --git a/lisp/nxml/nxml-mode.el b/lisp/nxml/nxml-mode.el index d45c1ded786..53c47810a1d 100644 --- a/lisp/nxml/nxml-mode.el +++ b/lisp/nxml/nxml-mode.el @@ -554,6 +554,7 @@ Many aspects this mode can be customized using (when nxml-auto-insert-xml-declaration-flag (nxml-insert-xml-declaration))) (rng-nxml-mode-init) + (nxml-enable-unicode-char-name-sets) (run-hooks 'nxml-mode-hook)) (defun nxml-degrade (context err) @@ -2432,7 +2433,7 @@ and attempts to find another possible way to do the markup." ;;; Character names -(defvar nxml-char-name-ignore-case nil) +(defvar nxml-char-name-ignore-case t) (defvar nxml-char-name-alist nil "Alist of character names. From 669eb5c7eeb6cae1587e8eef6284aad31f59640a Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Fri, 11 Jan 2008 17:30:52 +0000 Subject: [PATCH 075/439] (rng-preferred-prefix-alist): Add some defaults. (rng-preferred-prefix-alist-default): Remove. --- lisp/ChangeLog | 3 +++ lisp/nxml/rng-nxml.el | 10 ++++++---- 2 files changed, 9 insertions(+), 4 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8732275ee38..3b0c36c0e02 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2008-01-11 Jason Rumney + * nxml/rng-nxml.el (rng-preferred-prefix-alist): Add some defaults. + (rng-preferred-prefix-alist-default): Remove. + * nxml/nxml-uchnm.el (nxml-internal-unicode-char-name-sets-enabled): Rename from nxml-enable-unicode-char-name-sets-flag. (nxml-enable-unicode-char-name-sets-1): Merge into diff --git a/lisp/nxml/rng-nxml.el b/lisp/nxml/rng-nxml.el index cb040c96311..a854263752d 100644 --- a/lisp/nxml/rng-nxml.el +++ b/lisp/nxml/rng-nxml.el @@ -41,10 +41,12 @@ :type 'boolean :group 'relax-ng) -(defvar rng-preferred-prefix-alist-default nil - "Default value for variable `rng-preferred-prefix-alist'.") - -(defcustom rng-preferred-prefix-alist rng-preferred-prefix-alist-default +(defcustom rng-preferred-prefix-alist + '(("http://www.w3.org/1999/XSL/Transform" . "xsl") + ("http://www.w3.org/1999/02/22-rdf-syntax-ns#" . "rdf") + ("http://www.w3.org/1999/xlink" . "xlink") + ("http://www.w3.org/2001/XmlSchema" . "xsd") + ("http://www.w3.org/2001/XMLSchema-instance" . "xsi")) "*Alist of namespaces vs preferred prefixes." :type '(repeat (cons :tag "With" (string :tag "this namespace URI") From 374c0cd617cdeb36b253da56df9e6c3d9f06337f Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Fri, 11 Jan 2008 20:39:13 +0000 Subject: [PATCH 076/439] ** pot@gnu.org, 17 Dec: strange From line maker rmail-reply loop Removed because not reproducible (private communication from Francesco Potorti). --- admin/FOR-RELEASE | 4 ---- 1 file changed, 4 deletions(-) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index 503947e74c9..451a7318882 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -53,10 +53,6 @@ http://lists.gnu.org/archive/html/bug-gnu-emacs/2007-09/msg00055.html ** eric@openbsd.org, 24 Nov: c-mode syntactic analysis regression in emacs-22.1 http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00589.html -** pot@gnu.org, 17 Dec: strange From line maker rmail-reply loop -http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00460.html -reproducible? - ** david.reitter@gmail.com, 27 dec: pos-visible-in-window-p at ellipsis * DOCUMENTATION From 839087fe8aa980001731a75a8f2fcb1e629b4820 Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Sat, 12 Jan 2008 12:30:05 +0000 Subject: [PATCH 077/439] (nxml-enable-unicode-char-name-sets, rng-nxml-mode-init): Declare. --- lisp/ChangeLog | 5 +++++ lisp/nxml/nxml-mode.el | 3 +++ 2 files changed, 8 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3b0c36c0e02..0d9fb0dfc13 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-12 Jason Rumney + + * nxml/nxml-mode.el (nxml-enable-unicode-char-name-sets) + (rng-nxml-mode-init): Declare. + 2008-01-11 Jason Rumney * nxml/rng-nxml.el (rng-preferred-prefix-alist): Add some defaults. diff --git a/lisp/nxml/nxml-mode.el b/lisp/nxml/nxml-mode.el index 53c47810a1d..aa6ac078400 100644 --- a/lisp/nxml/nxml-mode.el +++ b/lisp/nxml/nxml-mode.el @@ -43,6 +43,9 @@ (require 'nxml-rap) (require 'nxml-outln) +(declare-function rng-nxml-mode-init "rng-nxml") +(declare-function nxml-enable-unicode-char-name-sets "nxml-uchnm") + ;;; Customization (defgroup nxml nil From 26a30fea51c6d583e87cf82f83f4f3545d1a112c Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 12 Jan 2008 14:04:05 +0000 Subject: [PATCH 078/439] (ebrowse-view-file-other-window): Delete function. (ebrowse-view/find-file-and-search-pattern): Call view-file-other-window instead of ebrowse-view-file-other-window. (ebrowse-view-file-other-frame): Don't call current-window-configuration. Fix second argument in the call to view-mode-enter. Doc fix. --- lisp/ChangeLog | 10 ++++++++++ lisp/progmodes/ebrowse.el | 24 ++++-------------------- 2 files changed, 14 insertions(+), 20 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 69f537f916c..19248cb4f4c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,13 @@ +2008-01-12 Eli Zaretskii + + * progmodes/ebrowse.el (ebrowse-view-file-other-window): Delete + function. + (ebrowse-view/find-file-and-search-pattern): Call + view-file-other-window instead of ebrowse-view-file-other-window. + (ebrowse-view-file-other-frame): Don't call + current-window-configuration. Fix second argument in the call to + view-mode-enter. Doc fix. + 2008-01-11 Richard Stallman * subr.el (atomic-change-group): Prevent undo list truncation. diff --git a/lisp/progmodes/ebrowse.el b/lisp/progmodes/ebrowse.el index 8099656827e..7f13971bdb1 100644 --- a/lisp/progmodes/ebrowse.el +++ b/lisp/progmodes/ebrowse.el @@ -1613,21 +1613,6 @@ and (b) in the directories named in `ebrowse-search-path'." file-name)) -(defun ebrowse-view-file-other-window (file) - "View a file FILE in another window. -This is a replacement for `view-file-other-window' which does not -seem to work. It should be removed when `view.el' is fixed." - (interactive) - (let ((old-arrangement (current-window-configuration)) - (had-a-buf (get-file-buffer file)) - (buf-to-view (find-file-noselect file))) - (switch-to-buffer-other-window buf-to-view) - (view-mode-enter old-arrangement - (and (not had-a-buf) - (not (buffer-modified-p buf-to-view)) - 'kill-buffer)))) - - (defun ebrowse-view-exit-fn (buffer) "Function called when exiting View mode in BUFFER. Restore frame configuration active before viewing the file, @@ -1648,10 +1633,9 @@ and possibly kill the viewed buffer." (defun ebrowse-view-file-other-frame (file) "View a file FILE in another frame. -The new frame is deleted when it is no longer used." +The new frame is deleted when you quit viewing the file in that frame." (interactive) (let ((old-frame-configuration (current-frame-configuration)) - (old-arrangement (current-window-configuration)) (had-a-buf (get-file-buffer file)) (buf-to-view (find-file-noselect file))) (switch-to-buffer-other-frame buf-to-view) @@ -1662,8 +1646,8 @@ The new frame is deleted when it is no longer used." (and (not had-a-buf) (not (buffer-modified-p buf-to-view)) 'kill-buffer)) - (view-mode-enter old-arrangement 'ebrowse-view-exit-fn))) - + (view-mode-enter (cons (selected-window) (cons (selected-window) t)) + 'ebrowse-view-exit-fn))) (defun ebrowse-view/find-file-and-search-pattern (struc info file tags-file-name &optional view where) @@ -1698,7 +1682,7 @@ specifies where to find/view the result." (setq view-mode-hook nil)) (push 'ebrowse-find-pattern view-mode-hook) (case where - (other-window (ebrowse-view-file-other-window file)) + (other-window (view-file-other-window file)) (other-frame (ebrowse-view-file-other-frame file)) (t (view-file file)))) (t From 48d93bebd51abdfd8d70c74d3c03bcbc2e3bb036 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 12 Jan 2008 14:15:35 +0000 Subject: [PATCH 079/439] (view-file-other-window, view-file-other-frame): Don't kill the buffer if it is modified. Doc fixes. --- lisp/ChangeLog | 3 +++ lisp/view.el | 27 +++++++++++++++++++-------- 2 files changed, 22 insertions(+), 8 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 19248cb4f4c..b86777131eb 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2008-01-12 Eli Zaretskii + * view.el (view-file-other-window, view-file-other-frame): Don't + kill the buffer if it is modified. Doc fixes. + * progmodes/ebrowse.el (ebrowse-view-file-other-window): Delete function. (ebrowse-view/find-file-and-search-pattern): Call diff --git a/lisp/view.el b/lisp/view.el index 8701decf41c..d2a7d5c9b44 100644 --- a/lisp/view.el +++ b/lisp/view.el @@ -263,7 +263,9 @@ This command runs the normal hook `view-mode-hook'." ;;;###autoload (defun view-file-other-window (file) "View FILE in View mode in another window. -Return that window to its previous buffer when done. +When done, return that window to its previous buffer, and kill the +buffer visiting FILE if unmodified and if it wasn't visited before. + Emacs commands editing the buffer contents are not available; instead, a special set of commands (mostly letters and punctuation) are defined for moving around in the buffer. @@ -273,14 +275,20 @@ For list of all View commands, type H or h while viewing. This command runs the normal hook `view-mode-hook'." (interactive "fIn other window view file: ") (unless (file-exists-p file) (error "%s does not exist" file)) - (let ((had-a-buf (get-file-buffer file))) - (view-buffer-other-window (find-file-noselect file) nil - (and (not had-a-buf) 'kill-buffer)))) + (let ((had-a-buf (get-file-buffer file)) + (buf-to-view (find-file-noselect file))) + (view-buffer-other-window buf-to-view nil + (and (not had-a-buf) + (not (buffer-modified-p buf-to-view)) + 'kill-buffer)))) ;;;###autoload (defun view-file-other-frame (file) "View FILE in View mode in another frame. -Maybe delete other frame and/or return to previous buffer when done. +When done, kill the buffer visiting FILE if unmodified and if it wasn't +visited before; also, maybe delete other frame and/or return to previous +buffer. + Emacs commands editing the buffer contents are not available; instead, a special set of commands (mostly letters and punctuation) are defined for moving around in the buffer. @@ -290,9 +298,12 @@ For list of all View commands, type H or h while viewing. This command runs the normal hook `view-mode-hook'." (interactive "fIn other frame view file: ") (unless (file-exists-p file) (error "%s does not exist" file)) - (let ((had-a-buf (get-file-buffer file))) - (view-buffer-other-frame (find-file-noselect file) nil - (and (not had-a-buf) 'kill-buffer)))) + (let ((had-a-buf (get-file-buffer file)) + (buf-to-view (find-file-noselect file))) + (view-buffer-other-frame buf-to-view nil + (and (not had-a-buf) + (not (buffer-modified-p buf-to-view)) + 'kill-buffer)))) ;;;###autoload From e10bf4de8df322feff54d9d34d061ad9ac2506ec Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 12 Jan 2008 15:23:15 +0000 Subject: [PATCH 080/439] Add an explicit list of platforms that are no longer supported. --- etc/MACHINES | 78 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 78 insertions(+) diff --git a/etc/MACHINES b/etc/MACHINES index 66a55ff6363..b959531c69c 100644 --- a/etc/MACHINES +++ b/etc/MACHINES @@ -24,6 +24,9 @@ file, and then edit the `configure' script to tell it which configuration name(s) should select your new machine description and system description files. +Some obsolete platforms are unsupported beginning with Emacs 23.1, see +the full list at the end of this file. + Here are the configurations Emacs is intended to work with, with the corresponding configuration names. You can postpend version numbers @@ -937,6 +940,81 @@ X86_64 GNU/Linux (using the location of the 32-bit X libraries on your system). +Support for the following obsolete platforms was removed in Emacs 23.1 +(the names in parentheses state the files in src/ that were removed): + + Apollo SR10.x (unexapollo.c) + Convex (unexconvex.c and m/convex.c) + Xenix (unexenix.c and s/xenix.h) + Iris (unexmips.c m/iris4d.h m/irist.h s/iris3-5.h s/iris3-6.h) + Gould (m/gould*) + Siemens machines running Sinix (unexsni.c) + Harris CXUX (s/cxux*) + ESIX, a variant of v.5.3 for the 386 (s/esix*) + Interactive (ISC) Unix (s/isc*) + Sony News (s/newsos*) + RTU 3.0, ucb universe (s/rtu.h) + UniSoft's UniPlus 5.2 (s/uniplus.h) + UMAX (s/umax.h) + AT&T UNIX PC model 7300 (m/7300.h) + Acorn + Alliant (m/alliant*) + Amdahl (m/amdahl*) + Altos 3068 Unix System V Release 2 (m/altos.h) + Apollo (m/apollo.h) + AT&T 3b (m/att3b.h) + Aviion (m/aviion*) + Celerity (m/celerity.h) + clipper (m/clipper.h) + convergent S series (m/cnvrgnt.h) + cydra (m/cydra5.h) + Motorola System V/88 machines (m/delta88k.h) + Bull DPX/2 range (m/dpx2.h) + Dual machines using unisoft port (m/dual.h) + Elxsi machine (running enix) (m/elxsi.h) + Fujitsu F301 machine (m/f301.h) + i860 (m/i860.h) + ibm ps/2 aix386 (m/ibmps2-aix.h) + ISI 68000's (m/is*) + Masscomp 5000 series running RTU, ucb universe (m/masscomp.h) + Megatest 68000's (m/mega68.h) + Whitechapel Computer Works MG1 (ns16000 based) (m/mg1.h) + Harris Night Hawk Series 1200 and Series 3000 (m/nh3000.h m/nh4000.h) + ns16000 (m/ns16000.h) + National Semiconductor 32000, running Genix (m/ns32000.h) + TI Nu machines using system V (m/nu.h) + HLH Orion (m/orion.h m/orion105.h) + Paragon i860 (m/paragon.h) + PFU A-series (m/pfa50.h) + Plexus running System V.2 (m/plexus.h) + pyramid. (m/pyramid.h) + sh3el (m/sh3el.h) + Bull SPS-7 (m/sps7.h) + Hitachi SR2001/SR2201 (m/sr2k.h) + Stride (m/stride.h) + Sun 1 (m/sun1.h) + Sun 2 (m/sun2.h) + SEQUENT SYMMETRY (m/symmetry.h) + Tadpole 68k machines (m/tad68k.h) + tahoe (m/tahoe.h) + targon31 (m/targon31.h) + Tektronix* (m/tek4300.h m/tekxd88.h) + NCR Tower 32 running System V.2 (m/tower32.h) + NCR Tower 32 running System V.3 (m/tower32v3.h) + U-station (Nihon Unisys, SS5E; Sumitomo Denkoh, U-Station E30) (m/ustation.h) + Wicat (m/wicat.h) + Honeywell XPS100 running UNIX System V.2 (m/xps100.h) + Data General's DG/UX (s/dgux*) + Irix before version 6 + osf1 (s/osf*) + SunOS4 (s/sunos*) + RISCiX (s/riscix*) + SCO 3.2v4 (s/sco4.h) + SCO 3.2v5 (s/sco5.h) + Sun's 386-based RoadRunner (m/sun386.h) + Sun3 machines (m/sun3*) + Integrated Solutions 386 machine (m/is386.h) + Local variables: mode: text From bb9f794856ee92c7e86d840996074df905f7515b Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 12 Jan 2008 15:24:21 +0000 Subject: [PATCH 081/439] Mention that old platforms are no longer supported. Add a reference to the full list in MACHINES. --- etc/ChangeLog | 6 ++++++ etc/NEWS | 3 +++ 2 files changed, 9 insertions(+) diff --git a/etc/ChangeLog b/etc/ChangeLog index ef3b8ccd927..1795f023d5f 100644 --- a/etc/ChangeLog +++ b/etc/ChangeLog @@ -1,3 +1,9 @@ +2008-01-12 Eli Zaretskii + + * MACHINES: Add an explicit list of platforms that are no longer + supported. + * NEWS: Refer to this list. + 2008-01-08 Glenn Morris * calccard.tex, cs-dired-ref.tex, cs-refcard.tex, cs-survival.tex: diff --git a/etc/NEWS b/etc/NEWS index 7e01829ac34..42e51b1fbc3 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -38,6 +38,9 @@ a GIF library. ** Support for Sun windows has been removed. +** Support for many obsolete platforms has been removed. +See the list at the end of etc/MACHINES for details. + ** The `emacstool' utility has been removed. ** The new configuration option "--with-dbus" enables D-Bus language From 0ebec7d35c363197865d0d4ba7fdfb9eda221b3b Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 12 Jan 2008 15:50:33 +0000 Subject: [PATCH 082/439] (decode_options) [WINDOWSNT]: Don't use the value of DISPLAY in the environment. Don't support -d. (print_help_and_exit) [WINDOWSNT]: Don't show the --display option. (longopts) [WINDOWSNT]: Remove --display. --- lib-src/ChangeLog | 7 +++++++ lib-src/emacsclient.c | 12 ++++++++++-- 2 files changed, 17 insertions(+), 2 deletions(-) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index c7c6d3076cc..07d73545468 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,10 @@ +2008-01-12 Eli Zaretskii + + * emacsclient.c (decode_options) [WINDOWSNT]: Don't use the value + of DISPLAY in the environment. Don't support -d. + (print_help_and_exit) [WINDOWSNT]: Don't show the --display option. + (longopts) [WINDOWSNT]: Remove --display. + 2008-01-10 Chong Yidong * pop.c (pop_stat, pop_last): Check validity of string-to-integer diff --git a/lib-src/emacsclient.c b/lib-src/emacsclient.c index 4fcd3398bd2..568b6c18119 100644 --- a/lib-src/emacsclient.c +++ b/lib-src/emacsclient.c @@ -170,7 +170,9 @@ struct option longopts[] = { "socket-name", required_argument, NULL, 's' }, #endif { "server-file", required_argument, NULL, 'f' }, +#ifndef WINDOWSNT { "display", required_argument, NULL, 'd' }, +#endif { 0, 0, 0, 0 } }; @@ -477,9 +479,11 @@ decode_options (argc, argv) char **argv; { alternate_editor = egetenv ("ALTERNATE_EDITOR"); +#ifndef WINDOWSNT display = egetenv ("DISPLAY"); if (display && strlen (display) == 0) display = NULL; +#endif while (1) { @@ -515,9 +519,11 @@ decode_options (argc, argv) server_file = optarg; break; +#ifndef WINDOWSNT case 'd': display = optarg; break; +#endif case 'n': nowait = 1; @@ -594,8 +600,10 @@ The following OPTIONS are accepted:\n\ -c, --create-frame Create a new frame instead of trying to\n\ use the current Emacs frame\n\ -e, --eval Evaluate the FILE arguments as ELisp expressions\n\ --n, --no-wait Don't wait for the server to return\n\ --d, --display=DISPLAY Visit the file in the given display\n" +-n, --no-wait Don't wait for the server to return\n" +#ifndef WINDOWSNT +"-d, --display=DISPLAY Visit the file in the given display\n" +#endif #ifndef NO_SOCKETS_IN_FILE_SYSTEM "-s, --socket-name=FILENAME\n\ Set filename of the UNIX socket for communication\n" From dd18f44f3b00001171e7b98b8ca5a8b036e337f2 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 12 Jan 2008 17:17:41 +0000 Subject: [PATCH 083/439] (view-file-other-window, view-file-other-frame): Fix last change. (kill-buffer-if-not-modified): New function. (view-file): Don't kill the buffer if it is modified. --- lisp/ChangeLog | 2 ++ lisp/view.el | 14 +++++++++----- 2 files changed, 11 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b86777131eb..ef40bc36c9e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -2,6 +2,8 @@ * view.el (view-file-other-window, view-file-other-frame): Don't kill the buffer if it is modified. Doc fixes. + (kill-buffer-if-not-modified): New function. + (view-file): Don't kill the buffer if it is modified. * progmodes/ebrowse.el (ebrowse-view-file-other-window): Delete function. diff --git a/lisp/view.el b/lisp/view.el index d2a7d5c9b44..bdf7f6a5728 100644 --- a/lisp/view.el +++ b/lisp/view.el @@ -238,6 +238,12 @@ This is local in each buffer, once it is used.") ;;; Commands that enter or exit view mode. +(defun kill-buffer-if-not-modified (buf) + "Like `kill-buffer', but does nothing if the buffer is modified." + (let ((buf (or (bufferp buf) (get-buffer buf)))) + (and buf (not (buffer-modified-p buf)) + (kill-buffer buf)))) + ;;;###autoload (defun view-file (file) "View FILE in View mode, returning to previous buffer when done. @@ -258,7 +264,7 @@ This command runs the normal hook `view-mode-hook'." (progn (switch-to-buffer buffer) (message "Not using View mode because the major mode is special")) - (view-buffer buffer (and (not had-a-buf) 'kill-buffer))))) + (view-buffer buffer (and (not had-a-buf) 'kill-buffer-if-not-modified))))) ;;;###autoload (defun view-file-other-window (file) @@ -279,8 +285,7 @@ This command runs the normal hook `view-mode-hook'." (buf-to-view (find-file-noselect file))) (view-buffer-other-window buf-to-view nil (and (not had-a-buf) - (not (buffer-modified-p buf-to-view)) - 'kill-buffer)))) + 'kill-buffer-if-not-modified)))) ;;;###autoload (defun view-file-other-frame (file) @@ -302,8 +307,7 @@ This command runs the normal hook `view-mode-hook'." (buf-to-view (find-file-noselect file))) (view-buffer-other-frame buf-to-view nil (and (not had-a-buf) - (not (buffer-modified-p buf-to-view)) - 'kill-buffer)))) + 'kill-buffer-if-not-modified)))) ;;;###autoload From 1e1cbbbff99d787ae8c558d5ae627ffff46aced6 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sat, 12 Jan 2008 23:21:25 +0000 Subject: [PATCH 084/439] (woman-parse-numeric-arg): Change handling of `==': can be interned without a function definition. --- lisp/ChangeLog | 5 +++++ lisp/woman.el | 6 ++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 0d9fb0dfc13..5ffcef352c3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-12 Glenn Morris + + * woman.el (woman-parse-numeric-arg): Change handling of `==': + can be interned without a function definition. + 2008-01-12 Jason Rumney * nxml/nxml-mode.el (nxml-enable-unicode-char-name-sets) diff --git a/lisp/woman.el b/lisp/woman.el index 0778d424324..2ba414aef9c 100644 --- a/lisp/woman.el +++ b/lisp/woman.el @@ -3540,8 +3540,10 @@ The expression may be an argument in quotes." (setq value (funcall op value (woman-parse-numeric-value)))) ((looking-at "[<=>]=?") ; relational operators (goto-char (match-end 0)) - (setq op (or (intern-soft (match-string 0)) - (intern-soft "="))) + (setq op (intern-soft + (if (string-equal (match-string 0) "==") + "=" + (match-string 0)))) (setq value (if (funcall op value (woman-parse-numeric-value)) 1 0))) ((memq (setq op (following-char)) '(?& ?:)) ; Boolean and / or From 2769422068be44ed3b8af00e23beb6ede145d6bb Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sat, 12 Jan 2008 23:21:43 +0000 Subject: [PATCH 085/439] (woman-parse-numeric-arg): Change handling of `==': can be interned without a function definition. --- lisp/ChangeLog | 5 +++++ lisp/woman.el | 6 ++++-- 2 files changed, 9 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ef40bc36c9e..5f19204e0b5 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-12 Glenn Morris + + * woman.el (woman-parse-numeric-arg): Change handling of `==': + can be interned without a function definition. + 2008-01-12 Eli Zaretskii * view.el (view-file-other-window, view-file-other-frame): Don't diff --git a/lisp/woman.el b/lisp/woman.el index a04b606280b..595bb6cc9a1 100644 --- a/lisp/woman.el +++ b/lisp/woman.el @@ -3558,8 +3558,10 @@ The expression may be an argument in quotes." (setq value (funcall op value (woman-parse-numeric-value)))) ((looking-at "[<=>]=?") ; relational operators (goto-char (match-end 0)) - (setq op (or (intern-soft (match-string 0)) - (intern-soft "="))) + (setq op (intern-soft + (if (string-equal (match-string 0) "==") + "=" + (match-string 0)))) (setq value (if (funcall op value (woman-parse-numeric-value)) 1 0))) ((memq (setq op (following-char)) '(?& ?:)) ; Boolean and / or From 5c4133cb507d82f6f20542e9751e5343744afe73 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sat, 12 Jan 2008 23:48:35 +0000 Subject: [PATCH 086/439] Regenerate. --- lisp/emacs-lisp/cl-loaddefs.el | 114 ++++++++++++++++----------------- 1 file changed, 57 insertions(+), 57 deletions(-) diff --git a/lisp/emacs-lisp/cl-loaddefs.el b/lisp/emacs-lisp/cl-loaddefs.el index e47247557d0..bfc711478da 100644 --- a/lisp/emacs-lisp/cl-loaddefs.el +++ b/lisp/emacs-lisp/cl-loaddefs.el @@ -10,16 +10,16 @@ ;;;;;; ceiling* floor* isqrt lcm gcd cl-progv-before cl-set-frame-visible-p ;;;;;; cl-map-overlays cl-map-intervals cl-map-keymap-recursively ;;;;;; notevery notany every some mapcon mapcan mapl maplist map -;;;;;; cl-mapcar-many equalp coerce) "cl-extra" "cl-extra.el" "53c2b3ede19dac62cff13a37f58cdf9c") +;;;;;; cl-mapcar-many equalp coerce) "cl-extra" "cl-extra.el" "2f89c94c42629315419a9d7404469c42") ;;; Generated autoloads from cl-extra.el -(autoload (quote coerce) "cl-extra" "\ +(autoload 'coerce "cl-extra" "\ Coerce OBJECT to type TYPE. TYPE is a Common Lisp type specifier. \(fn OBJECT TYPE)" nil nil) -(autoload (quote equalp) "cl-extra" "\ +(autoload 'equalp "cl-extra" "\ Return t if two Lisp objects have similar structures and contents. This is like `equal', except that it accepts numerically equal numbers of different types (float vs. integer), and also compares @@ -27,246 +27,246 @@ strings case-insensitively. \(fn X Y)" nil nil) -(autoload (quote cl-mapcar-many) "cl-extra" "\ +(autoload 'cl-mapcar-many "cl-extra" "\ Not documented \(fn CL-FUNC CL-SEQS)" nil nil) -(autoload (quote map) "cl-extra" "\ +(autoload 'map "cl-extra" "\ Map a FUNCTION across one or more SEQUENCEs, returning a sequence. TYPE is the sequence type to return. \(fn TYPE FUNCTION SEQUENCE...)" nil nil) -(autoload (quote maplist) "cl-extra" "\ +(autoload 'maplist "cl-extra" "\ Map FUNCTION to each sublist of LIST or LISTs. Like `mapcar', except applies to lists and their cdr's rather than to the elements themselves. \(fn FUNCTION LIST...)" nil nil) -(autoload (quote mapl) "cl-extra" "\ +(autoload 'mapl "cl-extra" "\ Like `maplist', but does not accumulate values returned by the function. \(fn FUNCTION LIST...)" nil nil) -(autoload (quote mapcan) "cl-extra" "\ +(autoload 'mapcan "cl-extra" "\ Like `mapcar', but nconc's together the values returned by the function. \(fn FUNCTION SEQUENCE...)" nil nil) -(autoload (quote mapcon) "cl-extra" "\ +(autoload 'mapcon "cl-extra" "\ Like `maplist', but nconc's together the values returned by the function. \(fn FUNCTION LIST...)" nil nil) -(autoload (quote some) "cl-extra" "\ +(autoload 'some "cl-extra" "\ Return true if PREDICATE is true of any element of SEQ or SEQs. If so, return the true (non-nil) value returned by PREDICATE. \(fn PREDICATE SEQ...)" nil nil) -(autoload (quote every) "cl-extra" "\ +(autoload 'every "cl-extra" "\ Return true if PREDICATE is true of every element of SEQ or SEQs. \(fn PREDICATE SEQ...)" nil nil) -(autoload (quote notany) "cl-extra" "\ +(autoload 'notany "cl-extra" "\ Return true if PREDICATE is false of every element of SEQ or SEQs. \(fn PREDICATE SEQ...)" nil nil) -(autoload (quote notevery) "cl-extra" "\ +(autoload 'notevery "cl-extra" "\ Return true if PREDICATE is false of some element of SEQ or SEQs. \(fn PREDICATE SEQ...)" nil nil) -(defalias (quote cl-map-keymap) (quote map-keymap)) +(defalias 'cl-map-keymap 'map-keymap) -(autoload (quote cl-map-keymap-recursively) "cl-extra" "\ +(autoload 'cl-map-keymap-recursively "cl-extra" "\ Not documented \(fn CL-FUNC-REC CL-MAP &optional CL-BASE)" nil nil) -(autoload (quote cl-map-intervals) "cl-extra" "\ +(autoload 'cl-map-intervals "cl-extra" "\ Not documented \(fn CL-FUNC &optional CL-WHAT CL-PROP CL-START CL-END)" nil nil) -(autoload (quote cl-map-overlays) "cl-extra" "\ +(autoload 'cl-map-overlays "cl-extra" "\ Not documented \(fn CL-FUNC &optional CL-BUFFER CL-START CL-END CL-ARG)" nil nil) -(autoload (quote cl-set-frame-visible-p) "cl-extra" "\ +(autoload 'cl-set-frame-visible-p "cl-extra" "\ Not documented \(fn FRAME VAL)" nil nil) -(autoload (quote cl-progv-before) "cl-extra" "\ +(autoload 'cl-progv-before "cl-extra" "\ Not documented \(fn SYMS VALUES)" nil nil) -(autoload (quote gcd) "cl-extra" "\ +(autoload 'gcd "cl-extra" "\ Return the greatest common divisor of the arguments. \(fn &rest ARGS)" nil nil) -(autoload (quote lcm) "cl-extra" "\ +(autoload 'lcm "cl-extra" "\ Return the least common multiple of the arguments. \(fn &rest ARGS)" nil nil) -(autoload (quote isqrt) "cl-extra" "\ +(autoload 'isqrt "cl-extra" "\ Return the integer square root of the argument. \(fn X)" nil nil) -(autoload (quote floor*) "cl-extra" "\ +(autoload 'floor* "cl-extra" "\ Return a list of the floor of X and the fractional part of X. With two arguments, return floor and remainder of their quotient. \(fn X &optional Y)" nil nil) -(autoload (quote ceiling*) "cl-extra" "\ +(autoload 'ceiling* "cl-extra" "\ Return a list of the ceiling of X and the fractional part of X. With two arguments, return ceiling and remainder of their quotient. \(fn X &optional Y)" nil nil) -(autoload (quote truncate*) "cl-extra" "\ +(autoload 'truncate* "cl-extra" "\ Return a list of the integer part of X and the fractional part of X. With two arguments, return truncation and remainder of their quotient. \(fn X &optional Y)" nil nil) -(autoload (quote round*) "cl-extra" "\ +(autoload 'round* "cl-extra" "\ Return a list of X rounded to the nearest integer and the remainder. With two arguments, return rounding and remainder of their quotient. \(fn X &optional Y)" nil nil) -(autoload (quote mod*) "cl-extra" "\ +(autoload 'mod* "cl-extra" "\ The remainder of X divided by Y, with the same sign as Y. \(fn X Y)" nil nil) -(autoload (quote rem*) "cl-extra" "\ +(autoload 'rem* "cl-extra" "\ The remainder of X divided by Y, with the same sign as X. \(fn X Y)" nil nil) -(autoload (quote signum) "cl-extra" "\ +(autoload 'signum "cl-extra" "\ Return 1 if X is positive, -1 if negative, 0 if zero. \(fn X)" nil nil) -(autoload (quote random*) "cl-extra" "\ +(autoload 'random* "cl-extra" "\ Return a random nonnegative number less than LIM, an integer or float. Optional second arg STATE is a random-state object. \(fn LIM &optional STATE)" nil nil) -(autoload (quote make-random-state) "cl-extra" "\ +(autoload 'make-random-state "cl-extra" "\ Return a copy of random-state STATE, or of `*random-state*' if omitted. If STATE is t, return a new state object seeded from the time of day. \(fn &optional STATE)" nil nil) -(autoload (quote random-state-p) "cl-extra" "\ +(autoload 'random-state-p "cl-extra" "\ Return t if OBJECT is a random-state object. \(fn OBJECT)" nil nil) -(autoload (quote cl-float-limits) "cl-extra" "\ +(autoload 'cl-float-limits "cl-extra" "\ Not documented \(fn)" nil nil) -(autoload (quote subseq) "cl-extra" "\ +(autoload 'subseq "cl-extra" "\ Return the subsequence of SEQ from START to END. If END is omitted, it defaults to the length of the sequence. If START or END is negative, it counts from the end. \(fn SEQ START &optional END)" nil nil) -(autoload (quote concatenate) "cl-extra" "\ +(autoload 'concatenate "cl-extra" "\ Concatenate, into a sequence of type TYPE, the argument SEQUENCEs. \(fn TYPE SEQUENCE...)" nil nil) -(autoload (quote revappend) "cl-extra" "\ +(autoload 'revappend "cl-extra" "\ Equivalent to (append (reverse X) Y). \(fn X Y)" nil nil) -(autoload (quote nreconc) "cl-extra" "\ +(autoload 'nreconc "cl-extra" "\ Equivalent to (nconc (nreverse X) Y). \(fn X Y)" nil nil) -(autoload (quote list-length) "cl-extra" "\ +(autoload 'list-length "cl-extra" "\ Return the length of list X. Return nil if list is circular. \(fn X)" nil nil) -(autoload (quote tailp) "cl-extra" "\ +(autoload 'tailp "cl-extra" "\ Return true if SUBLIST is a tail of LIST. \(fn SUBLIST LIST)" nil nil) -(autoload (quote get*) "cl-extra" "\ +(autoload 'get* "cl-extra" "\ Return the value of SYMBOL's PROPNAME property, or DEFAULT if none. \(fn SYMBOL PROPNAME &optional DEFAULT)" nil nil) -(autoload (quote getf) "cl-extra" "\ +(autoload 'getf "cl-extra" "\ Search PROPLIST for property PROPNAME; return its value or DEFAULT. PROPLIST is a list of the sort returned by `symbol-plist'. \(fn PROPLIST PROPNAME &optional DEFAULT)" nil nil) -(autoload (quote cl-set-getf) "cl-extra" "\ +(autoload 'cl-set-getf "cl-extra" "\ Not documented \(fn PLIST TAG VAL)" nil nil) -(autoload (quote cl-do-remf) "cl-extra" "\ +(autoload 'cl-do-remf "cl-extra" "\ Not documented \(fn PLIST TAG)" nil nil) -(autoload (quote cl-remprop) "cl-extra" "\ +(autoload 'cl-remprop "cl-extra" "\ Remove from SYMBOL's plist the property PROPNAME and its value. \(fn SYMBOL PROPNAME)" nil nil) -(defalias (quote remprop) (quote cl-remprop)) +(defalias 'remprop 'cl-remprop) -(defalias (quote cl-gethash) (quote gethash)) +(defalias 'cl-gethash 'gethash) -(defalias (quote cl-puthash) (quote puthash)) +(defalias 'cl-puthash 'puthash) -(defalias (quote cl-remhash) (quote remhash)) +(defalias 'cl-remhash 'remhash) -(defalias (quote cl-clrhash) (quote clrhash)) +(defalias 'cl-clrhash 'clrhash) -(defalias (quote cl-maphash) (quote maphash)) +(defalias 'cl-maphash 'maphash) -(defalias (quote cl-make-hash-table) (quote make-hash-table)) +(defalias 'cl-make-hash-table 'make-hash-table) -(defalias (quote cl-hash-table-p) (quote hash-table-p)) +(defalias 'cl-hash-table-p 'hash-table-p) -(defalias (quote cl-hash-table-count) (quote hash-table-count)) +(defalias 'cl-hash-table-count 'hash-table-count) -(autoload (quote cl-macroexpand-all) "cl-extra" "\ +(autoload 'cl-macroexpand-all "cl-extra" "\ Expand all macro calls through a Lisp FORM. This also does some trivial optimizations to make the form prettier. \(fn FORM &optional ENV)" nil nil) -(autoload (quote cl-prettyexpand) "cl-extra" "\ +(autoload 'cl-prettyexpand "cl-extra" "\ Not documented \(fn FORM &optional FULL)" nil nil) @@ -283,7 +283,7 @@ Not documented ;;;;;; do* do loop return-from return block etypecase typecase ecase ;;;;;; case load-time-value eval-when destructuring-bind function* ;;;;;; defmacro* defun* gentemp gensym cl-compile-time-init) "cl-macs" -;;;;;; "cl-macs.el" "c9b59a98f2066022e751aa5203b8d6b0") +;;;;;; "cl-macs.el" "b75c9203d71424764cb7d91607a965eb") ;;; Generated autoloads from cl-macs.el (autoload 'cl-compile-time-init "cl-macs" "\ @@ -745,7 +745,7 @@ Not documented ;;;;;; find nsubstitute-if-not nsubstitute-if nsubstitute substitute-if-not ;;;;;; substitute-if substitute delete-duplicates remove-duplicates ;;;;;; delete-if-not delete-if delete* remove-if-not remove-if remove* -;;;;;; replace fill reduce) "cl-seq" "cl-seq.el" "77bee7df392948b6ab0699e391e8abc1") +;;;;;; replace fill reduce) "cl-seq" "cl-seq.el" "e3c349e5231811c1c0482dd378dae56a") ;;; Generated autoloads from cl-seq.el (autoload 'reduce "cl-seq" "\ From 8d8ccf3636b6ae7f296ac4613b2dc87c7b159599 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sat, 12 Jan 2008 23:58:50 +0000 Subject: [PATCH 087/439] Regenerate for new tpu-extras md5sum in generated autoload. --- lisp/emulation/tpu-edt.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/emulation/tpu-edt.el b/lisp/emulation/tpu-edt.el index 686a79c9350..ff0e6ad25eb 100644 --- a/lisp/emulation/tpu-edt.el +++ b/lisp/emulation/tpu-edt.el @@ -2439,7 +2439,7 @@ If FILE is nil, try to load a default file. The default file names are ;;;### (autoloads (tpu-set-cursor-bound tpu-set-cursor-free tpu-set-scroll-margins -;;;;;; tpu-cursor-free-mode) "tpu-extras" "tpu-extras.el" "e0629234f1abe076917a303456b48329") +;;;;;; tpu-cursor-free-mode) "tpu-extras" "tpu-extras.el" "c7ce8bad68736a5682eb3f5f5edc48db") ;;; Generated autoloads from tpu-extras.el (autoload 'tpu-cursor-free-mode "tpu-extras" "\ From e39a993cce3b5d82cb997e34200a5395c315e3a6 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 13 Jan 2008 00:43:55 +0000 Subject: [PATCH 088/439] * movemail.c: * make-docfile.c: Remove reference to symbols defined by systems not supported anymore: MAC_OS8, XENIX and STRIDE. * (src/m/mips.h): * (src/m/intel386.h): * callproc.c: * config.in: * ecrt0.c: * emacs.c: * fileio.c: * frame.c: * getpagesize.h: * keyboard.c: * lread.c: * process.c: * puresize.h: * sysdep.c: * systty.h: * syswait.h: * unexec.c: * xdisp.c: * alloc.c: Remove code containing references to symbols defined by unsupported systems. --- lib-src/ChangeLog | 6 + lib-src/make-docfile.c | 4 - lib-src/movemail.c | 6 - src/ChangeLog | 25 ++++ src/alloc.c | 6 +- src/callproc.c | 87 +------------- src/config.in | 7 -- src/ecrt0.c | 266 ----------------------------------------- src/emacs.c | 39 ------ src/fileio.c | 40 +------ src/frame.c | 14 +-- src/getpagesize.h | 4 - src/keyboard.c | 17 +-- src/lread.c | 3 - src/m/intel386.h | 11 -- src/m/mips.h | 8 +- src/process.c | 41 ++----- src/puresize.h | 2 +- src/sysdep.c | 127 +------------------- src/systty.h | 27 ----- src/syswait.h | 4 +- src/unexec.c | 88 -------------- src/xdisp.c | 3 - 23 files changed, 67 insertions(+), 768 deletions(-) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index 07d73545468..bb28500d68d 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,9 @@ +2008-01-13 Dan Nicolaescu + + * movemail.c: + * make-docfile.c: Remove reference to symbols defined by systems + not supported anymore: MAC_OS8, XENIX and STRIDE. + 2008-01-12 Eli Zaretskii * emacsclient.c (decode_options) [WINDOWSNT]: Don't use the value diff --git a/lib-src/make-docfile.c b/lib-src/make-docfile.c index 1564aca5bbe..6e22eb857e3 100644 --- a/lib-src/make-docfile.c +++ b/lib-src/make-docfile.c @@ -62,11 +62,7 @@ Boston, MA 02110-1301, USA. */ #endif /* not DOS_NT */ #ifndef DIRECTORY_SEP -#ifdef MAC_OS8 -#define DIRECTORY_SEP ':' -#else /* not MAC_OS8 */ #define DIRECTORY_SEP '/' -#endif /* not MAC_OS8 */ #endif #ifndef IS_DIRECTORY_SEP diff --git a/lib-src/movemail.c b/lib-src/movemail.c index 7c647676ff5..daf8c6166e6 100644 --- a/lib-src/movemail.c +++ b/lib-src/movemail.c @@ -503,13 +503,7 @@ main (argc, argv) #ifdef MAIL_USE_SYSTEM_LOCK if (! preserve_mail) { -#if defined (STRIDE) || defined (XENIX) - /* Stride, xenix have file locking, but no ftruncate. - This mess will do. */ - close (open (inname, O_CREAT | O_TRUNC | O_RDWR, 0666)); -#else ftruncate (indesc, 0L); -#endif /* STRIDE or XENIX */ } #endif /* MAIL_USE_SYSTEM_LOCK */ diff --git a/src/ChangeLog b/src/ChangeLog index d56550fb1a3..0ad3ba97e0f 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,28 @@ +2008-01-13 Dan Nicolaescu + + * (unexsunos4): Remove file, system not supported anymore. + + * (src/m/mips.h): + * (src/m/intel386.h): + * callproc.c: + * config.in: + * ecrt0.c: + * emacs.c: + * fileio.c: + * frame.c: + * getpagesize.h: + * keyboard.c: + * lread.c: + * process.c: + * puresize.h: + * sysdep.c: + * systty.h: + * syswait.h: + * unexec.c: + * xdisp.c: + * alloc.c: Remove code containing references to symbols defined by + unsupported systems. + 2008-01-11 Kenichi Handa * coding.c (detect_coding_mask): Fix previous change. diff --git a/src/alloc.c b/src/alloc.c index 6ded38c17da..86a48e4dd18 100644 --- a/src/alloc.c +++ b/src/alloc.c @@ -1928,11 +1928,7 @@ allocate_string () consing_since_gc += sizeof *s; #ifdef GC_CHECK_STRING_BYTES - if (!noninteractive -#ifdef MAC_OS8 - && current_sblock -#endif - ) + if (!noninteractive) { if (++check_string_bytes_count == 200) { diff --git a/src/callproc.c b/src/callproc.c index ef5fcc8f400..2078c4411fd 100644 --- a/src/callproc.c +++ b/src/callproc.c @@ -160,14 +160,14 @@ Lisp_Object call_process_cleanup (fdpid) Lisp_Object fdpid; { -#if defined (MSDOS) || defined (MAC_OS8) +#if defined (MSDOS) /* for MSDOS fdpid is really (fd . tempfile) */ register Lisp_Object file; file = Fcdr (fdpid); emacs_close (XFASTINT (Fcar (fdpid))); if (strcmp (SDATA (file), NULL_DEVICE) != 0) unlink (SDATA (file)); -#else /* not MSDOS and not MAC_OS8 */ +#else /* not MSDOS */ register int pid = XFASTINT (Fcdr (fdpid)); if (call_process_exited) @@ -244,10 +244,6 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) char *outf, *tempfile; int outfilefd; #endif -#ifdef MAC_OS8 - char *tempfile; - int outfilefd; -#endif #if 0 int mask; #endif @@ -470,39 +466,11 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) fd[1] = outfilefd; #endif /* MSDOS */ -#ifdef MAC_OS8 - /* Since we don't have pipes on the Mac, create a temporary file to - hold the output of the subprocess. */ - tempfile = (char *) alloca (SBYTES (Vtemp_file_name_pattern) + 1); - bcopy (SDATA (Vtemp_file_name_pattern), tempfile, - SBYTES (Vtemp_file_name_pattern) + 1); - - mktemp (tempfile); - - outfilefd = creat (tempfile, S_IREAD | S_IWRITE); - if (outfilefd < 0) - { - close (filefd); - report_file_error ("Opening process output file", - Fcons (build_string (tempfile), Qnil)); - } - fd[0] = filefd; - fd[1] = outfilefd; -#endif /* MAC_OS8 */ - if (INTEGERP (buffer)) fd[1] = emacs_open (NULL_DEVICE, O_WRONLY, 0), fd[0] = -1; else { #ifndef MSDOS -#ifndef MAC_OS8 - errno = 0; - if (pipe (fd) == -1) - { - emacs_close (filefd); - report_file_error ("Creating process pipe", Qnil); - } -#endif #endif #if 0 /* Replaced by close_process_descs */ @@ -561,52 +529,6 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) report_file_error ("Cannot redirect stderr", Fcons (error_file, Qnil)); } -#ifdef MAC_OS8 - { - /* Call run_mac_command in sysdep.c here directly instead of doing - a child_setup as for MSDOS and other platforms. Note that this - code does not handle passing the environment to the synchronous - Mac subprocess. */ - char *infn, *outfn, *errfn, *currdn; - - /* close these files so subprocess can write to them */ - close (outfilefd); - if (fd_error != outfilefd) - close (fd_error); - fd1 = -1; /* No harm in closing that one! */ - - infn = SDATA (infile); - outfn = tempfile; - if (NILP (error_file)) - errfn = NULL_DEVICE; - else if (EQ (Qt, error_file)) - errfn = outfn; - else - errfn = SDATA (error_file); - currdn = SDATA (current_dir); - pid = run_mac_command (new_argv, currdn, infn, outfn, errfn); - - /* Record that the synchronous process exited and note its - termination status. */ - synch_process_alive = 0; - synch_process_retcode = pid; - if (synch_process_retcode < 0) /* means it couldn't be exec'ed */ - { - synchronize_system_messages_locale (); - synch_process_death = strerror (errno); - } - - /* Since CRLF is converted to LF within `decode_coding', we can - always open a file with binary mode. */ - fd[0] = open (tempfile, O_BINARY); - if (fd[0] < 0) - { - unlink (tempfile); - close (filefd); - report_file_error ("Cannot re-open temporary file", Qnil); - } - } -#else /* not MAC_OS8 */ #ifdef MSDOS /* MW, July 1993 */ /* Note that on MSDOS `child_setup' actually returns the child process exit status, not its PID, so we assign it to `synch_process_retcode' @@ -669,7 +591,6 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) if (fd_error >= 0) emacs_close (fd_error); #endif /* not MSDOS */ -#endif /* not MAC_OS8 */ environ = save_environ; @@ -703,14 +624,14 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) /* Enable sending signal if user quits below. */ call_process_exited = 0; -#if defined(MSDOS) || defined(MAC_OS8) +#if defined(MSDOS) /* MSDOS needs different cleanup information. */ record_unwind_protect (call_process_cleanup, Fcons (make_number (fd[0]), build_string (tempfile))); #else record_unwind_protect (call_process_cleanup, Fcons (make_number (fd[0]), make_number (pid))); -#endif /* not MSDOS and not MAC_OS8 */ +#endif /* not MSDOS */ if (BUFFERP (buffer)) diff --git a/src/config.in b/src/config.in index 27f89c29b90..75a2058c41a 100644 --- a/src/config.in +++ b/src/config.in @@ -837,13 +837,6 @@ Boston, MA 02110-1301, USA. */ /* Define to 1 if your declares `struct tm'. */ #undef TM_IN_SYS_TIME -/* Define to 1 for Encore UMAX. */ -#undef UMAX - -/* Define to 1 for Encore UMAX 4.3 that has instead of - . */ -#undef UMAX4_3 - /* Define to the unexec source file name. */ #undef UNEXEC_SRC diff --git a/src/ecrt0.c b/src/ecrt0.c index 36f6caeceb9..41bd1c8b323 100644 --- a/src/ecrt0.c +++ b/src/ecrt0.c @@ -84,146 +84,6 @@ char **environ; static start1 (); #endif -#ifdef APOLLO -extern char *malloc(), *realloc(), *(*_libc_malloc) (), *(*_libc_realloc)(); -extern void free(), (*_libc_free) (); extern int main(); -std_$call void unix_$main(); - -_start() -{ - _libc_malloc = malloc; - _libc_realloc = realloc; - _libc_free = free; - unix_$main(main); /* no return */ -} -#endif /* APOLLO */ - -#if defined(orion) || defined(pyramid) || defined(celerity) || defined(ALLIANT) || defined(clipper) || defined(sps7) - -#if defined(sps7) && defined(V3x) - asm(" section 10"); - asm(" ds.b 0xb0"); -#endif - -#ifdef ALLIANT -/* _start must initialize _curbrk and _minbrk on the first startup; - when starting up after dumping, it must initialize them to what they were - before the dumping, since they are in the shared library and - are not dumped. See ADJUST_EXEC_HEADER in m-alliant.h. */ -extern unsigned char *_curbrk, *_minbrk; -extern unsigned char end; -unsigned char *_setbrk = &end; -#ifdef ALLIANT_2800 -unsigned char *_end = &end; -#endif -#endif - -#ifndef DUMMIES -#define DUMMIES -#endif - -_start (DUMMIES argc, argv, envp) - int argc; - char **argv, **envp; -{ -#ifdef ALLIANT -#ifdef ALLIANT_2800 - _curbrk = _end; - _minbrk = _end; -#else - _curbrk = _setbrk; - _minbrk = _setbrk; -#endif -#endif - - environ = envp; - - exit (main (argc, argv, envp)); -} - -#endif /* orion or pyramid or celerity or alliant or clipper */ - -#if defined (ns16000) && !defined (sequent) && !defined (UMAX) && !defined (CRT0_DUMMIES) - -_start () -{ -/* On 16000, _start pushes fp onto stack */ - start1 (); -} - -/* ignore takes care of skipping the fp value pushed in start. */ -static -start1 (ignore, argc, argv) - int ignore; - int argc; - register char **argv; -{ - environ = argv + argc + 1; - - if (environ == *argv) - environ--; - exit (main (argc, argv, environ)); -} -#endif /* ns16000, not sequent and not UMAX, and not the CRT0_DUMMIES method */ - -#ifdef UMAX -_start() -{ - asm(" exit [] # undo enter"); - asm(" .set exitsc,1"); - asm(" .set sigcatchall,0x400"); - - asm(" .globl _exit"); - asm(" .globl start"); - asm(" .globl __start"); - asm(" .globl _main"); - asm(" .globl _environ"); - asm(" .globl _sigvec"); - asm(" .globl sigentry"); - - asm("start:"); - asm(" br .xstart"); - asm(" .org 0x20"); - asm(" .double p_glbl,0,0xf00000,0"); - asm(" .org 0x30"); - asm(".xstart:"); - asm(" adjspb $8"); - asm(" movd 8(sp),0(sp) # argc"); - asm(" addr 12(sp),r0"); - asm(" movd r0,4(sp) # argv"); - asm("L1:"); - asm(" movd r0,r1"); - asm(" addqd $4,r0"); - asm(" cmpqd $0,0(r1) # null args term ?"); - asm(" bne L1"); - asm(" cmpd r0,0(4(sp)) # end of 'env' or 'argv' ?"); - asm(" blt L2"); - asm(" addqd $-4,r0 # envp's are in list"); - asm("L2:"); - asm(" movd r0,8(sp) # env"); - asm(" movd r0,@_environ # indir is 0 if no env ; not 0 if env"); - asm(" movqd $0,tos # setup intermediate signal handler"); - asm(" addr @sv,tos"); - asm(" movzwd $sigcatchall,tos"); - asm(" jsr @_sigvec"); - asm(" adjspb $-12"); - asm(" jsr @_main"); - asm(" adjspb $-12"); - asm(" movd r0,tos"); - asm(" jsr @_exit"); - asm(" adjspb $-4"); - asm(" addr @exitsc,r0"); - asm(" svc"); - asm(" .align 4 # sigvec arg"); - asm("sv:"); - asm(" .double sigentry"); - asm(" .double 0"); - asm(" .double 0"); - - asm(" .comm p_glbl,1"); -} -#endif /* UMAX */ - #ifdef CRT0_DUMMIES /* Define symbol "start": here; some systems want that symbol. */ @@ -295,21 +155,10 @@ start1 (CRT0_DUMMIES argc, xargv) asm (" global _start"); asm (" text"); asm ("_start:"); -#ifndef NU -#ifdef STRIDE - asm (" comm havefpu%,2"); -#else /* m68k, not STRIDE */ asm (" comm splimit%,4"); -#endif /* STRIDE */ asm (" global exit"); asm (" text"); -#ifdef STRIDE - asm (" trap &3"); - asm (" mov.w %d0,havefpu%"); -#else /* m68k, not STRIDE */ asm (" mov.l %d0,splimit%"); -#endif /* STRIDE */ -#endif /* not NU */ asm (" jsr start1"); asm (" mov.l %d0,(%sp)"); asm (" jsr exit"); @@ -319,32 +168,6 @@ start1 (CRT0_DUMMIES argc, xargv) #ifdef m68000 -#ifdef ISI68K -/* Added by ESM Sun May 24 12:44:02 1987 to get new ISI library to work */ -/* Edited by Ray Mon May 15 15:59:56 EST 1989 so we can compile with gcc */ -#if defined(BSD4_3) && !defined(__GNUC__) -static foo () { -#endif - asm (" .globl is68020"); - asm ("is68020:"); -#ifndef BSD4_3 - asm (" .long 0x00000000"); - asm (" .long 0xffffffff"); -/* End of stuff added by ESM */ -#endif - asm (" .text"); - asm (" .globl __start"); - asm ("__start:"); - asm (" .word 0"); - asm (" link a6,#0"); - asm (" jbsr _start1"); - asm (" unlk a6"); - asm (" rts"); -#if defined(BSD4_3) && !defined(__GNUC__) - } -#endif -#else /* not ISI68K */ - _start () { #ifdef sun @@ -353,7 +176,6 @@ _start () /* On 68000, _start pushes a6 onto stack */ start1 (); } -#endif /* not ISI68k */ #endif /* m68000 */ #endif /* m68k */ @@ -373,15 +195,6 @@ start1 (ignore, argc, xargv) if ((char *)environ == xargv) environ--; -#ifdef sun_68881 - asm(" jsr f68881_used"); -#endif -#ifdef sun_fpa - asm(" jsr ffpa_used"); -#endif -#ifdef sun_soft - asm(" jsr start_float"); -#endif exit (main (argc, argv, environ)); } @@ -503,85 +316,6 @@ char **argv_value; #endif /* new hp assembler */ #endif /* hp9000s300 */ -#ifdef GOULD - -/* startup code has to be in near text rather - than fartext as allocated by the C compiler. */ - asm(" .text"); - asm(" .align 2"); - asm(" .globl __start"); - asm(" .text"); - asm("__start:"); -/* setup base register b1 (function base). */ - asm(" .using b1,."); - asm(" tpcbr b1"); -/* setup base registers b3 through b7 (data references). */ - asm(" file basevals,b3"); -/* setup base register b2 (stack pointer); it should be - aligned on a 8-word boundary; but because it is pointing - to argc, its value should be remembered (in r5). */ - asm(" movw b2,r4"); - asm(" movw b2,r5"); - asm(" andw #~0x1f,r4"); - asm(" movw r4,b2"); -/* allocate stack frame to do some work. */ - asm(" subea 16w,b2"); -/* initialize signal catching for UTX/32 1.2; this is - necessary to make restart from saved image work. */ - asm(" movea sigcatch,r1"); - asm(" movw r1,8w[b2]"); - asm(" svc #1,#150"); -/* setup address of argc for start1. */ - asm(" movw r5,8w[b2]"); - asm(" func #1,_start1"); - asm(" halt"); -/* space for ld to store base register initial values. */ - asm(" .align 5"); - asm("basevals:"); - asm(" .word __base3,__base4,__base5,__base6,__base7"); - -static -start1 (xargc) - int *xargc; -{ - register int argc; - register char **argv; - - argc = *xargc; - argv = (char **)(xargc) + 1; - environ = argv + argc + 1; - - if (environ == argv) - environ--; - exit (main (argc, argv, environ)); - -} - -#endif /* GOULD */ - -#ifdef elxsi -#include - -extern char **environ; -extern int errno; -extern void _init_doscan(), _init_iob(); -extern char end[]; -char *_init_brk = end; - -_start() -{ - environ = exec_cache.ac_envp; - brk (_init_brk); - errno = 0; - _init_doscan (); - _init_iob (); - _exit (exit (main (exec_cache.ac_argc, - exec_cache.ac_argv, - exec_cache.ac_envp))); -} -#endif /* elxsi */ - - #ifdef sparc asm (".global __start"); asm (".text"); diff --git a/src/emacs.c b/src/emacs.c index d990e1a6158..9a520951610 100644 --- a/src/emacs.c +++ b/src/emacs.c @@ -1307,29 +1307,6 @@ main (argc, argv CANNOT_DUMP is defined. */ syms_of_keyboard (); -#ifdef MAC_OS8 - /* init_window_once calls make_terminal_frame which on Mac OS - creates a full-fledge output_mac type frame. This does not - work correctly before syms_of_textprop, syms_of_macfns, - syms_of_ccl, syms_of_fontset, syms_of_xterm, syms_of_search, - syms_of_frame, mac_term_init, and init_keyboard have already - been called. */ - syms_of_textprop (); - syms_of_macfns (); - syms_of_ccl (); - syms_of_fontset (); - syms_of_macterm (); - syms_of_macmenu (); - syms_of_macselect (); - syms_of_data (); - syms_of_search (); - syms_of_frame (); - - init_atimer (); - mac_term_init (build_string ("Mac"), NULL, NULL); - init_keyboard (); -#endif - init_window_once (); /* Init the window system. */ init_fileio_once (); /* Must precede any path manipulation. */ #ifdef HAVE_WINDOW_SYSTEM @@ -1351,9 +1328,7 @@ main (argc, argv #ifdef CLASH_DETECTION init_filelock (); #endif -#ifndef MAC_OS8 init_atimer (); -#endif running_asynch_code = 0; /* Handle --unibyte and the EMACS_UNIBYTE envvar, @@ -1533,10 +1508,8 @@ main (argc, argv /* The basic levels of Lisp must come first. */ /* And data must come first of all for the sake of symbols like error-message. */ -#ifndef MAC_OS8 /* Called before init_window_once for Mac OS Classic. */ syms_of_data (); -#endif syms_of_alloc (); syms_of_lread (); syms_of_print (); @@ -1551,10 +1524,7 @@ main (argc, argv syms_of_casetab (); syms_of_callproc (); syms_of_category (); -#ifndef MAC_OS8 - /* Called before init_window_once for Mac OS Classic. */ syms_of_ccl (); -#endif syms_of_charset (); syms_of_cmds (); #ifndef NO_DIR_LIBRARY @@ -1576,11 +1546,8 @@ main (argc, argv syms_of_marker (); syms_of_minibuf (); syms_of_process (); -#ifndef MAC_OS8 - /* Called before init_window_once for Mac OS Classic. */ syms_of_search (); syms_of_frame (); -#endif syms_of_syntax (); syms_of_terminal (); syms_of_term (); @@ -1588,10 +1555,7 @@ main (argc, argv #ifdef HAVE_SOUND syms_of_sound (); #endif -#ifndef MAC_OS8 - /* Called before init_window_once for Mac OS Classic. */ syms_of_textprop (); -#endif syms_of_composite (); #ifdef VMS syms_of_vmsproc (); @@ -1673,10 +1637,7 @@ main (argc, argv init_editfns (); /* init_process uses Voperating_system_release. */ init_process (); /* init_display uses add_keyboard_wait_descriptor. */ -#ifndef MAC_OS8 - /* Called before init_window_once for Mac OS Classic. */ init_keyboard (); /* This too must precede init_sys_modes. */ -#endif #ifdef VMS init_vmsproc (); /* And this too. */ #endif /* VMS */ diff --git a/src/fileio.c b/src/fileio.c index d921916a4de..2789ab3fbd5 100644 --- a/src/fileio.c +++ b/src/fileio.c @@ -68,10 +68,6 @@ extern int errno; #endif #endif -#ifdef APOLLO -#include -#endif - #include "lisp.h" #include "intervals.h" #include "buffer.h" @@ -810,12 +806,6 @@ directory_file_name (src, dst) /* Process as Unix format: just remove any final slash. But leave "/" unchanged; do not change it to "". */ strcpy (dst, src); -#ifdef APOLLO - /* Handle // as root for apollo's. */ - if ((slen > 2 && dst[slen - 1] == '/') - || (slen > 1 && dst[0] != '/' && dst[slen - 1] == '/')) - dst[slen - 1] = 0; -#else if (slen > 1 && IS_DIRECTORY_SEP (dst[slen - 1]) #ifdef DOS_NT @@ -823,7 +813,6 @@ directory_file_name (src, dst) #endif ) dst[slen - 1] = 0; -#endif #ifdef DOS_NT CORRECT_DIR_SEPS (dst); #endif @@ -1788,10 +1777,6 @@ See also the function `substitute-in-file-name'.") while (*p) { if (p[0] == '/' && p[1] == '/' -#ifdef APOLLO - /* // at start of filename is meaningful on Apollo system. */ - && nm != p -#endif /* APOLLO */ ) nm = p + 1; if (p[0] == '/' && p[1] == '~') @@ -2023,10 +2008,6 @@ See also the function `substitute-in-file-name'.") *o++ = *p++; } else if (!strncmp (p, "//", 2) -#ifdef APOLLO - /* // at start of filename is meaningful in Apollo system. */ - && o != target -#endif /* APOLLO */ ) { o = target; @@ -2042,11 +2023,6 @@ See also the function `substitute-in-file-name'.") { while (o != target && *--o != '/') ; -#ifdef APOLLO - if (o == target + 1 && o[-1] == '/' && o[0] == '/') - ++o; - else -#endif /* APOLLO */ if (o == target && *o == '/') ++o; p += 3; @@ -2097,11 +2073,11 @@ search_embedded_absfilename (nm, endp) #endif /* VMS */ || IS_DIRECTORY_SEP (p[-1])) && file_name_absolute_p (p) -#if defined (APOLLO) || defined (WINDOWSNT) || defined(CYGWIN) +#if defined (WINDOWSNT) || defined(CYGWIN) /* // at start of file name is meaningful in Apollo, WindowsNT and Cygwin systems. */ && !(IS_DIRECTORY_SEP (p[0]) && p - 1 == nm) -#endif /* not (APOLLO || WINDOWSNT || CYGWIN) */ +#endif /* not (WINDOWSNT || CYGWIN) */ ) { for (s = p; *s && (!IS_DIRECTORY_SEP (*s) @@ -3782,12 +3758,7 @@ variable `last-coding-system-used' to the coding system actually used. */) } if (total < 0) #else -#ifndef APOLLO if (stat (SDATA (filename), &st) < 0) -#else - if ((fd = emacs_open (SDATA (filename), O_RDONLY, 0)) < 0 - || fstat (fd, &st) < 0) -#endif /* not APOLLO */ #endif /* WINDOWSNT */ { if (fd >= 0) emacs_close (fd); @@ -4665,9 +4636,6 @@ variable `last-coding-system-used' to the coding system actually used. */) { if (!EQ (current_buffer->undo_list, Qt)) current_buffer->undo_list = Qnil; -#ifdef APOLLO - stat (SDATA (filename), &st); -#endif if (NILP (handler)) { @@ -5376,15 +5344,13 @@ This does code conversion according to the value of but who knows about all the other machines with NFS?) */ #if 0 - /* On VMS and APOLLO, must do the stat after the close + /* On VMS, must do the stat after the close since closing changes the modtime. */ #ifndef VMS -#ifndef APOLLO /* Recall that #if defined does not work on VMS. */ #define FOO fstat (desc, &st); #endif -#endif #endif /* NFS can report a write failure now. */ diff --git a/src/frame.c b/src/frame.c index 9b921624bf7..77caef63442 100644 --- a/src/frame.c +++ b/src/frame.c @@ -592,9 +592,6 @@ make_terminal_frame (struct terminal *terminal) } else f->output_method = output_termcap; -#else -#ifdef MAC_OS8 - make_mac_terminal_frame (f); #else { f->output_method = output_termcap; @@ -620,7 +617,6 @@ make_terminal_frame (struct terminal *terminal) FRAME_FOREGROUND_PIXEL(f) = FACE_TTY_DEFAULT_FG_COLOR; FRAME_BACKGROUND_PIXEL(f) = FACE_TTY_DEFAULT_BG_COLOR; #endif -#endif /* MAC_OS8 */ #endif /* MSDOS */ if (!noninteractive) @@ -687,7 +683,7 @@ affects all frames on the same terminal device. */) abort (); #else /* not MSDOS */ -#if 0 /* #ifdef MAC_OS8 */ +#if 0 /* This can happen for multi-tty when using both terminal frames and Carbon frames. */ if (sf->output_method != output_mac) @@ -1359,13 +1355,7 @@ The functions are run with one arg, the frame to be deleted. */) if (! FRAME_LIVE_P (f)) return Qnil; - if (NILP (force) && !other_visible_frames (f) -#ifdef MAC_OS8 - /* Terminal frame deleted before any other visible frames are - created. */ - && strcmp (SDATA (f->name), "F1") != 0 -#endif - ) + if (NILP (force) && !other_visible_frames (f)) error ("Attempt to delete the sole visible or iconified frame"); #if 0 diff --git a/src/getpagesize.h b/src/getpagesize.h index 5c3180dc36e..ab54062f912 100644 --- a/src/getpagesize.h +++ b/src/getpagesize.h @@ -43,13 +43,9 @@ Boston, MA 02110-1301, USA. */ # define CLSIZE 1 # endif /* no CLSIZE */ # else /* no NBPG */ -# ifdef NBPC -# define getpagesize() NBPC -# else /* no NBPC */ # ifdef PAGESIZE # define getpagesize() PAGESIZE # endif /* PAGESIZE */ -# endif /* no NBPC */ # endif /* no NBPG */ # endif /* no EXEC_PAGESIZE */ # else /* no HAVE_SYS_PARAM_H */ diff --git a/src/keyboard.c b/src/keyboard.c index 0122e31396e..4d31c9e01b8 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -95,18 +95,7 @@ volatile int interrupt_input_blocked; during the current critical section. */ int interrupt_input_pending; - -#ifdef HAVE_WINDOW_SYSTEM -/* Make all keyboard buffers much bigger when using X windows. */ -#ifdef MAC_OS8 -/* But not too big (local data > 32K error) if on Mac OS Classic. */ -#define KBD_BUFFER_SIZE 512 -#else #define KBD_BUFFER_SIZE 4096 -#endif -#else /* No X-windows, character input */ -#define KBD_BUFFER_SIZE 4096 -#endif /* No X-windows */ #ifdef MULTI_KBOARD KBOARD *initial_kboard; @@ -7234,7 +7223,7 @@ tty_read_avail_input (struct terminal *terminal, if (n_to_read > sizeof cbuf) n_to_read = sizeof cbuf; #else /* no FIONREAD */ -#if defined (USG) || defined (DGUX) || defined(CYGWIN) +#if defined (USG) || defined(CYGWIN) /* Read some input if available, but don't wait. */ n_to_read = sizeof cbuf; fcntl (fileno (tty->input), F_SETFL, O_NDELAY); @@ -7284,9 +7273,9 @@ tty_read_avail_input (struct terminal *terminal, ); #ifndef FIONREAD -#if defined (USG) || defined (DGUX) || defined (CYGWIN) +#if defined (USG) || defined (CYGWIN) fcntl (fileno (tty->input), F_SETFL, 0); -#endif /* USG or DGUX or CYGWIN */ +#endif /* USG or CYGWIN */ #endif /* no FIONREAD */ if (nread <= 0) diff --git a/src/lread.c b/src/lread.c index a7fe30e9f89..271fd98a70c 100644 --- a/src/lread.c +++ b/src/lread.c @@ -1113,9 +1113,6 @@ complete_filename_p (pathname) return (IS_DIRECTORY_SEP (s[0]) || (SCHARS (pathname) > 2 && IS_DEVICE_SEP (s[1]) && IS_DIRECTORY_SEP (s[2])) -#ifdef ALTOS - || *s == '@' -#endif #ifdef VMS || index (s, ':') #endif /* VMS */ diff --git a/src/m/intel386.h b/src/m/intel386.h index 6ea2bbc60c6..17969dd16e4 100644 --- a/src/m/intel386.h +++ b/src/m/intel386.h @@ -85,17 +85,6 @@ NOTE-END */ #define DOT_GLOBAL_START -#ifdef XENIX -/* Data type of load average, as read out of kmem. */ -#define LOAD_AVE_TYPE short - -/* Convert that into an integer that is 100 for a load average of 1.0 */ -#define LOAD_AVE_CVT(x) (((double) (x)) * 100.0 / FSCALE) - -#define FSCALE 256.0 /* determined by experimentation... */ -#endif - - #ifdef SOLARIS2 /* Data type of load average, as read out of kmem. */ #define LOAD_AVE_TYPE long diff --git a/src/m/mips.h b/src/m/mips.h index 866a2a13742..f1401425603 100644 --- a/src/m/mips.h +++ b/src/m/mips.h @@ -130,7 +130,7 @@ NOTE-END */ /* Alter some of the options used when linking. */ -#if !defined(NEWSOS5) && !defined(__linux__) +#if !defined(__linux__) #ifdef BSD_SYSTEM /* DECstations don't have this library. @@ -161,7 +161,7 @@ NOTE-END */ #endif #endif /* not BSD_SYSTEM */ -#endif /* not NEWSOS5 && not __linux__ */ +#endif /* not __linux__ */ /* The standard definitions of these macros would work ok, but these are faster because the constants are short. */ @@ -173,7 +173,7 @@ NOTE-END */ ((int)(type) << VALBITS) \ + (((unsigned) (ptr) << (BITS_PER_INT-VALBITS)) >> (BITS_PER_INT-VALBITS))) -#if !defined (NEWSOS5) && !defined (__linux__) +#if !defined (__linux__) #ifdef USG /* Cancel certain parts of standard sysV support. */ @@ -213,7 +213,7 @@ NOTE-END */ #undef HAVE_UNION_WAIT #endif /* BSD_SYSTEM */ -#endif /* not NEWSOS5 && not __linux__ */ +#endif /* not __linux__ */ /* arch-tag: 8fd020ee-78a7-4d87-96ce-6129f52f7bee (do not change this comment) */ diff --git a/src/process.c b/src/process.c index a48e5435837..8e932be7b0c 100644 --- a/src/process.c +++ b/src/process.c @@ -78,7 +78,7 @@ Boston, MA 02110-1301, USA. */ #include #endif -/* On some systems, e.g. DGUX, inet_addr returns a 'struct in_addr'. */ +/* On some systems, inet_addr returns a 'struct in_addr'. */ #ifdef HAVE_BROKEN_INET_ADDR #define IN_ADDR struct in_addr #define NUMERIC_ADDR_ERROR (numeric_addr.s_addr == -1) @@ -87,12 +87,12 @@ Boston, MA 02110-1301, USA. */ #define NUMERIC_ADDR_ERROR (numeric_addr == -1) #endif -#if defined(BSD_SYSTEM) || defined(STRIDE) +#if defined(BSD_SYSTEM) #include #if !defined (O_NDELAY) && defined (HAVE_PTYS) && !defined(USG5) #include #endif /* HAVE_PTYS and no O_NDELAY */ -#endif /* BSD_SYSTEM || STRIDE */ +#endif /* BSD_SYSTEM */ #ifdef BROKEN_O_NONBLOCK #undef O_NONBLOCK @@ -596,7 +596,6 @@ allocate_pty () #else sprintf (pty_name, "/dev/tty%c%x", c, i); #endif /* no PTY_TTY_NAME_SPRINTF */ -#ifndef UNIPLUS if (access (pty_name, 6) != 0) { emacs_close (fd); @@ -606,7 +605,6 @@ allocate_pty () return -1; # endif /* IRIS */ } -#endif /* not UNIPLUS */ setup_pty (fd); return fd; } @@ -1889,12 +1887,12 @@ create_process (process, new_argv, current_dir) #endif if (forkin < 0) report_file_error ("Opening pty", Qnil); -#if defined (RTU) || defined (UNIPLUS) || defined (DONT_REOPEN_PTY) +#if defined (DONT_REOPEN_PTY) /* In the case that vfork is defined as fork, the parent process (Emacs) may send some data before the child process completes tty options setup. So we setup tty before forking. */ child_setup_tty (forkout); -#endif /* RTU or UNIPLUS or DONT_REOPEN_PTY */ +#endif /* DONT_REOPEN_PTY */ #else forkin = forkout = -1; #endif /* not USG, or USG_SUBTTY_WORKS */ @@ -1935,15 +1933,6 @@ create_process (process, new_argv, current_dir) set_exclusive_use (outchannel); #endif -/* Stride people say it's a mystery why this is needed - as well as the O_NDELAY, but that it fails without this. */ -#if defined (STRIDE) || (defined (pfa) && defined (HAVE_PTYS)) - { - int one = 1; - ioctl (inchannel, FIONBIO, &one); - } -#endif - #ifdef O_NONBLOCK fcntl (inchannel, F_SETFL, O_NONBLOCK); fcntl (outchannel, F_SETFL, O_NONBLOCK); @@ -1993,7 +1982,7 @@ create_process (process, new_argv, current_dir) #ifdef BSD4_1 sighold (SIGCHLD); #else /* not BSD4_1 */ -#if defined (BSD_SYSTEM) || defined (UNIPLUS) || defined (HPUX) +#if defined (BSD_SYSTEM) || defined (HPUX) sigsetmask (sigmask (SIGCHLD)); #else /* ordinary USG */ #if 0 @@ -2107,7 +2096,7 @@ create_process (process, new_argv, current_dir) } #endif /* TIOCNOTTY */ -#if !defined (RTU) && !defined (UNIPLUS) && !defined (DONT_REOPEN_PTY) +#if !defined (DONT_REOPEN_PTY) /*** There is a suggestion that this ought to be a conditional on TIOCSPGRP, or !(defined (HAVE_SETSID) && defined (TIOCSCTTY)). @@ -2141,7 +2130,7 @@ create_process (process, new_argv, current_dir) ioctl (xforkout, TIOCSPGRP, &pgrp); #endif } -#endif /* not UNIPLUS and not RTU and not DONT_REOPEN_PTY */ +#endif /* not DONT_REOPEN_PTY */ #ifdef SETUP_SLAVE_PTY if (pty_flag) @@ -2168,7 +2157,7 @@ create_process (process, new_argv, current_dir) #ifdef BSD4_1 sigrelse (SIGCHLD); #else /* not BSD4_1 */ -#if defined (BSD_SYSTEM) || defined (UNIPLUS) || defined (HPUX) +#if defined (BSD_SYSTEM) || defined (HPUX) sigsetmask (SIGEMPTYMASK); #else /* ordinary USG */ #if 0 @@ -2179,10 +2168,10 @@ create_process (process, new_argv, current_dir) #endif /* SIGCHLD */ #endif /* !POSIX_SIGNALS */ -#if !defined (RTU) && !defined (UNIPLUS) && !defined (DONT_REOPEN_PTY) +#if !defined (DONT_REOPEN_PTY) if (pty_flag) child_setup_tty (xforkout); -#endif /* not RTU and not UNIPLUS and not DONT_REOPEN_PTY */ +#endif /* not DONT_REOPEN_PTY */ #ifdef WINDOWSNT pid = child_setup (xforkin, xforkout, xforkout, new_argv, 1, current_dir); @@ -2260,7 +2249,7 @@ create_process (process, new_argv, current_dir) #ifdef BSD4_1 sigrelse (SIGCHLD); #else /* not BSD4_1 */ -#if defined (BSD_SYSTEM) || defined (UNIPLUS) || defined (HPUX) +#if defined (BSD_SYSTEM) || defined (HPUX) sigsetmask (SIGEMPTYMASK); #else /* ordinary USG */ #if 0 @@ -4650,12 +4639,6 @@ wait_reading_process_output (time_limit, microsecs, read_kbd, do_display, not by DEC's bundled CC. -JimB */ else if (xerrno == ENOMEM) no_avail = 1; -#endif -#ifdef ALLIANT - /* This happens for no known reason on ALLIANT. - I am guessing that this is the right response. -- RMS. */ - else if (xerrno == EFAULT) - no_avail = 1; #endif else if (xerrno == EBADF) { diff --git a/src/puresize.h b/src/puresize.h index 6f2982746ce..89632596546 100644 --- a/src/puresize.h +++ b/src/puresize.h @@ -70,7 +70,7 @@ extern void pure_write_error P_ ((void)) NO_RETURN; /* Define PURE_P. */ #if defined(VIRT_ADDR_VARIES) || defined(CYGWIN) -/* For machines like APOLLO where text and data can go anywhere +/* For machines where text and data can go anywhere in virtual memory. */ extern EMACS_INT pure[]; diff --git a/src/sysdep.c b/src/sysdep.c index 7c7b3810956..798cd3b2108 100644 --- a/src/sysdep.c +++ b/src/sysdep.c @@ -49,15 +49,6 @@ extern void srandom P_ ((unsigned int)); #include "blockinput.h" -#ifdef MAC_OS8 -#include - -#ifndef subprocesses -/* Nonzero means delete a process right away if it exits (process.c). */ -static int delete_exited_processes; -#endif -#endif /* MAC_OS8 */ - #ifdef WINDOWSNT #define read sys_read #define write sys_write @@ -151,12 +142,12 @@ extern int errno; #undef TIOCSWINSZ #endif -#if defined (USG) || defined (DGUX) +#if defined (USG) #include #ifndef MEMORY_IN_STRING_H #include #endif -#if defined (TIOCGWINSZ) || defined (ISC4_0) +#if defined (TIOCGWINSZ) #ifdef NEED_SIOCTL #include #endif @@ -164,8 +155,8 @@ extern int errno; #include #include #endif -#endif /* TIOCGWINSZ or ISC4_0 */ -#endif /* USG or DGUX */ +#endif /* TIOCGWINSZ */ +#endif /* USG */ extern int quit_char; @@ -345,17 +336,6 @@ discard_tty_input () &buf.main, 0, 0, terminator_mask, 0, 0); queue_kbd_input (); #else /* not VMS */ -#ifdef APOLLO - { - struct tty_display_info *tty; - for (tty = tty_list; tty; tty = tty->next) - { - int zero = 0; - if (tty->input) - ioctl (fileno (tty->input), TIOCFLUSH, &zero); - } - } -#else /* not Apollo */ #ifdef MSDOS /* Demacs 1.1.1 91/10/16 HIRANO Satoshi */ while (dos_keyread () != -1) ; @@ -372,7 +352,6 @@ discard_tty_input () } } #endif /* not MSDOS */ -#endif /* not Apollo */ #endif /* not VMS */ #endif /* not WINDOWSNT */ } @@ -532,11 +511,6 @@ wait_for_termination (pid) else sigpause (SIGEMPTYMASK); #else /* not BSD_SYSTEM, and not HPUX version >= 6 */ -#if defined (UNIPLUS) - if (0 > kill (pid, 0)) - break; - wait (0); -#else /* neither BSD_SYSTEM nor UNIPLUS: random sysV */ #ifdef POSIX_SIGNALS /* would this work for GNU/Linux as well? */ sigblock (sigmask (SIGCHLD)); errno = 0; @@ -570,7 +544,6 @@ wait_for_termination (pid) #endif /* not WINDOWSNT */ #endif /* not HAVE_SYSV_SIGPAUSE */ #endif /* not POSIX_SIGNALS */ -#endif /* not UNIPLUS */ #endif /* not BSD_SYSTEM, and not HPUX version >= 6 */ #endif /* not VMS */ #else /* not subprocesses */ @@ -727,12 +700,6 @@ child_setup_tty (out) if (interrupt_input) reset_sigio (0); #endif /* BSD4_1 */ -#ifdef RTU - { - int zero = 0; - ioctl (out, FIOASYNC, &zero); - } -#endif /* RTU */ #endif /* not DOS_NT */ } #endif /* not VMS */ @@ -821,7 +788,6 @@ sys_suspend () /* Fork a subshell. */ -#ifndef MAC_OS8 void sys_subshell () { @@ -957,7 +923,6 @@ sys_subshell () synch_process_alive = 0; #endif /* !VMS */ } -#endif /* !MAC_OS8 */ static void save_signal_handlers (saved_handlers) @@ -1066,69 +1031,6 @@ unrequest_sigio (void) } #else /* no FASYNC */ -#ifdef STRIDE /* Stride doesn't have FASYNC - use FIOASYNC */ - -void -request_sigio () -{ - int on = 1; - - if (noninteractive || read_socket_hook) - return; - - /* XXX CURTTY() is bogus here. */ - ioctl (fileno (CURTTY ()->input), FIOASYNC, &on); - interrupts_deferred = 0; -} - -void -unrequest_sigio () -{ - int off = 0; - - if (noninteractive || read_socket_hook) - return; - - /* XXX CURTTY() is bogus here. */ - ioctl (fileno (CURTTY ()->input), FIOASYNC, &off); - interrupts_deferred = 1; -} - -#else /* not FASYNC, not STRIDE */ - -#ifdef _CX_UX - -#include - -void -request_sigio () -{ - int on = 1; - sigset_t st; - - if (noninteractive || read_socket_hook) - return; - - sigemptyset (&st); - sigaddset (&st, SIGIO); - ioctl (0, FIOASYNC, &on); /* XXX This fails for multiple ttys. */ - interrupts_deferred = 0; - sigprocmask (SIG_UNBLOCK, &st, (sigset_t *)0); -} - -void -unrequest_sigio () -{ - int off = 0; - - if (noninteractive || read_socket_hook) - return; - - ioctl (0, FIOASYNC, &off); /* XXX This fails for multiple ttys. */ - interrupts_deferred = 1; -} - -#else /* ! _CX_UX */ #ifndef MSDOS void @@ -1150,8 +1052,6 @@ unrequest_sigio () } #endif /* MSDOS */ -#endif /* _CX_UX */ -#endif /* STRIDE */ #endif /* FASYNC */ #endif /* F_SETFL */ #endif /* SIGIO */ @@ -1486,10 +1386,6 @@ init_sys_modes (tty_out) #if defined (HAVE_TERMIO) || defined (HAVE_TERMIOS) XSETINT (Vtty_erase_char, tty.main.c_cc[VERASE]); -#ifdef DGUX - /* This allows meta to be sent on 8th bit. */ - tty.main.c_iflag &= ~INPCK; /* don't check input for parity */ -#endif tty.main.c_iflag |= (IGNBRK); /* Ignore break condition */ tty.main.c_iflag &= ~ICRNL; /* Disable map of CR to NL on input */ #ifdef INLCR /* I'm just being cautious, @@ -1703,11 +1599,9 @@ init_sys_modes (tty_out) #ifdef TCXONC if (!tty_out->flow_control) ioctl (fileno (tty_out->input), TCXONC, 1); #endif -#ifndef APOLLO #ifdef TIOCSTART if (!tty_out->flow_control) ioctl (fileno (tty_out->input), TIOCSTART, 0); #endif -#endif #if defined (HAVE_TERMIOS) || defined (HPUX9) #ifdef TCOON @@ -2085,14 +1979,6 @@ setup_pty (fd) } #endif #endif -#ifdef IBMRTAIX - /* On AIX, the parent gets SIGHUP when a pty attached child dies. So, we */ - /* ignore SIGHUP once we've started a child on a pty. Note that this may */ - /* cause EMACS not to die when it should, i.e., when its own controlling */ - /* tty goes away. I've complained to the AIX developers, and they may */ - /* change this behavior, but I'm not going to hold my breath. */ - signal (SIGHUP, SIG_IGN); -#endif } #endif /* HAVE_PTYS */ @@ -2377,13 +2263,8 @@ start_of_text () #ifdef TEXT_START return ((char *) TEXT_START); #else -#ifdef GOULD - extern csrt (); - return ((char *) csrt); -#else /* not GOULD */ extern int _start (); return ((char *) _start); -#endif /* GOULD */ #endif /* TEXT_START */ } #endif /* not HAVE_TEXT_START */ diff --git a/src/systty.h b/src/systty.h index 411286908a3..a7e8c41c698 100644 --- a/src/systty.h +++ b/src/systty.h @@ -26,9 +26,6 @@ Boston, MA 02110-1301, USA. */ /* Include the proper files. */ #ifdef HAVE_TERMIO -#ifdef __DGUX -#include -#endif #ifndef NO_TERMIO #include #endif /* not NO_TERMIO */ @@ -130,42 +127,18 @@ static struct sensemode { #ifdef SYSV_PTYS #include #include -#ifdef titan -#include -#include -#endif #ifndef NO_PTY_H #include #endif #endif -/* saka@pfu.fujitsu.co.JP writes: - FASYNC defined in this file. But, FASYNC don't working. - so no problem, because unrequest_sigio only need. */ -#if defined (pfa) -#include -#endif - /* Special cases - inhibiting the use of certain features. */ -#ifdef APOLLO -#undef TIOCSTART -#endif - -#ifdef XENIX -#undef TIOCGETC /* Avoid confusing some conditionals that test this. */ -#endif - #ifdef BROKEN_TIOCGETC #undef TIOCGETC /* Avoid confusing some conditionals that test this. */ #endif -/* UNIPLUS systems may have FIONREAD. */ -#ifdef UNIPLUS -#include -#endif - /* Allow m- file to inhibit use of FIONREAD. */ #ifdef BROKEN_FIONREAD #undef FIONREAD diff --git a/src/syswait.h b/src/syswait.h index 9f652a63b85..6bfab435459 100644 --- a/src/syswait.h +++ b/src/syswait.h @@ -79,7 +79,7 @@ Boston, MA 02110-1301, USA. */ #else /* not WAIT_USE_INT */ -#if (!defined (BSD_SYSTEM) && !defined (UNIPLUS) && !defined (STRIDE) && !(defined (HPUX) && !defined (NOMULTIPLEJOBS)) && !defined (HAVE_WAIT_HEADER)) +#if (!defined (BSD_SYSTEM) && !(defined (HPUX) && !defined (NOMULTIPLEJOBS)) && !defined (HAVE_WAIT_HEADER)) #define WAITTYPE int #define WIFSTOPPED(w) ((w&0377) == 0177) #define WIFSIGNALED(w) ((w&0377) != 0177 && (w&~0377) == 0) @@ -129,7 +129,7 @@ Boston, MA 02110-1301, USA. */ #ifndef WIFEXITED #define WIFEXITED(w) (WTERMSIG (w) == 0) #endif -#endif /* BSD_SYSTEM || UNIPLUS || STRIDE || HPUX */ +#endif /* BSD_SYSTEM || HPUX */ #endif /* not WAIT_USE_INT */ #endif /* no WAITTYPE */ diff --git a/src/unexec.c b/src/unexec.c index 05cff698313..b0ef8fc4d51 100644 --- a/src/unexec.c +++ b/src/unexec.c @@ -975,92 +975,9 @@ copy_text_and_data (new, a_out) lseek (new, (long) N_TXTOFF (hdr), 0); #endif /* no A_TEXT_SEEK */ -#ifdef RISCiX - - /* Acorn's RISC-iX has a wacky way of initialising the position of the heap. - * There is a little table in crt0.o that is filled at link time with - * the min and current brk positions, among other things. When start - * runs, it copies the table to where these parameters live during - * execution. This data is in text space, so it cannot be modified here - * before saving the executable, so the data is written manually. In - * addition, the table does not have a label, and the nearest accessible - * label (mcount) is not prefixed with a '_', thus making it inaccessible - * from within C programs. To overcome this, emacs's executable is passed - * through the command 'nm %s | fgrep mcount' into a pipe, and the - * resultant output is then used to find the address of 'mcount'. As far as - * is possible to determine, in RISC-iX releases prior to 1.2, the negative - * offset of the table from mcount is 0x2c, whereas from 1.2 onwards it is - * 0x30. bss_end has been rounded up to page boundary. This solution is - * based on suggestions made by Kevin Welton and Steve Hunt of Acorn, and - * avoids the need for a custom version of crt0.o for emacs which has its - * table in data space. - */ - - { - char command[1024]; - char errbuf[1024]; - char address_text[32]; - int proforma[4]; - FILE *pfile; - char *temp_ptr; - char c; - int mcount_address, mcount_offset, count; - extern char *_execname; - - - /* The use of _execname is incompatible with RISCiX 1.1 */ - sprintf (command, "nm %s | fgrep mcount", _execname); - - if ( (pfile = popen(command, "r")) == NULL) - { - sprintf (errbuf, "Could not open pipe"); - PERROR (errbuf); - } - - count=0; - while ( ((c=getc(pfile)) != EOF) && (c != ' ') && (count < 31)) - address_text[count++]=c; - address_text[count]=0; - - if ((count == 0) || pclose(pfile) != NULL) - { - sprintf (errbuf, "Failed to execute the command '%s'\n", command); - PERROR (errbuf); - } - - sscanf(address_text, "%x", &mcount_address); - ptr = (char *) unexec_text_start; - mcount_offset = (char *)mcount_address - ptr; - -#ifdef RISCiX_1_1 -#define EDATA_OFFSET 0x2c -#else -#define EDATA_OFFSET 0x30 -#endif - - end = ptr + mcount_offset - EDATA_OFFSET; - - write_segment (new, ptr, end); - - proforma[0] = bss_end; /* becomes _edata */ - proforma[1] = bss_end; /* becomes _end */ - proforma[2] = bss_end; /* becomes _minbrk */ - proforma[3] = bss_end; /* becomes _curbrk */ - - write (new, proforma, 16); - - temp_ptr = ptr; - ptr = end + 16; - end = temp_ptr + hdr.a_text; - - write_segment (new, ptr, end); - } - -#else /* !RISCiX */ ptr = (char *) unexec_text_start; end = ptr + hdr.a_text; write_segment (new, ptr, end); -#endif /* RISCiX */ ptr = (char *) unexec_data_start; end = ptr + hdr.a_data; @@ -1175,13 +1092,8 @@ adjust_lnnoptrs (writedesc, readdesc, new_name) { register int nsyms; register int new; -#if defined (amdahl_uts) || defined (pfa) - SYMENT symentry; - AUXENT auxentry; -#else struct syment symentry; union auxent auxentry; -#endif if (!lnnoptr || !f_hdr.f_symptr) return 0; diff --git a/src/xdisp.c b/src/xdisp.c index d98b5139ded..19ee4a0a92d 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -8785,8 +8785,6 @@ echo_area_display (update_frame_p) if (!FRAME_VISIBLE_P (f) || !f->glyphs_initialized_p) return 0; -/* The terminal frame is used as the first Emacs frame on the Mac OS. */ -#ifndef MAC_OS8 #ifdef HAVE_WINDOW_SYSTEM /* When Emacs starts, selected_frame may be the initial terminal frame. If we let this through, a message would be displayed on @@ -8794,7 +8792,6 @@ echo_area_display (update_frame_p) if (FRAME_INITIAL_P (XFRAME (selected_frame))) return 0; #endif /* HAVE_WINDOW_SYSTEM */ -#endif /* Redraw garbaged frames. */ if (frame_garbaged) From cb8e5d4e6e76be7266b424e0cb347442445ab14a Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 13 Jan 2008 00:46:16 +0000 Subject: [PATCH 089/439] Remove some symbols that are not used anymore. --- admin/CPP-DEFINES | 39 ++------------------------------------- 1 file changed, 2 insertions(+), 37 deletions(-) diff --git a/admin/CPP-DEFINES b/admin/CPP-DEFINES index ab485360138..daf668efd57 100644 --- a/admin/CPP-DEFINES +++ b/admin/CPP-DEFINES @@ -44,25 +44,10 @@ REL_ALLOC Compile in the relocatable memory allocator ralloc.c. SYSTEM_MALLOC Use the system library's malloc. ** All references to these symbols should be removed, all their definitions are gone ** -ALLIANT -ALLIANT_2800 -ALTOS -APOLLO -APOLLO_SR10 -RTU -STRIDE -UNIPLUS -GOULD +101:#if defined(orion) + NU -pyramid -sps7 -tahoe -tek4300 -__DGUX -DGUX romp -ibmrt -NEWSOS5 ** Temporarily put defines from removed files here, check if these macros need to be documented or removed because they are not used anymore. ** @@ -166,8 +151,6 @@ IRIS IRIS_4D IRIX6_5 IRIX_FORCE_32_BITS -ISC4_0 -ISI68K KEEP_OLD_PADDR KEEP_OLD_TEXT_SCNPTR KERNEL_FILE @@ -202,7 +185,6 @@ MKDIR_PROTOTYPE MOTIF M_TERMINFO NARROWPROTO -NBPC NEED_ERRNO NEED_NET_ERRNO_H NEED_PTEM_H @@ -247,8 +229,6 @@ PTY_TTY_NAME_SPRINTF PURESIZE READ REL_ALLOC -RISCiX -RISCiX_1_1 RUN_TIME_REMAP SECTION_ALIGNMENT SEEK @@ -266,7 +246,6 @@ SKTPAIR SMAIL START_FILES SUNOS4 -SUNOS4_SHARED_LIBRARIES SUNOS_LOCALTIME_BUG SVR4 SWITCH_ENUM_BUG @@ -290,8 +269,6 @@ TEXT_START_ADDR THIS_IS_MAKEFILE TPIX ULIMIT_BREAK_VALUE -UMAX -UMAX4_2 UNEXEC USE_DL_STUBS USE_GETOBAUD @@ -303,13 +280,11 @@ USG5_3 USG5_4 USG_JOBCTRL USG_SHARED_LIBRARIES -V3x VIRT_ADDR_VARIES WORDS_BIG_ENDIAN WORD_MACHINE WRITE X11R4 -XENIX XICCC XINT XSET @@ -325,15 +300,10 @@ _setjmp _sobuf aix386 alloca -amdahl_uts aouthdr -celerity -clipper -convex data_start drem dsize -elxsi emacs entry etext @@ -348,17 +318,12 @@ jmp_buf longjmp m68000 m68k -m88k magic mc68000 mips -orion sel subprocesses sun -sun_68881 -sun_fpa -sun_soft text_start # arch-tag: bc80061a-1168-4911-9766-46aaf2640250 From 8111ec056543164117099bd6fdecb51f39428fb4 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 13 Jan 2008 15:15:03 +0000 Subject: [PATCH 090/439] (Fcall_process): Fix previous change. --- src/ChangeLog | 4 ++++ src/callproc.c | 6 ++++++ 2 files changed, 10 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index 0ad3ba97e0f..a6caa49221b 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-13 Dan Nicolaescu + + * callproc.c: (Fcall_process): Fix previous change. + 2008-01-13 Dan Nicolaescu * (unexsunos4): Remove file, system not supported anymore. diff --git a/src/callproc.c b/src/callproc.c index 2078c4411fd..3a725b80a0a 100644 --- a/src/callproc.c +++ b/src/callproc.c @@ -471,6 +471,12 @@ usage: (call-process PROGRAM &optional INFILE BUFFER DISPLAY &rest ARGS) */) else { #ifndef MSDOS + errno = 0; + if (pipe (fd) == -1) + { + emacs_close (filefd); + report_file_error ("Creating process pipe", Qnil); + } #endif #if 0 /* Replaced by close_process_descs */ From 2a5cb2584f9ca171ad4310a464d6236e5f005b0e Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 13 Jan 2008 17:39:05 +0000 Subject: [PATCH 091/439] Remove obsolete file --- src/unexsunos4.c | 381 ----------------------------------------------- 1 file changed, 381 deletions(-) delete mode 100644 src/unexsunos4.c diff --git a/src/unexsunos4.c b/src/unexsunos4.c deleted file mode 100644 index 17f2b298e00..00000000000 --- a/src/unexsunos4.c +++ /dev/null @@ -1,381 +0,0 @@ -/* Unexec for Sunos 4 using shared libraries. - Copyright (C) 1990, 1994, 1999, 2001, 2002, 2003, 2004, - 2005, 2006, 2007, 2008 Free Software Foundation, Inc. - -This file is part of GNU Emacs. - -GNU Emacs is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 3, or (at your option) -any later version. - -GNU Emacs is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU Emacs; see the file COPYING. If not, write to -the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -Boston, MA 02110-1301, USA. */ - -/* Contributed by Viktor Dukhovni. */ -/* - * Unexec for Berkeley a.out format + SUNOS shared libraries - * The unexeced executable contains the __DYNAMIC area from the - * original text file, and then the rest of data + bss + malloced area of - * the current process. (The __DYNAMIC area is at the top of the process - * data segment, we use "data_start" defined externally to mark the start - * of the "real" data segment.) - * - * For programs that want to remap some of the data segment read only - * a run_time_remap is provided. This attempts to remap largest area starting - * and ending on page boundaries between "data_start" and "bndry" - * For this it to figure out where the text file is located. A path search - * is attempted after trying argv[0] and if all fails we simply do not remap - * - * One feature of run_time_remap () is mandatory: reseting the break. - * - * Note that we can no longer map data into the text segment, as this causes - * the __DYNAMIC struct to become read only, breaking the runtime loader. - * Thus we no longer need to mess with a private crt0.c, the standard one - * will do just fine, since environ can live in the writable area between - * __DYNAMIC and data_start, just make sure that pre-crt0.o (the name - * is somewhat abused here) is loaded first! - * - */ - -#ifdef emacs -#include -#endif - -#include -#include -#include -#include -#include -#include -#include - -#if defined (SUNOS4) || defined (__FreeBSD__) || defined (__NetBSD__) -#define UNDO_RELOCATION -#endif - -#ifdef UNDO_RELOCATION -#include -#endif - -#ifdef HAVE_UNISTD_H -#include -#endif - -/* NetBSD needs this bit, but SunOS does not have it. */ -#ifndef MAP_FILE -#define MAP_FILE 0 -#endif - - -/* - * for programs other than emacs - * define data_start + initialized here, and make sure - * this object is loaded first! - * emacs will define these elsewhere, and load the object containing - * data_start (pre-crt0.o or firstfile.o?) first! - * The custom crt0.o *must not* be loaded! - */ -#ifndef emacs - static int data_start = 0; - static int initialized = 0; -#else - extern int initialized; - extern unsigned data_start; - extern int pureptr; -#endif - -extern char *getenv (); -static unsigned brk_value; -static struct exec nhdr; -static int rd_only_len; -static long cookie; - - -unexec (new_name, a_name, bndry, bss_start, entry) - char *new_name, *a_name; - unsigned bndry, bss_start, entry; -{ - int fd, new; - char *old; - struct exec ohdr; /* Allocate on the stack, not needed in the next life */ - struct stat stat; - - if ((fd = open (a_name, O_RDONLY)) < 0) - { - fprintf (stderr, "%s: open: ", a_name); - perror (a_name); - exit (1); - } - if ((new = open (new_name, O_WRONLY | O_CREAT, 0666)) == -1) - { - fprintf (stderr, "%s: open: ", a_name); - perror (new_name); - exit (1); - } - - if ((fstat (fd, &stat) == -1)) - { - fprintf (stderr, "%s: ", a_name); - perror ("fstat"); - exit (1); - } - - old = (char *)mmap (0, stat.st_size, PROT_READ, MAP_FILE|MAP_SHARED, fd, 0); - if (old == (char *)-1) - { - fprintf (stderr, "%s: ", a_name); - perror ("mmap"); - exit (1); - } - close (fd); - - nhdr = ohdr = (*(struct exec *)old); - - - /* - * Remember a magic cookie so we know we've got the right binary - * when remapping. - */ - cookie = time (0); - - /* Save the break, it is reset to &_end (by ld.so?). */ - brk_value = (unsigned) sbrk (0); - - /* - * Round up data start to a page boundary (Lose if not a 2 power!) - */ - data_start = ((((int)&data_start) - 1) & ~(N_PAGSIZ (nhdr) - 1)) + N_PAGSIZ (nhdr); - - /* - * Round down read only pages to a multiple of the page size - */ - if (bndry) - rd_only_len = ((int)bndry & ~(N_PAGSIZ (nhdr) - 1)) - data_start; - -#ifndef emacs - /* Have to do this some time before dumping the data */ - initialized = 1; -#endif - - /* Handle new data and bss sizes and optional new entry point. - No one actually uses bss_start and entry, but tradition compels - one to support them. - Could complain if bss_start > brk_value, - but the caller is *supposed* to know what she is doing. */ - nhdr.a_data = (bss_start ? bss_start : brk_value) - N_DATADDR (nhdr); - nhdr.a_bss = bss_start ? brk_value - bss_start : 0; - if (entry) - nhdr.a_entry = entry; - - /* - * Write out the text segment with new header - * Dynamic executables are ZMAGIC with N_TXTOFF==0 and the header - * part of the text segment, but no need to rely on this. - * So write the TEXT first, then go back replace the header. - * Doing it in the other order is less general! - */ - lseek (new, N_TXTOFF (nhdr), L_SET); - write (new, old + N_TXTOFF (ohdr), N_TXTOFF (ohdr) + ohdr.a_text); - lseek (new, 0L, L_SET); - write (new, &nhdr, sizeof (nhdr)); - - /* - * Write out the head of the old data segment from the file not - * from core, this has the unresolved __DYNAMIC relocation data - * we need to reload - */ - lseek (new, N_DATOFF (nhdr), L_SET); - write (new, old + N_DATOFF (ohdr), (int)&data_start - N_DATADDR (ohdr)); - - /* - * Copy the rest of the data from core - */ - write (new, &data_start, N_BSSADDR (nhdr) - (int)&data_start); - - /* - * Copy the symbol table and line numbers - */ - lseek (new, N_TRELOFF (nhdr), L_SET); - write (new, old + N_TRELOFF (ohdr), stat.st_size - N_TRELOFF (ohdr)); - - /* Some other BSD systems use this file. - We don't know whether this change is right for them. */ -#ifdef UNDO_RELOCATION - /* Undo the relocations done at startup by ld.so. - It will do these relocations again when we start the dumped Emacs. - Doing them twice gives incorrect results. */ - { - unsigned long daddr = N_DATADDR (ohdr); - unsigned long rel, erel; -#ifdef SUNOS4 -#ifdef SUNOS4_SHARED_LIBRARIES - extern struct link_dynamic _DYNAMIC; - - /* SunOS4.x's ld_rel is relative to N_TXTADDR. */ - if (!ohdr.a_dynamic) - /* This was statically linked. */ - rel = erel = 0; - else if (_DYNAMIC.ld_version < 2) - { - rel = _DYNAMIC.ld_un.ld_1->ld_rel + N_TXTADDR (ohdr); - erel = _DYNAMIC.ld_un.ld_1->ld_hash + N_TXTADDR (ohdr); - } - else - { - rel = _DYNAMIC.ld_un.ld_2->ld_rel + N_TXTADDR (ohdr); - erel = _DYNAMIC.ld_un.ld_2->ld_hash + N_TXTADDR (ohdr); - } -#else /* not SUNOS4_SHARED_LIBRARIES */ - rel = erel = 0; -#endif /* not SUNOS4_SHARED_LIBRARIES */ -#ifdef sparc -#define REL_INFO_TYPE struct reloc_info_sparc -#else -#define REL_INFO_TYPE struct relocation_info -#endif /* sparc */ -#define REL_TARGET_ADDRESS(r) (((REL_INFO_TYPE *)(r))->r_address) -#endif /* SUNOS4 */ -#if defined (__FreeBSD__) || defined (__NetBSD__) - extern struct _dynamic _DYNAMIC; - - /* FreeBSD's LD_REL is a virtual address itself. */ - rel = LD_REL (&_DYNAMIC); - erel = rel + LD_RELSZ (&_DYNAMIC); -#define REL_INFO_TYPE struct relocation_info -#define REL_TARGET_ADDRESS(r) (((REL_INFO_TYPE *)(r))->r_address) -#endif - - for (; rel < erel; rel += sizeof (REL_INFO_TYPE)) - { - /* This is the virtual address where ld.so will do relocation. */ - unsigned long target = REL_TARGET_ADDRESS (rel); - /* This is the offset in the data segment. */ - unsigned long segoffset = target - daddr; - - /* If it is located below data_start, we have to do nothing here, - because the old data has been already written to the location. */ - if (target < (unsigned long)&data_start) - continue; - - lseek (new, N_DATOFF (nhdr) + segoffset, L_SET); - write (new, old + N_DATOFF (ohdr) + segoffset, sizeof (unsigned long)); - } - } -#endif /* UNDO_RELOCATION */ - - fchmod (new, 0755); -} - -void -run_time_remap (progname) - char *progname; -{ - char aout[MAXPATHLEN]; - register char *path, *p; - - /* Just in case */ - if (!initialized) - return; - - /* Restore the break */ - brk ((char *) brk_value); - - /* If nothing to remap: we are done! */ - if (rd_only_len == 0) - return; - - /* - * Attempt to find the executable - * First try argv[0], will almost always succeed as shells tend to give - * the full path from the hash list rather than using execvp () - */ - if (is_it (progname)) - return; - - /* - * If argv[0] is a full path and does not exist, not much sense in - * searching further - */ - if (strchr (progname, '/')) - return; - - /* - * Try to search for argv[0] on the PATH - */ - path = getenv ("PATH"); - if (path == NULL) - return; - - while (*path) - { - /* copy through ':' or end */ - for (p = aout; *p = *path; ++p, ++path) - if (*p == ':') - { - ++path; /* move past ':' */ - break; - } - *p++ = '/'; - strcpy (p, progname); - /* - * aout is a candidate full path name - */ - if (is_it (aout)) - return; - } -} - -is_it (filename) - char *filename; -{ - int fd; - long filenames_cookie; - struct exec hdr; - - /* - * Open an executable and check for a valid header! - * Can't bcmp the header with what we had, it may have been stripped! - * so we may save looking at non executables with the same name, mostly - * directories. - */ - fd = open (filename, O_RDONLY); - if (fd != -1) - { - if (read (fd, &hdr, sizeof (hdr)) == sizeof (hdr) - && !N_BADMAG (hdr) && N_DATOFF (hdr) == N_DATOFF (nhdr) - && N_TRELOFF (hdr) == N_TRELOFF (nhdr)) - { - /* compare cookies */ - lseek (fd, N_DATOFF (hdr) + (int)&cookie - N_DATADDR (hdr), L_SET); - read (fd, &filenames_cookie, sizeof (filenames_cookie)); - if (filenames_cookie == cookie) - { /* Eureka */ - - /* - * Do the mapping - * The PROT_EXEC may not be needed, but it is safer this way. - * should the shared library decide to indirect through - * addresses in the data segment not part of __DYNAMIC - */ - mmap ((char *) data_start, rd_only_len, PROT_READ | PROT_EXEC, - MAP_FILE | MAP_SHARED | MAP_FIXED, fd, - N_DATOFF (hdr) + data_start - N_DATADDR (hdr)); - close (fd); - return 1; - } - } - close (fd); - } - return 0; -} - -/* arch-tag: 30227420-2c6f-4700-a4f8-9e45e52f53b1 - (do not change this comment) */ From 19e2f1bfc7f4709a25ac16484bccb421fd94e88c Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sun, 13 Jan 2008 18:18:12 +0000 Subject: [PATCH 092/439] (rmail-convert-to-babyl-format): Remove save-excursion to avoid infinite looping. --- lisp/ChangeLog | 6 ++ lisp/mail/rmail.el | 145 +++++++++++++++++++++++---------------------- 2 files changed, 81 insertions(+), 70 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5ffcef352c3..f30ec291583 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-13 Martin Rudalics + + * mail/rmail.el (rmail-convert-to-babyl-format): Remove + save-excursion to avoid infinite looping. Reported by: dnz + . + 2008-01-12 Glenn Morris * woman.el (woman-parse-numeric-arg): Change handling of `==': diff --git a/lisp/mail/rmail.el b/lisp/mail/rmail.el index f610fb83ef0..e11e7dfe912 100644 --- a/lisp/mail/rmail.el +++ b/lisp/mail/rmail.el @@ -1934,7 +1934,7 @@ is non-nil if the user has supplied the password interactively. (save-restriction (while (not (eobp)) (setq start (point)) - (cond ((looking-at "BABYL OPTIONS:");Babyl header + (cond ((looking-at "BABYL OPTIONS:") ;Babyl header (if (search-forward "\n\^_" nil t) ;; If we find the proper terminator, delete through there. (delete-region (point-min) (point)) @@ -1953,75 +1953,80 @@ is non-nil if the user has supplied the password interactively. (save-excursion (skip-chars-forward " \t\n") (point))) - (save-excursion - (let* ((header-end - (progn - (save-excursion - (goto-char start) - (forward-line 1) - (if (looking-at "0") - (forward-line 1) - (forward-line 2)) - (save-restriction - (narrow-to-region (point) (point-max)) - (rfc822-goto-eoh) - (point))))) - (case-fold-search t) - (quoted-printable-header-field-end + ;; The following let* form was wrapped in a `save-excursion' + ;; which in one case caused infinite looping, see: + ;; http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00968.html + ;; Removing that form leaves `point' at the end of the + ;; region decoded by `rmail-decode-region' which should + ;; be correct. + (let* ((header-end + (progn (save-excursion (goto-char start) - (re-search-forward - "^content-transfer-encoding:\\(\n?[\t ]\\)*quoted-printable\\(\n?[\t ]\\)*" - header-end t))) - (base64-header-field-end - (save-excursion - (goto-char start) - ;; Don't try to decode non-text data. - (and (re-search-forward - "^content-type:\\(\n?[\t ]\\)\\(text\\|message\\)/" - header-end t) - (goto-char start) - (re-search-forward - "^content-transfer-encoding:\\(\n?[\t ]\\)*base64\\(\n?[\t ]\\)*" - header-end t))))) - (if quoted-printable-header-field-end + (forward-line 1) + (if (looking-at "0") + (forward-line 1) + (forward-line 2)) + (save-restriction + (narrow-to-region (point) (point-max)) + (rfc822-goto-eoh) + (point))))) + (case-fold-search t) + (quoted-printable-header-field-end (save-excursion - (unless - (mail-unquote-printable-region header-end (point) nil t t) - (message "Malformed MIME quoted-printable message")) - ;; Change "quoted-printable" to "8bit", - ;; to reflect the decoding we just did. - (goto-char quoted-printable-header-field-end) + (goto-char start) + (re-search-forward + "^content-transfer-encoding:\\(\n?[\t ]\\)*quoted-printable\\(\n?[\t ]\\)*" + header-end t))) + (base64-header-field-end + (save-excursion + (goto-char start) + ;; Don't try to decode non-text data. + (and (re-search-forward + "^content-type:\\(\n?[\t ]\\)\\(text\\|message\\)/" + header-end t) + (goto-char start) + (re-search-forward + "^content-transfer-encoding:\\(\n?[\t ]\\)*base64\\(\n?[\t ]\\)*" + header-end t))))) + (if quoted-printable-header-field-end + (save-excursion + (unless + (mail-unquote-printable-region header-end (point) nil t t) + (message "Malformed MIME quoted-printable message")) + ;; Change "quoted-printable" to "8bit", + ;; to reflect the decoding we just did. + (goto-char quoted-printable-header-field-end) + (delete-region (point) (search-backward ":")) + (insert ": 8bit"))) + (if base64-header-field-end + (save-excursion + (when + (condition-case nil + (progn + (base64-decode-region (1+ header-end) + (- (point) 2)) + t) + (error nil)) + ;; Change "base64" to "8bit", to reflect the + ;; decoding we just did. + (goto-char base64-header-field-end) (delete-region (point) (search-backward ":")) - (insert ": 8bit"))) - (if base64-header-field-end - (save-excursion - (when - (condition-case nil - (progn - (base64-decode-region (1+ header-end) - (- (point) 2)) - t) - (error nil)) - ;; Change "base64" to "8bit", to reflect the - ;; decoding we just did. - (goto-char base64-header-field-end) - (delete-region (point) (search-backward ":")) - (insert ": 8bit")))) - (setq last-coding-system-used nil) - (or rmail-enable-mime - (not rmail-enable-multibyte) - (let ((mime-charset - (if (and rmail-decode-mime-charset - (save-excursion - (goto-char start) - (search-forward "\n\n" nil t) - (let ((case-fold-search t)) - (re-search-backward - rmail-mime-charset-pattern - start t)))) - (intern (downcase (match-string 1)))))) - (rmail-decode-region start (point) mime-charset))))) + (insert ": 8bit")))) + (setq last-coding-system-used nil) + (or rmail-enable-mime + (not rmail-enable-multibyte) + (let ((mime-charset + (if (and rmail-decode-mime-charset + (save-excursion + (goto-char start) + (search-forward "\n\n" nil t) + (let ((case-fold-search t)) + (re-search-backward + rmail-mime-charset-pattern + start t)))) + (intern (downcase (match-string 1)))))) + (rmail-decode-region start (point) mime-charset)))) ;; Add an X-Coding-System: header if we don't have one. (save-excursion (goto-char start) @@ -2051,8 +2056,8 @@ is non-nil if the user has supplied the password interactively. (save-restriction (narrow-to-region start (1- (point))) (goto-char (point-min)) - (while (search-forward "\n\^_" nil t); single char "\^_" - (replace-match "\n^_")))); 2 chars: "^" and "_" + (while (search-forward "\n\^_" nil t) ; single char "\^_" + (replace-match "\n^_")))) ; 2 chars: "^" and "_" (setq last-coding-system-used nil) (or rmail-enable-mime (not rmail-enable-multibyte) @@ -2168,8 +2173,8 @@ is non-nil if the user has supplied the password interactively. (save-restriction (narrow-to-region start (point)) (goto-char (point-min)) - (while (search-forward "\n\^_" nil t); single char - (replace-match "\n^_")))); 2 chars: "^" and "_" + (while (search-forward "\n\^_" nil t) ; single char + (replace-match "\n^_")))) ; 2 chars: "^" and "_" ;; This is for malformed messages that don't end in newline. ;; There shouldn't be any, but some users say occasionally ;; there are some. From ce20b66472dfead20a281e8145af385780bd6d3a Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Sun, 13 Jan 2008 18:26:15 +0000 Subject: [PATCH 093/439] *** empty log message *** --- src/ChangeLog | 11 +++++------ 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index a6caa49221b..e2bbadcb62a 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,13 +1,13 @@ 2008-01-13 Dan Nicolaescu - * callproc.c: (Fcall_process): Fix previous change. + * callproc.c (Fcall_process): Fix previous change. 2008-01-13 Dan Nicolaescu - * (unexsunos4): Remove file, system not supported anymore. + * unexsunos4: Remove file, system not supported anymore. - * (src/m/mips.h): - * (src/m/intel386.h): + * src/m/mips.h: + * src/m/intel386.h: * callproc.c: * config.in: * ecrt0.c: @@ -1884,8 +1884,7 @@ 2007-08-29 Dan Nicolaescu * callproc.c (child_setup, getenv_internal): Use the - display-environment-variable and term-environment-variable frame - params. + display-environment-variable and term-environment-variable frame params. (set_initial_environment): Initialise Vprocess_environment. * config.in: Disable multi-keyboard support on a mac. From f40f5dc36e552879e565e489a4e3a5f19be7e4ea Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 13 Jan 2008 18:29:53 +0000 Subject: [PATCH 094/439] * configure.in: Remove more references to unsupported systems. * m/sequent-ptx.h: * m/sequent.h: * s/ptx.h: * s/ptx4-2.h: * s/ptx4.h: Remove files for systems no longer supported. --- ChangeLog | 4 + admin/CPP-DEFINES | 5 +- configure.in | 13 ---- src/ChangeLog | 6 ++ src/m/sequent-ptx.h | 132 --------------------------------- src/m/sequent.h | 169 ------------------------------------------ src/s/ptx.h | 174 -------------------------------------------- src/s/ptx4-2.h | 20 ----- src/s/ptx4.h | 61 ---------------- 9 files changed, 13 insertions(+), 571 deletions(-) delete mode 100644 src/m/sequent-ptx.h delete mode 100644 src/m/sequent.h delete mode 100644 src/s/ptx.h delete mode 100644 src/s/ptx4-2.h delete mode 100644 src/s/ptx4.h diff --git a/ChangeLog b/ChangeLog index 2b38e17910f..48fac99ad90 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-01-13 Dan Nicolaescu + + * configure.in: Remove more references to unsupported systems. + 2008-01-06 Romain Francoise * configure.in: Delete extra semicolons. diff --git a/admin/CPP-DEFINES b/admin/CPP-DEFINES index daf668efd57..5aee4f73c8c 100644 --- a/admin/CPP-DEFINES +++ b/admin/CPP-DEFINES @@ -44,7 +44,6 @@ REL_ALLOC Compile in the relocatable memory allocator ralloc.c. SYSTEM_MALLOC Use the system library's malloc. ** All references to these symbols should be removed, all their definitions are gone ** -101:#if defined(orion) NU romp @@ -107,6 +106,7 @@ FIRST_PTY_LETTER FREE_RETURN_TYPE FSCALE F_SETOWN_BUG +F_SETOWN_SOCK_NEG GC_MARK_STACK GC_SETJMP_WORKS GETPGRP_NO_ARG @@ -203,8 +203,10 @@ NO_PTY_H NO_REMAP NO_SIOCTL_H NO_SOCKETS_IN_FILE_SYSTEM +NO_SOCK_SIGIO NO_TERMIO NO_UNION_TYPE +NO_UNION_TYPE NSIG NSIG_MINIMUM OBJECTS_MACHINE @@ -260,7 +262,6 @@ S_IFLNK S_IFMT S_IREAD S_IWRITE -TAHOE_REGISTER_BUG TERMCAP TERMINFO TEXT_END diff --git a/configure.in b/configure.in index 5eb2eeaafe6..b06985a340a 100644 --- a/configure.in +++ b/configure.in @@ -504,19 +504,6 @@ dnl see the `changequote' comment above. machine=i386 opsys=usg5-3 ;; - ## Sequent Symmetry running ptx 4, which is a modified SVR4. - i[3456]86-sequent-ptx4* | i[3456]86-sequent-sysv4* ) - machine=sequent-ptx opsys=ptx4 - NON_GNU_CPP=/lib/cpp - ;; - - ## Sequent Symmetry running DYNIX/ptx - ## Use the old cpp rather than the newer ANSI one. - i[3456]86-sequent-ptx* ) - machine=sequent-ptx opsys=ptx - NON_GNU_CPP="/lib/cpp" - ;; - ## ncr machine running svr4.3. i[3456]86-ncr-sysv4.3 ) machine=ncr386 opsys=usg5-4-3 diff --git a/src/ChangeLog b/src/ChangeLog index e2bbadcb62a..045c8e762b3 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,11 @@ 2008-01-13 Dan Nicolaescu + * m/sequent-ptx.h: + * m/sequent.h: + * s/ptx.h: + * s/ptx4-2.h: + * s/ptx4.h: Remove files for systems no longer supported. + * callproc.c (Fcall_process): Fix previous change. 2008-01-13 Dan Nicolaescu diff --git a/src/m/sequent-ptx.h b/src/m/sequent-ptx.h deleted file mode 100644 index de998e9fa31..00000000000 --- a/src/m/sequent-ptx.h +++ /dev/null @@ -1,132 +0,0 @@ -/* machine description file for SEQUENT machines running DYNIX/ptx - Copyright (C) 1985, 1986, 2001, 2002, 2003, 2004, - 2005, 2006, 2007, 2008 Free Software Foundation, Inc. - -This file is part of GNU Emacs. - -GNU Emacs is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 3, or (at your option) -any later version. - -GNU Emacs is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU Emacs; see the file COPYING. If not, write to -the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -Boston, MA 02110-1301, USA. */ - - -/* The following line tells the configuration script what sort of - operating system this machine is likely to run. - USUAL-OPSYS="ptx" */ - -#include "intel386.h" - -/* Define how to take a char and sign-extend into an int. - On machines where char is signed, this is a no-op. */ -/* CHECK THIS */ -#define SIGN_EXTEND_CHAR(c) (c) - -/* Now define a symbol for the cpu type, if your compiler - does not define it automatically: - Ones defined so far include vax, m68000, ns16000, pyramid, - orion, tahoe, APOLLO and many others. */ - -/* BTW: ptx defines _SEQUENT_, i386 */ - -/* Use type int rather than a union, to represent Lisp_Object */ -/* This is desirable for most machines. */ - -#define NO_UNION_TYPE - -/* crt0.c should use the vax-bsd style of entry, with these dummy args. */ -/* Already defined. Assume prior definition works for PTX. */ -#if 0 -#undef CRT0_DUMMIES -#define CRT0_DUMMIES dummy1, dummy2, dummy3, -#endif - -/* Define EXPLICIT_SIGN_EXTEND if XINT must explicitly sign-extend - the 24-bit bit field into an int. In other words, if bit fields - are always unsigned. - - If you use NO_UNION_TYPE, this flag does not matter. */ - -#define EXPLICIT_SIGN_EXTEND - -/* Data type of load average, as read out of kmem. */ - -#undef LOAD_AVE_TYPE -#define LOAD_AVE_TYPE unsigned long - -/* Convert that into an integer that is 100 for a load average of 1.0 */ - -#undef FSCALE -#define FSCALE 1000.0 -#undef LOAD_AVE_CVT -#define LOAD_AVE_CVT(x) (int) (((double) (x)) * 100.0 / FSCALE) - -/* Define CANNOT_DUMP on machines where unexec does not work. - Then the function dump-emacs will not be defined - and temacs will do (load "loadup") automatically unless told otherwise. */ - -/* #define CANNOT_DUMP */ - -/* Define VIRT_ADDR_VARIES if the virtual addresses of - pure and impure space as loaded can vary, and even their - relative order cannot be relied on. - - Otherwise Emacs assumes that text space precedes data space, - numerically. */ - -/* #define VIRT_ADDR_VARIES */ - -/* Define NO_REMAP if memory segmentation makes it not work well - to change the boundary between the text section and data section - when Emacs is dumped. If you define this, the preloaded Lisp - code will not be sharable; but that's better than failing completely. */ -/* On PTX, can't seem to get a valid executable unless NO_REMAP is - defined. This did work in the Sequent patched Emacs 18.57. */ -#ifndef NO_REMAP -#define NO_REMAP -#endif -/* #undef NO_REMAP */ - -/* If a valid PTX executable could be dumped without NO_REMAP defined, - here's a guess at some defines to make it work. */ -#ifndef NO_REMAP - -/* PTX has getpagesize() but it returns 296. Using the default method of - including getpagesize.h in unexec.c returns 4096 which seems more - reasonable. */ -#undef HAVE_GETPAGESIZE - -/* Override magic number for a.out header. */ -#define EXEC_MAGIC 0411 /* from a.out.h: separated I&D */ - -#define ADJUST_TEXT_SCNHDR_SIZE -#define ADJUST_TEXTBASE - -/* The file sections in the Symmetry a.out must be on 4K boundaries. */ -/* #define DATA_SECTION_ALIGNMENT (4096-1) */ - -#endif /* ifndef NO_REMAP */ - -/* Avoids a compiler bug. */ -#define TAHOE_REGISTER_BUG - -/* (short) negative-int doesn't sign-extend correctly. */ -#define SHORT_CAST_BUG - -/* Cause compilations to be done in parallel in ymakefile. */ -#define MAKE_PARALLEL $& - -/* Use terminfo library. */ -#define LIBS_TERMCAP -ltermlib - -/* arch-tag: 0494629b-7e11-4f6f-865f-62254ac46099 - (do not change this comment) */ diff --git a/src/m/sequent.h b/src/m/sequent.h deleted file mode 100644 index 97df4da6e09..00000000000 --- a/src/m/sequent.h +++ /dev/null @@ -1,169 +0,0 @@ -/* machine description file for SEQUENT BALANCE machines - Copyright (C) 1985, 1986, 2001, 2002, 2003, 2004, - 2005, 2006, 2007, 2008 Free Software Foundation, Inc. - -This file is part of GNU Emacs. - -GNU Emacs is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 3, or (at your option) -any later version. - -GNU Emacs is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU Emacs; see the file COPYING. If not, write to -the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -Boston, MA 02110-1301, USA. */ - - -/* The following line tells the configuration script what sort of - operating system this machine is likely to run. - USUAL-OPSYS="note" - -NOTE-START -Use -opsystem=bsd4-2, or -opsystem=bsd4-3 on newer systems. -NOTE-END */ - -/* NOTE: this file works for DYNIX release 2.0 - (not tested on 1.3) on NS32000's */ - -/* Define WORDS_BIG_ENDIAN if lowest-numbered byte in a word - is the most significant byte. */ - -#undef WORDS_BIG_ENDIAN - -/* Define NO_ARG_ARRAY if you cannot take the address of the first of a - * group of arguments and treat it as an array of the arguments. */ - -/* #define NO_ARG_ARRAY */ - -/* Define WORD_MACHINE if addresses and such have - * to be corrected before they can be used as byte counts. */ - -/* #define WORD_MACHINE */ - -/* Now define a symbol for the cpu type, if your compiler - does not define it automatically: - vax, m68000, ns16000, pyramid, orion, tahoe and APOLLO - are the ones defined so far. */ - -/* BTW: DYNIX defines sequent, ns32000, and ns16000 (GENIX compatibility) */ -#ifndef sequent /* pre DYNIX 2.1 releases */ -# define sequent -#endif - -/* Use type int rather than a union, to represent Lisp_Object */ -/* This is desirable for most machines. */ - -#define NO_UNION_TYPE - -/* crt0.c should use the vax-bsd style of entry, with these dummy args. */ - -#define CRT0_DUMMIES bogus_fp, - -/* crt0.c should define a symbol `start' and do .globl with a dot. */ - -#define DOT_GLOBAL_START - -/* Define EXPLICIT_SIGN_EXTEND if XINT must explicitly sign-extend - the 24-bit bit field into an int. In other words, if bit fields - are always unsigned. - - If you use NO_UNION_TYPE, this flag does not matter. */ - -#define EXPLICIT_SIGN_EXTEND - -/* Data type of load average, as read out of kmem. */ - -#define LOAD_AVE_TYPE unsigned long - -/* Convert that into an integer that is 100 for a load average of 1.0 */ - -#define FSCALE 1000.0 -#define LOAD_AVE_CVT(x) (int) (((double) (x)) * 100.0 / FSCALE) - -/* Define CANNOT_DUMP on machines where unexec does not work. - Then the function dump-emacs will not be defined - and temacs will do (load "loadup") automatically unless told otherwise. */ - -/* #define CANNOT_DUMP */ - -/* Define VIRT_ADDR_VARIES if the virtual addresses of - pure and impure space as loaded can vary, and even their - relative order cannot be relied on. - - Otherwise Emacs assumes that text space precedes data space, - numerically. */ - -/* #define VIRT_ADDR_VARIES */ - -/* Name of file the to look in - for the kernel symbol table (for load average) */ - -#undef KERNEL_FILE -#define KERNEL_FILE "/dynix" - -/* Avoids a compiler bug */ - -#define TAHOE_REGISTER_BUG - -/* Say that the text segment of a.out includes the header; - the header actually occupies the first few bytes of the text segment - and is counted in hdr.a_text. Furthermore, the value written - in the a_text in the file must have N_ADDRADJ added to it. */ - -#define A_TEXT_OFFSET(HDR) (sizeof (HDR) + N_ADDRADJ (HDR)) - -/* This is the offset of the executable's text, from the start of the file. */ - -#define A_TEXT_SEEK(HDR) (N_TXTOFF (hdr) + sizeof (hdr)) - -/* (short) negative-int doesn't sign-extend correctly */ -#define SHORT_CAST_BUG - -/* Cause compilations to be done in parallel in ymakefile. */ -#define MAKE_PARALLEL & - -/* Say that mailer interlocking uses flock. */ -#define MAIL_USE_FLOCK - -/* On many 4.2-based systems, there's a rather tricky bug - * with the interpretation of the pid/pgrp value given to - * the F_SETOWN fcntl() call. It works as documented EXCEPT - * when applied to filedescriptors for sockets, in which case - * the sign must be reversed. If your emacs subprocesses get - * SIGIO's when they shouldn't, while running on a socket - * (e.g. under X windows), you should probably define this. - */ - -#define F_SETOWN_SOCK_NEG - -/* Some really obscure 4.2-based systems (like Sequent DYNIX) - * do not support asynchronous I/O (using SIGIO) on sockets, - * even though it works fine on tty's. If you have one of - * these systems, define the following, and then use it in - * config.h (or elsewhere) to decide when (not) to use SIGIO. - */ - -#define NO_SOCK_SIGIO - -/* Define how to search all pty names. - This is for Dynix 3.0; delete next 5 definitions for older systems. */ - -#define PTY_MAJOR "pqrstuvwPQRSTUVW" -#define PTY_MINOR "0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ" -#define PTY_ITERATION \ - register int ma, mi; \ - for (ma = 0; ma < sizeof(PTY_MAJOR) - 1; ma++) \ - for (mi = 0; mi < sizeof(PTY_MINOR) - 1; mi++) -#define PTY_NAME_SPRINTF \ - sprintf (ptyname, "/dev/pty%c%c", PTY_MAJOR[ma], PTY_MINOR[mi]); -#define PTY_TTY_NAME_SPRINTF \ - sprintf (ptyname, "/dev/tty%c%c", PTY_MAJOR[ma], PTY_MINOR[mi]); - -/* arch-tag: 81caea48-aa64-4021-9544-e969dea71ee8 - (do not change this comment) */ diff --git a/src/s/ptx.h b/src/s/ptx.h deleted file mode 100644 index 346aab187cc..00000000000 --- a/src/s/ptx.h +++ /dev/null @@ -1,174 +0,0 @@ -/* Definitions file for GNU Emacs running on Sequent DYNIX/ptx 1.x/2.x - Copyright (C) 1987, 1990, 1999, 2001, 2002, 2003, 2004, - 2005, 2006, 2007, 2008 Free Software Foundation, Inc. - -This file is part of GNU Emacs. - -GNU Emacs is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 3, or (at your option) -any later version. - -GNU Emacs is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU Emacs; see the file COPYING. If not, write to -the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -Boston, MA 02110-1301, USA. */ - -/* This file was written by Bill Burton . Parts were - adapted from m-ptx1-2.h and process.c as distributed with the Emacs 18.57 - on the Sequent Public software tape. Other parts were adapted from - usg5-4.h. */ - -/* Use the SysVr3 file for base configuration even though much is changed. */ -#include "usg5-3.h" - -/* Undo these defines because they are incorrect or need to be changed. */ -#undef LIB_X11_LIB -#undef LIBX11_SYSTEM -#undef USG_SHARED_LIBRARIES - -/* *defines* stat as a static function. If "static" - is blank, then many files will have a public definition for stat. */ -#undef static - -/* PTX supports job control. */ -#undef NOMULTIPLEJOBS - -/* PTX has System V streams. */ -#define SYSV_STREAMS - -/* Leave out -lPW since it conflicts with term.o and because we're not sure - if the alloca found there by autoconf should be trusted on PTX. */ -#define LIB_STANDARD -lc - -/* Local define. If TCP/IP is not installed, comment this out. */ -#define TCPIP_INSTALLED - -#ifdef TCPIP_INSTALLED -#define HAVE_SOCKETS -#else -#undef subprocesses -#endif - -#ifdef HAVE_X_WINDOWS - -#define LIBX11_SYSTEM -lsocket -linet -lnsl -/* This is also defined so that lib-src/profile can link. */ -#define LIBS_SYSTEM -lseq - -#else /* ! HAVE_X_WINDOWS */ - -#ifdef HAVE_SOCKETS -#define LIBS_SYSTEM -lsocket -linet -lnsl -lseq -#else -#define LIBS_SYSTEM -lseq -#endif - -#endif /* ! HAVE_X_WINDOWS */ - -/* No */ -#define NO_SIOCTL_H - -/* If we have X windows, configure should find gettimeofday in -lX11. - Since we emulate gettimeofday below, we really have it anyway. */ -#ifndef HAVE_GETTIMEOFDAY -#define HAVE_GETTIMEOFDAY -#endif - -#ifdef emacs -#include /* Support for pty's */ -#include - -/*#define BROKEN_SIGIO*/ /* BROKEN_SIGIO is already defined. PTX - has SIGIO, but it's just an alias for - SIGPOLL. */ - -/* Emulate gettimeofday() except for the time zone information which Emacs - doesn't use anyway. Get_process_stats() is in -lseq. */ -#include -#define gettimeofday(tp, tzp) get_process_stats (tp, PS_SELF, 0, 0) - -/* Define timezone since it's not in sys/time.h. Unfortunately, this causes - trouble when building with X since this struct is defined in - . */ -struct timezone -{ - int tz_minuteswest; - int tz_dsttime; -}; - -/* Unfortunately, this define is not checked in all files including - so we can't use it. */ -/* #define XOS_NEEDS_TIME_H */ - -/* In ptx/WINDOWS, this prevents problems with the timezone struct being - redefined in . It seems the necessary include files are - included via systime.h so leaving them out here is not a problem. This - may not work in X11R5 or X11R6. */ -#define __TIMEVAL__ - -#endif /* emacs */ - -/* PTX doesn't have FIONREAD at all. */ -#undef INTERRUPT_INPUT -#define BROKEN_FIONREAD - -/* We can support this */ -#define CLASH_DETECTION - -/* PTX has termios */ -#define HAVE_TERMIOS -#undef HAVE_TERMIO -#undef BROKEN_TIOCGWINSZ -#undef BROKEN_TIOCGETC - -/* It is possible to receive SIGCHLD when there are no children - waiting, because a previous waitsys cleaned up the carcass of child - without clearing the SIGCHLD pending info. So, use a non-blocking - wait3 instead, which maps to waitpid in SysVr4. */ -/* Not sure if this is used but PTX does support waitpid. */ -/*#define HAVE_WAIT_HEADER*/ -/*#define WAITTYPE int*/ -#define wait3(status, options, rusage) \ - waitpid ((pid_t) -1, (status), (options)) -/*#define WRETCODE(w) (w >> 8)*/ - -/* PTX has pty's but not like System V */ -#define HAVE_PTYS -#undef SYSV_PTYS - -/* Provide pty support which is defined into process.c:allocate_pty. - Basic ideas for handling getpseudotty were lifted from process.c in - Emacs 18.57 included on the Sequent Public Software tape. However, this - implementation bears almost no resemblance to the original and does not - require that process.c be patched. */ -#define PTY_ITERATION \ - char *mastername, *slavename; \ - while (1) - -#define PTY_OPEN \ - if (failed_count++ >= 5) break; \ - if ((fd = getpseudotty (&slavename, &mastername)) < 0) { \ - error("Out of ptys."); \ - continue; \ - } \ - strcpy (pty_name, slavename); - -/* Define these to prevent the default logic in process.c:allocate_pty - from being used. */ -#define PTY_NAME_SPRINTF -#define PTY_TTY_NAME_SPRINTF - -/* PTX doesn't seem to have memmove. */ -#define MEMMOVE_MISSING - -/* Kenneth Stailey says this is needed. */ -#define POSIX_SIGNALS - -/* arch-tag: 4f5e3abc-643b-413a-bae6-ed212d3af997 - (do not change this comment) */ diff --git a/src/s/ptx4-2.h b/src/s/ptx4-2.h deleted file mode 100644 index 3940093c28d..00000000000 --- a/src/s/ptx4-2.h +++ /dev/null @@ -1,20 +0,0 @@ -#include "ptx4.h" - -/* Gelling Kevan (gellingk.eurostar@ems.rail.co.uk) - says that PTX 4.2.3 needs this version. */ -#undef SETUP_SLAVE_PTY -#define SETUP_SLAVE_PTY \ - if (ioctl (xforkin, I_PUSH, "ptem") == -1) \ - fatal ("ioctl I_PUSH ptem", errno); \ - if (ioctl (xforkin, I_PUSH, "ldterm") == -1) \ - fatal ("ioctl I_PUSH ldterm", errno); - -/* Gelling Kevan (gellingk.eurostar@ems.rail.co.uk) - says that gmalloc.c needs _POSIX_SOURCE. - This defines _POSIX_SOURCE only for gmalloc.c. */ -#ifdef _MALLOC_INTERNAL -#define _POSIX_SOURCE -#endif - -/* arch-tag: 10a9fab3-9e84-4e9e-9535-6ff42baf9e77 - (do not change this comment) */ diff --git a/src/s/ptx4.h b/src/s/ptx4.h deleted file mode 100644 index 4e8913a0a6d..00000000000 --- a/src/s/ptx4.h +++ /dev/null @@ -1,61 +0,0 @@ -/* s/ file for Sequent "ptx 4", which is a modified SVR5.4. - -Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, - 2007, 2008 Free Software Foundation, Inc. - -This file is part of GNU Emacs. - -GNU Emacs is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 3, or (at your option) -any later version. - -GNU Emacs is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU Emacs; see the file COPYING. If not, write to -the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -Boston, MA 02110-1301, USA. */ - - -/* Tell usg5-4.h not to include filio.h. */ -#define NO_FILIO_H - -#include "usg5-4.h" - -/* Marcus Daniels says that SIGINFO is defined - on ptx4 but it is not a signal. Prevent process.c from doing the - wrong thing. */ -#define BROKEN_SIGINFO - -/* pae@dim.com (Phil Ernhardt) says this correction to - the definition in usg5-4.h is needed to prevent - all asynchronous subprocesses from exiting right away. */ - -/* James Youngman found that on "DYNIX/ptx ARNIE 4.0 - * V4.4.2 i386", the push of the ttcompat module would fail. It seems - * that PTX 4.4.2 doesn't have that module, so if the push fails we - * don't kill ourselves. While this version lacks ttcompat, it also - * has ptem, but the manual page for ptem indicates that it should - * be pushed onto the slave side before the line discipline module. - * See also the streampty manual page, if you're curious (and have - * a ptx system). - */ - -/* rms: I hope that older versions which do have ttcompat - will not get confused by the code to use ptem. */ - -#undef SETUP_SLAVE_PTY -#define SETUP_SLAVE_PTY \ - if (ioctl (xforkin, I_PUSH, "ptem") == -1 && errno != EINVAL) \ - fatal ("ioctl I_PUSH ptem", errno); \ - if (ioctl (xforkin, I_PUSH, "ldterm") == -1) \ - fatal ("ioctl I_PUSH ldterm", errno); \ - if (ioctl (xforkin, I_PUSH, "ttcompat") == -1 && errno != EINVAL) \ - fatal ("ioctl I_PUSH ttcompat", errno); - -/* arch-tag: 14621824-8dca-432b-a97a-049fc4ce0e9f - (do not change this comment) */ From c6a234ac6c8a198b2b627b72bb7d56d22b71638a Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 13 Jan 2008 20:03:35 +0000 Subject: [PATCH 095/439] * vc.el (vc-update): Resolve conflicts if necessary instead of just updating the buffer. * vc-cvs.el (vc-cvs-merge-news): Ignore the error status of the update command so that we can parse the output. --- lisp/ChangeLog | 8 ++++++++ lisp/vc-cvs.el | 2 +- lisp/vc.el | 3 +-- 3 files changed, 10 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index f30ec291583..3e9da0593db 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2008-01-13 Dan Nicolaescu + + * vc.el (vc-update): Resolve conflicts if necessary instead of + just updating the buffer. + + * vc-cvs.el (vc-cvs-merge-news): Ignore the error status of the + update command so that we can parse the output. + 2008-01-13 Martin Rudalics * mail/rmail.el (rmail-convert-to-babyl-format): Remove diff --git a/lisp/vc-cvs.el b/lisp/vc-cvs.el index d84c2839573..cc4cd47cfe7 100644 --- a/lisp/vc-cvs.el +++ b/lisp/vc-cvs.el @@ -453,7 +453,7 @@ The changes are between FIRST-REVISION and SECOND-REVISION." (message "Merging changes into %s..." file) ;; (vc-file-setprop file 'vc-working-revision nil) (vc-file-setprop file 'vc-checkout-time 0) - (vc-cvs-command nil 0 file "update") + (vc-cvs-command nil nil file "update") ;; Analyze the merge result reported by CVS, and set ;; file properties accordingly. (with-current-buffer (get-buffer "*vc*") diff --git a/lisp/vc.el b/lisp/vc.el index 88915f3715f..5006af37ec5 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -2899,8 +2899,7 @@ changes from the current branch are merged into the working file." (if (not (vc-find-backend-function (vc-backend file) 'merge-news)) (error "Sorry, merging news is not implemented for %s" (vc-backend file)) - (vc-call merge-news file) - (vc-resynch-buffer file t t)))))) + (vc-maybe-resolve-conflicts file (vc-call merge-news file))))))) (defun vc-version-backup-file (file &optional rev) "Return name of backup file for revision REV of FILE. From 052e457f1c19207015efc6c8f6b2b76ab8ffb1c9 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Sun, 13 Jan 2008 21:49:20 +0000 Subject: [PATCH 096/439] *** empty log message *** --- src/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 045c8e762b3..206c9a4e218 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -10,7 +10,7 @@ 2008-01-13 Dan Nicolaescu - * unexsunos4: Remove file, system not supported anymore. + * unexsunos4.c: Remove file, system not supported anymore. * src/m/mips.h: * src/m/intel386.h: From 944df51178e5c6617e89d28a2e6797b02550fde0 Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Sun, 13 Jan 2008 22:10:51 +0000 Subject: [PATCH 097/439] Fix typo in src/lisp.h --- src/ChangeLog | 4 ++++ src/lisp.h | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 206c9a4e218..24dcaf9d9b4 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-13 Tom Tromey + + * lisp.h: Fix typo. + 2008-01-13 Dan Nicolaescu * m/sequent-ptx.h: diff --git a/src/lisp.h b/src/lisp.h index d7ab71b5de9..5788f15852b 100644 --- a/src/lisp.h +++ b/src/lisp.h @@ -1425,7 +1425,7 @@ typedef unsigned char UCHAR; All callers should assure that at least this size of memory is allocated at the place pointed by the second argument. - Thers are 6 modifiers, each consumes 2 chars. + There are 6 modifiers, each consumes 2 chars. The octal form of a character code consumes (1 + CHARACTERBITS / 3 + 1) chars (including backslash at the head). We need one more byte for string terminator `\0'. */ From ba463d9eca5f05817eb843372ebc9e46ecbb471f Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Mon, 14 Jan 2008 07:38:05 +0000 Subject: [PATCH 098/439] * smerge-mode.el (smerge-auto): New function. * vc-svn.el (vc-svn-find-file-hook): * vc-arch.el (vc-arch-find-file-hook): * pcvs.el (cvs-revert-if-needed): * vc.el (vc-maybe-resolve-conflicts): Use it instead of vc-mode. (top-level): Add a Todo list. --- lisp/ChangeLog | 9 +++++++++ lisp/pcvs.el | 2 +- lisp/smerge-mode.el | 8 ++++++++ lisp/vc-arch.el | 2 +- lisp/vc-svn.el | 2 +- lisp/vc.el | 29 ++++++++++++++++++++++++++--- 6 files changed, 46 insertions(+), 6 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3e9da0593db..7c63ad22bef 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,12 @@ +2008-01-14 Dan Nicolaescu + + * smerge-mode.el (smerge-auto): New function. + * vc-svn.el (vc-svn-find-file-hook): + * vc-arch.el (vc-arch-find-file-hook): + * pcvs.el (cvs-revert-if-needed): + * vc.el (vc-maybe-resolve-conflicts): Use it instead of vc-mode. + (top-level): Add a Todo list. + 2008-01-13 Dan Nicolaescu * vc.el (vc-update): Resolve conflicts if necessary instead of diff --git a/lisp/pcvs.el b/lisp/pcvs.el index c4a7f67d930..401962872a2 100644 --- a/lisp/pcvs.el +++ b/lisp/pcvs.el @@ -2311,7 +2311,7 @@ this file, or a list of arguments to send to the program." ;; do want to reset the mode for VC, so we do it explicitly. (vc-find-file-hook) (when (eq (cvs-fileinfo->type fileinfo) 'CONFLICT) - (smerge-mode 1)))))))) + (smerge-auto)))))))) (defun cvs-change-cvsroot (newroot) diff --git a/lisp/smerge-mode.el b/lisp/smerge-mode.el index b72107eb6c3..fe7d06e537b 100644 --- a/lisp/smerge-mode.el +++ b/lisp/smerge-mode.el @@ -1021,6 +1021,14 @@ buffer names." (unless smerge-mode (smerge-remove-props (point-min) (point-max)))) +;;;###autoload +(defun smerge-auto () + "Turn on `smerge-mode' and move point to first conflict marker. +If no conflict maker is found, turn off `smerge-mode'." + (smerge-mode 1) + (condition-case nil + (smerge-next) + (error (smerge-auto-leave)))) (provide 'smerge-mode) diff --git a/lisp/vc-arch.el b/lisp/vc-arch.el index 284fe032a25..97c99dd8193 100644 --- a/lisp/vc-arch.el +++ b/lisp/vc-arch.el @@ -360,7 +360,7 @@ Return non-nil if FILE is unchanged." (if (not (re-search-forward "^<<<<<<< " nil t)) ;; The .rej file is obsolete. (condition-case nil (delete-file rej) (error nil)) - (smerge-mode 1) + (smerge-auto) (add-hook 'after-save-hook 'vc-arch-delete-rej-if-obsolete nil t) (message "There are unresolved conflicts in this file"))) diff --git a/lisp/vc-svn.el b/lisp/vc-svn.el index e387b57d4fe..16e10edc202 100644 --- a/lisp/vc-svn.el +++ b/lisp/vc-svn.el @@ -551,7 +551,7 @@ and that it passes `vc-svn-global-switches' to it before FLAGS." (re-search-forward "^<<<<<<< " nil t)) ;; There are conflict markers. (progn - (smerge-mode 1) + (smerge-auto) (add-hook 'after-save-hook 'vc-svn-resolve-when-done nil t)) ;; There are no conflict markers. This is problematic: maybe it means ;; the conflict has been resolved and we should immediately call "svn diff --git a/lisp/vc.el b/lisp/vc.el index 5006af37ec5..cc2627bb792 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -7,8 +7,6 @@ ;; Maintainer: Andre Spiegel ;; Keywords: tools -;; $Id$ - ;; This file is part of GNU Emacs. ;; GNU Emacs is free software; you can redistribute it and/or modify @@ -522,6 +520,31 @@ ;; to your backend and which does not map to any of the VC generic ;; concepts. +;;; Todo: + +;; - Make vc-checkin avoid reverting the buffer if has not changed +;; after the checkin. Comparing (md5 BUFFER) to (md5 FILE) should +;; be enough. +;; +;; - vc-update/vc-merge should deal with VC systems that don't +;; update/merge on a file basis, but on a whole repository basis. +;; +;; - vc-register should register multiple files at a time. The +;; `register' backend function already supports that. +;; +;; - the *VC-log* buffer needs font-locking. +;; +;; - make it easier to write logs, maybe C-x 4 a should add to the log +;; buffer if there's one instead of the ChangeLog. +;; +;; - deal with push/pull operations. +;; +;; - decide if vc-status should replace vc-dired. +;; +;; - vc-status should be made asynchronous. +;; +;; - vc-status needs a menu, mouse bindings and some color bling. + ;;; Code: (require 'vc-hooks) @@ -2222,7 +2245,7 @@ See Info node `Merging'." (defun vc-maybe-resolve-conflicts (file status &optional name-A name-B) (vc-resynch-buffer file t (not (buffer-modified-p))) (if (zerop status) (message "Merge successful") - (smerge-mode 1) + (smerge-auto) (message "File contains conflicts."))) ;;;###autoload From f6f844ab240a51db881a409c1f8449dffc71b487 Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Mon, 14 Jan 2008 13:20:31 +0000 Subject: [PATCH 099/439] (image-type): Use image-type-from-file-name (from trunk 2007-05-21 Chong Yidong ). --- lisp/ChangeLog | 5 +++++ lisp/image.el | 22 +++++++--------------- 2 files changed, 12 insertions(+), 15 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5f19204e0b5..86a9c4dc2ec 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-14 Jason Rumney + + * image.el (image-type): Use image-type-from-file-name (from trunk + 2007-05-21 Chong Yidong ). + 2008-01-12 Glenn Morris * woman.el (woman-parse-numeric-arg): Change handling of `==': diff --git a/lisp/image.el b/lisp/image.el index 2deaf0a5ebf..d111f7e82a8 100644 --- a/lisp/image.el +++ b/lisp/image.el @@ -313,22 +313,14 @@ use its file extension as image type. Optional DATA-P non-nil means FILE-OR-DATA is a string containing image data." (when (and (not data-p) (not (stringp file-or-data))) (error "Invalid image file name `%s'" file-or-data)) - (cond ((null data-p) - ;; FILE-OR-DATA is a file name. - (unless (or type - (setq type (image-type-from-file-header file-or-data))) - (let ((extension (file-name-extension file-or-data))) - (unless extension - (error "Cannot determine image type")) - (setq type (intern extension))))) - (t - ;; FILE-OR-DATA contains image data. - (unless type - (setq type (image-type-from-data file-or-data))))) (unless type - (error "Cannot determine image type")) - (unless (symbolp type) - (error "Invalid image type `%s'" type)) + (setq type (if data-p + (image-type-from-data file-or-data) + (or (image-type-from-file-header file-or-data) + (image-type-from-file-name file-or-data)))) + (or type(error "Cannot determine image type"))) + (or (memq type (and (boundp 'image-types) image-types)) + (error "Invalid image type `%s'" type)) type) From db0095e0f8b6d2ed1f624b2466ecef36721979bd Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Mon, 14 Jan 2008 15:41:34 +0000 Subject: [PATCH 100/439] (compilation-error-regexp-alist-alist): Accept "fatal error" from MSFT. Reported by Jared Finder . --- lisp/ChangeLog | 33 ++++++++++++++++++++------------- lisp/progmodes/compile.el | 3 ++- 2 files changed, 22 insertions(+), 14 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7c63ad22bef..e3da73d0175 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-14 Stefan Monnier + + * progmodes/compile.el (compilation-error-regexp-alist-alist): + Accept "fatal error" from MSFT. + Reported by Jared Finder . + 2008-01-14 Dan Nicolaescu * smerge-mode.el (smerge-auto): New function. @@ -17,9 +23,9 @@ 2008-01-13 Martin Rudalics - * mail/rmail.el (rmail-convert-to-babyl-format): Remove - save-excursion to avoid infinite looping. Reported by: dnz - . + * mail/rmail.el (rmail-convert-to-babyl-format): + Remove save-excursion to avoid infinite looping. + Reported by: dnz . 2008-01-12 Glenn Morris @@ -157,7 +163,7 @@ (vc-status-current-file): Likewise. (vc-ensure-vc-buffer): Understand vc-status mode. - * vc-hg.el (vc-hg-dir-status): Don't pass -A to "hg status". + * vc-hg.el (vc-hg-dir-status): Don't pass -A to "hg status". 2008-01-09 Glenn Morris @@ -402,8 +408,7 @@ * vc-arch.el (vc-arch-root): Only set a property if the file is managed by this backend. - * vc-hg.el (vc-hg-state): Support the new status code for - up-to-date. + * vc-hg.el (vc-hg-state): Support the new status code for up-to-date. 2008-01-04 Tassilo Horn @@ -413,8 +418,8 @@ * doc-view.el (doc-view-scroll-up-or-next-page) (doc-view-scroll-down-or-previous-page): Use image-scroll-up and - image-scroll-down instead of the non-image equivalents. Don't - rely on a signalled condition but switch pages when scrolling + image-scroll-down instead of the non-image equivalents. + Don't rely on a signalled condition but switch pages when scrolling doesn't change the vertical position anymore. (doc-view-mode-map): Remap scroll-{up,down} to image-scroll-{up,down}. @@ -432,7 +437,8 @@ * bs.el (bs--sort-by-mode, bs--get-mode-name): * imenu.el (imenu-add-to-menubar): * makesum.el (make-command-summary): - * mouse.el (mouse-major-mode-menu, mouse-popup-menubar, mouse-buffer-menu): + * mouse.el (mouse-major-mode-menu, mouse-popup-menubar) + (mouse-buffer-menu): * msb.el (msb--mode-menu-cond): * calc/calc-embed.el (calc-do-embedded): * emacs-lisp/helper.el (Helper-describe-mode): @@ -447,7 +453,8 @@ * progmodes/ada-xref.el (ada-prj-find-prj-file): * progmodes/ada-mode.el (comment-region): * calendar/todo-mode.el (todo-insert-item): - * bookmark.el (bookmark-buffer-name): Test major-mode rather than mode-name. + * bookmark.el (bookmark-buffer-name): + Test major-mode rather than mode-name. 2008-01-04 Richard Stallman @@ -523,8 +530,8 @@ 2008-01-02 Karl Fogel - Change a return type, for greater extensibility. See - http://lists.gnu.org/archive/html/emacs-devel/2007-12/msg01077.html + Change a return type, for greater extensibility. + See http://lists.gnu.org/archive/html/emacs-devel/2007-12/msg01077.html and its thread for discussion leading to this change. * emacs-cvs/lisp/bookmark.el: @@ -586,7 +593,7 @@ 2008-01-01 Eric S. Raymond - * vc-svn.el (vc-svn-parse-status): Set the 'unregisted property + * vc-svn.el (vc-svn-parse-status): Set the `unregisted' property correctly. * vc.el (vc-dired-hook): Speed tuning. Replace a vc-backend call diff --git a/lisp/progmodes/compile.el b/lisp/progmodes/compile.el index 772d35f94f0..f02a7756419 100644 --- a/lisp/progmodes/compile.el +++ b/lisp/progmodes/compile.el @@ -272,8 +272,9 @@ of[ \t]+\"?\\([a-zA-Z]?:?[^\":\n]+\\)\"?:" 3 2 nil (1)) " in \\([^()\n ]+\\)(\\([0-9]+\\))$" 1 2) (msft + ;; AFAWK, The message may be a "warning", "error", or "fatal error". "^\\([0-9]+>\\)?\\(\\(?:[a-zA-Z]:\\)?[^:(\t\n]+\\)(\\([0-9]+\\)) \ -: \\(?:error\\|warnin\\(g\\)\\) C[0-9]+:" 2 3 nil (4)) +: \\(?:warnin\\(g\\)\\|[a-z ]+\\) C[0-9]+:" 2 3 nil (4)) (oracle "^\\(?:Semantic error\\|Error\\|PCC-[0-9]+:\\).* line \\([0-9]+\\)\ From 2780711e73fbb4c98e701f5c5e5245603a012652 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Mon, 14 Jan 2008 19:16:12 +0000 Subject: [PATCH 101/439] *** empty log message *** --- lisp/ChangeLog | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 86a9c4dc2ec..28a2fab82b0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-14 acm + + * progmodes/cc-engine.el (c-guess-basic-syntax): prevent a macro + call inside a struct being recognised as a K&R argument. + 2008-01-14 Jason Rumney * image.el (image-type): Use image-type-from-file-name (from trunk From f189315dde3522f7fc76261d85e54563d10ad437 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Mon, 14 Jan 2008 19:17:31 +0000 Subject: [PATCH 102/439] (c-guess-basic-syntax): prevent a macro call inside a struct being recognised as a K&R argument. --- lisp/progmodes/cc-engine.el | 1 + 1 file changed, 1 insertion(+) diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 3f86e931d34..8596aaad4c2 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el @@ -8293,6 +8293,7 @@ comment at the start of cc-engine.el for more info." ;; CASE 5H: we could be looking at subsequent knr-argdecls ((and c-recognize-knr-p + (not containing-sexp) ; can't be knr inside braces. (not (eq char-before-ip ?})) (save-excursion (setq placeholder (cdr (c-beginning-of-decl-1 lim))) From 499520822f647b1a9560078d292242d112cdab9e Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Mon, 14 Jan 2008 19:20:20 +0000 Subject: [PATCH 103/439] Correct messed up ID info in previous patch --- lisp/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 28a2fab82b0..6985adc13c0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,4 +1,4 @@ -2008-01-14 acm +2008-01-14 Alan Mackenzie * progmodes/cc-engine.el (c-guess-basic-syntax): prevent a macro call inside a struct being recognised as a K&R argument. From f4b08f5447e484c806990c4fad45381eefeb4f60 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Mon, 14 Jan 2008 19:22:27 +0000 Subject: [PATCH 104/439] *** empty log message *** --- lisp/ChangeLog | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e3da73d0175..55679706eff 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-14 Alan Mackenzie + + * progmodes/cc-engine.el (c-guess-basic-syntax): prevent a macro + call inside a struct being recognised as a K&R argument. + 2008-01-14 Stefan Monnier * progmodes/compile.el (compilation-error-regexp-alist-alist): From 027d6bb11403cd7ee09d69003a94f88e00687df1 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Mon, 14 Jan 2008 19:23:32 +0000 Subject: [PATCH 105/439] (c-guess-basic-syntax): prevent a macro call inside a struct being recognised as a K&R argument. --- lisp/progmodes/cc-engine.el | 1 + 1 file changed, 1 insertion(+) diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 7cac158166e..9718bd0ddc9 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el @@ -8296,6 +8296,7 @@ comment at the start of cc-engine.el for more info." ;; CASE 5H: we could be looking at subsequent knr-argdecls ((and c-recognize-knr-p + (not containing-sexp) ; can't be knr inside braces. (not (eq char-before-ip ?})) (save-excursion (setq placeholder (cdr (c-beginning-of-decl-1 lim))) From b58c3770c7a6ec0488824b2e3862ec0c08979915 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Mon, 14 Jan 2008 19:35:12 +0000 Subject: [PATCH 106/439] *** empty log message *** --- lisp/net/tramp-cache.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/net/tramp-cache.el b/lisp/net/tramp-cache.el index 68c29a50982..4654c212ee3 100644 --- a/lisp/net/tramp-cache.el +++ b/lisp/net/tramp-cache.el @@ -1,6 +1,6 @@ ;;; tramp-cache.el --- file information caching for Tramp -;; Copyright (C) 2000, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +;; Copyright (C) 2000, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. ;; Author: Daniel Pittman ;; Michael Albinus From c992abdbc6e85052afa3ed7d4e6840eac1ca1ed2 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Mon, 14 Jan 2008 19:36:07 +0000 Subject: [PATCH 107/439] * net/tramp.el (tramp-local-host-p): Use `tramp-file-name-host' instead of `tramp-file-name-real-host'. --- lisp/net/tramp.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 5a65b95b0f8..3969f992a8c 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -6731,7 +6731,9 @@ necessary only. This function will be used in file name completion." (defun tramp-local-host-p (vec) "Return t if this points to the local host, nil otherwise." - (let ((host (tramp-file-name-real-host vec))) + ;; We cannot use `tramp-file-name-real-host'. A port is an + ;; indication for an ssh tunnel or alike. + (let ((host (tramp-file-name-host vec))) (and (stringp host) (string-match From c440aa2f4de31512ec4f593431d468e1ebda5a33 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Mon, 14 Jan 2008 19:42:14 +0000 Subject: [PATCH 108/439] * net/trampver.el: Update release number. --- doc/misc/tramp.texi | 2 +- lisp/ChangeLog | 7 +++++++ lisp/net/trampver.el | 7 ++++--- 3 files changed, 12 insertions(+), 4 deletions(-) diff --git a/doc/misc/tramp.texi b/doc/misc/tramp.texi index d1acafefa03..87164bfce31 100644 --- a/doc/misc/tramp.texi +++ b/doc/misc/tramp.texi @@ -39,7 +39,7 @@ @copying Copyright @copyright{} 1999, 2000, 2001, 2002, 2003, 2004, 2005, 2006, -2007 Free Software Foundation, Inc. +2007, 2008 Free Software Foundation, Inc. @quotation Permission is granted to copy, distribute and/or modify this document diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 55679706eff..fc0b5e4d634 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2008-01-14 Michael Albinus + + * net/tramp.el (tramp-local-host-p): Use `tramp-file-name-host' + instead of `tramp-file-name-real-host'. + + * net/trampver.el: Update release number. + 2008-01-14 Alan Mackenzie * progmodes/cc-engine.el (c-guess-basic-syntax): prevent a macro diff --git a/lisp/net/trampver.el b/lisp/net/trampver.el index 689987faff4..4a5525bd0fa 100644 --- a/lisp/net/trampver.el +++ b/lisp/net/trampver.el @@ -2,7 +2,8 @@ ;;; -*- mode: Emacs-Lisp; coding: utf-8; -*- ;;; lisp/trampver.el. Generated from trampver.el.in by configure. -;; Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +;; Copyright (C) 2003, 2004, 2005, 2006, 2007, +;; 2008 Free Software Foundation, Inc. ;; Author: Kai Großjohann ;; Keywords: comm, processes @@ -30,14 +31,14 @@ ;; "autoconf && ./configure" to change them. (X)Emacs version check is defined ;; in macro AC_EMACS_INFO of aclocal.m4; should be changed only there. -(defconst tramp-version "2.1.12" +(defconst tramp-version "2.1.13-pre" "This version of Tramp.") (defconst tramp-bug-report-address "tramp-devel@gnu.org" "Email address to send bug reports to.") ;; Check for (X)Emacs version. -(let ((x (if (or (< emacs-major-version 21) (and (featurep 'xemacs) (< emacs-minor-version 4))) (format "Tramp 2.1.12 is not fit for %s" (when (string-match "^.*$" (emacs-version)) (match-string 0 (emacs-version)))) "ok"))) +(let ((x (if (or (< emacs-major-version 21) (and (featurep 'xemacs) (< emacs-minor-version 4))) (format "Tramp 2.1.13-pre is not fit for %s" (when (string-match "^.*$" (emacs-version)) (match-string 0 (emacs-version)))) "ok"))) (unless (string-match "\\`ok\\'" x) (error "%s" x))) (provide 'trampver) From 6ed73f2812d526b0691573f58f60d98358c01797 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Mon, 14 Jan 2008 19:50:29 +0000 Subject: [PATCH 109/439] * trampver.texi: Update release number. --- doc/misc/ChangeLog | 4 ++++ doc/misc/trampver.texi | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index 0fd7a5dbe8c..d8c801a2054 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,7 @@ +2008-01-14 Michael Albinus + + * trampver.texi: Update release number. + 2008-01-09 Katsumi Yamaoka * gnus.texi (Article Keymap): Add diff --git a/doc/misc/trampver.texi b/doc/misc/trampver.texi index 74a1808686b..a82b5197cb5 100644 --- a/doc/misc/trampver.texi +++ b/doc/misc/trampver.texi @@ -4,7 +4,7 @@ @c In the Tramp CVS, the version number is auto-frobbed from @c configure.ac, so you should edit that file and run @c "autoconf && ./configure" to change the version number. -@set trampver 2.1.12 +@set trampver 2.1.13-pre @c Other flags from configuration @set instprefix /usr/local From 938a9a9e11e6a2f9c7a23d65783d59ba73ec4f0a Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Mon, 14 Jan 2008 20:17:52 +0000 Subject: [PATCH 110/439] (clear-abbrev-table): Can't pass a symbol to intern. --- lisp/ChangeLog | 6 +++++- lisp/abbrev.el | 4 +++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index fc0b5e4d634..203de0951e5 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-14 Stefan Monnier + + * abbrev.el (clear-abbrev-table): Can't pass a symbol to intern. + 2008-01-14 Michael Albinus * net/tramp.el (tramp-local-host-p): Use `tramp-file-name-host' @@ -7,7 +11,7 @@ 2008-01-14 Alan Mackenzie - * progmodes/cc-engine.el (c-guess-basic-syntax): prevent a macro + * progmodes/cc-engine.el (c-guess-basic-syntax): Prevent a macro call inside a struct being recognised as a K&R argument. 2008-01-14 Stefan Monnier diff --git a/lisp/abbrev.el b/lisp/abbrev.el index ff99430e027..5cdd2d0aa8f 100644 --- a/lisp/abbrev.el +++ b/lisp/abbrev.el @@ -524,7 +524,9 @@ the current abbrev table before abbrev lookup happens." (aset table i 0)) ;; Preserve the table's properties. (assert sym) - (intern sym table) + (let ((newsym (intern "" table))) + (set newsym nil) ; Make sure it won't be confused for an abbrev. + (setplist newsym (symbol-plist sym))) (abbrev-table-put table :abbrev-table-modiff (1+ (abbrev-table-get table :abbrev-table-modiff))))) From 235793595d3d2925f2817f5123cfb1ebd9f42473 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Mon, 14 Jan 2008 22:28:39 +0000 Subject: [PATCH 111/439] *** empty log message *** --- lisp/ChangeLog | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6985adc13c0..cca899e3354 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,14 @@ +2008-01-14 Alan Mackenzie + + * progmodes/cc-vars.el (c-constant-symbol): New function which + supersedes c-const-symbol. During a customize-.. call it enables + an element of (e.g.) c-hanging-braces alist to have its name + displayed, even when the default value of c-h-b etc. doesn't + include the elemnt. Replace uses of the old function by the new. + + * progmodes/cc-vars.el (c-hanging-braces-alist): Remove the + obscure non-working fragment ":value c-". + 2008-01-14 Alan Mackenzie * progmodes/cc-engine.el (c-guess-basic-syntax): prevent a macro From 43b829c1182d0165c18d18d976d6bd86618525a6 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Mon, 14 Jan 2008 22:31:07 +0000 Subject: [PATCH 112/439] * (c-constant-symbol): New function which supersedes c-const-symbol. During a customize-.. call it enables an element of (e.g.) c-hanging-braces alist to have its name displayed, even when the default value of c-h-b etc. doesn't include the elemnt. Replace uses of the old function by the new. * progmodes/cc-vars.el (c-hanging-braces-alist): Remove the obscure non-working fragment ":value c-". --- lisp/progmodes/cc-vars.el | 49 ++++++++++++++++++++++++--------------- 1 file changed, 30 insertions(+), 19 deletions(-) diff --git a/lisp/progmodes/cc-vars.el b/lisp/progmodes/cc-vars.el index af7175e4c7a..6ba2281f344 100644 --- a/lisp/progmodes/cc-vars.el +++ b/lisp/progmodes/cc-vars.el @@ -73,8 +73,27 @@ Useful as last item in a `choice' widget." :format "%t%n" :value 'other)) +;; The next defun will supersede c-const-symbol. +(defun c-constant-symbol (sym len) + "Create an uneditable symbol for customization buffers. +SYM is the name of the symbol, LEN the length of the field (in +characters) the symbol will be displayed in. LEN must be big +enough. + +This returns a (const ....) structure, suitable for embedding +within a customization type." + (or (symbolp sym) (error "c-constant-symbol: %s is not a symbol" sym)) + (let* ((name (symbol-name sym)) + (l (length name)) + (disp (concat name ":" (make-string (- len l 1) ?\ )))) + `(const + :size ,len + :format ,disp + :value ,sym))) + (define-widget 'c-const-symbol 'item - "An uneditable lisp symbol." + "An uneditable lisp symbol. This is obsolete - +use c-constant-symbol instead." :value nil :tag "Symbol" :format "%t: %v\n%d" @@ -395,9 +414,7 @@ in that case, i.e. as if \\[c-indent-command] was used instead." `(set ,@(mapcar (lambda (elt) `(cons :format "%v" - (c-const-symbol :format "%v: " - :size 20 - :value ,elt) + ,(c-constant-symbol elt 20) (choice :format "%[Choice%] %v" :value (column . nil) @@ -732,18 +749,15 @@ syntactic context for the brace line." `(set ,@(mapcar (lambda (elt) `(cons :format "%v" - (c-const-symbol :format "%v: " - :size 20 - :value ,elt) + ,(c-constant-symbol elt 24) (choice :format "%[Choice%] %v" :value (before after) (set :menu-tag "Before/after" - :format "Newline %v brace\n" - (const :format "%v, " before) - (const :format "%v" after)) + :format "Newline %v brace\n" + (const :format "%v, " before) + (const :format "%v " after)) (function :menu-tag "Function" - :format "Run function: %v" - :value c-)))) + :format "Run function: %v")))) '(defun-open defun-close class-open class-close inline-open inline-close @@ -779,11 +793,9 @@ currently not supported for this variable." `(set ,@(mapcar (lambda (elt) `(cons :format "%v" - (c-const-symbol :format "%v: " - :size 20 - :value ,elt) - (set :format "Newline %v brace\n" - (const :format "%v, " before) + ,(c-constant-symbol elt 20) + (set :format "Newline %v colon\n" + (const :format "%v, " before) (const :format "%v" after)))) '(case-label label access-label member-init-intro inher-intro))) :group 'c) @@ -1296,8 +1308,7 @@ Here is the current list of valid syntactic element symbols: (lambda (elt) `(cons :format "%v" :value ,elt - (c-const-symbol :format "%v: " - :size 25) + ,(c-constant-symbol (car elt) 25) (sexp :format "%v" :validate (lambda (widget) From 872efa5166f423b54e6c33fd2d50003087819666 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Mon, 14 Jan 2008 22:33:52 +0000 Subject: [PATCH 113/439] *** empty log message *** --- lisp/ChangeLog | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 203de0951e5..1d444bad5ed 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,14 @@ +2008-01-14 Alan Mackenzie + + * progmodes/cc-vars.el (c-constant-symbol): New function which + supersedes c-const-symbol. During a customize-.. call it enables + an element of (e.g.) c-hanging-braces alist to have its name + displayed, even when the default value of c-h-b etc. doesn't + include the elemnt. Replace uses of the old function by the new. + + * progmodes/cc-vars.el (c-hanging-braces-alist): Remove the + obscure non-working fragment ":value c-". + 2008-01-14 Stefan Monnier * abbrev.el (clear-abbrev-table): Can't pass a symbol to intern. From b4d0e5173bc7f418dad60143f85b74ffd8983a1a Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Mon, 14 Jan 2008 22:35:40 +0000 Subject: [PATCH 114/439] * progmodes/cc-vars.el (c-constant-symbol): New function which supersedes c-const-symbol. During a customize-.. call it enables an element of (e.g.) c-hanging-braces alist to have its name displayed, even when the default value of c-h-b etc. doesn't include the elemnt. Replace uses of the old function by the new. * progmodes/cc-vars.el (c-hanging-braces-alist): Remove the obscure non-working fragment ":value c-". --- lisp/progmodes/cc-vars.el | 49 ++++++++++++++++++++++++--------------- 1 file changed, 30 insertions(+), 19 deletions(-) diff --git a/lisp/progmodes/cc-vars.el b/lisp/progmodes/cc-vars.el index 25adb2be01b..5c5c4b3a001 100644 --- a/lisp/progmodes/cc-vars.el +++ b/lisp/progmodes/cc-vars.el @@ -73,8 +73,27 @@ Useful as last item in a `choice' widget." :format "%t%n" :value 'other)) +;; The next defun will supersede c-const-symbol. +(defun c-constant-symbol (sym len) + "Create an uneditable symbol for customization buffers. +SYM is the name of the symbol, LEN the length of the field (in +characters) the symbol will be displayed in. LEN must be big +enough. + +This returns a (const ....) structure, suitable for embedding +within a customization type." + (or (symbolp sym) (error "c-constant-symbol: %s is not a symbol" sym)) + (let* ((name (symbol-name sym)) + (l (length name)) + (disp (concat name ":" (make-string (- len l 1) ?\ )))) + `(const + :size ,len + :format ,disp + :value ,sym))) + (define-widget 'c-const-symbol 'item - "An uneditable lisp symbol." + "An uneditable lisp symbol. This is obsolete - +use c-constant-symbol instead." :value nil :tag "Symbol" :format "%t: %v\n%d" @@ -405,9 +424,7 @@ in that case, i.e. as if \\[c-indent-command] was used instead." `(set ,@(mapcar (lambda (elt) `(cons :format "%v" - (c-const-symbol :format "%v: " - :size 20 - :value ,elt) + ,(c-constant-symbol elt 20) (choice :format "%[Choice%] %v" :value (column . nil) @@ -743,18 +760,15 @@ syntactic context for the brace line." `(set ,@(mapcar (lambda (elt) `(cons :format "%v" - (c-const-symbol :format "%v: " - :size 20 - :value ,elt) + ,(c-constant-symbol elt 24) (choice :format "%[Choice%] %v" :value (before after) (set :menu-tag "Before/after" - :format "Newline %v brace\n" - (const :format "%v, " before) - (const :format "%v" after)) + :format "Newline %v brace\n" + (const :format "%v, " before) + (const :format "%v " after)) (function :menu-tag "Function" - :format "Run function: %v" - :value c-)))) + :format "Run function: %v")))) '(defun-open defun-close class-open class-close inline-open inline-close @@ -790,11 +804,9 @@ currently not supported for this variable." `(set ,@(mapcar (lambda (elt) `(cons :format "%v" - (c-const-symbol :format "%v: " - :size 20 - :value ,elt) - (set :format "Newline %v brace\n" - (const :format "%v, " before) + ,(c-constant-symbol elt 20) + (set :format "Newline %v colon\n" + (const :format "%v, " before) (const :format "%v" after)))) '(case-label label access-label member-init-intro inher-intro))) :group 'c) @@ -1307,8 +1319,7 @@ Here is the current list of valid syntactic element symbols: (lambda (elt) `(cons :format "%v" :value ,elt - (c-const-symbol :format "%v: " - :size 25) + ,(c-constant-symbol (car elt) 25) (sexp :format "%v" :validate (lambda (widget) From 4d3629207c25c3b4b2794fa140a4b5b7d536291c Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 15 Jan 2008 03:44:41 +0000 Subject: [PATCH 115/439] *** empty log message *** --- admin/FOR-RELEASE | 8 -------- 1 file changed, 8 deletions(-) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index 40ac2dc1c9d..577aadd8517 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -96,14 +96,8 @@ minimized. I don't know what is left to do here. ** sdl.web@gmail.com, 30 Oct: ps-lpr-switches has no effect -** Stephen.Berman@gmx.net: minibuffer and current-local-map - ** timh@insightful.com, 9 Nov: X-coding-system incompatibility, and workaround -** Get rid of old-style backquotes in cc-vars.el. -ttn has a patch: -http://lists.gnu.org/archive/html/emacs-devel/2007-10/msg02052.html - ** Fix or document the shortcoming of easymenu and :suffix. http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01857.html @@ -111,8 +105,6 @@ http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01857.html If mode-name stays non-string, add NEWS entry and doc fix. http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg02048.html -** pot@gnu.org, 17 Dec: strange From line maker rmail-reply loop - ** multi-tty does not work correctly. If the server is started from a tty frame and emacsclient creates an X11 frame, the tty frame gets confused, it thinks it is an X11 frame From 11a609d13fcbe36e89c8727be97654eb5dc0f86a Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 15 Jan 2008 03:45:18 +0000 Subject: [PATCH 116/439] *** empty log message *** --- admin/FOR-RELEASE | 9 ++++++--- 1 file changed, 6 insertions(+), 3 deletions(-) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index 451a7318882..feb509aece5 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -50,10 +50,13 @@ http://lists.gnu.org/archive/html/bug-gnu-emacs/2007-09/msg00055.html * BUGS -** eric@openbsd.org, 24 Nov: c-mode syntactic analysis regression in emacs-22.1 -http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00589.html - ** david.reitter@gmail.com, 27 dec: pos-visible-in-window-p at ellipsis +http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00945.html + +** diff mode change for missing spaces in -u format. +Installed 2008-01-08 fix does not work right. +http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01990.html +http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg01114.html * DOCUMENTATION From 858fd4a4b4cbe0ff031621097c4500f4f977cba8 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 15 Jan 2008 03:46:59 +0000 Subject: [PATCH 117/439] (diff-end-of-hunk): Revert 2008-01-08 change. --- lisp/ChangeLog | 6 +++++- lisp/diff-mode.el | 6 +----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index cca899e3354..91d3a778f24 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-15 Glenn Morris + + * diff-mode.el (diff-end-of-hunk): Revert 2008-01-08 change. + 2008-01-14 Alan Mackenzie * progmodes/cc-vars.el (c-constant-symbol): New function which @@ -8,7 +12,7 @@ * progmodes/cc-vars.el (c-hanging-braces-alist): Remove the obscure non-working fragment ":value c-". - + 2008-01-14 Alan Mackenzie * progmodes/cc-engine.el (c-guess-basic-syntax): prevent a macro diff --git a/lisp/diff-mode.el b/lisp/diff-mode.el index a088cd6ccba..4c566b344a9 100644 --- a/lisp/diff-mode.el +++ b/lisp/diff-mode.el @@ -391,13 +391,9 @@ when editing big diffs)." ;; Especially important for unified (because headers are ambiguous). (setq style (cdr (assq (char-after) '((?@ . unified) (?* . context)))))) (goto-char (match-end 0))) - ;; Some versions of diff replace all-blank context lines in unified - ;; format with empty lines. The use of \n below avoids matching such - ;; lines as headers. - ;; http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01990.html (let ((end (and (re-search-forward (case style ;; A `unified' header is ambiguous. - (unified (concat "^[^-+# \\\n]\\|" + (unified (concat "^[^-+# \\]\\|" diff-file-header-re)) (context "^[^-+#! \\]") (normal "^[^<>#\\]") From 9292328f935f06cdb014c572e9a7dd44875421a2 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 15 Jan 2008 03:54:28 +0000 Subject: [PATCH 118/439] Revert 2008-01-13 change: this is a generated file. --- lisp/ChangeLog | 6 +++++- src/ChangeLog | 4 ++++ src/config.in | 7 +++++++ 3 files changed, 16 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1d444bad5ed..2c215d57da0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-15 Glenn Morris + + * diff-mode.el (diff-end-of-hunk): Revert 2008-01-08 change. + 2008-01-14 Alan Mackenzie * progmodes/cc-vars.el (c-constant-symbol): New function which @@ -8,7 +12,7 @@ * progmodes/cc-vars.el (c-hanging-braces-alist): Remove the obscure non-working fragment ":value c-". - + 2008-01-14 Stefan Monnier * abbrev.el (clear-abbrev-table): Can't pass a symbol to intern. diff --git a/src/ChangeLog b/src/ChangeLog index 24dcaf9d9b4..001819a32a8 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-15 Glenn Morris + + * config.in: Revert 2008-01-13 change: this is a generated file. + 2008-01-13 Tom Tromey * lisp.h: Fix typo. diff --git a/src/config.in b/src/config.in index 75a2058c41a..27f89c29b90 100644 --- a/src/config.in +++ b/src/config.in @@ -837,6 +837,13 @@ Boston, MA 02110-1301, USA. */ /* Define to 1 if your declares `struct tm'. */ #undef TM_IN_SYS_TIME +/* Define to 1 for Encore UMAX. */ +#undef UMAX + +/* Define to 1 for Encore UMAX 4.3 that has instead of + . */ +#undef UMAX4_3 + /* Define to the unexec source file name. */ #undef UNEXEC_SRC From c422d9f0ffe2b176f732c545a5c3e3af32a0a4e8 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 15 Jan 2008 03:54:51 +0000 Subject: [PATCH 119/439] (diff-end-of-hunk): Revert 2008-01-08 change. --- lisp/diff-mode.el | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/lisp/diff-mode.el b/lisp/diff-mode.el index 6291453ba17..b8b6a009e2b 100644 --- a/lisp/diff-mode.el +++ b/lisp/diff-mode.el @@ -401,13 +401,9 @@ when editing big diffs)." (defun diff-end-of-hunk (&optional style) ;; Especially important for unified (because headers are ambiguous). (setq style (diff-hunk-style style)) - ;; Some versions of diff replace all-blank context lines in unified - ;; format with empty lines. The use of \n below avoids matching such - ;; lines as headers. - ;; http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01990.html (let ((end (and (re-search-forward (case style ;; A `unified' header is ambiguous. - (unified (concat "^[^-+# \\\n]\\|" + (unified (concat "^[^-+# \\]\\|" diff-file-header-re)) (context "^[^-+#! \\]") (normal "^[^<>#\\]") From 7d3169dbbdb106076475d537d0657295e603e8e0 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 15 Jan 2008 04:06:40 +0000 Subject: [PATCH 120/439] Simplify details of external icon licensing. --- etc/images/README | 80 +++++++++++++++++++----------------------- etc/images/gnus/README | 19 ++++------ etc/images/mail/README | 11 ++---- 3 files changed, 47 insertions(+), 63 deletions(-) diff --git a/etc/images/README b/etc/images/README index a1df3a0b4f8..1cdfb5b05b7 100644 --- a/etc/images/README +++ b/etc/images/README @@ -26,10 +26,9 @@ License: GNU General Public License version 3 or later (see COPYING) The following icons are from GTK+ 2.x. They are not part of Emacs, but -distributed and used by Emacs. - - Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald - License: GNU Library General Public License version 2 or later. +are distributed and used by Emacs. They are licensed under the +GNU Library General Public License version 2 or later. See the source +of the gtk+ package for more information. close.xpm copy.xpm cut.xpm help.xpm home.xpm index.xpm info.pbm info.xpm jump-to.xpm left-arrow.xpm new.xpm open.xpm paste.xpm @@ -42,49 +41,44 @@ distributed and used by Emacs. The following icons are from GNOME 2.x. They are not part of Emacs, -but distributed and used by Emacs. +but are distributed and used by Emacs. They are licensed under the +GNU General Public License version 2 or later. See the source of +the gnome-icons-theme package for more information. - Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 - Tuomas Kuosmanen, Rodney Dawes, Jakub Steiner, Alexander Larsson, - Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca - Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco - Pesenti Gritti - License: GNU General Public License version 2 or later. +Emacs images and their source in the GNOME icons stock/ directory: - Emacs images and their source in the GNOME icons stock/ directory: + attach.xpm document/stock_attach + cancel.xpm slightly modified generic/stock_stop + connect.xpm net/stock_connect + contact.xpm net/stock_contact + data-save.xpm data/stock_data-save + delete.xpm generic/stock_delete + describe.xpm generic/stock_properties + disconnect.xpm net/stock_disconnect + exit.xpm generic/stock_exit + lock-broken.xpm data/stock_lock-broken + lock-ok.xpm data/stock_lock-ok + lock.xpm data/stock_lock + redo.xpm generic/stock_redo + search-replace.xpm slightly modified generic/stock_search-and-replace + next-page.xpm navigation/stock_next-page + refresh.xpm generic/stock_refresh + separator.xpm ? + show.xpm slightly modified document/stock_new + sort-ascending.xpm slightly modified data/stock_sort-ascending + sort-column-ascending.xpm data/stock_sort-column-ascending + sort-criteria.xpm data/stock_sort-criteria + sort-descending.xpm slightly modified data/stock_sort-descending + sort-row-ascending.xpm data/stock_sort-row-ascending + zoom-in.xpm navigation/stock_zoom-in + zoom-out.xpm navigation/stock_zoom-out - attach.xpm document/stock_attach - cancel.xpm slightly modified generic/stock_stop - connect.xpm net/stock_connect - contact.xpm net/stock_contact - data-save.xpm data/stock_data-save - delete.xpm generic/stock_delete - describe.xpm generic/stock_properties - disconnect.xpm net/stock_disconnect - exit.xpm generic/stock_exit - lock-broken.xpm data/stock_lock-broken - lock-ok.xpm data/stock_lock-ok - lock.xpm data/stock_lock - redo.xpm generic/stock_redo - search-replace.xpm slightly modified generic/stock_search-and-replace - next-page.xpm navigation/stock_next-page - refresh.xpm generic/stock_refresh - separator.xpm ? - show.xpm slightly modified document/stock_new - sort-ascending.xpm slightly modified data/stock_sort-ascending - sort-column-ascending.xpm data/stock_sort-column-ascending - sort-criteria.xpm data/stock_sort-criteria - sort-descending.xpm slightly modified data/stock_sort-descending - sort-row-ascending.xpm data/stock_sort-row-ascending - zoom-in.xpm navigation/stock_zoom-in - zoom-out.xpm navigation/stock_zoom-out + next-node.xpm and prev-node.xpm are from gthumb version 2.0 (part of + GNOME 2.x) where they are called next-image-24.png and prev-image-24.png. + up-node.xpm is just next-node.xpm rotated 90 degrees. - next-node.xpm and prev-node.xpm are from gthumb version 2.0 (part of - GNOME 2.x) where they are called next-image-24.png and prev-image-24.png. - up-node.xpm is just next-node.xpm rotated 90 degrees. - - Some icons in the mail/ and gnus/ subdirectories are also taken - from this source (see their separate README files). + Some icons in the mail/ and gnus/ subdirectories are also taken + from this source (see their separate README files). The images in the low-color/ subdirectory are low-color versions of the files of the same name in this directory, and are subject to the diff --git a/etc/images/gnus/README b/etc/images/gnus/README index c92dc392558..16a52f135a7 100644 --- a/etc/images/gnus/README +++ b/etc/images/gnus/README @@ -23,16 +23,11 @@ Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 License: GNU General Public License version 3 or later (see COPYING) The following icons are from GNOME 2.x. They are not part of Emacs, -but distributed and used by Emacs. +but are distributed and used by Emacs. They are licensed under the +GNU General Public License version 2 or later. See the source of the +gnome-icons-theme package for more information. - Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 - Tuomas Kuosmanen, Rodney Dawes, Jakub Steiner, Alexander Larsson, - Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca - Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco - Pesenti Gritti - License: GNU General Public License version 2 or later - -toggle-subscription.xpm (GNOME stock/document/stock_task-recurring) -kill-group.pbm and kill-group.xpm are converted from close.xpm -rot13.pbm and rot13.xpm are converted from lock.xpm -mail-send.xpm ? + toggle-subscription.xpm (GNOME stock/document/stock_task-recurring) + kill-group.pbm and kill-group.xpm are converted from close.xpm + rot13.pbm and rot13.xpm are converted from lock.xpm + mail-send.xpm ? diff --git a/etc/images/mail/README b/etc/images/mail/README index dc9a83a27fb..962206e6ae8 100644 --- a/etc/images/mail/README +++ b/etc/images/mail/README @@ -1,14 +1,9 @@ COPYRIGHT AND LICENSE INFORMATION FOR IMAGE FILES The following icons are from GNOME 2.x. They are not part of Emacs, -but distributed and used by Emacs. - - Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 - Tuomas Kuosmanen, Rodney Dawes, Jakub Steiner, Alexander Larsson, - Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca - Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco - Pesenti Gritti - License: GNU General Public License version 2 or later +but are distributed and used by Emacs. They are licensed under the +GNU General Public License version 2 or later. See the source of the +gnome-icons-theme package for more information. Emacs images and their GNOME source (GNOME icons are from stock/net/ directory unless otherwise stated): From c8ad88298aa28a2dcef74d124937cff3e98f140b Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 15 Jan 2008 04:10:04 +0000 Subject: [PATCH 121/439] Simplify details of external icon licensing. --- etc/images/README | 84 ++++++++++++++++++++---------------------- etc/images/gnus/README | 19 ++++------ etc/images/mail/README | 11 ++---- 3 files changed, 49 insertions(+), 65 deletions(-) diff --git a/etc/images/README b/etc/images/README index ccc690d7832..b3271ae2ef5 100644 --- a/etc/images/README +++ b/etc/images/README @@ -34,11 +34,10 @@ Files: splash.pbm, splash.xpm, splash8.xpm, gnus.pbm License: GNU General Public License version 3 or later (see COPYING) -The following icons are from GTK+ 2.x. They are not part of Emacs, but -distributed and used by Emacs. - - Copyright (C) 1995-1997 Peter Mattis, Spencer Kimball and Josh MacDonald - License: GNU Library General Public License version 2 or later. +* The following icons are from GTK+ 2.x. They are not part of Emacs, but +are distributed and used by Emacs. They are licensed under the +GNU Library General Public License version 2 or later. See the source +of the gtk+ package for more information. close.xpm copy.xpm cut.xpm help.xpm home.xpm index.xpm info.pbm info.xpm jump-to.xpm left-arrow.xpm new.xpm open.xpm paste.xpm @@ -50,50 +49,45 @@ distributed and used by Emacs. diropen.xpm is file-manager.png from Gnome hicolor theme. -The following icons are from GNOME 2.x. They are not part of Emacs, -but distributed and used by Emacs. +* The following icons are from GNOME 2.x. They are not part of Emacs, +but are distributed and used by Emacs. They are licensed under the +GNU General Public License version 2 or later. See the source of +the gnome-icons-theme package for more information. - Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 - Tuomas Kuosmanen, Rodney Dawes, Jakub Steiner, Alexander Larsson, - Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca - Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco - Pesenti Gritti - License: GNU General Public License version 2 or later. +Emacs images and their source in the GNOME icons stock/ directory: - Emacs images and their source in the GNOME icons stock/ directory: + attach.xpm document/stock_attach + cancel.xpm slightly modified generic/stock_stop + connect.xpm net/stock_connect + contact.xpm net/stock_contact + data-save.xpm data/stock_data-save + delete.xpm generic/stock_delete + describe.xpm generic/stock_properties + disconnect.xpm net/stock_disconnect + exit.xpm generic/stock_exit + lock-broken.xpm data/stock_lock-broken + lock-ok.xpm data/stock_lock-ok + lock.xpm data/stock_lock + redo.xpm generic/stock_redo + search-replace.xpm slightly modified generic/stock_search-and-replace + next-page.xpm navigation/stock_next-page + refresh.xpm generic/stock_refresh + separator.xpm ? + show.xpm slightly modified document/stock_new + sort-ascending.xpm slightly modified data/stock_sort-ascending + sort-column-ascending.xpm data/stock_sort-column-ascending + sort-criteria.xpm data/stock_sort-criteria + sort-descending.xpm slightly modified data/stock_sort-descending + sort-row-ascending.xpm data/stock_sort-row-ascending + zoom-in.xpm navigation/stock_zoom-in + zoom-out.xpm navigation/stock_zoom-out - attach.xpm document/stock_attach - cancel.xpm slightly modified generic/stock_stop - connect.xpm net/stock_connect - contact.xpm net/stock_contact - data-save.xpm data/stock_data-save - delete.xpm generic/stock_delete - describe.xpm generic/stock_properties - disconnect.xpm net/stock_disconnect - exit.xpm generic/stock_exit - lock-broken.xpm data/stock_lock-broken - lock-ok.xpm data/stock_lock-ok - lock.xpm data/stock_lock - redo.xpm generic/stock_redo - search-replace.xpm slightly modified generic/stock_search-and-replace - next-page.xpm navigation/stock_next-page - refresh.xpm generic/stock_refresh - separator.xpm ? - show.xpm slightly modified document/stock_new - sort-ascending.xpm slightly modified data/stock_sort-ascending - sort-column-ascending.xpm data/stock_sort-column-ascending - sort-criteria.xpm data/stock_sort-criteria - sort-descending.xpm slightly modified data/stock_sort-descending - sort-row-ascending.xpm data/stock_sort-row-ascending - zoom-in.xpm navigation/stock_zoom-in - zoom-out.xpm navigation/stock_zoom-out + next-node.xpm and prev-node.xpm are from gthumb version 2.0 (part of + GNOME 2.x) where they are called next-image-24.png and prev-image-24.png. + up-node.xpm is just next-node.xpm rotated 90 degrees. - next-node.xpm and prev-node.xpm are from gthumb version 2.0 (part of - GNOME 2.x) where they are called next-image-24.png and prev-image-24.png. - up-node.xpm is just next-node.xpm rotated 90 degrees. - - Some icons in the mail/ and gnus/ subdirectories are also taken - from this source (see their separate README files). + Some icons in the mail/ and gnus/ subdirectories are also taken + from this source (see their separate README files). The images in the low-color/ subdirectory are low-color versions of the files of the same name in this directory, and are subject to the diff --git a/etc/images/gnus/README b/etc/images/gnus/README index c92dc392558..16a52f135a7 100644 --- a/etc/images/gnus/README +++ b/etc/images/gnus/README @@ -23,16 +23,11 @@ Copyright (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 License: GNU General Public License version 3 or later (see COPYING) The following icons are from GNOME 2.x. They are not part of Emacs, -but distributed and used by Emacs. +but are distributed and used by Emacs. They are licensed under the +GNU General Public License version 2 or later. See the source of the +gnome-icons-theme package for more information. - Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 - Tuomas Kuosmanen, Rodney Dawes, Jakub Steiner, Alexander Larsson, - Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca - Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco - Pesenti Gritti - License: GNU General Public License version 2 or later - -toggle-subscription.xpm (GNOME stock/document/stock_task-recurring) -kill-group.pbm and kill-group.xpm are converted from close.xpm -rot13.pbm and rot13.xpm are converted from lock.xpm -mail-send.xpm ? + toggle-subscription.xpm (GNOME stock/document/stock_task-recurring) + kill-group.pbm and kill-group.xpm are converted from close.xpm + rot13.pbm and rot13.xpm are converted from lock.xpm + mail-send.xpm ? diff --git a/etc/images/mail/README b/etc/images/mail/README index dc9a83a27fb..83183343fc1 100644 --- a/etc/images/mail/README +++ b/etc/images/mail/README @@ -1,14 +1,9 @@ COPYRIGHT AND LICENSE INFORMATION FOR IMAGE FILES The following icons are from GNOME 2.x. They are not part of Emacs, -but distributed and used by Emacs. - - Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007 - Tuomas Kuosmanen, Rodney Dawes, Jakub Steiner, Alexander Larsson, - Tor Lillqvist, Garrett LeSage, Dennis Cranston, Jody Goldberg, Luca - Ferretti, Mark Finlay, Lapo Calamandrei, Andreas Nilsson and Marco - Pesenti Gritti - License: GNU General Public License version 2 or later +but distributed and used by Emacs. They are licensed under the +GNU General Public License version 2 or later. See the source of the +gnome-icons-theme package for more information. Emacs images and their GNOME source (GNOME icons are from stock/net/ directory unless otherwise stated): From 54648b5c23a37346e89c99e622bc81e7a5f30d3f Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Tue, 15 Jan 2008 04:37:20 +0000 Subject: [PATCH 122/439] * vc-arch.el (vc-arch-delete-rej-if-obsolete): Remove the after-save-hook so that it is not called multiple times. * vc-svn.el (vc-svn-resolve-when-done): Likewise. --- lisp/ChangeLog | 7 +++++++ lisp/vc-arch.el | 8 +++++--- lisp/vc-svn.el | 6 ++++-- 3 files changed, 16 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 91d3a778f24..0ec33846981 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2008-01-15 Dan Nicolaescu + + * vc-arch.el (vc-arch-delete-rej-if-obsolete): Remove the + after-save-hook so that it is not called multiple times. + + * vc-svn.el (vc-svn-resolve-when-done): Likewise. + 2008-01-15 Glenn Morris * diff-mode.el (diff-end-of-hunk): Revert 2008-01-08 change. diff --git a/lisp/vc-arch.el b/lisp/vc-arch.el index 137dcf9e20f..c027d981b3a 100644 --- a/lisp/vc-arch.el +++ b/lisp/vc-arch.el @@ -341,9 +341,11 @@ Return non-nil if FILE is unchanged." (save-excursion (let ((rej (concat buffer-file-name ".rej"))) (when (and buffer-file-name (vc-arch-diff3-rej-p rej)) - (if (not (re-search-forward "^<<<<<<< " nil t)) - ;; The .rej file is obsolete. - (condition-case nil (delete-file rej) (error nil))))))) + (unless (re-search-forward "^<<<<<<< " nil t) + ;; The .rej file is obsolete. + (condition-case nil (delete-file rej) (error nil)) + ;; Remove the hook so that it is not called multiple times. + (remove-hook 'after-save-hook 'vc-arch-delete-rej-if-obsolete t)))))) (defun vc-arch-find-file-hook () (let ((rej (concat buffer-file-name ".rej"))) diff --git a/lisp/vc-svn.el b/lisp/vc-svn.el index 3e67a89afc7..0b0dd1ed74c 100644 --- a/lisp/vc-svn.el +++ b/lisp/vc-svn.el @@ -497,8 +497,10 @@ and that it passes `vc-svn-global-switches' to it before FLAGS." "Call \"svn resolved\" if the conflict markers have been removed." (save-excursion (goto-char (point-min)) - (if (not (re-search-forward "^<<<<<<< " nil t)) - (vc-svn-command nil 0 buffer-file-name "resolved")))) + (unless (re-search-forward "^<<<<<<< " nil t) + (vc-svn-command nil 0 buffer-file-name "resolved") + ;; Remove the hook so that it is not called multiple times. + (remove-hook 'after-save-hook 'vc-svn-resolve-when-done t)))) ;; Inspired by vc-arch-find-file-hook. (defun vc-svn-find-file-hook () From 2507310c84e569a0dcb981d497b8a067dfaffccd Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Tue, 15 Jan 2008 15:03:36 +0000 Subject: [PATCH 123/439] (log-edit): Doc fix. --- lisp/ChangeLog | 4 ++++ lisp/log-edit.el | 22 +++++++++++----------- 2 files changed, 15 insertions(+), 11 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2c215d57da0..a8c91301933 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-15 Thien-Thi Nguyen + + * log-edit.el (log-edit): Doc fix. + 2008-01-15 Glenn Morris * diff-mode.el (diff-end-of-hunk): Revert 2008-01-08 change. diff --git a/lisp/log-edit.el b/lisp/log-edit.el index b92de701b03..5447cda9f1c 100644 --- a/lisp/log-edit.el +++ b/lisp/log-edit.el @@ -309,20 +309,20 @@ automatically." "Setup a buffer to enter a log message. \\The buffer will be put in `log-edit-mode'. If SETUP is non-nil, the buffer is then erased and `log-edit-hook' is run. -Mark and point will be set around the entire contents of the -buffer so that it is easy to kill the contents of the buffer with \\[kill-region]. +Mark and point will be set around the entire contents of the buffer so +that it is easy to kill the contents of the buffer with \\[kill-region]. Once you're done editing the message, pressing \\[log-edit-done] will call `log-edit-done' which will end up calling CALLBACK to do the actual commit. -PARAMS if non-nil is an alist. The keys for the alist can be: -`log-edit-listfun' and `log-edit-diff-function'. The associated -value for `log-edit-listfun' should be a function with not -arguments that returns the list of files that are concerned by -the current operation (using relative names). The associated -value for `log-edit-diff-function' should be a function with no -arguments that displays a diff of the files concerned by the current operation. + +PARAMS if non-nil is an alist. Possible keys and associated values: + `log-edit-listfun' -- function taking no arguments that returns the list of + files that are concerned by the current operation (using relative names); + `log-edit-diff-function' -- function taking no arguments that + displays a diff of the files concerned by the current operation. + If BUFFER is non-nil `log-edit' will jump to that buffer, use it to edit the - log message and go back to the current buffer when done. Otherwise, it - uses the current buffer." +log message and go back to the current buffer when done. Otherwise, it +uses the current buffer." (let ((parent (current-buffer))) (if buffer (pop-to-buffer buffer)) (when (and log-edit-setup-invert (not (eq setup 'force))) From 30e68410fec9e2d3f0d06c6b9e60a77b7feb4c2a Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Tue, 15 Jan 2008 21:40:09 +0000 Subject: [PATCH 124/439] (smerge-refine): Also work on "same change conflicts". (smerge-makeup-conflict): New command. --- lisp/ChangeLog | 5 +++++ lisp/smerge-mode.el | 36 ++++++++++++++++++++++++++++++++---- 2 files changed, 37 insertions(+), 4 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index a8c91301933..efd472826c1 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-15 Stefan Monnier + + * smerge-mode.el (smerge-refine): Also work on "same change conflicts". + (smerge-makeup-conflict): New command. + 2008-01-15 Thien-Thi Nguyen * log-edit.el (log-edit): Doc fix. diff --git a/lisp/smerge-mode.el b/lisp/smerge-mode.el index fe7d06e537b..e7352c4479e 100644 --- a/lisp/smerge-mode.el +++ b/lisp/smerge-mode.el @@ -851,10 +851,12 @@ replace chars to try and eliminate some spurious differences." (remove-overlays (match-beginning 0) (match-end 0) 'smerge 'refine) (smerge-ensure-match 1) (smerge-ensure-match 3) - (smerge-refine-subst (match-beginning 1) (match-end 1) - (match-beginning 3) (match-end 3) - '((smerge . refine) - (face . smerge-refined-change)))) + ;; Match 1 and 3 may be one and the same in case of trivial diff3 -A conflict. + (let ((n1 (if (eq (match-end 1) (match-end 3)) 2 1))) + (smerge-refine-subst (match-beginning n1) (match-end n1) + (match-beginning 3) (match-end 3) + '((smerge . refine) + (face . smerge-refined-change))))) (defun smerge-diff (n1 n2) (smerge-match-conflict) @@ -992,6 +994,32 @@ buffer names." (message "Conflict resolution finished; you may save the buffer"))))) (message "Please resolve conflicts now; exit ediff when done"))) +(defun smerge-makeup-conflict (pt1 pt2 pt3 &optional pt4) + "Insert diff3 markers to make a new conflict. +Uses point and mark for 2 of the relevant positions and previous marks +for the other ones. +By default, makes up a 2-way conflict, +with a \\[universal-argument] prefix, makes up a 3-way conflict." + (interactive + (list (point) + (mark) + (progn (pop-mark) (mark)) + (when current-prefix-arg (pop-mark) (mark)))) + ;; Start from the end so as to avoid problems with pos-changes. + (destructuring-bind (pt1 pt2 pt3 &optional pt4) + (sort (list* pt1 pt2 pt3 (if pt4 (list pt4))) '>=) + (goto-char pt1) (beginning-of-line) + (insert ">>>>>>> OTHER\n") + (goto-char pt2) (beginning-of-line) + (insert "=======\n") + (goto-char pt3) (beginning-of-line) + (when pt4 + (insert "||||||| BASE\n") + (goto-char pt4) (beginning-of-line)) + (insert "<<<<<<< MINE\n")) + (if smerge-mode nil (smerge-mode 1)) + (smerge-refine)) + (defconst smerge-parsep-re (concat smerge-begin-re "\\|" smerge-end-re "\\|" From 5dbb074d607340282798b3eea482fa7c9bff6658 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Tue, 15 Jan 2008 22:33:05 +0000 Subject: [PATCH 125/439] (easy-menu-avoid-duplicate-keys): New var. (easy-menu-create-menu, easy-menu-convert-item-1): Use it to avoid using the same key for different menu entries. --- lisp/ChangeLog | 4 +++ lisp/emacs-lisp/easymenu.el | 65 ++++++++++++++++++++++++------------- 2 files changed, 47 insertions(+), 22 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index efd472826c1..396aa0fd92f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,9 @@ 2008-01-15 Stefan Monnier + * emacs-lisp/easymenu.el (easy-menu-avoid-duplicate-keys): New var. + (easy-menu-create-menu, easy-menu-convert-item-1): Use it to avoid + using the same key for different menu entries. + * smerge-mode.el (smerge-refine): Also work on "same change conflicts". (smerge-makeup-conflict): New command. diff --git a/lisp/emacs-lisp/easymenu.el b/lisp/emacs-lisp/easymenu.el index fa19ecd9c0f..ca5151fa984 100644 --- a/lisp/emacs-lisp/easymenu.el +++ b/lisp/emacs-lisp/easymenu.el @@ -216,12 +216,18 @@ If NAME is provided, it is used for the keymap." (setq menu (cdr (easy-menu-convert-item menu))))) menu) +(defvar easy-menu-avoid-duplicate-keys t + "Dynamically scoped var to register already used keys in a menu. +If it holds a list, this is expected to be a list of keys already seen in the +menu we're processing. Else it means we're not processing a menu.") + ;;;###autoload (defun easy-menu-create-menu (menu-name menu-items) "Create a menu called MENU-NAME with items described in MENU-ITEMS. MENU-NAME is a string, the name of the menu. MENU-ITEMS is a list of items possibly preceded by keyword pairs as described in `easy-menu-define'." (let ((menu (make-sparse-keymap menu-name)) + (easy-menu-avoid-duplicate-keys nil) prop keyword arg label enable filter visible help) ;; Look for keywords. (while (and menu-items @@ -341,22 +347,22 @@ ITEM defines an item as in `easy-menu-define'." (setq prop (cons :button (cons (cons (cdr style) selected) prop))))) (when (stringp keys) - (if (string-match "^[^\\]*\\(\\\\\\[\\([^]]+\\)]\\)[^\\]*$" - keys) - (let ((prefix - (if (< (match-beginning 0) (match-beginning 1)) - (substring keys 0 (match-beginning 1)))) - (postfix - (if (< (match-end 1) (match-end 0)) - (substring keys (match-end 1)))) - (cmd (intern (match-string 2 keys)))) - (setq keys (and (or prefix postfix) - (cons prefix postfix))) - (setq keys - (and (or keys (not (eq command cmd))) - (cons cmd keys)))) - (setq cache-specified nil)) - (if keys (setq prop (cons :keys (cons keys prop))))) + (if (string-match "^[^\\]*\\(\\\\\\[\\([^]]+\\)]\\)[^\\]*$" + keys) + (let ((prefix + (if (< (match-beginning 0) (match-beginning 1)) + (substring keys 0 (match-beginning 1)))) + (postfix + (if (< (match-end 1) (match-end 0)) + (substring keys (match-end 1)))) + (cmd (intern (match-string 2 keys)))) + (setq keys (and (or prefix postfix) + (cons prefix postfix))) + (setq keys + (and (or keys (not (eq command cmd))) + (cons cmd keys)))) + (setq cache-specified nil)) + (if keys (setq prop (cons :keys (cons keys prop))))) (if (and visible (not (easy-menu-always-true-p visible))) (if (equal visible ''nil) ;; Invisible menu item. Don't insert into keymap. @@ -371,12 +377,27 @@ ITEM defines an item as in `easy-menu-define'." ;; `intern' the name so as to merge multiple entries with the same name. ;; It also makes it easier/possible to lookup/change menu bindings ;; via keymap functions. - (cons (easy-menu-intern name) - (and (not remove) - (cons 'menu-item - (cons label - (and name - (cons command prop)))))))) + (let ((key (easy-menu-intern name))) + (when (listp easy-menu-avoid-duplicate-keys) + ;; Merging multiple entries with the same name is sometimes what we + ;; want, but not when the entries are actually different (e.g. same + ;; name but different :suffix as seen in cal-menu.el) and appear in + ;; the same menu. So we try to detect and resolve conflicts. + (while (and (stringp name) + (memq key easy-menu-avoid-duplicate-keys)) + ;; We need to use some distinct object, ideally a symbol, ideally + ;; related to the `name'. Uninterned symbols do not work (they + ;; are apparently turned into strings and re-interned later on). + (setq key (intern (format "%s (%d)" (symbol-name key) + (length easy-menu-avoid-duplicate-keys))))) + (push key easy-menu-avoid-duplicate-keys)) + + (cons key + (and (not remove) + (cons 'menu-item + (cons label + (and name + (cons command prop))))))))) (defun easy-menu-define-key (menu key item &optional before) "Add binding in MENU for KEY => ITEM. Similar to `define-key-after'. From 29ca115fea302fc9dd6947faaf66ad8a9a2f8634 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Tue, 15 Jan 2008 22:36:18 +0000 Subject: [PATCH 126/439] (cal-menu-holidays-menu): Comment update. --- lisp/calendar/cal-menu.el | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lisp/calendar/cal-menu.el b/lisp/calendar/cal-menu.el index 2846c283c15..38c14c80b14 100644 --- a/lisp/calendar/cal-menu.el +++ b/lisp/calendar/cal-menu.el @@ -141,7 +141,10 @@ "--" ,@(let ((l ())) ;; Show 11 years--5 before, 5 after year of middle month. + ;; We used to use :suffix rather than :label and bumped into + ;; an easymenu bug: ;; http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01813.html + ;; The bug has since been fixed. (dotimes (i 11) (push (vector (format "hol-year-%d" i) `(lambda () From 0d5998d1afedf49b70aeba1b5d9cad67860ce489 Mon Sep 17 00:00:00 2001 From: "Kim F. Storm" Date: Tue, 15 Jan 2008 23:29:43 +0000 Subject: [PATCH 127/439] Fixed typo. --- etc/MACHINES | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etc/MACHINES b/etc/MACHINES index b959531c69c..0e55fa76ead 100644 --- a/etc/MACHINES +++ b/etc/MACHINES @@ -1013,7 +1013,7 @@ Support for the following obsolete platforms was removed in Emacs 23.1 SCO 3.2v5 (s/sco5.h) Sun's 386-based RoadRunner (m/sun386.h) Sun3 machines (m/sun3*) - Integrated Solutions 386 machine (m/is386.h) + Integrated Solutions 386 machine (m/is386.h) Local variables: From 5bc93211c90be460778aeed6ce8c97f34855fd41 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 15 Jan 2008 23:55:28 +0000 Subject: [PATCH 128/439] *** empty log message *** --- lisp/ChangeLog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 396aa0fd92f..1f3f2a50d4f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-16 acm + + * progmodes/cc-vars.el (c-constant-symbol): Put this defun inside + an eval-and-compile, so as to permit byte-compiling (e.g. in + bootstrap). + 2008-01-15 Stefan Monnier * emacs-lisp/easymenu.el (easy-menu-avoid-duplicate-keys): New var. From 3a3995f843cf0afedb780b8e1c74712b14b80000 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 15 Jan 2008 23:56:38 +0000 Subject: [PATCH 129/439] (c-constant-symbol): Put this defun inside an eval-and-compile, so as to permit byte-compiling (e.g. in bootstrap). --- lisp/progmodes/cc-vars.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/progmodes/cc-vars.el b/lisp/progmodes/cc-vars.el index 5c5c4b3a001..8ee89170f19 100644 --- a/lisp/progmodes/cc-vars.el +++ b/lisp/progmodes/cc-vars.el @@ -74,7 +74,8 @@ Useful as last item in a `choice' widget." :value 'other)) ;; The next defun will supersede c-const-symbol. -(defun c-constant-symbol (sym len) +(eval-and-compile + (defun c-constant-symbol (sym len) "Create an uneditable symbol for customization buffers. SYM is the name of the symbol, LEN the length of the field (in characters) the symbol will be displayed in. LEN must be big @@ -89,7 +90,7 @@ within a customization type." `(const :size ,len :format ,disp - :value ,sym))) + :value ,sym)))) (define-widget 'c-const-symbol 'item "An uneditable lisp symbol. This is obsolete - From 2c2935f7f7a7139ecb32c34b3bc55dd483581c49 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 04:10:09 +0000 Subject: [PATCH 130/439] (maybe_bootstrap): Remove texinfo message, since configure checks for this. --- ChangeLog | 5 +++++ Makefile.in | 1 - admin/FOR-RELEASE | 3 --- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 48fac99ad90..7e049f376d1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-01-16 Glenn Morris + + * Makefile.in (maybe_bootstrap): Remove texinfo message, since + configure checks for this. + 2008-01-13 Dan Nicolaescu * configure.in: Remove more references to unsupported systems. diff --git a/Makefile.in b/Makefile.in index 5f804542d4e..fb4061b50ff 100644 --- a/Makefile.in +++ b/Makefile.in @@ -802,7 +802,6 @@ maybe_bootstrap: if [ \( "$$bar" = '$(srcdir)/lisp/*.elc' \) -o \( "$$bar" = '' \) ]; then \ echo "Your tree does not include the compiled Lisp files."; \ echo "You need to do \`make bootstrap' to build Emacs."; \ - echo "Emacs now requires Texinfo version 4.2."; \ exit 1;\ fi diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index 577aadd8517..25d0483e09a 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -98,9 +98,6 @@ minimized. I don't know what is left to do here. ** timh@insightful.com, 9 Nov: X-coding-system incompatibility, and workaround -** Fix or document the shortcoming of easymenu and :suffix. -http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01857.html - ** Fix problem with mode-name in SGML mode. If mode-name stays non-string, add NEWS entry and doc fix. http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg02048.html From 1e3f16b7a31f9a7cd17fcfa5c74cf1998cf6654a Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 04:10:45 +0000 Subject: [PATCH 131/439] Regenerate. --- lisp/ldefs-boot.el | 2442 +++++++++++++++++++++++++++----------------- 1 file changed, 1492 insertions(+), 950 deletions(-) diff --git a/lisp/ldefs-boot.el b/lisp/ldefs-boot.el index 8704a6d8ccb..4397568b2d7 100644 --- a/lisp/ldefs-boot.el +++ b/lisp/ldefs-boot.el @@ -4,7 +4,7 @@ ;;;### (autoloads (5x5-crack 5x5-crack-xor-mutate 5x5-crack-mutating-best ;;;;;; 5x5-crack-mutating-current 5x5-crack-randomly 5x5) "5x5" -;;;;;; "play/5x5.el" (18088 55113)) +;;;;;; "play/5x5.el" (18307 57870)) ;;; Generated autoloads from play/5x5.el (autoload '5x5 "5x5" "\ @@ -63,14 +63,14 @@ should return a grid vector array that is the new solution. ;;;*** -;;;### (autoloads nil "abbrev" "abbrev.el" (18212 46004)) +;;;### (autoloads nil "abbrev" "abbrev.el" (18316 2342)) ;;; Generated autoloads from abbrev.el (put 'abbrev-mode 'safe-local-variable 'booleanp) ;;;*** ;;;### (autoloads (list-one-abbrev-table) "abbrevlist" "abbrevlist.el" -;;;;;; (18088 55079)) +;;;;;; (18307 57851)) ;;; Generated autoloads from abbrevlist.el (autoload 'list-one-abbrev-table "abbrevlist" "\ @@ -81,7 +81,7 @@ Display alphabetical listing of ABBREV-TABLE in buffer OUTPUT-BUFFER. ;;;*** ;;;### (autoloads (ada-mode ada-add-extensions) "ada-mode" "progmodes/ada-mode.el" -;;;;;; (18173 8195)) +;;;;;; (18310 28917)) ;;; Generated autoloads from progmodes/ada-mode.el (autoload 'ada-add-extensions "ada-mode" "\ @@ -142,7 +142,7 @@ If you use ada-xref.el: ;;;*** ;;;### (autoloads (ada-header) "ada-stmt" "progmodes/ada-stmt.el" -;;;;;; (18088 55114)) +;;;;;; (18307 57870)) ;;; Generated autoloads from progmodes/ada-stmt.el (autoload 'ada-header "ada-stmt" "\ @@ -153,7 +153,7 @@ Insert a descriptive header at the top of the file. ;;;*** ;;;### (autoloads (ada-find-file) "ada-xref" "progmodes/ada-xref.el" -;;;;;; (18201 33327)) +;;;;;; (18302 4831)) ;;; Generated autoloads from progmodes/ada-xref.el (autoload 'ada-find-file "ada-xref" "\ @@ -167,8 +167,8 @@ Completion is available. ;;;### (autoloads (change-log-merge add-log-current-defun change-log-mode ;;;;;; add-change-log-entry-other-window add-change-log-entry find-change-log ;;;;;; prompt-for-change-log-name add-log-mailing-address add-log-full-name -;;;;;; add-log-current-defun-function) "add-log" "add-log.el" (18210 -;;;;;; 13714)) +;;;;;; add-log-current-defun-function) "add-log" "add-log.el" (18307 +;;;;;; 57852)) ;;; Generated autoloads from add-log.el (defvar add-log-current-defun-function nil "\ @@ -249,7 +249,6 @@ This is just like `add-change-log-entry' except that it displays the change log file in another window. \(fn &optional WHOAMI FILE-NAME)" t nil) - (define-key ctl-x-4-map "a" 'add-change-log-entry-other-window) (autoload 'change-log-mode "add-log" "\ Major mode for editing change logs; like Indented Text Mode. @@ -301,7 +300,7 @@ old-style time formats for entries are supported. ;;;### (autoloads (defadvice ad-activate ad-add-advice ad-disable-advice ;;;;;; ad-enable-advice ad-default-compilation-action ad-redefinition-action) -;;;;;; "advice" "emacs-lisp/advice.el" (18213 13926)) +;;;;;; "advice" "emacs-lisp/advice.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/advice.el (defvar ad-redefinition-action 'warn "\ @@ -429,7 +428,7 @@ See Info node `(elisp)Advising Functions' for comprehensive documentation. ;;;### (autoloads (align-newline-and-indent align-unhighlight-rule ;;;;;; align-highlight-rule align-current align-entire align-regexp -;;;;;; align) "align" "align.el" (18088 55079)) +;;;;;; align) "align" "align.el" (18307 57852)) ;;; Generated autoloads from align.el (autoload 'align "align" "\ @@ -519,9 +518,13 @@ A replacement function for `newline-and-indent', aligning as it goes. ;;;*** ;;;### (autoloads (outlineify-sticky allout-mode) "allout" "allout.el" -;;;;;; (18187 36838)) +;;;;;; (18307 57852)) ;;; Generated autoloads from allout.el +(put 'allout-use-hanging-indents 'safe-local-variable (if (fboundp 'booleanp) 'booleanp '(lambda (x) (member x '(t nil))))) + +(put 'allout-reindent-bodies 'safe-local-variable '(lambda (x) (memq x '(nil t text force)))) + (put 'allout-show-bodies 'safe-local-variable (if (fboundp 'booleanp) 'booleanp '(lambda (x) (member x '(t nil))))) (put 'allout-header-prefix 'safe-local-variable 'stringp) @@ -544,10 +547,6 @@ A replacement function for `newline-and-indent', aligning as it goes. (put 'allout-presentation-padding 'safe-local-variable 'integerp) -(put 'allout-use-hanging-indents 'safe-local-variable (if (fboundp 'booleanp) 'booleanp '(lambda (x) (member x '(t nil))))) - -(put 'allout-reindent-bodies 'safe-local-variable '(lambda (x) (memq x '(nil t text force)))) - (put 'allout-layout 'safe-local-variable '(lambda (x) (or (numberp x) (listp x) (memq x '(: * + -))))) (put 'allout-passphrase-verifier-string 'safe-local-variable 'stringp) @@ -826,7 +825,7 @@ setup for auto-startup. ;;;*** ;;;### (autoloads (ange-ftp-hook-function ange-ftp-reread-dir) "ange-ftp" -;;;;;; "net/ange-ftp.el" (18203 37788)) +;;;;;; "net/ange-ftp.el" (18307 57869)) ;;; Generated autoloads from net/ange-ftp.el (defalias 'ange-ftp-re-read-dir 'ange-ftp-reread-dir) @@ -848,7 +847,7 @@ Not documented ;;;*** ;;;### (autoloads (animate-birthday-present animate-sequence animate-string) -;;;;;; "animate" "play/animate.el" (18088 55113)) +;;;;;; "animate" "play/animate.el" (18307 57870)) ;;; Generated autoloads from play/animate.el (autoload 'animate-string "animate" "\ @@ -876,7 +875,7 @@ You can specify the one's name by NAME; the default value is \"Sarah\". ;;;*** ;;;### (autoloads (ansi-color-process-output ansi-color-for-comint-mode-on) -;;;;;; "ansi-color" "ansi-color.el" (18169 11930)) +;;;;;; "ansi-color" "ansi-color.el" (18307 57852)) ;;; Generated autoloads from ansi-color.el (autoload 'ansi-color-for-comint-mode-on "ansi-color" "\ @@ -902,7 +901,7 @@ This is a good function to put in `comint-output-filter-functions'. ;;;*** ;;;### (autoloads (antlr-set-tabs antlr-mode antlr-show-makefile-rules) -;;;;;; "antlr-mode" "progmodes/antlr-mode.el" (18203 37788)) +;;;;;; "antlr-mode" "progmodes/antlr-mode.el" (18307 57870)) ;;; Generated autoloads from progmodes/antlr-mode.el (autoload 'antlr-show-makefile-rules "antlr-mode" "\ @@ -941,52 +940,52 @@ Used in `antlr-mode'. Also a useful function in `java-mode-hook'. ;;;### (autoloads (appt-activate appt-make-list appt-delete appt-add ;;;;;; appt-display-diary appt-display-duration appt-display-mode-line ;;;;;; appt-msg-window appt-visible appt-audible appt-message-warning-time -;;;;;; appt-issue-message) "appt" "calendar/appt.el" (18090 40233)) +;;;;;; appt-issue-message) "appt" "calendar/appt.el" (18307 57860)) ;;; Generated autoloads from calendar/appt.el (defvar appt-issue-message t "\ -*Non-nil means check for appointments in the diary buffer. +Non-nil means check for appointments in the diary buffer. To be detected, the diary entry must have the format described in the documentation of the function `appt-check'.") (custom-autoload 'appt-issue-message "appt" t) (defvar appt-message-warning-time 12 "\ -*Time in minutes before an appointment that the warning begins.") +Time in minutes before an appointment that the warning begins.") (custom-autoload 'appt-message-warning-time "appt" t) (defvar appt-audible t "\ -*Non-nil means beep to indicate appointment.") +Non-nil means beep to indicate appointment.") (custom-autoload 'appt-audible "appt" t) (defvar appt-visible t "\ -*Non-nil means display appointment message in echo area. +Non-nil means display appointment message in echo area. This variable is only relevant if `appt-msg-window' is nil.") (custom-autoload 'appt-visible "appt" t) (defvar appt-msg-window t "\ -*Non-nil means display appointment message in another window. +Non-nil means display appointment message in another window. If non-nil, this variable overrides `appt-visible'.") (custom-autoload 'appt-msg-window "appt" t) (defvar appt-display-mode-line t "\ -*Non-nil means display minutes to appointment and time on the mode line. +Non-nil means display minutes to appointment and time on the mode line. This is in addition to any other display of appointment messages.") (custom-autoload 'appt-display-mode-line "appt" t) (defvar appt-display-duration 10 "\ -*The number of seconds an appointment message is displayed. +The number of seconds an appointment message is displayed. Only relevant if reminders are to be displayed in their own window.") (custom-autoload 'appt-display-duration "appt" t) (defvar appt-display-diary t "\ -*Non-nil displays the diary when the appointment list is first initialized. +Non-nil displays the diary when the appointment list is first initialized. This will occur at midnight when the appointment list is updated.") (custom-autoload 'appt-display-diary "appt" t) @@ -1029,7 +1028,7 @@ ARG is positive, otherwise off. ;;;### (autoloads (apropos-documentation apropos-value apropos apropos-documentation-property ;;;;;; apropos-command apropos-variable apropos-read-pattern) "apropos" -;;;;;; "apropos.el" (18088 55080)) +;;;;;; "apropos.el" (18307 57852)) ;;; Generated autoloads from apropos.el (autoload 'apropos-read-pattern "apropos" "\ @@ -1125,8 +1124,8 @@ Returns list of symbols and documentation found. ;;;*** -;;;### (autoloads (archive-mode) "arc-mode" "arc-mode.el" (18163 -;;;;;; 2859)) +;;;### (autoloads (archive-mode) "arc-mode" "arc-mode.el" (18307 +;;;;;; 57852)) ;;; Generated autoloads from arc-mode.el (autoload 'archive-mode "arc-mode" "\ @@ -1146,7 +1145,7 @@ archive. ;;;*** -;;;### (autoloads (array-mode) "array" "array.el" (18088 55080)) +;;;### (autoloads (array-mode) "array" "array.el" (18307 57852)) ;;; Generated autoloads from array.el (autoload 'array-mode "array" "\ @@ -1217,8 +1216,8 @@ Entering array mode calls the function `array-mode-hook'. ;;;*** -;;;### (autoloads (artist-mode) "artist" "textmodes/artist.el" (18200 -;;;;;; 51267)) +;;;### (autoloads (artist-mode) "artist" "textmodes/artist.el" (18307 +;;;;;; 57872)) ;;; Generated autoloads from textmodes/artist.el (autoload 'artist-mode "artist" "\ @@ -1423,8 +1422,8 @@ Keymap summary ;;;*** -;;;### (autoloads (asm-mode) "asm-mode" "progmodes/asm-mode.el" (18088 -;;;;;; 55114)) +;;;### (autoloads (asm-mode) "asm-mode" "progmodes/asm-mode.el" (18307 +;;;;;; 57870)) ;;; Generated autoloads from progmodes/asm-mode.el (autoload 'asm-mode "asm-mode" "\ @@ -1449,21 +1448,10 @@ Special commands: \(fn)" t nil) -;;;*** - -;;;### (autoloads (assistant) "assistant" "gnus/assistant.el" (18212 -;;;;;; 21478)) -;;; Generated autoloads from gnus/assistant.el - -(autoload 'assistant "assistant" "\ -Assist setting up Emacs based on FILE. - -\(fn FILE)" t nil) - ;;;*** ;;;### (autoloads (autoarg-kp-mode autoarg-mode) "autoarg" "autoarg.el" -;;;;;; (18088 55080)) +;;;;;; (18307 57852)) ;;; Generated autoloads from autoarg.el (defvar autoarg-mode nil "\ @@ -1517,7 +1505,7 @@ etc. to supply digit arguments. ;;;*** ;;;### (autoloads (autoconf-mode) "autoconf" "progmodes/autoconf.el" -;;;;;; (18147 59473)) +;;;;;; (18307 57870)) ;;; Generated autoloads from progmodes/autoconf.el (autoload 'autoconf-mode "autoconf" "\ @@ -1528,7 +1516,7 @@ Major mode for editing Autoconf configure.in files. ;;;*** ;;;### (autoloads (auto-insert-mode define-auto-insert auto-insert) -;;;;;; "autoinsert" "autoinsert.el" (18183 58476)) +;;;;;; "autoinsert" "autoinsert.el" (18307 57852)) ;;; Generated autoloads from autoinsert.el (autoload 'auto-insert "autoinsert" "\ @@ -1567,7 +1555,7 @@ insert a template for the file depending on the mode of the buffer. ;;;### (autoloads (batch-update-autoloads update-directory-autoloads ;;;;;; update-file-autoloads) "autoload" "emacs-lisp/autoload.el" -;;;;;; (18120 34750)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/autoload.el (put 'generated-autoload-file 'safe-local-variable 'stringp) @@ -1604,7 +1592,7 @@ Calls `update-directory-autoloads' on the command line arguments. ;;;### (autoloads (global-auto-revert-mode turn-on-auto-revert-tail-mode ;;;;;; auto-revert-tail-mode turn-on-auto-revert-mode auto-revert-mode) -;;;;;; "autorevert" "autorevert.el" (18177 7730)) +;;;;;; "autorevert" "autorevert.el" (18307 57852)) ;;; Generated autoloads from autorevert.el (autoload 'auto-revert-mode "autorevert" "\ @@ -1673,7 +1661,7 @@ Use `auto-revert-mode' to revert a particular buffer. ;;;*** ;;;### (autoloads (mouse-avoidance-mode mouse-avoidance-mode) "avoid" -;;;;;; "avoid.el" (18088 55080)) +;;;;;; "avoid.el" (18307 57852)) ;;; Generated autoloads from avoid.el (defvar mouse-avoidance-mode nil "\ @@ -1714,7 +1702,7 @@ definition of \"random distance\".) ;;;*** ;;;### (autoloads (backquote) "backquote" "emacs-lisp/backquote.el" -;;;;;; (18130 62047)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/backquote.el (autoload 'backquote "backquote" "\ @@ -1732,14 +1720,14 @@ b => (ba bb bc) ; assume b has this value Vectors work just like lists. Nested backquotes are permitted. -\(fn ARG)" nil (quote macro)) +\(fn STRUCTURE)" nil (quote macro)) (defalias '\` (symbol-function 'backquote)) ;;;*** ;;;### (autoloads (display-battery-mode battery) "battery" "battery.el" -;;;;;; (18088 55080)) +;;;;;; (18307 57852)) ;;; Generated autoloads from battery.el (put 'battery-mode-line-string 'risky-local-variable t) @@ -1771,7 +1759,7 @@ seconds. ;;;*** ;;;### (autoloads (benchmark benchmark-run-compiled benchmark-run) -;;;;;; "benchmark" "emacs-lisp/benchmark.el" (18088 55094)) +;;;;;; "benchmark" "emacs-lisp/benchmark.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/benchmark.el (autoload 'benchmark-run "benchmark" "\ @@ -1803,10 +1791,23 @@ non-interactive use see also `benchmark-run' and ;;;*** -;;;### (autoloads (bibtex-mode) "bibtex" "textmodes/bibtex.el" (18088 -;;;;;; 55119)) +;;;### (autoloads (bibtex-mode bibtex-initialize) "bibtex" "textmodes/bibtex.el" +;;;;;; (18308 12343)) ;;; Generated autoloads from textmodes/bibtex.el +(autoload 'bibtex-initialize "bibtex" "\ +(Re)Initialize BibTeX buffers. +Visit the BibTeX files defined by `bibtex-files' and return a list +of corresponding buffers. +Initialize in these buffers `bibtex-reference-keys' if not yet set. +List of BibTeX buffers includes current buffer if CURRENT is non-nil. +If FORCE is non-nil, (re)initialize `bibtex-reference-keys' even if +already set. If SELECT is non-nil interactively select a BibTeX buffer. +When called interactively, FORCE is t, CURRENT is t if current buffer uses +`bibtex-mode', and SELECT is t if current buffer does not use `bibtex-mode', + +\(fn &optional CURRENT FORCE SELECT)" t nil) + (autoload 'bibtex-mode "bibtex" "\ Major mode for editing BibTeX files. @@ -1865,7 +1866,7 @@ if that value is non-nil. ;;;*** ;;;### (autoloads (bibtex-style-mode) "bibtex-style" "textmodes/bibtex-style.el" -;;;;;; (18157 34340)) +;;;;;; (18307 57872)) ;;; Generated autoloads from textmodes/bibtex-style.el (add-to-list 'auto-mode-alist '("\\.bst\\'" . bibtex-style-mode)) @@ -1877,9 +1878,9 @@ Major mode for editing BibTeX style files. ;;;*** ;;;### (autoloads (binhex-decode-region binhex-decode-region-external -;;;;;; binhex-decode-region-internal) "binhex" "gnus/binhex.el" -;;;;;; (18212 46006)) -;;; Generated autoloads from gnus/binhex.el +;;;;;; binhex-decode-region-internal) "binhex" "mail/binhex.el" +;;;;;; (18307 57868)) +;;; Generated autoloads from mail/binhex.el (defconst binhex-begin-line "^:...............................................................$") @@ -1901,8 +1902,8 @@ Binhex decode region between START and END. ;;;*** -;;;### (autoloads (blackbox) "blackbox" "play/blackbox.el" (18203 -;;;;;; 37788)) +;;;### (autoloads (blackbox) "blackbox" "play/blackbox.el" (18308 +;;;;;; 19808)) ;;; Generated autoloads from play/blackbox.el (autoload 'blackbox "blackbox" "\ @@ -2024,8 +2025,8 @@ a reflection. ;;;### (autoloads (bookmark-bmenu-list bookmark-load bookmark-save ;;;;;; bookmark-write bookmark-delete bookmark-insert bookmark-rename ;;;;;; bookmark-insert-location bookmark-relocate bookmark-jump-other-window -;;;;;; bookmark-jump bookmark-set) "bookmark" "bookmark.el" (18169 -;;;;;; 11930)) +;;;;;; bookmark-jump bookmark-set) "bookmark" "bookmark.el" (18302 +;;;;;; 4830)) ;;; Generated autoloads from bookmark.el (define-key ctl-x-map "rb" 'bookmark-jump) (define-key ctl-x-map "rm" 'bookmark-set) @@ -2222,7 +2223,7 @@ deletion, or > if it is flagged for displaying. ;;;;;; browse-url-of-dired-file browse-url-of-buffer browse-url-of-file ;;;;;; browse-url-url-at-point browse-url-galeon-program browse-url-firefox-program ;;;;;; browse-url-browser-function) "browse-url" "net/browse-url.el" -;;;;;; (18214 4479)) +;;;;;; (18307 57869)) ;;; Generated autoloads from net/browse-url.el (defvar browse-url-browser-function (cond ((memq system-type '(windows-nt ms-dos cygwin)) 'browse-url-default-windows-browser) ((memq system-type '(darwin)) 'browse-url-default-macosx-browser) (t 'browse-url-default-browser)) "\ @@ -2552,8 +2553,8 @@ from `browse-url-elinks-wrapper'. ;;;*** -;;;### (autoloads (snarf-bruces bruce) "bruce" "play/bruce.el" (18088 -;;;;;; 55113)) +;;;### (autoloads (snarf-bruces bruce) "bruce" "play/bruce.el" (18307 +;;;;;; 57870)) ;;; Generated autoloads from play/bruce.el (autoload 'bruce "bruce" "\ @@ -2569,7 +2570,7 @@ Return a vector containing the lines from `bruce-phrases-file'. ;;;*** ;;;### (autoloads (bs-show bs-customize bs-cycle-previous bs-cycle-next) -;;;;;; "bs" "bs.el" (18211 32385)) +;;;;;; "bs" "bs.el" (18302 26511)) ;;; Generated autoloads from bs.el (autoload 'bs-cycle-next "bs" "\ @@ -2609,7 +2610,7 @@ name of buffer configuration. ;;;*** -;;;### (autoloads (bubbles) "bubbles" "play/bubbles.el" (18157 34340)) +;;;### (autoloads (bubbles) "bubbles" "play/bubbles.el" (18308 19808)) ;;; Generated autoloads from play/bubbles.el (autoload 'bubbles "bubbles" "\ @@ -2620,8 +2621,8 @@ Play Bubbles game. ;;;*** ;;;### (autoloads (insert-text-button make-text-button insert-button -;;;;;; make-button define-button-type) "button" "button.el" (18133 -;;;;;; 60495)) +;;;;;; make-button define-button-type) "button" "button.el" (18307 +;;;;;; 57852)) ;;; Generated autoloads from button.el (defvar button-map (let ((map (make-sparse-keymap))) (define-key map " " 'push-button) (define-key map [mouse-2] 'push-button) map) "\ @@ -2710,7 +2711,7 @@ Also see `make-text-button'. ;;;;;; compile-defun byte-compile-file byte-recompile-directory ;;;;;; byte-force-recompile byte-compile-enable-warning byte-compile-disable-warning ;;;;;; byte-compile-warnings-safe-p) "bytecomp" "emacs-lisp/bytecomp.el" -;;;;;; (18213 13926)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/bytecomp.el (put 'byte-compile-dynamic 'safe-local-variable 'booleanp) (put 'byte-compile-disable-print-circle 'safe-local-variable 'booleanp) @@ -2726,6 +2727,8 @@ Not documented Change `byte-compile-warnings' to disable WARNING. If `byte-compile-warnings' is t, set it to `(not WARNING)'. Otherwise, if the first element is `not', add WARNING, else remove it. +Normally you should let-bind `byte-compile-warnings' before calling this, +else the global value will be modified. \(fn WARNING)" nil nil) @@ -2733,6 +2736,8 @@ Otherwise, if the first element is `not', add WARNING, else remove it. Change `byte-compile-warnings' to enable WARNING. If `byte-compile-warnings' is `t', do nothing. Otherwise, if the first element is `not', remove WARNING, else add it. +Normally you should let-bind `byte-compile-warnings' before calling this, +else the global value will be modified. \(fn WARNING)" nil nil) @@ -2824,14 +2829,14 @@ Must be used only with `-batch', and kills Emacs on completion. For example, invoke `emacs -batch -f batch-byte-recompile-directory .'. Optional argument ARG is passed as second argument ARG to -`batch-recompile-directory'; see there for its possible values +`byte-recompile-directory'; see there for its possible values and corresponding effects. \(fn &optional ARG)" nil nil) ;;;*** -;;;### (autoloads nil "cal-dst" "calendar/cal-dst.el" (18088 55093)) +;;;### (autoloads nil "cal-dst" "calendar/cal-dst.el" (18307 57860)) ;;; Generated autoloads from calendar/cal-dst.el (put 'calendar-daylight-savings-starts 'risky-local-variable t) @@ -2841,7 +2846,7 @@ and corresponding effects. ;;;*** ;;;### (autoloads (list-yahrzeit-dates) "cal-hebrew" "calendar/cal-hebrew.el" -;;;;;; (18203 38492)) +;;;;;; (18307 57860)) ;;; Generated autoloads from calendar/cal-hebrew.el (autoload 'list-yahrzeit-dates "cal-hebrew" "\ @@ -2856,7 +2861,7 @@ from the cursor position. ;;;### (autoloads (defmath calc-embedded-activate calc-embedded calc-grab-rectangle ;;;;;; calc-grab-region full-calc-keypad calc-keypad calc-eval quick-calc ;;;;;; full-calc calc calc-dispatch calc-settings-file) "calc" "calc/calc.el" -;;;;;; (18214 4479)) +;;;;;; (18307 57860)) ;;; Generated autoloads from calc/calc.el (defvar calc-settings-file (convert-standard-filename "~/.calc.el") "\ @@ -2934,8 +2939,8 @@ Not documented ;;;*** -;;;### (autoloads (calculator) "calculator" "calculator.el" (18203 -;;;;;; 37786)) +;;;### (autoloads (calculator) "calculator" "calculator.el" (18307 +;;;;;; 57852)) ;;; Generated autoloads from calculator.el (autoload 'calculator "calculator" "\ @@ -2963,7 +2968,7 @@ See the documentation for `calculator-mode' for more information. ;;;;;; mark-holidays-in-calendar view-calendar-holidays-initially ;;;;;; calendar-remove-frame-by-deleting mark-diary-entries-in-calendar ;;;;;; view-diary-entries-initially calendar-offset) "calendar" -;;;;;; "calendar/calendar.el" (18157 34340)) +;;;;;; "calendar/calendar.el" (18307 57860)) ;;; Generated autoloads from calendar/calendar.el (defvar calendar-offset 0 "\ @@ -3367,7 +3372,7 @@ List of functions called for listing diary file and included files. As the files are processed for diary entries, these functions are used to cull relevant entries. You can use either or both of `list-hebrew-diary-entries', `list-islamic-diary-entries' and -`list-bahai-diary-entries'. The documentation for these functions +`diary-bahai-list-entries'. The documentation for these functions describes the style of such diary entries.") (custom-autoload 'nongregorian-diary-listing-hook "calendar" t) @@ -3536,7 +3541,7 @@ movement commands will not work correctly.") ;;;*** ;;;### (autoloads (canlock-verify canlock-insert-header) "canlock" -;;;;;; "gnus/canlock.el" (18088 55101)) +;;;;;; "gnus/canlock.el" (18307 57865)) ;;; Generated autoloads from gnus/canlock.el (autoload 'canlock-insert-header "canlock" "\ @@ -3553,15 +3558,15 @@ it fails. ;;;*** -;;;### (autoloads nil "cc-compat" "progmodes/cc-compat.el" (18088 -;;;;;; 55114)) +;;;### (autoloads nil "cc-compat" "progmodes/cc-compat.el" (18307 +;;;;;; 57870)) ;;; Generated autoloads from progmodes/cc-compat.el (put 'c-indent-level 'safe-local-variable 'integerp) ;;;*** ;;;### (autoloads (c-guess-basic-syntax) "cc-engine" "progmodes/cc-engine.el" -;;;;;; (18203 37789)) +;;;;;; (18316 2343)) ;;; Generated autoloads from progmodes/cc-engine.el (autoload 'c-guess-basic-syntax "cc-engine" "\ @@ -3573,7 +3578,7 @@ Return the syntactic context of the current line. ;;;### (autoloads (pike-mode idl-mode java-mode objc-mode c++-mode ;;;;;; c-mode c-initialize-cc-mode) "cc-mode" "progmodes/cc-mode.el" -;;;;;; (18191 7159)) +;;;;;; (18307 57870)) ;;; Generated autoloads from progmodes/cc-mode.el (autoload 'c-initialize-cc-mode "cc-mode" "\ @@ -3731,7 +3736,7 @@ Key bindings: ;;;*** ;;;### (autoloads (c-set-offset c-add-style c-set-style) "cc-styles" -;;;;;; "progmodes/cc-styles.el" (18192 17587)) +;;;;;; "progmodes/cc-styles.el" (18307 57871)) ;;; Generated autoloads from progmodes/cc-styles.el (autoload 'c-set-style "cc-styles" "\ @@ -3782,14 +3787,36 @@ and exists only for compatibility reasons. ;;;*** -;;;### (autoloads nil "cc-subword" "progmodes/cc-subword.el" (18088 -;;;;;; 55115)) +;;;### (autoloads (c-subword-mode) "cc-subword" "progmodes/cc-subword.el" +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/cc-subword.el - (autoload 'c-subword-mode "cc-subword" "Mode enabling subword movement and editing keys." t) + +(autoload 'c-subword-mode "cc-subword" "\ +Mode enabling subword movement and editing keys. +In spite of GNU Coding Standards, it is popular to name a symbol by +mixing uppercase and lowercase letters, e.g. \"GtkWidget\", +\"EmacsFrameClass\", \"NSGraphicsContext\", etc. Here we call these +mixed case symbols `nomenclatures'. Also, each capitalized (or +completely uppercase) part of a nomenclature is called a `subword'. +Here are some examples: + + Nomenclature Subwords + =========================================================== + GtkWindow => \"Gtk\" and \"Window\" + EmacsFrameClass => \"Emacs\", \"Frame\" and \"Class\" + NSGraphicsContext => \"NS\", \"Graphics\" and \"Context\" + +The subword oriented commands activated in this minor mode recognize +subwords in a nomenclature to move between subwords and to edit them +as words. + +\\{c-subword-mode-map} + +\(fn &optional ARG)" t nil) ;;;*** -;;;### (autoloads nil "cc-vars" "progmodes/cc-vars.el" (18120 34752)) +;;;### (autoloads nil "cc-vars" "progmodes/cc-vars.el" (18317 19256)) ;;; Generated autoloads from progmodes/cc-vars.el (put 'c-basic-offset 'safe-local-variable 'integerp) (put 'c-backslash-column 'safe-local-variable 'integerp) @@ -3799,7 +3826,7 @@ and exists only for compatibility reasons. ;;;### (autoloads (ccl-execute-with-args check-ccl-program define-ccl-program ;;;;;; declare-ccl-program ccl-dump ccl-compile) "ccl" "international/ccl.el" -;;;;;; (18088 55107)) +;;;;;; (18307 57867)) ;;; Generated autoloads from international/ccl.el (autoload 'ccl-compile "ccl" "\ @@ -4058,7 +4085,7 @@ See the documentation of `define-ccl-program' for the detail of CCL program. ;;;*** ;;;### (autoloads (cfengine-mode) "cfengine" "progmodes/cfengine.el" -;;;;;; (18088 55115)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/cfengine.el (autoload 'cfengine-mode "cfengine" "\ @@ -4070,6 +4097,26 @@ to the action header. \(fn)" t nil) +;;;*** + +;;;### (autoloads (check-declare-directory check-declare-file) "check-declare" +;;;;;; "emacs-lisp/check-declare.el" (18308 19808)) +;;; Generated autoloads from emacs-lisp/check-declare.el + +(autoload 'check-declare-file "check-declare" "\ +Check veracity of all `declare-function' statements in FILE. +See `check-declare-directory' for more information. + +\(fn FILE)" t nil) + +(autoload 'check-declare-directory "check-declare" "\ +Check veracity of all `declare-function' statements under directory ROOT. +Returns non-nil if any false statements are found. For this to +work correctly, the statements must adhere to the format +described in the documentation of `declare-function'. + +\(fn ROOT)" t nil) + ;;;*** ;;;### (autoloads (checkdoc-minor-mode checkdoc-ispell-defun checkdoc-ispell-comments @@ -4080,7 +4127,7 @@ to the action header. ;;;;;; checkdoc-comments checkdoc-continue checkdoc-start checkdoc-current-buffer ;;;;;; checkdoc-eval-current-buffer checkdoc-message-interactive ;;;;;; checkdoc-interactive checkdoc) "checkdoc" "emacs-lisp/checkdoc.el" -;;;;;; (18203 37787)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/checkdoc.el (put 'checkdoc-force-docstrings-flag 'safe-local-variable 'booleanp) (put 'checkdoc-permit-comma-termination-flag 'safe-local-variable 'booleanp) @@ -4266,8 +4313,8 @@ checking of documentation strings. ;;;*** ;;;### (autoloads (encode-hz-buffer encode-hz-region decode-hz-buffer -;;;;;; decode-hz-region) "china-util" "language/china-util.el" (18088 -;;;;;; 55108)) +;;;;;; decode-hz-region) "china-util" "language/china-util.el" (18311 +;;;;;; 19809)) ;;; Generated autoloads from language/china-util.el (autoload 'decode-hz-region "china-util" "\ @@ -4295,7 +4342,7 @@ Encode the text in the current buffer to HZ. ;;;*** ;;;### (autoloads (command-history list-command-history repeat-matching-complex-command) -;;;;;; "chistory" "chistory.el" (18088 55080)) +;;;;;; "chistory" "chistory.el" (18307 57853)) ;;; Generated autoloads from chistory.el (autoload 'repeat-matching-complex-command "chistory" "\ @@ -4334,7 +4381,7 @@ and runs the normal hook `command-history-hook'. ;;;*** -;;;### (autoloads nil "cl" "emacs-lisp/cl.el" (18213 13926)) +;;;### (autoloads nil "cl" "emacs-lisp/cl.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/cl.el (defvar custom-print-functions nil "\ @@ -4350,7 +4397,7 @@ a future Emacs interpreter will be able to use it.") ;;;*** ;;;### (autoloads (common-lisp-indent-function) "cl-indent" "emacs-lisp/cl-indent.el" -;;;;;; (18088 55095)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/cl-indent.el (autoload 'common-lisp-indent-function "cl-indent" "\ @@ -4361,7 +4408,7 @@ Not documented ;;;*** ;;;### (autoloads (c-macro-expand) "cmacexp" "progmodes/cmacexp.el" -;;;;;; (18088 55115)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/cmacexp.el (autoload 'c-macro-expand "cmacexp" "\ @@ -4381,8 +4428,8 @@ For use inside Lisp programs, see also `c-macro-expansion'. ;;;*** -;;;### (autoloads (run-scheme) "cmuscheme" "cmuscheme.el" (18088 -;;;;;; 55080)) +;;;### (autoloads (run-scheme) "cmuscheme" "cmuscheme.el" (18307 +;;;;;; 57853)) ;;; Generated autoloads from cmuscheme.el (autoload 'run-scheme "cmuscheme" "\ @@ -4404,7 +4451,7 @@ is run). ;;;*** ;;;### (autoloads (cp-make-coding-system) "code-pages" "international/code-pages.el" -;;;;;; (18088 55107)) +;;;;;; (18307 57867)) ;;; Generated autoloads from international/code-pages.el (autoload 'cp-make-coding-system "code-pages" "\ @@ -4465,7 +4512,7 @@ Return an updated `non-iso-charset-alist'. ;;;### (autoloads (codepage-setup cp-supported-codepages cp-offset-for-codepage ;;;;;; cp-language-for-codepage cp-charset-for-codepage cp-make-coding-systems-for-codepage) -;;;;;; "codepage" "international/codepage.el" (18088 55107)) +;;;;;; "codepage" "international/codepage.el" (18307 57867)) ;;; Generated autoloads from international/codepage.el (autoload 'cp-make-coding-systems-for-codepage "codepage" "\ @@ -4524,7 +4571,7 @@ read/written by MS-DOS software, or for display on the MS-DOS terminal. ;;;### (autoloads (comint-redirect-results-list-from-process comint-redirect-results-list ;;;;;; comint-redirect-send-command-to-process comint-redirect-send-command ;;;;;; comint-run make-comint make-comint-in-buffer) "comint" "comint.el" -;;;;;; (18208 48750)) +;;;;;; (18316 9691)) ;;; Generated autoloads from comint.el (defvar comint-output-filter-functions '(comint-postoutput-scroll-to-bottom comint-watch-for-password-prompt) "\ @@ -4614,8 +4661,8 @@ REGEXP-GROUP is the regular expression group in REGEXP to use. ;;;*** -;;;### (autoloads (compare-windows) "compare-w" "compare-w.el" (18088 -;;;;;; 55080)) +;;;### (autoloads (compare-windows) "compare-w" "compare-w.el" (18307 +;;;;;; 57854)) ;;; Generated autoloads from compare-w.el (autoload 'compare-windows "compare-w" "\ @@ -4652,7 +4699,7 @@ on third call it again advances points to the next difference and so on. ;;;;;; compilation-shell-minor-mode compilation-mode compilation-start ;;;;;; compile compilation-disable-input compile-command compilation-search-path ;;;;;; compilation-ask-about-save compilation-window-height compilation-mode-hook) -;;;;;; "compile" "progmodes/compile.el" (18202 4003)) +;;;;;; "compile" "progmodes/compile.el" (18316 2343)) ;;; Generated autoloads from progmodes/compile.el (defvar compilation-mode-hook nil "\ @@ -4820,7 +4867,7 @@ This is the value of `next-error-function' in Compilation buffers. ;;;*** ;;;### (autoloads (partial-completion-mode) "complete" "complete.el" -;;;;;; (18204 59927)) +;;;;;; (18307 57854)) ;;; Generated autoloads from complete.el (defvar partial-completion-mode nil "\ @@ -4862,7 +4909,7 @@ second TAB brings up the `*Completions*' buffer. ;;;*** ;;;### (autoloads (dynamic-completion-mode) "completion" "completion.el" -;;;;;; (18169 11930)) +;;;;;; (18307 57854)) ;;; Generated autoloads from completion.el (defvar dynamic-completion-mode nil "\ @@ -4884,7 +4931,7 @@ Enable dynamic word-completion. ;;;### (autoloads (decompose-composite-char compose-last-chars compose-chars-after ;;;;;; find-composition compose-chars decompose-string compose-string ;;;;;; decompose-region compose-region encode-composition-rule) -;;;;;; "composite" "composite.el" (18088 55081)) +;;;;;; "composite" "composite.el" (18307 57854)) ;;; Generated autoloads from composite.el (defconst reference-point-alist '((tl . 0) (tc . 1) (tr . 2) (Bl . 3) (Bc . 4) (Br . 5) (bl . 6) (bc . 7) (br . 8) (cl . 9) (cc . 10) (cr . 11) (top-left . 0) (top-center . 1) (top-right . 2) (base-left . 3) (base-center . 4) (base-right . 5) (bottom-left . 6) (bottom-center . 7) (bottom-right . 8) (center-left . 9) (center-center . 10) (center-right . 11) (ml . 3) (mc . 10) (mr . 5) (mid-left . 3) (mid-center . 10) (mid-right . 5)) "\ @@ -5106,7 +5153,7 @@ Optional 3rd arg WITH-COMPOSITION-RULE is ignored. ;;;### (autoloads (conf-xdefaults-mode conf-ppd-mode conf-colon-mode ;;;;;; conf-space-keywords conf-space-mode conf-javaprop-mode conf-windows-mode ;;;;;; conf-unix-mode conf-mode) "conf-mode" "textmodes/conf-mode.el" -;;;;;; (18208 48754)) +;;;;;; (18307 57872)) ;;; Generated autoloads from textmodes/conf-mode.el (autoload 'conf-mode "conf-mode" "\ @@ -5262,7 +5309,7 @@ For details see `conf-mode'. Example: ;;;*** ;;;### (autoloads (shuffle-vector cookie-snarf cookie-insert cookie) -;;;;;; "cookie1" "play/cookie1.el" (18088 55113)) +;;;;;; "cookie1" "play/cookie1.el" (18307 57870)) ;;; Generated autoloads from play/cookie1.el (autoload 'cookie "cookie1" "\ @@ -5294,7 +5341,7 @@ Randomly permute the elements of VECTOR (all permutations equally likely). ;;;*** ;;;### (autoloads (copyright copyright-fix-years copyright-update) -;;;;;; "copyright" "emacs-lisp/copyright.el" (18183 58476)) +;;;;;; "copyright" "emacs-lisp/copyright.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/copyright.el (autoload 'copyright-update "copyright" "\ @@ -5322,9 +5369,15 @@ Insert a copyright by $ORGANIZATION notice at cursor. ;;;*** ;;;### (autoloads (cperl-perldoc-at-point cperl-perldoc cperl-mode) -;;;;;; "cperl-mode" "progmodes/cperl-mode.el" (18214 4479)) +;;;;;; "cperl-mode" "progmodes/cperl-mode.el" (18307 57871)) ;;; Generated autoloads from progmodes/cperl-mode.el (put 'cperl-indent-level 'safe-local-variable 'integerp) +(put 'cperl-brace-offset 'safe-local-variable 'integerp) +(put 'cperl-continued-brace-offset 'safe-local-variable 'integerp) +(put 'cperl-label-offset 'safe-local-variable 'integerp) +(put 'cperl-continued-statement-offset 'safe-local-variable 'integerp) +(put 'cperl-extra-newline-before-brace 'safe-local-variable 'booleanp) +(put 'cperl-merge-trailing-else 'safe-local-variable 'booleanp) (autoload 'cperl-mode "cperl-mode" "\ Major mode for editing Perl code. @@ -5514,7 +5567,7 @@ Run a `perldoc' on the word around point. ;;;*** ;;;### (autoloads (cpp-parse-edit cpp-highlight-buffer) "cpp" "progmodes/cpp.el" -;;;;;; (18120 34752)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/cpp.el (autoload 'cpp-highlight-buffer "cpp" "\ @@ -5533,7 +5586,7 @@ Edit display information for cpp conditionals. ;;;*** ;;;### (autoloads (crisp-mode crisp-mode) "crisp" "emulation/crisp.el" -;;;;;; (18088 55097)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emulation/crisp.el (defvar crisp-mode nil "\ @@ -5557,7 +5610,7 @@ With ARG, turn CRiSP mode on if ARG is positive, off otherwise. ;;;*** ;;;### (autoloads (completing-read-multiple) "crm" "emacs-lisp/crm.el" -;;;;;; (18088 55095)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/crm.el (autoload 'completing-read-multiple "crm" "\ @@ -5592,8 +5645,8 @@ INHERIT-INPUT-METHOD. ;;;*** -;;;### (autoloads (css-mode) "css-mode" "textmodes/css-mode.el" (18211 -;;;;;; 32385)) +;;;### (autoloads (css-mode) "css-mode" "textmodes/css-mode.el" (18307 +;;;;;; 57872)) ;;; Generated autoloads from textmodes/css-mode.el (add-to-list 'auto-mode-alist '("\\.css\\'" . css-mode)) @@ -5605,7 +5658,7 @@ Major mode to edit Cascading Style Sheets. ;;;*** ;;;### (autoloads (cua-selection-mode cua-mode) "cua-base" "emulation/cua-base.el" -;;;;;; (18186 14736)) +;;;;;; (18307 57862)) ;;; Generated autoloads from emulation/cua-base.el (defvar cua-mode nil "\ @@ -5664,7 +5717,7 @@ Enable CUA selection mode without the C-z/C-x/C-c/C-v bindings. ;;;;;; customize-mode customize customize-save-variable customize-set-variable ;;;;;; customize-set-value custom-menu-sort-alphabetically custom-buffer-sort-alphabetically ;;;;;; custom-browse-sort-alphabetically) "cus-edit" "cus-edit.el" -;;;;;; (18212 54459)) +;;;;;; (18304 46561)) ;;; Generated autoloads from cus-edit.el (defvar custom-browse-sort-alphabetically nil "\ @@ -5862,7 +5915,7 @@ that are not customizable options, as well as faces and groups (autoload 'customize-apropos-options "cus-edit" "\ Customize all loaded customizable options matching REGEXP. With prefix arg, include variables that are not customizable options -\(but we recommend using `apropos-variable' instead). +\(but it is better to use `apropos-variable' if you want to find those). \(fn REGEXP &optional ARG)" t nil) @@ -5962,7 +6015,7 @@ The format is suitable for use with `easy-menu-define'. ;;;*** ;;;### (autoloads (custom-reset-faces custom-theme-reset-faces custom-set-faces -;;;;;; custom-declare-face) "cus-face" "cus-face.el" (18157 61328)) +;;;;;; custom-declare-face) "cus-face" "cus-face.el" (18307 57854)) ;;; Generated autoloads from cus-face.el (autoload 'custom-declare-face "cus-face" "\ @@ -6032,7 +6085,7 @@ This means reset FACE to its value in FROM-THEME. ;;;*** ;;;### (autoloads (customize-create-theme) "cus-theme" "cus-theme.el" -;;;;;; (18088 55081)) +;;;;;; (18307 57854)) ;;; Generated autoloads from cus-theme.el (autoload 'customize-create-theme "cus-theme" "\ @@ -6043,7 +6096,7 @@ Create a custom theme. ;;;*** ;;;### (autoloads (cvs-status-mode) "cvs-status" "cvs-status.el" -;;;;;; (18088 55081)) +;;;;;; (18307 57854)) ;;; Generated autoloads from cvs-status.el (autoload 'cvs-status-mode "cvs-status" "\ @@ -6054,7 +6107,7 @@ Mode used for cvs status output. ;;;*** ;;;### (autoloads (global-cwarn-mode turn-on-cwarn-mode cwarn-mode) -;;;;;; "cwarn" "progmodes/cwarn.el" (18088 55115)) +;;;;;; "cwarn" "progmodes/cwarn.el" (18307 57871)) ;;; Generated autoloads from progmodes/cwarn.el (autoload 'cwarn-mode "cwarn" "\ @@ -6097,7 +6150,7 @@ See `cwarn-mode' for more information on Cwarn mode. ;;;### (autoloads (standard-display-cyrillic-translit cyrillic-encode-alternativnyj-char ;;;;;; cyrillic-encode-koi8-r-char) "cyril-util" "language/cyril-util.el" -;;;;;; (18088 55108)) +;;;;;; (18307 57867)) ;;; Generated autoloads from language/cyril-util.el (autoload 'cyrillic-encode-koi8-r-char "cyril-util" "\ @@ -6126,7 +6179,7 @@ If the argument is nil, we return the display table to its standard state. ;;;*** ;;;### (autoloads (dabbrev-expand dabbrev-completion) "dabbrev" "dabbrev.el" -;;;;;; (18126 18419)) +;;;;;; (18307 57854)) ;;; Generated autoloads from dabbrev.el (define-key esc-map "/" 'dabbrev-expand) (define-key esc-map [?\C-/] 'dabbrev-completion) @@ -6170,8 +6223,21 @@ See also `dabbrev-abbrev-char-regexp' and \\[dabbrev-completion]. ;;;*** -;;;### (autoloads (dcl-mode) "dcl-mode" "progmodes/dcl-mode.el" (18203 -;;;;;; 37789)) +;;;### (autoloads (dbus-handle-event) "dbus" "net/dbus.el" (18303 +;;;;;; 25698)) +;;; Generated autoloads from net/dbus.el + +(autoload 'dbus-handle-event "dbus" "\ +Handle events from the D-Bus. +EVENT is a D-Bus event, see `dbus-check-event'. HANDLER, being +part of the event, is called with arguments ARGS. + +\(fn EVENT)" t nil) + +;;;*** + +;;;### (autoloads (dcl-mode) "dcl-mode" "progmodes/dcl-mode.el" (18307 +;;;;;; 57871)) ;;; Generated autoloads from progmodes/dcl-mode.el (autoload 'dcl-mode "dcl-mode" "\ @@ -6298,7 +6364,7 @@ There is some minimal font-lock support (see vars ;;;*** ;;;### (autoloads (cancel-debug-on-entry debug-on-entry debug) "debug" -;;;;;; "emacs-lisp/debug.el" (18197 21672)) +;;;;;; "emacs-lisp/debug.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/debug.el (setq debugger 'debug) @@ -6342,7 +6408,7 @@ To specify a nil argument interactively, exit with an empty minibuffer. ;;;*** ;;;### (autoloads (decipher-mode decipher) "decipher" "play/decipher.el" -;;;;;; (18202 4002)) +;;;;;; (18307 57870)) ;;; Generated autoloads from play/decipher.el (autoload 'decipher "decipher" "\ @@ -6371,8 +6437,8 @@ The most useful commands are: ;;;*** ;;;### (autoloads (delimit-columns-rectangle delimit-columns-region -;;;;;; delimit-columns-customize) "delim-col" "delim-col.el" (18088 -;;;;;; 55081)) +;;;;;; delimit-columns-customize) "delim-col" "delim-col.el" (18307 +;;;;;; 57854)) ;;; Generated autoloads from delim-col.el (autoload 'delimit-columns-customize "delim-col" "\ @@ -6396,8 +6462,8 @@ START and END delimits the corners of text rectangle. ;;;*** -;;;### (autoloads (delphi-mode) "delphi" "progmodes/delphi.el" (18200 -;;;;;; 51266)) +;;;### (autoloads (delphi-mode) "delphi" "progmodes/delphi.el" (18307 +;;;;;; 57871)) ;;; Generated autoloads from progmodes/delphi.el (autoload 'delphi-mode "delphi" "\ @@ -6447,8 +6513,8 @@ no args, if that value is non-nil. ;;;*** -;;;### (autoloads (delete-selection-mode) "delsel" "delsel.el" (18186 -;;;;;; 14736)) +;;;### (autoloads (delete-selection-mode) "delsel" "delsel.el" (18307 +;;;;;; 57854)) ;;; Generated autoloads from delsel.el (defalias 'pending-delete-mode 'delete-selection-mode) @@ -6464,8 +6530,8 @@ or call the function `delete-selection-mode'.") (autoload 'delete-selection-mode "delsel" "\ Toggle Delete Selection mode. -With prefix ARG, turn Delete Selection mode on if and only if ARG is -positive. +With prefix ARG, turn Delete Selection mode on if ARG is +positive, off if ARG is not positive. When Delete Selection mode is enabled, Transient Mark mode is also enabled and typed text replaces the selection if the selection is @@ -6477,7 +6543,7 @@ any selection. ;;;*** ;;;### (autoloads (derived-mode-init-mode-variables define-derived-mode) -;;;;;; "derived" "emacs-lisp/derived.el" (18088 55095)) +;;;;;; "derived" "emacs-lisp/derived.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/derived.el (autoload 'define-derived-mode "derived" "\ @@ -6542,7 +6608,7 @@ the first time the mode is used. ;;;*** ;;;### (autoloads (describe-char describe-text-properties) "descr-text" -;;;;;; "descr-text.el" (18088 55081)) +;;;;;; "descr-text.el" (18307 57854)) ;;; Generated autoloads from descr-text.el (autoload 'describe-text-properties "descr-text" "\ @@ -6568,7 +6634,7 @@ as well as widgets, buttons, overlays, and text properties. ;;;### (autoloads (desktop-revert desktop-save-in-desktop-dir desktop-change-dir ;;;;;; desktop-load-default desktop-read desktop-remove desktop-save ;;;;;; desktop-clear desktop-locals-to-save desktop-save-mode) "desktop" -;;;;;; "desktop.el" (18211 32385)) +;;;;;; "desktop.el" (18307 57854)) ;;; Generated autoloads from desktop.el (defvar desktop-save-mode nil "\ @@ -6752,7 +6818,7 @@ Revert to the last loaded desktop. ;;;### (autoloads (gnus-article-outlook-deuglify-article gnus-outlook-deuglify-article ;;;;;; gnus-article-outlook-repair-attribution gnus-article-outlook-unwrap-lines) -;;;;;; "deuglify" "gnus/deuglify.el" (18212 46006)) +;;;;;; "deuglify" "gnus/deuglify.el" (18307 57865)) ;;; Generated autoloads from gnus/deuglify.el (autoload 'gnus-article-outlook-unwrap-lines "deuglify" "\ @@ -6785,7 +6851,7 @@ Deuglify broken Outlook (Express) articles and redisplay. ;;;*** ;;;### (autoloads (devanagari-post-read-conversion devanagari-compose-region) -;;;;;; "devan-util" "language/devan-util.el" (18088 55109)) +;;;;;; "devan-util" "language/devan-util.el" (18307 57867)) ;;; Generated autoloads from language/devan-util.el (defconst devanagari-consonant "[\x51ad5-\x51af9\x51b38-\x51b3f]") @@ -6803,7 +6869,7 @@ Not documented ;;;*** ;;;### (autoloads (diary-mode diary-mail-entries diary) "diary-lib" -;;;;;; "calendar/diary-lib.el" (18157 34340)) +;;;;;; "calendar/diary-lib.el" (18307 57860)) ;;; Generated autoloads from calendar/diary-lib.el (autoload 'diary "diary-lib" "\ @@ -6849,7 +6915,7 @@ Major mode for editing the diary file. ;;;*** ;;;### (autoloads (diff-backup diff diff-command diff-switches) "diff" -;;;;;; "diff.el" (18210 30826)) +;;;;;; "diff.el" (18307 57854)) ;;; Generated autoloads from diff.el (defvar diff-switches "-c" "\ @@ -6883,7 +6949,7 @@ With prefix arg, prompt for diff switches. ;;;*** ;;;### (autoloads (diff-minor-mode diff-mode) "diff-mode" "diff-mode.el" -;;;;;; (18203 37786)) +;;;;;; (18316 12901)) ;;; Generated autoloads from diff-mode.el (autoload 'diff-mode "diff-mode" "\ @@ -6915,7 +6981,7 @@ Minor mode for viewing/editing context diffs. ;;;;;; dired dired-copy-preserve-time dired-dwim-target dired-keep-marker-symlink ;;;;;; dired-keep-marker-hardlink dired-keep-marker-copy dired-keep-marker-rename ;;;;;; dired-trivial-filenames dired-ls-F-marks-symlinks dired-listing-switches) -;;;;;; "dired" "dired.el" (18200 51263)) +;;;;;; "dired" "dired.el" (18307 57854)) ;;; Generated autoloads from dired.el (defvar dired-listing-switches "-al" "\ @@ -6929,7 +6995,7 @@ some of the `ls' switches are not supported; see the doc string of (custom-autoload 'dired-listing-switches "dired" t) -(defvar dired-chown-program (if (memq system-type '(hpux dgux usg-unix-v irix linux gnu/linux cygwin)) "chown" (if (file-exists-p "/usr/sbin/chown") "/usr/sbin/chown" "/etc/chown")) "\ +(defvar dired-chown-program (if (memq system-type '(hpux usg-unix-v irix linux gnu/linux cygwin)) "chown" (if (file-exists-p "/usr/sbin/chown") "/usr/sbin/chown" "/etc/chown")) "\ Name of chown command (usually `chown' or `/etc/chown').") (defvar dired-ls-F-marks-symlinks nil "\ @@ -7120,7 +7186,7 @@ Keybindings: ;;;;;; dired-run-shell-command dired-do-shell-command dired-clean-directory ;;;;;; dired-do-print dired-do-touch dired-do-chown dired-do-chgrp ;;;;;; dired-do-chmod dired-compare-directories dired-backup-diff -;;;;;; dired-diff) "dired-aux" "dired-aux.el" (18169 11930)) +;;;;;; dired-diff) "dired-aux" "dired-aux.el" (18307 57854)) ;;; Generated autoloads from dired-aux.el (autoload 'dired-diff "dired-aux" "\ @@ -7535,7 +7601,7 @@ true then the type of the file linked to by FILE is printed instead. ;;;*** ;;;### (autoloads (dired-do-relsymlink dired-jump) "dired-x" "dired-x.el" -;;;;;; (18212 46004)) +;;;;;; (18307 57854)) ;;; Generated autoloads from dired-x.el (autoload 'dired-jump "dired-x" "\ @@ -7565,12 +7631,16 @@ For absolute symlinks, use \\[dired-do-symlink]. ;;;*** ;;;### (autoloads (dirtrack dirtrack-mode) "dirtrack" "dirtrack.el" -;;;;;; (18213 13926)) +;;;;;; (18307 57854)) ;;; Generated autoloads from dirtrack.el (autoload 'dirtrack-mode "dirtrack" "\ Enable or disable Dirtrack directory tracking in a shell buffer. -This provides an alternative to `shell-dirtrack-mode'. +This method requires that your shell prompt contain the full +current working directory at all times, and that `dirtrack-list' +is set to match the prompt. This is an alternative to +`shell-dirtrack-mode', which works differently, by tracking `cd' +and similar commands which change the shell working directory. \(fn &optional ARG)" t nil) @@ -7587,8 +7657,8 @@ function `dirtrack-debug-mode' to turn on debugging output. ;;;*** -;;;### (autoloads (disassemble) "disass" "emacs-lisp/disass.el" (18173 -;;;;;; 8195)) +;;;### (autoloads (disassemble) "disass" "emacs-lisp/disass.el" (18307 +;;;;;; 57861)) ;;; Generated autoloads from emacs-lisp/disass.el (autoload 'disassemble "disass" "\ @@ -7607,7 +7677,7 @@ redefine OBJECT if it is a symbol. ;;;;;; standard-display-g1 standard-display-ascii standard-display-default ;;;;;; standard-display-8bit describe-current-display-table describe-display-table ;;;;;; set-display-table-slot display-table-slot make-display-table) -;;;;;; "disp-table" "disp-table.el" (18088 55082)) +;;;;;; "disp-table" "disp-table.el" (18307 57854)) ;;; Generated autoloads from disp-table.el (autoload 'make-display-table "disp-table" "\ @@ -7723,7 +7793,7 @@ for users who call this function in `.emacs'. ;;;*** ;;;### (autoloads (dissociated-press) "dissociate" "play/dissociate.el" -;;;;;; (18088 55113)) +;;;;;; (18307 57870)) ;;; Generated autoloads from play/dissociate.el (autoload 'dissociated-press "dissociate" "\ @@ -7739,7 +7809,7 @@ Default is 2. ;;;*** -;;;### (autoloads (dnd-protocol-alist) "dnd" "dnd.el" (18088 55082)) +;;;### (autoloads (dnd-protocol-alist) "dnd" "dnd.el" (18307 57854)) ;;; Generated autoloads from dnd.el (defvar dnd-protocol-alist '(("^file:///" . dnd-open-local-file) ("^file://" . dnd-open-file) ("^file:" . dnd-open-local-file) ("^\\(https?\\|ftp\\|file\\|nfs\\)://" . dnd-open-file)) "\ @@ -7760,7 +7830,7 @@ if some action was made, or nil if the URL is ignored.") ;;;*** ;;;### (autoloads (dns-mode-soa-increment-serial dns-mode) "dns-mode" -;;;;;; "textmodes/dns-mode.el" (18088 55119)) +;;;;;; "textmodes/dns-mode.el" (18307 57872)) ;;; Generated autoloads from textmodes/dns-mode.el (autoload 'dns-mode "dns-mode" "\ @@ -7784,20 +7854,38 @@ Locate SOA record and increment the serial field. ;;;*** -;;;### (autoloads (doc-view-mode) "doc-view" "doc-view.el" (18201 -;;;;;; 33325)) +;;;### (autoloads (doc-view-bookmark-jump doc-view-minor-mode doc-view-mode +;;;;;; doc-view-mode-p) "doc-view" "doc-view.el" (18310 28916)) ;;; Generated autoloads from doc-view.el +(autoload 'doc-view-mode-p "doc-view" "\ +Return non-nil if image type TYPE is available for `doc-view'. +Image types are symbols like `dvi', `postscript' or `pdf'. + +\(fn TYPE)" nil nil) + (autoload 'doc-view-mode "doc-view" "\ Major mode in DocView buffers. You can use \\\\[doc-view-toggle-display] to -toggle between display as a set of images and display as text. +toggle between displaying the document or editing it as text. \(fn)" t nil) +(autoload 'doc-view-minor-mode "doc-view" "\ +Toggle Doc view minor mode. +With arg, turn Doc view minor mode on if arg is positive, off otherwise. +See the command `doc-view-mode' for more information on this mode. + +\(fn &optional ARG)" t nil) + +(autoload 'doc-view-bookmark-jump "doc-view" "\ +Not documented + +\(fn BMK)" nil nil) + ;;;*** -;;;### (autoloads (doctor) "doctor" "play/doctor.el" (18088 55113)) +;;;### (autoloads (doctor) "doctor" "play/doctor.el" (18307 57870)) ;;; Generated autoloads from play/doctor.el (autoload 'doctor "doctor" "\ @@ -7807,7 +7895,7 @@ Switch to *doctor* buffer and start giving psychotherapy. ;;;*** -;;;### (autoloads (double-mode) "double" "double.el" (18203 37786)) +;;;### (autoloads (double-mode) "double" "double.el" (18307 57855)) ;;; Generated autoloads from double.el (autoload 'double-mode "double" "\ @@ -7822,7 +7910,7 @@ when pressed twice. See variable `double-map' for details. ;;;*** -;;;### (autoloads (dunnet) "dunnet" "play/dunnet.el" (18088 55113)) +;;;### (autoloads (dunnet) "dunnet" "play/dunnet.el" (18307 57870)) ;;; Generated autoloads from play/dunnet.el (autoload 'dunnet "dunnet" "\ @@ -7833,7 +7921,7 @@ Switch to *dungeon* buffer and start game. ;;;*** ;;;### (autoloads (gnus-earcon-display) "earcon" "gnus/earcon.el" -;;;;;; (18088 55101)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/earcon.el (autoload 'gnus-earcon-display "earcon" "\ @@ -7845,7 +7933,7 @@ Play sounds in message buffers. ;;;### (autoloads (easy-mmode-defsyntax easy-mmode-defmap easy-mmode-define-keymap ;;;;;; define-globalized-minor-mode define-minor-mode) "easy-mmode" -;;;;;; "emacs-lisp/easy-mmode.el" (18201 33326)) +;;;;;; "emacs-lisp/easy-mmode.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/easy-mmode.el (defalias 'easy-mmode-define-minor-mode 'define-minor-mode) @@ -7939,8 +8027,8 @@ CSS contains a list of syntax specifications of the form (CHAR . SYNTAX). ;;;*** ;;;### (autoloads (easy-menu-change easy-menu-create-menu easy-menu-do-define -;;;;;; easy-menu-define) "easymenu" "emacs-lisp/easymenu.el" (18120 -;;;;;; 34750)) +;;;;;; easy-menu-define) "easymenu" "emacs-lisp/easymenu.el" (18317 +;;;;;; 19256)) ;;; Generated autoloads from emacs-lisp/easymenu.el (put 'easy-menu-define 'lisp-indent-function 'defun) @@ -8013,10 +8101,15 @@ whenever this expression's value is non-nil. INCLUDE is an expression; this item is only visible if this expression has a non-nil value. `:included' is an alias for `:visible'. + :label FORM + +FORM is an expression that will be dynamically evaluated and whose +value will be used for the menu entry's text label (the default is NAME). + :suffix FORM FORM is an expression that will be dynamically evaluated and whose -value will be concatenated to the menu entry's NAME. +value will be concatenated to the menu entry's label. :style STYLE @@ -8089,7 +8182,7 @@ To implement dynamic menus, either call this from ;;;;;; ebnf-eps-file ebnf-eps-directory ebnf-spool-region ebnf-spool-buffer ;;;;;; ebnf-spool-file ebnf-spool-directory ebnf-print-region ebnf-print-buffer ;;;;;; ebnf-print-file ebnf-print-directory ebnf-customize) "ebnf2ps" -;;;;;; "progmodes/ebnf2ps.el" (18192 17587)) +;;;;;; "progmodes/ebnf2ps.el" (18307 57871)) ;;; Generated autoloads from progmodes/ebnf2ps.el (autoload 'ebnf-customize "ebnf2ps" "\ @@ -8363,8 +8456,8 @@ See `ebnf-style-database' documentation. ;;;;;; ebrowse-tags-find-declaration-other-window ebrowse-tags-find-definition ;;;;;; ebrowse-tags-view-definition ebrowse-tags-find-declaration ;;;;;; ebrowse-tags-view-declaration ebrowse-member-mode ebrowse-electric-choose-tree -;;;;;; ebrowse-tree-mode) "ebrowse" "progmodes/ebrowse.el" (18197 -;;;;;; 21675)) +;;;;;; ebrowse-tree-mode) "ebrowse" "progmodes/ebrowse.el" (18307 +;;;;;; 57871)) ;;; Generated autoloads from progmodes/ebrowse.el (autoload 'ebrowse-tree-mode "ebrowse" "\ @@ -8515,7 +8608,7 @@ Display statistics for a class tree. ;;;*** ;;;### (autoloads (electric-buffer-list) "ebuff-menu" "ebuff-menu.el" -;;;;;; (18133 2196)) +;;;;;; (18307 57855)) ;;; Generated autoloads from ebuff-menu.el (autoload 'electric-buffer-list "ebuff-menu" "\ @@ -8540,7 +8633,7 @@ Run hooks in `electric-buffer-menu-mode-hook' on entry. ;;;*** ;;;### (autoloads (Electric-command-history-redo-expression) "echistory" -;;;;;; "echistory.el" (18133 2196)) +;;;;;; "echistory.el" (18307 57855)) ;;; Generated autoloads from echistory.el (autoload 'Electric-command-history-redo-expression "echistory" "\ @@ -8552,7 +8645,7 @@ With prefix arg NOCONFIRM, execute current line as-is without editing. ;;;*** ;;;### (autoloads (ecomplete-setup) "ecomplete" "gnus/ecomplete.el" -;;;;;; (18212 21473)) +;;;;;; (18308 19808)) ;;; Generated autoloads from gnus/ecomplete.el (autoload 'ecomplete-setup "ecomplete" "\ @@ -8564,7 +8657,7 @@ Not documented ;;;### (autoloads (edebug-all-forms edebug-all-defs edebug-eval-top-level-form ;;;;;; edebug-basic-spec edebug-all-forms edebug-all-defs) "edebug" -;;;;;; "emacs-lisp/edebug.el" (18197 21672)) +;;;;;; "emacs-lisp/edebug.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/edebug.el (defvar edebug-all-defs nil "\ @@ -8629,15 +8722,15 @@ Toggle edebugging of all forms. ;;;*** ;;;### (autoloads (ediff-documentation ediff-version ediff-revision -;;;;;; ediff-patch-buffer ediff-patch-file run-ediff-from-cvs-buffer -;;;;;; ediff-merge-revisions-with-ancestor ediff-merge-revisions -;;;;;; ediff-merge-buffers-with-ancestor ediff-merge-buffers ediff-merge-files-with-ancestor -;;;;;; ediff-merge-files ediff-regions-linewise ediff-regions-wordwise -;;;;;; ediff-windows-linewise ediff-windows-wordwise ediff-merge-directory-revisions-with-ancestor -;;;;;; ediff-merge-directory-revisions ediff-merge-directories-with-ancestor -;;;;;; ediff-merge-directories ediff-directories3 ediff-directory-revisions -;;;;;; ediff-directories ediff-buffers3 ediff-buffers ediff-backup -;;;;;; ediff-files3 ediff-files) "ediff" "ediff.el" (18120 34749)) +;;;;;; ediff-patch-buffer ediff-patch-file ediff-merge-revisions-with-ancestor +;;;;;; ediff-merge-revisions ediff-merge-buffers-with-ancestor ediff-merge-buffers +;;;;;; ediff-merge-files-with-ancestor ediff-merge-files ediff-regions-linewise +;;;;;; ediff-regions-wordwise ediff-windows-linewise ediff-windows-wordwise +;;;;;; ediff-merge-directory-revisions-with-ancestor ediff-merge-directory-revisions +;;;;;; ediff-merge-directories-with-ancestor ediff-merge-directories +;;;;;; ediff-directories3 ediff-directory-revisions ediff-directories +;;;;;; ediff-buffers3 ediff-buffers ediff-backup ediff-files3 ediff-files) +;;;;;; "ediff" "ediff.el" (18309 50453)) ;;; Generated autoloads from ediff.el (autoload 'ediff-files "ediff" "\ @@ -8813,13 +8906,6 @@ buffer. \(fn &optional FILE STARTUP-HOOKS MERGE-BUFFER-FILE)" t nil) -(autoload 'run-ediff-from-cvs-buffer "ediff" "\ -Run Ediff-merge on appropriate revisions of the selected file. -First run after `M-x cvs-update'. Then place the cursor on a line describing a -file and then run `run-ediff-from-cvs-buffer'. - -\(fn POS)" t nil) - (autoload 'ediff-patch-file "ediff" "\ Run Ediff by patching SOURCE-FILENAME. If optional PATCH-BUF is given, use the patch in that buffer @@ -8869,7 +8955,7 @@ With optional NODE, goes to that node. ;;;*** ;;;### (autoloads (ediff-customize) "ediff-help" "ediff-help.el" -;;;;;; (18202 3993)) +;;;;;; (18307 57855)) ;;; Generated autoloads from ediff-help.el (autoload 'ediff-customize "ediff-help" "\ @@ -8879,7 +8965,7 @@ Not documented ;;;*** -;;;### (autoloads nil "ediff-hook" "ediff-hook.el" (18203 37786)) +;;;### (autoloads nil "ediff-hook" "ediff-hook.el" (18307 57855)) ;;; Generated autoloads from ediff-hook.el (defvar ediff-window-setup-function) @@ -8892,7 +8978,7 @@ Not documented ;;;*** ;;;### (autoloads (ediff-show-registry) "ediff-mult" "ediff-mult.el" -;;;;;; (18169 11930)) +;;;;;; (18307 57855)) ;;; Generated autoloads from ediff-mult.el (autoload 'ediff-show-registry "ediff-mult" "\ @@ -8905,7 +8991,7 @@ Display Ediff's registry. ;;;*** ;;;### (autoloads (ediff-toggle-use-toolbar ediff-toggle-multiframe) -;;;;;; "ediff-util" "ediff-util.el" (18214 4759)) +;;;;;; "ediff-util" "ediff-util.el" (18309 50453)) ;;; Generated autoloads from ediff-util.el (autoload 'ediff-toggle-multiframe "ediff-util" "\ @@ -8926,7 +9012,7 @@ To change the default, set the variable `ediff-use-toolbar-p', which see. ;;;### (autoloads (format-kbd-macro read-kbd-macro edit-named-kbd-macro ;;;;;; edit-last-kbd-macro edit-kbd-macro) "edmacro" "edmacro.el" -;;;;;; (18133 2196)) +;;;;;; (18307 57855)) ;;; Generated autoloads from edmacro.el (defvar edmacro-eight-bits nil "\ @@ -8979,7 +9065,7 @@ or nil, use a compact 80-column format. ;;;*** ;;;### (autoloads (edt-emulation-on edt-set-scroll-margins) "edt" -;;;;;; "emulation/edt.el" (18212 54459)) +;;;;;; "emulation/edt.el" (18307 57862)) ;;; Generated autoloads from emulation/edt.el (autoload 'edt-set-scroll-margins "edt" "\ @@ -8997,7 +9083,7 @@ Turn on EDT Emulation. ;;;*** ;;;### (autoloads (electric-helpify with-electric-help) "ehelp" "ehelp.el" -;;;;;; (18088 55083)) +;;;;;; (18307 57855)) ;;; Generated autoloads from ehelp.el (autoload 'with-electric-help "ehelp" "\ @@ -9034,7 +9120,7 @@ Not documented ;;;*** ;;;### (autoloads (turn-on-eldoc-mode eldoc-mode eldoc-minor-mode-string) -;;;;;; "eldoc" "emacs-lisp/eldoc.el" (18173 8195)) +;;;;;; "eldoc" "emacs-lisp/eldoc.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/eldoc.el (defvar eldoc-minor-mode-string " ElDoc" "\ @@ -9072,8 +9158,8 @@ Emacs Lisp mode) that support Eldoc.") ;;;*** -;;;### (autoloads (elide-head) "elide-head" "elide-head.el" (18088 -;;;;;; 55083)) +;;;### (autoloads (elide-head) "elide-head" "elide-head.el" (18307 +;;;;;; 57855)) ;;; Generated autoloads from elide-head.el (autoload 'elide-head "elide-head" "\ @@ -9089,7 +9175,7 @@ This is suitable as an entry on `find-file-hook' or appropriate mode hooks. ;;;*** ;;;### (autoloads (elint-initialize) "elint" "emacs-lisp/elint.el" -;;;;;; (18173 8195)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/elint.el (autoload 'elint-initialize "elint" "\ @@ -9100,8 +9186,8 @@ Initialize elint. ;;;*** ;;;### (autoloads (elp-results elp-instrument-package elp-instrument-list -;;;;;; elp-instrument-function) "elp" "emacs-lisp/elp.el" (18173 -;;;;;; 8195)) +;;;;;; elp-instrument-function) "elp" "emacs-lisp/elp.el" (18307 +;;;;;; 57861)) ;;; Generated autoloads from emacs-lisp/elp.el (autoload 'elp-instrument-function "elp" "\ @@ -9127,7 +9213,7 @@ For example, to instrument all ELP functions, do the following: (autoload 'elp-results "elp" "\ Display current profiling results. If `elp-reset-after-results' is non-nil, then current profiling -information for all instrumented functions are reset after results are +information for all instrumented functions is reset after results are displayed. \(fn)" t nil) @@ -9135,7 +9221,7 @@ displayed. ;;;*** ;;;### (autoloads (report-emacs-bug) "emacsbug" "mail/emacsbug.el" -;;;;;; (18173 8195)) +;;;;;; (18302 4831)) ;;; Generated autoloads from mail/emacsbug.el (autoload 'report-emacs-bug "emacsbug" "\ @@ -9228,7 +9314,7 @@ Not documented ;;;*** ;;;### (autoloads (encoded-kbd-setup-display) "encoded-kb" "international/encoded-kb.el" -;;;;;; (18200 51265)) +;;;;;; (18307 57867)) ;;; Generated autoloads from international/encoded-kb.el (autoload 'encoded-kbd-setup-display "encoded-kb" "\ @@ -9238,26 +9324,10 @@ DISPLAY may be a display id, a frame, or nil for the selected frame's display. \(fn DISPLAY)" nil nil) -;;;*** - -;;;### (autoloads (encrypt-insert-file-contents encrypt-find-model) -;;;;;; "encrypt" "gnus/encrypt.el" (18212 21482)) -;;; Generated autoloads from gnus/encrypt.el - -(autoload 'encrypt-find-model "encrypt" "\ -Given a filename, find a encrypt-file-alist entry - -\(fn FILENAME)" nil nil) - -(autoload 'encrypt-insert-file-contents "encrypt" "\ -Decrypt FILE into the current buffer. - -\(fn FILE &optional MODEL)" t nil) - ;;;*** ;;;### (autoloads (enriched-decode enriched-encode enriched-mode) -;;;;;; "enriched" "textmodes/enriched.el" (18088 55119)) +;;;;;; "enriched" "textmodes/enriched.el" (18307 57872)) ;;; Generated autoloads from textmodes/enriched.el (autoload 'enriched-mode "enriched" "\ @@ -9288,7 +9358,7 @@ Not documented ;;;*** ;;;### (autoloads (erc-handle-irc-url erc erc-select-read-args) "erc" -;;;;;; "erc/erc.el" (18213 13926)) +;;;;;; "erc/erc.el" (18307 57865)) ;;; Generated autoloads from erc/erc.el (autoload 'erc-select-read-args "erc" "\ @@ -9330,33 +9400,33 @@ Otherwise, connect to HOST:PORT as USER and /join CHANNEL. ;;;*** -;;;### (autoloads nil "erc-autoaway" "erc/erc-autoaway.el" (18088 -;;;;;; 55099)) +;;;### (autoloads nil "erc-autoaway" "erc/erc-autoaway.el" (18307 +;;;;;; 57864)) ;;; Generated autoloads from erc/erc-autoaway.el (autoload 'erc-autoaway-mode "erc-autoaway") ;;;*** -;;;### (autoloads nil "erc-button" "erc/erc-button.el" (18147 59472)) +;;;### (autoloads nil "erc-button" "erc/erc-button.el" (18307 57864)) ;;; Generated autoloads from erc/erc-button.el (autoload 'erc-button-mode "erc-button" nil t) ;;;*** -;;;### (autoloads nil "erc-capab" "erc/erc-capab.el" (18088 55099)) +;;;### (autoloads nil "erc-capab" "erc/erc-capab.el" (18307 57864)) ;;; Generated autoloads from erc/erc-capab.el (autoload 'erc-capab-identify-mode "erc-capab" nil t) ;;;*** -;;;### (autoloads nil "erc-compat" "erc/erc-compat.el" (18147 59472)) +;;;### (autoloads nil "erc-compat" "erc/erc-compat.el" (18307 57864)) ;;; Generated autoloads from erc/erc-compat.el (autoload 'erc-define-minor-mode "erc-compat") ;;;*** ;;;### (autoloads (erc-ctcp-query-DCC pcomplete/erc-mode/DCC erc-cmd-DCC) -;;;;;; "erc-dcc" "erc/erc-dcc.el" (18088 55099)) +;;;;;; "erc-dcc" "erc/erc-dcc.el" (18307 57864)) ;;; Generated autoloads from erc/erc-dcc.el (autoload 'erc-cmd-DCC "erc-dcc" "\ @@ -9388,7 +9458,7 @@ that subcommand. ;;;;;; erc-ezb-add-session erc-ezb-end-of-session-list erc-ezb-init-session-list ;;;;;; erc-ezb-identify erc-ezb-notice-autodetect erc-ezb-lookup-action ;;;;;; erc-ezb-get-login erc-cmd-ezb) "erc-ezbounce" "erc/erc-ezbounce.el" -;;;;;; (18088 55099)) +;;;;;; (18307 57864)) ;;; Generated autoloads from erc/erc-ezbounce.el (autoload 'erc-cmd-ezb "erc-ezbounce" "\ @@ -9450,8 +9520,8 @@ Add EZBouncer convenience functions to ERC. ;;;*** -;;;### (autoloads (erc-fill) "erc-fill" "erc/erc-fill.el" (18088 -;;;;;; 55099)) +;;;### (autoloads (erc-fill) "erc-fill" "erc/erc-fill.el" (18307 +;;;;;; 57864)) ;;; Generated autoloads from erc/erc-fill.el (autoload 'erc-fill-mode "erc-fill" nil t) @@ -9463,15 +9533,15 @@ You can put this on `erc-insert-modify-hook' and/or `erc-send-modify-hook'. ;;;*** -;;;### (autoloads nil "erc-hecomplete" "erc/erc-hecomplete.el" (18088 -;;;;;; 55099)) +;;;### (autoloads nil "erc-hecomplete" "erc/erc-hecomplete.el" (18307 +;;;;;; 57864)) ;;; Generated autoloads from erc/erc-hecomplete.el (autoload 'erc-hecomplete-mode "erc-hecomplete" nil t) ;;;*** ;;;### (autoloads (erc-identd-stop erc-identd-start) "erc-identd" -;;;;;; "erc/erc-identd.el" (18147 59472)) +;;;;;; "erc/erc-identd.el" (18307 57864)) ;;; Generated autoloads from erc/erc-identd.el (autoload 'erc-identd-mode "erc-identd") @@ -9493,7 +9563,7 @@ Not documented ;;;*** ;;;### (autoloads (erc-create-imenu-index) "erc-imenu" "erc/erc-imenu.el" -;;;;;; (18088 55099)) +;;;;;; (18307 57864)) ;;; Generated autoloads from erc/erc-imenu.el (autoload 'erc-create-imenu-index "erc-imenu" "\ @@ -9503,14 +9573,14 @@ Not documented ;;;*** -;;;### (autoloads nil "erc-join" "erc/erc-join.el" (18088 55099)) +;;;### (autoloads nil "erc-join" "erc/erc-join.el" (18307 57864)) ;;; Generated autoloads from erc/erc-join.el (autoload 'erc-autojoin-mode "erc-join" nil t) ;;;*** ;;;### (autoloads (erc-save-buffer-in-logs erc-logging-enabled) "erc-log" -;;;;;; "erc/erc-log.el" (18213 13926)) +;;;;;; "erc/erc-log.el" (18307 57864)) ;;; Generated autoloads from erc/erc-log.el (autoload 'erc-log-mode "erc-log" nil t) @@ -9542,7 +9612,7 @@ You can save every individual message by putting this function on ;;;### (autoloads (erc-delete-dangerous-host erc-add-dangerous-host ;;;;;; erc-delete-keyword erc-add-keyword erc-delete-fool erc-add-fool ;;;;;; erc-delete-pal erc-add-pal) "erc-match" "erc/erc-match.el" -;;;;;; (18088 55100)) +;;;;;; (18307 57864)) ;;; Generated autoloads from erc/erc-match.el (autoload 'erc-match-mode "erc-match") @@ -9588,14 +9658,14 @@ Delete dangerous-host interactively to `erc-dangerous-hosts'. ;;;*** -;;;### (autoloads nil "erc-menu" "erc/erc-menu.el" (18088 55100)) +;;;### (autoloads nil "erc-menu" "erc/erc-menu.el" (18307 57864)) ;;; Generated autoloads from erc/erc-menu.el (autoload 'erc-menu-mode "erc-menu" nil t) ;;;*** ;;;### (autoloads (erc-cmd-WHOLEFT) "erc-netsplit" "erc/erc-netsplit.el" -;;;;;; (18088 55100)) +;;;;;; (18307 57864)) ;;; Generated autoloads from erc/erc-netsplit.el (autoload 'erc-netsplit-mode "erc-netsplit") @@ -9607,7 +9677,7 @@ Show who's gone. ;;;*** ;;;### (autoloads (erc-server-select erc-determine-network) "erc-networks" -;;;;;; "erc/erc-networks.el" (18088 55100)) +;;;;;; "erc/erc-networks.el" (18307 57864)) ;;; Generated autoloads from erc/erc-networks.el (autoload 'erc-determine-network "erc-networks" "\ @@ -9625,7 +9695,7 @@ Interactively select a server to connect to using `erc-server-alist'. ;;;*** ;;;### (autoloads (pcomplete/erc-mode/NOTIFY erc-cmd-NOTIFY) "erc-notify" -;;;;;; "erc/erc-notify.el" (18088 55100)) +;;;;;; "erc/erc-notify.el" (18307 57865)) ;;; Generated autoloads from erc/erc-notify.el (autoload 'erc-notify-mode "erc-notify" nil t) @@ -9643,33 +9713,33 @@ Not documented ;;;*** -;;;### (autoloads nil "erc-page" "erc/erc-page.el" (18088 55100)) +;;;### (autoloads nil "erc-page" "erc/erc-page.el" (18307 57865)) ;;; Generated autoloads from erc/erc-page.el (autoload 'erc-page-mode "erc-page") ;;;*** -;;;### (autoloads nil "erc-pcomplete" "erc/erc-pcomplete.el" (18088 -;;;;;; 55100)) +;;;### (autoloads nil "erc-pcomplete" "erc/erc-pcomplete.el" (18307 +;;;;;; 57865)) ;;; Generated autoloads from erc/erc-pcomplete.el (autoload 'erc-completion-mode "erc-pcomplete" nil t) ;;;*** -;;;### (autoloads nil "erc-replace" "erc/erc-replace.el" (18088 55100)) +;;;### (autoloads nil "erc-replace" "erc/erc-replace.el" (18307 57865)) ;;; Generated autoloads from erc/erc-replace.el (autoload 'erc-replace-mode "erc-replace") ;;;*** -;;;### (autoloads nil "erc-ring" "erc/erc-ring.el" (18088 55100)) +;;;### (autoloads nil "erc-ring" "erc/erc-ring.el" (18307 57865)) ;;; Generated autoloads from erc/erc-ring.el (autoload 'erc-ring-mode "erc-ring" nil t) ;;;*** ;;;### (autoloads (erc-nickserv-identify erc-nickserv-identify-mode) -;;;;;; "erc-services" "erc/erc-services.el" (18088 55100)) +;;;;;; "erc-services" "erc/erc-services.el" (18309 39532)) ;;; Generated autoloads from erc/erc-services.el (autoload 'erc-services-mode "erc-services" nil t) @@ -9686,14 +9756,14 @@ When called interactively, read the password using `read-passwd'. ;;;*** -;;;### (autoloads nil "erc-sound" "erc/erc-sound.el" (18161 20995)) +;;;### (autoloads nil "erc-sound" "erc/erc-sound.el" (18307 57865)) ;;; Generated autoloads from erc/erc-sound.el (autoload 'erc-sound-mode "erc-sound") ;;;*** ;;;### (autoloads (erc-speedbar-browser) "erc-speedbar" "erc/erc-speedbar.el" -;;;;;; (18088 55100)) +;;;;;; (18307 57865)) ;;; Generated autoloads from erc/erc-speedbar.el (autoload 'erc-speedbar-browser "erc-speedbar" "\ @@ -9704,21 +9774,21 @@ This will add a speedbar major display mode. ;;;*** -;;;### (autoloads nil "erc-spelling" "erc/erc-spelling.el" (18088 -;;;;;; 55100)) +;;;### (autoloads nil "erc-spelling" "erc/erc-spelling.el" (18307 +;;;;;; 57865)) ;;; Generated autoloads from erc/erc-spelling.el (autoload 'erc-spelling-mode "erc-spelling" nil t) ;;;*** -;;;### (autoloads nil "erc-stamp" "erc/erc-stamp.el" (18214 4763)) +;;;### (autoloads nil "erc-stamp" "erc/erc-stamp.el" (18307 57865)) ;;; Generated autoloads from erc/erc-stamp.el (autoload 'erc-timestamp-mode "erc-stamp" nil t) ;;;*** ;;;### (autoloads (erc-track-minor-mode) "erc-track" "erc/erc-track.el" -;;;;;; (18213 13926)) +;;;;;; (18307 57865)) ;;; Generated autoloads from erc/erc-track.el (defvar erc-track-minor-mode nil "\ @@ -9741,7 +9811,7 @@ module, otherwise the keybindings will not do anything useful. ;;;*** ;;;### (autoloads (erc-truncate-buffer erc-truncate-buffer-to-size) -;;;;;; "erc-truncate" "erc/erc-truncate.el" (18088 55100)) +;;;;;; "erc-truncate" "erc/erc-truncate.el" (18307 57865)) ;;; Generated autoloads from erc/erc-truncate.el (autoload 'erc-truncate-mode "erc-truncate" nil t) @@ -9761,7 +9831,7 @@ Meant to be used in hooks, like `erc-insert-post-hook'. ;;;*** ;;;### (autoloads (erc-xdcc-add-file) "erc-xdcc" "erc/erc-xdcc.el" -;;;;;; (18088 55100)) +;;;;;; (18307 57865)) ;;; Generated autoloads from erc/erc-xdcc.el (autoload 'erc-xdcc-add-file "erc-xdcc" "\ @@ -9771,8 +9841,8 @@ Add a file to `erc-xdcc-files'. ;;;*** -;;;### (autoloads (eshell-mode) "esh-mode" "eshell/esh-mode.el" (18203 -;;;;;; 37788)) +;;;### (autoloads (eshell-mode) "esh-mode" "eshell/esh-mode.el" (18307 +;;;;;; 57865)) ;;; Generated autoloads from eshell/esh-mode.el (autoload 'eshell-mode "esh-mode" "\ @@ -9784,8 +9854,8 @@ Emacs shell interactive mode. ;;;*** -;;;### (autoloads (eshell-test) "esh-test" "eshell/esh-test.el" (18088 -;;;;;; 55101)) +;;;### (autoloads (eshell-test) "esh-test" "eshell/esh-test.el" (18307 +;;;;;; 57865)) ;;; Generated autoloads from eshell/esh-test.el (autoload 'eshell-test "esh-test" "\ @@ -9795,8 +9865,8 @@ Test Eshell to verify that it works as expected. ;;;*** -;;;### (autoloads (eshell-report-bug eshell-command-result eshell-command -;;;;;; eshell) "eshell" "eshell/eshell.el" (18088 55101)) +;;;### (autoloads (eshell-command-result eshell-command eshell) "eshell" +;;;;;; "eshell/eshell.el" (18307 57865)) ;;; Generated autoloads from eshell/eshell.el (autoload 'eshell "eshell" "\ @@ -9826,12 +9896,7 @@ corresponding to a successful execution. \(fn COMMAND &optional STATUS-VAR)" nil nil) -(autoload 'eshell-report-bug "eshell" "\ -Report a bug in Eshell. -Prompts for the TOPIC. Leaves you in a mail buffer. -Please include any configuration details that might be involved. - -\(fn TOPIC)" t nil) +(define-obsolete-function-alias 'eshell-report-bug 'report-emacs-bug "23.1") ;;;*** @@ -9842,7 +9907,7 @@ Please include any configuration details that might be involved. ;;;;;; visit-tags-table tags-table-mode find-tag-default-function ;;;;;; find-tag-hook tags-add-tables tags-compression-info-list ;;;;;; tags-table-list tags-case-fold-search) "etags" "progmodes/etags.el" -;;;;;; (18201 33327)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/etags.el (defvar tags-file-name nil "\ @@ -10144,7 +10209,7 @@ for \\[find-tag] (which see). ;;;;;; ethio-fidel-to-sera-buffer ethio-fidel-to-sera-region ethio-sera-to-fidel-marker ;;;;;; ethio-sera-to-fidel-mail ethio-sera-to-fidel-mail-or-marker ;;;;;; ethio-sera-to-fidel-buffer ethio-sera-to-fidel-region setup-ethiopic-environment-internal) -;;;;;; "ethio-util" "language/ethio-util.el" (18173 8195)) +;;;;;; "ethio-util" "language/ethio-util.el" (18307 57867)) ;;; Generated autoloads from language/ethio-util.el (autoload 'setup-ethiopic-environment-internal "ethio-util" "\ @@ -10339,7 +10404,7 @@ Transcribe Ethiopic characters in ASCII depending on the file extension. ;;;### (autoloads (eudc-load-eudc eudc-query-form eudc-expand-inline ;;;;;; eudc-get-phone eudc-get-email eudc-set-server) "eudc" "net/eudc.el" -;;;;;; (18203 37788)) +;;;;;; (18307 57870)) ;;; Generated autoloads from net/eudc.el (autoload 'eudc-set-server "eudc" "\ @@ -10395,7 +10460,7 @@ This does nothing except loading eudc by autoload side-effect. ;;;### (autoloads (eudc-display-jpeg-as-button eudc-display-jpeg-inline ;;;;;; eudc-display-sound eudc-display-mail eudc-display-url eudc-display-generic-binary) -;;;;;; "eudc-bob" "net/eudc-bob.el" (18203 37788)) +;;;;;; "eudc-bob" "net/eudc-bob.el" (18307 57869)) ;;; Generated autoloads from net/eudc-bob.el (autoload 'eudc-display-generic-binary "eudc-bob" "\ @@ -10431,7 +10496,7 @@ Display a button for the JPEG DATA. ;;;*** ;;;### (autoloads (eudc-try-bbdb-insert eudc-insert-record-at-point-into-bbdb) -;;;;;; "eudc-export" "net/eudc-export.el" (18088 55111)) +;;;;;; "eudc-export" "net/eudc-export.el" (18307 57869)) ;;; Generated autoloads from net/eudc-export.el (autoload 'eudc-insert-record-at-point-into-bbdb "eudc-export" "\ @@ -10448,7 +10513,7 @@ Call `eudc-insert-record-at-point-into-bbdb' if on a record. ;;;*** ;;;### (autoloads (eudc-edit-hotlist) "eudc-hotlist" "net/eudc-hotlist.el" -;;;;;; (18203 37788)) +;;;;;; (18307 57869)) ;;; Generated autoloads from net/eudc-hotlist.el (autoload 'eudc-edit-hotlist "eudc-hotlist" "\ @@ -10458,8 +10523,8 @@ Edit the hotlist of directory servers in a specialized buffer. ;;;*** -;;;### (autoloads (ewoc-create) "ewoc" "emacs-lisp/ewoc.el" (18088 -;;;;;; 55095)) +;;;### (autoloads (ewoc-create) "ewoc" "emacs-lisp/ewoc.el" (18307 +;;;;;; 57861)) ;;; Generated autoloads from emacs-lisp/ewoc.el (autoload 'ewoc-create "ewoc" "\ @@ -10488,7 +10553,7 @@ fourth arg NOSEP non-nil inhibits this. ;;;### (autoloads (executable-make-buffer-file-executable-if-script-p ;;;;;; executable-self-display executable-set-magic executable-interpret ;;;;;; executable-command-find-posix-p) "executable" "progmodes/executable.el" -;;;;;; (18088 55116)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/executable.el (autoload 'executable-command-find-posix-p "executable" "\ @@ -10531,7 +10596,7 @@ file modes. ;;;### (autoloads (expand-jump-to-next-slot expand-jump-to-previous-slot ;;;;;; expand-abbrev-hook expand-add-abbrevs) "expand" "expand.el" -;;;;;; (18088 55083)) +;;;;;; (18307 57855)) ;;; Generated autoloads from expand.el (autoload 'expand-add-abbrevs "expand" "\ @@ -10580,7 +10645,7 @@ This is used only in conjunction with `expand-add-abbrevs'. ;;;*** -;;;### (autoloads (f90-mode) "f90" "progmodes/f90.el" (18212 46008)) +;;;### (autoloads (f90-mode) "f90" "progmodes/f90.el" (18307 57871)) ;;; Generated autoloads from progmodes/f90.el (autoload 'f90-mode "f90" "\ @@ -10647,7 +10712,7 @@ with no args, if that value is non-nil. ;;;;;; facemenu-remove-all facemenu-remove-face-props facemenu-set-read-only ;;;;;; facemenu-set-intangible facemenu-set-invisible facemenu-set-face-from-menu ;;;;;; facemenu-set-background facemenu-set-foreground facemenu-set-face) -;;;;;; "facemenu" "facemenu.el" (18088 55083)) +;;;;;; "facemenu" "facemenu.el" (18307 57855)) ;;; Generated autoloads from facemenu.el (define-key global-map "\M-o" 'facemenu-keymap) (autoload 'facemenu-keymap "facemenu" "Keymap for face-changing commands." t 'keymap) @@ -10816,7 +10881,7 @@ argument BUFFER-NAME is nil, it defaults to *Colors*. ;;;### (autoloads (feedmail-queue-reminder feedmail-run-the-queue ;;;;;; feedmail-run-the-queue-global-prompt feedmail-run-the-queue-no-prompts -;;;;;; feedmail-send-it) "feedmail" "mail/feedmail.el" (18192 17587)) +;;;;;; feedmail-send-it) "feedmail" "mail/feedmail.el" (18290 13665)) ;;; Generated autoloads from mail/feedmail.el (autoload 'feedmail-send-it "feedmail" "\ @@ -10870,7 +10935,7 @@ you can set `feedmail-queue-reminder-alist' to nil. ;;;*** ;;;### (autoloads (ffap-bindings dired-at-point ffap-at-mouse ffap-menu -;;;;;; find-file-at-point ffap-next) "ffap" "ffap.el" (18169 11931)) +;;;;;; find-file-at-point ffap-next) "ffap" "ffap.el" (18308 19808)) ;;; Generated autoloads from ffap.el (autoload 'ffap-next "ffap" "\ @@ -10929,7 +10994,7 @@ Evaluate the forms in variable `ffap-bindings'. ;;;### (autoloads (file-cache-minibuffer-complete file-cache-add-directory-recursively ;;;;;; file-cache-add-directory-using-locate file-cache-add-directory-using-find ;;;;;; file-cache-add-file file-cache-add-directory-list file-cache-add-directory) -;;;;;; "filecache" "filecache.el" (18169 11931)) +;;;;;; "filecache" "filecache.el" (18307 57855)) ;;; Generated autoloads from filecache.el (autoload 'file-cache-add-directory "filecache" "\ @@ -10982,14 +11047,11 @@ the name is considered already unique; only the second substitution \(directories) is done. \(fn ARG)" t nil) - (define-key minibuffer-local-completion-map [C-tab] 'file-cache-minibuffer-complete) - (define-key minibuffer-local-map [C-tab] 'file-cache-minibuffer-complete) - (define-key minibuffer-local-must-match-map [C-tab] 'file-cache-minibuffer-complete) ;;;*** -;;;### (autoloads (filesets-init) "filesets" "filesets.el" (18197 -;;;;;; 21668)) +;;;### (autoloads (filesets-init) "filesets" "filesets.el" (18307 +;;;;;; 57855)) ;;; Generated autoloads from filesets.el (autoload 'filesets-init "filesets" "\ @@ -11000,15 +11062,15 @@ Set up hooks, load the cache file -- if existing -- and build the menu. ;;;*** -;;;### (autoloads nil "fill" "textmodes/fill.el" (18210 22046)) +;;;### (autoloads nil "fill" "textmodes/fill.el" (18307 57873)) ;;; Generated autoloads from textmodes/fill.el (put 'colon-double-space 'safe-local-variable 'booleanp) ;;;*** -;;;### (autoloads (find-grep-dired find-name-dired find-dired find-grep-options -;;;;;; find-ls-subdir-switches find-ls-option) "find-dired" "find-dired.el" -;;;;;; (18088 55084)) +;;;### (autoloads (find-grep-dired find-name-dired find-dired find-name-arg +;;;;;; find-grep-options find-ls-subdir-switches find-ls-option) +;;;;;; "find-dired" "find-dired.el" (18307 57855)) ;;; Generated autoloads from find-dired.el (defvar find-ls-option (if (eq system-type 'berkeley-unix) '("-ls" . "-gilsb") '("-exec ls -ld {} \\;" . "-ld")) "\ @@ -11034,6 +11096,13 @@ On other systems, the closest you can come is to use `-l'.") (custom-autoload 'find-grep-options "find-dired" t) +(defvar find-name-arg (if read-file-name-completion-ignore-case "-iname" "-name") "\ +*Argument used to specify file name pattern. +If `read-file-name-completion-ignore-case' is non-nil, -iname is used so that +find also ignores case. Otherwise, -name is used.") + +(custom-autoload 'find-name-arg "find-dired" t) + (autoload 'find-dired "find-dired" "\ Run `find' and go into Dired mode on a buffer of the output. The command run (after changing into DIR) is @@ -11069,7 +11138,7 @@ Thus ARG can also contain additional grep options. ;;;### (autoloads (ff-mouse-find-other-file-other-window ff-mouse-find-other-file ;;;;;; ff-find-other-file ff-get-other-file) "find-file" "find-file.el" -;;;;;; (18088 55084)) +;;;;;; (18307 57855)) ;;; Generated autoloads from find-file.el (defvar ff-special-constructs '(("^#\\s *\\(include\\|import\\)\\s +[<\"]\\(.*\\)[>\"]" lambda nil (buffer-substring (match-beginning 2) (match-end 2)))) "\ @@ -11163,7 +11232,7 @@ Visit the file you click on in another window. ;;;;;; find-variable find-variable-noselect find-function-other-frame ;;;;;; find-function-other-window find-function find-function-noselect ;;;;;; find-function-search-for-symbol find-library) "find-func" -;;;;;; "emacs-lisp/find-func.el" (18200 51265)) +;;;;;; "emacs-lisp/find-func.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/find-func.el (autoload 'find-library "find-func" "\ @@ -11317,7 +11386,7 @@ Define some key bindings for the find-function family of functions. ;;;*** ;;;### (autoloads (find-lisp-find-dired-filter find-lisp-find-dired-subdirectories -;;;;;; find-lisp-find-dired) "find-lisp" "find-lisp.el" (18169 11931)) +;;;;;; find-lisp-find-dired) "find-lisp" "find-lisp.el" (18307 57855)) ;;; Generated autoloads from find-lisp.el (autoload 'find-lisp-find-dired "find-lisp" "\ @@ -11338,7 +11407,7 @@ Change the filter on a find-lisp-find-dired buffer to REGEXP. ;;;*** ;;;### (autoloads (finder-by-keyword finder-commentary finder-list-keywords) -;;;;;; "finder" "finder.el" (18169 11931)) +;;;;;; "finder" "finder.el" (18307 57855)) ;;; Generated autoloads from finder.el (autoload 'finder-list-keywords "finder" "\ @@ -11360,7 +11429,7 @@ Find packages matching a given keyword. ;;;*** ;;;### (autoloads (enable-flow-control-on enable-flow-control) "flow-ctrl" -;;;;;; "flow-ctrl.el" (18088 55084)) +;;;;;; "flow-ctrl.el" (18307 57855)) ;;; Generated autoloads from flow-ctrl.el (autoload 'enable-flow-control "flow-ctrl" "\ @@ -11382,7 +11451,7 @@ to get the effect of a C-q. ;;;*** ;;;### (autoloads (fill-flowed fill-flowed-encode) "flow-fill" "gnus/flow-fill.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/flow-fill.el (autoload 'fill-flowed-encode "flow-fill" "\ @@ -11398,7 +11467,7 @@ Not documented ;;;*** ;;;### (autoloads (flymake-mode-off flymake-mode-on flymake-mode) -;;;;;; "flymake" "progmodes/flymake.el" (18120 34752)) +;;;;;; "flymake" "progmodes/flymake.el" (18307 57871)) ;;; Generated autoloads from progmodes/flymake.el (autoload 'flymake-mode "flymake" "\ @@ -11422,7 +11491,7 @@ Turn flymake mode off. ;;;### (autoloads (flyspell-buffer flyspell-region flyspell-mode-off ;;;;;; turn-off-flyspell turn-on-flyspell flyspell-mode flyspell-prog-mode) -;;;;;; "flyspell" "textmodes/flyspell.el" (18187 36841)) +;;;;;; "flyspell" "textmodes/flyspell.el" (18307 57873)) ;;; Generated autoloads from textmodes/flyspell.el (autoload 'flyspell-prog-mode "flyspell" "\ @@ -11492,7 +11561,7 @@ Flyspell whole buffer. ;;;### (autoloads (follow-delete-other-windows-and-split follow-mode ;;;;;; turn-off-follow-mode turn-on-follow-mode) "follow" "follow.el" -;;;;;; (18200 51264)) +;;;;;; (18307 57855)) ;;; Generated autoloads from follow.el (autoload 'turn-on-follow-mode "follow" "\ @@ -11565,8 +11634,8 @@ in your `~/.emacs' file, replacing [f7] by your favourite key: ;;;*** -;;;### (autoloads (footnote-mode) "footnote" "mail/footnote.el" (18088 -;;;;;; 55109)) +;;;### (autoloads (footnote-mode) "footnote" "mail/footnote.el" (18307 +;;;;;; 57868)) ;;; Generated autoloads from mail/footnote.el (autoload 'footnote-mode "footnote" "\ @@ -11587,7 +11656,7 @@ key binding ;;;*** ;;;### (autoloads (forms-find-file-other-window forms-find-file forms-mode) -;;;;;; "forms" "forms.el" (18088 55084)) +;;;;;; "forms" "forms.el" (18307 57855)) ;;; Generated autoloads from forms.el (autoload 'forms-mode "forms" "\ @@ -11624,7 +11693,7 @@ Visit a file in Forms mode in other window. ;;;*** ;;;### (autoloads (fortran-mode) "fortran" "progmodes/fortran.el" -;;;;;; (18212 46008)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/fortran.el (autoload 'fortran-mode "fortran" "\ @@ -11702,7 +11771,7 @@ with no args, if that value is non-nil. ;;;*** ;;;### (autoloads (fortune fortune-to-signature fortune-compile fortune-from-region -;;;;;; fortune-add-fortune) "fortune" "play/fortune.el" (18088 55113)) +;;;;;; fortune-add-fortune) "fortune" "play/fortune.el" (18307 57870)) ;;; Generated autoloads from play/fortune.el (autoload 'fortune-add-fortune "fortune" "\ @@ -11752,7 +11821,7 @@ and choose the directory as the fortune-file. ;;;*** ;;;### (autoloads (gdb-enable-debug gdb) "gdb-ui" "progmodes/gdb-ui.el" -;;;;;; (18197 21675)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/gdb-ui.el (autoload 'gdb "gdb-ui" "\ @@ -11760,7 +11829,6 @@ Run gdb on program FILE in buffer *gud-FILE*. The directory containing FILE becomes the initial working directory and source-file directory for your debugger. - If `gdb-many-windows' is nil (the default value) then gdb just pops up the GUD buffer unless `gdb-show-main' is t. In this case it starts with two windows: one displaying the GUD buffer and the @@ -11823,8 +11891,8 @@ Non-nil means record the process input and output in `gdb-debug-log'.") ;;;*** ;;;### (autoloads (generic-make-keywords-list generic-mode generic-mode-internal -;;;;;; define-generic-mode) "generic" "emacs-lisp/generic.el" (18173 -;;;;;; 8195)) +;;;;;; define-generic-mode) "generic" "emacs-lisp/generic.el" (18307 +;;;;;; 57861)) ;;; Generated autoloads from emacs-lisp/generic.el (defvar generic-mode-list nil "\ @@ -11899,7 +11967,7 @@ regular expression that can be used as an element of ;;;*** ;;;### (autoloads (glasses-mode) "glasses" "progmodes/glasses.el" -;;;;;; (18088 55116)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/glasses.el (autoload 'glasses-mode "glasses" "\ @@ -11913,7 +11981,7 @@ at places they belong to. ;;;### (autoloads (gmm-tool-bar-from-list gmm-widget-p gmm-error ;;;;;; gmm-message gmm-regexp-concat) "gmm-utils" "gnus/gmm-utils.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/gmm-utils.el (autoload 'gmm-regexp-concat "gmm-utils" "\ @@ -11966,7 +12034,7 @@ DEFAULT-MAP specifies the default key map for ICON-LIST. ;;;*** ;;;### (autoloads (gnus gnus-other-frame gnus-slave gnus-no-server -;;;;;; gnus-slave-no-server) "gnus" "gnus/gnus.el" (18212 46007)) +;;;;;; gnus-slave-no-server) "gnus" "gnus/gnus.el" (18307 57866)) ;;; Generated autoloads from gnus/gnus.el (when (fboundp 'custom-autoload) (custom-autoload 'gnus-select-method "gnus")) @@ -12019,7 +12087,7 @@ prompt the user for the name of an NNTP server to use. ;;;;;; gnus-agent-get-undownloaded-list gnus-agent-delete-group ;;;;;; gnus-agent-rename-group gnus-agent-possibly-save-gcc gnus-agentize ;;;;;; gnus-slave-unplugged gnus-plugged gnus-unplugged) "gnus-agent" -;;;;;; "gnus/gnus-agent.el" (18212 46006)) +;;;;;; "gnus/gnus-agent.el" (18307 57865)) ;;; Generated autoloads from gnus/gnus-agent.el (autoload 'gnus-unplugged "gnus-agent" "\ @@ -12110,7 +12178,7 @@ If CLEAN, obsolete (ignore). ;;;*** ;;;### (autoloads (gnus-article-prepare-display) "gnus-art" "gnus/gnus-art.el" -;;;;;; (18212 46006)) +;;;;;; (18310 28916)) ;;; Generated autoloads from gnus/gnus-art.el (autoload 'gnus-article-prepare-display "gnus-art" "\ @@ -12121,7 +12189,7 @@ Make the current buffer look like a nice article. ;;;*** ;;;### (autoloads (gnus-audio-play) "gnus-audio" "gnus/gnus-audio.el" -;;;;;; (18088 55102)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/gnus-audio.el (autoload 'gnus-audio-play "gnus-audio" "\ @@ -12132,7 +12200,7 @@ Play a sound FILE through the speaker. ;;;*** ;;;### (autoloads (gnus-bookmark-bmenu-list gnus-bookmark-jump gnus-bookmark-set) -;;;;;; "gnus-bookmark" "gnus/gnus-bookmark.el" (18212 21481)) +;;;;;; "gnus-bookmark" "gnus/gnus-bookmark.el" (18308 19808)) ;;; Generated autoloads from gnus/gnus-bookmark.el (autoload 'gnus-bookmark-set "gnus-bookmark" "\ @@ -12157,8 +12225,8 @@ deletion, or > if it is flagged for displaying. ;;;### (autoloads (gnus-cache-delete-group gnus-cache-rename-group ;;;;;; gnus-cache-generate-nov-databases gnus-cache-generate-active -;;;;;; gnus-jog-cache) "gnus-cache" "gnus/gnus-cache.el" (18212 -;;;;;; 46006)) +;;;;;; gnus-jog-cache) "gnus-cache" "gnus/gnus-cache.el" (18307 +;;;;;; 57865)) ;;; Generated autoloads from gnus/gnus-cache.el (autoload 'gnus-jog-cache "gnus-cache" "\ @@ -12200,7 +12268,7 @@ supported. ;;;*** ;;;### (autoloads (gnus-delay-initialize gnus-delay-send-queue gnus-delay-article) -;;;;;; "gnus-delay" "gnus/gnus-delay.el" (18212 46006)) +;;;;;; "gnus-delay" "gnus/gnus-delay.el" (18307 57865)) ;;; Generated autoloads from gnus/gnus-delay.el (autoload 'gnus-delay-article "gnus-delay" "\ @@ -12236,7 +12304,7 @@ Checking delayed messages is skipped if optional arg NO-CHECK is non-nil. ;;;*** ;;;### (autoloads (gnus-user-format-function-D gnus-user-format-function-d) -;;;;;; "gnus-diary" "gnus/gnus-diary.el" (18212 46006)) +;;;;;; "gnus-diary" "gnus/gnus-diary.el" (18307 57865)) ;;; Generated autoloads from gnus/gnus-diary.el (autoload 'gnus-user-format-function-d "gnus-diary" "\ @@ -12252,18 +12320,18 @@ Not documented ;;;*** ;;;### (autoloads (turn-on-gnus-dired-mode) "gnus-dired" "gnus/gnus-dired.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/gnus-dired.el (autoload 'turn-on-gnus-dired-mode "gnus-dired" "\ Convenience method to turn on gnus-dired-mode. -\(fn)" nil nil) +\(fn)" t nil) ;;;*** ;;;### (autoloads (gnus-draft-reminder) "gnus-draft" "gnus/gnus-draft.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/gnus-draft.el (autoload 'gnus-draft-reminder "gnus-draft" "\ @@ -12275,8 +12343,8 @@ Reminder user if there are unsent drafts. ;;;### (autoloads (gnus-convert-png-to-face gnus-convert-face-to-png ;;;;;; gnus-face-from-file gnus-x-face-from-file gnus-insert-random-x-face-header -;;;;;; gnus-random-x-face) "gnus-fun" "gnus/gnus-fun.el" (18212 -;;;;;; 46006)) +;;;;;; gnus-random-x-face) "gnus-fun" "gnus/gnus-fun.el" (18307 +;;;;;; 57865)) ;;; Generated autoloads from gnus/gnus-fun.el (autoload 'gnus-random-x-face "gnus-fun" "\ @@ -12321,7 +12389,7 @@ FILE should be a PNG file that's 48x48 and smaller than or equal to ;;;*** ;;;### (autoloads (gnus-fetch-group-other-frame gnus-fetch-group) -;;;;;; "gnus-group" "gnus/gnus-group.el" (18212 46006)) +;;;;;; "gnus-group" "gnus/gnus-group.el" (18310 28916)) ;;; Generated autoloads from gnus/gnus-group.el (autoload 'gnus-fetch-group "gnus-group" "\ @@ -12339,7 +12407,7 @@ Pop up a frame and enter GROUP. ;;;*** ;;;### (autoloads (gnus-batch-score) "gnus-kill" "gnus/gnus-kill.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/gnus-kill.el (defalias 'gnus-batch-kill 'gnus-batch-score) @@ -12354,7 +12422,7 @@ Usage: emacs -batch -l ~/.emacs -l gnus -f gnus-batch-score ;;;### (autoloads (gnus-mailing-list-mode gnus-mailing-list-insinuate ;;;;;; turn-on-gnus-mailing-list-mode) "gnus-ml" "gnus/gnus-ml.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/gnus-ml.el (autoload 'turn-on-gnus-mailing-list-mode "gnus-ml" "\ @@ -12379,7 +12447,7 @@ Minor mode for providing mailing-list commands. ;;;### (autoloads (gnus-group-split-fancy gnus-group-split gnus-group-split-update ;;;;;; gnus-group-split-setup) "gnus-mlspl" "gnus/gnus-mlspl.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/gnus-mlspl.el (autoload 'gnus-group-split-setup "gnus-mlspl" "\ @@ -12480,7 +12548,7 @@ Calling (gnus-group-split-fancy nil nil \"mail.others\") returns: ;;;*** ;;;### (autoloads (gnus-change-server) "gnus-move" "gnus/gnus-move.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/gnus-move.el (autoload 'gnus-change-server "gnus-move" "\ @@ -12492,7 +12560,7 @@ Update the .newsrc.eld file to reflect the change of nntp server. ;;;*** ;;;### (autoloads (gnus-button-reply gnus-button-mailto gnus-msg-mail) -;;;;;; "gnus-msg" "gnus/gnus-msg.el" (18212 46006)) +;;;;;; "gnus-msg" "gnus/gnus-msg.el" (18307 57865)) ;;; Generated autoloads from gnus/gnus-msg.el (autoload 'gnus-msg-mail "gnus-msg" "\ @@ -12517,7 +12585,7 @@ Like `message-reply'. ;;;*** ;;;### (autoloads (gnus-nocem-load-cache gnus-nocem-scan-groups) -;;;;;; "gnus-nocem" "gnus/gnus-nocem.el" (18212 46006)) +;;;;;; "gnus-nocem" "gnus/gnus-nocem.el" (18307 57865)) ;;; Generated autoloads from gnus/gnus-nocem.el (autoload 'gnus-nocem-scan-groups "gnus-nocem" "\ @@ -12534,7 +12602,7 @@ Load the NoCeM cache. ;;;### (autoloads (gnus-treat-newsgroups-picon gnus-treat-mail-picon ;;;;;; gnus-treat-from-picon) "gnus-picon" "gnus/gnus-picon.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57865)) ;;; Generated autoloads from gnus/gnus-picon.el (autoload 'gnus-treat-from-picon "gnus-picon" "\ @@ -12561,7 +12629,7 @@ If picons are already displayed, remove them. ;;;;;; gnus-sorted-nintersection gnus-sorted-range-intersection ;;;;;; gnus-sorted-intersection gnus-intersection gnus-sorted-complement ;;;;;; gnus-sorted-ndifference gnus-sorted-difference) "gnus-range" -;;;;;; "gnus/gnus-range.el" (18212 46006)) +;;;;;; "gnus/gnus-range.el" (18307 57865)) ;;; Generated autoloads from gnus/gnus-range.el (autoload 'gnus-sorted-difference "gnus-range" "\ @@ -12629,7 +12697,7 @@ Add NUM into sorted LIST by side effect. ;;;*** ;;;### (autoloads (gnus-registry-install-hooks gnus-registry-initialize) -;;;;;; "gnus-registry" "gnus/gnus-registry.el" (18212 46006)) +;;;;;; "gnus-registry" "gnus/gnus-registry.el" (18307 57865)) ;;; Generated autoloads from gnus/gnus-registry.el (autoload 'gnus-registry-initialize "gnus-registry" "\ @@ -12645,8 +12713,8 @@ Install the registry hooks. ;;;*** ;;;### (autoloads (gnus-sieve-article-add-rule gnus-sieve-generate -;;;;;; gnus-sieve-update) "gnus-sieve" "gnus/gnus-sieve.el" (18088 -;;;;;; 55103)) +;;;;;; gnus-sieve-update) "gnus-sieve" "gnus/gnus-sieve.el" (18307 +;;;;;; 57866)) ;;; Generated autoloads from gnus/gnus-sieve.el (autoload 'gnus-sieve-update "gnus-sieve" "\ @@ -12674,7 +12742,7 @@ Not documented ;;;*** ;;;### (autoloads (gnus-batch-brew-soup) "gnus-soup" "gnus/gnus-soup.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/gnus-soup.el (autoload 'gnus-batch-brew-soup "gnus-soup" "\ @@ -12694,7 +12762,7 @@ Note -- this function hasn't been implemented yet. ;;;*** ;;;### (autoloads (gnus-update-format) "gnus-spec" "gnus/gnus-spec.el" -;;;;;; (18212 46006)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/gnus-spec.el (autoload 'gnus-update-format "gnus-spec" "\ @@ -12705,8 +12773,8 @@ Update the format specification near point. ;;;*** ;;;### (autoloads (gnus-fixup-nnimap-unread-after-getting-new-news -;;;;;; gnus-declare-backend) "gnus-start" "gnus/gnus-start.el" (18212 -;;;;;; 46006)) +;;;;;; gnus-declare-backend) "gnus-start" "gnus/gnus-start.el" (18307 +;;;;;; 57866)) ;;; Generated autoloads from gnus/gnus-start.el (autoload 'gnus-declare-backend "gnus-start" "\ @@ -12722,7 +12790,7 @@ Not documented ;;;*** ;;;### (autoloads (gnus-add-configuration) "gnus-win" "gnus/gnus-win.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/gnus-win.el (autoload 'gnus-add-configuration "gnus-win" "\ @@ -12732,7 +12800,7 @@ Add the window configuration CONF to `gnus-buffer-configuration'. ;;;*** -;;;### (autoloads (gomoku) "gomoku" "play/gomoku.el" (18088 55114)) +;;;### (autoloads (gomoku) "gomoku" "play/gomoku.el" (18307 57870)) ;;; Generated autoloads from play/gomoku.el (autoload 'gomoku "gomoku" "\ @@ -12759,7 +12827,7 @@ Use \\[describe-mode] for more info. ;;;*** ;;;### (autoloads (goto-address goto-address-at-point) "goto-addr" -;;;;;; "net/goto-addr.el" (18088 55111)) +;;;;;; "net/goto-addr.el" (18307 57870)) ;;; Generated autoloads from net/goto-addr.el (define-obsolete-function-alias 'goto-address-at-mouse 'goto-address-at-point "22.1") @@ -12789,7 +12857,7 @@ Also fontifies the buffer appropriately (see `goto-address-fontify-p' and ;;;### (autoloads (rgrep lgrep grep-find grep grep-mode grep-compute-defaults ;;;;;; grep-process-setup grep-setup-hook grep-find-command grep-command -;;;;;; grep-window-height) "grep" "progmodes/grep.el" (18135 53075)) +;;;;;; grep-window-height) "grep" "progmodes/grep.el" (18301 42252)) ;;; Generated autoloads from progmodes/grep.el (defvar grep-window-height nil "\ @@ -12831,6 +12899,11 @@ This variable's value takes effect when `grep-compute-defaults' is called.") The default find program for `grep-find-command'. This variable's value takes effect when `grep-compute-defaults' is called.") +(defvar xargs-program "xargs" "\ +The default xargs program for `grep-find-command'. +See `grep-find-use-xargs'. +This variable's value takes effect when `grep-compute-defaults' is called.") + (defvar grep-find-use-xargs nil "\ Non-nil means that `grep-find' uses the `xargs' utility by default. If `exec', use `find -exec'. @@ -12862,19 +12935,19 @@ Sets `grep-last-buffer' and `compilation-window-height'. (autoload 'grep "grep" "\ Run grep, with user-specified args, and collect output in a buffer. While grep runs asynchronously, you can use \\[next-error] (M-x next-error), -or \\\\[compile-goto-error] in the grep output buffer, to go to the lines -where grep found matches. +or \\\\[compile-goto-error] in the grep output buffer, to go to the lines where grep +found matches. For doing a recursive `grep', see the `rgrep' command. For running `grep' in a specific directory, see `lgrep'. -This command uses a special history list for its COMMAND-ARGS, so you can -easily repeat a grep command. +This command uses a special history list for its COMMAND-ARGS, so you +can easily repeat a grep command. A prefix argument says to default the argument based upon the current tag the cursor is over, substituting it into the last grep command -in the grep command history (or into `grep-command' -if that history list is empty). +in the grep command history (or into `grep-command' if that history +list is empty). \(fn COMMAND-ARGS)" t nil) @@ -12902,8 +12975,8 @@ before it is executed. With two \\[universal-argument] prefixes, directly edit and run `grep-command'. Collect output in a buffer. While grep runs asynchronously, you -can use \\[next-error] (M-x next-error), or \\\\[compile-goto-error] -in the grep output buffer, to go to the lines where grep found matches. +can use \\[next-error] (M-x next-error), or \\\\[compile-goto-error] in the grep output buffer, +to go to the lines where grep found matches. This command shares argument histories with \\[rgrep] and \\[grep]. @@ -12920,8 +12993,8 @@ before it is executed. With two \\[universal-argument] prefixes, directly edit and run `grep-find-command'. Collect output in a buffer. While find runs asynchronously, you -can use \\[next-error] (M-x next-error), or \\\\[compile-goto-error] -in the grep output buffer, to go to the lines where grep found matches. +can use \\[next-error] (M-x next-error), or \\\\[compile-goto-error] in the grep output buffer, +to go to the lines where grep found matches. This command shares argument histories with \\[lgrep] and \\[grep-find]. @@ -12929,7 +13002,7 @@ This command shares argument histories with \\[lgrep] and \\[grep-find]. ;;;*** -;;;### (autoloads (gs-load-image) "gs" "gs.el" (18088 55084)) +;;;### (autoloads (gs-load-image) "gs" "gs.el" (18307 57855)) ;;; Generated autoloads from gs.el (autoload 'gs-load-image "gs" "\ @@ -12943,22 +13016,13 @@ the form \"WINDOW-ID PIXMAP-ID\". Value is non-nil if successful. ;;;*** ;;;### (autoloads (gdb-script-mode jdb pdb perldb xdb dbx sdb gud-gdb) -;;;;;; "gud" "progmodes/gud.el" (18214 4763)) +;;;;;; "gud" "progmodes/gud.el" (18307 57871)) ;;; Generated autoloads from progmodes/gud.el (autoload 'gud-gdb "gud" "\ Run gdb on program FILE in buffer *gud-FILE*. The directory containing FILE becomes the initial working -directory and source-file directory for your debugger. By -default this command starts GDB using a graphical interface. See -`gdba' for more information. - -To run GDB in text command mode, replace the GDB \"--annotate=3\" -option with \"--fullname\" either in the minibuffer for the -current Emacs session, or the custom variable -`gud-gdb-command-name' for all future sessions. You need to use -text command mode to debug multiple programs within one Emacs -session. +directory and source-file directory for your debugger. \(fn COMMAND-LINE)" t nil) @@ -13026,8 +13090,8 @@ Major mode for editing GDB scripts ;;;*** -;;;### (autoloads (handwrite) "handwrite" "play/handwrite.el" (18202 -;;;;;; 4002)) +;;;### (autoloads (handwrite) "handwrite" "play/handwrite.el" (18307 +;;;;;; 57870)) ;;; Generated autoloads from play/handwrite.el (autoload 'handwrite "handwrite" "\ @@ -13074,8 +13138,8 @@ to be updated. ;;;### (autoloads (mail-check-payment mail-add-payment-async mail-add-payment ;;;;;; hashcash-verify-payment hashcash-insert-payment-async hashcash-insert-payment) -;;;;;; "hashcash" "gnus/hashcash.el" (18212 21477)) -;;; Generated autoloads from gnus/hashcash.el +;;;;;; "hashcash" "mail/hashcash.el" (18308 19808)) +;;; Generated autoloads from mail/hashcash.el (autoload 'hashcash-insert-payment "hashcash" "\ Insert X-Payment and X-Hashcash headers with a payment for ARG @@ -13119,7 +13183,7 @@ Prefix arg sets default accept amount temporarily. ;;;### (autoloads (scan-buf-previous-region scan-buf-next-region ;;;;;; scan-buf-move-to-region help-at-pt-display-when-idle help-at-pt-set-timer ;;;;;; help-at-pt-cancel-timer display-local-help help-at-pt-kbd-string -;;;;;; help-at-pt-string) "help-at-pt" "help-at-pt.el" (18088 55084)) +;;;;;; help-at-pt-string) "help-at-pt" "help-at-pt.el" (18307 57855)) ;;; Generated autoloads from help-at-pt.el (autoload 'help-at-pt-string "help-at-pt" "\ @@ -13249,7 +13313,7 @@ different regions. With numeric argument ARG, behaves like ;;;### (autoloads (describe-categories describe-syntax describe-variable ;;;;;; variable-at-point describe-function-1 describe-simplify-lib-file-name ;;;;;; help-C-file-name describe-function) "help-fns" "help-fns.el" -;;;;;; (18201 33325)) +;;;;;; (18307 57855)) ;;; Generated autoloads from help-fns.el (autoload 'describe-function "help-fns" "\ @@ -13307,7 +13371,7 @@ BUFFER should be a buffer or a buffer name. ;;;*** ;;;### (autoloads (three-step-help) "help-macro" "help-macro.el" -;;;;;; (18088 55084)) +;;;;;; (18307 57855)) ;;; Generated autoloads from help-macro.el (defvar three-step-help nil "\ @@ -13322,8 +13386,9 @@ A value of nil means skip the middle step, so that ;;;*** ;;;### (autoloads (help-xref-on-pp help-insert-xref-button help-xref-button -;;;;;; help-make-xrefs help-setup-xref help-mode-finish help-mode-setup -;;;;;; help-mode) "help-mode" "help-mode.el" (18120 34749)) +;;;;;; help-make-xrefs help-buffer help-setup-xref help-mode-finish +;;;;;; help-mode-setup help-mode) "help-mode" "help-mode.el" (18307 +;;;;;; 57856)) ;;; Generated autoloads from help-mode.el (autoload 'help-mode "help-mode" "\ @@ -13358,6 +13423,11 @@ restore it properly when going back. \(fn ITEM INTERACTIVE-P)" nil nil) +(autoload 'help-buffer "help-mode" "\ +Not documented + +\(fn)" nil nil) + (autoload 'help-make-xrefs "help-mode" "\ Parse and hyperlink documentation cross-references in the given BUFFER. @@ -13406,7 +13476,7 @@ Add xrefs for symbols in `pp's output between FROM and TO. ;;;*** ;;;### (autoloads (Helper-help Helper-describe-bindings) "helper" -;;;;;; "emacs-lisp/helper.el" (18088 55096)) +;;;;;; "emacs-lisp/helper.el" (18302 4831)) ;;; Generated autoloads from emacs-lisp/helper.el (autoload 'Helper-describe-bindings "helper" "\ @@ -13422,7 +13492,7 @@ Provide help for current mode. ;;;*** ;;;### (autoloads (hexlify-buffer hexl-find-file hexl-mode) "hexl" -;;;;;; "hexl.el" (18211 32385)) +;;;;;; "hexl.el" (18307 57856)) ;;; Generated autoloads from hexl.el (autoload 'hexl-mode "hexl" "\ @@ -13519,7 +13589,7 @@ This discards the buffer's undo information. ;;;### (autoloads (hi-lock-write-interactive-patterns hi-lock-unface-buffer ;;;;;; hi-lock-face-phrase-buffer hi-lock-face-buffer hi-lock-line-face-buffer ;;;;;; global-hi-lock-mode hi-lock-mode) "hi-lock" "hi-lock.el" -;;;;;; (18169 11931)) +;;;;;; (18307 57856)) ;;; Generated autoloads from hi-lock.el (autoload 'hi-lock-mode "hi-lock" "\ @@ -13649,7 +13719,7 @@ be found in variable `hi-lock-interactive-patterns'. ;;;*** ;;;### (autoloads (hide-ifdef-lines hide-ifdef-read-only hide-ifdef-initially -;;;;;; hide-ifdef-mode) "hideif" "progmodes/hideif.el" (18088 55116)) +;;;;;; hide-ifdef-mode) "hideif" "progmodes/hideif.el" (18307 57871)) ;;; Generated autoloads from progmodes/hideif.el (autoload 'hide-ifdef-mode "hideif" "\ @@ -13704,7 +13774,7 @@ how the hiding is done: ;;;*** ;;;### (autoloads (turn-off-hideshow hs-minor-mode) "hideshow" "progmodes/hideshow.el" -;;;;;; (18128 32656)) +;;;;;; (18302 4831)) ;;; Generated autoloads from progmodes/hideshow.el (defvar hs-special-modes-alist '((c-mode "{" "}" "/[*/]" nil hs-c-like-adjust-block-beginning) (c++-mode "{" "}" "/[*/]" nil hs-c-like-adjust-block-beginning) (bibtex-mode ("^@\\S(*\\(\\s(\\)" 1)) (java-mode "{" "}" "/[*/]" nil hs-c-like-adjust-block-beginning)) "\ @@ -13767,7 +13837,7 @@ Unconditionally turn off `hs-minor-mode'. ;;;;;; highlight-compare-buffers highlight-changes-rotate-faces ;;;;;; highlight-changes-previous-change highlight-changes-next-change ;;;;;; highlight-changes-mode highlight-changes-remove-highlight) -;;;;;; "hilit-chg" "hilit-chg.el" (18120 34749)) +;;;;;; "hilit-chg" "hilit-chg.el" (18307 57856)) ;;; Generated autoloads from hilit-chg.el (autoload 'highlight-changes-remove-highlight "hilit-chg" "\ @@ -13897,7 +13967,7 @@ variable `highlight-changes-global-changes-existing-buffers' is non-nil). ;;;;;; hippie-expand-ignore-buffers hippie-expand-max-buffers hippie-expand-no-restriction ;;;;;; hippie-expand-dabbrev-as-symbol hippie-expand-dabbrev-skip-space ;;;;;; hippie-expand-verbose hippie-expand-try-functions-list) "hippie-exp" -;;;;;; "hippie-exp.el" (18088 55085)) +;;;;;; "hippie-exp.el" (18307 57856)) ;;; Generated autoloads from hippie-exp.el (defvar hippie-expand-try-functions-list '(try-complete-file-name-partially try-complete-file-name try-expand-all-abbrevs try-expand-list try-expand-line try-expand-dabbrev try-expand-dabbrev-all-buffers try-expand-dabbrev-from-kill try-complete-lisp-symbol-partially try-complete-lisp-symbol) "\ @@ -13970,7 +14040,7 @@ argument VERBOSE non-nil makes the function verbose. ;;;*** ;;;### (autoloads (global-hl-line-mode hl-line-mode) "hl-line" "hl-line.el" -;;;;;; (18088 55085)) +;;;;;; (18307 57856)) ;;; Generated autoloads from hl-line.el (autoload 'hl-line-mode "hl-line" "\ @@ -14011,7 +14081,7 @@ Global-Hl-Line mode uses the functions `global-hl-line-unhighlight' and ;;;*** ;;;### (autoloads (list-holidays holidays) "holidays" "calendar/holidays.el" -;;;;;; (18157 34340)) +;;;;;; (18307 57860)) ;;; Generated autoloads from calendar/holidays.el (autoload 'holidays "holidays" "\ @@ -14045,10 +14115,12 @@ The optional LABEL is used to label the buffer created. \(fn Y1 Y2 &optional L LABEL)" t nil) +(defalias 'holiday-list 'list-holidays) + ;;;*** -;;;### (autoloads (html2text) "html2text" "gnus/html2text.el" (18212 -;;;;;; 46007)) +;;;### (autoloads (html2text) "html2text" "gnus/html2text.el" (18307 +;;;;;; 57866)) ;;; Generated autoloads from gnus/html2text.el (autoload 'html2text "html2text" "\ @@ -14080,7 +14152,7 @@ Convert HTML to plain text in the current buffer. ;;;;;; ibuffer-backward-filter-group ibuffer-forward-filter-group ;;;;;; ibuffer-toggle-filter-group ibuffer-mouse-toggle-filter-group ;;;;;; ibuffer-interactive-filter-by-mode ibuffer-mouse-filter-by-mode -;;;;;; ibuffer-auto-mode) "ibuf-ext" "ibuf-ext.el" (18208 48750)) +;;;;;; ibuffer-auto-mode) "ibuf-ext" "ibuf-ext.el" (18307 57856)) ;;; Generated autoloads from ibuf-ext.el (autoload 'ibuffer-auto-mode "ibuf-ext" "\ @@ -14442,8 +14514,8 @@ defaults to one. ;;;*** ;;;### (autoloads (define-ibuffer-filter define-ibuffer-op define-ibuffer-sorter -;;;;;; define-ibuffer-column) "ibuf-macs" "ibuf-macs.el" (18088 -;;;;;; 55085)) +;;;;;; define-ibuffer-column) "ibuf-macs" "ibuf-macs.el" (18307 +;;;;;; 57856)) ;;; Generated autoloads from ibuf-macs.el (autoload 'define-ibuffer-column "ibuf-macs" "\ @@ -14532,7 +14604,7 @@ bound to the current value of the filter. ;;;*** ;;;### (autoloads (ibuffer ibuffer-other-window ibuffer-list-buffers) -;;;;;; "ibuffer" "ibuffer.el" (18120 34749)) +;;;;;; "ibuffer" "ibuffer.el" (18307 57856)) ;;; Generated autoloads from ibuffer.el (autoload 'ibuffer-list-buffers "ibuffer" "\ @@ -14573,7 +14645,7 @@ FORMATS is the value to use for `ibuffer-formats'. ;;;### (autoloads (icalendar-import-buffer icalendar-import-file ;;;;;; icalendar-export-region icalendar-export-file) "icalendar" -;;;;;; "calendar/icalendar.el" (18173 8195)) +;;;;;; "calendar/icalendar.el" (18317 7567)) ;;; Generated autoloads from calendar/icalendar.el (autoload 'icalendar-export-file "icalendar" "\ @@ -14625,8 +14697,8 @@ buffer `*icalendar-errors*'. ;;;*** -;;;### (autoloads (icomplete-mode) "icomplete" "icomplete.el" (18120 -;;;;;; 34749)) +;;;### (autoloads (icomplete-mode) "icomplete" "icomplete.el" (18307 +;;;;;; 57856)) ;;; Generated autoloads from icomplete.el (defvar icomplete-mode nil "\ @@ -14647,7 +14719,7 @@ otherwise turn it off. ;;;*** -;;;### (autoloads (icon-mode) "icon" "progmodes/icon.el" (18088 55116)) +;;;### (autoloads (icon-mode) "icon" "progmodes/icon.el" (18307 57871)) ;;; Generated autoloads from progmodes/icon.el (autoload 'icon-mode "icon" "\ @@ -14688,7 +14760,7 @@ with no args, if that value is non-nil. ;;;*** ;;;### (autoloads (idlwave-shell) "idlw-shell" "progmodes/idlw-shell.el" -;;;;;; (18201 33329)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/idlw-shell.el (autoload 'idlwave-shell "idlw-shell" "\ @@ -14714,7 +14786,7 @@ See also the variable `idlwave-shell-prompt-pattern'. ;;;*** ;;;### (autoloads (idlwave-mode) "idlwave" "progmodes/idlwave.el" -;;;;;; (18197 21676)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/idlwave.el (autoload 'idlwave-mode "idlwave" "\ @@ -14849,8 +14921,8 @@ The main features of this mode are ;;;;;; ido-find-alternate-file ido-find-file-other-window ido-find-file ;;;;;; ido-find-file-in-dir ido-switch-buffer-other-frame ido-insert-buffer ;;;;;; ido-kill-buffer ido-display-buffer ido-switch-buffer-other-window -;;;;;; ido-switch-buffer ido-mode ido-mode) "ido" "ido.el" (18169 -;;;;;; 11931)) +;;;;;; ido-switch-buffer ido-mode ido-mode) "ido" "ido.el" (18302 +;;;;;; 4831)) ;;; Generated autoloads from ido.el (defvar ido-mode nil "\ @@ -15111,7 +15183,7 @@ DEF, if non-nil, is the default value. ;;;*** -;;;### (autoloads (ielm) "ielm" "ielm.el" (18214 4479)) +;;;### (autoloads (ielm) "ielm" "ielm.el" (18307 57856)) ;;; Generated autoloads from ielm.el (add-hook 'same-window-buffer-names "*ielm*") @@ -15124,7 +15196,7 @@ Switches to the buffer `*ielm*', or creates it if it does not exist. ;;;*** ;;;### (autoloads (iimage-mode turn-on-iimage-mode) "iimage" "iimage.el" -;;;;;; (18088 55085)) +;;;;;; (18307 57856)) ;;; Generated autoloads from iimage.el (autoload 'turn-on-iimage-mode "iimage" "\ @@ -15143,7 +15215,7 @@ Toggle inline image minor mode. ;;;;;; insert-image put-image create-image image-type-auto-detected-p ;;;;;; image-type-available-p image-type image-type-from-file-name ;;;;;; image-type-from-file-header image-type-from-buffer image-type-from-data) -;;;;;; "image" "image.el" (18186 14736)) +;;;;;; "image" "image.el" (18307 57856)) ;;; Generated autoloads from image.el (autoload 'image-type-from-data "image" "\ @@ -15326,7 +15398,7 @@ Example: ;;;;;; image-dired-jump-thumbnail-buffer image-dired-delete-tag ;;;;;; image-dired-tag-files image-dired-show-all-from-dir image-dired-display-thumbs ;;;;;; image-dired-dired-with-window-configuration image-dired-dired-insert-marked-thumbs) -;;;;;; "image-dired" "image-dired.el" (18202 3995)) +;;;;;; "image-dired" "image-dired.el" (18307 57856)) ;;; Generated autoloads from image-dired.el (autoload 'image-dired-dired-insert-marked-thumbs "image-dired" "\ @@ -15460,7 +15532,7 @@ easy-to-use form. ;;;### (autoloads (auto-image-file-mode insert-image-file image-file-name-regexp ;;;;;; image-file-name-regexps image-file-name-extensions) "image-file" -;;;;;; "image-file.el" (18123 58387)) +;;;;;; "image-file.el" (18307 57856)) ;;; Generated autoloads from image-file.el (defvar image-file-name-extensions '("png" "jpeg" "jpg" "gif" "tiff" "tif" "xbm" "xpm" "pbm" "pgm" "ppm" "pnm" "svg") "\ @@ -15521,8 +15593,8 @@ Image files are those whose name has an extension in ;;;*** -;;;### (autoloads (image-mode-maybe image-minor-mode image-mode) -;;;;;; "image-mode" "image-mode.el" (18132 64031)) +;;;### (autoloads (image-bookmark-jump image-mode-maybe image-minor-mode +;;;;;; image-mode) "image-mode" "image-mode.el" (18301 42251)) ;;; Generated autoloads from image-mode.el (push '("\\.jpe?g\\'" . image-mode) auto-mode-alist) (push '("\\.png\\'" . image-mode) auto-mode-alist) @@ -15560,10 +15632,15 @@ information on these modes. \(fn)" t nil) +(autoload 'image-bookmark-jump "image-mode" "\ +Not documented + +\(fn BMK)" nil nil) + ;;;*** ;;;### (autoloads (imenu imenu-add-menubar-index imenu-add-to-menubar -;;;;;; imenu-sort-function) "imenu" "imenu.el" (18120 34749)) +;;;;;; imenu-sort-function) "imenu" "imenu.el" (18302 4831)) ;;; Generated autoloads from imenu.el (defvar imenu-sort-function nil "\ @@ -15678,7 +15755,7 @@ for more information. ;;;### (autoloads (indian-char-glyph indian-glyph-char in-is13194-pre-write-conversion ;;;;;; in-is13194-post-read-conversion indian-compose-string indian-compose-region) -;;;;;; "ind-util" "language/ind-util.el" (18088 55109)) +;;;;;; "ind-util" "language/ind-util.el" (18307 57867)) ;;; Generated autoloads from language/ind-util.el (autoload 'indian-compose-region "ind-util" "\ @@ -15721,7 +15798,7 @@ See also the function `indian-glyph-char'. ;;;### (autoloads (inferior-lisp inferior-lisp-prompt inferior-lisp-load-command ;;;;;; inferior-lisp-program inferior-lisp-filter-regexp) "inf-lisp" -;;;;;; "progmodes/inf-lisp.el" (18088 55117)) +;;;;;; "progmodes/inf-lisp.el" (18307 57871)) ;;; Generated autoloads from progmodes/inf-lisp.el (defvar inferior-lisp-filter-regexp "\\`\\s *\\(:\\(\\w\\|\\s_\\)\\)?\\s *\\'" "\ @@ -15788,7 +15865,7 @@ of `inferior-lisp-program'). Runs the hooks from ;;;### (autoloads (Info-speedbar-browser Info-goto-emacs-key-command-node ;;;;;; Info-goto-emacs-command-node Info-mode info-apropos Info-index ;;;;;; Info-directory Info-on-current-buffer info-standalone info-emacs-manual -;;;;;; info info-other-window) "info" "info.el" (18132 64031)) +;;;;;; info info-other-window) "info" "info.el" (18307 57856)) ;;; Generated autoloads from info.el (autoload 'info-other-window "info" "\ @@ -15954,7 +16031,7 @@ This will add a speedbar major display mode. ;;;### (autoloads (info-complete-file info-complete-symbol info-lookup-file ;;;;;; info-lookup-symbol info-lookup-reset) "info-look" "info-look.el" -;;;;;; (18120 34749)) +;;;;;; (18307 57856)) ;;; Generated autoloads from info-look.el (autoload 'info-lookup-reset "info-look" "\ @@ -16002,7 +16079,7 @@ Perform completion on file preceding point. ;;;*** ;;;### (autoloads (info-xref-check-all-custom info-xref-check-all -;;;;;; info-xref-check) "info-xref" "info-xref.el" (18088 55085)) +;;;;;; info-xref-check) "info-xref" "info-xref.el" (18307 57856)) ;;; Generated autoloads from info-xref.el (autoload 'info-xref-check "info-xref" "\ @@ -16029,7 +16106,7 @@ quite a while. ;;;*** ;;;### (autoloads (batch-info-validate Info-validate Info-split Info-tagify) -;;;;;; "informat" "informat.el" (18088 55086)) +;;;;;; "informat" "informat.el" (18307 57856)) ;;; Generated autoloads from informat.el (autoload 'Info-tagify "informat" "\ @@ -16069,7 +16146,7 @@ For example, invoke \"emacs -batch -f batch-info-validate $info/ ~/*.info\" ;;;*** ;;;### (autoloads (isearch-buffers-minor-mode) "isearch-multi" "isearch-multi.el" -;;;;;; (18210 13714)) +;;;;;; (18308 19808)) ;;; Generated autoloads from isearch-multi.el (defvar isearch-buffers-current-buffer nil "\ @@ -16080,15 +16157,15 @@ The value is nil when the search still is in the initial buffer.") Function to call to get the next buffer to search. When this variable is set to a function that returns a buffer, then -after typing another C-s or C-r at a failing search, the search goes +after typing another \\[isearch-forward] or \\[isearch-backward] at a failing search, the search goes to the next buffer in the series and continues searching for the next occurrence. The first argument of this function is the current buffer where the search is currently searching. It defines the base buffer relative to which this function should find the next buffer. When the isearch -direction is backward (when isearch-forward is nil), this function -should return the previous buffer to search. If the second argument of +direction is backward (when `isearch-forward' is nil), this function +should return the previous buffer to search. If the second argument of this function WRAP is non-nil, then it should return the first buffer in the series; and for the backward search, it should return the last buffer in the series.") @@ -16103,7 +16180,7 @@ With arg, turn isearch-buffers minor mode on if arg is positive, off otherwise. ;;;### (autoloads (isearch-process-search-multibyte-characters isearch-toggle-input-method ;;;;;; isearch-toggle-specified-input-method) "isearch-x" "international/isearch-x.el" -;;;;;; (18088 55107)) +;;;;;; (18307 57867)) ;;; Generated autoloads from international/isearch-x.el (autoload 'isearch-toggle-specified-input-method "isearch-x" "\ @@ -16123,8 +16200,8 @@ Not documented ;;;*** -;;;### (autoloads (isearchb-activate) "isearchb" "isearchb.el" (18088 -;;;;;; 55086)) +;;;### (autoloads (isearchb-activate) "isearchb" "isearchb.el" (18307 +;;;;;; 57856)) ;;; Generated autoloads from isearchb.el (autoload 'isearchb-activate "isearchb" "\ @@ -16140,68 +16217,75 @@ accessed via isearchb. ;;;### (autoloads (iso-cvt-define-menu iso-cvt-write-only iso-cvt-read-only ;;;;;; iso-sgml2iso iso-iso2sgml iso-iso2duden iso-iso2gtex iso-gtex2iso ;;;;;; iso-tex2iso iso-iso2tex iso-german iso-spanish) "iso-cvt" -;;;;;; "international/iso-cvt.el" (18088 55107)) +;;;;;; "international/iso-cvt.el" (18307 57867)) ;;; Generated autoloads from international/iso-cvt.el (autoload 'iso-spanish "iso-cvt" "\ Translate net conventions for Spanish to ISO 8859-1. -The region between FROM and TO is translated using the table TRANS-TAB. +Translate the region between FROM and TO using the table +`iso-spanish-trans-tab'. Optional arg BUFFER is ignored (for use in `format-alist'). \(fn FROM TO &optional BUFFER)" t nil) (autoload 'iso-german "iso-cvt" "\ Translate net conventions for German to ISO 8859-1. -The region between FROM and TO is translated using the table TRANS-TAB. +Translate the region FROM and TO using the table +`iso-german-trans-tab'. Optional arg BUFFER is ignored (for use in `format-alist'). \(fn FROM TO &optional BUFFER)" t nil) (autoload 'iso-iso2tex "iso-cvt" "\ Translate ISO 8859-1 characters to TeX sequences. -The region between FROM and TO is translated using the table TRANS-TAB. +Translate the region between FROM and TO using the table +`iso-iso2tex-trans-tab'. Optional arg BUFFER is ignored (for use in `format-alist'). \(fn FROM TO &optional BUFFER)" t nil) (autoload 'iso-tex2iso "iso-cvt" "\ Translate TeX sequences to ISO 8859-1 characters. -The region between FROM and TO is translated using the table TRANS-TAB. +Translate the region between FROM and TO using the table +`iso-tex2iso-trans-tab'. Optional arg BUFFER is ignored (for use in `format-alist'). \(fn FROM TO &optional BUFFER)" t nil) (autoload 'iso-gtex2iso "iso-cvt" "\ Translate German TeX sequences to ISO 8859-1 characters. -The region between FROM and TO is translated using the table TRANS-TAB. +Translate the region between FROM and TO using the table +`iso-gtex2iso-trans-tab'. Optional arg BUFFER is ignored (for use in `format-alist'). \(fn FROM TO &optional BUFFER)" t nil) (autoload 'iso-iso2gtex "iso-cvt" "\ Translate ISO 8859-1 characters to German TeX sequences. -The region between FROM and TO is translated using the table TRANS-TAB. +Translate the region between FROM and TO using the table +`iso-iso2gtex-trans-tab'. Optional arg BUFFER is ignored (for use in `format-alist'). \(fn FROM TO &optional BUFFER)" t nil) (autoload 'iso-iso2duden "iso-cvt" "\ -Translate ISO 8859-1 characters to German TeX sequences. -The region between FROM and TO is translated using the table TRANS-TAB. +Translate ISO 8859-1 characters to Duden sequences. +Translate the region between FROM and TO using the table +`iso-iso2duden-trans-tab'. Optional arg BUFFER is ignored (for use in `format-alist'). \(fn FROM TO &optional BUFFER)" t nil) (autoload 'iso-iso2sgml "iso-cvt" "\ Translate ISO 8859-1 characters in the region to SGML entities. -The entities used are from \"ISO 8879:1986//ENTITIES Added Latin 1//EN\". +Use entities from \"ISO 8879:1986//ENTITIES Added Latin 1//EN\". Optional arg BUFFER is ignored (for use in `format-alist'). \(fn FROM TO &optional BUFFER)" t nil) (autoload 'iso-sgml2iso "iso-cvt" "\ Translate SGML entities in the region to ISO 8859-1 characters. -The entities used are from \"ISO 8879:1986//ENTITIES Added Latin 1//EN\". +Use entities from \"ISO 8879:1986//ENTITIES Added Latin 1//EN\". Optional arg BUFFER is ignored (for use in `format-alist'). \(fn FROM TO &optional BUFFER)" t nil) @@ -16224,7 +16308,7 @@ Add submenus to the File menu, to convert to and from various formats. ;;;*** ;;;### (autoloads nil "iso-transl" "international/iso-transl.el" -;;;;;; (18088 55107)) +;;;;;; (18307 57867)) ;;; Generated autoloads from international/iso-transl.el (or key-translation-map (setq key-translation-map (make-sparse-keymap))) (define-key key-translation-map "\C-x8" 'iso-transl-ctl-x-8-map) @@ -16237,7 +16321,7 @@ Add submenus to the File menu, to convert to and from various formats. ;;;;;; ispell-region ispell-change-dictionary ispell-kill-ispell ;;;;;; ispell-help ispell-pdict-save ispell-word ispell-local-dictionary-alist ;;;;;; ispell-personal-dictionary) "ispell" "textmodes/ispell.el" -;;;;;; (18200 51267)) +;;;;;; (18307 57873)) ;;; Generated autoloads from textmodes/ispell.el (put 'ispell-check-comments 'safe-local-variable (lambda (a) (memq a '(nil t exclusive)))) @@ -16362,6 +16446,7 @@ for skipping in latex mode.") Same format as `ispell-skip-region-alist' Note - substrings of other matches must come last (e.g. \"<[tT][tT]/\" and \"<[^ \\t\\n>]\").") +(put 'ispell-local-pdict 'safe-local-variable 'stringp) (define-key esc-map "$" 'ispell-word) (autoload 'ispell-word "ispell" "\ @@ -16528,8 +16613,8 @@ You can bind this to the key C-c i in GNUS or mail by adding to ;;;*** -;;;### (autoloads (iswitchb-mode) "iswitchb" "iswitchb.el" (18120 -;;;;;; 34749)) +;;;### (autoloads (iswitchb-mode) "iswitchb" "iswitchb.el" (18302 +;;;;;; 4831)) ;;; Generated autoloads from iswitchb.el (defvar iswitchb-mode nil "\ @@ -16554,7 +16639,7 @@ This mode enables switching between buffers using substrings. See ;;;### (autoloads (read-hiragana-string japanese-zenkaku-region japanese-hankaku-region ;;;;;; japanese-hiragana-region japanese-katakana-region japanese-zenkaku ;;;;;; japanese-hankaku japanese-hiragana japanese-katakana setup-japanese-environment-internal) -;;;;;; "japan-util" "language/japan-util.el" (18088 55109)) +;;;;;; "japan-util" "language/japan-util.el" (18307 57867)) ;;; Generated autoloads from language/japan-util.el (autoload 'setup-japanese-environment-internal "japan-util" "\ @@ -16632,7 +16717,7 @@ If non-nil, second arg INITIAL-INPUT is a string to insert before reading. ;;;*** ;;;### (autoloads (jka-compr-uninstall jka-compr-handler) "jka-compr" -;;;;;; "jka-compr.el" (18088 55086)) +;;;;;; "jka-compr.el" (18307 57856)) ;;; Generated autoloads from jka-compr.el (defvar jka-compr-inhibit nil "\ @@ -16657,7 +16742,7 @@ by `jka-compr-installed'. ;;;### (autoloads (keypad-setup keypad-numlock-shifted-setup keypad-shifted-setup ;;;;;; keypad-numlock-setup keypad-setup) "keypad" "emulation/keypad.el" -;;;;;; (18088 55097)) +;;;;;; (18307 57862)) ;;; Generated autoloads from emulation/keypad.el (defvar keypad-setup nil "\ @@ -16713,7 +16798,7 @@ the decimal key on the keypad is mapped to DECIMAL instead of `.' ;;;*** ;;;### (autoloads (kinsoku) "kinsoku" "international/kinsoku.el" -;;;;;; (18088 55107)) +;;;;;; (18307 57867)) ;;; Generated autoloads from international/kinsoku.el (autoload 'kinsoku "kinsoku" "\ @@ -16734,8 +16819,8 @@ the context of text formatting. ;;;*** -;;;### (autoloads (kkc-region) "kkc" "international/kkc.el" (18088 -;;;;;; 55107)) +;;;### (autoloads (kkc-region) "kkc" "international/kkc.el" (18307 +;;;;;; 57867)) ;;; Generated autoloads from international/kkc.el (defvar kkc-after-update-conversion-functions nil "\ @@ -16760,7 +16845,7 @@ and the return value is the length of the conversion. ;;;### (autoloads (kmacro-end-call-mouse kmacro-end-and-call-macro ;;;;;; kmacro-end-or-call-macro kmacro-start-macro-or-insert-counter ;;;;;; kmacro-call-macro kmacro-end-macro kmacro-start-macro) "kmacro" -;;;;;; "kmacro.el" (18088 55086)) +;;;;;; "kmacro.el" (18307 57856)) ;;; Generated autoloads from kmacro.el (global-set-key "\C-x(" 'kmacro-start-macro) (global-set-key "\C-x)" 'kmacro-end-macro) @@ -16867,7 +16952,7 @@ If kbd macro currently being defined end it before activating it. ;;;### (autoloads (kannada-post-read-conversion kannada-compose-string ;;;;;; kannada-compose-region) "knd-util" "language/knd-util.el" -;;;;;; (18088 55109)) +;;;;;; (18307 57867)) ;;; Generated autoloads from language/knd-util.el (defconst kannada-consonant "[\x51f75-\x51fb9]") @@ -16890,7 +16975,7 @@ Not documented ;;;*** ;;;### (autoloads (setup-korean-environment-internal) "korea-util" -;;;;;; "language/korea-util.el" (18088 55109)) +;;;;;; "language/korea-util.el" (18307 57867)) ;;; Generated autoloads from language/korea-util.el (defvar default-korean-keyboard (if (string-match "3" (or (getenv "HANGUL_KEYBOARD_TYPE") "")) "3" "") "\ @@ -16905,7 +16990,7 @@ Not documented ;;;*** ;;;### (autoloads (lm lm-test-run) "landmark" "play/landmark.el" -;;;;;; (18202 4002)) +;;;;;; (18307 57870)) ;;; Generated autoloads from play/landmark.el (defalias 'landmark-repeat 'lm-test-run) @@ -16939,8 +17024,8 @@ Use \\[describe-mode] for more info. ;;;### (autoloads (lao-compose-region lao-composition-function lao-post-read-conversion ;;;;;; lao-transcribe-roman-to-lao-string lao-transcribe-single-roman-syllable-to-lao -;;;;;; lao-compose-string) "lao-util" "language/lao-util.el" (18088 -;;;;;; 55109)) +;;;;;; lao-compose-string) "lao-util" "language/lao-util.el" (18307 +;;;;;; 57867)) ;;; Generated autoloads from language/lao-util.el (autoload 'lao-compose-string "lao-util" "\ @@ -16989,7 +17074,7 @@ Not documented ;;;### (autoloads (latexenc-find-file-coding-system latexenc-coding-system-to-inputenc ;;;;;; latexenc-inputenc-to-coding-system latex-inputenc-coding-alist) -;;;;;; "latexenc" "international/latexenc.el" (18088 55107)) +;;;;;; "latexenc" "international/latexenc.el" (18307 57867)) ;;; Generated autoloads from international/latexenc.el (defvar latex-inputenc-coding-alist '(("ansinew" . windows-1252) ("applemac" . mac-roman) ("ascii" . us-ascii) ("cp1250" . windows-1250) ("cp1252" . windows-1252) ("cp1257" . cp1257) ("cp437de" . cp437) ("cp437" . cp437) ("cp850" . cp850) ("cp852" . cp852) ("cp858" . cp858) ("cp865" . cp865) ("latin1" . iso-8859-1) ("latin2" . iso-8859-2) ("latin3" . iso-8859-3) ("latin4" . iso-8859-4) ("latin5" . iso-8859-5) ("latin9" . iso-8859-15) ("next" . next) ("utf8" . utf-8) ("utf8x" . utf-8)) "\ @@ -17021,7 +17106,7 @@ coding system names is determined from `latex-inputenc-coding-alist'. ;;;*** ;;;### (autoloads (latin1-display-ucs-per-lynx latin1-display latin1-display) -;;;;;; "latin1-disp" "international/latin1-disp.el" (18120 34751)) +;;;;;; "latin1-disp" "international/latin1-disp.el" (18307 57867)) ;;; Generated autoloads from international/latin1-disp.el (defvar latin1-display nil "\ @@ -17065,7 +17150,7 @@ use either \\[customize] or the function `latin1-display'.") ;;;*** ;;;### (autoloads (ld-script-mode) "ld-script" "progmodes/ld-script.el" -;;;;;; (18088 55117)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/ld-script.el (add-to-list 'auto-mode-alist '("\\.ld[si]?\\>" . ld-script-mode)) @@ -17080,7 +17165,7 @@ A major mode to edit GNU ld script files ;;;*** ;;;### (autoloads (ledit-from-lisp-mode ledit-mode) "ledit" "ledit.el" -;;;;;; (18088 55086)) +;;;;;; (18307 57856)) ;;; Generated autoloads from ledit.el (defconst ledit-save-files t "\ @@ -17115,7 +17200,7 @@ Not documented ;;;*** -;;;### (autoloads (life) "life" "play/life.el" (18088 55114)) +;;;### (autoloads (life) "life" "play/life.el" (18307 57870)) ;;; Generated autoloads from play/life.el (autoload 'life "life" "\ @@ -17128,8 +17213,8 @@ generations (this defaults to 1). ;;;*** -;;;### (autoloads (unload-feature) "loadhist" "loadhist.el" (18213 -;;;;;; 13926)) +;;;### (autoloads (unload-feature) "loadhist" "loadhist.el" (18307 +;;;;;; 57856)) ;;; Generated autoloads from loadhist.el (autoload 'unload-feature "loadhist" "\ @@ -17161,7 +17246,7 @@ something strange, such as redefining an Emacs function. ;;;*** ;;;### (autoloads (locate-with-filter locate locate-ls-subdir-switches) -;;;;;; "locate" "locate.el" (18126 18420)) +;;;;;; "locate" "locate.el" (18307 57856)) ;;; Generated autoloads from locate.el (defvar locate-ls-subdir-switches "-al" "\ @@ -17212,29 +17297,34 @@ except that FILTER is not optional. ;;;*** -;;;### (autoloads (log-edit) "log-edit" "log-edit.el" (18120 34749)) +;;;### (autoloads (log-edit) "log-edit" "log-edit.el" (18317 11736)) ;;; Generated autoloads from log-edit.el (autoload 'log-edit "log-edit" "\ Setup a buffer to enter a log message. \\The buffer will be put in `log-edit-mode'. If SETUP is non-nil, the buffer is then erased and `log-edit-hook' is run. -Mark and point will be set around the entire contents of the -buffer so that it is easy to kill the contents of the buffer with \\[kill-region]. +Mark and point will be set around the entire contents of the buffer so +that it is easy to kill the contents of the buffer with \\[kill-region]. Once you're done editing the message, pressing \\[log-edit-done] will call `log-edit-done' which will end up calling CALLBACK to do the actual commit. -LISTFUN if non-nil is a function of no arguments returning the list of files - that are concerned by the current operation (using relative names). -If BUFFER is non-nil `log-edit' will jump to that buffer, use it to edit the - log message and go back to the current buffer when done. Otherwise, it - uses the current buffer. -\(fn CALLBACK &optional SETUP LISTFUN BUFFER &rest IGNORE)" nil nil) +PARAMS if non-nil is an alist. Possible keys and associated values: + `log-edit-listfun' -- function taking no arguments that returns the list of + files that are concerned by the current operation (using relative names); + `log-edit-diff-function' -- function taking no arguments that + displays a diff of the files concerned by the current operation. + +If BUFFER is non-nil `log-edit' will jump to that buffer, use it to edit the +log message and go back to the current buffer when done. Otherwise, it +uses the current buffer. + +\(fn CALLBACK &optional SETUP PARAMS BUFFER &rest IGNORE)" nil nil) ;;;*** -;;;### (autoloads (log-view-mode) "log-view" "log-view.el" (18202 -;;;;;; 3995)) +;;;### (autoloads (log-view-mode) "log-view" "log-view.el" (18301 +;;;;;; 42251)) ;;; Generated autoloads from log-view.el (autoload 'log-view-mode "log-view" "\ @@ -17244,8 +17334,8 @@ Major mode for browsing CVS log output. ;;;*** -;;;### (autoloads (longlines-mode) "longlines" "longlines.el" (18214 -;;;;;; 4763)) +;;;### (autoloads (longlines-mode) "longlines" "longlines.el" (18307 +;;;;;; 57856)) ;;; Generated autoloads from longlines.el (autoload 'longlines-mode "longlines" "\ @@ -17266,13 +17356,13 @@ are indicated with a symbol. ;;;*** ;;;### (autoloads (print-region lpr-region print-buffer lpr-buffer -;;;;;; lpr-command lpr-switches printer-name) "lpr" "lpr.el" (18088 -;;;;;; 55086)) +;;;;;; lpr-command lpr-switches printer-name) "lpr" "lpr.el" (18307 +;;;;;; 57856)) ;;; Generated autoloads from lpr.el (defvar lpr-windows-system (memq system-type '(emx win32 w32 mswindows ms-dos windows-nt))) -(defvar lpr-lp-system (memq system-type '(usg-unix-v dgux hpux irix))) +(defvar lpr-lp-system (memq system-type '(usg-unix-v hpux irix))) (defvar printer-name (and lpr-windows-system "PRN") "\ *The name of a local printer to which data is sent for printing. @@ -17361,7 +17451,7 @@ for further customization of the printer command. ;;;*** ;;;### (autoloads (ls-lisp-support-shell-wildcards) "ls-lisp" "ls-lisp.el" -;;;;;; (18088 55086)) +;;;;;; (18307 57856)) ;;; Generated autoloads from ls-lisp.el (defvar ls-lisp-support-shell-wildcards t "\ @@ -17372,8 +17462,8 @@ Otherwise they are treated as Emacs regexps (for backward compatibility).") ;;;*** -;;;### (autoloads (phases-of-moon) "lunar" "calendar/lunar.el" (18088 -;;;;;; 55094)) +;;;### (autoloads (phases-of-moon) "lunar" "calendar/lunar.el" (18307 +;;;;;; 57860)) ;;; Generated autoloads from calendar/lunar.el (autoload 'phases-of-moon "lunar" "\ @@ -17386,8 +17476,8 @@ This function is suitable for execution in a .emacs file. ;;;*** -;;;### (autoloads (m4-mode) "m4-mode" "progmodes/m4-mode.el" (18088 -;;;;;; 55117)) +;;;### (autoloads (m4-mode) "m4-mode" "progmodes/m4-mode.el" (18307 +;;;;;; 57871)) ;;; Generated autoloads from progmodes/m4-mode.el (autoload 'm4-mode "m4-mode" "\ @@ -17399,7 +17489,7 @@ A major mode to edit m4 macro files. ;;;*** ;;;### (autoloads (macroexpand-all) "macroexp" "emacs-lisp/macroexp.el" -;;;;;; (18088 55096)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/macroexp.el (autoload 'macroexpand-all "macroexp" "\ @@ -17413,7 +17503,7 @@ definitions to shadow the loaded ones for use in file byte-compilation. ;;;*** ;;;### (autoloads (apply-macro-to-region-lines kbd-macro-query insert-kbd-macro -;;;;;; name-last-kbd-macro) "macros" "macros.el" (18088 55086)) +;;;;;; name-last-kbd-macro) "macros" "macros.el" (18307 57856)) ;;; Generated autoloads from macros.el (autoload 'name-last-kbd-macro "macros" "\ @@ -17502,7 +17592,7 @@ and then select the region of un-tablified names and use ;;;*** ;;;### (autoloads (what-domain mail-extract-address-components) "mail-extr" -;;;;;; "mail/mail-extr.el" (18088 55109)) +;;;;;; "mail/mail-extr.el" (18307 57869)) ;;; Generated autoloads from mail/mail-extr.el (autoload 'mail-extract-address-components "mail-extr" "\ @@ -17534,7 +17624,7 @@ Convert mail domain DOMAIN to the country it corresponds to. ;;;### (autoloads (mail-hist-put-headers-into-history mail-hist-keep-history ;;;;;; mail-hist-enable mail-hist-define-keys) "mail-hist" "mail/mail-hist.el" -;;;;;; (18088 55110)) +;;;;;; (18307 57869)) ;;; Generated autoloads from mail/mail-hist.el (autoload 'mail-hist-define-keys "mail-hist" "\ @@ -17565,8 +17655,8 @@ This function normally would be called when the message is sent. ;;;### (autoloads (mail-fetch-field mail-unquote-printable-region ;;;;;; mail-unquote-printable mail-quote-printable mail-file-babyl-p -;;;;;; mail-use-rfc822) "mail-utils" "mail/mail-utils.el" (18088 -;;;;;; 55110)) +;;;;;; mail-use-rfc822) "mail-utils" "mail/mail-utils.el" (18307 +;;;;;; 57869)) ;;; Generated autoloads from mail/mail-utils.el (defvar mail-use-rfc822 nil "\ @@ -17617,10 +17707,25 @@ If 4th arg LIST is non-nil, return a list of all such fields. ;;;*** -;;;### (autoloads (define-mail-abbrev build-mail-abbrevs mail-abbrevs-setup) -;;;;;; "mailabbrev" "mail/mailabbrev.el" (18120 34751)) +;;;### (autoloads (define-mail-abbrev build-mail-abbrevs mail-abbrevs-setup +;;;;;; mail-abbrevs-mode) "mailabbrev" "mail/mailabbrev.el" (18307 +;;;;;; 57869)) ;;; Generated autoloads from mail/mailabbrev.el +(defvar mail-abbrevs-mode nil "\ +Non-nil if Mail-Abbrevs mode is enabled. +See the command `mail-abbrevs-mode' for a description of this minor mode. +Setting this variable directly does not take effect; +either customize it (see the info node `Easy Customization') +or call the function `mail-abbrevs-mode'.") + +(custom-autoload 'mail-abbrevs-mode "mailabbrev" nil) + +(autoload 'mail-abbrevs-mode "mailabbrev" "\ +Non-nil means expand mail aliases as abbrevs, in certain message headers. + +\(fn &optional ARG)" t nil) + (autoload 'mail-abbrevs-setup "mailabbrev" "\ Initialize use of the `mailabbrev' package. @@ -17641,8 +17746,8 @@ If DEFINITION contains multiple addresses, separate them with commas. ;;;*** ;;;### (autoloads (mail-complete define-mail-alias expand-mail-aliases -;;;;;; mail-complete-style) "mailalias" "mail/mailalias.el" (18088 -;;;;;; 55110)) +;;;;;; mail-complete-style) "mailalias" "mail/mailalias.el" (18307 +;;;;;; 57869)) ;;; Generated autoloads from mail/mailalias.el (defvar mail-complete-style 'angles "\ @@ -17688,7 +17793,7 @@ current header, calls `mail-complete-function' and passes prefix arg if any. ;;;*** ;;;### (autoloads (mailclient-send-it) "mailclient" "mail/mailclient.el" -;;;;;; (18088 55110)) +;;;;;; (18307 57869)) ;;; Generated autoloads from mail/mailclient.el (autoload 'mailclient-send-it "mailclient" "\ @@ -17702,7 +17807,7 @@ The mail client is taken to be the handler of mailto URLs. ;;;### (autoloads (makefile-imake-mode makefile-bsdmake-mode makefile-makepp-mode ;;;;;; makefile-gmake-mode makefile-automake-mode makefile-mode) -;;;;;; "make-mode" "progmodes/make-mode.el" (18088 55117)) +;;;;;; "make-mode" "progmodes/make-mode.el" (18307 57871)) ;;; Generated autoloads from progmodes/make-mode.el (autoload 'makefile-mode "make-mode" "\ @@ -17819,8 +17924,8 @@ An adapted `makefile-mode' that knows about imake. ;;;*** -;;;### (autoloads (make-command-summary) "makesum" "makesum.el" (18088 -;;;;;; 55086)) +;;;### (autoloads (make-command-summary) "makesum" "makesum.el" (18302 +;;;;;; 4831)) ;;; Generated autoloads from makesum.el (autoload 'make-command-summary "makesum" "\ @@ -17831,7 +17936,7 @@ Previous contents of that buffer are killed first. ;;;*** -;;;### (autoloads (man-follow man) "man" "man.el" (18153 31207)) +;;;### (autoloads (man-follow man) "man" "man.el" (18307 57856)) ;;; Generated autoloads from man.el (defalias 'manual-entry 'man) @@ -17858,7 +17963,7 @@ Get a Un*x manual page of the item under point and put it in a buffer. ;;;*** -;;;### (autoloads (master-mode) "master" "master.el" (18088 55086)) +;;;### (autoloads (master-mode) "master" "master.el" (18307 57856)) ;;; Generated autoloads from master.el (autoload 'master-mode "master" "\ @@ -17881,7 +17986,7 @@ yourself the value of `master-of' by calling `master-show-slave'. ;;;*** ;;;### (autoloads (minibuffer-indicate-depth-mode) "mb-depth" "mb-depth.el" -;;;;;; (18187 36839)) +;;;;;; (18308 19808)) ;;; Generated autoloads from mb-depth.el (defvar minibuffer-indicate-depth-mode nil "\ @@ -17906,8 +18011,8 @@ Returns non-nil if the new state is enabled. ;;;*** -;;;### (autoloads (menu-bar-mode) "menu-bar" "menu-bar.el" (18211 -;;;;;; 32385)) +;;;### (autoloads (menu-bar-mode) "menu-bar" "menu-bar.el" (18307 +;;;;;; 57856)) ;;; Generated autoloads from menu-bar.el (put 'menu-bar-mode 'standard-value '(t)) @@ -17938,7 +18043,7 @@ turn on menu bars; otherwise, turn off menu bars. ;;;;;; message-forward-make-body message-forward message-recover ;;;;;; message-supersede message-cancel-news message-followup message-wide-reply ;;;;;; message-reply message-news message-mail message-mode) "message" -;;;;;; "gnus/message.el" (18212 46007)) +;;;;;; "gnus/message.el" (18307 57866)) ;;; Generated autoloads from gnus/message.el (define-mail-user-agent 'message-user-agent 'message-mail 'message-send-and-exit 'message-kill-buffer 'message-send-hook) @@ -18104,7 +18209,7 @@ which specify the range to operate on. ;;;*** ;;;### (autoloads (metapost-mode metafont-mode) "meta-mode" "progmodes/meta-mode.el" -;;;;;; (18161 20996)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/meta-mode.el (autoload 'metafont-mode "meta-mode" "\ @@ -18131,7 +18236,7 @@ Turning on MetaPost mode calls the value of the variable ;;;### (autoloads (metamail-region metamail-buffer metamail-interpret-body ;;;;;; metamail-interpret-header) "metamail" "mail/metamail.el" -;;;;;; (18088 55110)) +;;;;;; (18307 57869)) ;;; Generated autoloads from mail/metamail.el (autoload 'metamail-interpret-header "metamail" "\ @@ -18176,7 +18281,7 @@ redisplayed as output is inserted. ;;;### (autoloads (mh-fully-kill-draft mh-send-letter mh-user-agent-compose ;;;;;; mh-smail-batch mh-smail-other-window mh-smail) "mh-comp" -;;;;;; "mh-e/mh-comp.el" (18128 32656)) +;;;;;; "mh-e/mh-comp.el" (18307 57869)) ;;; Generated autoloads from mh-e/mh-comp.el (autoload 'mh-smail "mh-comp" "\ @@ -18263,7 +18368,7 @@ delete the draft message. ;;;*** -;;;### (autoloads (mh-version) "mh-e" "mh-e/mh-e.el" (18152 13227)) +;;;### (autoloads (mh-version) "mh-e" "mh-e/mh-e.el" (18307 57869)) ;;; Generated autoloads from mh-e/mh-e.el (put 'mh-progs 'risky-local-variable t) @@ -18280,7 +18385,7 @@ Display version information about MH-E and the MH mail handling system. ;;;*** ;;;### (autoloads (mh-folder-mode mh-nmail mh-rmail) "mh-folder" -;;;;;; "mh-e/mh-folder.el" (18123 35153)) +;;;;;; "mh-e/mh-folder.el" (18307 57869)) ;;; Generated autoloads from mh-e/mh-folder.el (autoload 'mh-rmail "mh-folder" "\ @@ -18362,7 +18467,7 @@ perform the operation on all messages in that region. ;;;*** ;;;### (autoloads (midnight-delay-set clean-buffer-list) "midnight" -;;;;;; "midnight.el" (18088 55086)) +;;;;;; "midnight.el" (18307 57856)) ;;; Generated autoloads from midnight.el (autoload 'clean-buffer-list "midnight" "\ @@ -18389,7 +18494,7 @@ to its second argument TM. ;;;*** ;;;### (autoloads (minibuffer-electric-default-mode) "minibuf-eldef" -;;;;;; "minibuf-eldef.el" (18088 55087)) +;;;;;; "minibuf-eldef.el" (18307 57856)) ;;; Generated autoloads from minibuf-eldef.el (defvar minibuffer-electric-default-mode nil "\ @@ -18417,7 +18522,7 @@ Returns non-nil if the new state is enabled. ;;;*** ;;;### (autoloads (mixal-mode) "mixal-mode" "progmodes/mixal-mode.el" -;;;;;; (18088 55117)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/mixal-mode.el (autoload 'mixal-mode "mixal-mode" "\ @@ -18432,7 +18537,7 @@ Major mode for the mixal asm language. ;;;### (autoloads (malayalam-composition-function malayalam-post-read-conversion ;;;;;; malayalam-compose-region) "mlm-util" "language/mlm-util.el" -;;;;;; (18088 55109)) +;;;;;; (18307 57867)) ;;; Generated autoloads from language/mlm-util.el (autoload 'malayalam-compose-region "mlm-util" "\ @@ -18455,7 +18560,7 @@ PATTERN regexp. ;;;*** ;;;### (autoloads (mm-inline-external-body mm-extern-cache-contents) -;;;;;; "mm-extern" "gnus/mm-extern.el" (18088 55104)) +;;;;;; "mm-extern" "gnus/mm-extern.el" (18307 57866)) ;;; Generated autoloads from gnus/mm-extern.el (autoload 'mm-extern-cache-contents "mm-extern" "\ @@ -18474,7 +18579,7 @@ If NO-DISPLAY is nil, display it. Otherwise, do nothing after replacing. ;;;*** ;;;### (autoloads (mm-inline-partial) "mm-partial" "gnus/mm-partial.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/mm-partial.el (autoload 'mm-inline-partial "mm-partial" "\ @@ -18488,7 +18593,7 @@ If NO-DISPLAY is nil, display it. Otherwise, do nothing after replacing. ;;;*** ;;;### (autoloads (mm-url-insert-file-contents-external mm-url-insert-file-contents) -;;;;;; "mm-url" "gnus/mm-url.el" (18212 46007)) +;;;;;; "mm-url" "gnus/mm-url.el" (18307 57866)) ;;; Generated autoloads from gnus/mm-url.el (autoload 'mm-url-insert-file-contents "mm-url" "\ @@ -18505,7 +18610,7 @@ Insert file contents of URL using `mm-url-program'. ;;;*** ;;;### (autoloads (mm-uu-dissect-text-parts mm-uu-dissect) "mm-uu" -;;;;;; "gnus/mm-uu.el" (18212 46007)) +;;;;;; "gnus/mm-uu.el" (18307 57866)) ;;; Generated autoloads from gnus/mm-uu.el (autoload 'mm-uu-dissect "mm-uu" "\ @@ -18525,7 +18630,7 @@ Assume text has been decoded if DECODED is non-nil. ;;;*** ;;;### (autoloads (mml1991-sign mml1991-encrypt) "mml1991" "gnus/mml1991.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/mml1991.el (autoload 'mml1991-encrypt "mml1991" "\ @@ -18542,7 +18647,7 @@ Not documented ;;;### (autoloads (mml2015-self-encrypt mml2015-sign mml2015-encrypt ;;;;;; mml2015-verify-test mml2015-verify mml2015-decrypt-test mml2015-decrypt) -;;;;;; "mml2015" "gnus/mml2015.el" (18212 46007)) +;;;;;; "mml2015" "gnus/mml2015.el" (18307 57866)) ;;; Generated autoloads from gnus/mml2015.el (autoload 'mml2015-decrypt "mml2015" "\ @@ -18583,7 +18688,7 @@ Not documented ;;;*** ;;;### (autoloads (modula-2-mode) "modula2" "progmodes/modula2.el" -;;;;;; (18130 62049)) +;;;;;; (18131 3995)) ;;; Generated autoloads from progmodes/modula2.el (autoload 'modula-2-mode "modula2" "\ @@ -18615,7 +18720,7 @@ followed by the first character of the construct. ;;;*** ;;;### (autoloads (unmorse-region morse-region) "morse" "play/morse.el" -;;;;;; (18088 55114)) +;;;;;; (18307 57870)) ;;; Generated autoloads from play/morse.el (autoload 'morse-region "morse" "\ @@ -18630,8 +18735,8 @@ Convert morse coded text in region to ordinary ASCII text. ;;;*** -;;;### (autoloads (mouse-sel-mode) "mouse-sel" "mouse-sel.el" (18088 -;;;;;; 55087)) +;;;### (autoloads (mouse-sel-mode) "mouse-sel" "mouse-sel.el" (18307 +;;;;;; 57856)) ;;; Generated autoloads from mouse-sel.el (defvar mouse-sel-mode nil "\ @@ -18683,7 +18788,7 @@ primary selection and region. ;;;*** -;;;### (autoloads (mpuz) "mpuz" "play/mpuz.el" (18088 55114)) +;;;### (autoloads (mpuz) "mpuz" "play/mpuz.el" (18307 57870)) ;;; Generated autoloads from play/mpuz.el (autoload 'mpuz "mpuz" "\ @@ -18693,7 +18798,7 @@ Multiplication puzzle with GNU Emacs. ;;;*** -;;;### (autoloads (msb-mode) "msb" "msb.el" (18211 32385)) +;;;### (autoloads (msb-mode) "msb" "msb.el" (18302 4831)) ;;; Generated autoloads from msb.el (defvar msb-mode nil "\ @@ -18720,7 +18825,7 @@ different buffer menu using the function `msb'. ;;;;;; describe-current-coding-system describe-current-coding-system-briefly ;;;;;; describe-coding-system describe-character-set list-charset-chars ;;;;;; read-charset list-character-sets) "mule-diag" "international/mule-diag.el" -;;;;;; (18173 8195)) +;;;;;; (18307 57867)) ;;; Generated autoloads from international/mule-diag.el (defvar non-iso-charset-alist `((mac-roman (ascii latin-iso8859-1 mule-unicode-2500-33ff mule-unicode-0100-24ff mule-unicode-e000-ffff) mac-roman-decoder ((0 255))) (viscii (ascii vietnamese-viscii-lower vietnamese-viscii-upper) viet-viscii-nonascii-translation-table ((0 255))) (vietnamese-tcvn (ascii vietnamese-viscii-lower vietnamese-viscii-upper) viet-tcvn-nonascii-translation-table ((0 255))) (koi8-r (ascii cyrillic-iso8859-5) cyrillic-koi8-r-nonascii-translation-table ((32 255))) (alternativnyj (ascii cyrillic-iso8859-5) cyrillic-alternativnyj-nonascii-translation-table ((32 255))) (koi8-u (ascii cyrillic-iso8859-5 mule-unicode-0100-24ff) cyrillic-koi8-u-nonascii-translation-table ((32 255))) (big5 (ascii chinese-big5-1 chinese-big5-2) decode-big5-char ((32 127) ((161 254) 64 126 161 254))) (sjis (ascii katakana-jisx0201 japanese-jisx0208) decode-sjis-char ((32 127 161 223) ((129 159 224 239) 64 126 128 252)))) "\ @@ -18894,7 +18999,7 @@ system which uses fontsets). ;;;;;; coding-system-translation-table-for-decode coding-system-pre-write-conversion ;;;;;; coding-system-post-read-conversion lookup-nested-alist set-nested-alist ;;;;;; truncate-string-to-width store-substring string-to-sequence) -;;;;;; "mule-util" "international/mule-util.el" (18088 55108)) +;;;;;; "mule-util" "international/mule-util.el" (18307 57867)) ;;; Generated autoloads from international/mule-util.el (autoload 'string-to-sequence "mule-util" "\ @@ -19023,7 +19128,7 @@ basis, this may not be accurate. ;;;*** ;;;### (autoloads (mwheel-install mouse-wheel-mode) "mwheel" "mwheel.el" -;;;;;; (18088 55087)) +;;;;;; (18307 57856)) ;;; Generated autoloads from mwheel.el (defvar mouse-wheel-mode nil "\ @@ -19052,7 +19157,7 @@ Enable mouse wheel support. ;;;### (autoloads (network-connection network-connection-to-service ;;;;;; whois-reverse-lookup whois finger ftp run-dig dns-lookup-host ;;;;;; nslookup nslookup-host route arp netstat ipconfig ping traceroute) -;;;;;; "net-utils" "net/net-utils.el" (18088 55112)) +;;;;;; "net-utils" "net/net-utils.el" (18307 57870)) ;;; Generated autoloads from net/net-utils.el (autoload 'traceroute "net-utils" "\ @@ -19148,7 +19253,7 @@ Open a network connection to HOST on PORT. ;;;;;; uncomment-region comment-kill comment-set-column comment-indent ;;;;;; comment-indent-default comment-normalize-vars comment-multi-line ;;;;;; comment-padding comment-style comment-column) "newcomment" -;;;;;; "newcomment.el" (18210 13714)) +;;;;;; "newcomment.el" (18307 57856)) ;;; Generated autoloads from newcomment.el (defalias 'indent-for-comment 'comment-indent) @@ -19310,7 +19415,8 @@ Call the comment command you want (Do What I Mean). If the region is active and `transient-mark-mode' is on, call `comment-region' (unless it only consists of comments, in which case it calls `uncomment-region'). -Else, if the current line is empty, insert a comment and indent it. +Else, if the current line is empty, call `comment-insert-comment-function' +if it is defined, otherwise insert a comment and indent it. Else if a prefix ARG is specified, call `comment-kill'. Else, call `comment-indent'. You can configure `comment-style' to change the way regions are commented. @@ -19344,7 +19450,7 @@ unless optional argument SOFT is non-nil. ;;;### (autoloads (newsticker-show-news newsticker-start-ticker newsticker-start ;;;;;; newsticker-ticker-running-p newsticker-running-p) "newsticker" -;;;;;; "net/newsticker.el" (18088 55112)) +;;;;;; "net/newsticker.el" (18307 57870)) ;;; Generated autoloads from net/newsticker.el (autoload 'newsticker-running-p "newsticker" "\ @@ -19386,7 +19492,7 @@ Switch to newsticker buffer. You may want to bind this to a key. ;;;*** ;;;### (autoloads (nndiary-generate-nov-databases) "nndiary" "gnus/nndiary.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/nndiary.el (autoload 'nndiary-generate-nov-databases "nndiary" "\ @@ -19396,8 +19502,8 @@ Generate NOV databases in all nndiary directories. ;;;*** -;;;### (autoloads (nndoc-add-type) "nndoc" "gnus/nndoc.el" (18212 -;;;;;; 46007)) +;;;### (autoloads (nndoc-add-type) "nndoc" "gnus/nndoc.el" (18307 +;;;;;; 57866)) ;;; Generated autoloads from gnus/nndoc.el (autoload 'nndoc-add-type "nndoc" "\ @@ -19412,7 +19518,7 @@ symbol in the alist. ;;;*** ;;;### (autoloads (nnfolder-generate-active-file) "nnfolder" "gnus/nnfolder.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/nnfolder.el (autoload 'nnfolder-generate-active-file "nnfolder" "\ @@ -19424,7 +19530,7 @@ This command does not work if you use short group names. ;;;*** ;;;### (autoloads (nnkiboze-generate-groups) "nnkiboze" "gnus/nnkiboze.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/nnkiboze.el (autoload 'nnkiboze-generate-groups "nnkiboze" "\ @@ -19436,7 +19542,7 @@ Finds out what articles are to be part of the nnkiboze groups. ;;;*** ;;;### (autoloads (nnml-generate-nov-databases) "nnml" "gnus/nnml.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/nnml.el (autoload 'nnml-generate-nov-databases "nnml" "\ @@ -19447,7 +19553,7 @@ Generate NOV databases in all nnml directories. ;;;*** ;;;### (autoloads (nnsoup-revert-variables nnsoup-set-variables nnsoup-pack-replies) -;;;;;; "nnsoup" "gnus/nnsoup.el" (18212 46007)) +;;;;;; "nnsoup" "gnus/nnsoup.el" (18307 57866)) ;;; Generated autoloads from gnus/nnsoup.el (autoload 'nnsoup-pack-replies "nnsoup" "\ @@ -19468,7 +19574,7 @@ Revert posting and mailing methods to the standard Emacs methods. ;;;*** ;;;### (autoloads (disable-command enable-command disabled-command-function) -;;;;;; "novice" "novice.el" (18088 55087)) +;;;;;; "novice" "novice.el" (18307 57856)) ;;; Generated autoloads from novice.el (defvar disabled-command-function 'disabled-command-function "\ @@ -19501,7 +19607,7 @@ to future sessions. ;;;*** ;;;### (autoloads (nroff-mode) "nroff-mode" "textmodes/nroff-mode.el" -;;;;;; (18120 34753)) +;;;;;; (18307 57874)) ;;; Generated autoloads from textmodes/nroff-mode.el (autoload 'nroff-mode "nroff-mode" "\ @@ -19513,10 +19619,99 @@ closing requests for requests that are used in matched pairs. \(fn)" t nil) +;;;*** + +;;;### (autoloads (nxml-glyph-display-string) "nxml-glyph" "nxml/nxml-glyph.el" +;;;;;; (18308 19808)) +;;; Generated autoloads from nxml/nxml-glyph.el + +(autoload 'nxml-glyph-display-string "nxml-glyph" "\ +Return a string that can display a glyph for Unicode code-point N. +FACE gives the face that will be used for displaying the string. +Return nil if the face cannot display a glyph for N. + +\(fn N FACE)" nil nil) + +;;;*** + +;;;### (autoloads (nxml-mode) "nxml-mode" "nxml/nxml-mode.el" (18313 +;;;;;; 19474)) +;;; Generated autoloads from nxml/nxml-mode.el + +(autoload 'nxml-mode "nxml-mode" "\ +Major mode for editing XML. + +Syntax highlighting is performed unless the variable +`nxml-syntax-highlight-flag' is nil. + +\\[nxml-finish-element] finishes the current element by inserting an end-tag. +C-c C-i closes a start-tag with `>' and then inserts a balancing end-tag +leaving point between the start-tag and end-tag. +\\[nxml-balanced-close-start-tag-block] is similar but for block rather than inline elements: +the start-tag, point, and end-tag are all left on separate lines. +If `nxml-slash-auto-complete-flag' is non-nil, then inserting a ` ;;;*** ;;;### (autoloads (pp-eval-last-sexp pp-eval-expression pp pp-buffer -;;;;;; pp-to-string) "pp" "emacs-lisp/pp.el" (18098 47345)) +;;;;;; pp-to-string) "pp" "emacs-lisp/pp.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/pp.el (autoload 'pp-to-string "pp" "\ @@ -21040,7 +21230,7 @@ Ignores leading comment characters. ;;;;;; pr-ps-buffer-print pr-ps-buffer-using-ghostscript pr-ps-buffer-preview ;;;;;; pr-ps-directory-ps-print pr-ps-directory-print pr-ps-directory-using-ghostscript ;;;;;; pr-ps-directory-preview pr-interface) "printing" "printing.el" -;;;;;; (18211 32385)) +;;;;;; (18307 57857)) ;;; Generated autoloads from printing.el (autoload 'pr-interface "printing" "\ @@ -21628,7 +21818,7 @@ are both set to t. ;;;*** ;;;### (autoloads (switch-to-prolog prolog-mode) "prolog" "progmodes/prolog.el" -;;;;;; (18203 37789)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/prolog.el (autoload 'prolog-mode "prolog" "\ @@ -21651,7 +21841,7 @@ With prefix argument \\[universal-prefix], prompt for the program to use. ;;;*** -;;;### (autoloads nil "ps-bdf" "ps-bdf.el" (18088 55088)) +;;;### (autoloads nil "ps-bdf" "ps-bdf.el" (18307 57857)) ;;; Generated autoloads from ps-bdf.el (defvar bdf-directory-list (if (memq system-type '(ms-dos windows-nt)) (list (expand-file-name "fonts/bdf" installation-directory)) '("/usr/local/share/emacs/fonts/bdf")) "\ @@ -21660,8 +21850,8 @@ The default value is '(\"/usr/local/share/emacs/fonts/bdf\").") ;;;*** -;;;### (autoloads (ps-mode) "ps-mode" "progmodes/ps-mode.el" (18210 -;;;;;; 13716)) +;;;### (autoloads (ps-mode) "ps-mode" "progmodes/ps-mode.el" (18307 +;;;;;; 57871)) ;;; Generated autoloads from progmodes/ps-mode.el (autoload 'ps-mode "ps-mode" "\ @@ -21712,8 +21902,8 @@ Typing \\\\[ps-run-goto-error] when the cursor is at the number ;;;;;; ps-spool-region ps-spool-buffer-with-faces ps-spool-buffer ;;;;;; ps-print-region-with-faces ps-print-region ps-print-buffer-with-faces ;;;;;; ps-print-buffer ps-print-customize ps-print-color-p ps-paper-type -;;;;;; ps-page-dimensions-database) "ps-print" "ps-print.el" (18214 -;;;;;; 4479)) +;;;;;; ps-page-dimensions-database) "ps-print" "ps-print.el" (18309 +;;;;;; 34405)) ;;; Generated autoloads from ps-print.el (defvar ps-page-dimensions-database (list (list 'a4 (/ (* 72 21.0) 2.54) (/ (* 72 29.7) 2.54) "A4") (list 'a3 (/ (* 72 29.7) 2.54) (/ (* 72 42.0) 2.54) "A3") (list 'letter (* 72 8.5) (* 72 11.0) "Letter") (list 'legal (* 72 8.5) (* 72 14.0) "Legal") (list 'letter-small (* 72 7.68) (* 72 10.16) "LetterSmall") (list 'tabloid (* 72 11.0) (* 72 17.0) "Tabloid") (list 'ledger (* 72 17.0) (* 72 11.0) "Ledger") (list 'statement (* 72 5.5) (* 72 8.5) "Statement") (list 'executive (* 72 7.5) (* 72 10.0) "Executive") (list 'a4small (* 72 7.47) (* 72 10.85) "A4Small") (list 'b4 (* 72 10.125) (* 72 14.33) "B4") (list 'b5 (* 72 7.16) (* 72 10.125) "B5")) "\ @@ -21910,7 +22100,7 @@ If EXTENSION is any other symbol, it is ignored. ;;;*** ;;;### (autoloads (jython-mode python-mode run-python) "python" "progmodes/python.el" -;;;;;; (18208 48754)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/python.el (add-to-list 'interpreter-mode-alist '("jython" . jython-mode)) @@ -21985,7 +22175,7 @@ Runs `jython-mode-hook' after `python-mode-hook'. ;;;*** ;;;### (autoloads (quoted-printable-decode-region) "qp" "gnus/qp.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/qp.el (autoload 'quoted-printable-decode-region "qp" "\ @@ -22008,7 +22198,7 @@ them into characters should be done separately. ;;;;;; quail-defrule quail-install-decode-map quail-install-map ;;;;;; quail-define-rules quail-show-keyboard-layout quail-set-keyboard-layout ;;;;;; quail-define-package quail-use-package quail-title) "quail" -;;;;;; "international/quail.el" (18120 34751)) +;;;;;; "international/quail.el" (18307 57867)) ;;; Generated autoloads from international/quail.el (autoload 'quail-title "quail" "\ @@ -22239,8 +22429,8 @@ of each directory. ;;;### (autoloads (quickurl-list quickurl-list-mode quickurl-edit-urls ;;;;;; quickurl-browse-url-ask quickurl-browse-url quickurl-add-url -;;;;;; quickurl-ask quickurl) "quickurl" "net/quickurl.el" (18088 -;;;;;; 55112)) +;;;;;; quickurl-ask quickurl) "quickurl" "net/quickurl.el" (18307 +;;;;;; 57870)) ;;; Generated autoloads from net/quickurl.el (defconst quickurl-reread-hook-postfix "\n;; Local Variables:\n;; eval: (progn (require 'quickurl) (add-hook 'local-write-file-hooks (lambda () (quickurl-read) nil)))\n;; End:\n" "\ @@ -22312,7 +22502,7 @@ Display `quickurl-list' as a formatted list using `quickurl-list-mode'. ;;;*** ;;;### (autoloads (rcirc-track-minor-mode rcirc-connect rcirc) "rcirc" -;;;;;; "net/rcirc.el" (18213 14317)) +;;;;;; "net/rcirc.el" (18307 57870)) ;;; Generated autoloads from net/rcirc.el (autoload 'rcirc "rcirc" "\ @@ -22347,8 +22537,8 @@ Global minor mode for tracking activity in rcirc buffers. ;;;*** -;;;### (autoloads (remote-compile) "rcompile" "net/rcompile.el" (18088 -;;;;;; 55112)) +;;;### (autoloads (remote-compile) "rcompile" "net/rcompile.el" (18307 +;;;;;; 57870)) ;;; Generated autoloads from net/rcompile.el (autoload 'remote-compile "rcompile" "\ @@ -22360,7 +22550,7 @@ See \\[compile]. ;;;*** ;;;### (autoloads (re-builder) "re-builder" "emacs-lisp/re-builder.el" -;;;;;; (18173 8195)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/re-builder.el (defalias 'regexp-builder 're-builder) @@ -22372,7 +22562,7 @@ Construct a regexp interactively. ;;;*** -;;;### (autoloads (recentf-mode) "recentf" "recentf.el" (18161 20994)) +;;;### (autoloads (recentf-mode) "recentf" "recentf.el" (18307 57858)) ;;; Generated autoloads from recentf.el (defvar recentf-mode nil "\ @@ -22399,8 +22589,8 @@ that were operated on recently. ;;;### (autoloads (clear-rectangle string-insert-rectangle string-rectangle ;;;;;; delete-whitespace-rectangle open-rectangle insert-rectangle ;;;;;; yank-rectangle kill-rectangle extract-rectangle delete-extract-rectangle -;;;;;; delete-rectangle move-to-column-force) "rect" "rect.el" (18088 -;;;;;; 55088)) +;;;;;; delete-rectangle move-to-column-force) "rect" "rect.el" (18307 +;;;;;; 57858)) ;;; Generated autoloads from rect.el (autoload 'move-to-column-force "rect" "\ @@ -22528,8 +22718,8 @@ rectangle which were empty. ;;;*** -;;;### (autoloads (refill-mode) "refill" "textmodes/refill.el" (18120 -;;;;;; 34753)) +;;;### (autoloads (refill-mode) "refill" "textmodes/refill.el" (18307 +;;;;;; 57874)) ;;; Generated autoloads from textmodes/refill.el (autoload 'refill-mode "refill" "\ @@ -22545,7 +22735,7 @@ refilling if they would cause auto-filling. ;;;*** ;;;### (autoloads (reftex-reset-scanning-information reftex-mode -;;;;;; turn-on-reftex) "reftex" "textmodes/reftex.el" (18203 37790)) +;;;;;; turn-on-reftex) "reftex" "textmodes/reftex.el" (18307 57874)) ;;; Generated autoloads from textmodes/reftex.el (autoload 'turn-on-reftex "reftex" "\ @@ -22595,7 +22785,7 @@ This enforces rescanning the buffer on next use. ;;;*** ;;;### (autoloads (reftex-citation) "reftex-cite" "textmodes/reftex-cite.el" -;;;;;; (18191 7159)) +;;;;;; (18307 57874)) ;;; Generated autoloads from textmodes/reftex-cite.el (autoload 'reftex-citation "reftex-cite" "\ @@ -22625,7 +22815,7 @@ While entering the regexp, completion on knows citation keys is possible. ;;;*** ;;;### (autoloads (reftex-isearch-minor-mode) "reftex-global" "textmodes/reftex-global.el" -;;;;;; (18120 34753)) +;;;;;; (18307 57874)) ;;; Generated autoloads from textmodes/reftex-global.el (autoload 'reftex-isearch-minor-mode "reftex-global" "\ @@ -22642,7 +22832,7 @@ With no argument, this command toggles ;;;*** ;;;### (autoloads (reftex-index-phrases-mode) "reftex-index" "textmodes/reftex-index.el" -;;;;;; (18088 55120)) +;;;;;; (18307 57874)) ;;; Generated autoloads from textmodes/reftex-index.el (autoload 'reftex-index-phrases-mode "reftex-index" "\ @@ -22675,7 +22865,7 @@ Here are all local bindings. ;;;*** ;;;### (autoloads (reftex-all-document-files) "reftex-parse" "textmodes/reftex-parse.el" -;;;;;; (18088 55120)) +;;;;;; (18307 57874)) ;;; Generated autoloads from textmodes/reftex-parse.el (autoload 'reftex-all-document-files "reftex-parse" "\ @@ -22687,8 +22877,8 @@ of master file. ;;;*** -;;;### (autoloads nil "reftex-vars" "textmodes/reftex-vars.el" (18088 -;;;;;; 55120)) +;;;### (autoloads nil "reftex-vars" "textmodes/reftex-vars.el" (18307 +;;;;;; 57874)) ;;; Generated autoloads from textmodes/reftex-vars.el (put 'reftex-vref-is-default 'safe-local-variable (lambda (x) (or (stringp x) (symbolp x)))) (put 'reftex-fref-is-default 'safe-local-variable (lambda (x) (or (stringp x) (symbolp x)))) @@ -22698,7 +22888,7 @@ of master file. ;;;*** ;;;### (autoloads (regexp-opt-depth regexp-opt) "regexp-opt" "emacs-lisp/regexp-opt.el" -;;;;;; (18088 55096)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/regexp-opt.el (autoload 'regexp-opt "regexp-opt" "\ @@ -22725,7 +22915,40 @@ This means the number of non-shy regexp grouping constructs ;;;*** -;;;### (autoloads (repeat) "repeat" "repeat.el" (18187 36839)) +;;;### (autoloads (remember-diary-extract-entries remember-clipboard +;;;;;; remember-other-frame remember) "remember" "textmodes/remember.el" +;;;;;; (18308 19808)) +;;; Generated autoloads from textmodes/remember.el + +(autoload 'remember "remember" "\ +Remember an arbitrary piece of data. +INITIAL is the text to initially place in the *Remember* buffer, +or nil to bring up a blank *Remember* buffer. + +With a prefix or a visible region, use the region as INITIAL. + +\(fn &optional INITIAL)" t nil) + +(autoload 'remember-other-frame "remember" "\ +Call `remember' in another frame. + +\(fn &optional INITIAL)" t nil) + +(autoload 'remember-clipboard "remember" "\ +Remember the contents of the current clipboard. +Most useful for remembering things from Netscape or other X Windows +application. + +\(fn)" t nil) + +(autoload 'remember-diary-extract-entries "remember" "\ +Extract diary entries from the region. + +\(fn)" nil nil) + +;;;*** + +;;;### (autoloads (repeat) "repeat" "repeat.el" (18307 57859)) ;;; Generated autoloads from repeat.el (autoload 'repeat "repeat" "\ @@ -22748,7 +22971,7 @@ recently executed command not bound to an input event\". ;;;*** ;;;### (autoloads (reporter-submit-bug-report) "reporter" "mail/reporter.el" -;;;;;; (18192 17587)) +;;;;;; (18307 57869)) ;;; Generated autoloads from mail/reporter.el (autoload 'reporter-submit-bug-report "reporter" "\ @@ -22780,7 +23003,7 @@ mail-sending package is used for editing and sending the message. ;;;*** ;;;### (autoloads (reposition-window) "reposition" "reposition.el" -;;;;;; (18088 55088)) +;;;;;; (18307 57859)) ;;; Generated autoloads from reposition.el (autoload 'reposition-window "reposition" "\ @@ -22803,12 +23026,11 @@ comments, including the first comment line, are visible), or to make the first comment line visible (if point is in a comment). \(fn &optional ARG)" t nil) - (define-key esc-map "\C-l" 'reposition-window) ;;;*** -;;;### (autoloads (resume-suspend-hook) "resume" "resume.el" (18088 -;;;;;; 55088)) +;;;### (autoloads (resume-suspend-hook) "resume" "resume.el" (18307 +;;;;;; 57859)) ;;; Generated autoloads from resume.el (autoload 'resume-suspend-hook "resume" "\ @@ -22819,7 +23041,7 @@ Clear out the file used for transmitting args when Emacs resumes. ;;;*** ;;;### (autoloads (global-reveal-mode reveal-mode) "reveal" "reveal.el" -;;;;;; (18088 55088)) +;;;;;; (18307 57859)) ;;; Generated autoloads from reveal.el (autoload 'reveal-mode "reveal" "\ @@ -22854,7 +23076,7 @@ With zero or negative ARG turn mode off. ;;;*** ;;;### (autoloads (make-ring ring-p) "ring" "emacs-lisp/ring.el" -;;;;;; (18197 21672)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/ring.el (autoload 'ring-p "ring" "\ @@ -22869,7 +23091,7 @@ Make a ring that can contain SIZE elements. ;;;*** -;;;### (autoloads (rlogin) "rlogin" "net/rlogin.el" (18088 55112)) +;;;### (autoloads (rlogin) "rlogin" "net/rlogin.el" (18307 57870)) ;;; Generated autoloads from net/rlogin.el (add-hook 'same-window-regexps "^\\*rlogin-.*\\*\\(\\|<[0-9]+>\\)") @@ -22920,8 +23142,8 @@ variable. ;;;;;; rmail-mail-new-frame rmail-primary-inbox-list rmail-delete-after-output ;;;;;; rmail-highlight-face rmail-highlighted-headers rmail-retry-ignored-headers ;;;;;; rmail-displayed-headers rmail-ignored-headers rmail-dont-reply-to-names -;;;;;; rmail-movemail-variant-p) "rmail" "mail/rmail.el" (18191 -;;;;;; 7159)) +;;;;;; rmail-movemail-variant-p) "rmail" "mail/rmail.el" (18314 +;;;;;; 32066)) ;;; Generated autoloads from mail/rmail.el (autoload 'rmail-movemail-variant-p "rmail" "\ @@ -23186,7 +23408,7 @@ Set PASSWORD to be used for retrieving mail from a POP or IMAP server. ;;;*** ;;;### (autoloads (rmail-edit-current-message) "rmailedit" "mail/rmailedit.el" -;;;;;; (18088 55110)) +;;;;;; (18307 57869)) ;;; Generated autoloads from mail/rmailedit.el (autoload 'rmail-edit-current-message "rmailedit" "\ @@ -23198,7 +23420,7 @@ Edit the contents of this message. ;;;### (autoloads (rmail-next-labeled-message rmail-previous-labeled-message ;;;;;; rmail-read-label rmail-kill-label rmail-add-label) "rmailkwd" -;;;;;; "mail/rmailkwd.el" (18088 55110)) +;;;;;; "mail/rmailkwd.el" (18307 57869)) ;;; Generated autoloads from mail/rmailkwd.el (autoload 'rmail-add-label "rmailkwd" "\ @@ -23237,7 +23459,7 @@ With prefix argument N moves forward N messages with these labels. ;;;*** ;;;### (autoloads (set-rmail-inbox-list) "rmailmsc" "mail/rmailmsc.el" -;;;;;; (18088 55110)) +;;;;;; (18307 57869)) ;;; Generated autoloads from mail/rmailmsc.el (autoload 'set-rmail-inbox-list "rmailmsc" "\ @@ -23251,7 +23473,7 @@ If FILE-NAME is empty, remove any existing inbox list. ;;;### (autoloads (rmail-output-body-to-file rmail-output rmail-fields-not-to-output ;;;;;; rmail-output-to-rmail-file rmail-output-file-alist) "rmailout" -;;;;;; "mail/rmailout.el" (18088 55110)) +;;;;;; "mail/rmailout.el" (18307 57869)) ;;; Generated autoloads from mail/rmailout.el (defvar rmail-output-file-alist nil "\ @@ -23318,8 +23540,8 @@ FILE-NAME defaults, interactively, from the Subject field of the message. ;;;### (autoloads (rmail-sort-by-labels rmail-sort-by-lines rmail-sort-by-correspondent ;;;;;; rmail-sort-by-recipient rmail-sort-by-author rmail-sort-by-subject -;;;;;; rmail-sort-by-date) "rmailsort" "mail/rmailsort.el" (18088 -;;;;;; 55110)) +;;;;;; rmail-sort-by-date) "rmailsort" "mail/rmailsort.el" (18307 +;;;;;; 57869)) ;;; Generated autoloads from mail/rmailsort.el (autoload 'rmail-sort-by-date "rmailsort" "\ @@ -23371,7 +23593,7 @@ KEYWORDS is a comma-separated list of labels. ;;;;;; rmail-summary-by-senders rmail-summary-by-topic rmail-summary-by-regexp ;;;;;; rmail-summary-by-recipients rmail-summary-by-labels rmail-summary ;;;;;; rmail-summary-line-count-flag rmail-summary-scroll-between-messages) -;;;;;; "rmailsum" "mail/rmailsum.el" (18101 9759)) +;;;;;; "rmailsum" "mail/rmailsum.el" (18307 57869)) ;;; Generated autoloads from mail/rmailsum.el (defvar rmail-summary-scroll-between-messages t "\ @@ -23450,10 +23672,93 @@ Setting this variable has an effect only before reading a mail.") (custom-autoload 'rmail-user-mail-address-regexp "rmailsum" t) +;;;*** + +;;;### (autoloads (rng-c-load-schema) "rng-cmpct" "nxml/rng-cmpct.el" +;;;;;; (18308 19808)) +;;; Generated autoloads from nxml/rng-cmpct.el + +(autoload 'rng-c-load-schema "rng-cmpct" "\ +Load a schema in RELAX NG compact syntax from FILENAME. +Return a pattern. + +\(fn FILENAME)" nil nil) + +;;;*** + +;;;### (autoloads (rng-nxml-mode-init) "rng-nxml" "nxml/rng-nxml.el" +;;;;;; (18312 40673)) +;;; Generated autoloads from nxml/rng-nxml.el + +(autoload 'rng-nxml-mode-init "rng-nxml" "\ +Initialize `nxml-mode' to take advantage of `rng-validate-mode'. +This is typically called from `nxml-mode-hook'. +Validation will be enabled if `rng-nxml-auto-validate-flag' is non-nil. + +\(fn)" t nil) + +;;;*** + +;;;### (autoloads (rng-validate-mode) "rng-valid" "nxml/rng-valid.el" +;;;;;; (18308 19808)) +;;; Generated autoloads from nxml/rng-valid.el + +(autoload 'rng-validate-mode "rng-valid" "\ +Minor mode performing continual validation against a RELAX NG schema. + +Checks whether the buffer is a well-formed XML 1.0 document, +conforming to the XML Namespaces Recommendation and valid against a +RELAX NG schema. The mode-line indicates whether it is or not. Any +parts of the buffer that cause it not to be are considered errors and +are highlighted with face `rng-error'. A description of each error is +available as a tooltip. \\[rng-next-error] goes to the next error +after point. Clicking mouse-1 on the word `Invalid' in the mode-line +goes to the first error in the buffer. If the buffer changes, then it +will be automatically rechecked when Emacs becomes idle; the +rechecking will be paused whenever there is input pending.. + +By default, uses a vacuous schema that allows any well-formed XML +document. A schema can be specified explictly using +\\[rng-set-schema-file-and-validate], or implicitly based on the buffer's +file name or on the root element name. In each case the schema must +be a RELAX NG schema using the compact schema (such schemas +conventionally have a suffix of `.rnc'). The variable +`rng-schema-locating-files' specifies files containing rules +to use for finding the schema. + +\(fn &optional ARG NO-CHANGE-SCHEMA)" t nil) + +;;;*** + +;;;### (autoloads (rng-xsd-compile) "rng-xsd" "nxml/rng-xsd.el" (18308 +;;;;;; 19808)) +;;; Generated autoloads from nxml/rng-xsd.el + +(put 'http://www\.w3\.org/2001/XMLSchema-datatypes 'rng-dt-compile 'rng-xsd-compile) + +(autoload 'rng-xsd-compile "rng-xsd" "\ +Provides W3C XML Schema as a RELAX NG datatypes library. NAME is a +symbol giving the local name of the datatype. PARAMS is a list of +pairs (PARAM-NAME . PARAM-VALUE) where PARAM-NAME is a symbol giving +the name of the parameter and PARAM-VALUE is a string giving its +value. If NAME or PARAMS are invalid, it calls rng-dt-error passing +it arguments in the same style as format; the value from rng-dt-error +will be returned. Otherwise, it returns a list. The first member of +the list is t if any string is a legal value for the datatype and nil +otherwise. The second argument is a symbol; this symbol will be +called as a function passing it a string followed by the remaining +members of the list. The function must return an object representing +the value of the datatype that was represented by the string, or nil +if the string is not a representation of any value. The object +returned can be any convenient non-nil value, provided that, if two +strings represent the same value, the returned objects must be equal. + +\(fn NAME PARAMS)" nil nil) + ;;;*** ;;;### (autoloads (toggle-rot13-mode rot13-other-window rot13-region -;;;;;; rot13-string rot13) "rot13" "rot13.el" (18088 55088)) +;;;;;; rot13-string rot13) "rot13" "rot13.el" (18307 57859)) ;;; Generated autoloads from rot13.el (autoload 'rot13 "rot13" "\ @@ -23490,8 +23795,8 @@ Toggle the use of ROT13 encoding for the current window. ;;;*** -;;;### (autoloads (ruler-mode) "ruler-mode" "ruler-mode.el" (18088 -;;;;;; 55088)) +;;;### (autoloads (ruler-mode) "ruler-mode" "ruler-mode.el" (18307 +;;;;;; 57859)) ;;; Generated autoloads from ruler-mode.el (autoload 'ruler-mode "ruler-mode" "\ @@ -23501,8 +23806,8 @@ Display a ruler in the header line if ARG > 0. ;;;*** -;;;### (autoloads (rx rx-to-string) "rx" "emacs-lisp/rx.el" (18142 -;;;;;; 63529)) +;;;### (autoloads (rx rx-to-string) "rx" "emacs-lisp/rx.el" (18307 +;;;;;; 57861)) ;;; Generated autoloads from emacs-lisp/rx.el (autoload 'rx-to-string "rx" "\ @@ -23815,7 +24120,7 @@ enclosed in `(and ...)'. ;;;*** ;;;### (autoloads (savehist-mode savehist-mode) "savehist" "savehist.el" -;;;;;; (18211 32385)) +;;;;;; (18301 36271)) ;;; Generated autoloads from savehist.el (defvar savehist-mode nil "\ @@ -23841,7 +24146,7 @@ which is probably undesirable. ;;;*** ;;;### (autoloads (dsssl-mode scheme-mode) "scheme" "progmodes/scheme.el" -;;;;;; (18120 34753)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/scheme.el (autoload 'scheme-mode "scheme" "\ @@ -23883,7 +24188,7 @@ that variable's value is a string. ;;;*** ;;;### (autoloads (gnus-score-mode) "score-mode" "gnus/score-mode.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/score-mode.el (autoload 'gnus-score-mode "score-mode" "\ @@ -23897,7 +24202,7 @@ This mode is an extended emacs-lisp mode. ;;;*** ;;;### (autoloads (scroll-all-mode) "scroll-all" "scroll-all.el" -;;;;;; (18088 55088)) +;;;;;; (18307 57859)) ;;; Generated autoloads from scroll-all.el (defvar scroll-all-mode nil "\ @@ -23920,7 +24225,7 @@ apply to all visible windows in the same frame. ;;;*** ;;;### (autoloads (scroll-lock-mode) "scroll-lock" "scroll-lock.el" -;;;;;; (18202 3996)) +;;;;;; (18307 57859)) ;;; Generated autoloads from scroll-lock.el (autoload 'scroll-lock-mode "scroll-lock" "\ @@ -23942,7 +24247,7 @@ during scrolling. ;;;;;; mail-alias-file mail-default-reply-to mail-archive-file-name ;;;;;; mail-header-separator send-mail-function mail-interactive ;;;;;; mail-self-blind mail-specify-envelope-from mail-from-style) -;;;;;; "sendmail" "mail/sendmail.el" (18197 21674)) +;;;;;; "sendmail" "mail/sendmail.el" (18307 57869)) ;;; Generated autoloads from mail/sendmail.el (defvar mail-from-style 'angles "\ @@ -24243,7 +24548,7 @@ Like `mail' command, but display mail buffer in another frame. ;;;*** ;;;### (autoloads (server-save-buffers-kill-terminal server-mode -;;;;;; server-start) "server" "server.el" (18213 13926)) +;;;;;; server-start) "server" "server.el" (18301 36271)) ;;; Generated autoloads from server.el (autoload 'server-start "server" "\ @@ -24287,7 +24592,7 @@ only these files will be asked to be saved. ;;;*** -;;;### (autoloads (ses-mode) "ses" "ses.el" (18209 8664)) +;;;### (autoloads (ses-mode) "ses" "ses.el" (18307 57859)) ;;; Generated autoloads from ses.el (autoload 'ses-mode "ses" "\ @@ -24306,7 +24611,7 @@ These are active only in the minibuffer, when entering or editing a formula: ;;;*** ;;;### (autoloads (html-mode sgml-mode) "sgml-mode" "textmodes/sgml-mode.el" -;;;;;; (18120 34753)) +;;;;;; (18309 34405)) ;;; Generated autoloads from textmodes/sgml-mode.el (autoload 'sgml-mode "sgml-mode" "\ @@ -24374,7 +24679,7 @@ To work around that, do: ;;;*** ;;;### (autoloads (sh-mode) "sh-script" "progmodes/sh-script.el" -;;;;;; (18173 8196)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/sh-script.el (put 'sh-shell 'safe-local-variable 'symbolp) @@ -24438,8 +24743,8 @@ with your script for an edit-interpret-debug cycle. ;;;*** -;;;### (autoloads (sha1) "sha1" "gnus/sha1.el" (18130 62048)) -;;; Generated autoloads from gnus/sha1.el +;;;### (autoloads (sha1) "sha1" "sha1.el" (18307 57859)) +;;; Generated autoloads from sha1.el (autoload 'sha1 "sha1" "\ Return the SHA1 (Secure Hash Algorithm) of an object. @@ -24453,7 +24758,7 @@ If BINARY is non-nil, return a string in binary form. ;;;*** ;;;### (autoloads (list-load-path-shadows) "shadow" "emacs-lisp/shadow.el" -;;;;;; (18088 55096)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/shadow.el (autoload 'list-load-path-shadows "shadow" "\ @@ -24500,8 +24805,8 @@ buffer called `*Shadows*'. Shadowings are located by calling the ;;;*** ;;;### (autoloads (shadow-initialize shadow-define-regexp-group shadow-define-literal-group -;;;;;; shadow-define-cluster) "shadowfile" "shadowfile.el" (18120 -;;;;;; 34749)) +;;;;;; shadow-define-cluster) "shadowfile" "shadowfile.el" (18307 +;;;;;; 57859)) ;;; Generated autoloads from shadowfile.el (autoload 'shadow-define-cluster "shadowfile" "\ @@ -24509,8 +24814,8 @@ Edit (or create) the definition of a cluster NAME. This is a group of hosts that share directories, so that copying to or from one of them is sufficient to update the file on all of them. Clusters are defined by a name, the network address of a primary host (the one we copy -files to), and a regular expression that matches the hostnames of all the sites -in the cluster. +files to), and a regular expression that matches the hostnames of all the +sites in the cluster. \(fn NAME)" t nil) @@ -24526,8 +24831,8 @@ specific hostnames, or names of clusters (see `shadow-define-cluster'). Make each of a group of files be shared between hosts. Prompts for regular expression; files matching this are shared between a list of sites, which are also prompted for. The filenames must be identical on all -hosts (if they aren't, use `shadow-define-literal-group' instead of this function). -Each site can be either a hostname or the name of a cluster (see +hosts (if they aren't, use `shadow-define-literal-group' instead of this +function). Each site can be either a hostname or the name of a cluster (see `shadow-define-cluster'). \(fn)" t nil) @@ -24540,7 +24845,7 @@ Set up file shadowing. ;;;*** ;;;### (autoloads (shell shell-dumb-shell-regexp) "shell" "shell.el" -;;;;;; (18212 46004)) +;;;;;; (18307 57859)) ;;; Generated autoloads from shell.el (defvar shell-dumb-shell-regexp "cmd\\(proxy\\)?\\.exe" "\ @@ -24590,7 +24895,7 @@ Otherwise, one argument `-i' is passed to the shell. ;;;*** ;;;### (autoloads (sieve-upload-and-bury sieve-upload sieve-manage) -;;;;;; "sieve" "gnus/sieve.el" (18212 46007)) +;;;;;; "sieve" "gnus/sieve.el" (18307 57866)) ;;; Generated autoloads from gnus/sieve.el (autoload 'sieve-manage "sieve" "\ @@ -24611,7 +24916,7 @@ Not documented ;;;*** ;;;### (autoloads (sieve-mode) "sieve-mode" "gnus/sieve-mode.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/sieve-mode.el (autoload 'sieve-mode "sieve-mode" "\ @@ -24626,14 +24931,14 @@ Turning on Sieve mode runs `sieve-mode-hook'. ;;;*** -;;;### (autoloads nil "simple" "simple.el" (18208 48751)) +;;;### (autoloads nil "simple" "simple.el" (18307 57859)) ;;; Generated autoloads from simple.el (put 'fill-prefix 'safe-local-variable 'string-or-null-p) ;;;*** -;;;### (autoloads (simula-mode) "simula" "progmodes/simula.el" (18088 -;;;;;; 55117)) +;;;### (autoloads (simula-mode) "simula" "progmodes/simula.el" (18307 +;;;;;; 57871)) ;;; Generated autoloads from progmodes/simula.el (autoload 'simula-mode "simula" "\ @@ -24682,7 +24987,7 @@ with no arguments, if that value is non-nil. ;;;*** ;;;### (autoloads (skeleton-pair-insert-maybe skeleton-insert skeleton-proxy-new -;;;;;; define-skeleton) "skeleton" "skeleton.el" (18120 34749)) +;;;;;; define-skeleton) "skeleton" "skeleton.el" (18307 57859)) ;;; Generated autoloads from skeleton.el (defvar skeleton-filter-function 'identity "\ @@ -24791,8 +25096,8 @@ symmetrical ones, and the same character twice for the others. ;;;*** -;;;### (autoloads (smerge-mode smerge-ediff) "smerge-mode" "smerge-mode.el" -;;;;;; (18202 3996)) +;;;### (autoloads (smerge-auto smerge-mode smerge-ediff) "smerge-mode" +;;;;;; "smerge-mode.el" (18317 11736)) ;;; Generated autoloads from smerge-mode.el (autoload 'smerge-ediff "smerge-mode" "\ @@ -24808,10 +25113,16 @@ Minor mode to simplify editing output from the diff3 program. \(fn &optional ARG)" t nil) +(autoload 'smerge-auto "smerge-mode" "\ +Turn on `smerge-mode' and move point to first conflict marker. +If no conflict maker is found, turn off `smerge-mode'. + +\(fn)" nil nil) + ;;;*** ;;;### (autoloads (smiley-buffer smiley-region) "smiley" "gnus/smiley.el" -;;;;;; (18212 46007)) +;;;;;; (18307 57866)) ;;; Generated autoloads from gnus/smiley.el (autoload 'smiley-region "smiley" "\ @@ -24829,7 +25140,7 @@ interactively. If there's no argument, do it at the current buffer ;;;*** ;;;### (autoloads (smtpmail-send-queued-mail smtpmail-send-it) "smtpmail" -;;;;;; "mail/smtpmail.el" (18088 55110)) +;;;;;; "mail/smtpmail.el" (18307 57869)) ;;; Generated autoloads from mail/smtpmail.el (autoload 'smtpmail-send-it "smtpmail" "\ @@ -24844,7 +25155,7 @@ Send mail that was queued as a result of setting `smtpmail-queue-mail'. ;;;*** -;;;### (autoloads (snake) "snake" "play/snake.el" (18088 55114)) +;;;### (autoloads (snake) "snake" "play/snake.el" (18307 57870)) ;;; Generated autoloads from play/snake.el (autoload 'snake "snake" "\ @@ -24868,7 +25179,7 @@ Snake mode keybindings: ;;;*** ;;;### (autoloads (snmpv2-mode snmp-mode) "snmp-mode" "net/snmp-mode.el" -;;;;;; (18161 20995)) +;;;;;; (18307 57870)) ;;; Generated autoloads from net/snmp-mode.el (autoload 'snmp-mode "snmp-mode" "\ @@ -24899,7 +25210,7 @@ then `snmpv2-mode-hook'. ;;;### (autoloads (solar-equinoxes-solstices sunrise-sunset calendar-location-name ;;;;;; calendar-longitude calendar-latitude calendar-time-display-form) -;;;;;; "solar" "calendar/solar.el" (18088 55094)) +;;;;;; "solar" "calendar/solar.el" (18307 57860)) ;;; Generated autoloads from calendar/solar.el (defvar calendar-time-display-form '(12-hours ":" minutes am-pm (if time-zone " (") time-zone (if time-zone ")")) "\ @@ -24970,8 +25281,8 @@ Requires floating point. ;;;*** -;;;### (autoloads (solitaire) "solitaire" "play/solitaire.el" (18173 -;;;;;; 8195)) +;;;### (autoloads (solitaire) "solitaire" "play/solitaire.el" (18307 +;;;;;; 57870)) ;;; Generated autoloads from play/solitaire.el (autoload 'solitaire "solitaire" "\ @@ -25048,7 +25359,7 @@ Pick your favourite shortcuts: ;;;### (autoloads (reverse-region sort-columns sort-regexp-fields ;;;;;; sort-fields sort-numeric-fields sort-pages sort-paragraphs -;;;;;; sort-lines sort-subr) "sort" "sort.el" (18128 32655)) +;;;;;; sort-lines sort-subr) "sort" "sort.el" (18307 57859)) ;;; Generated autoloads from sort.el (put 'sort-fold-case 'safe-local-variable 'booleanp) @@ -25192,16 +25503,16 @@ From a program takes two point or marker arguments, BEG and END. ;;;*** -;;;### (autoloads (spam-initialize) "spam" "gnus/spam.el" (18212 -;;;;;; 46007)) +;;;### (autoloads (spam-initialize) "spam" "gnus/spam.el" (18307 +;;;;;; 57866)) ;;; Generated autoloads from gnus/spam.el (autoload 'spam-initialize "spam" "\ Install the spam.el hooks and do other initialization. When SYMBOLS is given, set those variables to t. This is so you -can call spam-initialize before you set spam-use-* variables on +can call `spam-initialize' before you set spam-use-* variables on explicitly, and matters only if you need the extra headers -installed through spam-necessary-extra-headers. +installed through `spam-necessary-extra-headers'. \(fn &rest SYMBOLS)" t nil) @@ -25209,7 +25520,7 @@ installed through spam-necessary-extra-headers. ;;;### (autoloads (spam-report-deagentize spam-report-agentize spam-report-url-to-file ;;;;;; spam-report-url-ping-mm-url spam-report-process-queue) "spam-report" -;;;;;; "gnus/spam-report.el" (18212 46007)) +;;;;;; "gnus/spam-report.el" (18307 57866)) ;;; Generated autoloads from gnus/spam-report.el (autoload 'spam-report-process-queue "spam-report" "\ @@ -25252,7 +25563,7 @@ Spam reports will be queued with the method used when ;;;*** ;;;### (autoloads (speedbar-get-focus speedbar-frame-mode) "speedbar" -;;;;;; "speedbar.el" (18164 30590)) +;;;;;; "speedbar.el" (18307 57859)) ;;; Generated autoloads from speedbar.el (defalias 'speedbar 'speedbar-frame-mode) @@ -25277,7 +25588,7 @@ selected. If the speedbar frame is active, then select the attached frame. ;;;*** ;;;### (autoloads (spell-string spell-region spell-word spell-buffer) -;;;;;; "spell" "textmodes/spell.el" (18088 55120)) +;;;;;; "spell" "textmodes/spell.el" (18307 57874)) ;;; Generated autoloads from textmodes/spell.el (put 'spell-filter 'risky-local-variable t) @@ -25313,8 +25624,8 @@ Check spelling of string supplied as argument. ;;;*** -;;;### (autoloads (snarf-spooks spook) "spook" "play/spook.el" (18088 -;;;;;; 55114)) +;;;### (autoloads (snarf-spooks spook) "spook" "play/spook.el" (18307 +;;;;;; 57870)) ;;; Generated autoloads from play/spook.el (autoload 'spook "spook" "\ @@ -25332,8 +25643,8 @@ Return a vector containing the lines from `spook-phrases-file'. ;;;### (autoloads (sql-linter sql-db2 sql-interbase sql-postgres ;;;;;; sql-ms sql-ingres sql-solid sql-mysql sql-sqlite sql-informix ;;;;;; sql-sybase sql-oracle sql-product-interactive sql-mode sql-help -;;;;;; sql-add-product-keywords) "sql" "progmodes/sql.el" (18173 -;;;;;; 8196)) +;;;;;; sql-add-product-keywords) "sql" "progmodes/sql.el" (18307 +;;;;;; 57871)) ;;; Generated autoloads from progmodes/sql.el (autoload 'sql-add-product-keywords "sql" "\ @@ -25764,8 +26075,8 @@ input. See `sql-interactive-mode'. ;;;;;; strokes-mode strokes-list-strokes strokes-load-user-strokes ;;;;;; strokes-help strokes-describe-stroke strokes-do-complex-stroke ;;;;;; strokes-do-stroke strokes-read-complex-stroke strokes-read-stroke -;;;;;; strokes-global-set-stroke) "strokes" "strokes.el" (18120 -;;;;;; 34749)) +;;;;;; strokes-global-set-stroke) "strokes" "strokes.el" (18307 +;;;;;; 57859)) ;;; Generated autoloads from strokes.el (autoload 'strokes-global-set-stroke "strokes" "\ @@ -25895,7 +26206,7 @@ Studlify-case the current buffer. ;;;*** -;;;### (autoloads (locate-library) "subr" "subr.el" (18211 32385)) +;;;### (autoloads (locate-library) "subr" "subr.el" (18307 57859)) ;;; Generated autoloads from subr.el (autoload 'locate-library "subr" "\ @@ -25917,7 +26228,7 @@ and the file name is displayed in the echo area. ;;;*** ;;;### (autoloads (sc-cite-original) "supercite" "mail/supercite.el" -;;;;;; (18173 8195)) +;;;;;; (18307 57869)) ;;; Generated autoloads from mail/supercite.el (autoload 'sc-cite-original "supercite" "\ @@ -25949,8 +26260,8 @@ before, and `sc-post-hook' is run after the guts of this function. ;;;*** -;;;### (autoloads (gpm-mouse-mode) "t-mouse" "t-mouse.el" (18177 -;;;;;; 7731)) +;;;### (autoloads (gpm-mouse-mode) "t-mouse" "t-mouse.el" (18307 +;;;;;; 57859)) ;;; Generated autoloads from t-mouse.el (define-obsolete-function-alias 't-mouse-mode 'gpm-mouse-mode "23.1") @@ -25977,7 +26288,7 @@ It relies on the `gpm' daemon being activated. ;;;*** -;;;### (autoloads (tabify untabify) "tabify" "tabify.el" (18088 55089)) +;;;### (autoloads (tabify untabify) "tabify" "tabify.el" (18307 57859)) ;;; Generated autoloads from tabify.el (autoload 'untabify "tabify" "\ @@ -26012,7 +26323,7 @@ The variable `tab-width' controls the spacing of tab stops. ;;;;;; table-recognize table-insert-row-column table-insert-column ;;;;;; table-insert-row table-insert table-point-left-cell-hook ;;;;;; table-point-entered-cell-hook table-load-hook table-cell-map-hook) -;;;;;; "table" "textmodes/table.el" (18173 8196)) +;;;;;; "table" "textmodes/table.el" (18302 4831)) ;;; Generated autoloads from textmodes/table.el (defvar table-cell-map-hook nil "\ @@ -26600,7 +26911,7 @@ converts a table into plain text without frames. It is a companion to ;;;*** -;;;### (autoloads (talk talk-connect) "talk" "talk.el" (18133 2197)) +;;;### (autoloads (talk talk-connect) "talk" "talk.el" (18307 57859)) ;;; Generated autoloads from talk.el (autoload 'talk-connect "talk" "\ @@ -26615,7 +26926,7 @@ Connect to the Emacs talk group from the current X display or tty frame. ;;;*** -;;;### (autoloads (tar-mode) "tar-mode" "tar-mode.el" (18202 3996)) +;;;### (autoloads (tar-mode) "tar-mode" "tar-mode.el" (18307 57859)) ;;; Generated autoloads from tar-mode.el (autoload 'tar-mode "tar-mode" "\ @@ -26639,7 +26950,7 @@ See also: variables `tar-update-datestamp' and `tar-anal-blocksize'. ;;;*** ;;;### (autoloads (tcl-help-on-word inferior-tcl tcl-mode) "tcl" -;;;;;; "progmodes/tcl.el" (18120 34753)) +;;;;;; "progmodes/tcl.el" (18307 57871)) ;;; Generated autoloads from progmodes/tcl.el (autoload 'tcl-mode "tcl" "\ @@ -26690,7 +27001,7 @@ Prefix argument means invert sense of `tcl-use-smart-word-finder'. ;;;*** -;;;### (autoloads (rsh telnet) "telnet" "net/telnet.el" (18101 9759)) +;;;### (autoloads (rsh telnet) "telnet" "net/telnet.el" (18307 57870)) ;;; Generated autoloads from net/telnet.el (add-hook 'same-window-regexps "\\*telnet-.*\\*\\(\\|<[0-9]+>\\)") @@ -26717,8 +27028,8 @@ Normally input is edited in Emacs and sent a line at a time. ;;;*** -;;;### (autoloads (ansi-term term make-term) "term" "term.el" (18120 -;;;;;; 34749)) +;;;### (autoloads (ansi-term term make-term) "term" "term.el" (18307 +;;;;;; 57859)) ;;; Generated autoloads from term.el (autoload 'make-term "term" "\ @@ -26746,8 +27057,8 @@ Start a terminal-emulator in a new buffer. ;;;*** -;;;### (autoloads (terminal-emulator) "terminal" "terminal.el" (18088 -;;;;;; 55090)) +;;;### (autoloads (terminal-emulator) "terminal" "terminal.el" (18307 +;;;;;; 57859)) ;;; Generated autoloads from terminal.el (autoload 'terminal-emulator "terminal" "\ @@ -26784,7 +27095,7 @@ subprocess started. ;;;*** ;;;### (autoloads (testcover-this-defun) "testcover" "emacs-lisp/testcover.el" -;;;;;; (18088 55096)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/testcover.el (autoload 'testcover-this-defun "testcover" "\ @@ -26794,7 +27105,7 @@ Start coverage on function under point. ;;;*** -;;;### (autoloads (tetris) "tetris" "play/tetris.el" (18088 55114)) +;;;### (autoloads (tetris) "tetris" "play/tetris.el" (18307 57870)) ;;; Generated autoloads from play/tetris.el (autoload 'tetris "tetris" "\ @@ -26825,7 +27136,7 @@ tetris-mode keybindings: ;;;;;; tex-start-commands tex-start-options slitex-run-command latex-run-command ;;;;;; tex-run-command tex-offer-save tex-main-file tex-first-line-header-regexp ;;;;;; tex-directory tex-shell-file-name) "tex-mode" "textmodes/tex-mode.el" -;;;;;; (18211 32385)) +;;;;;; (18307 57874)) ;;; Generated autoloads from textmodes/tex-mode.el (defvar tex-shell-file-name nil "\ @@ -27127,7 +27438,7 @@ Major mode to edit DocTeX files. ;;;*** ;;;### (autoloads (texi2info texinfo-format-region texinfo-format-buffer) -;;;;;; "texinfmt" "textmodes/texinfmt.el" (18130 62049)) +;;;;;; "texinfmt" "textmodes/texinfmt.el" (18307 57874)) ;;; Generated autoloads from textmodes/texinfmt.el (autoload 'texinfo-format-buffer "texinfmt" "\ @@ -27167,7 +27478,7 @@ if large. You can use `Info-split' to do this manually. ;;;*** ;;;### (autoloads (texinfo-mode texinfo-close-quote texinfo-open-quote) -;;;;;; "texinfo" "textmodes/texinfo.el" (18149 22003)) +;;;;;; "texinfo" "textmodes/texinfo.el" (18307 57874)) ;;; Generated autoloads from textmodes/texinfo.el (defvar texinfo-open-quote "``" "\ @@ -27254,7 +27565,7 @@ value of `texinfo-mode-hook'. ;;;### (autoloads (thai-auto-composition-mode thai-composition-function ;;;;;; thai-post-read-conversion thai-compose-buffer thai-compose-string ;;;;;; thai-compose-region) "thai-util" "language/thai-util.el" -;;;;;; (18088 55109)) +;;;;;; (18307 57867)) ;;; Generated autoloads from language/thai-util.el (autoload 'thai-compose-region "thai-util" "\ @@ -27298,7 +27609,7 @@ Minor mode for automatically correct Thai character composition. ;;;### (autoloads (list-at-point number-at-point symbol-at-point ;;;;;; sexp-at-point thing-at-point bounds-of-thing-at-point forward-thing) -;;;;;; "thingatpt" "thingatpt.el" (18088 55090)) +;;;;;; "thingatpt" "thingatpt.el" (18307 57859)) ;;; Generated autoloads from thingatpt.el (autoload 'forward-thing "thingatpt" "\ @@ -27355,7 +27666,7 @@ Not documented ;;;### (autoloads (thumbs-dired-setroot thumbs-dired-show thumbs-dired-show-marked ;;;;;; thumbs-show-from-dir thumbs-find-thumb) "thumbs" "thumbs.el" -;;;;;; (18088 55090)) +;;;;;; (18307 57859)) ;;; Generated autoloads from thumbs.el (autoload 'thumbs-find-thumb "thumbs" "\ @@ -27394,7 +27705,7 @@ In dired, call the setroot program on the image at point. ;;;;;; tibetan-composition-function tibetan-decompose-string tibetan-decompose-region ;;;;;; tibetan-compose-region tibetan-compose-string tibetan-transcription-to-tibetan ;;;;;; tibetan-tibetan-to-transcription tibetan-char-p) "tibet-util" -;;;;;; "language/tibet-util.el" (18088 55109)) +;;;;;; "language/tibet-util.el" (18307 57867)) ;;; Generated autoloads from language/tibet-util.el (autoload 'tibetan-char-p "tibet-util" "\ @@ -27473,7 +27784,7 @@ Not documented ;;;*** ;;;### (autoloads (tildify-buffer tildify-region) "tildify" "textmodes/tildify.el" -;;;;;; (18088 55121)) +;;;;;; (18307 57875)) ;;; Generated autoloads from textmodes/tildify.el (autoload 'tildify-region "tildify" "\ @@ -27497,7 +27808,7 @@ This function performs no refilling of the changed text. ;;;*** ;;;### (autoloads (display-time-world display-time-mode display-time -;;;;;; display-time-day-and-date) "time" "time.el" (18211 32385)) +;;;;;; display-time-day-and-date) "time" "time.el" (18307 57859)) ;;; Generated autoloads from time.el (defvar display-time-day-and-date nil "\ @@ -27546,8 +27857,8 @@ To turn off the world time display, go to that window and type `q'. ;;;### (autoloads (safe-date-to-time time-to-days time-to-day-in-year ;;;;;; date-leap-year-p days-between date-to-day time-add time-subtract ;;;;;; time-since days-to-time time-less-p seconds-to-time time-to-seconds -;;;;;; date-to-time) "time-date" "calendar/time-date.el" (18088 -;;;;;; 55094)) +;;;;;; date-to-time) "time-date" "calendar/time-date.el" (18307 +;;;;;; 57860)) ;;; Generated autoloads from calendar/time-date.el (autoload 'date-to-time "time-date" "\ @@ -27633,9 +27944,10 @@ If DATE is malformed, return a time value of zeros. ;;;*** ;;;### (autoloads (time-stamp-toggle-active time-stamp) "time-stamp" -;;;;;; "time-stamp.el" (18088 55090)) +;;;;;; "time-stamp.el" (18307 57859)) ;;; Generated autoloads from time-stamp.el (put 'time-stamp-format 'safe-local-variable 'stringp) +(put 'time-stamp-time-zone 'safe-local-variable 'string-or-null-p) (put 'time-stamp-line-limit 'safe-local-variable 'integerp) (put 'time-stamp-start 'safe-local-variable 'stringp) (put 'time-stamp-end 'safe-local-variable 'stringp) @@ -27676,7 +27988,7 @@ With ARG, turn time stamping on if and only if arg is positive. ;;;;;; timeclock-workday-remaining-string timeclock-reread-log timeclock-query-out ;;;;;; timeclock-change timeclock-status-string timeclock-out timeclock-in ;;;;;; timeclock-modeline-display) "timeclock" "calendar/timeclock.el" -;;;;;; (18088 55094)) +;;;;;; (18307 57861)) ;;; Generated autoloads from calendar/timeclock.el (autoload 'timeclock-modeline-display "timeclock" "\ @@ -27777,7 +28089,7 @@ relative only to the time worked today, and not to past time. ;;;### (autoloads (with-timeout run-with-idle-timer add-timeout run-with-timer ;;;;;; run-at-time cancel-function-timers cancel-timer) "timer" -;;;;;; "emacs-lisp/timer.el" (18088 55096)) +;;;;;; "emacs-lisp/timer.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/timer.el (defalias 'disable-timeout 'cancel-timer) @@ -27858,7 +28170,7 @@ be detected. ;;;*** ;;;### (autoloads (batch-titdic-convert titdic-convert) "titdic-cnv" -;;;;;; "international/titdic-cnv.el" (18088 55108)) +;;;;;; "international/titdic-cnv.el" (18307 57867)) ;;; Generated autoloads from international/titdic-cnv.el (autoload 'titdic-convert "titdic-cnv" "\ @@ -27881,8 +28193,8 @@ To get complete usage, invoke \"emacs -batch -f batch-titdic-convert -h\". ;;;*** ;;;### (autoloads (tamil-composition-function tamil-post-read-conversion -;;;;;; tamil-compose-region) "tml-util" "language/tml-util.el" (18088 -;;;;;; 55109)) +;;;;;; tamil-compose-region) "tml-util" "language/tml-util.el" (18307 +;;;;;; 57867)) ;;; Generated autoloads from language/tml-util.el (autoload 'tamil-compose-region "tml-util" "\ @@ -27905,7 +28217,7 @@ PATTERN regexp. ;;;*** ;;;### (autoloads (tmm-prompt tmm-menubar-mouse tmm-menubar) "tmm" -;;;;;; "tmm.el" (18149 22003)) +;;;;;; "tmm.el" (18307 57859)) ;;; Generated autoloads from tmm.el (define-key global-map "\M-`" 'tmm-menubar) (define-key global-map [menu-bar mouse-1] 'tmm-menubar-mouse) @@ -27945,7 +28257,7 @@ Its value should be an event that has a binding in MENU. ;;;### (autoloads (todo-show todo-cp todo-mode todo-print todo-top-priorities ;;;;;; todo-insert-item todo-add-item-non-interactively todo-add-category) -;;;;;; "todo-mode" "calendar/todo-mode.el" (18203 38492)) +;;;;;; "todo-mode" "calendar/todo-mode.el" (18302 4831)) ;;; Generated autoloads from calendar/todo-mode.el (autoload 'todo-add-category "todo-mode" "\ @@ -28006,7 +28318,7 @@ Show TODO list. ;;;### (autoloads (tool-bar-local-item-from-menu tool-bar-add-item-from-menu ;;;;;; tool-bar-local-item tool-bar-add-item toggle-tool-bar-mode-from-frame) -;;;;;; "tool-bar" "tool-bar.el" (18133 2197)) +;;;;;; "tool-bar" "tool-bar.el" (18307 57859)) ;;; Generated autoloads from tool-bar.el (autoload 'toggle-tool-bar-mode-from-frame "tool-bar" "\ @@ -28079,7 +28391,7 @@ holds a keymap. ;;;*** ;;;### (autoloads (tpu-edt-on tpu-edt-mode) "tpu-edt" "emulation/tpu-edt.el" -;;;;;; (18211 32385)) +;;;;;; (18313 61535)) ;;; Generated autoloads from emulation/tpu-edt.el (defvar tpu-edt-mode nil "\ @@ -28105,7 +28417,42 @@ Turn on TPU/edt emulation. ;;;*** -;;;### (autoloads (tq-create) "tq" "emacs-lisp/tq.el" (18088 55096)) +;;;### (autoloads (tpu-mapper) "tpu-mapper" "emulation/tpu-mapper.el" +;;;;;; (18302 4831)) +;;; Generated autoloads from emulation/tpu-mapper.el + +(autoload 'tpu-mapper "tpu-mapper" "\ +Create an Emacs lisp file defining the TPU-edt keypad for X-windows. + +This command displays an instruction screen showing the TPU-edt keypad +and asks you to press the TPU-edt editing keys. It uses the keys you +press to create an Emacs Lisp file that will define a TPU-edt keypad +for your X server. You can even re-arrange the standard EDT keypad to +suit your tastes (or to cope with those silly Sun and PC keypads). + +Finally, you will be prompted for the name of the file to store the key +definitions. If you chose the default, TPU-edt will find it and load it +automatically. If you specify a different file name, you will need to +set the variable ``tpu-xkeys-file'' before starting TPU-edt. Here's how +you might go about doing that in your .emacs file. + + (setq tpu-xkeys-file (expand-file-name \"~/.my-emacs-x-keys\")) + (tpu-edt) + +Known Problems: + +Sometimes, tpu-mapper will ignore a key you press, and just continue to +prompt for the same key. This can happen when your window manager sucks +up the key and doesn't pass it on to Emacs, or it could be an Emacs bug. +Either way, there's nothing that tpu-mapper can do about it. You must +press RETURN, to skip the current key and continue. Later, you and/or +your local X guru can try to figure out why the key is being ignored. + +\(fn)" t nil) + +;;;*** + +;;;### (autoloads (tq-create) "tq" "emacs-lisp/tq.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/tq.el (autoload 'tq-create "tq" "\ @@ -28119,7 +28466,7 @@ to a tcp server on another machine. ;;;*** ;;;### (autoloads (trace-function-background trace-function trace-buffer) -;;;;;; "trace" "emacs-lisp/trace.el" (18088 55096)) +;;;;;; "trace" "emacs-lisp/trace.el" (18307 57861)) ;;; Generated autoloads from emacs-lisp/trace.el (defvar trace-buffer "*trace-output*" "\ @@ -28156,7 +28503,7 @@ BUFFER defaults to `trace-buffer'. ;;;### (autoloads (tramp-unload-tramp tramp-completion-handle-file-name-completion ;;;;;; tramp-completion-handle-file-name-all-completions tramp-unload-file-name-handlers ;;;;;; tramp-file-name-handler tramp-syntax) "tramp" "net/tramp.el" -;;;;;; (18211 32385)) +;;;;;; (18316 2343)) ;;; Generated autoloads from net/tramp.el (defvar tramp-syntax (if (featurep 'xemacs) 'sep 'ftp) "\ @@ -28284,7 +28631,7 @@ Discard Tramp from loading remote files. ;;;*** ;;;### (autoloads (tramp-ftp-enable-ange-ftp) "tramp-ftp" "net/tramp-ftp.el" -;;;;;; (18183 58477)) +;;;;;; (18307 57870)) ;;; Generated autoloads from net/tramp-ftp.el (autoload 'tramp-ftp-enable-ange-ftp "tramp-ftp" "\ @@ -28294,8 +28641,8 @@ Not documented ;;;*** -;;;### (autoloads (help-with-tutorial) "tutorial" "tutorial.el" (18200 -;;;;;; 51264)) +;;;### (autoloads (help-with-tutorial) "tutorial" "tutorial.el" (18307 +;;;;;; 57859)) ;;; Generated autoloads from tutorial.el (autoload 'help-with-tutorial "tutorial" "\ @@ -28320,7 +28667,7 @@ resumed later. ;;;*** ;;;### (autoloads (2C-split 2C-associate-buffer 2C-two-columns) "two-column" -;;;;;; "textmodes/two-column.el" (18201 33329)) +;;;;;; "textmodes/two-column.el" (18307 57875)) ;;; Generated autoloads from textmodes/two-column.el (autoload '2C-command "two-column" () t 'keymap) (global-set-key "\C-x6" '2C-command) @@ -28371,7 +28718,7 @@ First column's text sSs Second column's text ;;;;;; type-break type-break-mode type-break-keystroke-threshold ;;;;;; type-break-good-break-interval type-break-good-rest-interval ;;;;;; type-break-interval type-break-mode) "type-break" "type-break.el" -;;;;;; (18088 55090)) +;;;;;; (18307 57859)) ;;; Generated autoloads from type-break.el (defvar type-break-mode nil "\ @@ -28554,7 +28901,7 @@ FRAC should be the inverse of the fractional value; for example, a value of ;;;*** ;;;### (autoloads (ununderline-region underline-region) "underline" -;;;;;; "textmodes/underline.el" (18088 55121)) +;;;;;; "textmodes/underline.el" (18307 57875)) ;;; Generated autoloads from textmodes/underline.el (autoload 'underline-region "underline" "\ @@ -28575,7 +28922,7 @@ which specify the range to operate on. ;;;*** ;;;### (autoloads (unforward-rmail-message undigestify-rmail-message) -;;;;;; "undigest" "mail/undigest.el" (18120 34751)) +;;;;;; "undigest" "mail/undigest.el" (18307 57869)) ;;; Generated autoloads from mail/undigest.el (autoload 'undigestify-rmail-message "undigest" "\ @@ -28594,7 +28941,7 @@ following the containing message. ;;;*** ;;;### (autoloads (unrmail batch-unrmail) "unrmail" "mail/unrmail.el" -;;;;;; (18088 55110)) +;;;;;; (18307 57869)) ;;; Generated autoloads from mail/unrmail.el (autoload 'batch-unrmail "unrmail" "\ @@ -28613,21 +28960,21 @@ Convert Rmail file FILE to system inbox format file TO-FILE. ;;;*** -;;;### (autoloads (unsafep) "unsafep" "emacs-lisp/unsafep.el" (18120 -;;;;;; 34750)) +;;;### (autoloads (unsafep) "unsafep" "emacs-lisp/unsafep.el" (18307 +;;;;;; 57861)) ;;; Generated autoloads from emacs-lisp/unsafep.el (autoload 'unsafep "unsafep" "\ -Return nil if evaluating FORM couldn't possibly do any harm; -otherwise result is a reason why FORM is unsafe. UNSAFEP-VARS is a list -of symbols with local bindings. +Return nil if evaluating FORM couldn't possibly do any harm. +Otherwise result is a reason why FORM is unsafe. +UNSAFEP-VARS is a list of symbols with local bindings. \(fn FORM &optional UNSAFEP-VARS)" nil nil) ;;;*** ;;;### (autoloads (url-retrieve-synchronously url-retrieve) "url" -;;;;;; "url/url.el" (18088 55122)) +;;;;;; "url/url.el" (18307 57875)) ;;; Generated autoloads from url/url.el (autoload 'url-retrieve "url" "\ @@ -28667,7 +29014,7 @@ no further processing). URL is either a string or a parsed URL. ;;;*** ;;;### (autoloads (url-register-auth-scheme url-get-authentication) -;;;;;; "url-auth" "url/url-auth.el" (18197 21677)) +;;;;;; "url-auth" "url/url-auth.el" (18307 57875)) ;;; Generated autoloads from url/url-auth.el (autoload 'url-get-authentication "url-auth" "\ @@ -28709,8 +29056,8 @@ RATING a rating between 1 and 10 of the strength of the authentication. ;;;*** ;;;### (autoloads (url-cache-expired url-cache-extract url-is-cached -;;;;;; url-store-in-cache) "url-cache" "url/url-cache.el" (18120 -;;;;;; 34753)) +;;;;;; url-store-in-cache) "url-cache" "url/url-cache.el" (18307 +;;;;;; 57875)) ;;; Generated autoloads from url/url-cache.el (autoload 'url-store-in-cache "url-cache" "\ @@ -28735,7 +29082,7 @@ Return t if a cached file has expired. ;;;*** -;;;### (autoloads (url-cid) "url-cid" "url/url-cid.el" (18088 55121)) +;;;### (autoloads (url-cid) "url-cid" "url/url-cid.el" (18307 57875)) ;;; Generated autoloads from url/url-cid.el (autoload 'url-cid "url-cid" "\ @@ -28746,7 +29093,7 @@ Not documented ;;;*** ;;;### (autoloads (url-dav-vc-registered url-dav-supported-p) "url-dav" -;;;;;; "url/url-dav.el" (18173 8196)) +;;;;;; "url/url-dav.el" (18307 57875)) ;;; Generated autoloads from url/url-dav.el (autoload 'url-dav-supported-p "url-dav" "\ @@ -28761,8 +29108,8 @@ Not documented ;;;*** -;;;### (autoloads (url-file) "url-file" "url/url-file.el" (18140 -;;;;;; 63039)) +;;;### (autoloads (url-file) "url-file" "url/url-file.el" (18307 +;;;;;; 57875)) ;;; Generated autoloads from url/url-file.el (autoload 'url-file "url-file" "\ @@ -28773,7 +29120,7 @@ Handle file: and ftp: URLs. ;;;*** ;;;### (autoloads (url-open-stream url-gateway-nslookup-host) "url-gw" -;;;;;; "url/url-gw.el" (18088 55121)) +;;;;;; "url/url-gw.el" (18307 57875)) ;;; Generated autoloads from url/url-gw.el (autoload 'url-gateway-nslookup-host "url-gw" "\ @@ -28792,8 +29139,8 @@ Might do a non-blocking connection; use `process-status' to check. ;;;*** ;;;### (autoloads (url-insert-file-contents url-file-local-copy url-copy-file -;;;;;; url-handler-mode) "url-handlers" "url/url-handlers.el" (18088 -;;;;;; 55121)) +;;;;;; url-file-handler url-handler-mode) "url-handlers" "url/url-handlers.el" +;;;;;; (18307 57875)) ;;; Generated autoloads from url/url-handlers.el (defvar url-handler-mode nil "\ @@ -28810,6 +29157,13 @@ Use URL to handle URL-like file names. \(fn &optional ARG)" t nil) +(autoload 'url-file-handler "url-handlers" "\ +Function called from the `file-name-handler-alist' routines. +OPERATION is what needs to be done (`file-exists-p', etc). ARGS are +the arguments that would have been passed to OPERATION. + +\(fn OPERATION &rest ARGS)" nil nil) + (autoload 'url-copy-file "url-handlers" "\ Copy URL to NEWNAME. Both args must be strings. Signals a `file-already-exists' error if file NEWNAME already exists, @@ -28837,7 +29191,7 @@ Not documented ;;;*** ;;;### (autoloads (url-http-options url-http-file-attributes url-http-file-exists-p -;;;;;; url-http) "url-http" "url/url-http.el" (18140 63039)) +;;;;;; url-http) "url-http" "url/url-http.el" (18307 57875)) ;;; Generated autoloads from url/url-http.el (autoload 'url-http "url-http" "\ @@ -28902,7 +29256,7 @@ HTTPS retrievals are asynchronous.") ;;;*** -;;;### (autoloads (url-irc) "url-irc" "url/url-irc.el" (18088 55121)) +;;;### (autoloads (url-irc) "url-irc" "url/url-irc.el" (18307 57875)) ;;; Generated autoloads from url/url-irc.el (autoload 'url-irc "url-irc" "\ @@ -28912,8 +29266,8 @@ Not documented ;;;*** -;;;### (autoloads (url-ldap) "url-ldap" "url/url-ldap.el" (18088 -;;;;;; 55121)) +;;;### (autoloads (url-ldap) "url-ldap" "url/url-ldap.el" (18307 +;;;;;; 57875)) ;;; Generated autoloads from url/url-ldap.el (autoload 'url-ldap "url-ldap" "\ @@ -28927,7 +29281,7 @@ URL can be a URL string, or a URL vector of the type returned by ;;;*** ;;;### (autoloads (url-mailto url-mail) "url-mailto" "url/url-mailto.el" -;;;;;; (18140 63039)) +;;;;;; (18307 57875)) ;;; Generated autoloads from url/url-mailto.el (autoload 'url-mail "url-mailto" "\ @@ -28943,7 +29297,7 @@ Handle the mailto: URL syntax. ;;;*** ;;;### (autoloads (url-data url-generic-emulator-loader url-info -;;;;;; url-man) "url-misc" "url/url-misc.el" (18165 39747)) +;;;;;; url-man) "url-misc" "url/url-misc.el" (18307 57875)) ;;; Generated autoloads from url/url-misc.el (autoload 'url-man "url-misc" "\ @@ -28975,7 +29329,7 @@ Fetch a data URL (RFC 2397). ;;;*** ;;;### (autoloads (url-snews url-news) "url-news" "url/url-news.el" -;;;;;; (18163 15437)) +;;;;;; (18307 57875)) ;;; Generated autoloads from url/url-news.el (autoload 'url-news "url-news" "\ @@ -28992,7 +29346,7 @@ Not documented ;;;### (autoloads (url-ns-user-pref url-ns-prefs isInNet isResolvable ;;;;;; dnsResolve dnsDomainIs isPlainHostName) "url-ns" "url/url-ns.el" -;;;;;; (18088 55121)) +;;;;;; (18307 57875)) ;;; Generated autoloads from url/url-ns.el (autoload 'isPlainHostName "url-ns" "\ @@ -29033,7 +29387,7 @@ Not documented ;;;*** ;;;### (autoloads (url-generic-parse-url url-recreate-url) "url-parse" -;;;;;; "url/url-parse.el" (18140 63039)) +;;;;;; "url/url-parse.el" (18307 57875)) ;;; Generated autoloads from url/url-parse.el (autoload 'url-recreate-url "url-parse" "\ @@ -29051,7 +29405,7 @@ Format is: ;;;*** ;;;### (autoloads (url-setup-privacy-info) "url-privacy" "url/url-privacy.el" -;;;;;; (18088 55121)) +;;;;;; (18307 57875)) ;;; Generated autoloads from url/url-privacy.el (autoload 'url-setup-privacy-info "url-privacy" "\ @@ -29067,7 +29421,7 @@ Setup variables that expose info about you and your system. ;;;;;; url-pretty-length url-strip-leading-spaces url-eat-trailing-space ;;;;;; url-get-normalized-date url-lazy-message url-normalize-url ;;;;;; url-insert-entities-in-string url-parse-args url-debug url-debug) -;;;;;; "url-util" "url/url-util.el" (18197 21677)) +;;;;;; "url-util" "url/url-util.el" (18307 57875)) ;;; Generated autoloads from url/url-util.el (defvar url-debug nil "\ @@ -29201,7 +29555,7 @@ This uses `url-current-object', set locally to the buffer. ;;;*** ;;;### (autoloads (ask-user-about-supersession-threat ask-user-about-lock) -;;;;;; "userlock" "userlock.el" (18120 34749)) +;;;;;; "userlock" "userlock.el" (18307 57859)) ;;; Generated autoloads from userlock.el (autoload 'ask-user-about-lock "userlock" "\ @@ -29229,16 +29583,17 @@ The buffer in question is current when this function is called. ;;;*** -;;;### (autoloads nil "utf-7" "international/utf-7.el" (18088 55108)) +;;;### (autoloads nil "utf-7" "international/utf-7.el" (18307 57867)) ;;; Generated autoloads from international/utf-7.el (autoload-coding-system 'utf-7 '(require 'utf-7)) +(autoload-coding-system 'utf-7-imap '(require 'utf-7)) ;;;*** ;;;### (autoloads (uudecode-decode-region uudecode-decode-region-internal -;;;;;; uudecode-decode-region-external) "uudecode" "gnus/uudecode.el" -;;;;;; (18212 46007)) -;;; Generated autoloads from gnus/uudecode.el +;;;;;; uudecode-decode-region-external) "uudecode" "mail/uudecode.el" +;;;;;; (18307 57869)) +;;; Generated autoloads from mail/uudecode.el (autoload 'uudecode-decode-region-external "uudecode" "\ Uudecode region between START and END using external program. @@ -29267,7 +29622,7 @@ If FILE-NAME is non-nil, save the result to FILE-NAME. ;;;;;; vc-directory vc-merge vc-insert-headers vc-revision-other-window ;;;;;; vc-diff vc-version-diff vc-register vc-next-action vc-do-command ;;;;;; edit-vc-file with-vc-file vc-before-checkin-hook vc-checkin-hook -;;;;;; vc-checkout-hook) "vc" "vc.el" (18214 4763)) +;;;;;; vc-checkout-hook) "vc" "vc.el" (18317 26672)) ;;; Generated autoloads from vc.el (defvar vc-checkout-hook nil "\ @@ -29355,7 +29710,8 @@ merge in the changes into your working copy. \(fn VERBOSE)" t nil) (autoload 'vc-register "vc" "\ -Register the current file into a version control system. +Register into a version control system. +If FNAME is given register that file, otherwise register the current file. With prefix argument SET-REVISION, allow user to specify initial revision level. If COMMENT is present, use that as an initial comment. @@ -29366,7 +29722,7 @@ directory are already registered under that backend) will be used to register the file. If no backend declares itself responsible, the first backend that could register the file is used. -\(fn &optional SET-REVISION COMMENT)" t nil) +\(fn &optional FNAME SET-REVISION COMMENT)" t nil) (autoload 'vc-version-diff "vc" "\ Report diffs between revisions of the fileset in the repository history. @@ -29557,7 +29913,7 @@ mode-specific menu. `vc-annotate-color-map' and ;;;*** -;;;### (autoloads nil "vc-arch" "vc-arch.el" (18201 33325)) +;;;### (autoloads nil "vc-arch" "vc-arch.el" (18315 16863)) ;;; Generated autoloads from vc-arch.el (defun vc-arch-registered (file) (if (vc-find-root file "{arch}/=tagging-method") @@ -29567,7 +29923,7 @@ mode-specific menu. `vc-annotate-color-map' and ;;;*** -;;;### (autoloads nil "vc-bzr" "vc-bzr.el" (18201 33325)) +;;;### (autoloads nil "vc-bzr" "vc-bzr.el" (18307 57859)) ;;; Generated autoloads from vc-bzr.el (defconst vc-bzr-admin-dirname ".bzr" "\ @@ -29582,7 +29938,7 @@ Name of the directory containing Bzr repository status files.") ;;;*** -;;;### (autoloads nil "vc-cvs" "vc-cvs.el" (18201 33326)) +;;;### (autoloads nil "vc-cvs" "vc-cvs.el" (18314 32066)) ;;; Generated autoloads from vc-cvs.el (defun vc-cvs-registered (f) (when (file-readable-p (expand-file-name @@ -29592,7 +29948,7 @@ Name of the directory containing Bzr repository status files.") ;;;*** -;;;### (autoloads nil "vc-git" "vc-git.el" (18201 33364)) +;;;### (autoloads nil "vc-git" "vc-git.el" (18307 57859)) ;;; Generated autoloads from vc-git.el (defun vc-git-registered (file) "Return non-nil if FILE is registered with git." @@ -29603,7 +29959,7 @@ Name of the directory containing Bzr repository status files.") ;;;*** -;;;### (autoloads nil "vc-hg" "vc-hg.el" (18203 37787)) +;;;### (autoloads nil "vc-hg" "vc-hg.el" (18308 43617)) ;;; Generated autoloads from vc-hg.el (defun vc-hg-registered (file) "Return non-nil if FILE is registered with hg." @@ -29614,7 +29970,7 @@ Name of the directory containing Bzr repository status files.") ;;;*** -;;;### (autoloads nil "vc-mcvs" "vc-mcvs.el" (18201 33326)) +;;;### (autoloads nil "vc-mcvs" "vc-mcvs.el" (18307 57859)) ;;; Generated autoloads from vc-mcvs.el (defun vc-mcvs-registered (file) (if (vc-find-root file "MCVS/CVS") @@ -29624,7 +29980,7 @@ Name of the directory containing Bzr repository status files.") ;;;*** -;;;### (autoloads nil "vc-mtn" "vc-mtn.el" (18202 3996)) +;;;### (autoloads nil "vc-mtn" "vc-mtn.el" (18307 57859)) ;;; Generated autoloads from vc-mtn.el (defconst vc-mtn-admin-dir "_MTN") @@ -29639,7 +29995,7 @@ Name of the directory containing Bzr repository status files.") ;;;*** ;;;### (autoloads (vc-rcs-master-templates) "vc-rcs" "vc-rcs.el" -;;;;;; (18190 46608)) +;;;;;; (18307 57859)) ;;; Generated autoloads from vc-rcs.el (defvar vc-rcs-master-templates '("%sRCS/%s,v" "%s%s,v" "%sRCS/%s") "\ @@ -29652,7 +30008,7 @@ For a description of possible values, see `vc-check-master-templates'.") ;;;*** ;;;### (autoloads (vc-sccs-master-templates) "vc-sccs" "vc-sccs.el" -;;;;;; (18190 46608)) +;;;;;; (18307 57859)) ;;; Generated autoloads from vc-sccs.el (defvar vc-sccs-master-templates '("%sSCCS/s.%s" "%ss.%s" vc-sccs-search-project-dir) "\ @@ -29669,7 +30025,7 @@ find any project directory." (let ((project-dir (getenv "PROJECTDIR")) dirs dir) ;;;*** -;;;### (autoloads nil "vc-svn" "vc-svn.el" (18201 33326)) +;;;### (autoloads nil "vc-svn" "vc-svn.el" (18315 16863)) ;;; Generated autoloads from vc-svn.el (defun vc-svn-registered (f) (let ((admin-dir (cond ((and (eq system-type 'windows-nt) @@ -29687,7 +30043,7 @@ find any project directory." (let ((project-dir (getenv "PROJECTDIR")) dirs dir) ;;;*** ;;;### (autoloads (vera-mode) "vera-mode" "progmodes/vera-mode.el" -;;;;;; (18203 37789)) +;;;;;; (18307 57871)) ;;; Generated autoloads from progmodes/vera-mode.el (add-to-list 'auto-mode-alist '("\\.vr[hi]?\\'" . vera-mode)) @@ -29742,10 +30098,146 @@ Key bindings: \(fn)" t nil) +;;;*** + +;;;### (autoloads (verilog-mode) "verilog-mode" "progmodes/verilog-mode.el" +;;;;;; (18307 57872)) +;;; Generated autoloads from progmodes/verilog-mode.el + +(autoload 'verilog-mode "verilog-mode" "\ +Major mode for editing Verilog code. +\\ +See \\[describe-function] verilog-auto (\\[verilog-auto]) for details on how +AUTOs can improve coding efficiency. + +Use \\[verilog-faq] for a pointer to frequently asked questions. + +NEWLINE, TAB indents for Verilog code. +Delete converts tabs to spaces as it moves back. + +Supports highlighting. + +Turning on Verilog mode calls the value of the variable `verilog-mode-hook' +with no args, if that value is non-nil. + +Variables controlling indentation/edit style: + + variable `verilog-indent-level' (default 3) + Indentation of Verilog statements with respect to containing block. + `verilog-indent-level-module' (default 3) + Absolute indentation of Module level Verilog statements. + Set to 0 to get initial and always statements lined up + on the left side of your screen. + `verilog-indent-level-declaration' (default 3) + Indentation of declarations with respect to containing block. + Set to 0 to get them list right under containing block. + `verilog-indent-level-behavioral' (default 3) + Indentation of first begin in a task or function block + Set to 0 to get such code to lined up underneath the task or function keyword + `verilog-indent-level-directive' (default 1) + Indentation of `ifdef/`endif blocks + `verilog-cexp-indent' (default 1) + Indentation of Verilog statements broken across lines i.e.: + if (a) + begin + `verilog-case-indent' (default 2) + Indentation for case statements. + `verilog-auto-newline' (default nil) + Non-nil means automatically newline after semicolons and the punctuation + mark after an end. + `verilog-auto-indent-on-newline' (default t) + Non-nil means automatically indent line after newline + `verilog-tab-always-indent' (default t) + Non-nil means TAB in Verilog mode should always reindent the current line, + regardless of where in the line point is when the TAB command is used. + `verilog-indent-begin-after-if' (default t) + Non-nil means to indent begin statements following a preceding + if, else, while, for and repeat statements, if any. otherwise, + the begin is lined up with the preceding token. If t, you get: + if (a) + begin // amount of indent based on `verilog-cexp-indent' + otherwise you get: + if (a) + begin + `verilog-auto-endcomments' (default t) + Non-nil means a comment /* ... */ is set after the ends which ends + cases, tasks, functions and modules. + The type and name of the object will be set between the braces. + `verilog-minimum-comment-distance' (default 10) + Minimum distance (in lines) between begin and end required before a comment + will be inserted. Setting this variable to zero results in every + end acquiring a comment; the default avoids too many redundant + comments in tight quarters. + `verilog-auto-lineup' (default `(all)) + List of contexts where auto lineup of code should be done. + +Variables controlling other actions: + + `verilog-linter' (default surelint) + Unix program to call to run the lint checker. This is the default + command for \\[compile-command] and \\[verilog-auto-save-compile]. + +See \\[customize] for the complete list of variables. + +AUTO expansion functions are, in part: + + \\[verilog-auto] Expand AUTO statements. + \\[verilog-delete-auto] Remove the AUTOs. + \\[verilog-inject-auto] Insert AUTOs for the first time. + +Some other functions are: + + \\[verilog-complete-word] Complete word with appropriate possibilities. + \\[verilog-mark-defun] Mark function. + \\[verilog-beg-of-defun] Move to beginning of current function. + \\[verilog-end-of-defun] Move to end of current function. + \\[verilog-label-be] Label matching begin ... end, fork ... join, etc statements. + + \\[verilog-comment-region] Put marked area in a comment. + \\[verilog-uncomment-region] Uncomment an area commented with \\[verilog-comment-region]. + \\[verilog-insert-block] Insert begin ... end;. + \\[verilog-star-comment] Insert /* ... */. + + \\[verilog-sk-always] Insert a always @(AS) begin .. end block. + \\[verilog-sk-begin] Insert a begin .. end block. + \\[verilog-sk-case] Insert a case block, prompting for details. + \\[verilog-sk-for] Insert a for (...) begin .. end block, prompting for details. + \\[verilog-sk-generate] Insert a generate .. endgenerate block. + \\[verilog-sk-header] Insert a nice header block at the top of file. + \\[verilog-sk-initial] Insert an initial begin .. end block. + \\[verilog-sk-fork] Insert a fork begin .. end .. join block. + \\[verilog-sk-module] Insert a module .. (/*AUTOARG*/);.. endmodule block. + \\[verilog-sk-primitive] Insert a primitive .. (.. );.. endprimitive block. + \\[verilog-sk-repeat] Insert a repeat (..) begin .. end block. + \\[verilog-sk-specify] Insert a specify .. endspecify block. + \\[verilog-sk-task] Insert a task .. begin .. end endtask block. + \\[verilog-sk-while] Insert a while (...) begin .. end block, prompting for details. + \\[verilog-sk-casex] Insert a casex (...) item: begin.. end endcase block, prompting for details. + \\[verilog-sk-casez] Insert a casez (...) item: begin.. end endcase block, prompting for details. + \\[verilog-sk-if] Insert an if (..) begin .. end block. + \\[verilog-sk-else-if] Insert an else if (..) begin .. end block. + \\[verilog-sk-comment] Insert a comment block. + \\[verilog-sk-assign] Insert an assign .. = ..; statement. + \\[verilog-sk-function] Insert a function .. begin .. end endfunction block. + \\[verilog-sk-input] Insert an input declaration, prompting for details. + \\[verilog-sk-output] Insert an output declaration, prompting for details. + \\[verilog-sk-state-machine] Insert a state machine definition, prompting for details. + \\[verilog-sk-inout] Insert an inout declaration, prompting for details. + \\[verilog-sk-wire] Insert a wire declaration, prompting for details. + \\[verilog-sk-reg] Insert a register declaration, prompting for details. + \\[verilog-sk-define-signal] Define signal under point as a register at the top of the module. + +All key bindings can be seen in a Verilog-buffer with \\[describe-bindings]. +Key bindings specific to `verilog-mode-map' are: + +\\{verilog-mode-map} + +\(fn)" t nil) + ;;;*** ;;;### (autoloads (vhdl-mode) "vhdl-mode" "progmodes/vhdl-mode.el" -;;;;;; (18203 37789)) +;;;;;; (18307 57872)) ;;; Generated autoloads from progmodes/vhdl-mode.el (autoload 'vhdl-mode "vhdl-mode" "\ @@ -30286,7 +30778,7 @@ Key bindings: ;;;*** -;;;### (autoloads (vi-mode) "vi" "emulation/vi.el" (18201 33326)) +;;;### (autoloads (vi-mode) "vi" "emulation/vi.el" (18263 30458)) ;;; Generated autoloads from emulation/vi.el (autoload 'vi-mode "vi" "\ @@ -30341,7 +30833,7 @@ Syntax table and abbrevs while in vi mode remain as they were in Emacs. ;;;### (autoloads (viqr-pre-write-conversion viqr-post-read-conversion ;;;;;; viet-encode-viqr-buffer viet-encode-viqr-region viet-decode-viqr-buffer ;;;;;; viet-decode-viqr-region viet-encode-viscii-char) "viet-util" -;;;;;; "language/viet-util.el" (18088 55109)) +;;;;;; "language/viet-util.el" (18307 57868)) ;;; Generated autoloads from language/viet-util.el (autoload 'viet-encode-viscii-char "viet-util" "\ @@ -30385,12 +30877,19 @@ Not documented ;;;*** -;;;### (autoloads (View-exit-and-edit view-mode-enter view-mode view-buffer-other-frame -;;;;;; view-buffer-other-window view-buffer view-file-other-frame -;;;;;; view-file-other-window view-file) "view" "view.el" (18169 -;;;;;; 11932)) +;;;### (autoloads (View-exit-and-edit view-mode-enter view-return-to-alist-update +;;;;;; view-mode view-buffer-other-frame view-buffer-other-window +;;;;;; view-buffer view-file-other-frame view-file-other-window +;;;;;; view-file view-remove-frame-by-deleting) "view" "view.el" +;;;;;; (18307 57859)) ;;; Generated autoloads from view.el +(defvar view-remove-frame-by-deleting t "\ +*Determine how View mode removes a frame no longer needed. +If nil, make an icon of the frame. If non-nil, delete the frame.") + +(custom-autoload 'view-remove-frame-by-deleting "view" t) + (defvar view-mode nil "\ Non-nil if View mode is enabled. Don't change this variable directly, you must change it by one of the @@ -30400,11 +30899,11 @@ functions that enable or disable view mode.") (autoload 'view-file "view" "\ View FILE in View mode, returning to previous buffer when done. -Emacs commands editing the buffer contents are not available; instead, -a special set of commands (mostly letters and punctuation) -are defined for moving around in the buffer. +Emacs commands editing the buffer contents are not available; instead, a +special set of commands (mostly letters and punctuation) are defined for +moving around in the buffer. Space scrolls forward, Delete scrolls backward. -For list of all View commands, type H or h while viewing. +For a list of all View commands, type H or h while viewing. This command runs the normal hook `view-mode-hook'. @@ -30412,12 +30911,12 @@ This command runs the normal hook `view-mode-hook'. (autoload 'view-file-other-window "view" "\ View FILE in View mode in another window. -Return that window to its previous buffer when done. -Emacs commands editing the buffer contents are not available; instead, -a special set of commands (mostly letters and punctuation) -are defined for moving around in the buffer. +Return that window to its previous buffer when done. Emacs commands +editing the buffer contents are not available; instead, a special set of +commands (mostly letters and punctuation) are defined for moving around +in the buffer. Space scrolls forward, Delete scrolls backward. -For list of all View commands, type H or h while viewing. +For a list of all View commands, type H or h while viewing. This command runs the normal hook `view-mode-hook'. @@ -30426,11 +30925,11 @@ This command runs the normal hook `view-mode-hook'. (autoload 'view-file-other-frame "view" "\ View FILE in View mode in another frame. Maybe delete other frame and/or return to previous buffer when done. -Emacs commands editing the buffer contents are not available; instead, -a special set of commands (mostly letters and punctuation) -are defined for moving around in the buffer. +Emacs commands editing the buffer contents are not available; instead, a +special set of commands (mostly letters and punctuation) are defined for +moving around in the buffer. Space scrolls forward, Delete scrolls backward. -For list of all View commands, type H or h while viewing. +For a list of all View commands, type H or h while viewing. This command runs the normal hook `view-mode-hook'. @@ -30438,51 +30937,51 @@ This command runs the normal hook `view-mode-hook'. (autoload 'view-buffer "view" "\ View BUFFER in View mode, returning to previous buffer when done. -Emacs commands editing the buffer contents are not available; instead, -a special set of commands (mostly letters and punctuation) -are defined for moving around in the buffer. +Emacs commands editing the buffer contents are not available; instead, a +special set of commands (mostly letters and punctuation) are defined for +moving around in the buffer. Space scrolls forward, Delete scrolls backward. -For list of all View commands, type H or h while viewing. +For a list of all View commands, type H or h while viewing. This command runs the normal hook `view-mode-hook'. Optional argument EXIT-ACTION is either nil or a function with buffer as -argument. This function is called when finished viewing buffer. -Use this argument instead of explicitly setting `view-exit-action'. +argument. This function is called when finished viewing buffer. Use +this argument instead of explicitly setting `view-exit-action'. \(fn BUFFER &optional EXIT-ACTION)" t nil) (autoload 'view-buffer-other-window "view" "\ View BUFFER in View mode in another window. -Return to previous buffer when done, unless optional NOT-RETURN is non-nil. -Emacs commands editing the buffer contents are not available; instead, -a special set of commands (mostly letters and punctuation) -are defined for moving around in the buffer. +Return to previous buffer when done, unless optional NOT-RETURN is +non-nil. Emacs commands editing the buffer contents are not available; +instead, a special set of commands (mostly letters and punctuation) are +defined for moving around in the buffer. Space scrolls forward, Delete scrolls backward. -For list of all View commands, type H or h while viewing. +For a list of all View commands, type H or h while viewing. This command runs the normal hook `view-mode-hook'. Optional argument EXIT-ACTION is either nil or a function with buffer as -argument. This function is called when finished viewing buffer. -Use this argument instead of explicitly setting `view-exit-action'. +argument. This function is called when finished viewing buffer. Use +this argument instead of explicitly setting `view-exit-action'. \(fn BUFFER &optional NOT-RETURN EXIT-ACTION)" t nil) (autoload 'view-buffer-other-frame "view" "\ View BUFFER in View mode in another frame. -Return to previous buffer when done, unless optional NOT-RETURN is non-nil. -Emacs commands editing the buffer contents are not available; instead, -a special set of commands (mostly letters and punctuation) -are defined for moving around in the buffer. +Return to previous buffer when done, unless optional NOT-RETURN is +non-nil. Emacs commands editing the buffer contents are not available; +instead, a special set of commands (mostly letters and punctuation) are +defined for moving around in the buffer. Space scrolls forward, Delete scrolls backward. -For list of all View commands, type H or h while viewing. +For a list of all View commands, type H or h while viewing. This command runs the normal hook `view-mode-hook'. Optional argument EXIT-ACTION is either nil or a function with buffer as -argument. This function is called when finished viewing buffer. -Use this argument instead of explicitly setting `view-exit-action'. +argument. This function is called when finished viewing buffer. Use +this argument instead of explicitly setting `view-exit-action'. \(fn BUFFER &optional NOT-RETURN EXIT-ACTION)" t nil) @@ -30566,26 +31065,41 @@ Entry to view-mode runs the normal hook `view-mode-hook'. \(fn &optional ARG)" t nil) +(autoload 'view-return-to-alist-update "view" "\ +Update `view-return-to-alist' of buffer BUFFER. +Remove from `view-return-to-alist' all entries referencing dead +windows. Optional argument ITEM non-nil means add ITEM to +`view-return-to-alist' after purging. For a decsription of items +that can be added see the RETURN-TO-ALIST argument of the +function `view-mode-exit'. If `view-return-to-alist' contains an +entry for the selected window, purge that entry from +`view-return-to-alist' before adding ITEM. + +\(fn BUFFER &optional ITEM)" nil nil) + (autoload 'view-mode-enter "view" "\ Enter View mode and set up exit from view mode depending on optional arguments. -If RETURN-TO is non-nil it is added as an element to the buffer local alist -`view-return-to-alist'. -Save EXIT-ACTION in buffer local variable `view-exit-action'. -It should be either nil or a function that takes a buffer as argument. -This function will be called by `view-mode-exit'. +RETURN-TO non-nil means add RETURN-TO as an element to the buffer +local alist `view-return-to-alist'. Save EXIT-ACTION in buffer +local variable `view-exit-action'. It should be either nil or a +function that takes a buffer as argument. This function will be +called by `view-mode-exit'. -RETURN-TO is either nil, meaning do nothing when exiting view mode, or -it has the format (WINDOW OLD-WINDOW . OLD-BUF-INFO). -WINDOW is a window used for viewing. -OLD-WINDOW is nil or the window to select after viewing. -OLD-BUF-INFO tells what to do with WINDOW when exiting. It is one of: -1) nil Do nothing. -2) t Delete WINDOW or, if it is the only window, its frame. +RETURN-TO is either nil, meaning do nothing when exiting view +mode, or must have the format (WINDOW OLD-WINDOW . OLD-BUF-INFO). +WINDOW is the window used for viewing. OLD-WINDOW is nil or the +window to select after viewing. OLD-BUF-INFO tells what to do +with WINDOW when exiting. It is one of: +1) nil Do nothing. +2) t Delete WINDOW or, if it is the only window and + `view-remove-frame-by-deleting' is non-nil, its + frame. 3) (OLD-BUFF START POINT) Display buffer OLD-BUFF with displayed text - starting at START and point at POINT in WINDOW. -4) quit-window Do `quit-window' in WINDOW. + starting at START and point at POINT in WINDOW. +4) quit-window Do `quit-window' in WINDOW. +5) keep-frame Like case 2) but do not delete the frame. -For list of all View commands, type H or h while viewing. +For a list of all View commands, type H or h while viewing. This function runs the normal hook `view-mode-hook'. @@ -30598,8 +31112,8 @@ Exit View mode and make the current buffer editable. ;;;*** -;;;### (autoloads (vip-mode vip-setup) "vip" "emulation/vip.el" (18088 -;;;;;; 55097)) +;;;### (autoloads (vip-mode vip-setup) "vip" "emulation/vip.el" (18307 +;;;;;; 57862)) ;;; Generated autoloads from emulation/vip.el (autoload 'vip-setup "vip" "\ @@ -30615,7 +31129,7 @@ Turn on VIP emulation of VI. ;;;*** ;;;### (autoloads (viper-mode toggle-viper-mode) "viper" "emulation/viper.el" -;;;;;; (18213 13953)) +;;;;;; (18308 43618)) ;;; Generated autoloads from emulation/viper.el (autoload 'toggle-viper-mode "viper" "\ @@ -30632,7 +31146,7 @@ Turn on Viper emulation of Vi in Emacs. See Info node `(viper)Top'. ;;;*** ;;;### (autoloads (warn lwarn display-warning) "warnings" "emacs-lisp/warnings.el" -;;;;;; (18088 55096)) +;;;;;; (18307 57861)) ;;; Generated autoloads from emacs-lisp/warnings.el (defvar warning-prefix-function nil "\ @@ -30722,7 +31236,7 @@ this is equivalent to `display-warning', using ;;;*** ;;;### (autoloads (wdired-change-to-wdired-mode) "wdired" "wdired.el" -;;;;;; (18214 4479)) +;;;;;; (18307 57859)) ;;; Generated autoloads from wdired.el (autoload 'wdired-change-to-wdired-mode "wdired" "\ @@ -30738,7 +31252,7 @@ See `wdired-mode'. ;;;*** -;;;### (autoloads (webjump) "webjump" "net/webjump.el" (18088 55112)) +;;;### (autoloads (webjump) "webjump" "net/webjump.el" (18307 57870)) ;;; Generated autoloads from net/webjump.el (autoload 'webjump "webjump" "\ @@ -30755,7 +31269,7 @@ Please submit bug reports and other feedback to the author, Neil W. Van Dyke ;;;*** ;;;### (autoloads (which-function-mode) "which-func" "progmodes/which-func.el" -;;;;;; (18147 59474)) +;;;;;; (18307 57872)) ;;; Generated autoloads from progmodes/which-func.el (put 'which-func-format 'risky-local-variable t) (put 'which-func-current 'risky-local-variable t) @@ -30788,8 +31302,13 @@ and off otherwise. ;;;;;; whitespace-buffer whitespace-toggle-ateol-check whitespace-toggle-spacetab-check ;;;;;; whitespace-toggle-indent-check whitespace-toggle-trailing-check ;;;;;; whitespace-toggle-leading-check) "whitespace" "whitespace.el" -;;;;;; (18169 11932)) +;;;;;; (18307 57860)) ;;; Generated autoloads from whitespace.el +(put 'whitespace-check-buffer-leading 'safe-local-variable 'booleanp) +(put 'whitespace-check-buffer-trailing 'safe-local-variable 'booleanp) +(put 'whitespace-check-buffer-indent 'safe-local-variable 'booleanp) +(put 'whitespace-check-buffer-spacetab 'safe-local-variable 'booleanp) +(put 'whitespace-check-buffer-ateol 'safe-local-variable 'booleanp) (autoload 'whitespace-toggle-leading-check "whitespace" "\ Toggle the check for leading space in the local buffer. @@ -30874,12 +31393,12 @@ When this mode is active, `whitespace-buffer' is added to Hook function to be called on the buffer when whitespace check is enabled. This is meant to be added buffer-locally to `write-file-functions'. -\(fn)" t nil) +\(fn)" nil nil) ;;;*** ;;;### (autoloads (widget-minor-mode widget-browse-other-window widget-browse -;;;;;; widget-browse-at) "wid-browse" "wid-browse.el" (18149 22003)) +;;;;;; widget-browse-at) "wid-browse" "wid-browse.el" (18307 57860)) ;;; Generated autoloads from wid-browse.el (autoload 'widget-browse-at "wid-browse" "\ @@ -30906,8 +31425,8 @@ With arg, turn widget mode on if and only if arg is positive. ;;;*** ;;;### (autoloads (widget-setup widget-insert widget-delete widget-create -;;;;;; widget-prompt-value widgetp) "wid-edit" "wid-edit.el" (18187 -;;;;;; 36840)) +;;;;;; widget-prompt-value widgetp) "wid-edit" "wid-edit.el" (18307 +;;;;;; 57860)) ;;; Generated autoloads from wid-edit.el (autoload 'widgetp "wid-edit" "\ @@ -30951,8 +31470,8 @@ Setup current buffer so editing string widgets works. ;;;*** ;;;### (autoloads (windmove-default-keybindings windmove-down windmove-right -;;;;;; windmove-up windmove-left) "windmove" "windmove.el" (18088 -;;;;;; 55091)) +;;;;;; windmove-up windmove-left) "windmove" "windmove.el" (18307 +;;;;;; 57860)) ;;; Generated autoloads from windmove.el (autoload 'windmove-left "windmove" "\ @@ -31005,7 +31524,7 @@ Default MODIFIER is 'shift. ;;;*** ;;;### (autoloads (winner-mode winner-mode) "winner" "winner.el" -;;;;;; (18120 34750)) +;;;;;; (18307 57860)) ;;; Generated autoloads from winner.el (defvar winner-mode nil "\ @@ -31024,7 +31543,7 @@ With arg, turn Winner mode on if and only if arg is positive. ;;;*** ;;;### (autoloads (woman-find-file woman-dired-find-file woman) "woman" -;;;;;; "woman.el" (18197 21670)) +;;;;;; "woman.el" (18313 19473)) ;;; Generated autoloads from woman.el (autoload 'woman "woman" "\ @@ -31060,7 +31579,7 @@ decompress the file if appropriate. See the documentation for the ;;;*** ;;;### (autoloads (wordstar-mode) "ws-mode" "emulation/ws-mode.el" -;;;;;; (18088 55097)) +;;;;;; (18307 57864)) ;;; Generated autoloads from emulation/ws-mode.el (autoload 'wordstar-mode "ws-mode" "\ @@ -31173,7 +31692,7 @@ The key bindings are: ;;;*** ;;;### (autoloads (xml-parse-region xml-parse-file) "xml" "xml.el" -;;;;;; (18088 55091)) +;;;;;; (18307 57860)) ;;; Generated autoloads from xml.el (autoload 'xml-parse-file "xml" "\ @@ -31198,8 +31717,27 @@ If PARSE-NS is non-nil, then QNAMES are expanded. ;;;*** -;;;### (autoloads (xterm-mouse-mode) "xt-mouse" "xt-mouse.el" (18200 -;;;;;; 51264)) +;;;### (autoloads (xmltok-get-declared-encoding-position) "xmltok" +;;;;;; "nxml/xmltok.el" (18308 19808)) +;;; Generated autoloads from nxml/xmltok.el + +(autoload 'xmltok-get-declared-encoding-position "xmltok" "\ +Return the position of the encoding in the XML declaration at point. +If there is a well-formed XML declaration starting at point and it +contains an encoding declaration, then return (START . END) +where START and END are the positions of the start and the end +of the encoding name; if there is no encoding declaration return +the position where and encoding declaration could be inserted. +If there is XML that is not well-formed that looks like an XML declaration, +return nil. Otherwise, return t. +If LIMIT is non-nil, then do not consider characters beyond LIMIT. + +\(fn &optional LIMIT)" nil nil) + +;;;*** + +;;;### (autoloads (xterm-mouse-mode) "xt-mouse" "xt-mouse.el" (18307 +;;;;;; 57860)) ;;; Generated autoloads from xt-mouse.el (defvar xterm-mouse-mode nil "\ @@ -31228,7 +31766,7 @@ down the SHIFT key while pressing the mouse button. ;;;*** ;;;### (autoloads (yenc-extract-filename yenc-decode-region) "yenc" -;;;;;; "gnus/yenc.el" (18088 55107)) +;;;;;; "gnus/yenc.el" (18307 57866)) ;;; Generated autoloads from gnus/yenc.el (autoload 'yenc-decode-region "yenc" "\ @@ -31244,7 +31782,7 @@ Extract file name from an yenc header. ;;;*** ;;;### (autoloads (psychoanalyze-pinhead apropos-zippy insert-zippyism -;;;;;; yow) "yow" "play/yow.el" (18203 37788)) +;;;;;; yow) "yow" "play/yow.el" (18307 57870)) ;;; Generated autoloads from play/yow.el (autoload 'yow "yow" "\ @@ -31270,7 +31808,7 @@ Zippy goes to the analyst. ;;;*** -;;;### (autoloads (zone) "zone" "play/zone.el" (18202 4002)) +;;;### (autoloads (zone) "zone" "play/zone.el" (18307 57870)) ;;; Generated autoloads from play/zone.el (autoload 'zone "zone" "\ @@ -31287,61 +31825,59 @@ Zone out, completely. ;;;;;; "calc/calc-frac.el" "calc/calc-funcs.el" "calc/calc-graph.el" ;;;;;; "calc/calc-help.el" "calc/calc-incom.el" "calc/calc-keypd.el" ;;;;;; "calc/calc-lang.el" "calc/calc-macs.el" "calc/calc-map.el" -;;;;;; "calc/calc-math.el" "calc/calc-misc.el" "calc/calc-mode.el" -;;;;;; "calc/calc-mtx.el" "calc/calc-nlfit.el" "calc/calc-poly.el" -;;;;;; "calc/calc-prog.el" "calc/calc-rewr.el" "calc/calc-rules.el" -;;;;;; "calc/calc-sel.el" "calc/calc-stat.el" "calc/calc-store.el" -;;;;;; "calc/calc-stuff.el" "calc/calc-trail.el" "calc/calc-undo.el" -;;;;;; "calc/calc-units.el" "calc/calc-vec.el" "calc/calc-yank.el" -;;;;;; "calc/calcalg2.el" "calc/calcalg3.el" "calc/calccomp.el" -;;;;;; "calc/calcsel2.el" "calendar/cal-bahai.el" "calendar/cal-china.el" -;;;;;; "calendar/cal-coptic.el" "calendar/cal-french.el" "calendar/cal-html.el" -;;;;;; "calendar/cal-islam.el" "calendar/cal-iso.el" "calendar/cal-julian.el" -;;;;;; "calendar/cal-mayan.el" "calendar/cal-menu.el" "calendar/cal-move.el" -;;;;;; "calendar/cal-persia.el" "calendar/cal-tex.el" "calendar/cal-x.el" -;;;;;; "case-table.el" "cdl.el" "cus-dep.el" "cus-load.el" "cus-start.el" -;;;;;; "custom.el" "dframe.el" "dos-fns.el" "dos-vars.el" "dos-w32.el" -;;;;;; "ediff-diff.el" "ediff-init.el" "ediff-merg.el" "ediff-ptch.el" -;;;;;; "ediff-vers.el" "ediff-wind.el" "electric.el" "emacs-lisp/assoc.el" -;;;;;; "emacs-lisp/authors.el" "emacs-lisp/avl-tree.el" "emacs-lisp/bindat.el" -;;;;;; "emacs-lisp/byte-opt.el" "emacs-lisp/byte-run.el" "emacs-lisp/cl-compat.el" -;;;;;; "emacs-lisp/cl-extra.el" "emacs-lisp/cl-loaddefs.el" "emacs-lisp/cl-macs.el" -;;;;;; "emacs-lisp/cl-seq.el" "emacs-lisp/cl-specs.el" "emacs-lisp/cust-print.el" -;;;;;; "emacs-lisp/find-gc.el" "emacs-lisp/float-sup.el" "emacs-lisp/gulp.el" -;;;;;; "emacs-lisp/levents.el" "emacs-lisp/lisp-mnt.el" "emacs-lisp/lisp-mode.el" -;;;;;; "emacs-lisp/lisp.el" "emacs-lisp/lmenu.el" "emacs-lisp/lselect.el" +;;;;;; "calc/calc-math.el" "calc/calc-menu.el" "calc/calc-misc.el" +;;;;;; "calc/calc-mode.el" "calc/calc-mtx.el" "calc/calc-nlfit.el" +;;;;;; "calc/calc-poly.el" "calc/calc-prog.el" "calc/calc-rewr.el" +;;;;;; "calc/calc-rules.el" "calc/calc-sel.el" "calc/calc-stat.el" +;;;;;; "calc/calc-store.el" "calc/calc-stuff.el" "calc/calc-trail.el" +;;;;;; "calc/calc-undo.el" "calc/calc-units.el" "calc/calc-vec.el" +;;;;;; "calc/calc-yank.el" "calc/calcalg2.el" "calc/calcalg3.el" +;;;;;; "calc/calccomp.el" "calc/calcsel2.el" "calendar/cal-bahai.el" +;;;;;; "calendar/cal-china.el" "calendar/cal-coptic.el" "calendar/cal-french.el" +;;;;;; "calendar/cal-html.el" "calendar/cal-islam.el" "calendar/cal-iso.el" +;;;;;; "calendar/cal-julian.el" "calendar/cal-mayan.el" "calendar/cal-menu.el" +;;;;;; "calendar/cal-move.el" "calendar/cal-persia.el" "calendar/cal-tex.el" +;;;;;; "calendar/cal-x.el" "case-table.el" "cdl.el" "cus-dep.el" +;;;;;; "cus-start.el" "custom.el" "dframe.el" "dos-fns.el" "dos-vars.el" +;;;;;; "dos-w32.el" "ediff-diff.el" "ediff-init.el" "ediff-merg.el" +;;;;;; "ediff-ptch.el" "ediff-vers.el" "ediff-wind.el" "electric.el" +;;;;;; "emacs-lisp/assoc.el" "emacs-lisp/authors.el" "emacs-lisp/avl-tree.el" +;;;;;; "emacs-lisp/bindat.el" "emacs-lisp/byte-opt.el" "emacs-lisp/byte-run.el" +;;;;;; "emacs-lisp/cl-compat.el" "emacs-lisp/cl-extra.el" "emacs-lisp/cl-loaddefs.el" +;;;;;; "emacs-lisp/cl-macs.el" "emacs-lisp/cl-seq.el" "emacs-lisp/cl-specs.el" +;;;;;; "emacs-lisp/cust-print.el" "emacs-lisp/find-gc.el" "emacs-lisp/float-sup.el" +;;;;;; "emacs-lisp/gulp.el" "emacs-lisp/levents.el" "emacs-lisp/lisp-mnt.el" +;;;;;; "emacs-lisp/lisp-mode.el" "emacs-lisp/lisp.el" "emacs-lisp/lmenu.el" ;;;;;; "emacs-lisp/lucid.el" "emacs-lisp/map-ynp.el" "emacs-lisp/regi.el" ;;;;;; "emacs-lisp/sregex.el" "emacs-lisp/syntax.el" "emacs-lisp/tcover-ses.el" ;;;;;; "emacs-lisp/tcover-unsafep.el" "emacs-lock.el" "emulation/cua-gmrk.el" ;;;;;; "emulation/cua-rect.el" "emulation/edt-lk201.el" "emulation/edt-mapper.el" ;;;;;; "emulation/edt-pc.el" "emulation/edt-vt100.el" "emulation/tpu-extras.el" -;;;;;; "emulation/tpu-mapper.el" "emulation/viper-cmd.el" "emulation/viper-ex.el" -;;;;;; "emulation/viper-init.el" "emulation/viper-keym.el" "emulation/viper-macs.el" -;;;;;; "emulation/viper-mous.el" "emulation/viper-util.el" "env.el" -;;;;;; "erc/erc-backend.el" "erc/erc-goodies.el" "erc/erc-ibuffer.el" -;;;;;; "erc/erc-lang.el" "eshell/em-alias.el" "eshell/em-banner.el" -;;;;;; "eshell/em-basic.el" "eshell/em-cmpl.el" "eshell/em-dirs.el" -;;;;;; "eshell/em-glob.el" "eshell/em-hist.el" "eshell/em-ls.el" -;;;;;; "eshell/em-pred.el" "eshell/em-prompt.el" "eshell/em-rebind.el" -;;;;;; "eshell/em-script.el" "eshell/em-smart.el" "eshell/em-term.el" -;;;;;; "eshell/em-unix.el" "eshell/em-xtra.el" "eshell/esh-arg.el" -;;;;;; "eshell/esh-cmd.el" "eshell/esh-ext.el" "eshell/esh-groups.el" -;;;;;; "eshell/esh-io.el" "eshell/esh-maint.el" "eshell/esh-module.el" -;;;;;; "eshell/esh-opt.el" "eshell/esh-proc.el" "eshell/esh-util.el" -;;;;;; "eshell/esh-var.el" "ezimage.el" "faces.el" "files.el" "finder-inf.el" -;;;;;; "foldout.el" "font-core.el" "font-lock.el" "format.el" "forms-d2.el" -;;;;;; "forms-pass.el" "frame.el" "fringe.el" "generic-x.el" "gnus/compface.el" -;;;;;; "gnus/dig.el" "gnus/dns.el" "gnus/format-spec.el" "gnus/gnus-async.el" -;;;;;; "gnus/gnus-bcklg.el" "gnus/gnus-cite.el" "gnus/gnus-cus.el" -;;;;;; "gnus/gnus-demon.el" "gnus/gnus-dup.el" "gnus/gnus-eform.el" -;;;;;; "gnus/gnus-ems.el" "gnus/gnus-int.el" "gnus/gnus-logic.el" -;;;;;; "gnus/gnus-mh.el" "gnus/gnus-salt.el" "gnus/gnus-score.el" -;;;;;; "gnus/gnus-setup.el" "gnus/gnus-srvr.el" "gnus/gnus-sum.el" -;;;;;; "gnus/gnus-topic.el" "gnus/gnus-undo.el" "gnus/gnus-util.el" -;;;;;; "gnus/gnus-uu.el" "gnus/gnus-vm.el" "gnus/hex-util.el" "gnus/hmac-def.el" -;;;;;; "gnus/hmac-md5.el" "gnus/ietf-drums.el" "gnus/imap.el" "gnus/legacy-gnus-agent.el" +;;;;;; "emulation/viper-cmd.el" "emulation/viper-ex.el" "emulation/viper-init.el" +;;;;;; "emulation/viper-keym.el" "emulation/viper-macs.el" "emulation/viper-mous.el" +;;;;;; "emulation/viper-util.el" "env.el" "erc/erc-backend.el" "erc/erc-goodies.el" +;;;;;; "erc/erc-ibuffer.el" "erc/erc-lang.el" "eshell/em-alias.el" +;;;;;; "eshell/em-banner.el" "eshell/em-basic.el" "eshell/em-cmpl.el" +;;;;;; "eshell/em-dirs.el" "eshell/em-glob.el" "eshell/em-hist.el" +;;;;;; "eshell/em-ls.el" "eshell/em-pred.el" "eshell/em-prompt.el" +;;;;;; "eshell/em-rebind.el" "eshell/em-script.el" "eshell/em-smart.el" +;;;;;; "eshell/em-term.el" "eshell/em-unix.el" "eshell/em-xtra.el" +;;;;;; "eshell/esh-arg.el" "eshell/esh-cmd.el" "eshell/esh-ext.el" +;;;;;; "eshell/esh-groups.el" "eshell/esh-io.el" "eshell/esh-maint.el" +;;;;;; "eshell/esh-module.el" "eshell/esh-opt.el" "eshell/esh-proc.el" +;;;;;; "eshell/esh-util.el" "eshell/esh-var.el" "ezimage.el" "faces.el" +;;;;;; "files.el" "foldout.el" "font-core.el" "font-lock.el" "format-spec.el" +;;;;;; "format.el" "forms-d2.el" "forms-pass.el" "frame.el" "fringe.el" +;;;;;; "generic-x.el" "gnus/compface.el" "gnus/gnus-async.el" "gnus/gnus-bcklg.el" +;;;;;; "gnus/gnus-cite.el" "gnus/gnus-cus.el" "gnus/gnus-demon.el" +;;;;;; "gnus/gnus-dup.el" "gnus/gnus-eform.el" "gnus/gnus-ems.el" +;;;;;; "gnus/gnus-int.el" "gnus/gnus-logic.el" "gnus/gnus-mh.el" +;;;;;; "gnus/gnus-salt.el" "gnus/gnus-score.el" "gnus/gnus-setup.el" +;;;;;; "gnus/gnus-srvr.el" "gnus/gnus-sum.el" "gnus/gnus-topic.el" +;;;;;; "gnus/gnus-undo.el" "gnus/gnus-util.el" "gnus/gnus-uu.el" +;;;;;; "gnus/gnus-vm.el" "gnus/ietf-drums.el" "gnus/legacy-gnus-agent.el" ;;;;;; "gnus/mail-parse.el" "gnus/mail-prsvr.el" "gnus/mail-source.el" -;;;;;; "gnus/mailcap.el" "gnus/md4.el" "gnus/messcompat.el" "gnus/mm-bodies.el" +;;;;;; "gnus/mailcap.el" "gnus/messcompat.el" "gnus/mm-bodies.el" ;;;;;; "gnus/mm-decode.el" "gnus/mm-encode.el" "gnus/mm-util.el" ;;;;;; "gnus/mm-view.el" "gnus/mml-sec.el" "gnus/mml-smime.el" "gnus/mml.el" ;;;;;; "gnus/nnagent.el" "gnus/nnbabyl.el" "gnus/nndb.el" "gnus/nndir.el" @@ -31350,14 +31886,13 @@ Zone out, completely. ;;;;;; "gnus/nnmail.el" "gnus/nnmaildir.el" "gnus/nnmbox.el" "gnus/nnmh.el" ;;;;;; "gnus/nnnil.el" "gnus/nnoo.el" "gnus/nnrss.el" "gnus/nnslashdot.el" ;;;;;; "gnus/nnspool.el" "gnus/nntp.el" "gnus/nnultimate.el" "gnus/nnvirtual.el" -;;;;;; "gnus/nnwarchive.el" "gnus/nnweb.el" "gnus/nnwfm.el" "gnus/ntlm.el" -;;;;;; "gnus/password.el" "gnus/pop3.el" "gnus/rfc1843.el" "gnus/rfc2045.el" -;;;;;; "gnus/rfc2047.el" "gnus/rfc2104.el" "gnus/rfc2231.el" "gnus/sasl-cram.el" -;;;;;; "gnus/sasl-digest.el" "gnus/sasl-ntlm.el" "gnus/sasl.el" -;;;;;; "gnus/sieve-manage.el" "gnus/smime-ldap.el" "gnus/smime.el" +;;;;;; "gnus/nnwarchive.el" "gnus/nnweb.el" "gnus/nnwfm.el" "gnus/pop3.el" +;;;;;; "gnus/rfc1843.el" "gnus/rfc2045.el" "gnus/rfc2047.el" "gnus/rfc2104.el" +;;;;;; "gnus/rfc2231.el" "gnus/sieve-manage.el" "gnus/smime.el" ;;;;;; "gnus/spam-stat.el" "gnus/spam-wash.el" "gnus/starttls.el" -;;;;;; "gnus/utf7.el" "gnus/webmail.el" "help.el" "indent.el" "international/characters.el" -;;;;;; "international/fontset.el" "international/iso-ascii.el" "international/ja-dic-cnv.el" +;;;;;; "gnus/utf7.el" "gnus/webmail.el" "help.el" "hex-util.el" +;;;;;; "indent.el" "international/characters.el" "international/fontset.el" +;;;;;; "international/iso-ascii.el" "international/ja-dic-cnv.el" ;;;;;; "international/ja-dic-utl.el" "international/latin-1.el" ;;;;;; "international/latin-2.el" "international/latin-3.el" "international/latin-4.el" ;;;;;; "international/latin-5.el" "international/latin-8.el" "international/latin-9.el" @@ -31378,44 +31913,51 @@ Zone out, completely. ;;;;;; "ldefs-boot.el" "loadup.el" "mail/blessmail.el" "mail/mailheader.el" ;;;;;; "mail/mailpost.el" "mail/mspools.el" "mail/rfc2368.el" "mail/rfc822.el" ;;;;;; "mail/rmail-spam-filter.el" "mail/uce.el" "mail/vms-pmail.el" -;;;;;; "mh-e/mh-acros.el" "mh-e/mh-alias.el" "mh-e/mh-buffers.el" +;;;;;; "md4.el" "mh-e/mh-acros.el" "mh-e/mh-alias.el" "mh-e/mh-buffers.el" ;;;;;; "mh-e/mh-compat.el" "mh-e/mh-funcs.el" "mh-e/mh-gnus.el" ;;;;;; "mh-e/mh-identity.el" "mh-e/mh-inc.el" "mh-e/mh-junk.el" ;;;;;; "mh-e/mh-letter.el" "mh-e/mh-limit.el" "mh-e/mh-loaddefs.el" ;;;;;; "mh-e/mh-mime.el" "mh-e/mh-print.el" "mh-e/mh-scan.el" "mh-e/mh-search.el" ;;;;;; "mh-e/mh-seq.el" "mh-e/mh-show.el" "mh-e/mh-speed.el" "mh-e/mh-thread.el" ;;;;;; "mh-e/mh-tool-bar.el" "mh-e/mh-utils.el" "mh-e/mh-xface.el" -;;;;;; "misc.el" "mouse-copy.el" "mouse-drag.el" "mouse.el" "net/eudc-vars.el" -;;;;;; "net/eudcb-bbdb.el" "net/eudcb-ldap.el" "net/eudcb-mab.el" -;;;;;; "net/eudcb-ph.el" "net/ldap.el" "net/netrc.el" "net/socks.el" -;;;;;; "net/tls.el" "net/tramp-cache.el" "net/tramp-cmds.el" "net/tramp-compat.el" -;;;;;; "net/tramp-fish.el" "net/tramp-gw.el" "net/tramp-smb.el" -;;;;;; "net/tramp-uu.el" "net/trampver.el" "patcomp.el" "paths.el" -;;;;;; "pcvs-info.el" "pcvs-parse.el" "pcvs-util.el" "pgg-def.el" -;;;;;; "pgg-parse.el" "pgg-pgp.el" "pgg-pgp5.el" "play/gamegrid.el" -;;;;;; "play/gametree.el" "play/meese.el" "progmodes/ada-prj.el" -;;;;;; "progmodes/cc-align.el" "progmodes/cc-awk.el" "progmodes/cc-bytecomp.el" -;;;;;; "progmodes/cc-cmds.el" "progmodes/cc-defs.el" "progmodes/cc-fonts.el" -;;;;;; "progmodes/cc-langs.el" "progmodes/cc-menus.el" "progmodes/ebnf-abn.el" -;;;;;; "progmodes/ebnf-bnf.el" "progmodes/ebnf-dtd.el" "progmodes/ebnf-ebx.el" -;;;;;; "progmodes/ebnf-iso.el" "progmodes/ebnf-otz.el" "progmodes/ebnf-yac.el" -;;;;;; "progmodes/idlw-complete-structtag.el" "progmodes/idlw-help.el" -;;;;;; "progmodes/idlw-toolbar.el" "progmodes/mantemp.el" "progmodes/xscheme.el" -;;;;;; "ps-mule.el" "register.el" "replace.el" "rfn-eshadow.el" -;;;;;; "s-region.el" "saveplace.el" "sb-image.el" "scroll-bar.el" -;;;;;; "select.el" "soundex.el" "startup.el" "subdirs.el" "tempo.el" -;;;;;; "textmodes/bib-mode.el" "textmodes/makeinfo.el" "textmodes/page-ext.el" -;;;;;; "textmodes/page.el" "textmodes/refbib.el" "textmodes/refer.el" -;;;;;; "textmodes/reftex-auc.el" "textmodes/reftex-dcr.el" "textmodes/reftex-ref.el" -;;;;;; "textmodes/reftex-sel.el" "textmodes/reftex-toc.el" "textmodes/texnfo-upd.el" -;;;;;; "textmodes/text-mode.el" "timezone.el" "tooltip.el" "tree-widget.el" -;;;;;; "uniquify.el" "url/url-about.el" "url/url-cookie.el" "url/url-dired.el" -;;;;;; "url/url-expand.el" "url/url-ftp.el" "url/url-history.el" -;;;;;; "url/url-imap.el" "url/url-methods.el" "url/url-nfs.el" "url/url-proxy.el" -;;;;;; "url/url-vars.el" "url/vc-dav.el" "vc-hooks.el" "vcursor.el" -;;;;;; "version.el" "vms-patch.el" "vmsproc.el" "vt-control.el" -;;;;;; "vt100-led.el" "w32-fns.el" "w32-vars.el" "widget.el" "window.el" -;;;;;; "x-dnd.el") (18214 7224 993409)) +;;;;;; "misc.el" "mouse-copy.el" "mouse-drag.el" "mouse.el" "net/dig.el" +;;;;;; "net/dns.el" "net/eudc-vars.el" "net/eudcb-bbdb.el" "net/eudcb-ldap.el" +;;;;;; "net/eudcb-mab.el" "net/eudcb-ph.el" "net/hmac-def.el" "net/hmac-md5.el" +;;;;;; "net/imap.el" "net/ldap.el" "net/netrc.el" "net/ntlm.el" +;;;;;; "net/sasl-cram.el" "net/sasl-digest.el" "net/sasl-ntlm.el" +;;;;;; "net/sasl.el" "net/socks.el" "net/tls.el" "net/tramp-cache.el" +;;;;;; "net/tramp-cmds.el" "net/tramp-compat.el" "net/tramp-fish.el" +;;;;;; "net/tramp-gw.el" "net/tramp-smb.el" "net/tramp-uu.el" "net/trampver.el" +;;;;;; "nxml/nxml-enc.el" "nxml/nxml-maint.el" "nxml/nxml-ns.el" +;;;;;; "nxml/nxml-outln.el" "nxml/nxml-parse.el" "nxml/nxml-rap.el" +;;;;;; "nxml/nxml-util.el" "nxml/rng-dt.el" "nxml/rng-loc.el" "nxml/rng-maint.el" +;;;;;; "nxml/rng-match.el" "nxml/rng-parse.el" "nxml/rng-pttrn.el" +;;;;;; "nxml/rng-uri.el" "nxml/rng-util.el" "nxml/xsd-regexp.el" +;;;;;; "password-cache.el" "patcomp.el" "paths.el" "pcvs-info.el" +;;;;;; "pcvs-parse.el" "pcvs-util.el" "pgg-def.el" "pgg-parse.el" +;;;;;; "pgg-pgp.el" "pgg-pgp5.el" "play/gamegrid.el" "play/gametree.el" +;;;;;; "play/meese.el" "progmodes/ada-prj.el" "progmodes/cc-align.el" +;;;;;; "progmodes/cc-awk.el" "progmodes/cc-bytecomp.el" "progmodes/cc-cmds.el" +;;;;;; "progmodes/cc-defs.el" "progmodes/cc-fonts.el" "progmodes/cc-langs.el" +;;;;;; "progmodes/cc-menus.el" "progmodes/ebnf-abn.el" "progmodes/ebnf-bnf.el" +;;;;;; "progmodes/ebnf-dtd.el" "progmodes/ebnf-ebx.el" "progmodes/ebnf-iso.el" +;;;;;; "progmodes/ebnf-otz.el" "progmodes/ebnf-yac.el" "progmodes/idlw-complete-structtag.el" +;;;;;; "progmodes/idlw-help.el" "progmodes/idlw-toolbar.el" "progmodes/mantemp.el" +;;;;;; "progmodes/xscheme.el" "ps-mule.el" "register.el" "replace.el" +;;;;;; "rfn-eshadow.el" "s-region.el" "saveplace.el" "sb-image.el" +;;;;;; "scroll-bar.el" "select.el" "soundex.el" "startup.el" "subdirs.el" +;;;;;; "tempo.el" "textmodes/bib-mode.el" "textmodes/makeinfo.el" +;;;;;; "textmodes/page-ext.el" "textmodes/page.el" "textmodes/refbib.el" +;;;;;; "textmodes/refer.el" "textmodes/reftex-auc.el" "textmodes/reftex-dcr.el" +;;;;;; "textmodes/reftex-ref.el" "textmodes/reftex-sel.el" "textmodes/reftex-toc.el" +;;;;;; "textmodes/texnfo-upd.el" "textmodes/text-mode.el" "timezone.el" +;;;;;; "tooltip.el" "tree-widget.el" "uniquify.el" "url/url-about.el" +;;;;;; "url/url-cookie.el" "url/url-dired.el" "url/url-expand.el" +;;;;;; "url/url-ftp.el" "url/url-history.el" "url/url-imap.el" "url/url-methods.el" +;;;;;; "url/url-nfs.el" "url/url-proxy.el" "url/url-vars.el" "url/vc-dav.el" +;;;;;; "vc-hooks.el" "vcursor.el" "version.el" "vms-patch.el" "vmsproc.el" +;;;;;; "vt-control.el" "vt100-led.el" "w32-fns.el" "w32-vars.el" +;;;;;; "widget.el" "window.el" "x-dnd.el") (18317 32734 645076)) ;;;*** From 28dd7fcf2ff4f53d5eaaf9c45624e04a6a33a9b1 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 04:11:16 +0000 Subject: [PATCH 132/439] Update for doc/ directory. finder-inf no longer in CVS. --- admin/make-tarball.txt | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/admin/make-tarball.txt b/admin/make-tarball.txt index 9a202d62f85..ea2f98284e0 100644 --- a/admin/make-tarball.txt +++ b/admin/make-tarball.txt @@ -21,8 +21,8 @@ For each step, check for possible errors. 5. rm configure; make bootstrap -6. Commit configure, README, etc/AUTHORS, lisp/finder-inf.el, - lisp/version.el, man/emacs.texi, lispref/elisp.texi, +6. Commit configure, README, doc/emacs/emacs.texi, + doc/lispref/elisp.texi, etc/AUTHORS, lisp/version.el, mac/Emacs.app/Contents/Resources/English.lproj/InfoPlist.strings, mac/src/Emacs.r, nt/emacs.rc. Copy lisp/loaddefs.el to lisp/ldefs-boot.el and commit lisp/ldefs-boot.el. For a release, From fdecf90749c6594b2d47a93b4e8adb11ffb264e4 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 04:12:22 +0000 Subject: [PATCH 133/439] (select-safe-coding-system-function): Doc fix. --- src/ChangeLog | 4 ++++ src/coding.c | 4 +++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 001819a32a8..e04746694f1 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-16 Glenn Morris + + * coding.c (select-safe-coding-system-function): Doc fix. + 2008-01-15 Glenn Morris * config.in: Revert 2008-01-13 change: this is a generated file. diff --git a/src/coding.c b/src/coding.c index dda3f0f854c..7bfec68d5d1 100644 --- a/src/coding.c +++ b/src/coding.c @@ -8157,7 +8157,9 @@ Only 128th through 159th elements has a meaning. */); If set, this function is called to force a user to select a proper coding system which can encode the text in the case that a default -coding system used in each operation can't encode the text. +coding system used in each operation can't encode the text. The +function should take care that the buffer is not modified while +the coding system is being selected. The default value is `select-safe-coding-system' (which see). */); Vselect_safe_coding_system_function = Qnil; From 309c894f0a7bae1eb974d0c45552cb53e34c92d6 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 04:13:44 +0000 Subject: [PATCH 134/439] Ulf Jasper (icalendar-version): Increase to 0.16. (icalendar-export-file, icalendar-import-file): Restore significant trailing whitespace in `interactive' prompts. Tom Tromey (icalendar--convert-tz-offset) (icalendar--parse-vtimezone, icalendar--convert-all-timezones) (icalendar--find-time-zone): New functions. (icalendar--decode-isodatetime): Add `zone' argument, passed to `decode-time'. Doc fix. (icalendar--convert-ical-to-diary): Compute zone-map. Pass timezone to icalendar--decode-isodatetime. --- lisp/ChangeLog | 18 ++++- lisp/calendar/icalendar.el | 159 +++++++++++++++++++++++++++++-------- 2 files changed, 142 insertions(+), 35 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1f3f2a50d4f..2ee346b33a2 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,4 +1,20 @@ -2008-01-16 acm +2008-01-16 Ulf Jasper + + * calendar/icalendar.el (icalendar-version): Increase to 0.16. + (icalendar-export-file, icalendar-import-file): Restore + significant trailing whitespace in `interactive' prompts. + +2008-01-16 Tom Tromey + + * calendar/icalendar.el (icalendar--convert-tz-offset) + (icalendar--parse-vtimezone, icalendar--convert-all-timezones) + (icalendar--find-time-zone): New functions. + (icalendar--decode-isodatetime): Add `zone' argument, passed to + `decode-time'. Doc fix. + (icalendar--convert-ical-to-diary): Compute zone-map. Pass + timezone to icalendar--decode-isodatetime. + +2008-01-16 Alan Mackenzie * progmodes/cc-vars.el (c-constant-symbol): Put this defun inside an eval-and-compile, so as to permit byte-compiling (e.g. in diff --git a/lisp/calendar/icalendar.el b/lisp/calendar/icalendar.el index 46b16a54c89..b05598b6a27 100644 --- a/lisp/calendar/icalendar.el +++ b/lisp/calendar/icalendar.el @@ -1,6 +1,7 @@ ;;; icalendar.el --- iCalendar implementation -*-coding: utf-8 -*- -;; Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +;; Copyright (C) 2002, 2003, 2004, 2005, 2006, 2007, 2008 +;; Free Software Foundation, Inc. ;; Author: Ulf Jasper ;; Created: August 2002 @@ -40,33 +41,36 @@ ;; 0.07 onwards: see lisp/ChangeLog -;; 0.06: Bugfixes regarding icalendar-import-format-*. -;; Fix in icalendar-convert-diary-to-ical -- thanks to Philipp -;; Grau. +;; 0.06: (2004-10-06) +;; - Bugfixes regarding icalendar-import-format-*. +;; - Fix in icalendar-convert-diary-to-ical -- thanks to Philipp Grau. -;; 0.05: New import format scheme: Replaced icalendar-import-prefix-*, -;; icalendar-import-ignored-properties, and -;; icalendar-import-separator with icalendar-import-format(-*). -;; icalendar-import-file and icalendar-convert-diary-to-ical -;; have an extra parameter which should prevent them from -;; erasing their target files (untested!). -;; Tested with Emacs 21.3.2 +;; 0.05: (2003-06-19) +;; - New import format scheme: Replaced icalendar-import-prefix-*, +;; icalendar-import-ignored-properties, and +;; icalendar-import-separator with icalendar-import-format(-*). +;; - icalendar-import-file and icalendar-convert-diary-to-ical +;; have an extra parameter which should prevent them from +;; erasing their target files (untested!). +;; - Tested with Emacs 21.3.2 -;; 0.04: Bugfix: import: double quoted param values did not work -;; Read DURATION property when importing. -;; Added parameter icalendar-duration-correction. +;; 0.04: +;; - Bugfix: import: double quoted param values did not work +;; - Read DURATION property when importing. +;; - Added parameter icalendar-duration-correction. -;; 0.03: Export takes care of european-calendar-style. -;; Tested with Emacs 21.3.2 and XEmacs 21.4.12 +;; 0.03: (2003-05-07) +;; - Export takes care of european-calendar-style. +;; - Tested with Emacs 21.3.2 and XEmacs 21.4.12 -;; 0.02: Should work in XEmacs now. Thanks to Len Trigg for the -;; XEmacs patches! -;; Added exporting from Emacs diary to ical. -;; Some bugfixes, after testing with calendars from -;; http://icalshare.com. -;; Tested with Emacs 21.3.2 and XEmacs 21.4.12 +;; 0.02: +;; - Should work in XEmacs now. Thanks to Len Trigg for the XEmacs patches! +;; - Added exporting from Emacs diary to ical. +;; - Some bugfixes, after testing with calendars from http://icalshare.com. +;; - Tested with Emacs 21.3.2 and XEmacs 21.4.12 -;; 0.01: First published version. Trial version. Alpha version. +;; 0.01: (2003-03-21) +;; - First published version. Trial version. Alpha version. ;; ====================================================================== ;; To Do: @@ -86,7 +90,7 @@ ;; + the parser is too soft ;; + error log is incomplete ;; + nice to have: #include "webcal://foo.com/some-calendar.ics" -;; + timezones, currently all times are local! +;; + timezones probably still need some improvements. ;; * Export from diary to ical ;; + diary-date, diary-float, and self-made sexp entries are not @@ -101,7 +105,7 @@ ;;; Code: -(defconst icalendar-version "0.15" +(defconst icalendar-version "0.16" "Version number of icalendar.el.") ;; ====================================================================== @@ -390,15 +394,90 @@ children." (append result (list (list param-name param-value))))))) result)) -(defun icalendar--decode-isodatetime (isodatetimestring &optional day-shift) +(defun icalendar--convert-tz-offset (alist dst-p) + "Return a cons of two strings representing a timezone start. +ALIST is an alist entry from a VTIMEZONE, like STANDARD. +DST-P is non-nil if this is for daylight savings time. +The strings are suitable for assembling into a TZ variable." + (let ((offset (car (cddr (assq 'TZOFFSETTO alist)))) + (rrule-value (car (cddr (assq 'RRULE alist)))) + (dtstart (car (cddr (assq 'DTSTART alist))))) + ;; FIXME: for now we only handle RRULE and not RDATE here. + (when (and offset rrule-value dtstart) + (let* ((rrule (icalendar--split-value rrule-value)) + (freq (cadr (assq 'FREQ rrule))) + (bymonth (cadr (assq 'BYMONTH rrule))) + (byday (cadr (assq 'BYDAY rrule)))) + ;; FIXME: we don't correctly handle WKST here. + (if (and (string= freq "YEARLY") bymonth) + (cons + (concat + ;; Fake a name. + (if dst-p "(DST?)" "(STD?)") + ;; For TZ, OFFSET is added to the local time. So, + ;; invert the values. + (if (eq (aref offset 0) ?-) "+" "-") + (substring offset 1 3) + ":" + (substring offset 3 5)) + ;; The start time. + (let* ((day (icalendar--get-weekday-number (substring byday -2))) + (week (if (eq day -1) + byday + (substring byday 0 -2)))) + (concat "M" bymonth "." week "." (if (eq day -1) "0" + (int-to-string day)) + ;; Start time. + "/" + (substring dtstart -6 -4) + ":" + (substring dtstart -4 -2) + ":" + (substring dtstart -2))))))))) + +(defun icalendar--parse-vtimezone (alist) + "Turn a VTIMEZONE ALIST into a cons (ID . TZ-STRING). +Return nil if timezone cannot be parsed." + (let* ((tz-id (icalendar--get-event-property alist 'TZID)) + (daylight (cadr (cdar (icalendar--get-children alist 'DAYLIGHT)))) + (day (and daylight (icalendar--convert-tz-offset daylight t))) + (standard (cadr (cdar (icalendar--get-children alist 'STANDARD)))) + (std (and standard (icalendar--convert-tz-offset standard nil)))) + (if (and tz-id std) + (cons tz-id + (if day + (concat (car std) (car day) + "," (cdr day) "," (cdr std)) + (car std)))))) + +(defun icalendar--convert-all-timezones (icalendar) + "Convert all timezones in the ICALENDAR into an alist. +Each element of the alist is a cons (ID . TZ-STRING), +like `icalendar--parse-vtimezone'." + (let (result) + (dolist (zone (icalendar--get-children (car icalendar) 'VTIMEZONE)) + (setq zone (icalendar--parse-vtimezone zone)) + (if zone + (setq result (cons zone result)))) + result)) + +(defun icalendar--find-time-zone (prop-list zone-map) + "Return a timezone string for the time zone in PROP-LIST, or nil if none. +ZONE-MAP is a timezone alist as returned by `icalendar--convert-all-timezones'." + (let ((id (plist-get prop-list 'TZID))) + (if id + (cdr (assoc id zone-map))))) + +(defun icalendar--decode-isodatetime (isodatetimestring &optional day-shift + zone) "Return ISODATETIMESTRING in format like `decode-time'. Converts from ISO-8601 to Emacs representation. If ISODATETIMESTRING specifies UTC time (trailing letter Z) the decoded time is given in the local time zone! If optional parameter DAY-SHIFT is non-nil the result is shifted by DAY-SHIFT days. +ZONE, if provided, is the timezone, in any format understood by `encode-time'. -FIXME: TZID-attributes are ignored....! FIXME: multiple comma-separated values should be allowed!" (icalendar--dmsg isodatetimestring) (if isodatetimestring @@ -433,7 +512,7 @@ FIXME: multiple comma-separated values should be allowed!" ;; create the decoded date-time ;; FIXME!?! (condition-case nil - (decode-time (encode-time second minute hour day month year)) + (decode-time (encode-time second minute hour day month year zone)) (error (message "Cannot decode \"%s\"" isodatetimestring) ;; hope for the best... @@ -710,7 +789,7 @@ would be \"pm\"." "Export diary file to iCalendar format. All diary entries in the file DIARY-FILENAME are converted to iCalendar format. The result is appended to the file ICAL-FILENAME." - (interactive "FExport diary data from file: + (interactive "FExport diary data from file: Finto iCalendar file: ") (save-current-buffer (set-buffer (find-file diary-filename)) @@ -1454,8 +1533,8 @@ Argument ICAL-FILENAME output iCalendar file. Argument DIARY-FILENAME input `diary-file'. Optional argument NON-MARKING determines whether events are created as non-marking or not." - (interactive "fImport iCalendar data from file: -Finto diary file: + (interactive "fImport iCalendar data from file: +Finto diary file: p") ;; clean up the diary file (save-current-buffer @@ -1566,6 +1645,7 @@ written into the buffer `*icalendar-errors*'." (error-string "") (event-ok t) (found-error nil) + (zone-map (icalendar--convert-all-timezones ical-list)) e diary-string) ;; step through all events/appointments (while ev @@ -1574,13 +1654,24 @@ written into the buffer `*icalendar-errors*'." (setq event-ok nil) (condition-case error-val (let* ((dtstart (icalendar--get-event-property e 'DTSTART)) - (dtstart-dec (icalendar--decode-isodatetime dtstart)) + (dtstart-zone (icalendar--find-time-zone + (icalendar--get-event-property-attributes + e 'DTSTART) + zone-map)) + (dtstart-dec (icalendar--decode-isodatetime dtstart nil + dtstart-zone)) (start-d (icalendar--datetime-to-diary-date dtstart-dec)) (start-t (icalendar--datetime-to-colontime dtstart-dec)) (dtend (icalendar--get-event-property e 'DTEND)) - (dtend-dec (icalendar--decode-isodatetime dtend)) - (dtend-1-dec (icalendar--decode-isodatetime dtend -1)) + (dtend-zone (icalendar--find-time-zone + (icalendar--get-event-property-attributes + e 'DTEND) + zone-map)) + (dtend-dec (icalendar--decode-isodatetime dtend + nil dtend-zone)) + (dtend-1-dec (icalendar--decode-isodatetime dtend -1 + dtend-zone)) end-d end-1-d end-t From 6b2872c2167f9f47a7f1ef865adcce0c8121ff9d Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 04:14:45 +0000 Subject: [PATCH 135/439] Ulf Jasper (icalendar-export-file, icalendar-import-file): Restore significant trailing whitespace in `interactive' prompts. --- lisp/ChangeLog | 8 ++++++-- lisp/calendar/icalendar.el | 6 +++--- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 0ec33846981..a9e8fa4fbfb 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-16 Ulf Jasper + + * calendar/icalendar.el (icalendar-export-file) + (icalendar-import-file): Restore significant trailing whitespace + in `interactive' prompts. + 2008-01-15 Dan Nicolaescu * vc-arch.el (vc-arch-delete-rej-if-obsolete): Remove the @@ -20,8 +26,6 @@ * progmodes/cc-vars.el (c-hanging-braces-alist): Remove the obscure non-working fragment ":value c-". -2008-01-14 Alan Mackenzie - * progmodes/cc-engine.el (c-guess-basic-syntax): prevent a macro call inside a struct being recognised as a K&R argument. diff --git a/lisp/calendar/icalendar.el b/lisp/calendar/icalendar.el index a3dc34a2e9b..982934d94f4 100644 --- a/lisp/calendar/icalendar.el +++ b/lisp/calendar/icalendar.el @@ -710,7 +710,7 @@ would be \"pm\"." "Export diary file to iCalendar format. All diary entries in the file DIARY-FILENAME are converted to iCalendar format. The result is appended to the file ICAL-FILENAME." - (interactive "FExport diary data from file: + (interactive "FExport diary data from file: Finto iCalendar file: ") (save-current-buffer (set-buffer (find-file diary-filename)) @@ -1454,8 +1454,8 @@ Argument ICAL-FILENAME output iCalendar file. Argument DIARY-FILENAME input `diary-file'. Optional argument NON-MARKING determines whether events are created as non-marking or not." - (interactive "fImport iCalendar data from file: -Finto diary file: + (interactive "fImport iCalendar data from file: +Finto diary file: p") ;; clean up the diary file (save-current-buffer From 5525a92a34aff85e9754b0cca1ba84f83a83673b Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 04:17:13 +0000 Subject: [PATCH 136/439] finder-inf no longer in CVS. Fill last paragraph. --- admin/make-tarball.txt | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/admin/make-tarball.txt b/admin/make-tarball.txt index e56c26571d9..e5a06e2d0ef 100644 --- a/admin/make-tarball.txt +++ b/admin/make-tarball.txt @@ -21,8 +21,8 @@ For each step, check for possible errors. 5. rm configure; make bootstrap -6. Commit configure, README, AUTHORS, lisp/finder-inf.el, - lisp/version.el, man/emacs.texi, lispref/elisp.texi, +6. Commit configure, README, AUTHORS, lisp/version.el, + man/emacs.texi, lispref/elisp.texi, mac/Emacs.app/Contents/Resources/English.lproj/InfoPlist.strings, mac/src/Emacs.r, nt/emacs.rc. Copy lisp/loaddefs.el to lisp/ldefs-boot.el and commit lisp/ldefs-boot.el. For a release, @@ -73,10 +73,11 @@ For each step, check for possible errors. ftp://alpha.gnu.org/gnu/emacs/pretest/ for a pretest, at ftp://ftp.gnu.org/gnu/emacs/ for a release. -14. For a pretest, let Richard Stallman know about the new pretest and - tell him to announce it using the announcement you prepared. Remind - him to set a Reply-to header to . - For a release, Richard should prepare the announcement himself, - possibly starting from a previous announcment. +14. For a pretest, let Richard Stallman know about the + new pretest and tell him to announce it using the announcement you + prepared. Remind him to set a Reply-to header to + . For a release, Richard should prepare + the announcement himself, possibly starting from a previous + announcment. # arch-tag: c23c771f-ca26-4584-8a04-50ecf0989390 From ed398055862ab898d8dc3037a537af94ea69910b Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 04:33:32 +0000 Subject: [PATCH 137/439] Sven Joachim Add --lzma. --- ChangeLog | 4 ++++ make-dist | 6 ++++++ 2 files changed, 10 insertions(+) diff --git a/ChangeLog b/ChangeLog index 7e049f376d1..17f0c98a91c 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-01-16 Sven Joachim + + * make-dist: Add --lzma. + 2008-01-16 Glenn Morris * Makefile.in (maybe_bootstrap): Remove texinfo message, since diff --git a/make-dist b/make-dist index 26fb5b31daf..305112ed153 100755 --- a/make-dist +++ b/make-dist @@ -85,6 +85,10 @@ while [ $# -gt 0 ]; do "--bzip2") default_gzip="bzip2" ;; + ## Same with lzma. + "--lzma") + default_gzip="lzma" + ;; "--snapshot") clean_up=yes @@ -99,6 +103,7 @@ while [ $# -gt 0 ]; do echo " --bzip2 use bzip2 instead of gzip" echo " --clean-up delete staging directories when done" echo " --compress use compress instead of gzip" + echo " --lzma use lzma instead of gzip" echo " --newer=TIME don't include files older than TIME" echo " --no-check don't check for bad file names etc." echo " --no-update don't recompile or do analogous things" @@ -750,6 +755,7 @@ if [ "${make_tar}" = yes ]; then case "${default_gzip}" in bzip2) gzip_extension=.bz2 ;; compress* ) gzip_extension=.Z ;; + lzma) gzip_extension=.lzma ;; * ) gzip_extension=.gz ;; esac echo "Creating tar file" From 8772b5a8566ddab4aea41c6bd24d4498f56f793b Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 05:11:33 +0000 Subject: [PATCH 138/439] Fix alignment whitespace in usage. --- make-dist | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/make-dist b/make-dist index 305112ed153..19c79b4db0c 100755 --- a/make-dist +++ b/make-dist @@ -100,10 +100,10 @@ while [ $# -gt 0 ]; do "--help") echo "Usage: ${progname} [options]" echo "" - echo " --bzip2 use bzip2 instead of gzip" + echo " --bzip2 use bzip2 instead of gzip" echo " --clean-up delete staging directories when done" echo " --compress use compress instead of gzip" - echo " --lzma use lzma instead of gzip" + echo " --lzma use lzma instead of gzip" echo " --newer=TIME don't include files older than TIME" echo " --no-check don't check for bad file names etc." echo " --no-update don't recompile or do analogous things" From 28e4e2b434e3574f01b69c585dcccaecde6c940f Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 16 Jan 2008 06:22:59 +0000 Subject: [PATCH 139/439] * smerge-mode.el (smerge-start-session): Rename from smerge-auto. * pcvs.el (cvs-revert-if-needed): * vc.el (vc-maybe-resolve-conflicts): Rename callers. * vc-svn.el (vc-svn-find-file-hook): * vc-arch.el (vc-arch-find-file-hook): Undo previous change. --- lisp/ChangeLog | 9 +++++++++ lisp/pcvs.el | 2 +- lisp/smerge-mode.el | 2 +- lisp/vc-arch.el | 2 +- lisp/vc-svn.el | 2 +- lisp/vc.el | 2 +- 6 files changed, 14 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2ee346b33a2..8ae0d57023d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,12 @@ +2008-01-16 Dan Nicolaescu + + * smerge-mode.el (smerge-start-session): Rename from smerge-auto. + * pcvs.el (cvs-revert-if-needed): + * vc.el (vc-maybe-resolve-conflicts): Rename callers. + + * vc-svn.el (vc-svn-find-file-hook): + * vc-arch.el (vc-arch-find-file-hook): Undo previous change. + 2008-01-16 Ulf Jasper * calendar/icalendar.el (icalendar-version): Increase to 0.16. diff --git a/lisp/pcvs.el b/lisp/pcvs.el index 401962872a2..462597a277b 100644 --- a/lisp/pcvs.el +++ b/lisp/pcvs.el @@ -2311,7 +2311,7 @@ this file, or a list of arguments to send to the program." ;; do want to reset the mode for VC, so we do it explicitly. (vc-find-file-hook) (when (eq (cvs-fileinfo->type fileinfo) 'CONFLICT) - (smerge-auto)))))))) + (smerge-start-session)))))))) (defun cvs-change-cvsroot (newroot) diff --git a/lisp/smerge-mode.el b/lisp/smerge-mode.el index e7352c4479e..f2a7a9caf9e 100644 --- a/lisp/smerge-mode.el +++ b/lisp/smerge-mode.el @@ -1050,7 +1050,7 @@ with a \\[universal-argument] prefix, makes up a 3-way conflict." (smerge-remove-props (point-min) (point-max)))) ;;;###autoload -(defun smerge-auto () +(defun smerge-start-session () "Turn on `smerge-mode' and move point to first conflict marker. If no conflict maker is found, turn off `smerge-mode'." (smerge-mode 1) diff --git a/lisp/vc-arch.el b/lisp/vc-arch.el index 97c99dd8193..284fe032a25 100644 --- a/lisp/vc-arch.el +++ b/lisp/vc-arch.el @@ -360,7 +360,7 @@ Return non-nil if FILE is unchanged." (if (not (re-search-forward "^<<<<<<< " nil t)) ;; The .rej file is obsolete. (condition-case nil (delete-file rej) (error nil)) - (smerge-auto) + (smerge-mode 1) (add-hook 'after-save-hook 'vc-arch-delete-rej-if-obsolete nil t) (message "There are unresolved conflicts in this file"))) diff --git a/lisp/vc-svn.el b/lisp/vc-svn.el index 16e10edc202..e463e138490 100644 --- a/lisp/vc-svn.el +++ b/lisp/vc-svn.el @@ -551,7 +551,7 @@ and that it passes `vc-svn-global-switches' to it before FLAGS." (re-search-forward "^<<<<<<< " nil t)) ;; There are conflict markers. (progn - (smerge-auto) + (smerge-start-session) (add-hook 'after-save-hook 'vc-svn-resolve-when-done nil t)) ;; There are no conflict markers. This is problematic: maybe it means ;; the conflict has been resolved and we should immediately call "svn diff --git a/lisp/vc.el b/lisp/vc.el index cc2627bb792..ac83365613b 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -2245,7 +2245,7 @@ See Info node `Merging'." (defun vc-maybe-resolve-conflicts (file status &optional name-A name-B) (vc-resynch-buffer file t (not (buffer-modified-p))) (if (zerop status) (message "Merge successful") - (smerge-auto) + (smerge-mode 1) (message "File contains conflicts."))) ;;;###autoload From 2d216b52ea90383bda098aea2786dba39d4d8251 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 08:10:36 +0000 Subject: [PATCH 140/439] (comint-regexp-arg): Fix no-input case. --- lisp/ChangeLog | 4 ++++ lisp/comint.el | 6 ++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index a9e8fa4fbfb..12621959992 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-16 Glenn Morris + + * comint.el (comint-regexp-arg): Fix no-input case. + 2008-01-16 Ulf Jasper * calendar/icalendar.el (icalendar-export-file) diff --git a/lisp/comint.el b/lisp/comint.el index 0a22cdba5c9..f8a47152976 100644 --- a/lisp/comint.el +++ b/lisp/comint.el @@ -1021,9 +1021,11 @@ See also `comint-read-input-ring'." (last-command last-command) (regexp (read-from-minibuffer prompt nil nil nil 'minibuffer-history-search-history))) + ;; If the user didn't enter anything, nothing is added to m-h-s-h. + ;; Use the previous search regexp, if there is one. (list (if (string-equal regexp "") - (setcar minibuffer-history-search-history - (nth 1 minibuffer-history-search-history)) + (or (car minibuffer-history-search-history) + regexp) regexp) (prefix-numeric-value current-prefix-arg)))) From b11a06ccc7ea7e282e435bf4b3e46f4ed3bee9f1 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 08:11:05 +0000 Subject: [PATCH 141/439] (comint-regexp-arg): Fix no-input case. --- lisp/ChangeLog | 4 ++++ lisp/comint.el | 6 ++++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8ae0d57023d..b1d4e26dfdb 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-16 Glenn Morris + + * comint.el (comint-regexp-arg): Fix no-input case. + 2008-01-16 Dan Nicolaescu * smerge-mode.el (smerge-start-session): Rename from smerge-auto. diff --git a/lisp/comint.el b/lisp/comint.el index 6fb89e28181..70d6f85ff68 100644 --- a/lisp/comint.el +++ b/lisp/comint.el @@ -1022,9 +1022,11 @@ See also `comint-read-input-ring'." (last-command last-command) (regexp (read-from-minibuffer prompt nil nil nil 'minibuffer-history-search-history))) + ;; If the user didn't enter anything, nothing is added to m-h-s-h. + ;; Use the previous search regexp, if there is one. (list (if (string-equal regexp "") - (setcar minibuffer-history-search-history - (nth 1 minibuffer-history-search-history)) + (or (car minibuffer-history-search-history) + regexp) regexp) (prefix-numeric-value current-prefix-arg)))) From a9c6b41c6351342b05f1c1c236829d795fce21e8 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 16 Jan 2008 08:57:42 +0000 Subject: [PATCH 142/439] Regenerate. --- lisp/ldefs-boot.el | 20 ++++++++++---------- 1 file changed, 10 insertions(+), 10 deletions(-) diff --git a/lisp/ldefs-boot.el b/lisp/ldefs-boot.el index 4397568b2d7..5b2c5030a6b 100644 --- a/lisp/ldefs-boot.el +++ b/lisp/ldefs-boot.el @@ -4571,7 +4571,7 @@ read/written by MS-DOS software, or for display on the MS-DOS terminal. ;;;### (autoloads (comint-redirect-results-list-from-process comint-redirect-results-list ;;;;;; comint-redirect-send-command-to-process comint-redirect-send-command ;;;;;; comint-run make-comint make-comint-in-buffer) "comint" "comint.el" -;;;;;; (18316 9691)) +;;;;;; (18317 49783)) ;;; Generated autoloads from comint.el (defvar comint-output-filter-functions '(comint-postoutput-scroll-to-bottom comint-watch-for-password-prompt) "\ @@ -14645,7 +14645,7 @@ FORMATS is the value to use for `ibuffer-formats'. ;;;### (autoloads (icalendar-import-buffer icalendar-import-file ;;;;;; icalendar-export-region icalendar-export-file) "icalendar" -;;;;;; "calendar/icalendar.el" (18317 7567)) +;;;;;; "calendar/icalendar.el" (18317 33926)) ;;; Generated autoloads from calendar/icalendar.el (autoload 'icalendar-export-file "icalendar" "\ @@ -20771,7 +20771,7 @@ Setup shell-mode to use pcomplete. ;;;### (autoloads (cvs-dired-use-hook cvs-dired-action cvs-status ;;;;;; cvs-update cvs-examine cvs-quickdir cvs-checkout) "pcvs" -;;;;;; "pcvs.el" (18317 25035)) +;;;;;; "pcvs.el" (18317 49783)) ;;; Generated autoloads from pcvs.el (autoload 'cvs-checkout "pcvs" "\ @@ -25096,8 +25096,8 @@ symmetrical ones, and the same character twice for the others. ;;;*** -;;;### (autoloads (smerge-auto smerge-mode smerge-ediff) "smerge-mode" -;;;;;; "smerge-mode.el" (18317 11736)) +;;;### (autoloads (smerge-start-session smerge-mode smerge-ediff) +;;;;;; "smerge-mode" "smerge-mode.el" (18317 49783)) ;;; Generated autoloads from smerge-mode.el (autoload 'smerge-ediff "smerge-mode" "\ @@ -25113,7 +25113,7 @@ Minor mode to simplify editing output from the diff3 program. \(fn &optional ARG)" t nil) -(autoload 'smerge-auto "smerge-mode" "\ +(autoload 'smerge-start-session "smerge-mode" "\ Turn on `smerge-mode' and move point to first conflict marker. If no conflict maker is found, turn off `smerge-mode'. @@ -29622,7 +29622,7 @@ If FILE-NAME is non-nil, save the result to FILE-NAME. ;;;;;; vc-directory vc-merge vc-insert-headers vc-revision-other-window ;;;;;; vc-diff vc-version-diff vc-register vc-next-action vc-do-command ;;;;;; edit-vc-file with-vc-file vc-before-checkin-hook vc-checkin-hook -;;;;;; vc-checkout-hook) "vc" "vc.el" (18317 26672)) +;;;;;; vc-checkout-hook) "vc" "vc.el" (18317 49783)) ;;; Generated autoloads from vc.el (defvar vc-checkout-hook nil "\ @@ -29913,7 +29913,7 @@ mode-specific menu. `vc-annotate-color-map' and ;;;*** -;;;### (autoloads nil "vc-arch" "vc-arch.el" (18315 16863)) +;;;### (autoloads nil "vc-arch" "vc-arch.el" (18317 49783)) ;;; Generated autoloads from vc-arch.el (defun vc-arch-registered (file) (if (vc-find-root file "{arch}/=tagging-method") @@ -30025,7 +30025,7 @@ find any project directory." (let ((project-dir (getenv "PROJECTDIR")) dirs dir) ;;;*** -;;;### (autoloads nil "vc-svn" "vc-svn.el" (18315 16863)) +;;;### (autoloads nil "vc-svn" "vc-svn.el" (18317 49783)) ;;; Generated autoloads from vc-svn.el (defun vc-svn-registered (f) (let ((admin-dir (cond ((and (eq system-type 'windows-nt) @@ -31957,7 +31957,7 @@ Zone out, completely. ;;;;;; "url/url-nfs.el" "url/url-proxy.el" "url/url-vars.el" "url/vc-dav.el" ;;;;;; "vc-hooks.el" "vcursor.el" "version.el" "vms-patch.el" "vmsproc.el" ;;;;;; "vt-control.el" "vt100-led.el" "w32-fns.el" "w32-vars.el" -;;;;;; "widget.el" "window.el" "x-dnd.el") (18317 32734 645076)) +;;;;;; "widget.el" "window.el" "x-dnd.el") (18317 50564 111773)) ;;;*** From 145fe412ba3d33d81462ce39bb2e757b0dea93d7 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Wed, 16 Jan 2008 15:55:15 +0000 Subject: [PATCH 143/439] (describe-mode): Pass the right buffer to format-mode-line. --- lisp/ChangeLog | 12 ++++++++---- lisp/help.el | 2 +- 2 files changed, 9 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b1d4e26dfdb..334412d7d0f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-16 Stefan Monnier + + * help.el (describe-mode): Pass the right buffer to format-mode-line. + 2008-01-16 Glenn Morris * comint.el (comint-regexp-arg): Fix no-input case. @@ -14,8 +18,8 @@ 2008-01-16 Ulf Jasper * calendar/icalendar.el (icalendar-version): Increase to 0.16. - (icalendar-export-file, icalendar-import-file): Restore - significant trailing whitespace in `interactive' prompts. + (icalendar-export-file, icalendar-import-file): + Restore significant trailing whitespace in `interactive' prompts. 2008-01-16 Tom Tromey @@ -24,8 +28,8 @@ (icalendar--find-time-zone): New functions. (icalendar--decode-isodatetime): Add `zone' argument, passed to `decode-time'. Doc fix. - (icalendar--convert-ical-to-diary): Compute zone-map. Pass - timezone to icalendar--decode-isodatetime. + (icalendar--convert-ical-to-diary): Compute zone-map. + Pass timezone to icalendar--decode-isodatetime. 2008-01-16 Alan Mackenzie diff --git a/lisp/help.el b/lisp/help.el index 68d3e33fe0a..24f1e74d71a 100644 --- a/lisp/help.el +++ b/lisp/help.el @@ -860,7 +860,7 @@ whose documentation describes the minor mode." (let ((mode mode-name)) (with-current-buffer standard-output (let ((start (point))) - (insert (format-mode-line mode)) + (insert (format-mode-line mode nil nil buffer)) (add-text-properties start (point) '(face bold))))) (princ " mode:\n") (princ (documentation major-mode)))))) From b5c499629bb142f926cab4519194966baaecf911 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Wed, 16 Jan 2008 15:57:42 +0000 Subject: [PATCH 144/439] (ibuffer-auto-update-changed, ibuffer-auto-mode): Use derived-mode-p. (ibuffer-mark-by-mode-regexp): Pass the buffer to format-mode-line. --- lisp/ChangeLog | 4 ++++ lisp/ibuf-ext.el | 8 ++++---- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 334412d7d0f..19155ed1b6b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,9 @@ 2008-01-16 Stefan Monnier + * ibuf-ext.el (ibuffer-auto-update-changed, ibuffer-auto-mode): + Use derived-mode-p. + (ibuffer-mark-by-mode-regexp): Pass the buffer to format-mode-line. + * help.el (describe-mode): Pass the right buffer to format-mode-line. 2008-01-16 Glenn Morris diff --git a/lisp/ibuf-ext.el b/lisp/ibuf-ext.el index 0b2586d0fce..aafc93af990 100644 --- a/lisp/ibuf-ext.el +++ b/lisp/ibuf-ext.el @@ -228,7 +228,7 @@ Currently, this only applies to `ibuffer-saved-filters' and (ignore-errors (with-current-buffer buf (when (and ibuffer-auto-mode - (eq major-mode 'ibuffer-mode)) + (derived-mode-p 'ibuffer-mode)) (ibuffer-update nil t))))))) ;;;###autoload @@ -236,7 +236,7 @@ Currently, this only applies to `ibuffer-saved-filters' and "Toggle use of Ibuffer's auto-update facility. With numeric ARG, enable auto-update if and only if ARG is positive." (interactive) - (unless (eq major-mode 'ibuffer-mode) + (unless (derived-mode-p 'ibuffer-mode) (error "This buffer is not in Ibuffer mode")) (set (make-local-variable 'ibuffer-auto-mode) (if arg @@ -1386,7 +1386,7 @@ You can then feed the file name(s) to other commands with \\[yank]." (ibuffer-mark-on-buffer #'(lambda (buf) (with-current-buffer buf - (string-match regexp (format-mode-line mode-name)))))) + (string-match regexp (format-mode-line mode-name nil nil buf)))))) ;;;###autoload (defun ibuffer-mark-by-file-name-regexp (regexp) @@ -1539,5 +1539,5 @@ defaults to one." (provide 'ibuf-ext) -;;; arch-tag: 9af21953-deda-4c30-b76d-f81d9128e76d +;; arch-tag: 9af21953-deda-4c30-b76d-f81d9128e76d ;;; ibuf-ext.el ends here From 23eabff6db4307e484b26be2e94d0721544e9f2f Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Wed, 16 Jan 2008 16:11:09 +0000 Subject: [PATCH 145/439] (mode): Pass the buffer to format-mode-line. (ibuffer-update-mode-name): Remove. (ibuffer-redisplay, ibuffer-update, ibuffer-mode): Don't call it. (ibuffer-mode): Use mode-line-process instead. --- lisp/ChangeLog | 5 +++++ lisp/ibuffer.el | 52 +++++++++++++++++++++---------------------------- 2 files changed, 27 insertions(+), 30 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 19155ed1b6b..6db94872819 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,10 @@ 2008-01-16 Stefan Monnier + * ibuffer.el (mode): Pass the buffer to format-mode-line. + (ibuffer-update-mode-name): Remove. + (ibuffer-redisplay, ibuffer-update, ibuffer-mode): Don't call it. + (ibuffer-mode): Use mode-line-process instead. + * ibuf-ext.el (ibuffer-auto-update-changed, ibuffer-auto-mode): Use derived-mode-p. (ibuffer-mark-by-mode-regexp): Pass the buffer to format-mode-line. diff --git a/lisp/ibuffer.el b/lisp/ibuffer.el index 9e6918e8020..0a26311541c 100644 --- a/lisp/ibuffer.el +++ b/lisp/ibuffer.el @@ -1722,7 +1722,7 @@ If point is on a group name, this function operates on that group." ('mouse-face 'highlight 'keymap ibuffer-mode-name-map 'help-echo "mouse-2: filter by this mode")) - (format-mode-line mode-name)) + (format-mode-line mode-name nil nil (current-buffer))) (define-ibuffer-column process (:summarizer @@ -2097,29 +2097,6 @@ the value of point at the beginning of the line for that buffer." (point)) `(ibuffer-summary t))))) -(defun ibuffer-update-mode-name () - (setq mode-name (format "Ibuffer by %s" (if ibuffer-sorting-mode - ibuffer-sorting-mode - "view time"))) - (when ibuffer-sorting-reversep - (setq mode-name (concat mode-name " [rev]"))) - (when (and (featurep 'ibuf-ext) - ibuffer-auto-mode) - (setq mode-name (concat mode-name " (Auto)"))) - (let ((result "")) - (when (featurep 'ibuf-ext) - (dolist (qualifier ibuffer-filtering-qualifiers) - (setq result - (concat result (ibuffer-format-qualifier qualifier)))) - (if ibuffer-use-header-line - (setq header-line-format - (when ibuffer-filtering-qualifiers - (replace-regexp-in-string "%" "%%" - (concat mode-name result)))) - (progn - (setq mode-name (concat mode-name result)) - (when (boundp 'header-line-format) - (setq header-line-format nil))))))) (defun ibuffer-redisplay (&optional silent) "Redisplay the current list of buffers. @@ -2137,7 +2114,6 @@ If optional arg SILENT is non-nil, do not display progress messages." (message "No buffers! (note: filtering in effect)") (error "No buffers!"))) (ibuffer-redisplay-engine blist t) - (ibuffer-update-mode-name) (unless silent (message "Redisplaying current buffer list...done")) (ibuffer-forward-line 0))) @@ -2174,7 +2150,6 @@ If optional arg SILENT is non-nil, do not display progress messages." (unless silent (message "Updating buffer list...")) (ibuffer-redisplay-engine blist arg) - (ibuffer-update-mode-name) (unless silent (message "Updating buffer list...done"))) (if (eq ibuffer-shrink-to-minimum-size 'onewindow) @@ -2540,6 +2515,25 @@ will be inserted before the group at point." (use-local-map ibuffer-mode-map) (setq major-mode 'ibuffer-mode) (setq mode-name "Ibuffer") + ;; Include state info next to the mode name. + (set (make-local-variable mode-line-process) + '((ibuffer-sorting-mode (:eval (symbol-name ibuffer-sorting-mode)) + "view time") + (ibuffer-sorting-reversep " [rev]") + (ibuffer-auto-mode " (Auto)") + ;; Only list the filters if they're not already in the header-line. + (header-line-format + "" + (:eval (if (functionp 'ibuffer-format-qualifier) + (mapconcat 'ibuffer-format-qualifier + ibuffer-filtering-qualifiers "")))))) + (setq header-line-format + (if ibuffer-use-header-line + ;; Display the part that won't be in the mode-line. + (mapcar (lambda (elem) (if (eq (car-safe elem) 'header-line-format) + (nth 2 elem) elem)) + mode-line-process))) + (setq buffer-read-only t) (buffer-disable-undo) (setq truncate-lines ibuffer-truncate-lines) @@ -2578,9 +2572,7 @@ will be inserted before the group at point." (when ibuffer-default-directory (setq default-directory ibuffer-default-directory)) (add-hook 'change-major-mode-hook 'font-lock-defontify nil t) - (run-mode-hooks 'ibuffer-mode-hook) - ;; called after mode hooks to allow the user to add filters - (ibuffer-update-mode-name)) + (run-mode-hooks 'ibuffer-mode-hook)) (provide 'ibuffer) @@ -2590,5 +2582,5 @@ will be inserted before the group at point." ;; coding: iso-8859-1 ;; End: -;;; arch-tag: 72581688-0603-4954-b8cf-837c700f62e8 +;; arch-tag: 72581688-0603-4954-b8cf-837c700f62e8 ;;; ibuffer.el ends here From d2bde04f6ac6272a14bf453e914c867b9ed0a53d Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 16 Jan 2008 16:15:56 +0000 Subject: [PATCH 146/439] Fix typos in comments. --- lisp/progmodes/ada-mode.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/progmodes/ada-mode.el b/lisp/progmodes/ada-mode.el index d8f4ffffea5..e674f68c843 100644 --- a/lisp/progmodes/ada-mode.el +++ b/lisp/progmodes/ada-mode.el @@ -4957,11 +4957,11 @@ The paragraph is indented on the first line." ;; cursor at the correct position. ;; Standard Ada does not force any relation between unit names and file names, ;; so some of these functions can only be a good approximation. However, they -;; are also overriden in `ada-xref'.el when we know that the user is using +;; are also overridden in `ada-xref'.el when we know that the user is using ;; GNAT. ;; --------------------------------------------------- -;; Overriden when we work with GNAT, to use gnatkrunch +;; Overridden when we work with GNAT, to use gnatkrunch (defun ada-make-filename-from-adaname (adaname) "Determine the filename in which ADANAME is found. This matches the GNAT default naming convention, except for From c7972fb159dbe7ea591132e04b17f346f0eb71e1 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Wed, 16 Jan 2008 16:17:00 +0000 Subject: [PATCH 147/439] (rng-nxml-mode-init): Don't overwrite mode-line-process. --- lisp/ChangeLog | 3 +++ lisp/nxml/rng-nxml.el | 4 ++-- 2 files changed, 5 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6db94872819..73bfeb84b24 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2008-01-16 Stefan Monnier + * nxml/rng-nxml.el (rng-nxml-mode-init): + Don't overwrite mode-line-process. + * ibuffer.el (mode): Pass the buffer to format-mode-line. (ibuffer-update-mode-name): Remove. (ibuffer-redisplay, ibuffer-update, ibuffer-mode): Don't call it. diff --git a/lisp/nxml/rng-nxml.el b/lisp/nxml/rng-nxml.el index a854263752d..ffe66d98be8 100644 --- a/lisp/nxml/rng-nxml.el +++ b/lisp/nxml/rng-nxml.el @@ -102,8 +102,8 @@ Validation will be enabled if `rng-nxml-auto-validate-flag' is non-nil." (easy-menu-define rng-nxml-menu nxml-mode-map "Menu for nxml-mode used with rng-validate-mode." rng-nxml-easy-menu) - (setq mode-line-process - '(rng-validate-mode (:eval (rng-compute-mode-line-string)))) + (add-to-list 'mode-line-process + '(rng-validate-mode (:eval (rng-compute-mode-line-string)))) (cond (rng-nxml-auto-validate-flag (rng-validate-mode 1) (add-hook 'nxml-completion-hook 'rng-complete nil t) From d7cd2d8b4eb0e0b0e2bbe77d2fe48d4a0c353055 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 16 Jan 2008 16:17:19 +0000 Subject: [PATCH 148/439] (display-mm-height, display-mm-width): Fix typos in docstrings. --- lisp/frame.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/frame.el b/lisp/frame.el index 56f7cbbe937..6b3ced3f986 100644 --- a/lisp/frame.el +++ b/lisp/frame.el @@ -1099,7 +1099,7 @@ displays not explicitely specified." (defun display-mm-height (&optional display) "Return the height of DISPLAY's screen in millimeters. -System values can be overriden by `display-mm-dimensions-alist'. +System values can be overridden by `display-mm-dimensions-alist'. If the information is unavailable, value is nil." (and (memq (framep-on-display display) '(x w32 mac)) (or (cddr (assoc (or display (frame-parameter nil 'display)) @@ -1109,7 +1109,7 @@ If the information is unavailable, value is nil." (defun display-mm-width (&optional display) "Return the width of DISPLAY's screen in millimeters. -System values can be overriden by `display-mm-dimensions-alist'. +System values can be overridden by `display-mm-dimensions-alist'. If the information is unavailable, value is nil." (and (memq (framep-on-display display) '(x w32 mac)) (or (cadr (assoc (or display (frame-parameter nil 'display)) From 7d7d1bb69d0d5d2d1df13947a66be1b17ee120bf Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Wed, 16 Jan 2008 16:17:53 +0000 Subject: [PATCH 149/439] (nxml-mode): Use mode-line-process to indicate the use of degraded mode. (nxml-degrade): Don't change mode-name. --- lisp/ChangeLog | 4 ++++ lisp/nxml/nxml-mode.el | 4 ++-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 73bfeb84b24..d426c72a4b7 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,9 @@ 2008-01-16 Stefan Monnier + * nxml/nxml-mode.el (nxml-mode): Use mode-line-process to indicate + the use of degraded mode. + (nxml-degrade): Don't change mode-name. + * nxml/rng-nxml.el (rng-nxml-mode-init): Don't overwrite mode-line-process. diff --git a/lisp/nxml/nxml-mode.el b/lisp/nxml/nxml-mode.el index aa6ac078400..11fadedd531 100644 --- a/lisp/nxml/nxml-mode.el +++ b/lisp/nxml/nxml-mode.el @@ -510,6 +510,7 @@ Many aspects this mode can be customized using (kill-all-local-variables) (setq major-mode 'nxml-mode) (setq mode-name "nXML") + (set (make-local-variable 'mode-line-process) '((nxml-degraded "/degraded"))) ;; We'll determine the fill prefix ourselves (make-local-variable 'adaptive-fill-mode) (setq adaptive-fill-mode nil) @@ -573,8 +574,7 @@ Many aspects this mode can be customized using (nxml-with-unmodifying-text-property-changes (nxml-clear-face (point-min) (point-max)) (nxml-set-fontified (point-min) (point-max)) - (nxml-clear-inside (point-min) (point-max))) - (setq mode-name "nXML/degraded")))) + (nxml-clear-inside (point-min) (point-max)))))) ;;; Change management From 6b588eb77e2c53e7045ac9be4d1864563f11674d Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 16 Jan 2008 16:18:32 +0000 Subject: [PATCH 150/439] (whitespace-check-leading-whitespace, whitespace-check-trailing-whitespace, whitespace-check-spacetab-whitespace, whitespace-check-indent-whitespace, whitespace-check-ateol-whitespace): Fix typos in docstrings. --- lisp/whitespace.el | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/lisp/whitespace.el b/lisp/whitespace.el index d9aad2a2eea..a250f24ddaa 100644 --- a/lisp/whitespace.el +++ b/lisp/whitespace.el @@ -171,21 +171,21 @@ don't define it." (defcustom whitespace-check-leading-whitespace t "Flag to check leading whitespace. This is the global for the system. -It can be overriden by setting a buffer local variable +It can be overridden by setting a buffer local variable `whitespace-check-buffer-leading'." :type 'boolean :group 'whitespace) (defcustom whitespace-check-trailing-whitespace t "Flag to check trailing whitespace. This is the global for the system. -It can be overriden by setting a buffer local variable +It can be overridden by setting a buffer local variable `whitespace-check-buffer-trailing'." :type 'boolean :group 'whitespace) (defcustom whitespace-check-spacetab-whitespace t "Flag to check space followed by a TAB. This is the global for the system. -It can be overriden by setting a buffer local variable +It can be overridden by setting a buffer local variable `whitespace-check-buffer-spacetab'." :type 'boolean :group 'whitespace) @@ -197,7 +197,7 @@ It can be overriden by setting a buffer local variable (defcustom whitespace-check-indent-whitespace indent-tabs-mode "Flag to check indentation whitespace. This is the global for the system. -It can be overriden by setting a buffer local variable +It can be overridden by setting a buffer local variable `whitespace-check-buffer-indent'." :type 'boolean :group 'whitespace) @@ -210,7 +210,7 @@ The default value ignores leading TABs." (defcustom whitespace-check-ateol-whitespace t "Flag to check end-of-line whitespace. This is the global for the system. -It can be overriden by setting a buffer local variable +It can be overridden by setting a buffer local variable `whitespace-check-buffer-ateol'." :type 'boolean :group 'whitespace) From a8b6a3a6a0845515f99d5ac1a577c9f85316d82a Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 16 Jan 2008 16:19:01 +0000 Subject: [PATCH 151/439] (ada-convert-file-name): Fix typo in docstring. --- lisp/progmodes/ada-xref.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/progmodes/ada-xref.el b/lisp/progmodes/ada-xref.el index 77d4213a6db..2740d1cec14 100644 --- a/lisp/progmodes/ada-xref.el +++ b/lisp/progmodes/ada-xref.el @@ -617,7 +617,7 @@ If NO-USER-QUESTION, don't prompt user for file. Call (defun ada-convert-file-name (name) "Convert from NAME to a name that can be used by the compilation commands. -This is overriden on VMS to convert from VMS filenames to Unix filenames." +This is overridden on VMS to convert from VMS filenames to Unix filenames." name) ;; FIXME: use convert-standard-filename instead From 656d4706ab9f836b5e24f7da29e420491a7976de Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Wed, 16 Jan 2008 16:21:08 +0000 Subject: [PATCH 152/439] (server-process-filter): Replace lineno and columnnno which defaulted to 1&0 with filepos which defaults to nil. (server-goto-line-column): Don't move if filepos is nil. (server-visit-files): Slight restructure to consolidate two calls to server-goto-line-column into just one. --- lisp/ChangeLog | 7 +++++ lisp/server.el | 71 ++++++++++++++++++++++++-------------------------- 2 files changed, 41 insertions(+), 37 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index d426c72a4b7..4e049abdc67 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,12 @@ 2008-01-16 Stefan Monnier + * server.el (server-process-filter): Replace lineno and columnnno + which defaulted to 1&0 with filepos which defaults to nil. + (server-goto-line-column): Only receive the filepos. + Only move if filepos is non-nil. + (server-visit-files): Slight restructure to consolidate two calls to + server-goto-line-column into just one. + * nxml/nxml-mode.el (nxml-mode): Use mode-line-process to indicate the use of degraded mode. (nxml-degrade): Don't change mode-name. diff --git a/lisp/server.el b/lisp/server.el index 63245135347..8e14ffa3826 100644 --- a/lisp/server.el +++ b/lisp/server.el @@ -805,8 +805,7 @@ The following commands are accepted by the client: (tty-name nil) ;nil, `window-system', or the tty name. tty-type ;string. (files nil) - (lineno 1) - (columnno 0) + (filepos nil) command-line-args-left arg) ;; Remove this line from STRING. @@ -876,9 +875,9 @@ The following commands are accepted by the client: (string-match "\\+\\([0-9]+\\)\\(?::\\([0-9]+\\)\\)?" (car command-line-args-left))) (setq arg (pop command-line-args-left)) - (setq lineno (string-to-number (match-string 1 arg)) - columnno (if (null (match-end 2)) 0 - (string-to-number (match-string 2 arg))))) + (setq filepos + (cons (string-to-number (match-string 1 arg)) + (string-to-number (or (match-string 2 arg) ""))))) ;; -file FILENAME: Load the given file. ((and (equal "-file" arg) @@ -887,11 +886,10 @@ The following commands are accepted by the client: (if coding-system (setq file (decode-coding-string file coding-system))) (setq file (command-line-normalize-file-name file)) - (push (list file lineno columnno) files) - (server-log (format "New file: %s (%d:%d)" - file lineno columnno) proc)) - (setq lineno 1 - columnno 0)) + (push (cons file filepos) files) + (server-log (format "New file: %s %s" + file (or filepos "")) proc)) + (setq filepos nil)) ;; -eval EXPR: Evaluate a Lisp expression. ((and (equal "-eval" arg) @@ -901,8 +899,7 @@ The following commands are accepted by the client: (setq expr (decode-coding-string expr coding-system))) (push (lambda () (server-eval-and-print expr proc)) commands) - (setq lineno 1 - columnno 0))) + (setq filepos nil))) ;; -env NAME=VALUE: An environment variable. ((and (equal "-env" arg) command-line-args-left) @@ -991,18 +988,19 @@ The following commands are accepted by the client: (server-log (error-message-string err) proc) (delete-process proc))) -(defun server-goto-line-column (file-line-col) - "Move point to the position indicated in FILE-LINE-COL. -FILE-LINE-COL should be a three-element list as described in -`server-visit-files'." - (goto-line (nth 1 file-line-col)) - (let ((column-number (nth 2 file-line-col))) - (when (> column-number 0) - (move-to-column (1- column-number))))) +(defun server-goto-line-column (line-col) + "Move point to the position indicated in LINE-COL. +LINE-COL should be a pair (LINE . COL)." + (when line-col + (goto-line (car line-col)) + (let ((column-number (cdr line-col))) + (when (> column-number 0) + (move-to-column (1- column-number)))))) (defun server-visit-files (files proc &optional nowait) "Find FILES and return a list of buffers created. -FILES is an alist whose elements are (FILENAME LINENUMBER COLUMNNUMBER). +FILES is an alist whose elements are (FILENAME . FILEPOS) +where FILEPOS can be nil or a pair (LINENUMBER . COLUMNNUMBER). PROC is the client that requested this operation. NOWAIT non-nil means this client is not waiting for the results, so don't mark these buffers specially, just visit them normally." @@ -1021,22 +1019,21 @@ so don't mark these buffers specially, just visit them normally." (filen (car file)) (obuf (get-file-buffer filen))) (add-to-history 'file-name-history filen) - (if (and obuf (set-buffer obuf)) - (progn - (cond ((file-exists-p filen) - (when (not (verify-visited-file-modtime obuf)) - (revert-buffer t nil))) - (t - (when (y-or-n-p - (concat "File no longer exists: " filen - ", write buffer to file? ")) - (write-file filen)))) - (unless server-buffer-clients - (setq server-existing-buffer t)) - (server-goto-line-column file)) - (set-buffer (find-file-noselect filen)) - (server-goto-line-column file) - (run-hooks 'server-visit-hook))) + (if (null obuf) + (set-buffer (find-file-noselect filen)) + (set-buffer obuf) + (cond ((file-exists-p filen) + (when (not (verify-visited-file-modtime obuf)) + (revert-buffer t nil))) + (t + (when (y-or-n-p + (concat "File no longer exists: " filen + ", write buffer to file? ")) + (write-file filen)))) + (unless server-buffer-clients + (setq server-existing-buffer t))) + (server-goto-line-column (cdr file)) + (run-hooks 'server-visit-hook)) (unless nowait ;; When the buffer is killed, inform the clients. (add-hook 'kill-buffer-hook 'server-kill-buffer nil t) From 5ae87ed4147af1b70f5a1b2b8ab28a054d8d1048 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Wed, 16 Jan 2008 16:22:29 +0000 Subject: [PATCH 153/439] (custom-reset-standard-variables-list) (custom-reset-standard-faces-list): New variables. (custom-reset-standard-save-and-update): New function. (Custom-save): Apply custom-mark-to-save before and custom-state-set-and-redraw after saving options. (Custom-reset-standard): Apply custom-mark-to-reset-standard to options and call custom-reset-standard-save-and-update. (custom-variable, custom-face, custom-group): Provide new entries for custom-mark-to-save, custom-mark-to-reset-standard, and custom-state-set-and-redraw. (custom-variable-mark-to-save) (custom-variable-state-set-and-redraw) (custom-variable-mark-to-reset-standard) (custom-face-mark-to-save, custom-face-state-set-and-redraw) (custom-face-mark-to-reset-standard) (custom-group-mark-to-save, custom-group-state-set-and-redraw) (custom-group-mark-to-reset-standard): New functions. (custom-variable-save): Move save, state-set, and redraw functionality to custom-variable-mark-to-save. (custom-face-save): Move save, state-set, and redraw functionality to custom-face-mark-to-save. (custom-group-save): Move save, state-set, and redraw functionality to custom-group-mark-to-save. (custom-variable-reset-standard, custom-face-reset-standard) (custom-group-reset-standard): Move save, state-set, and redraw functionality to custom-reset-standard-save-and-update. (custom-buffer-create-internal): Fix text in verbose help. (custom-face-value-create): Indent doc-strings of faces like those of variables. --- lisp/cus-edit.el | 265 +++++++++++++++++++++++++++++++++++------------ 1 file changed, 196 insertions(+), 69 deletions(-) diff --git a/lisp/cus-edit.el b/lisp/cus-edit.el index c1071f3b3ef..7e014b4f7bd 100644 --- a/lisp/cus-edit.el +++ b/lisp/cus-edit.el @@ -826,16 +826,19 @@ and `yes-or-no-p' otherwise." (defun Custom-save (&rest ignore) "Set all edited settings, then save all settings that have been set. -If a setting was edited and set before, this saves it. -If a setting was merely edited before, this sets it then saves it." +If a setting was edited and set before, this saves it. If a +setting was merely edited before, this sets it then saves it." (interactive) - (if (custom-command-apply - (lambda (child) - (when (memq (widget-get child :custom-state) - '(modified set changed rogue)) - (widget-apply child :custom-save))) - "Save all settings in this buffer? " t) - (custom-save-all))) + (when (custom-command-apply + (lambda (child) + (when (memq (widget-get child :custom-state) + '(modified set changed rogue)) + (widget-apply child :custom-mark-to-save))) + "Save all settings in this buffer? " t) + ;; Save changes to buffer and redraw. + (custom-save-all) + (dolist (child custom-options) + (widget-apply child :custom-state-set-and-redraw)))) (defun custom-reset (widget &optional event) "Select item from reset menu." @@ -865,20 +868,67 @@ This also shows the saved values in the buffer." (widget-apply widget :custom-reset-saved))) "Reset all settings (current values and buffer text) to saved values? ")) +;; The next two variables are bound to '(t) by `Custom-reset-standard' +;; and `custom-group-reset-standard'. If these variables are nil, both +;; `custom-variable-reset-standard' and `custom-face-reset-standard' +;; save, reset and redraw the handled widget immediately. Otherwise, +;; they add the widget to the corresponding list and leave it to +;; `custom-reset-standard-save-and-update' to save, reset and redraw it. +(defvar custom-reset-standard-variables-list nil) +(defvar custom-reset-standard-faces-list nil) + +;; The next function was excerpted from `custom-variable-reset-standard' +;; and `custom-face-reset-standard' and is used to avoid calling +;; `custom-save-all' repeatedly (and thus saving settings to file one by +;; one) when erasing all customizations. +(defun custom-reset-standard-save-and-update () + "Save settings and redraw after erasing customizations." + (when (or (and custom-reset-standard-variables-list + (not (eq custom-reset-standard-variables-list '(t)))) + (and custom-reset-standard-faces-list + (not (eq custom-reset-standard-faces-list '(t))))) + ;; Save settings to file. + (custom-save-all) + ;; Set state of and redraw variables. + (dolist (widget custom-reset-standard-variables-list) + (unless (eq widget t) + (widget-put widget :custom-state 'unknown) + (custom-redraw widget))) + ;; Set state of and redraw faces. + (dolist (widget custom-reset-standard-faces-list) + (unless (eq widget t) + (let* ((symbol (widget-value widget)) + (child (car (widget-get widget :children))) + (value (get symbol 'face-defface-spec)) + (comment-widget (widget-get widget :comment-widget))) + (put symbol 'face-comment nil) + (widget-value-set child + (custom-pre-filter-face-spec + (list (list t (custom-face-attributes-get + symbol nil))))) + ;; This call manages the comment visibility + (widget-value-set comment-widget "") + (custom-face-state-set widget) + (custom-redraw-magic widget)))))) + (defun Custom-reset-standard (&rest ignore) - "Erase all customization (either current or saved) for the group members. + "Erase all customizations (either current or saved) in current buffer. The immediate result is to restore them to their standard values. This operation eliminates any saved values for the group members, making them as if they had never been customized at all." (interactive) - (custom-command-apply - (lambda (widget) - (and (or (null (widget-get widget :custom-standard-value)) - (widget-apply widget :custom-standard-value)) - (memq (widget-get widget :custom-state) - '(modified set changed saved rogue)) - (widget-apply widget :custom-reset-standard))) - "Erase all customizations for settings in this buffer? " t)) + ;; Bind these temporarily. + (let ((custom-reset-standard-variables-list '(t)) + (custom-reset-standard-faces-list '(t))) + (custom-command-apply + (lambda (widget) + (and (or (null (widget-get widget :custom-standard-value)) + (widget-apply widget :custom-standard-value)) + (memq (widget-get widget :custom-state) + '(modified set changed saved rogue)) + (widget-apply widget :custom-mark-to-reset-standard))) + "Erase all customizations for settings in this buffer? " t) + (custom-reset-standard-save-and-update))) ;;; The Customize Commands @@ -1535,7 +1585,7 @@ Otherwise use brackets." (widget-insert "Editing a setting changes only the text in this buffer." (if init-file " -To set apply your changes, use the Save or Set buttons. +To apply your changes, use the Save or Set buttons. Saving a change normally works by editing your init file." " Currently, these settings cannot be saved for future Emacs sessions, @@ -2441,11 +2491,13 @@ However, setting it through Custom sets the default value.") :value-create 'custom-variable-value-create :action 'custom-variable-action :custom-set 'custom-variable-set - :custom-save 'custom-variable-save + :custom-mark-to-save 'custom-variable-mark-to-save :custom-reset-current 'custom-redraw :custom-reset-saved 'custom-variable-reset-saved :custom-reset-standard 'custom-variable-reset-standard - :custom-standard-value 'custom-variable-standard-value) + :custom-mark-to-reset-standard 'custom-variable-mark-to-reset-standard + :custom-standard-value 'custom-variable-standard-value + :custom-state-set-and-redraw 'custom-variable-state-set-and-redraw) (defun custom-variable-type (symbol) "Return a widget suitable for editing the value of SYMBOL. @@ -2807,8 +2859,8 @@ Optional EVENT is the location for the menu." (custom-variable-state-set widget) (custom-redraw-magic widget))) -(defun custom-variable-save (widget) - "Set and save the value for the variable being edited by WIDGET." +(defun custom-variable-mark-to-save (widget) + "Set value and mark for saving the variable edited by WIDGET." (let* ((form (widget-get widget :custom-form)) (state (widget-get widget :custom-state)) (child (car (widget-get widget :children))) @@ -2846,10 +2898,18 @@ Optional EVENT is the location for the menu." (put symbol 'variable-comment comment) (put symbol 'saved-variable-comment comment))) (put symbol 'customized-value nil) - (put symbol 'customized-variable-comment nil) - (custom-save-all) - (custom-variable-state-set widget) - (custom-redraw-magic widget))) + (put symbol 'customized-variable-comment nil))) + +(defsubst custom-variable-state-set-and-redraw (widget) + "Set state of variable widget WIDGET and redraw with current settings." + (custom-variable-state-set widget) + (custom-redraw-magic widget)) + +(defun custom-variable-save (widget) + "Save value of variable edited by widget WIDGET." + (custom-variable-mark-to-save widget) + (custom-save-all) + (custom-variable-state-set-and-redraw widget)) (defun custom-variable-reset-saved (widget) "Restore the saved value for the variable being edited by WIDGET. @@ -2875,12 +2935,10 @@ becomes the backup value, so you can get it again." ;; This call will possibly make the comment invisible (custom-redraw widget))) -(defun custom-variable-reset-standard (widget) - "Restore the standard setting for the variable being edited by WIDGET. -This operation eliminates any saved setting for the variable, -restoring it to the state of a variable that has never been customized. -The value that was current before this operation -becomes the backup value, so you can get it again." +(defun custom-variable-mark-to-reset-standard (widget) + "Mark to restore standard setting for the variable edited by widget WIDGET. +If `custom-reset-standard-variables-list' is nil, save, reset and +redraw the widget immediately." (let* ((symbol (widget-value widget))) (if (get symbol 'standard-value) (custom-variable-backup-value widget) @@ -2890,13 +2948,32 @@ becomes the backup value, so you can get it again." (put symbol 'customized-variable-comment nil) (custom-push-theme 'theme-value symbol 'user 'reset) (custom-theme-recalc-variable symbol) - (when (or (get symbol 'saved-value) (get symbol 'saved-variable-comment)) - (put symbol 'saved-value nil) - (put symbol 'saved-variable-comment nil) - (custom-save-all)) - (widget-put widget :custom-state 'unknown) - ;; This call will possibly make the comment invisible - (custom-redraw widget))) + (if (and custom-reset-standard-variables-list + (or (get symbol 'saved-value) (get symbol 'saved-variable-comment))) + (progn + (put symbol 'saved-value nil) + (put symbol 'saved-variable-comment nil) + ;; Append this to `custom-reset-standard-variables-list' to + ;; have `custom-reset-standard-save-and-update' save setting + ;; to the file, update the widget's state, and redraw it. + (setq custom-reset-standard-variables-list + (cons widget custom-reset-standard-variables-list))) + (when (or (get symbol 'saved-value) (get symbol 'saved-variable-comment)) + (put symbol 'saved-value nil) + (put symbol 'saved-variable-comment nil) + (custom-save-all)) + (widget-put widget :custom-state 'unknown) + ;; This call will possibly make the comment invisible + (custom-redraw widget)))) + +(defun custom-variable-reset-standard (widget) + "Restore standard setting for the variable edited by WIDGET. +This operation eliminates any saved setting for the variable, +restoring it to the state of a variable that has never been customized. +The value that was current before this operation +becomes the backup value, so you can get it again." + (let (custom-reset-standard-variables-list) + (custom-variable-mark-to-reset-standard widget))) (defun custom-variable-backup-value (widget) "Back up the current value for WIDGET's variable. @@ -3172,11 +3249,13 @@ Only match frames that support the specified face attributes.") :custom-category 'face :custom-form nil ; defaults to value of `custom-face-default-form' :custom-set 'custom-face-set - :custom-save 'custom-face-save + :custom-mark-to-save 'custom-face-mark-to-save :custom-reset-current 'custom-redraw :custom-reset-saved 'custom-face-reset-saved :custom-reset-standard 'custom-face-reset-standard + :custom-mark-to-reset-standard 'custom-face-mark-to-reset-standard :custom-standard-value 'custom-face-standard-value + :custom-state-set-and-redraw 'custom-face-state-set-and-redraw :custom-menu 'custom-face-menu-create) (define-widget 'custom-face-all 'editable-list @@ -3321,6 +3400,7 @@ SPEC must be a full face spec." ;; Update buttons. (widget-put widget :buttons buttons) ;; Insert documentation. + (widget-put widget :documentation-indent 3) (widget-add-documentation-string-button widget :visibility-widget 'custom-visibility) @@ -3510,8 +3590,8 @@ Optional EVENT is the location for the menu." (custom-face-state-set widget) (custom-redraw-magic widget))) -(defun custom-face-save (widget) - "Save in `.emacs' the face attributes in WIDGET." +(defun custom-face-mark-to-save (widget) + "Mark for saving the face edited by WIDGET." (let* ((symbol (widget-value widget)) (child (car (widget-get widget :children))) (value (custom-post-filter-face-spec (widget-value child))) @@ -3532,10 +3612,18 @@ Optional EVENT is the location for the menu." (put symbol 'customized-face nil) (put symbol 'face-comment comment) (put symbol 'customized-face-comment nil) - (put symbol 'saved-face-comment comment) - (custom-save-all) - (custom-face-state-set widget) - (custom-redraw-magic widget))) + (put symbol 'saved-face-comment comment))) + +(defsubst custom-face-state-set-and-redraw (widget) + "Set state of face widget WIDGET and redraw with current settings." + (custom-face-state-set widget) + (custom-redraw-magic widget)) + +(defun custom-face-save (widget) + "Save the face edited by WIDGET." + (custom-face-mark-to-save widget) + (custom-save-all) + (custom-face-state-set-and-redraw widget)) ;; For backward compatibility. (define-obsolete-function-alias 'custom-face-save-command 'custom-face-save @@ -3564,10 +3652,10 @@ Optional EVENT is the location for the menu." (defun custom-face-standard-value (widget) (get (widget-value widget) 'face-defface-spec)) -(defun custom-face-reset-standard (widget) - "Restore WIDGET to the face's standard attribute values. -This operation eliminates any saved attributes for the face, -restoring it to the state of a face that has never been customized." +(defun custom-face-mark-to-reset-standard (widget) + "Restore widget WIDGET to the face's standard attribute values. +If `custom-reset-standard-faces-list' is nil, save, reset and +redraw the widget immediately." (let* ((symbol (widget-value widget)) (child (car (widget-get widget :children))) (value (get symbol 'face-defface-spec)) @@ -3579,19 +3667,37 @@ restoring it to the state of a face that has never been customized." (custom-push-theme 'theme-face symbol 'user 'reset) (face-spec-set symbol value t) (custom-theme-recalc-face symbol) - (when (or (get symbol 'saved-face) (get symbol 'saved-face-comment)) - (put symbol 'saved-face nil) - (put symbol 'saved-face-comment nil) - (custom-save-all)) - (put symbol 'face-comment nil) - (widget-value-set child - (custom-pre-filter-face-spec - (list (list t (custom-face-attributes-get - symbol nil))))) - ;; This call manages the comment visibility - (widget-value-set comment-widget "") - (custom-face-state-set widget) - (custom-redraw-magic widget))) + (if (and custom-reset-standard-faces-list + (or (get symbol 'saved-face) (get symbol 'saved-face-comment))) + ;; Do this later. + (progn + (put symbol 'saved-face nil) + (put symbol 'saved-face-comment nil) + ;; Append this to `custom-reset-standard-faces-list' and have + ;; `custom-reset-standard-save-and-update' save setting to the + ;; file, update the widget's state, and redraw it. + (setq custom-reset-standard-faces-list + (cons widget custom-reset-standard-faces-list))) + (when (or (get symbol 'saved-face) (get symbol 'saved-face-comment)) + (put symbol 'saved-face nil) + (put symbol 'saved-face-comment nil) + (custom-save-all)) + (put symbol 'face-comment nil) + (widget-value-set child + (custom-pre-filter-face-spec + (list (list t (custom-face-attributes-get + symbol nil))))) + ;; This call manages the comment visibility + (widget-value-set comment-widget "") + (custom-face-state-set widget) + (custom-redraw-magic widget)))) + +(defun custom-face-reset-standard (widget) + "Restore WIDGET to the face's standard attribute values. +This operation eliminates any saved attributes for the face, +restoring it to the state of a face that has never been customized." + (let (custom-reset-standard-faces-list) + (custom-face-mark-to-reset-standard widget))) ;;; The `face' Widget. @@ -3736,10 +3842,12 @@ and so forth. The remaining group tags are shown with `custom-group-tag'." :action 'custom-group-action :custom-category 'group :custom-set 'custom-group-set - :custom-save 'custom-group-save + :custom-mark-to-save 'custom-group-mark-to-save :custom-reset-current 'custom-group-reset-current :custom-reset-saved 'custom-group-reset-saved :custom-reset-standard 'custom-group-reset-standard + :custom-mark-to-reset-standard 'custom-group-mark-to-reset-standard + :custom-state-set-and-redraw 'custom-group-state-set-and-redraw :custom-menu 'custom-group-menu-create) (defun custom-group-sample-face-get (widget) @@ -4034,11 +4142,23 @@ Optional EVENT is the location for the menu." (when (eq (widget-get child :custom-state) 'modified) (widget-apply child :custom-set)))) -(defun custom-group-save (widget) - "Save all modified group members." +(defun custom-group-mark-to-save (widget) + "Mark all modified group members for saving." (dolist (child (widget-get widget :children)) (when (memq (widget-get child :custom-state) '(modified set)) - (widget-apply child :custom-save)))) + (widget-apply child :custom-mark-to-save)))) + +(defsubst custom-group-state-set-and-redraw (widget) + "Set state of group widget WIDGET and redraw with current settings." + (dolist (child (widget-get widget :children)) + (when (memq (widget-get child :custom-state) '(modified set)) + (widget-apply child :custom-state-set-and-redraw)))) + +(defun custom-group-save (widget) + "Save all modified group members." + (custom-group-mark-to-save widget) + (custom-save-all) + (custom-group-state-set-and-redraw widget)) (defun custom-group-reset-current (widget) "Reset all modified group members." @@ -4054,10 +4174,17 @@ Optional EVENT is the location for the menu." (defun custom-group-reset-standard (widget) "Reset all modified, set, or saved group members." + (let ((custom-reset-standard-variables-list '(t)) + (custom-reset-standard-faces-list '(t))) + (custom-group-mark-to-reset-standard widget) + (custom-reset-standard-save-and-update))) + +(defun custom-group-mark-to-reset-standard (widget) + "Mark to reset all modified, set, or saved group members." (dolist (child (widget-get widget :children)) (when (memq (widget-get child :custom-state) '(modified set saved)) - (widget-apply child :custom-reset-standard)))) + (widget-apply child :custom-mark-to-reset-standard)))) (defun custom-group-state-update (widget) "Update magic." From 91b53ad5c8b78f8ab8494e3c5b600f29d2305e84 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Wed, 16 Jan 2008 16:23:00 +0000 Subject: [PATCH 154/439] (longlines-mode, longlines-show-region) (longlines-unshow-hard-newlines): Bind buffer-file-name and buffer-file-truename to nil while modifying buffer. --- lisp/longlines.el | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/lisp/longlines.el b/lisp/longlines.el index 932a70480a1..77176a5db24 100644 --- a/lisp/longlines.el +++ b/lisp/longlines.el @@ -136,7 +136,8 @@ are indicated with a symbol." (let ((buffer-undo-list t) (inhibit-read-only t) (after-change-functions nil) - (mod (buffer-modified-p))) + (mod (buffer-modified-p)) + buffer-file-name buffer-file-truename) ;; Turning off undo is OK since (spaces + newlines) is ;; conserved, except for a corner case in ;; longlines-wrap-lines that we'll never encounter from here @@ -176,7 +177,8 @@ are indicated with a symbol." (longlines-unshow-hard-newlines)) (let ((buffer-undo-list t) (after-change-functions nil) - (inhibit-read-only t)) + (inhibit-read-only t) + buffer-file-name buffer-file-truename) (if longlines-decoded (save-restriction (widen) @@ -220,7 +222,8 @@ With optional argument ARG, make the hard newlines invisible again." (mod (buffer-modified-p)) (buffer-undo-list t) (inhibit-read-only t) - (inhibit-modification-hooks t)) + (inhibit-modification-hooks t) + buffer-file-name buffer-file-truename) (while pos (put-text-property pos (1+ pos) 'display (copy-sequence longlines-show-effect)) @@ -235,7 +238,8 @@ With optional argument ARG, make the hard newlines invisible again." (mod (buffer-modified-p)) (buffer-undo-list t) (inhibit-read-only t) - (inhibit-modification-hooks t)) + (inhibit-modification-hooks t) + buffer-file-name buffer-file-truename) (while pos (remove-text-properties pos (1+ pos) '(display)) (setq pos (text-property-not-all (1+ pos) (point-max) 'hard nil))) From d783847a912f16bb6e171f1e5c5823b8afea1b0f Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Wed, 16 Jan 2008 16:23:09 +0000 Subject: [PATCH 155/439] (rng-nxml-mode-init): Add status after the "degraded" indicator. --- lisp/nxml/rng-nxml.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lisp/nxml/rng-nxml.el b/lisp/nxml/rng-nxml.el index ffe66d98be8..083c637876b 100644 --- a/lisp/nxml/rng-nxml.el +++ b/lisp/nxml/rng-nxml.el @@ -103,7 +103,8 @@ Validation will be enabled if `rng-nxml-auto-validate-flag' is non-nil." "Menu for nxml-mode used with rng-validate-mode." rng-nxml-easy-menu) (add-to-list 'mode-line-process - '(rng-validate-mode (:eval (rng-compute-mode-line-string)))) + '(rng-validate-mode (:eval (rng-compute-mode-line-string))) + 'append) (cond (rng-nxml-auto-validate-flag (rng-validate-mode 1) (add-hook 'nxml-completion-hook 'rng-complete nil t) From 1d86a98fa03896f2b6fe95874a3f5ec1231cb0f2 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Wed, 16 Jan 2008 16:25:18 +0000 Subject: [PATCH 156/439] *** empty log message *** --- lisp/ChangeLog | 37 +++++++++++++++++++++++++++++++++++++ 1 file changed, 37 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4e049abdc67..03e6e3fd1d5 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,40 @@ +2008-01-16 Martin Rudalics + + * longlines.el (longlines-mode, longlines-show-region) + (longlines-unshow-hard-newlines): Bind buffer-file-name and + buffer-file-truename to nil while modifying buffer. + + * cus-edit.el (custom-reset-standard-variables-list) + (custom-reset-standard-faces-list): New variables. + (custom-reset-standard-save-and-update): New function. + (Custom-save): Apply custom-mark-to-save before and + custom-state-set-and-redraw after saving options. + (Custom-reset-standard): Apply custom-mark-to-reset-standard to + options and call custom-reset-standard-save-and-update. + (custom-variable, custom-face, custom-group): Provide new + entries for custom-mark-to-save, custom-mark-to-reset-standard, + and custom-state-set-and-redraw. + (custom-variable-mark-to-save) + (custom-variable-state-set-and-redraw) + (custom-variable-mark-to-reset-standard) + (custom-face-mark-to-save, custom-face-state-set-and-redraw) + (custom-face-mark-to-reset-standard) + (custom-group-mark-to-save, custom-group-state-set-and-redraw) + (custom-group-mark-to-reset-standard): New functions. + (custom-variable-save): Move save, state-set, and redraw + functionality to custom-variable-mark-to-save. + (custom-face-save): Move save, state-set, and redraw + functionality to custom-face-mark-to-save. + (custom-group-save): Move save, state-set, and redraw + functionality to custom-group-mark-to-save. + (custom-variable-reset-standard, custom-face-reset-standard) + (custom-group-reset-standard): Move save, state-set, and redraw + functionality to custom-reset-standard-save-and-update. + + (custom-buffer-create-internal): Fix text in verbose help. + (custom-face-value-create): Indent doc-strings of faces like + those of variables. + 2008-01-16 Stefan Monnier * server.el (server-process-filter): Replace lineno and columnnno From 6bed5c4a80687fa9767819a948453cfe3551bbc2 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 16 Jan 2008 16:29:00 +0000 Subject: [PATCH 157/439] * configure.in: Remove more references to unsupported systems. * s/irix3-3.h: * s/irix4-0.h: * s/386-ix.h: * s/domain.h: * s/hpux9-x11r4.h: * s/hpux9shxr4.h: Remove files for systems no longer supported. * sysdep.c: Remove code containing references to symbols defined by unsupported systems. --- ChangeLog | 4 ++ configure.in | 22 ------- src/ChangeLog | 12 ++++ src/s/386-ix.h | 18 ----- src/s/domain.h | 7 -- src/s/hpux9-x11r4.h | 12 ---- src/s/hpux9shxr4.h | 10 --- src/s/irix3-3.h | 156 -------------------------------------------- src/s/irix4-0.h | 79 ---------------------- src/sysdep.c | 10 --- 10 files changed, 16 insertions(+), 314 deletions(-) delete mode 100644 src/s/386-ix.h delete mode 100644 src/s/domain.h delete mode 100644 src/s/hpux9-x11r4.h delete mode 100644 src/s/hpux9shxr4.h delete mode 100644 src/s/irix3-3.h delete mode 100644 src/s/irix4-0.h diff --git a/ChangeLog b/ChangeLog index 17f0c98a91c..4ddf3d2ab95 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-01-16 Dan Nicolaescu + + * configure.in: Remove more references to unsupported systems. + 2008-01-16 Sven Joachim * make-dist: Add --lzma. diff --git a/configure.in b/configure.in index b06985a340a..2c10879dcdb 100644 --- a/configure.in +++ b/configure.in @@ -571,12 +571,6 @@ dnl see the `changequote' comment above. ## Silicon Graphics machines ## Iris 4D - mips-sgi-irix3* ) - machine=iris4d opsys=irix3-3 - ;; - mips-sgi-irix4* ) - machine=iris4d opsys=irix4-0 - ;; mips-sgi-irix6.5 ) machine=iris4d opsys=irix6-5 # Without defining _LANGUAGE_C, things get masked out in the headers @@ -1467,22 +1461,6 @@ case ${HAVE_X11} in yes ) HAVE_MENUS=yes ;; esac -if test "${opsys}" = "hpux9"; then - case "${x_libraries}" in - *X11R4* ) - opsysfile="s/hpux9-x11r4.h" - ;; - esac -fi - -if test "${opsys}" = "hpux9shr"; then - case "${x_libraries}" in - *X11R4* ) - opsysfile="s/hpux9shxr4.h" - ;; - esac -fi - ### Compute the unexec source name from the object name. UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`" diff --git a/src/ChangeLog b/src/ChangeLog index e04746694f1..f5c648f03af 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,15 @@ +2008-01-16 Dan Nicolaescu + + * s/irix3-3.h: + * s/irix4-0.h: + * s/386-ix.h: + * s/domain.h: + * s/hpux9-x11r4.h: + * s/hpux9shxr4.h: Remove files for systems no longer supported. + + * sysdep.c: Remove code containing references to symbols defined + by unsupported systems. + 2008-01-16 Glenn Morris * coding.c (select-safe-coding-system-function): Doc fix. diff --git a/src/s/386-ix.h b/src/s/386-ix.h deleted file mode 100644 index 33658dd65e6..00000000000 --- a/src/s/386-ix.h +++ /dev/null @@ -1,18 +0,0 @@ -/* Interactive 386/ix. */ - -#include "usg5-3.h" - -#define BROKEN_TIOCGETC - -/* There are some reports that the following is needed - with some version of this system. -#undef LIBX11_SYSTEM -#define LIBX11_SYSTEM -linet -*/ - -/* This is said to be needed as a result of having _insque rather - than insque in -loldX. This may not always be the right thing. */ -#define WRONG_NAME_INSQUE - -/* arch-tag: c2fc2d64-46fd-4a87-933b-85eff622829c - (do not change this comment) */ diff --git a/src/s/domain.h b/src/s/domain.h deleted file mode 100644 index ebcdc7ea365..00000000000 --- a/src/s/domain.h +++ /dev/null @@ -1,7 +0,0 @@ -#include "bsd4-3.h" - -/* Inhibit using -X, which is the default. */ -#define LD_SWITCH_SYSTEM - -/* arch-tag: 08941c4f-d0b6-4ad6-b7e3-7e7fe76c0e94 - (do not change this comment) */ diff --git a/src/s/hpux9-x11r4.h b/src/s/hpux9-x11r4.h deleted file mode 100644 index 6a701d5a412..00000000000 --- a/src/s/hpux9-x11r4.h +++ /dev/null @@ -1,12 +0,0 @@ -/* System description file for hpux version 9 using X11R4. */ - -#include "hpux9.h" - -#undef C_SWITCH_X_SYSTEM -#define C_SWITCH_X_SYSTEM -I/usr/include/Motif1.1 - -#undef LD_SWITCH_X_DEFAULT -#define LD_SWITCH_X_DEFAULT -L/usr/lib/Motif1.1 - -/* arch-tag: 47664d7b-23ce-43e6-acdd-044a4be08da3 - (do not change this comment) */ diff --git a/src/s/hpux9shxr4.h b/src/s/hpux9shxr4.h deleted file mode 100644 index 63810273698..00000000000 --- a/src/s/hpux9shxr4.h +++ /dev/null @@ -1,10 +0,0 @@ -#include "hpux9shr.h" - -#undef C_SWITCH_X_SYSTEM -#define C_SWITCH_X_SYSTEM -I/usr/include/Motif1.1 - -#undef LD_SWITCH_X_DEFAULT -#define LD_SWITCH_X_DEFAULT -L/usr/lib/Motif1.1 - -/* arch-tag: 7f68b8b6-c733-4e6c-81df-39d8d13fb656 - (do not change this comment) */ diff --git a/src/s/irix3-3.h b/src/s/irix3-3.h deleted file mode 100644 index bb5785c6115..00000000000 --- a/src/s/irix3-3.h +++ /dev/null @@ -1,156 +0,0 @@ -/* Definitions file for GNU Emacs running on Silicon Graphics Irix system 3.3. - Copyright (C) 1987, 1990, 1999, 2001, 2002, 2003, 2004, - 2005, 2006, 2007, 2008 Free Software Foundation, Inc. - -This file is part of GNU Emacs. - -GNU Emacs is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 3, or (at your option) -any later version. - -GNU Emacs is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU Emacs; see the file COPYING. If not, write to -the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -Boston, MA 02110-1301, USA. */ - - -/* - * Define symbols to identify the version of Unix this is. - * Define all the symbols that apply correctly. - */ - -#define USG -#define USG5 -#define IRIS -#ifndef IRIX -#define IRIX -#endif - -/* SYSTEM_TYPE should indicate the kind of system you are using. - It sets the Lisp variable system-type. */ - -#define SYSTEM_TYPE "irix" - -/* nomultiplejobs should be defined if your system's shell - does not have "job control" (the ability to stop a program, - run some other program, then continue the first one). */ - -/* #define NOMULTIPLEJOBS */ - -/* Default is to set interrupt_input to 0: don't do input buffering within Emacs */ - -/* #define INTERRUPT_INPUT */ - -/* Letter to use in finding device name of first pty, - if system supports pty's. 'a' means it is /dev/ptya0 */ - -#define FIRST_PTY_LETTER 'a' - -/* - * Define HAVE_TERMIO if the system provides sysV-style ioctls - * for terminal control. - */ - -#define HAVE_TERMIO - -/* - * Define HAVE_PTYS if the system supports pty devices. - */ - -#define HAVE_PTYS - -/* Define HAVE_SOCKETS if system supports 4.2-compatible sockets. */ - -#define HAVE_SOCKETS - -/* - * Define NONSYSTEM_DIR_LIBRARY to make Emacs emulate - * The 4.2 opendir, etc., library functions. - */ - -/* #define NONSYSTEM_DIR_LIBRARY */ - -/* Define this symbol if your system has the functions bcopy, etc. */ - -#define BSTRING - -/* subprocesses should be defined if you want to - have code for asynchronous subprocesses - (as used in M-x compile and M-x shell). - This is generally OS dependent, and not supported - under most USG systems. */ - -#define subprocesses - -/* If your system uses COFF (Common Object File Format) then define the - preprocessor symbol "COFF". */ - -/* #define COFF */ - -/* define MAIL_USE_FLOCK if the mailer uses flock - to interlock access to /usr/spool/mail/$USER. - The alternative is that a lock file named - /usr/spool/mail/$USER.lock. */ - -#define MAIL_USE_FLOCK - -/* Define CLASH_DETECTION if you want lock files to be written - so that Emacs can tell instantly when you try to modify - a file that someone else has modified in his Emacs. */ - -/* #define CLASH_DETECTION */ - -/* The file containing the kernel's symbol table is called /unix. */ - -#define KERNEL_FILE "/unix" - -/* The symbol in the kernel where the load average is found - is named _avenrun. */ - -#define LDAV_SYMBOL "avenrun" - - -/* setjmp and longjmp can safely replace _setjmp and _longjmp, - but they will run slower. */ - -#define _setjmp setjmp -#define _longjmp longjmp - -/* On USG systems these have different names */ - -#define index strchr -#define rindex strrchr - -/* USG systems tend to put everything declared static - into the initialized data area, which becomes pure after dumping Emacs. - Foil this. Emacs carefully avoids static vars inside functions. */ - -/* #define static */ - -/* This is how to get the device name of the tty end of a pty. */ -#define PTY_TTY_NAME_SPRINTF \ - sprintf (ptyname, "/dev/ttyq%d", minor (stb.st_rdev)); - - -#define HAVE_SYSVIPC - -/* sioctl.h should be included where appropriate. */ - -#define NEED_SIOCTL - -/* This affects child_setup. */ - -#define SETPGRP_RELEASES_CTTY - -/* This was formerly in LIBS_MACHINE in iris4d.h, - but it is not needed for newer system versions. */ -#define LIBS_SYSTEM -lsun - -/* arch-tag: cccdd761-2ae9-4e71-a33e-749681c01889 - (do not change this comment) */ diff --git a/src/s/irix4-0.h b/src/s/irix4-0.h deleted file mode 100644 index e06940a0378..00000000000 --- a/src/s/irix4-0.h +++ /dev/null @@ -1,79 +0,0 @@ -/* Definitions file for GNU Emacs running on Silicon Graphics Irix system 4.0 - - Copyright (C) 1999, 2001, 2002, 2003, 2004, 2005, 2006, - 2007, 2008 Free Software Foundation, Inc. - -This file is part of GNU Emacs. - -GNU Emacs is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 3, or (at your option) -any later version. - -GNU Emacs is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with GNU Emacs; see the file COPYING. If not, write to -the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -Boston, MA 02110-1301, USA. */ - - -#include "irix3-3.h" - -#define USG5_3 -#define IRIX4 -/* XPointer is not defined in the older X headers -- JPff@maths.bath.ac.uk */ -#define XPointer caddr_t - -#undef NEED_SIOCTL - -/* Include unistd.h, even though we don't define POSIX. */ -#define NEED_UNISTD_H - -/* Make process_send_signal work by "typing" a signal character on the pty. */ -#define SIGNALS_VIA_CHARACTERS - -#ifndef __GNUC__ -/* use K&R C */ -/* We need to increase the expression tree space with -Wf,-XNh - (ghazi@caip.rutgers.edu 7/8/97.) -*/ -#define C_SWITCH_SYSTEM -cckr -Wf,-XNh4000 -#endif - -/* SGI has all the fancy wait stuff, but we can't include sys/wait.h - because it defines BIG_ENDIAN and LITTLE_ENDIAN (ugh!.) Instead - we'll just define WNOHANG right here. - (An implicit decl is good enough for wait3.) */ - -#define WNOHANG 0x1 - -/* No need to use sprintf to get the tty name--we get that from _getpty. */ -#undef PTY_TTY_NAME_SPRINTF -#define PTY_TTY_NAME_SPRINTF -/* No need to get the pty name at all. */ -#define PTY_NAME_SPRINTF -/* We need only try once to open a pty. */ -#define PTY_ITERATION -/* Here is how to do it. */ -/* It is necessary to prevent SIGCHLD signals within _getpty. - So we block them. */ -#define PTY_OPEN \ -{ \ - int mask = sigblock (sigmask (SIGCHLD)); \ - char *name = _getpty (&fd, O_RDWR | O_NDELAY, 0600, 0); \ - sigsetmask(mask); \ - if (name == 0) \ - return -1; \ - if (fd < 0) \ - return -1; \ - if (fstat (fd, &stb) < 0) \ - return -1; \ - strcpy (pty_name, name); \ -} - -/* arch-tag: cfd7e200-a4dc-4f67-9a32-4184c10b0c57 - (do not change this comment) */ diff --git a/src/sysdep.c b/src/sysdep.c index 798cd3b2108..01126c4907e 100644 --- a/src/sysdep.c +++ b/src/sysdep.c @@ -3205,16 +3205,6 @@ get_random () return val & ((1L << VALBITS) - 1); } -#ifdef WRONG_NAME_INSQUE - -insque (q,p) - caddr_t q,p; -{ - _insque (q,p); -} - -#endif - #ifdef VMS #ifdef getenv From 927783c1e2b83ef8d0a11006135f1da382ba3b90 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 16 Jan 2008 16:30:53 +0000 Subject: [PATCH 158/439] *** empty log message *** --- lisp/ChangeLog | 14 ++++++++++++-- 1 file changed, 12 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 12621959992..c17a99cdf85 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,13 @@ +2008-01-16 Juanma Barranquero + + * frame.el (display-mm-height, display-mm-width): + * whitespace.el (whitespace-check-leading-whitespace) + (whitespace-check-trailing-whitespace) + (whitespace-check-spacetab-whitespace) + (whitespace-check-indent-whitespace) + (whitespace-check-ateol-whitespace): + * progmodes/ada-xref.el (ada-convert-file-name): Fix typo in docstring. + 2008-01-16 Glenn Morris * comint.el (comint-regexp-arg): Fix no-input case. @@ -555,7 +565,7 @@ (verilog-re-search-backward, verilog-re-search-forward-quick) (verilog-re-search-backward-quick, verilog-get-beg-of-line) (verilog-get-end-of-line, verilog-within-string): Move definitions - before first use. No code changes. + before first use. No code changes. 2007-12-08 Dan Nicolaescu @@ -5988,7 +5998,7 @@ path. Rewrite function in `cond' style for readability. Suggested by: Stephen Eglen . - (The path shortening, that is, not the rearrarangement.) + (The path shortening, that is, not the rearrangement.) 2007-01-15 YAMAMOTO Mitsuharu From 9302e128c967ebb06e05bfac3fbd3525784b5631 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Wed, 16 Jan 2008 21:26:01 +0000 Subject: [PATCH 159/439] *** empty log message *** --- lisp/ChangeLog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c17a99cdf85..c497286f4ea 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-16 Alan Mackenzie + + * progmodes/cc-vars.el (c-constant-symbol): Put this defun inside + an eval-and-compile, so as to permit byte-compiling (e.g. in + bootstrap). + 2008-01-16 Juanma Barranquero * frame.el (display-mm-height, display-mm-width): From 1d6c7cd7ee40709f25c6e24a2daffbfbc226efc3 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Wed, 16 Jan 2008 21:26:59 +0000 Subject: [PATCH 160/439] (c-constant-symbol): Put this defun inside an eval-and-compile, so as to permit byte-compiling (e.g. in bootstrap). --- lisp/progmodes/cc-vars.el | 21 +++++++++++---------- 1 file changed, 11 insertions(+), 10 deletions(-) diff --git a/lisp/progmodes/cc-vars.el b/lisp/progmodes/cc-vars.el index 6ba2281f344..7596dc60b5f 100644 --- a/lisp/progmodes/cc-vars.el +++ b/lisp/progmodes/cc-vars.el @@ -74,22 +74,23 @@ Useful as last item in a `choice' widget." :value 'other)) ;; The next defun will supersede c-const-symbol. -(defun c-constant-symbol (sym len) - "Create an uneditable symbol for customization buffers. +(eval-and-compile + (defun c-constant-symbol (sym len) + "Create an uneditable symbol for customization buffers. SYM is the name of the symbol, LEN the length of the field (in characters) the symbol will be displayed in. LEN must be big enough. This returns a (const ....) structure, suitable for embedding within a customization type." - (or (symbolp sym) (error "c-constant-symbol: %s is not a symbol" sym)) - (let* ((name (symbol-name sym)) - (l (length name)) - (disp (concat name ":" (make-string (- len l 1) ?\ )))) - `(const - :size ,len - :format ,disp - :value ,sym))) + (or (symbolp sym) (error "c-constant-symbol: %s is not a symbol" sym)) + (let* ((name (symbol-name sym)) + (l (length name)) + (disp (concat name ":" (make-string (- len l 1) ?\ )))) + `(const + :size ,len + :format ,disp + :value ,sym)))) (define-widget 'c-const-symbol 'item "An uneditable lisp symbol. This is obsolete - From 5d2c8fc0d8e74cfa8bbe6b5d4a26eff56d911df6 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 17 Jan 2008 04:04:26 +0000 Subject: [PATCH 161/439] (START_FILES, LIB_STANDARD): Adjust value according to HAVE_X86_64_LIB64_DIR. --- src/ChangeLog | 5 +++++ src/m/ibms390x.h | 10 +++++++++- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 25b994e3ab8..ceea594199e 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-01-17 Glenn Morris + + * m/ibms390x.h (START_FILES, LIB_STANDARD): Adjust value according + to HAVE_X86_64_LIB64_DIR. + 2008-01-11 YAMAMOTO Mitsuharu * mac.c (mac_emacs_pid) [MAC_OSX]: New variable. diff --git a/src/m/ibms390x.h b/src/m/ibms390x.h index 89aa3c19335..290b17a3e3f 100644 --- a/src/m/ibms390x.h +++ b/src/m/ibms390x.h @@ -23,7 +23,7 @@ Boston, MA 02110-1301, USA. */ into ibms390.h. */ -/* The following line tells the configuration script what sort of +/* The following line tells the configuration script what sort of operating system this machine is likely to run. USUAL-OPSYS="" @@ -161,10 +161,18 @@ NOTE-END */ #define XPNTR(a) XUINT (a) #undef START_FILES +#ifdef HAVE_X86_64_LIB64_DIR #define START_FILES pre-crt0.o /usr/lib64/crt1.o /usr/lib64/crti.o +#else +#define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o +#endif #undef LIB_STANDARD +#ifdef HAVE_X86_64_LIB64_DIR #define LIB_STANDARD -lgcc -lc -lgcc /usr/lib64/crtn.o +#else +#define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o +#endif /* arch-tag: 4b87653c-6add-4663-8691-7d9dc17b5519 (do not change this comment) */ From beccaaa6de6fb74a94e86237f3a5e1b8b969d8d0 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 17 Jan 2008 04:04:51 +0000 Subject: [PATCH 162/439] (HAVE_X86_64_LIB64_DIR): Also set on s390x systems. --- configure.in | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/configure.in b/configure.in index 6105539df2d..2320ea18370 100644 --- a/configure.in +++ b/configure.in @@ -1532,7 +1532,7 @@ AC_SYS_LARGEFILE ### The standard library on x86-64 GNU/Linux distributions can ### be located in either /usr/lib64 or /usr/lib. case "${canonical}" in - x86_64-*-linux-gnu* ) + x86_64-*-linux-gnu* | s390x-*-linux-gnu* ) if test -d /usr/lib64; then AC_DEFINE(HAVE_X86_64_LIB64_DIR, 1, [Define to 1 if the file /usr/lib64 exists.]) From eddedb1594409e2eb4dc42840a72023190d0e716 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 17 Jan 2008 04:06:38 +0000 Subject: [PATCH 163/439] Regenerate. --- ChangeLog | 4 ++++ configure | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index dd999eb2123..5d993d114f4 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-01-17 Glenn Morris + + * configure.in (HAVE_X86_64_LIB64_DIR): Also set on s390x systems. + 2007-11-28 Petr Salinger (tiny change) * configure.in: Add support for gnu-kfreebsd. diff --git a/configure b/configure index 8242d6ef59f..859f6b74881 100755 --- a/configure +++ b/configure @@ -5828,7 +5828,7 @@ fi ### The standard library on x86-64 GNU/Linux distributions can ### be located in either /usr/lib64 or /usr/lib. case "${canonical}" in - x86_64-*-linux-gnu* ) + x86_64-*-linux-gnu* | s390x-*-linux-gnu* ) if test -d /usr/lib64; then cat >>confdefs.h <<\_ACEOF From b16ed52dbb30e8009eb8689de6877f500f7f7c33 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 17 Jan 2008 04:08:06 +0000 Subject: [PATCH 164/439] (START_FILES, LIB_STANDARD): Adjust value according to HAVE_X86_64_LIB64_DIR. --- src/ChangeLog | 5 +++++ src/m/ibms390x.h | 8 ++++++++ 2 files changed, 13 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index f5c648f03af..5e464404310 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-01-17 Glenn Morris + + * m/ibms390x.h (START_FILES, LIB_STANDARD): Adjust value according + to HAVE_X86_64_LIB64_DIR. + 2008-01-16 Dan Nicolaescu * s/irix3-3.h: diff --git a/src/m/ibms390x.h b/src/m/ibms390x.h index 7c0c577523e..9c4a14895fd 100644 --- a/src/m/ibms390x.h +++ b/src/m/ibms390x.h @@ -152,10 +152,18 @@ NOTE-END */ #define XPNTR(a) XUINT (a) #undef START_FILES +#ifdef HAVE_X86_64_LIB64_DIR #define START_FILES pre-crt0.o /usr/lib64/crt1.o /usr/lib64/crti.o +#else +#define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o +#endif #undef LIB_STANDARD +#ifdef HAVE_X86_64_LIB64_DIR #define LIB_STANDARD -lgcc -lc -lgcc /usr/lib64/crtn.o +#else +#define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o +#endif /* arch-tag: 4b87653c-6add-4663-8691-7d9dc17b5519 (do not change this comment) */ From b4e96cdbf9b2c9cf9f4a79b26211da6ac378181a Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 17 Jan 2008 04:09:20 +0000 Subject: [PATCH 165/439] (ibuffer-auto-mode): Remove call to deleted ibuffer-update-mode-name. --- lisp/ChangeLog | 5 +++++ lisp/ibuf-ext.el | 3 +-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 03e6e3fd1d5..9d4a7f4644c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-17 Glenn Morris + + * ibuf-ext.el (ibuffer-auto-mode): Remove call to deleted + ibuffer-update-mode-name. + 2008-01-16 Martin Rudalics * longlines.el (longlines-mode, longlines-show-region) diff --git a/lisp/ibuf-ext.el b/lisp/ibuf-ext.el index aafc93af990..810b9f03a16 100644 --- a/lisp/ibuf-ext.el +++ b/lisp/ibuf-ext.el @@ -243,8 +243,7 @@ With numeric ARG, enable auto-update if and only if ARG is positive." (plusp arg) (not ibuffer-auto-mode))) (frame-or-buffer-changed-p 'ibuffer-auto-buffers-changed) ; Initialize state vector - (add-hook 'post-command-hook 'ibuffer-auto-update-changed) - (ibuffer-update-mode-name)) + (add-hook 'post-command-hook 'ibuffer-auto-update-changed)) ;;;###autoload (defun ibuffer-mouse-filter-by-mode (event) From 058e0687623576d2ec9b84a212882f25ffb3eb02 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 17 Jan 2008 04:10:08 +0000 Subject: [PATCH 166/439] (HAVE_X86_64_LIB64_DIR): Also set on s390x systems. --- ChangeLog | 4 ++++ configure.in | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 4ddf3d2ab95..86d1bce92a9 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-01-17 Glenn Morris + + * configure.in (HAVE_X86_64_LIB64_DIR): Also set on s390x systems. + 2008-01-16 Dan Nicolaescu * configure.in: Remove more references to unsupported systems. diff --git a/configure.in b/configure.in index 2c10879dcdb..f514087e306 100644 --- a/configure.in +++ b/configure.in @@ -1075,7 +1075,7 @@ AC_SYS_LARGEFILE ### The standard library on x86-64 GNU/Linux distributions can ### be located in either /usr/lib64 or /usr/lib. case "${canonical}" in - x86_64-*-linux-gnu* ) + x86_64-*-linux-gnu* | s390x-*-linux-gnu* ) if test -d /usr/lib64; then AC_DEFINE(HAVE_X86_64_LIB64_DIR, 1, [Define to 1 if the file /usr/lib64 exists.]) From 2f5ca70b21e0f3be0bc2e51f25d8430670a16bc2 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 17 Jan 2008 05:16:35 +0000 Subject: [PATCH 167/439] (ibuffer-save-filter-groups, ibuffer-save-filters): Remove calls to deleted ibuffer-update-mode-name. --- lisp/ChangeLog | 3 ++- lisp/ibuf-ext.el | 6 ++---- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9d4a7f4644c..fe334702fdb 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,6 +1,7 @@ 2008-01-17 Glenn Morris - * ibuf-ext.el (ibuffer-auto-mode): Remove call to deleted + * ibuf-ext.el (ibuffer-auto-mode, ibuffer-save-filter-groups) + (ibuffer-save-filters): Remove calls to deleted ibuffer-update-mode-name. 2008-01-16 Martin Rudalics diff --git a/lisp/ibuf-ext.el b/lisp/ibuf-ext.el index 810b9f03a16..0499fab51aa 100644 --- a/lisp/ibuf-ext.el +++ b/lisp/ibuf-ext.el @@ -730,8 +730,7 @@ prompt for NAME, and use the current filters." (ibuffer-aif (assoc name ibuffer-saved-filter-groups) (setcdr it groups) (push (cons name groups) ibuffer-saved-filter-groups)) - (ibuffer-maybe-save-stuff) - (ibuffer-update-mode-name)) + (ibuffer-maybe-save-stuff)) ;;;###autoload (defun ibuffer-delete-saved-filter-groups (name) @@ -896,8 +895,7 @@ Interactively, prompt for NAME, and use the current filters." (ibuffer-aif (assoc name ibuffer-saved-filters) (setcdr it filters) (push (list name filters) ibuffer-saved-filters)) - (ibuffer-maybe-save-stuff) - (ibuffer-update-mode-name)) + (ibuffer-maybe-save-stuff)) ;;;###autoload (defun ibuffer-delete-saved-filters (name) From 602e142f5cddd7b199abb16ee9db1aeaa6e01ea6 Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Thu, 17 Jan 2008 11:38:45 +0000 Subject: [PATCH 168/439] (w32_read_socket) : Decode characters outside the unicode range available in MULE by locale-coding-system. Improve dbcs lead byte detection. Set event timestamp and modifiers earlier. --- src/ChangeLog | 7 +++++ src/w32term.c | 86 ++++++++++++++++++++++++++++++++++++++++----------- 2 files changed, 75 insertions(+), 18 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index ceea594199e..a2cb8c490a6 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,10 @@ +2008-01-17 Jason Rumney + + * w32term.c (w32_read_socket) : Decode characters outside + the unicode range available in MULE by locale-coding-system. + Improve dbcs lead byte detection. Set event timestamp and modifiers + earlier. + 2008-01-17 Glenn Morris * m/ibms390x.h (START_FILES, LIB_STANDARD): Adjust value according diff --git a/src/w32term.c b/src/w32term.c index a85715dbfb9..23b79008402 100644 --- a/src/w32term.c +++ b/src/w32term.c @@ -4290,6 +4290,10 @@ w32_read_socket (sd, expected, hold_quit) temp_index = 0; temp_buffer[temp_index++] = msg.msg.wParam; + inev.modifiers = msg.dwModifiers; + XSETFRAME (inev.frame_or_window, f); + inev.timestamp = msg.msg.time; + if (msg.msg.wParam < 128 && !dbcs_lead) { inev.kind = ASCII_KEYSTROKE_EVENT; @@ -4298,20 +4302,14 @@ w32_read_socket (sd, expected, hold_quit) else if (msg.msg.wParam < 256) { wchar_t code; - + char dbcs[2]; inev.kind = MULTIBYTE_CHAR_KEYSTROKE_EVENT; + dbcs[0] = 0; + dbcs[1] = (char) msg.msg.wParam; - if (IsDBCSLeadByteEx(CP_ACP, (BYTE) msg.msg.wParam)) + if (dbcs_lead) { - dbcs_lead = (char) msg.msg.wParam; - inev.kind = NO_EVENT; - break; - } - else if (dbcs_lead) - { - char dbcs[2]; dbcs[0] = dbcs_lead; - dbcs[1] = (char) msg.msg.wParam; dbcs_lead = 0; if (!MultiByteToWideChar(CP_ACP, 0, dbcs, 2, &code, 1)) { @@ -4322,14 +4320,19 @@ w32_read_socket (sd, expected, hold_quit) break; } } + else if (IsDBCSLeadByteEx(CP_ACP, (BYTE) msg.msg.wParam)) + { + dbcs_lead = (char) msg.msg.wParam; + inev.kind = NO_EVENT; + break; + } else { - char single_byte = (char) msg.msg.wParam; - if (!MultiByteToWideChar(CP_ACP, 0, &single_byte, 1, + if (!MultiByteToWideChar(CP_ACP, 0, &dbcs[1], 1, &code, 1)) { /* What to do with garbage? */ - DebPrint (("Invalid character: %d\n", single_byte)); + DebPrint (("Invalid character: %d\n", dbcs[1])); inev.kind = NO_EVENT; break; } @@ -4355,17 +4358,67 @@ w32_read_socket (sd, expected, hold_quit) charset_id = charset_mule_unicode_0100_24ff; code -= 0x100; } - else if (code < 0xE000) + else if (code < 0x3400) { charset_id = charset_mule_unicode_2500_33ff; code -= 0x2500; } - else + else if (code >= 0xE000) { charset_id = charset_mule_unicode_e000_ffff; code -= 0xE000; } + else + { + /* Not in the unicode range that we can handle in + Emacs-22, so decode the original character + using the locale */ + int nbytes, nchars, require, i, len; + unsigned char *dest; + struct coding_system coding; + if (dbcs[0] == 0) + { + nbytes = 1; + dbcs[0] = dbcs[1]; + } + else + nbytes = 2; + + setup_coding_system (Vlocale_coding_system, &coding); + coding.src_multibyte = 0; + coding.dst_multibyte = 1; + coding.composing = COMPOSITION_DISABLED; + require = decoding_buffer_size (&coding, nbytes); + dest = (unsigned char *) alloca (require); + coding.mode |= CODING_MODE_LAST_BLOCK; + + decode_coding (&coding, dbcs, dest, nbytes, require); + nbytes = coding.produced; + nchars = coding.produced_char; + + for (i = 0; i < nbytes; i += len) + { + if (nchars == nbytes) + { + inev.code = dest[i]; + len = 1; + } + else + inev.code = STRING_CHAR_AND_LENGTH (dest + i, + nbytes - 1, + len); + inev.kind = (SINGLE_BYTE_CHAR_P (inev.code) + ? ASCII_KEYSTROKE_EVENT + : MULTIBYTE_CHAR_KEYSTROKE_EVENT); + kbd_buffer_store_event_hold (&inev, hold_quit); + count++; + } + inev.kind = NO_EVENT; /* Already handled */ + break; + } + + /* Unicode characters from above. */ c1 = (code / 96) + 32; c2 = (code % 96) + 32; inev.code = MAKE_CHAR (charset_id, c1, c2); @@ -4379,9 +4432,6 @@ w32_read_socket (sd, expected, hold_quit) inev.kind = NO_EVENT; break; } - inev.modifiers = msg.dwModifiers; - XSETFRAME (inev.frame_or_window, f); - inev.timestamp = msg.msg.time; } break; From ddd01c5dd482b19eb962f60cb135ac392eba9f01 Mon Sep 17 00:00:00 2001 From: Andreas Schwab Date: Thu, 17 Jan 2008 11:41:10 +0000 Subject: [PATCH 169/439] (HAVE_LIB64_DIR): Renamed from HAVE_X86_64_LIB64_DIR. --- configure.in | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/configure.in b/configure.in index f514087e306..00b219db21e 100644 --- a/configure.in +++ b/configure.in @@ -1072,13 +1072,13 @@ dnl Do this early because it can frob feature test macros for Unix-98 &c. AC_SYS_LARGEFILE -### The standard library on x86-64 GNU/Linux distributions can +### The standard library on x86-64 and s390x GNU/Linux distributions can ### be located in either /usr/lib64 or /usr/lib. case "${canonical}" in x86_64-*-linux-gnu* | s390x-*-linux-gnu* ) if test -d /usr/lib64; then - AC_DEFINE(HAVE_X86_64_LIB64_DIR, 1, - [Define to 1 if the file /usr/lib64 exists.]) + AC_DEFINE(HAVE_LIB64_DIR, 1, + [Define to 1 if the directory /usr/lib64 exists.]) fi esac From ea7a608ab965d4c0784188824670051c9e5e4a0e Mon Sep 17 00:00:00 2001 From: Andreas Schwab Date: Thu, 17 Jan 2008 11:42:12 +0000 Subject: [PATCH 170/439] (START_FILES, LIB_STANDARD): Use HAVE_LIB64_DIR instead of HAVE_X86_64_LIB64_DIR. --- src/m/amdx86-64.h | 4 ++-- src/m/ibms390x.h | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/m/amdx86-64.h b/src/m/amdx86-64.h index 37ae8ebb148..cdf8599e9b6 100644 --- a/src/m/amdx86-64.h +++ b/src/m/amdx86-64.h @@ -146,7 +146,7 @@ Boston, MA 02110-1301, USA. */ #else /* !__OpenBSD__ && !__FreeBSD__ && !__NetBSD__ && !sun */ #undef START_FILES -#ifdef HAVE_X86_64_LIB64_DIR +#ifdef HAVE_LIB64_DIR #define START_FILES pre-crt0.o /usr/lib64/crt1.o /usr/lib64/crti.o #else #define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o @@ -158,7 +158,7 @@ Boston, MA 02110-1301, USA. */ versions of ld are one-pass linkers, we need to mention -lgcc twice, or else we risk getting unresolved externals. */ #undef LIB_STANDARD -#ifdef HAVE_X86_64_LIB64_DIR +#ifdef HAVE_LIB64_DIR #define LIB_STANDARD -lgcc -lc -lgcc /usr/lib64/crtn.o #else #define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o diff --git a/src/m/ibms390x.h b/src/m/ibms390x.h index 9c4a14895fd..443357966b6 100644 --- a/src/m/ibms390x.h +++ b/src/m/ibms390x.h @@ -152,14 +152,14 @@ NOTE-END */ #define XPNTR(a) XUINT (a) #undef START_FILES -#ifdef HAVE_X86_64_LIB64_DIR +#ifdef HAVE_LIB64_DIR #define START_FILES pre-crt0.o /usr/lib64/crt1.o /usr/lib64/crti.o #else #define START_FILES pre-crt0.o /usr/lib/crt1.o /usr/lib/crti.o #endif #undef LIB_STANDARD -#ifdef HAVE_X86_64_LIB64_DIR +#ifdef HAVE_LIB64_DIR #define LIB_STANDARD -lgcc -lc -lgcc /usr/lib64/crtn.o #else #define LIB_STANDARD -lgcc -lc -lgcc /usr/lib/crtn.o From 55e6d9b27eae4f97500516f4fb86e4013d148d14 Mon Sep 17 00:00:00 2001 From: Andreas Schwab Date: Thu, 17 Jan 2008 11:43:28 +0000 Subject: [PATCH 171/439] Regenerate. --- ChangeLog | 5 + configure | 509 +------------------------------------------------- src/ChangeLog | 6 + src/config.in | 6 +- 4 files changed, 19 insertions(+), 507 deletions(-) diff --git a/ChangeLog b/ChangeLog index 86d1bce92a9..80b38fefba2 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-01-17 Andreas Schwab + + * configure.in (HAVE_LIB64_DIR): Renamed from + HAVE_X86_64_LIB64_DIR. + 2008-01-17 Glenn Morris * configure.in (HAVE_X86_64_LIB64_DIR): Also set on s390x systems. diff --git a/configure b/configure index 4d8d153ba55..fe96275bd42 100755 --- a/configure +++ b/configure @@ -2235,8 +2235,8 @@ configuration=${host_alias-${build_alias-$host}} ### based on the machine portion of the configuration name, and an s- ### file based on the operating system portion. However, it turns out ### that each m/*.h file is pretty manufacturer-specific - for -### example, apollo.h, hp9000s300.h, mega68k, news.h, and tad68k are -### all 68000 machines; mips.h, pmax.h, and news-risc are all MIPS +### example hp9000s300.h is a 68000 machine; +### mips.h, pmax.h are all MIPS ### machines. So we basically have to have a special case for each ### configuration name. ### @@ -2299,14 +2299,12 @@ _ACEOF mips-*-netbsd*) machine=pmax ;; mipsel-*-netbsd*) machine=pmax ;; mipseb-*-netbsd*) machine=pmax ;; - ns32k-*-netbsd*) machine=ns32000 ;; powerpc-*-netbsd*) machine=macppc ;; sparc*-*-netbsd*) machine=sparc ;; vax-*-netbsd*) machine=vax ;; arm-*-netbsd*) machine=arm ;; x86_64-*-netbsd*) machine=amdx86-64 ;; hppa-*-netbsd*) machine=hp800 ;; - shle-*-netbsd*) machine=sh3el ;; esac ;; @@ -2319,10 +2317,8 @@ _ACEOF hppa-*-openbsd*) machine=hp9000s300 ;; i386-*-openbsd*) machine=intel386 ;; m68k-*-openbsd*) machine=hp9000s300 ;; - m88k-*-openbsd*) machine=aviion ;; mips64-*-openbsd*) machine=mips64 ;; powerpc-*-openbsd*) machine=macppc ;; - sh-*-openbsd*) machine=sh3el ;; sparc*-*-openbsd*) machine=sparc ;; vax-*-openbsd*) machine=vax ;; x86_64-*-openbsd*) machine=amdx86-64 ;; @@ -2338,16 +2334,6 @@ _ACEOF esac ;; - ## Acorn RISCiX: - arm-acorn-riscix1.1* ) - machine=acorn opsys=riscix1-1 - ;; - arm-acorn-riscix1.2* | arm-acorn-riscix ) - ## This name is riscix12 instead of riscix1.2 - ## to avoid a file name conflict on MSDOS. - machine=acorn opsys=riscix12 - ;; - ## BSDI ports *-*-bsdi* ) opsys=bsdi @@ -2365,19 +2351,6 @@ _ACEOF esac ;; - ## Alliant machines - ## Strictly speaking, we need the version of the alliant operating - ## system to choose the right machine file, but currently the - ## configuration name doesn't tell us enough to choose the right - ## one; we need to give alliants their own operating system name to - ## do this right. When someone cares, they can help us. - fx80-alliant-* ) - machine=alliant4 opsys=bsd4-2 - ;; - i860-alliant-* ) - machine=alliant-2800 opsys=bsd4-3 - ;; - ## Alpha (DEC) machines. alpha*-dec-osf* ) machine=alpha opsys=osf1 @@ -2403,21 +2376,6 @@ _ACEOF machine=arm opsys=gnu-linux ;; - ## Altos 3068 - m68*-altos-sysv* ) - machine=altos opsys=usg5-2 - ;; - - ## Amdahl UTS - 580-amdahl-sysv* ) - machine=amdahl opsys=usg5-2-2 - ;; - - ## Apollo, Domain/OS - m68*-apollo-* ) - machine=apollo opsys=bsd4-3 - ;; - ## Apple Darwin / Mac OS X *-apple-darwin* ) case "${canonical}" in @@ -2436,101 +2394,16 @@ _ACEOF fi ;; - ## AT&T 3b2, 3b5, 3b15, 3b20 - we32k-att-sysv* ) - machine=att3b opsys=usg5-2-2 - ;; - - ## AT&T 3b1 - The Mighty Unix PC! - m68*-att-sysv* ) - machine=7300 opsys=usg5-2-2 - ;; - - ## Bull dpx20 - rs6000-bull-bosx* ) - machine=ibmrs6000 opsys=aix3-2 - ;; - - ## Bull dpx2 - m68*-bull-sysv3* ) - machine=dpx2 opsys=usg5-3 - ;; - - ## Bull sps7 - m68*-bull-sysv2* ) - machine=sps7 opsys=usg5-2 - ;; - - ## CCI 5/32, 6/32 -- see "Tahoe". - - ## Celerity - ## I don't know what configuration name to use for this; config.sub - ## doesn't seem to know anything about it. Hey, Celerity users, get - ## in touch with us! - celerity-celerity-bsd* ) - machine=celerity opsys=bsd4-2 - ;; - - ## Clipper - ## What operating systems does this chip run that Emacs has been - ## tested on? - clipper-* ) - machine=clipper - ## We'll use the catch-all code at the bottom to guess the - ## operating system. - ;; - ## Compaq Nonstop mips-compaq-nonstopux* ) machine=nonstopux opsys=nonstopux ;; - ## Convex - *-convex-bsd* | *-convex-convexos* ) - machine=convex opsys=bsd4-3 - ## Prevents spurious white space in makefiles - d.m.cooke@larc.nasa.gov - NON_GNU_CPP="cc -E -P" - ;; - ## Cubix QBx/386 i[3456]86-cubix-sysv* ) machine=intel386 opsys=usg5-3 ;; - ## Cydra 5 - cydra*-cydrome-sysv* ) - machine=cydra5 opsys=usg5-3 - ;; - - ## Data General AViiON Machines - ## DG changed naming conventions with the release of 5.4.4.10, they - ## dropped the initial 5.4 but left the intervening R. Because of the - ## R this shouldn't conflict with older versions of the OS (which I - ## think were named like dgux4.*). In addition, DG new AViiONs series - ## uses either Motorola M88k or Intel Pentium CPUs. - m88k-dg-dguxR4.* | m88k-dg-dgux4* ) - machine=aviion opsys=dgux4 - ;; - m88k-dg-dgux5.4R3* | m88k-dg-dgux5.4.3* ) - ## This name is dgux5-4-3 instead of dgux5-4r3 - ## to avoid a file name conflict on MSDOS. - machine=aviion opsys=dgux5-4-3 - ;; - m88k-dg-dgux5.4R2* | m88k-dg-dgux5.4.2* ) - machine=aviion opsys=dgux5-4r2 - ;; - m88k-dg-dgux* ) - machine=aviion opsys=dgux - ;; - - ## Data General AViiON Intel (x86) Machines - ## Exists from 5.4.3 (current i586-dg-dguxR4.11) - ## Ehud Karni, 1998-may-30, ehud@unix.simonwiesel.co.il - i[345]86-dg-dguxR4* ) - machine=aviion-intel opsys=dgux4 - ;; - - ## DECstations mips-dec-ultrix[0-3].* | mips-dec-ultrix4.0* | mips-dec-bsd4.2* ) machine=pmax opsys=bsd4-2 ;; @@ -2547,96 +2420,6 @@ _ACEOF machine=pmax opsys=mach-bsd4-3 ;; - ## Motorola Delta machines - m68k-motorola-sysv* | m68000-motorola-sysv* ) - machine=delta opsys=usg5-3 - if test -z "`type gnucc | grep 'not found'`" - then - if test -s /etc/167config - then CC="gnucc -m68040" - else CC="gnucc -m68881" - fi - else - if test -z "`type gcc | grep 'not found'`" - then CC=gcc - else CC=cc - fi - fi - ;; - m88k-motorola-sysv4* ) - # jbotte@bnr.ca says that UNIX_System_V 4.0 R40V4.3 m88k mc88110 - # needs POSIX_SIGNALS and therefore needs usg5-4-2. - # I hope there are not other 4.0 versions for this machine - # which really need usg5-4 instead. - machine=delta88k opsys=usg5-4-2 - ;; - m88k-motorola-sysv* | m88k-motorola-m88kbcs* ) - machine=delta88k opsys=usg5-3 - ;; - - ## Dual machines - m68*-dual-sysv* ) - machine=dual opsys=usg5-2 - ;; - m68*-dual-uniplus* ) - machine=dual opsys=unipl5-2 - ;; - - ## Elxsi 6400 - elxsi-elxsi-sysv* ) - machine=elxsi opsys=usg5-2 - ;; - - ## Encore machines - ns16k-encore-bsd* ) - machine=ns16000 opsys=umax - ;; - - ## The GEC 63 - apparently, this port isn't really finished yet. - # I'm sure we finished off the last of the machines, though. -- fx - - ## Gould Power Node and NP1 - pn-gould-bsd4.2* ) - machine=gould opsys=bsd4-2 - ;; - pn-gould-bsd4.3* ) - machine=gould opsys=bsd4-3 - ;; - np1-gould-bsd* ) - machine=gould-np1 opsys=bsd4-3 - ;; - - ## Harris Night Hawk machines running CX/UX (a 5000 looks just like a 4000 - ## as far as Emacs is concerned). - m88k-harris-cxux* ) - # Build needs to be different on 7.0 and later releases - case "`uname -r`" in - [56].[0-9] ) machine=nh4000 opsys=cxux ;; - [7].[0-9] ) machine=nh4000 opsys=cxux7 ;; - esac - NON_GNU_CPP="/lib/cpp" - ;; - ## Harris ecx or gcx running CX/UX (Series 1200, Series 3000) - m68k-harris-cxux* ) - machine=nh3000 opsys=cxux - ;; - ## Harris power pc NightHawk running Power UNIX (Series 6000) - powerpc-harris-powerunix ) - machine=nh6000 opsys=powerunix - NON_GNU_CPP="cc -Xo -E -P" - ;; - ## SR2001/SR2201 running HI-UX/MPP - hppa1.1-hitachi-hiuxmpp* ) - machine=sr2k opsys=hiuxmpp - ;; - hppa1.1-hitachi-hiuxwe2* ) - machine=sr2k opsys=hiuxwe2 - ;; - ## Honeywell XPS100 - xps*-honeywell-sysv* ) - machine=xps100 opsys=usg5-2 - ;; - ## HP 9000 series 200 or 300 m68*-hp-bsd* ) machine=hp9000s300 opsys=bsd4-3 @@ -2698,21 +2481,7 @@ _ACEOF machine=hp800 opsys=nextstep ;; - ## Orion machines - orion-orion-bsd* ) - machine=orion opsys=bsd4-2 - ;; - clipper-orion-bsd* ) - machine=orion105 opsys=bsd4-2 - ;; - ## IBM machines - i[3456]86-ibm-aix1.1* ) - machine=ibmps2-aix opsys=usg5-2-2 - ;; - i[3456]86-ibm-aix1.[23]* | i[3456]86-ibm-aix* ) - machine=ibmps2-aix opsys=usg5-3 - ;; i370-ibm-aix*) machine=ibm370aix opsys=usg5-3 ;; @@ -2749,64 +2518,12 @@ _ACEOF rs6000-ibm-aix* | powerpc-ibm-aix* ) machine=ibmrs6000 opsys=aix3-2 ;; - romp-ibm-bsd4.3* ) - machine=ibmrt opsys=bsd4-3 - ;; - romp-ibm-bsd4.2* ) - machine=ibmrt opsys=bsd4-2 - ;; - romp-ibm-aos4.3* ) - machine=ibmrt opsys=bsd4-3 - ;; - romp-ibm-aos4.2* ) - machine=ibmrt opsys=bsd4-2 - ;; - romp-ibm-aos* ) - machine=ibmrt opsys=bsd4-3 - ;; - romp-ibm-bsd* ) - machine=ibmrt opsys=bsd4-3 - ;; - romp-ibm-aix* ) - machine=ibmrt-aix opsys=usg5-2-2 - ;; - - ## Integrated Solutions `Optimum V' - m68*-isi-bsd4.2* ) - machine=isi-ov opsys=bsd4-2 - ;; - m68*-isi-bsd4.3* ) - machine=isi-ov opsys=bsd4-3 - ;; - - ## Intel 386 machines where we do care about the manufacturer - i[3456]86-intsys-sysv* ) - machine=is386 opsys=usg5-2-2 - ;; ## Prime EXL i[3456]86-prime-sysv* ) machine=i386 opsys=usg5-3 ;; - ## Sequent Symmetry running Dynix - i[3456]86-sequent-bsd* ) - machine=symmetry opsys=bsd4-3 - ;; - - ## Sequent Symmetry running ptx 4, which is a modified SVR4. - i[3456]86-sequent-ptx4* | i[3456]86-sequent-sysv4* ) - machine=sequent-ptx opsys=ptx4 - NON_GNU_CPP=/lib/cpp - ;; - - ## Sequent Symmetry running DYNIX/ptx - ## Use the old cpp rather than the newer ANSI one. - i[3456]86-sequent-ptx* ) - machine=sequent-ptx opsys=ptx - NON_GNU_CPP="/lib/cpp" - ;; - ## ncr machine running svr4.3. i[3456]86-ncr-sysv4.3 ) machine=ncr386 opsys=usg5-4-3 @@ -2818,33 +2535,11 @@ _ACEOF machine=ncr386 opsys=usg5-4-2 ;; - ## Intel Paragon OSF/1 - i860-intel-osf1* ) - machine=paragon opsys=osf1 NON_GNU_CPP=/usr/mach/lib/cpp - ;; - - ## Intel 860 - i860-*-sysv4* ) - machine=i860 opsys=usg5-4 - NON_GNU_CC="/bin/cc" # Ie, not the one in /usr/ucb/cc. - NON_GNU_CPP="/usr/ccs/lib/cpp" # cc -E tokenizes macro expansion. - ;; - ## Macintosh PowerPC powerpc*-*-linux-gnu* ) machine=macppc opsys=gnu-linux ;; - ## Masscomp machines - m68*-masscomp-rtu* ) - machine=masscomp opsys=rtu - ;; - - ## Megatest machines - m68*-megatest-bsd* ) - machine=mega68 opsys=bsd4-2 - ;; - ## Workstations sold by MIPS ## This is not necessarily all workstations using the MIPS processor - ## Irises are produced by SGI, and DECstations by DEC. @@ -2882,54 +2577,11 @@ _ACEOF machine=m68k opsys=nextstep ;; - ## The complete machine from National Semiconductor - ns32k-ns-genix* ) - machine=ns32000 opsys=usg5-2 - ;; - - ## NCR machines - m68*-ncr-sysv2* | m68*-ncr-sysvr2* ) - machine=tower32 opsys=usg5-2-2 - ;; - m68*-ncr-sysv3* | m68*-ncr-sysvr3* ) - machine=tower32v3 opsys=usg5-3 - ;; - ## NEC EWS4800 mips-nec-sysv4*) machine=ews4800 opsys=ux4800 ;; - ## Nixdorf Targon 31 - m68*-nixdorf-sysv* ) - machine=targon31 opsys=usg5-2-2 - ;; - - ## Nu (TI or LMI) - m68*-nu-sysv* ) - machine=nu opsys=usg5-2 - ;; - - ## Plexus - m68*-plexus-sysv* ) - machine=plexus opsys=usg5-2 - ;; - - ## Pyramid machines - ## I don't really have any idea what sort of processor the Pyramid has, - ## so I'm assuming it is its own architecture. - pyramid-pyramid-bsd* ) - machine=pyramid opsys=bsd4-2 - ;; - - ## Sequent Balance - ns32k-sequent-bsd4.2* ) - machine=sequent opsys=bsd4-2 - ;; - ns32k-sequent-bsd4.3* ) - machine=sequent opsys=bsd4-3 - ;; - ## Siemens Nixdorf mips-siemens-sysv* | mips-sni-sysv*) machine=mips-siemens opsys=usg5-4 @@ -2938,20 +2590,7 @@ _ACEOF ;; ## Silicon Graphics machines - ## Iris 2500 and Iris 2500 Turbo (aka the Iris 3030) - m68*-sgi-iris3.5* ) - machine=irist opsys=iris3-5 - ;; - m68*-sgi-iris3.6* | m68*-sgi-iris*) - machine=irist opsys=iris3-6 - ;; ## Iris 4D - mips-sgi-irix3* ) - machine=iris4d opsys=irix3-3 - ;; - mips-sgi-irix4* ) - machine=iris4d opsys=irix4-0 - ;; mips-sgi-irix6.5 ) machine=iris4d opsys=irix6-5 # Without defining _LANGUAGE_C, things get masked out in the headers @@ -2975,31 +2614,6 @@ _ACEOF machine=iris4d opsys=irix5-2 ;; - ## SONY machines - m68*-sony-bsd4.2* ) - machine=news opsys=bsd4-2 - ;; - m68*-sony-bsd4.3* ) - machine=news opsys=bsd4-3 - ;; - m68*-sony-newsos3* | m68*-sony-news3*) - machine=news opsys=bsd4-3 - ;; - mips-sony-bsd* | mips-sony-newsos4* | mips-sony-news4*) - machine=news-risc opsys=bsd4-3 - ;; - mips-sony-newsos6* ) - machine=news-r6 opsys=newsos6 - ;; - mips-sony-news* ) - machine=news-risc opsys=newsos5 - ;; - - ## Stride - m68*-stride-sysv* ) - machine=stride opsys=usg5-2 - ;; - ## Suns sparc-*-linux-gnu* | sparc64-*-linux-gnu* ) machine=sparc opsys=gnu-linux @@ -3009,10 +2623,6 @@ _ACEOF | i[3456]86-*-solaris2* | i[3456]86-*-sunos5* | powerpc*-*-solaris2* \ | rs6000-*-solaris2*) case "${canonical}" in - m68*-sunos1* ) machine=sun1 ;; - m68*-sunos2* ) machine=sun2 ;; - m68* ) machine=sun3 ;; - i[3456]86-sun-sunos[34]* ) machine=sun386 ;; i[3456]86-*-* ) machine=intel386 ;; amd64-*-*|x86_64-*-*) machine=amdx86-64 ;; powerpcle* ) machine=powerpcle ;; @@ -3021,26 +2631,6 @@ _ACEOF * ) unported=yes ;; esac case "${canonical}" in - ## The Sun386 didn't get past 4.0. - i[3456]86-*-sunos4 ) opsys=sunos4-0 ;; - *-sunos4.0* ) opsys=sunos4-0 ;; - *-sunos4.1.[3-9]*noshare ) - ## This name is sunos413 instead of sunos4-1-3 - ## to avoid a file name conflict on MSDOS. - opsys=sunos413 - NON_GNU_CPP=/usr/lib/cpp - NON_GCC_TEST_OPTIONS=-Bstatic - GCC_TEST_OPTIONS=-static - ;; - *-sunos4.1.[3-9]* | *-sunos4shr*) - opsys=sunos4shr - NON_GNU_CPP=/usr/lib/cpp - ;; - *-sunos4* | *-sunos ) - opsys=sunos4-1 - NON_GCC_TEST_OPTIONS=-Bstatic - GCC_TEST_OPTIONS=-static - ;; *-sunos5.3* | *-solaris2.3* ) opsys=sol2-3 NON_GNU_CPP=/usr/ccs/lib/cpp @@ -3083,50 +2673,11 @@ _ACEOF machine=sparc opsys=nextstep ;; - ## Tadpole 68k - m68*-tadpole-sysv* ) - machine=tad68k opsys=usg5-3 - ;; - - ## Tahoe machines - tahoe-tahoe-bsd4.2* ) - machine=tahoe opsys=bsd4-2 - ;; - tahoe-tahoe-bsd4.3* ) - machine=tahoe opsys=bsd4-3 - ;; - ## Tandem Integrity S2 mips-tandem-sysv* ) machine=tandem-s2 opsys=usg5-3 ;; - ## Tektronix XD88 - m88k-tektronix-sysv3* ) - machine=tekxd88 opsys=usg5-3 - ;; - - ## Tektronix 16000 box (6130?) - ns16k-tektronix-bsd* ) - machine=ns16000 opsys=bsd4-2 - ;; - ## Tektronix 4300 - ## src/m/tek4300.h hints that this is a m68k machine. - m68*-tektronix-bsd* ) - machine=tek4300 opsys=bsd4-3 - ;; - - ## Titan P2 or P3 - ## We seem to have lost the machine-description file titan.h! - titan-titan-sysv* ) - machine=titan opsys=usg5-3 - ;; - - ## Ustation E30 (SS5E) - m68*-unisys-uniplus* ) - machine=ustation opsystem=unipl5-2 - ;; - ## Vaxen. vax-dec-* ) machine=vax @@ -3141,18 +2692,6 @@ _ACEOF esac ;; - ## Whitechapel MG1 - ns16k-whitechapel-* ) - machine=mg1 - ## We don't know what sort of OS runs on these; we'll let the - ## operating system guessing code below try. - ;; - - ## Wicat - m68*-wicat-sysv* ) - machine=wicat opsys=usg5-2 - ;; - ## IA-64 ia64*-*-linux* ) machine=ia64 opsys=gnu-linux @@ -3166,25 +2705,8 @@ _ACEOF *-darwin* ) opsys=darwin CPP="${CC-cc} -E -no-cpp-precomp" ;; - *-isc1.* | *-isc2.[01]* ) opsys=386-ix ;; - *-isc2.2* ) opsys=isc2-2 ;; - *-isc4.0* ) opsys=isc4-0 ;; - *-isc4.* ) opsys=isc4-1 - GCC_TEST_OPTIONS=-posix - NON_GCC_TEST_OPTIONS=-Xp - ;; - *-isc* ) opsys=isc3-0 ;; - *-esix5* ) opsys=esix5r4; NON_GNU_CPP=/usr/lib/cpp ;; - *-esix* ) opsys=esix ;; *-xenix* ) opsys=xenix ;; *-linux-gnu* ) opsys=gnu-linux ;; - *-sco3.2v4* ) opsys=sco4 ; NON_GNU_CPP=/lib/cpp ;; - *-sco3.2v5* ) opsys=sco5 - NON_GNU_CPP=/lib/cpp - # Prevent -belf from being passed to $CPP. - # /lib/cpp does not accept it. - OVERRIDE_CPPFLAGS=" " - ;; *-sysv4.2uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;; *-sysv5uw* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;; *-sysv5OpenUNIX* ) opsys=unixware; NON_GNU_CPP=/lib/cpp ;; @@ -3211,11 +2733,6 @@ _ACEOF RANLIB="ar -ts" ;; - ## UXP/V - f301-fujitsu-uxpv4.1) - machine=f301 opsys=uxpv - ;; - ## AMD x86-64 Linux-based GNU system x86_64-*-linux-gnu* ) machine=amdx86-64 opsys=gnu-linux @@ -5993,14 +5510,14 @@ fi -### The standard library on x86-64 GNU/Linux distributions can +### The standard library on x86-64 and s390x GNU/Linux distributions can ### be located in either /usr/lib64 or /usr/lib. case "${canonical}" in - x86_64-*-linux-gnu* ) + x86_64-*-linux-gnu* | s390x-*-linux-gnu* ) if test -d /usr/lib64; then cat >>confdefs.h <<\_ACEOF -#define HAVE_X86_64_LIB64_DIR 1 +#define HAVE_LIB64_DIR 1 _ACEOF fi @@ -9767,22 +9284,6 @@ case ${HAVE_X11} in yes ) HAVE_MENUS=yes ;; esac -if test "${opsys}" = "hpux9"; then - case "${x_libraries}" in - *X11R4* ) - opsysfile="s/hpux9-x11r4.h" - ;; - esac -fi - -if test "${opsys}" = "hpux9shr"; then - case "${x_libraries}" in - *X11R4* ) - opsysfile="s/hpux9shxr4.h" - ;; - esac -fi - ### Compute the unexec source name from the object name. UNEXEC_SRC="`echo ${unexec} | sed 's/\.o/.c/'`" diff --git a/src/ChangeLog b/src/ChangeLog index 5e464404310..b641635484b 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,9 @@ +2008-01-17 Andreas Schwab + + * m/amdx86-64.h (START_FILES, LIB_STANDARD): Use HAVE_LIB64_DIR + instead of HAVE_X86_64_LIB64_DIR. + * m/ibms390x.h (START_FILES, LIB_STANDARD): Likewise. + 2008-01-17 Glenn Morris * m/ibms390x.h (START_FILES, LIB_STANDARD): Adjust value according diff --git a/src/config.in b/src/config.in index 27f89c29b90..7f1bdfd32c2 100644 --- a/src/config.in +++ b/src/config.in @@ -298,6 +298,9 @@ Boston, MA 02110-1301, USA. */ /* Define if you have and nl_langinfo(CODESET). */ #undef HAVE_LANGINFO_CODESET +/* Define to 1 if the directory /usr/lib64 exists. */ +#undef HAVE_LIB64_DIR + /* Define to 1 if you have the `com_err' library (-lcom_err). */ #undef HAVE_LIBCOM_ERR @@ -711,9 +714,6 @@ Boston, MA 02110-1301, USA. */ /* Define to 1 if you have the X11R6 or newer version of Xt. */ #undef HAVE_X11XTR6 -/* Define to 1 if the file /usr/lib64 exists. */ -#undef HAVE_X86_64_LIB64_DIR - /* Define to 1 if you have the Xaw3d library (-lXaw3d). */ #undef HAVE_XAW3D From 1f1d079727abfbea594068199fc11dcc75580c69 Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Thu, 17 Jan 2008 12:05:19 +0000 Subject: [PATCH 172/439] (use_file_dialog): Doc fix. --- src/fns.c | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/src/fns.c b/src/fns.c index 360501db80a..3f3cdccc36d 100644 --- a/src/fns.c +++ b/src/fns.c @@ -5828,9 +5828,10 @@ invoked by mouse clicks and mouse menu items. */); DEFVAR_BOOL ("use-file-dialog", &use_file_dialog, doc: /* *Non-nil means mouse commands use a file dialog to ask for files. -This applies to commands from menus and tool bar buttons. The value of -`use-dialog-box' takes precedence over this variable, so a file dialog is only -used if both `use-dialog-box' and this variable are non-nil. */); +This applies to commands from menus and tool bar buttons even when +they are initiated from the keyboard. The value of `use-dialog-box' +takes precedence over this variable, so a file dialog is only used if +both `use-dialog-box' and this variable are non-nil. */); use_file_dialog = 1; defsubr (&Sidentity); From 30d0ade9b8ccdcb6adfa65faf652ab9fb7fac2f0 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Thu, 17 Jan 2008 12:46:55 +0000 Subject: [PATCH 173/439] New file: blank-mode.el --- lisp/ChangeLog | 8 + lisp/blank-mode.el | 1281 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 1289 insertions(+) create mode 100644 lisp/blank-mode.el diff --git a/lisp/ChangeLog b/lisp/ChangeLog index fe334702fdb..58a6d361ab3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2008-01-17 Vinicius Jose Latorre +2008-01-17 Miles Bader + + * blank-mode.el: New file. Minor mode to visualise TAB, + (HARD) SPACE, NEWLINE. Miles Bader wrote the original + code for handling display table (via visws.el package), his code was + modified, but the main idea was kept. + 2008-01-17 Glenn Morris * ibuf-ext.el (ibuffer-auto-mode, ibuffer-save-filter-groups) diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el new file mode 100644 index 00000000000..ed235d5f531 --- /dev/null +++ b/lisp/blank-mode.el @@ -0,0 +1,1281 @@ +;;; blank-mode.el --- minor mode to visualise TAB, (HARD) SPACE, NEWLINE + +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 +;; Free Software Foundation, Inc. + +;; Author: Vinicius Jose Latorre +;; Maintainer: Vinicius Jose Latorre +;; Keywords: data, wp +;; Version: 8.0 +;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre + +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published +;; by the Free Software Foundation; either version 3, or (at your +;; option) any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. + +;;; Commentary: + +;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;; +;; Introduction +;; ------------ +;; +;; This package is a minor mode to visualise blanks (TAB, (HARD) SPACE +;; and NEWLINE). +;; +;; blank-mode uses two ways to visualise blanks: faces and display +;; table. +;; +;; * Faces are used to highlight the background with a color. +;; blank-mode uses font-lock to highlight blank characters. +;; +;; * Display table changes the way a character is displayed, that is, +;; it provides a visual mark for characters, for example, at the end +;; of line (?\xB6), at SPACEs (?\xB7) and at TABs (?\xBB). +;; +;; The `blank-style' and `blank-chars' variables are used to select +;; which way should be used to visualise blanks. +;; +;; Note that when blank-mode is turned on, blank-mode saves the +;; font-lock state, that is, if font-lock is on or off. And +;; blank-mode restores the font-lock state when it is turned off. So, +;; if blank-mode is turned on and font-lock is off, blank-mode also +;; turns on the font-lock to highlight blanks, but the font-lock will +;; be turned off when blank-mode is turned off. Thus, turn on +;; font-lock before blank-mode is on, if you want that font-lock +;; continues on after blank-mode is turned off. +;; +;; When blank-mode is on, it takes care of highlighting some special +;; characters over the default mechanism of `nobreak-char-display' +;; (which see) and `show-trailing-whitespace' (which see). +;; +;; There are two ways of using blank-mode: local and global. +;; +;; * Local blank-mode affects only the current buffer. +;; +;; * Global blank-mode affects all current and future buffers. That +;; is, if you turn on global blank-mode and then create a new +;; buffer, the new buffer will also have blank-mode on. The +;; `blank-global-modes' variable controls which major-mode will be +;; automagically turned on. +;; +;; You can mix the local and global usage without any conflict. But +;; local blank-mode has priority over global blank-mode. Blank mode +;; is active in a buffer if you have enabled it in that buffer or if +;; you have enabled it globally. +;; +;; When global and local blank-mode are on: +;; +;; * if local blank-mode is turned off, blank-mode is turned off for +;; the current buffer only. +;; +;; * if global blank-mode is turned off, blank-mode continues on only +;; in the buffers in which local blank-mode is on. +;; +;; To use blank-mode, insert in your ~/.emacs: +;; +;; (require 'blank-mode) +;; +;; Or autoload at least one of the commands`blank-mode', +;; `blank-toggle-options', `global-blank-mode' or +;; `global-blank-toggle-options'. For example: +;; +;; (autoload 'blank-mode "blank-mode" +;; "Toggle blank visualisation." t) +;; (autoload 'blank-toggle-options "blank-mode" +;; "Toggle local `blank-mode' options." t) +;; +;; blank-mode was inspired by: +;; +;; show-whitespace-mode.el Aurelien Tisne +;; Simple mode to highlight whitespaces +;; (inspired the idea to use font-lock) +;; +;; whitespace-mode.el Lawrence Mitchell +;; Major mode for editing Whitespace +;; (inspired the idea to use display table) +;; +;; visws.el Miles Bader +;; Make whitespace visible +;; (handle display table, his code was modified, but the main +;; idea was kept) +;; +;; +;; Using blank-mode +;; ---------------- +;; +;; There is no problem if you mix local and global minor mode usage. +;; +;; * LOCAL blank-mode: +;; + To toggle blank-mode options locally, type: +;; +;; M-x blank-toggle-options RET +;; +;; + To activate blank-mode locally, type: +;; +;; C-u 1 M-x blank-mode RET +;; +;; + To deactivate blank-mode locally, type: +;; +;; C-u 0 M-x blank-mode RET +;; +;; + To toggle blank-mode locally, type: +;; +;; M-x blank-mode RET +;; +;; * GLOBAL blank-mode: +;; + To toggle blank-mode options globally, type: +;; +;; M-x global-blank-toggle-options RET +;; +;; + To activate blank-mode globally, type: +;; +;; C-u 1 M-x global-blank-mode RET +;; +;; + To deactivate blank-mode globally, type: +;; +;; C-u 0 M-x global-blank-mode RET +;; +;; + To toggle blank-mode globally, type: +;; +;; M-x global-blank-mode RET +;; +;; +;; Hooks +;; ----- +;; +;; blank-mode has the following hook variables: +;; +;; `blank-mode-hook' +;; It is evaluated always when blank-mode is turned on locally. +;; +;; `global-blank-mode-hook' +;; It is evaluated always when blank-mode is turned on globally. +;; +;; `blank-load-hook' +;; It is evaluated after blank-mode package is loaded. +;; +;; +;; Options +;; ------- +;; +;; Below it's shown a brief description of blank-mode options, please, +;; see the options declaration in the code for a long documentation. +;; +;; `blank-style' Specify the visualisation style. +;; +;; `blank-chars' Specify which kind of blank is +;; visualised. +;; +;; `blank-space-face' Face used to visualise SPACE. +;; +;; `blank-hspace-face' Face used to visualise HARD SPACE. +;; +;; `blank-tab-face' Face used to visualise TAB. +;; +;; `blank-newline-face' Face used to visualise NEWLINE char +;; mapping. +;; +;; `blank-trailing-face' Face used to visualise trailing +;; blanks. +;; +;; `blank-line-face' Face used to visualise "long" lines. +;; +;; `blank-space-before-tab-face' Face used to visualise SPACEs +;; before TAB. +;; +;; `blank-space-regexp' Specify SPACE characters regexp. +;; +;; `blank-hspace-regexp' Specify HARD SPACE characters regexp. +;; +;; `blank-tab-regexp' Specify TAB characters regexp. +;; +;; `blank-trailing-regexp' Specify trailing characters regexp. +;; +;; `blank-space-before-tab-regexp' Specify SPACEs before TAB +;; regexp. +;; +;; `blank-line-length' Specify length beyond which the line +;; is highlighted. +;; +;; `blank-display-mappings' Specify an alist of mappings for +;; displaying characters. +;; +;; `blank-global-modes' Modes for which global `blank-mode' is +;; automagically turned on. +;; +;; +;; Acknowledgements +;; ---------------- +;; +;; Thanks to Juri Linkov for suggesting: +;; * `define-minor-mode'. +;; * `global-blank-*' name for global commands. +;; +;; Thanks to Robert J. Chassell for doc fix and testing. +;; +;; Thanks to Drew Adams for toggle commands +;; suggestion. +;; +;; Thanks to Antti Kaihola for +;; helping to fix `find-file-hooks' reference. +;; +;; Thanks to Andreas Roehler for +;; indicating defface byte-compilation warnings. +;; +;; Thanks to TimOCallaghan (EmacsWiki) for the idea about highlight +;; "long" lines. See EightyColumnRule (EmacsWiki). +;; +;; Thanks to Yanghui Bian for indicating a new +;; newline character mapping. +;; +;; Thanks to Pete Forman for indicating +;; whitespace-mode on XEmacs. +;; +;; Thanks to Miles Bader for handling display table via +;; visws.el (his code was modified, but the main idea was kept). +;; +;; Thanks to: +;; Aurelien Tisne show-whitespace-mode.el +;; Lawrence Mitchell whitespace-mode.el +;; Miles Bader visws.el +;; And to all people who contributed with them. +;; +;; +;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + +;;; code: + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; User Variables: + + +;;; Interface to the command system + + +(defgroup blank nil + "Visualise blanks (TAB, (HARD) SPACE and NEWLINE)." + :link '(emacs-library-link :tag "Source Lisp File" "blank-mode.el") + :version "22.2" + :group 'wp + :group 'data) + + +(defcustom blank-style '(mark color) + "*Specify the visualisation style. + +It's a list which element value can be: + + mark display mappings are visualised. + + color faces are visualised. + +Any other value is ignored. + +If it's nil, don't visualise TABs, (HARD) SPACEs and NEWLINEs. + +See also `blank-display-mappings' for documentation." + :type '(repeat :tag "Style of Blank" + (choice :tag "Style of Blank" + (const :tag "Display Table" mark) + (const :tag "Faces" color))) + :group 'blank) + + +(defcustom blank-chars + '(tabs spaces trailing lines space-before-tab newline) + "*Specify which kind of blank is visualised. + +It's a list which element value can be: + + trailing trailing blanks are visualised. + + tabs TABs are visualised. + + spaces SPACEs and HARD SPACEs are visualised. + + lines lines whose length is greater than + `blank-line-length' are highlighted. + + space-before-tab SPACEs before TAB are visualised. + + newline NEWLINEs are visualised. + +Any other element value is ignored. + +If it's nil, don't visualise TABs, (HARD) SPACEs and NEWLINEs. + +Used when `blank-style' has `color' as an element. +If `blank-chars' has `newline' as an element, used when `blank-style' +has `mark' as an element." + :type '(repeat :tag "Kind of Blank" + (choice :tag "Kind of Blank" + (const :tag "Trailing TABs, SPACEs and HARD SPACEs" + trailing) + (const :tag "SPACEs and HARD SPACEs" spaces) + (const :tag "TABs" tabs) + (const :tag "Lines" lines) + (const :tag "SPACEs before TAB" + space-before-tab) + (const :tag "NEWLINEs" newline))) + :group 'blank) + + +(defcustom blank-space-face 'blank-space-face + "*Symbol face used to visualise SPACE. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-space-face + '((((class color) (background dark)) + (:background "grey20" :foreground "aquamarine3")) + (((class color) (background light)) + (:background "LightYellow" :foreground "aquamarine3")) + (t (:inverse-video t))) + "Face used to visualise SPACE." + :group 'blank) + + +(defcustom blank-hspace-face 'blank-hspace-face + "*Symbol face used to visualise HARD SPACE. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-hspace-face ; 'nobreak-space + '((((class color) (background dark)) + (:background "grey24" :foreground "aquamarine3")) + (((class color) (background light)) + (:background "LemonChiffon3" :foreground "aquamarine3")) + (t (:inverse-video t))) + "Face used to visualise HARD SPACE." + :group 'blank) + + +(defcustom blank-tab-face 'blank-tab-face + "*Symbol face used to visualise TAB. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-tab-face + '((((class color) (background dark)) + (:background "grey22" :foreground "aquamarine3")) + (((class color) (background light)) + (:background "beige" :foreground "aquamarine3")) + (t (:inverse-video t))) + "Face used to visualise TAB." + :group 'blank) + + +(defcustom blank-newline-face 'blank-newline-face + "*Symbol face used to visualise NEWLINE char mapping. + +See `blank-display-mappings'. + +Used when `blank-style' has `mark' and `color' as elements +and `blank-chars' has `newline' as an element." + :type 'face + :group 'blank) + + +(defface blank-newline-face + '((((class color) (background dark)) + (:background "grey26" :foreground "aquamarine3" :bold t)) + (((class color) (background light)) + (:background "linen" :foreground "aquamarine3" :bold t)) + (t (:bold t :underline t))) + "Face used to visualise NEWLINE char mapping. + +See `blank-display-mappings'." + :group 'blank) + + +(defcustom blank-trailing-face 'blank-trailing-face + "*Symbol face used to visualise traling blanks. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-trailing-face ; 'trailing-whitespace + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "red1" :foreground "yellow" :bold t))) + "Face used to visualise trailing blanks." + :group 'blank) + + +(defcustom blank-line-face 'blank-line-face + "*Symbol face used to visualise \"long\" lines. + +See `blank-line-legnth'. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-line-face + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "gray20" :foreground "violet"))) + "Face used to visualise \"long\" lines. + +See `blank-line-length'." + :group 'blank) + + +(defcustom blank-space-before-tab-face 'blank-space-before-tab-face + "*Symbol face used to visualise SPACEs before TAB. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-space-before-tab-face + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "DarkOrange" :foreground "firebrick"))) + "Face used to visualise SPACEs before TAB." + :group 'blank) + + +(defcustom blank-hspace-regexp + "\\(\\(\xA0\\|\x8A0\\|\x920\\|\xE20\\|\xF20\\)+\\)" + "*Specify HARD SPACE characters regexp. + +If you're using `mule' package, it may exist other characters besides: + + \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \"\\xF20\" + +that it should be considered HARD SPACE. + +Here are some examples: + + \"\\\\(^\\xA0+\\\\)\" \ +visualise only leading HARD SPACEs. + \"\\\\(\\xA0+$\\\\)\" \ +visualise only trailing HARD SPACEs. + \"\\\\(^\\xA0+\\\\|\\xA0+$\\\\)\" \ +visualise leading and/or trailing HARD SPACEs. + \"\\t\\\\(\\xA0+\\\\)\\t\" \ +visualise only HARD SPACEs between TABs. + +NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. + Use exactly one pair of enclosing \\\\( and \\\\). + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `spaces' as an element." + :type '(regexp :tag "HARD SPACE Chars") + :group 'blank) + + +(defcustom blank-space-regexp "\\( +\\)" + "*Specify SPACE characters regexp. + +If you're using `mule' package, it may exist other characters +besides \" \" that it should be considered SPACE. + +Here are some examples: + + \"\\\\(^ +\\\\)\" visualise only leading SPACEs. + \"\\\\( +$\\\\)\" visualise only trailing SPACEs. + \"\\\\(^ +\\\\| +$\\\\)\" \ +visualise leading and/or trailing SPACEs. + \"\\t\\\\( +\\\\)\\t\" visualise only SPACEs between TABs. + +NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. + Use exactly one pair of enclosing \\\\( and \\\\). + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `spaces' as an element." + :type '(regexp :tag "SPACE Chars") + :group 'blank) + + +(defcustom blank-tab-regexp "\\(\t+\\)" + "*Specify TAB characters regexp. + +If you're using `mule' package, it may exist other characters +besides \"\\t\" that it should be considered TAB. + +Here are some examples: + + \"\\\\(^\\t+\\\\)\" visualise only leading TABs. + \"\\\\(\\t+$\\\\)\" visualise only trailing TABs. + \"\\\\(^\\t+\\\\|\\t+$\\\\)\" \ +visualise leading and/or trailing TABs. + \" \\\\(\\t+\\\\) \" visualise only TABs between SPACEs. + +NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. + Use exactly one pair of enclosing \\\\( and \\\\). + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `tabs' as an element." + :type '(regexp :tag "TAB Chars") + :group 'blank) + + +(defcustom blank-trailing-regexp + "\t\\| \\|\xA0\\|\x8A0\\|\x920\\|\xE20\\|\xF20" + "*Specify trailing characters regexp. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that it should be considered blank. + +NOTE: DOES NOT enclose by \\\\( and \\\\) the elements to highlight. + `blank-mode' surrounds this regexp by \"\\\\(\\\\(\" and + \"\\\\)+\\\\)$\". + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `trailing' as an element." + :type '(regexp :tag "Trailing Chars") + :group 'blank) + + +(defcustom blank-space-before-tab-regexp "\\( +\\)\t" + "*Specify SPACEs before TAB regexp. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that it should be considered blank. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `space-before-tab' as an element." + :type '(regexp :tag "SPACEs Before TAB") + :group 'blank) + + +(defcustom blank-line-length 80 + "*Specify length beyond which the line is highlighted. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `lines' as an element." + :type '(integer :tag "Line Length") + :group 'blank) + + +;; Hacked from `visible-whitespace-mappings' in visws.el +(defcustom blank-display-mappings + ;; Due to limitations of glyph representation, the char code can not + ;; be above ?\x1FFFF. Probably, this will be fixed after Emacs + ;; unicode merging. + '( + (?\ [?\xB7] [?.]) ; space - centered dot + (?\xA0 [?\xA4] [?_]) ; hard space - currency + (?\x8A0 [?\x8A4] [?_]) ; hard space - currency + (?\x920 [?\x924] [?_]) ; hard space - currency + (?\xE20 [?\xE24] [?_]) ; hard space - currency + (?\xF20 [?\xF24] [?_]) ; hard space - currency + ;; NEWLINE is displayed using the face `blank-newline-face' + (?\n [?$ ?\n]) ; end-of-line - dollar sign + ;; (?\n [?\u21B5 ?\n] [?$ ?\n]) ; end-of-line - downwards arrow + ;; (?\n [?\xB6 ?\n] [?$ ?\n]) ; end-of-line - pilcrow + ;; (?\n [?\x8AF ?\n] [?$ ?\n]) ; end-of-line - overscore + ;; (?\n [?\x8AC ?\n] [?$ ?\n]) ; end-of-line - negation + ;; (?\n [?\x8B0 ?\n] [?$ ?\n]) ; end-of-line - grade + ;; + ;; WARNING: the mapping below has a problem. + ;; When a TAB occupies exactly one column, it will display the + ;; character ?\xBB at that column followed by a TAB which goes to + ;; the next TAB column. + ;; If this is a problem for you, please, comment the line below. + (?\t [?\xBB ?\t] [?\\ ?\t]) ; tab - left quote mark + ) + "*Specify an alist of mappings for displaying characters. + +Each element has the following form: + + (CHAR VECTOR...) + +Where: + +CHAR is the character to be mapped. + +VECTOR is a vector of characters to be displayed in place of CHAR. + The first display vector that can be displayed is used; + if no display vector for a mapping can be displayed, then + that character is displayed unmodified. + +The NEWLINE character is displayed using the face given by +`blank-newline-face' variable. The characters in the vector to be +displayed will not have applied this face if the character code is +above #x1FFFF. + +Used when `blank-style' has `mark' as an element." + :type '(repeat + (list :tag "Character Mapping" + (character :tag "Char") + (repeat :inline t :tag "Vector List" + (vector :tag "" + (repeat :inline t + :tag "Vector Characters" + (character :tag "Char")))))) + :group 'blank) + + +(defcustom blank-global-modes t + "*Modes for which global `blank-mode' is automagically turned on. + +Global `blank-mode' is controlled by the command `global-blank-mode'. + +If nil, means no modes have `blank-mode' automatically turned on. +If t, all modes that support `blank-mode' have it automatically +turned on. +If a list, it should be a list of `major-mode' symbol names for +which `blank-mode' should be automatically turned on. The sense +of the list is negated if it begins with `not'. For example: + + (c-mode c++-mode) + +means that `blank-mode' is turned on for buffers in C and C++ +modes only." + :type '(choice (const :tag "none" nil) + (const :tag "all" t) + (set :menu-tag "mode specific" :tag "modes" + :value (not) + (const :tag "Except" not) + (repeat :inline t + (symbol :tag "mode")))) + :group 'blank) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; User commands - Local mode + + +;;;###autoload +(define-minor-mode blank-mode + "Toggle blank minor mode visualisation (bl on modeline). + +If ARG is null, toggle blank visualisation. +If ARG is a number and is greater than zero, turn on +visualisation; otherwise, turn off visualisation. +Only useful with a windowing system." + :lighter " bl" + :init-value nil + :global nil + :group 'blank + (cond + (noninteractive ; running a batch job + (setq blank-mode nil)) + (blank-mode ; blank-mode on + (blank-turn-on)) + (t ; blank-mode off + (blank-turn-off)))) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; User commands - Global mode + + +(define-minor-mode global-blank-mode + "Toggle blank global minor mode visualisation (BL on modeline). + +If ARG is null, toggle blank visualisation. +If ARG is a number and is greater than zero, turn on +visualisation; otherwise, turn off visualisation. +Only useful with a windowing system." + :lighter " BL" + :init-value nil + :global t + :group 'blank + (cond + (noninteractive ; running a batch job + (setq global-blank-mode nil)) + (global-blank-mode ; global-blank-mode on + (save-excursion + (if (boundp 'find-file-hook) + (add-hook 'find-file-hook 'blank-turn-on-if-enabled t) + (add-hook 'find-file-hooks 'blank-turn-on-if-enabled t)) + (dolist (buffer (buffer-list)) ; adjust all local mode + (set-buffer buffer) + (unless blank-mode + (blank-turn-on-if-enabled))))) + (t ; global-blank-mode off + (save-excursion + (if (boundp 'find-file-hook) + (remove-hook 'find-file-hook 'blank-turn-on-if-enabled) + (remove-hook 'find-file-hooks 'blank-turn-on-if-enabled)) + (dolist (buffer (buffer-list)) ; adjust all local mode + (set-buffer buffer) + (unless blank-mode + (blank-turn-off))))))) + + +(defun blank-turn-on-if-enabled () + (when (cond + ((eq blank-global-modes t)) + ((listp blank-global-modes) + (if (eq (car-safe blank-global-modes) 'not) + (not (memq major-mode (cdr blank-global-modes))) + (memq major-mode blank-global-modes))) + (t nil)) + (let (inhibit-quit) + ;; Don't turn on blank mode if... + (or + ;; ...we don't have a display (we're running a batch job) + noninteractive + ;; ...or if the buffer is invisible (name starts with a space) + (eq (aref (buffer-name) 0) ?\ ) + ;; ...or if the buffer is temporary (name starts with *) + (and (eq (aref (buffer-name) 0) ?*) + ;; except the scratch buffer. + (not (string= (buffer-name) "*scratch*"))) + ;; Otherwise, turn on blank mode. + (blank-turn-on))))) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; User commands - Toggle + + +(defconst blank-chars-value-list + '(tabs + spaces + trailing + space-before-tab + lines + newline + ) + "List of valid `blank-chars' value.") + + +(defconst blank-style-value-list + '(color + mark + ) + "List of valid `blank-style' value.") + + +(defconst blank-toggle-option-alist + '((?t . tabs) + (?s . spaces) + (?r . trailing) + (?b . space-before-tab) + (?l . lines) + (?n . newline) + (?c . color) + (?m . mark) + (?x . blank-chars) + (?z . blank-style) + ) + "Alist of toggle options. + +Each element has the form: + + (CHAR . SYMBOL) + +Where: + +CHAR is a char which the user will have to type. + +SYMBOL is a valid symbol associated with CHAR. + See `blank-chars-value-list' and `blank-style-value-list'.") + + +(defvar blank-active-chars nil + "Used to save locally `blank-chars' value.") +(make-variable-buffer-local 'blank-active-chars) + +(defvar blank-active-style nil + "Used to save locally `blank-style' value.") +(make-variable-buffer-local 'blank-active-style) + + +;;;###autoload +(defun blank-toggle-options (arg) + "Toggle local `blank-mode' options. + +If local blank-mode is off, toggle the option given by ARG and +turn on local blank-mode. + +If local blank-mode is on, toggle the option given by ARG and +restart local blank-mode. + +Interactively, it reads one of the following chars: + + CHAR MEANING + t toggle TAB visualisation + s toggle SPACE and HARD SPACE visualisation + r toggle trailing blanks visualisation + b toggle SPACEs before TAB visualisation + l toggle \"long lines\" visualisation + n toggle NEWLINE visualisation + c toggle color faces + m toggle visual mark + x restore `blank-chars' value + z restore `blank-style' value + ? display brief help + +Non-interactively, ARG should be a symbol or a list of symbol. +The valid symbols are: + + tabs toggle TAB visualisation + spaces toggle SPACE and HARD SPACE visualisation + trailing toggle trailing blanks visualisation + space-before-tab toggle SPACEs before TAB visualisation + lines toggle \"long lines\" visualisation + newline toggle NEWLINE visualisation + color toggle color faces + mark toggle visual mark + blank-chars restore `blank-chars' value + blank-style restore `blank-style' value + +Only useful with a windowing system." + (interactive (blank-interactive-char t)) + (let ((blank-chars + (blank-toggle-list t arg blank-active-chars blank-chars + 'blank-chars blank-chars-value-list)) + (blank-style + (blank-toggle-list t arg blank-active-style blank-style + 'blank-style blank-style-value-list))) + (blank-mode 0) + (blank-mode 1))) + + +(defvar blank-toggle-chars nil + "Used to toggle the global `blank-chars' value.") +(defvar blank-toggle-style nil + "Used to toggle the global `blank-style' value.") + + +;;;###autoload +(defun global-blank-toggle-options (arg) + "Toggle global `blank-mode' options. + +If global blank-mode is off, toggle the option given by ARG and +turn on global blank-mode. + +If global blank-mode is on, toggle the option given by ARG and +restart global blank-mode. + +Interactively, it reads one of the following chars: + + CHAR MEANING + t toggle TAB visualisation + s toggle SPACE and HARD SPACE visualisation + r toggle trailing blanks visualisation + b toggle SPACEs before TAB visualisation + l toggle \"long lines\" visualisation + n toggle NEWLINE visualisation + c toggle color faces + m toggle visual mark + x restore `blank-chars' value + z restore `blank-style' value + ? display brief help + +Non-interactively, ARG should be a symbol or a list of symbol. +The valid symbols are: + + tabs toggle TAB visualisation + spaces toggle SPACE and HARD SPACE visualisation + trailing toggle trailing blanks visualisation + space-before-tab toggle SPACEs before TAB visualisation + lines toggle \"long lines\" visualisation + newline toggle NEWLINE visualisation + color toggle color faces + mark toggle visual mark + blank-chars restore `blank-chars' value + blank-style restore `blank-style' value + +Only useful with a windowing system." + (interactive (blank-interactive-char nil)) + (let ((blank-chars + (blank-toggle-list nil arg blank-toggle-chars blank-chars + 'blank-chars blank-chars-value-list)) + (blank-style + (blank-toggle-list nil arg blank-toggle-style blank-style + 'blank-style blank-style-value-list))) + (setq blank-toggle-chars blank-chars + blank-toggle-style blank-style) + (global-blank-mode 0) + (global-blank-mode 1))) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; Internal functions + + +(defvar blank-font-lock-mode nil + "Used to remember whether a buffer had font lock mode on or not.") +(make-variable-buffer-local 'blank-font-lock-mode) + +(defvar blank-font-lock nil + "Used to remember whether a buffer initially had font lock on or not.") +(make-variable-buffer-local 'blank-font-lock) + +(defvar blank-font-lock-keywords nil + "Used to save locally `font-lock-keywords' value.") +(make-variable-buffer-local 'blank-font-lock-keywords) + + +(defconst blank-help-text + "\ + blank-mode toggle options: + + [] t - toggle TAB visualisation + [] s - toggle SPACE and HARD SPACE visualisation + [] r - toggle trailing blanks visualisation + [] b - toggle SPACEs before TAB visualisation + [] l - toggle \"long lines\" visualisation + [] n - toggle NEWLINE visualisation + + [] c - toggle color faces + [] m - toggle visual mark + + x - restore `blank-chars' value + z - restore `blank-style' value + + ? - display this text\n\n" + "Text for blank toggle options.") + + +(defconst blank-help-buffer-name "*Blank Toggle Options*" + "The buffer name for blank toggle options.") + + +(defun blank-insert-option-mark (the-list the-value) + "Insert the option mark ('X' or ' ') in toggle options buffer." + (forward-line 1) + (dolist (sym the-list) + (forward-line 1) + (forward-char 2) + (insert (if (memq sym the-value) "X" " ")))) + + +(defun blank-help-on (chars style) + "Display the blank toggle options." + (unless (get-buffer blank-help-buffer-name) + (delete-other-windows) + (let ((buffer (get-buffer-create blank-help-buffer-name))) + (save-excursion + (set-buffer buffer) + (erase-buffer) + (insert blank-help-text) + (goto-char (point-min)) + (blank-insert-option-mark blank-chars-value-list chars) + (blank-insert-option-mark blank-style-value-list style) + (goto-char (point-min)) + (set-buffer-modified-p nil) + (let ((size (- (window-height) + (max window-min-height + (1+ (count-lines (point-min) (point-max))))))) + (when (<= size 0) + (kill-buffer buffer) + (error "Frame height is too small; \ +can't split window to display blank toggle options")) + (set-window-buffer (split-window nil size) buffer)))))) + + +(defun blank-help-off () + "Remove the buffer and window of the blank toggle options." + (let ((buffer (get-buffer blank-help-buffer-name))) + (when buffer + (delete-windows-on buffer) + (kill-buffer buffer)))) + + +(defun blank-interactive-char (local-p) + "Interactive function to read a char and return a symbol. + +If LOCAL-P is non-nil, it uses a local context; otherwise, it +uses a global context. + +It reads one of the following chars: + + CHAR MEANING + t toggle TAB visualisation + s toggle SPACE and HARD SPACE visualisation + r toggle trailing blanks visualisation + b toggle SPACEs before TAB visualisation + l toggle \"long lines\" visualisation + n toggle NEWLINE visualisation + c toggle color faces + m toggle visual mark + x restore `blank-chars' value + z restore `blank-style' value + ? display brief help + +See also `blank-toggle-option-alist'." + (let* ((is-off (not (if local-p blank-mode global-blank-mode))) + (chars (cond (is-off blank-chars) ; use default value + (local-p blank-active-chars) + (t blank-toggle-chars))) + (style (cond (is-off blank-style) ; use default value + (local-p blank-active-style) + (t blank-toggle-style))) + (prompt + (format "Blank Toggle %s (type ? for further options)-" + (if local-p "Local" "Global"))) + ch sym) + ;; read a valid option and get the corresponding symbol + (save-window-excursion + (condition-case data + (progn + (while + ;; while condition + (progn + (setq ch (read-char prompt)) + (not + (setq sym + (cdr (assq ch blank-toggle-option-alist))))) + ;; while body + (if (eq ch ?\?) + (blank-help-on chars style) + (ding))) + (blank-help-off) + (message " ")) ; clean echo area + ;; handler + ((quit error) + (blank-help-off) + (error (error-message-string data))))) + (list sym))) ; return the apropriate symbol + + +(defun blank-toggle-list (local-p arg the-list default-list + sym-restore sym-list) + "Toggle options in THE-LIST based on list ARG. + +If LOCAL-P is non-nil, it uses a local context; otherwise, it +uses a global context. + +ARG is a list of options to be toggled. + +THE-LIST is a list of options. This list will be toggled and the +resultant list will be returned. + +DEFAULT-LIST is the default list of options. It is used to +restore the options in THE-LIST. + +SYM-RESTORE is the symbol which indicates to restore the options +in THE-LIST. + +SYM-LIST is a list of valid options, used to check if the ARG's +options are valid." + (unless (if local-p blank-mode global-blank-mode) + (setq the-list default-list)) + (setq the-list (copy-sequence the-list)) ; keep original list + (dolist (sym (if (listp arg) arg (list arg))) + (cond + ;; restore default values + ((eq sym sym-restore) + (setq the-list default-list)) + ;; toggle valid values + ((memq sym sym-list) + (setq the-list (if (memq sym the-list) + (delq sym the-list) + (cons sym the-list)))))) + the-list) + + +(defun blank-turn-on () + "Turn on blank visualisation." + (setq blank-active-style (if (listp blank-style) + blank-style + (list blank-style))) + (setq blank-active-chars (if (listp blank-chars) + blank-chars + (list blank-chars))) + (and (memq 'color blank-active-style) + (blank-color-on)) + (and (memq 'mark blank-active-style) + (blank-display-char-on))) + + +(defun blank-turn-off () + "Turn off blank visualisation." + (and (memq 'color blank-active-style) + (blank-color-off)) + (and (memq 'mark blank-active-style) + (blank-display-char-off))) + + +(defun blank-color-on () + "Turn on color visualisation." + (when blank-active-chars + (unless blank-font-lock + (setq blank-font-lock t + blank-font-lock-keywords + (copy-sequence font-lock-keywords))) + ;; turn off font lock + (setq blank-font-lock-mode font-lock-mode) + (font-lock-mode 0) + ;; add blank-mode color into font lock + (when (memq 'spaces blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show SPACEs + (list blank-space-regexp 1 blank-space-face t) + ;; Show HARD SPACEs + (list blank-hspace-regexp 1 blank-hspace-face t)) + t)) + (when (memq 'tabs blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show TABs + (list blank-tab-regexp 1 blank-tab-face t)) + t)) + (when (memq 'trailing blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show trailing blanks + (list (concat "\\(\\(" blank-trailing-regexp "\\)+\\)$") + 1 blank-trailing-face t)) + t)) + (when (memq 'lines blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show "long" lines + (list (concat "^\\(.\\{" (int-to-string blank-line-length) + ",\\}\\)$") + 1 blank-line-face t)) + t)) + (when (memq 'space-before-tab blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show SPACEs before TAB + (list blank-space-before-tab-regexp + 1 blank-space-before-tab-face t)) + t)) + ;; now turn on font lock and highlight blanks + (font-lock-mode 1))) + + +(defun blank-color-off () + "Turn off color visualisation." + (when blank-active-chars + (when blank-font-lock + (setq blank-font-lock nil + font-lock-keywords blank-font-lock-keywords)) + ;; turn off font lock + (font-lock-mode 0) + ;; restore original font lock state + (font-lock-mode blank-font-lock-mode))) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; Hacked from visws.el (Miles Bader ) + + +(defvar blank-display-table nil + "Used to save a local display table.") +(make-variable-buffer-local 'blank-display-table) + +(defvar blank-display-table-was-local nil + "Used to remember whether a buffer initially had a local display table or not.") +(make-variable-buffer-local 'blank-display-table-was-local) + + +(defsubst blank-char-valid-p (char) + ;; This check should be improved!!! + (or (< char 256) + (char-valid-p char))) + + +(defun blank-legal-display-vector-p (vec) + "Return true if every character in vector VEC can be displayed." + (let ((i (length vec))) + (when (> i 0) + (while (and (>= (setq i (1- i)) 0) + (blank-char-valid-p (aref vec i)))) + (< i 0)))) + + +(defun blank-display-char-on () + "Turn on character display mapping." + (when blank-display-mappings + (let (vecs vec) + ;; Remember whether a buffer has a local display table. + (unless blank-display-table-was-local + (setq blank-display-table-was-local t + blank-display-table + (copy-sequence buffer-display-table))) + (unless buffer-display-table + (setq buffer-display-table (make-display-table))) + (dolist (entry blank-display-mappings) + (setq vecs (cdr entry)) + ;; Get a displayable mapping. + (while (and vecs + (not (blank-legal-display-vector-p (car vecs)))) + (setq vecs (cdr vecs))) + ;; Display a valid mapping. + (when vecs + (setq vec (copy-sequence (car vecs))) + (cond + ;; Any char except newline + ((not (eq (car entry) ?\n)) + (aset buffer-display-table (car entry) vec)) + ;; Newline char - display it + ((memq 'newline blank-active-chars) + ;; Only insert face bits on NEWLINE char mapping to avoid + ;; obstruction of other faces like TABs and (HARD) SPACEs + ;; faces, font-lock faces, etc. + (when (memq 'color blank-active-style) + (dotimes (i (length vec)) + ;; Due to limitations of glyph representation, the char + ;; code can not be above ?\x1FFFF. Probably, this will + ;; be fixed after Emacs unicode merging. + (or (eq (aref vec i) ?\n) + (> (aref vec i) #x1FFFF) + (aset vec i (make-glyph-code (aref vec i) + blank-newline-face))))) + ;; Display mapping + (aset buffer-display-table (car entry) vec)) + ;; Newline char - don't display it + (t + ;; Do nothing + ))))))) + + +(defun blank-display-char-off () + "Turn off character display mapping." + (and blank-display-mappings + blank-display-table-was-local + (setq blank-display-table-was-local nil + buffer-display-table blank-display-table))) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + + +(provide 'blank-mode) + + +(run-hooks 'blank-load-hook) + + +;;; blank-mode.el ends here From 5ba43af2c2aa0653a6a0f3413b9e35cd16ccb7be Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Thu, 17 Jan 2008 12:48:41 +0000 Subject: [PATCH 174/439] New file: blank-mode.el --- lisp/ChangeLog | 8 + lisp/blank-mode.el | 1281 ++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 1289 insertions(+) create mode 100644 lisp/blank-mode.el diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c497286f4ea..ee05404c36a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2008-01-17 Vinicius Jose Latorre +2008-01-17 Miles Bader + + * blank-mode.el: New file. Minor mode to visualise TAB, + (HARD) SPACE, NEWLINE. Miles Bader wrote the original + code for handling display table (via visws.el package), his code was + modified, but the main idea was kept. + 2008-01-16 Alan Mackenzie * progmodes/cc-vars.el (c-constant-symbol): Put this defun inside diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el new file mode 100644 index 00000000000..ed235d5f531 --- /dev/null +++ b/lisp/blank-mode.el @@ -0,0 +1,1281 @@ +;;; blank-mode.el --- minor mode to visualise TAB, (HARD) SPACE, NEWLINE + +;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 +;; Free Software Foundation, Inc. + +;; Author: Vinicius Jose Latorre +;; Maintainer: Vinicius Jose Latorre +;; Keywords: data, wp +;; Version: 8.0 +;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre + +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published +;; by the Free Software Foundation; either version 3, or (at your +;; option) any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. + +;;; Commentary: + +;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;; +;; Introduction +;; ------------ +;; +;; This package is a minor mode to visualise blanks (TAB, (HARD) SPACE +;; and NEWLINE). +;; +;; blank-mode uses two ways to visualise blanks: faces and display +;; table. +;; +;; * Faces are used to highlight the background with a color. +;; blank-mode uses font-lock to highlight blank characters. +;; +;; * Display table changes the way a character is displayed, that is, +;; it provides a visual mark for characters, for example, at the end +;; of line (?\xB6), at SPACEs (?\xB7) and at TABs (?\xBB). +;; +;; The `blank-style' and `blank-chars' variables are used to select +;; which way should be used to visualise blanks. +;; +;; Note that when blank-mode is turned on, blank-mode saves the +;; font-lock state, that is, if font-lock is on or off. And +;; blank-mode restores the font-lock state when it is turned off. So, +;; if blank-mode is turned on and font-lock is off, blank-mode also +;; turns on the font-lock to highlight blanks, but the font-lock will +;; be turned off when blank-mode is turned off. Thus, turn on +;; font-lock before blank-mode is on, if you want that font-lock +;; continues on after blank-mode is turned off. +;; +;; When blank-mode is on, it takes care of highlighting some special +;; characters over the default mechanism of `nobreak-char-display' +;; (which see) and `show-trailing-whitespace' (which see). +;; +;; There are two ways of using blank-mode: local and global. +;; +;; * Local blank-mode affects only the current buffer. +;; +;; * Global blank-mode affects all current and future buffers. That +;; is, if you turn on global blank-mode and then create a new +;; buffer, the new buffer will also have blank-mode on. The +;; `blank-global-modes' variable controls which major-mode will be +;; automagically turned on. +;; +;; You can mix the local and global usage without any conflict. But +;; local blank-mode has priority over global blank-mode. Blank mode +;; is active in a buffer if you have enabled it in that buffer or if +;; you have enabled it globally. +;; +;; When global and local blank-mode are on: +;; +;; * if local blank-mode is turned off, blank-mode is turned off for +;; the current buffer only. +;; +;; * if global blank-mode is turned off, blank-mode continues on only +;; in the buffers in which local blank-mode is on. +;; +;; To use blank-mode, insert in your ~/.emacs: +;; +;; (require 'blank-mode) +;; +;; Or autoload at least one of the commands`blank-mode', +;; `blank-toggle-options', `global-blank-mode' or +;; `global-blank-toggle-options'. For example: +;; +;; (autoload 'blank-mode "blank-mode" +;; "Toggle blank visualisation." t) +;; (autoload 'blank-toggle-options "blank-mode" +;; "Toggle local `blank-mode' options." t) +;; +;; blank-mode was inspired by: +;; +;; show-whitespace-mode.el Aurelien Tisne +;; Simple mode to highlight whitespaces +;; (inspired the idea to use font-lock) +;; +;; whitespace-mode.el Lawrence Mitchell +;; Major mode for editing Whitespace +;; (inspired the idea to use display table) +;; +;; visws.el Miles Bader +;; Make whitespace visible +;; (handle display table, his code was modified, but the main +;; idea was kept) +;; +;; +;; Using blank-mode +;; ---------------- +;; +;; There is no problem if you mix local and global minor mode usage. +;; +;; * LOCAL blank-mode: +;; + To toggle blank-mode options locally, type: +;; +;; M-x blank-toggle-options RET +;; +;; + To activate blank-mode locally, type: +;; +;; C-u 1 M-x blank-mode RET +;; +;; + To deactivate blank-mode locally, type: +;; +;; C-u 0 M-x blank-mode RET +;; +;; + To toggle blank-mode locally, type: +;; +;; M-x blank-mode RET +;; +;; * GLOBAL blank-mode: +;; + To toggle blank-mode options globally, type: +;; +;; M-x global-blank-toggle-options RET +;; +;; + To activate blank-mode globally, type: +;; +;; C-u 1 M-x global-blank-mode RET +;; +;; + To deactivate blank-mode globally, type: +;; +;; C-u 0 M-x global-blank-mode RET +;; +;; + To toggle blank-mode globally, type: +;; +;; M-x global-blank-mode RET +;; +;; +;; Hooks +;; ----- +;; +;; blank-mode has the following hook variables: +;; +;; `blank-mode-hook' +;; It is evaluated always when blank-mode is turned on locally. +;; +;; `global-blank-mode-hook' +;; It is evaluated always when blank-mode is turned on globally. +;; +;; `blank-load-hook' +;; It is evaluated after blank-mode package is loaded. +;; +;; +;; Options +;; ------- +;; +;; Below it's shown a brief description of blank-mode options, please, +;; see the options declaration in the code for a long documentation. +;; +;; `blank-style' Specify the visualisation style. +;; +;; `blank-chars' Specify which kind of blank is +;; visualised. +;; +;; `blank-space-face' Face used to visualise SPACE. +;; +;; `blank-hspace-face' Face used to visualise HARD SPACE. +;; +;; `blank-tab-face' Face used to visualise TAB. +;; +;; `blank-newline-face' Face used to visualise NEWLINE char +;; mapping. +;; +;; `blank-trailing-face' Face used to visualise trailing +;; blanks. +;; +;; `blank-line-face' Face used to visualise "long" lines. +;; +;; `blank-space-before-tab-face' Face used to visualise SPACEs +;; before TAB. +;; +;; `blank-space-regexp' Specify SPACE characters regexp. +;; +;; `blank-hspace-regexp' Specify HARD SPACE characters regexp. +;; +;; `blank-tab-regexp' Specify TAB characters regexp. +;; +;; `blank-trailing-regexp' Specify trailing characters regexp. +;; +;; `blank-space-before-tab-regexp' Specify SPACEs before TAB +;; regexp. +;; +;; `blank-line-length' Specify length beyond which the line +;; is highlighted. +;; +;; `blank-display-mappings' Specify an alist of mappings for +;; displaying characters. +;; +;; `blank-global-modes' Modes for which global `blank-mode' is +;; automagically turned on. +;; +;; +;; Acknowledgements +;; ---------------- +;; +;; Thanks to Juri Linkov for suggesting: +;; * `define-minor-mode'. +;; * `global-blank-*' name for global commands. +;; +;; Thanks to Robert J. Chassell for doc fix and testing. +;; +;; Thanks to Drew Adams for toggle commands +;; suggestion. +;; +;; Thanks to Antti Kaihola for +;; helping to fix `find-file-hooks' reference. +;; +;; Thanks to Andreas Roehler for +;; indicating defface byte-compilation warnings. +;; +;; Thanks to TimOCallaghan (EmacsWiki) for the idea about highlight +;; "long" lines. See EightyColumnRule (EmacsWiki). +;; +;; Thanks to Yanghui Bian for indicating a new +;; newline character mapping. +;; +;; Thanks to Pete Forman for indicating +;; whitespace-mode on XEmacs. +;; +;; Thanks to Miles Bader for handling display table via +;; visws.el (his code was modified, but the main idea was kept). +;; +;; Thanks to: +;; Aurelien Tisne show-whitespace-mode.el +;; Lawrence Mitchell whitespace-mode.el +;; Miles Bader visws.el +;; And to all people who contributed with them. +;; +;; +;; ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + +;;; code: + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; User Variables: + + +;;; Interface to the command system + + +(defgroup blank nil + "Visualise blanks (TAB, (HARD) SPACE and NEWLINE)." + :link '(emacs-library-link :tag "Source Lisp File" "blank-mode.el") + :version "22.2" + :group 'wp + :group 'data) + + +(defcustom blank-style '(mark color) + "*Specify the visualisation style. + +It's a list which element value can be: + + mark display mappings are visualised. + + color faces are visualised. + +Any other value is ignored. + +If it's nil, don't visualise TABs, (HARD) SPACEs and NEWLINEs. + +See also `blank-display-mappings' for documentation." + :type '(repeat :tag "Style of Blank" + (choice :tag "Style of Blank" + (const :tag "Display Table" mark) + (const :tag "Faces" color))) + :group 'blank) + + +(defcustom blank-chars + '(tabs spaces trailing lines space-before-tab newline) + "*Specify which kind of blank is visualised. + +It's a list which element value can be: + + trailing trailing blanks are visualised. + + tabs TABs are visualised. + + spaces SPACEs and HARD SPACEs are visualised. + + lines lines whose length is greater than + `blank-line-length' are highlighted. + + space-before-tab SPACEs before TAB are visualised. + + newline NEWLINEs are visualised. + +Any other element value is ignored. + +If it's nil, don't visualise TABs, (HARD) SPACEs and NEWLINEs. + +Used when `blank-style' has `color' as an element. +If `blank-chars' has `newline' as an element, used when `blank-style' +has `mark' as an element." + :type '(repeat :tag "Kind of Blank" + (choice :tag "Kind of Blank" + (const :tag "Trailing TABs, SPACEs and HARD SPACEs" + trailing) + (const :tag "SPACEs and HARD SPACEs" spaces) + (const :tag "TABs" tabs) + (const :tag "Lines" lines) + (const :tag "SPACEs before TAB" + space-before-tab) + (const :tag "NEWLINEs" newline))) + :group 'blank) + + +(defcustom blank-space-face 'blank-space-face + "*Symbol face used to visualise SPACE. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-space-face + '((((class color) (background dark)) + (:background "grey20" :foreground "aquamarine3")) + (((class color) (background light)) + (:background "LightYellow" :foreground "aquamarine3")) + (t (:inverse-video t))) + "Face used to visualise SPACE." + :group 'blank) + + +(defcustom blank-hspace-face 'blank-hspace-face + "*Symbol face used to visualise HARD SPACE. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-hspace-face ; 'nobreak-space + '((((class color) (background dark)) + (:background "grey24" :foreground "aquamarine3")) + (((class color) (background light)) + (:background "LemonChiffon3" :foreground "aquamarine3")) + (t (:inverse-video t))) + "Face used to visualise HARD SPACE." + :group 'blank) + + +(defcustom blank-tab-face 'blank-tab-face + "*Symbol face used to visualise TAB. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-tab-face + '((((class color) (background dark)) + (:background "grey22" :foreground "aquamarine3")) + (((class color) (background light)) + (:background "beige" :foreground "aquamarine3")) + (t (:inverse-video t))) + "Face used to visualise TAB." + :group 'blank) + + +(defcustom blank-newline-face 'blank-newline-face + "*Symbol face used to visualise NEWLINE char mapping. + +See `blank-display-mappings'. + +Used when `blank-style' has `mark' and `color' as elements +and `blank-chars' has `newline' as an element." + :type 'face + :group 'blank) + + +(defface blank-newline-face + '((((class color) (background dark)) + (:background "grey26" :foreground "aquamarine3" :bold t)) + (((class color) (background light)) + (:background "linen" :foreground "aquamarine3" :bold t)) + (t (:bold t :underline t))) + "Face used to visualise NEWLINE char mapping. + +See `blank-display-mappings'." + :group 'blank) + + +(defcustom blank-trailing-face 'blank-trailing-face + "*Symbol face used to visualise traling blanks. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-trailing-face ; 'trailing-whitespace + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "red1" :foreground "yellow" :bold t))) + "Face used to visualise trailing blanks." + :group 'blank) + + +(defcustom blank-line-face 'blank-line-face + "*Symbol face used to visualise \"long\" lines. + +See `blank-line-legnth'. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-line-face + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "gray20" :foreground "violet"))) + "Face used to visualise \"long\" lines. + +See `blank-line-length'." + :group 'blank) + + +(defcustom blank-space-before-tab-face 'blank-space-before-tab-face + "*Symbol face used to visualise SPACEs before TAB. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-space-before-tab-face + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "DarkOrange" :foreground "firebrick"))) + "Face used to visualise SPACEs before TAB." + :group 'blank) + + +(defcustom blank-hspace-regexp + "\\(\\(\xA0\\|\x8A0\\|\x920\\|\xE20\\|\xF20\\)+\\)" + "*Specify HARD SPACE characters regexp. + +If you're using `mule' package, it may exist other characters besides: + + \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \"\\xF20\" + +that it should be considered HARD SPACE. + +Here are some examples: + + \"\\\\(^\\xA0+\\\\)\" \ +visualise only leading HARD SPACEs. + \"\\\\(\\xA0+$\\\\)\" \ +visualise only trailing HARD SPACEs. + \"\\\\(^\\xA0+\\\\|\\xA0+$\\\\)\" \ +visualise leading and/or trailing HARD SPACEs. + \"\\t\\\\(\\xA0+\\\\)\\t\" \ +visualise only HARD SPACEs between TABs. + +NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. + Use exactly one pair of enclosing \\\\( and \\\\). + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `spaces' as an element." + :type '(regexp :tag "HARD SPACE Chars") + :group 'blank) + + +(defcustom blank-space-regexp "\\( +\\)" + "*Specify SPACE characters regexp. + +If you're using `mule' package, it may exist other characters +besides \" \" that it should be considered SPACE. + +Here are some examples: + + \"\\\\(^ +\\\\)\" visualise only leading SPACEs. + \"\\\\( +$\\\\)\" visualise only trailing SPACEs. + \"\\\\(^ +\\\\| +$\\\\)\" \ +visualise leading and/or trailing SPACEs. + \"\\t\\\\( +\\\\)\\t\" visualise only SPACEs between TABs. + +NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. + Use exactly one pair of enclosing \\\\( and \\\\). + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `spaces' as an element." + :type '(regexp :tag "SPACE Chars") + :group 'blank) + + +(defcustom blank-tab-regexp "\\(\t+\\)" + "*Specify TAB characters regexp. + +If you're using `mule' package, it may exist other characters +besides \"\\t\" that it should be considered TAB. + +Here are some examples: + + \"\\\\(^\\t+\\\\)\" visualise only leading TABs. + \"\\\\(\\t+$\\\\)\" visualise only trailing TABs. + \"\\\\(^\\t+\\\\|\\t+$\\\\)\" \ +visualise leading and/or trailing TABs. + \" \\\\(\\t+\\\\) \" visualise only TABs between SPACEs. + +NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. + Use exactly one pair of enclosing \\\\( and \\\\). + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `tabs' as an element." + :type '(regexp :tag "TAB Chars") + :group 'blank) + + +(defcustom blank-trailing-regexp + "\t\\| \\|\xA0\\|\x8A0\\|\x920\\|\xE20\\|\xF20" + "*Specify trailing characters regexp. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that it should be considered blank. + +NOTE: DOES NOT enclose by \\\\( and \\\\) the elements to highlight. + `blank-mode' surrounds this regexp by \"\\\\(\\\\(\" and + \"\\\\)+\\\\)$\". + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `trailing' as an element." + :type '(regexp :tag "Trailing Chars") + :group 'blank) + + +(defcustom blank-space-before-tab-regexp "\\( +\\)\t" + "*Specify SPACEs before TAB regexp. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that it should be considered blank. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `space-before-tab' as an element." + :type '(regexp :tag "SPACEs Before TAB") + :group 'blank) + + +(defcustom blank-line-length 80 + "*Specify length beyond which the line is highlighted. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `lines' as an element." + :type '(integer :tag "Line Length") + :group 'blank) + + +;; Hacked from `visible-whitespace-mappings' in visws.el +(defcustom blank-display-mappings + ;; Due to limitations of glyph representation, the char code can not + ;; be above ?\x1FFFF. Probably, this will be fixed after Emacs + ;; unicode merging. + '( + (?\ [?\xB7] [?.]) ; space - centered dot + (?\xA0 [?\xA4] [?_]) ; hard space - currency + (?\x8A0 [?\x8A4] [?_]) ; hard space - currency + (?\x920 [?\x924] [?_]) ; hard space - currency + (?\xE20 [?\xE24] [?_]) ; hard space - currency + (?\xF20 [?\xF24] [?_]) ; hard space - currency + ;; NEWLINE is displayed using the face `blank-newline-face' + (?\n [?$ ?\n]) ; end-of-line - dollar sign + ;; (?\n [?\u21B5 ?\n] [?$ ?\n]) ; end-of-line - downwards arrow + ;; (?\n [?\xB6 ?\n] [?$ ?\n]) ; end-of-line - pilcrow + ;; (?\n [?\x8AF ?\n] [?$ ?\n]) ; end-of-line - overscore + ;; (?\n [?\x8AC ?\n] [?$ ?\n]) ; end-of-line - negation + ;; (?\n [?\x8B0 ?\n] [?$ ?\n]) ; end-of-line - grade + ;; + ;; WARNING: the mapping below has a problem. + ;; When a TAB occupies exactly one column, it will display the + ;; character ?\xBB at that column followed by a TAB which goes to + ;; the next TAB column. + ;; If this is a problem for you, please, comment the line below. + (?\t [?\xBB ?\t] [?\\ ?\t]) ; tab - left quote mark + ) + "*Specify an alist of mappings for displaying characters. + +Each element has the following form: + + (CHAR VECTOR...) + +Where: + +CHAR is the character to be mapped. + +VECTOR is a vector of characters to be displayed in place of CHAR. + The first display vector that can be displayed is used; + if no display vector for a mapping can be displayed, then + that character is displayed unmodified. + +The NEWLINE character is displayed using the face given by +`blank-newline-face' variable. The characters in the vector to be +displayed will not have applied this face if the character code is +above #x1FFFF. + +Used when `blank-style' has `mark' as an element." + :type '(repeat + (list :tag "Character Mapping" + (character :tag "Char") + (repeat :inline t :tag "Vector List" + (vector :tag "" + (repeat :inline t + :tag "Vector Characters" + (character :tag "Char")))))) + :group 'blank) + + +(defcustom blank-global-modes t + "*Modes for which global `blank-mode' is automagically turned on. + +Global `blank-mode' is controlled by the command `global-blank-mode'. + +If nil, means no modes have `blank-mode' automatically turned on. +If t, all modes that support `blank-mode' have it automatically +turned on. +If a list, it should be a list of `major-mode' symbol names for +which `blank-mode' should be automatically turned on. The sense +of the list is negated if it begins with `not'. For example: + + (c-mode c++-mode) + +means that `blank-mode' is turned on for buffers in C and C++ +modes only." + :type '(choice (const :tag "none" nil) + (const :tag "all" t) + (set :menu-tag "mode specific" :tag "modes" + :value (not) + (const :tag "Except" not) + (repeat :inline t + (symbol :tag "mode")))) + :group 'blank) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; User commands - Local mode + + +;;;###autoload +(define-minor-mode blank-mode + "Toggle blank minor mode visualisation (bl on modeline). + +If ARG is null, toggle blank visualisation. +If ARG is a number and is greater than zero, turn on +visualisation; otherwise, turn off visualisation. +Only useful with a windowing system." + :lighter " bl" + :init-value nil + :global nil + :group 'blank + (cond + (noninteractive ; running a batch job + (setq blank-mode nil)) + (blank-mode ; blank-mode on + (blank-turn-on)) + (t ; blank-mode off + (blank-turn-off)))) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; User commands - Global mode + + +(define-minor-mode global-blank-mode + "Toggle blank global minor mode visualisation (BL on modeline). + +If ARG is null, toggle blank visualisation. +If ARG is a number and is greater than zero, turn on +visualisation; otherwise, turn off visualisation. +Only useful with a windowing system." + :lighter " BL" + :init-value nil + :global t + :group 'blank + (cond + (noninteractive ; running a batch job + (setq global-blank-mode nil)) + (global-blank-mode ; global-blank-mode on + (save-excursion + (if (boundp 'find-file-hook) + (add-hook 'find-file-hook 'blank-turn-on-if-enabled t) + (add-hook 'find-file-hooks 'blank-turn-on-if-enabled t)) + (dolist (buffer (buffer-list)) ; adjust all local mode + (set-buffer buffer) + (unless blank-mode + (blank-turn-on-if-enabled))))) + (t ; global-blank-mode off + (save-excursion + (if (boundp 'find-file-hook) + (remove-hook 'find-file-hook 'blank-turn-on-if-enabled) + (remove-hook 'find-file-hooks 'blank-turn-on-if-enabled)) + (dolist (buffer (buffer-list)) ; adjust all local mode + (set-buffer buffer) + (unless blank-mode + (blank-turn-off))))))) + + +(defun blank-turn-on-if-enabled () + (when (cond + ((eq blank-global-modes t)) + ((listp blank-global-modes) + (if (eq (car-safe blank-global-modes) 'not) + (not (memq major-mode (cdr blank-global-modes))) + (memq major-mode blank-global-modes))) + (t nil)) + (let (inhibit-quit) + ;; Don't turn on blank mode if... + (or + ;; ...we don't have a display (we're running a batch job) + noninteractive + ;; ...or if the buffer is invisible (name starts with a space) + (eq (aref (buffer-name) 0) ?\ ) + ;; ...or if the buffer is temporary (name starts with *) + (and (eq (aref (buffer-name) 0) ?*) + ;; except the scratch buffer. + (not (string= (buffer-name) "*scratch*"))) + ;; Otherwise, turn on blank mode. + (blank-turn-on))))) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; User commands - Toggle + + +(defconst blank-chars-value-list + '(tabs + spaces + trailing + space-before-tab + lines + newline + ) + "List of valid `blank-chars' value.") + + +(defconst blank-style-value-list + '(color + mark + ) + "List of valid `blank-style' value.") + + +(defconst blank-toggle-option-alist + '((?t . tabs) + (?s . spaces) + (?r . trailing) + (?b . space-before-tab) + (?l . lines) + (?n . newline) + (?c . color) + (?m . mark) + (?x . blank-chars) + (?z . blank-style) + ) + "Alist of toggle options. + +Each element has the form: + + (CHAR . SYMBOL) + +Where: + +CHAR is a char which the user will have to type. + +SYMBOL is a valid symbol associated with CHAR. + See `blank-chars-value-list' and `blank-style-value-list'.") + + +(defvar blank-active-chars nil + "Used to save locally `blank-chars' value.") +(make-variable-buffer-local 'blank-active-chars) + +(defvar blank-active-style nil + "Used to save locally `blank-style' value.") +(make-variable-buffer-local 'blank-active-style) + + +;;;###autoload +(defun blank-toggle-options (arg) + "Toggle local `blank-mode' options. + +If local blank-mode is off, toggle the option given by ARG and +turn on local blank-mode. + +If local blank-mode is on, toggle the option given by ARG and +restart local blank-mode. + +Interactively, it reads one of the following chars: + + CHAR MEANING + t toggle TAB visualisation + s toggle SPACE and HARD SPACE visualisation + r toggle trailing blanks visualisation + b toggle SPACEs before TAB visualisation + l toggle \"long lines\" visualisation + n toggle NEWLINE visualisation + c toggle color faces + m toggle visual mark + x restore `blank-chars' value + z restore `blank-style' value + ? display brief help + +Non-interactively, ARG should be a symbol or a list of symbol. +The valid symbols are: + + tabs toggle TAB visualisation + spaces toggle SPACE and HARD SPACE visualisation + trailing toggle trailing blanks visualisation + space-before-tab toggle SPACEs before TAB visualisation + lines toggle \"long lines\" visualisation + newline toggle NEWLINE visualisation + color toggle color faces + mark toggle visual mark + blank-chars restore `blank-chars' value + blank-style restore `blank-style' value + +Only useful with a windowing system." + (interactive (blank-interactive-char t)) + (let ((blank-chars + (blank-toggle-list t arg blank-active-chars blank-chars + 'blank-chars blank-chars-value-list)) + (blank-style + (blank-toggle-list t arg blank-active-style blank-style + 'blank-style blank-style-value-list))) + (blank-mode 0) + (blank-mode 1))) + + +(defvar blank-toggle-chars nil + "Used to toggle the global `blank-chars' value.") +(defvar blank-toggle-style nil + "Used to toggle the global `blank-style' value.") + + +;;;###autoload +(defun global-blank-toggle-options (arg) + "Toggle global `blank-mode' options. + +If global blank-mode is off, toggle the option given by ARG and +turn on global blank-mode. + +If global blank-mode is on, toggle the option given by ARG and +restart global blank-mode. + +Interactively, it reads one of the following chars: + + CHAR MEANING + t toggle TAB visualisation + s toggle SPACE and HARD SPACE visualisation + r toggle trailing blanks visualisation + b toggle SPACEs before TAB visualisation + l toggle \"long lines\" visualisation + n toggle NEWLINE visualisation + c toggle color faces + m toggle visual mark + x restore `blank-chars' value + z restore `blank-style' value + ? display brief help + +Non-interactively, ARG should be a symbol or a list of symbol. +The valid symbols are: + + tabs toggle TAB visualisation + spaces toggle SPACE and HARD SPACE visualisation + trailing toggle trailing blanks visualisation + space-before-tab toggle SPACEs before TAB visualisation + lines toggle \"long lines\" visualisation + newline toggle NEWLINE visualisation + color toggle color faces + mark toggle visual mark + blank-chars restore `blank-chars' value + blank-style restore `blank-style' value + +Only useful with a windowing system." + (interactive (blank-interactive-char nil)) + (let ((blank-chars + (blank-toggle-list nil arg blank-toggle-chars blank-chars + 'blank-chars blank-chars-value-list)) + (blank-style + (blank-toggle-list nil arg blank-toggle-style blank-style + 'blank-style blank-style-value-list))) + (setq blank-toggle-chars blank-chars + blank-toggle-style blank-style) + (global-blank-mode 0) + (global-blank-mode 1))) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; Internal functions + + +(defvar blank-font-lock-mode nil + "Used to remember whether a buffer had font lock mode on or not.") +(make-variable-buffer-local 'blank-font-lock-mode) + +(defvar blank-font-lock nil + "Used to remember whether a buffer initially had font lock on or not.") +(make-variable-buffer-local 'blank-font-lock) + +(defvar blank-font-lock-keywords nil + "Used to save locally `font-lock-keywords' value.") +(make-variable-buffer-local 'blank-font-lock-keywords) + + +(defconst blank-help-text + "\ + blank-mode toggle options: + + [] t - toggle TAB visualisation + [] s - toggle SPACE and HARD SPACE visualisation + [] r - toggle trailing blanks visualisation + [] b - toggle SPACEs before TAB visualisation + [] l - toggle \"long lines\" visualisation + [] n - toggle NEWLINE visualisation + + [] c - toggle color faces + [] m - toggle visual mark + + x - restore `blank-chars' value + z - restore `blank-style' value + + ? - display this text\n\n" + "Text for blank toggle options.") + + +(defconst blank-help-buffer-name "*Blank Toggle Options*" + "The buffer name for blank toggle options.") + + +(defun blank-insert-option-mark (the-list the-value) + "Insert the option mark ('X' or ' ') in toggle options buffer." + (forward-line 1) + (dolist (sym the-list) + (forward-line 1) + (forward-char 2) + (insert (if (memq sym the-value) "X" " ")))) + + +(defun blank-help-on (chars style) + "Display the blank toggle options." + (unless (get-buffer blank-help-buffer-name) + (delete-other-windows) + (let ((buffer (get-buffer-create blank-help-buffer-name))) + (save-excursion + (set-buffer buffer) + (erase-buffer) + (insert blank-help-text) + (goto-char (point-min)) + (blank-insert-option-mark blank-chars-value-list chars) + (blank-insert-option-mark blank-style-value-list style) + (goto-char (point-min)) + (set-buffer-modified-p nil) + (let ((size (- (window-height) + (max window-min-height + (1+ (count-lines (point-min) (point-max))))))) + (when (<= size 0) + (kill-buffer buffer) + (error "Frame height is too small; \ +can't split window to display blank toggle options")) + (set-window-buffer (split-window nil size) buffer)))))) + + +(defun blank-help-off () + "Remove the buffer and window of the blank toggle options." + (let ((buffer (get-buffer blank-help-buffer-name))) + (when buffer + (delete-windows-on buffer) + (kill-buffer buffer)))) + + +(defun blank-interactive-char (local-p) + "Interactive function to read a char and return a symbol. + +If LOCAL-P is non-nil, it uses a local context; otherwise, it +uses a global context. + +It reads one of the following chars: + + CHAR MEANING + t toggle TAB visualisation + s toggle SPACE and HARD SPACE visualisation + r toggle trailing blanks visualisation + b toggle SPACEs before TAB visualisation + l toggle \"long lines\" visualisation + n toggle NEWLINE visualisation + c toggle color faces + m toggle visual mark + x restore `blank-chars' value + z restore `blank-style' value + ? display brief help + +See also `blank-toggle-option-alist'." + (let* ((is-off (not (if local-p blank-mode global-blank-mode))) + (chars (cond (is-off blank-chars) ; use default value + (local-p blank-active-chars) + (t blank-toggle-chars))) + (style (cond (is-off blank-style) ; use default value + (local-p blank-active-style) + (t blank-toggle-style))) + (prompt + (format "Blank Toggle %s (type ? for further options)-" + (if local-p "Local" "Global"))) + ch sym) + ;; read a valid option and get the corresponding symbol + (save-window-excursion + (condition-case data + (progn + (while + ;; while condition + (progn + (setq ch (read-char prompt)) + (not + (setq sym + (cdr (assq ch blank-toggle-option-alist))))) + ;; while body + (if (eq ch ?\?) + (blank-help-on chars style) + (ding))) + (blank-help-off) + (message " ")) ; clean echo area + ;; handler + ((quit error) + (blank-help-off) + (error (error-message-string data))))) + (list sym))) ; return the apropriate symbol + + +(defun blank-toggle-list (local-p arg the-list default-list + sym-restore sym-list) + "Toggle options in THE-LIST based on list ARG. + +If LOCAL-P is non-nil, it uses a local context; otherwise, it +uses a global context. + +ARG is a list of options to be toggled. + +THE-LIST is a list of options. This list will be toggled and the +resultant list will be returned. + +DEFAULT-LIST is the default list of options. It is used to +restore the options in THE-LIST. + +SYM-RESTORE is the symbol which indicates to restore the options +in THE-LIST. + +SYM-LIST is a list of valid options, used to check if the ARG's +options are valid." + (unless (if local-p blank-mode global-blank-mode) + (setq the-list default-list)) + (setq the-list (copy-sequence the-list)) ; keep original list + (dolist (sym (if (listp arg) arg (list arg))) + (cond + ;; restore default values + ((eq sym sym-restore) + (setq the-list default-list)) + ;; toggle valid values + ((memq sym sym-list) + (setq the-list (if (memq sym the-list) + (delq sym the-list) + (cons sym the-list)))))) + the-list) + + +(defun blank-turn-on () + "Turn on blank visualisation." + (setq blank-active-style (if (listp blank-style) + blank-style + (list blank-style))) + (setq blank-active-chars (if (listp blank-chars) + blank-chars + (list blank-chars))) + (and (memq 'color blank-active-style) + (blank-color-on)) + (and (memq 'mark blank-active-style) + (blank-display-char-on))) + + +(defun blank-turn-off () + "Turn off blank visualisation." + (and (memq 'color blank-active-style) + (blank-color-off)) + (and (memq 'mark blank-active-style) + (blank-display-char-off))) + + +(defun blank-color-on () + "Turn on color visualisation." + (when blank-active-chars + (unless blank-font-lock + (setq blank-font-lock t + blank-font-lock-keywords + (copy-sequence font-lock-keywords))) + ;; turn off font lock + (setq blank-font-lock-mode font-lock-mode) + (font-lock-mode 0) + ;; add blank-mode color into font lock + (when (memq 'spaces blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show SPACEs + (list blank-space-regexp 1 blank-space-face t) + ;; Show HARD SPACEs + (list blank-hspace-regexp 1 blank-hspace-face t)) + t)) + (when (memq 'tabs blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show TABs + (list blank-tab-regexp 1 blank-tab-face t)) + t)) + (when (memq 'trailing blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show trailing blanks + (list (concat "\\(\\(" blank-trailing-regexp "\\)+\\)$") + 1 blank-trailing-face t)) + t)) + (when (memq 'lines blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show "long" lines + (list (concat "^\\(.\\{" (int-to-string blank-line-length) + ",\\}\\)$") + 1 blank-line-face t)) + t)) + (when (memq 'space-before-tab blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show SPACEs before TAB + (list blank-space-before-tab-regexp + 1 blank-space-before-tab-face t)) + t)) + ;; now turn on font lock and highlight blanks + (font-lock-mode 1))) + + +(defun blank-color-off () + "Turn off color visualisation." + (when blank-active-chars + (when blank-font-lock + (setq blank-font-lock nil + font-lock-keywords blank-font-lock-keywords)) + ;; turn off font lock + (font-lock-mode 0) + ;; restore original font lock state + (font-lock-mode blank-font-lock-mode))) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; Hacked from visws.el (Miles Bader ) + + +(defvar blank-display-table nil + "Used to save a local display table.") +(make-variable-buffer-local 'blank-display-table) + +(defvar blank-display-table-was-local nil + "Used to remember whether a buffer initially had a local display table or not.") +(make-variable-buffer-local 'blank-display-table-was-local) + + +(defsubst blank-char-valid-p (char) + ;; This check should be improved!!! + (or (< char 256) + (char-valid-p char))) + + +(defun blank-legal-display-vector-p (vec) + "Return true if every character in vector VEC can be displayed." + (let ((i (length vec))) + (when (> i 0) + (while (and (>= (setq i (1- i)) 0) + (blank-char-valid-p (aref vec i)))) + (< i 0)))) + + +(defun blank-display-char-on () + "Turn on character display mapping." + (when blank-display-mappings + (let (vecs vec) + ;; Remember whether a buffer has a local display table. + (unless blank-display-table-was-local + (setq blank-display-table-was-local t + blank-display-table + (copy-sequence buffer-display-table))) + (unless buffer-display-table + (setq buffer-display-table (make-display-table))) + (dolist (entry blank-display-mappings) + (setq vecs (cdr entry)) + ;; Get a displayable mapping. + (while (and vecs + (not (blank-legal-display-vector-p (car vecs)))) + (setq vecs (cdr vecs))) + ;; Display a valid mapping. + (when vecs + (setq vec (copy-sequence (car vecs))) + (cond + ;; Any char except newline + ((not (eq (car entry) ?\n)) + (aset buffer-display-table (car entry) vec)) + ;; Newline char - display it + ((memq 'newline blank-active-chars) + ;; Only insert face bits on NEWLINE char mapping to avoid + ;; obstruction of other faces like TABs and (HARD) SPACEs + ;; faces, font-lock faces, etc. + (when (memq 'color blank-active-style) + (dotimes (i (length vec)) + ;; Due to limitations of glyph representation, the char + ;; code can not be above ?\x1FFFF. Probably, this will + ;; be fixed after Emacs unicode merging. + (or (eq (aref vec i) ?\n) + (> (aref vec i) #x1FFFF) + (aset vec i (make-glyph-code (aref vec i) + blank-newline-face))))) + ;; Display mapping + (aset buffer-display-table (car entry) vec)) + ;; Newline char - don't display it + (t + ;; Do nothing + ))))))) + + +(defun blank-display-char-off () + "Turn off character display mapping." + (and blank-display-mappings + blank-display-table-was-local + (setq blank-display-table-was-local nil + buffer-display-table blank-display-table))) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; + + +(provide 'blank-mode) + + +(run-hooks 'blank-load-hook) + + +;;; blank-mode.el ends here From d616968003b11307a17d0995f9d6bfbe12b6c51c Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Thu, 17 Jan 2008 15:23:38 +0000 Subject: [PATCH 175/439] (handle_one_xevent): Revert to counting chars not bytes. (XTread_socket): Clarify what return value is counting in comment. --- src/ChangeLog | 2 ++ src/xterm.c | 8 ++++---- 2 files changed, 6 insertions(+), 4 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index a2cb8c490a6..b28c1d9ac05 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,7 @@ 2008-01-17 Jason Rumney + * xterm.c (handle_one_xevent): Revert to counting chars not bytes. + * w32term.c (w32_read_socket) : Decode characters outside the unicode range available in MULE by locale-coding-system. Improve dbcs lead byte detection. Set event timestamp and modifiers diff --git a/src/xterm.c b/src/xterm.c index 7f948815860..96638c2ee5f 100644 --- a/src/xterm.c +++ b/src/xterm.c @@ -6488,9 +6488,7 @@ handle_one_xevent (dpyinfo, eventp, finish, hold_quit) kbd_buffer_store_event_hold (&inev.ie, hold_quit); } - /* Previous code updated count by nchars rather than nbytes, - but that seems bogus to me. ++kfs */ - count += nbytes; + count += nchars; inev.ie.kind = NO_EVENT; /* Already stored above. */ @@ -6989,7 +6987,9 @@ x_dispatch_event (event, display) We return as soon as there are no more events to be read. We return the number of characters stored into the buffer, - thus pretending to be `read'. + thus pretending to be `read' (except the characters we store + in the keyboard buffer can be multibyte, so are not necessarily + C chars). EXPECTED is nonzero if the caller knows input is available. */ From 9536288fb0a060cf1a8fbf0e219e08d4d2c7b322 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Thu, 17 Jan 2008 18:24:10 +0000 Subject: [PATCH 176/439] *** empty log message *** --- admin/CPP-DEFINES | 7 +++---- 1 file changed, 3 insertions(+), 4 deletions(-) diff --git a/admin/CPP-DEFINES b/admin/CPP-DEFINES index 5aee4f73c8c..4d1d647f03e 100644 --- a/admin/CPP-DEFINES +++ b/admin/CPP-DEFINES @@ -3,10 +3,9 @@ of their use. Feel free to add more macros and more categories. ** Distinguishing OSes ** -MAC_OS Compiling for some version of Mac OS? -MAC_OS8 Compiling for Mac OS version 8. Requires MAC_OS? -MAC_OSX Compiling for Mac OS X? Is that also valid for Darwin? -MAC_OS_X ?? Apparently only used once in mac.c. +MAC_OS Compiling for the `mac' window-system. +MAC_OS8 Compiling for Mac OS Classic (v8 or v9). +MAC_OSX Compiling for Mac OS X. Not bare Darwin. CYGWIN Compiling the Cygwin port. __CYGWIN__ Ditto MSDOS Compiling the MS-DOS port. From 4afd234b27f785b58c120f007fdb981c196a78b5 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 18 Jan 2008 03:19:07 +0000 Subject: [PATCH 177/439] (icomplete-get-keys): Look up KEYS using all maps in proper buffer. --- lisp/ChangeLog | 5 +++++ lisp/icomplete.el | 3 +-- 2 files changed, 6 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ee05404c36a..1611261964b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-18 Richard Stallman + + * icomplete.el (icomplete-get-keys): + Look up KEYS using all maps in proper buffer. + 2008-01-17 Vinicius Jose Latorre 2008-01-17 Miles Bader diff --git a/lisp/icomplete.el b/lisp/icomplete.el index b1e8fa5ebb5..3eb4b4babf2 100644 --- a/lisp/icomplete.el +++ b/lisp/icomplete.el @@ -147,8 +147,7 @@ is minibuffer." (save-excursion (let* ((sym (intern func-name)) (buf (other-buffer nil t)) - (map (save-excursion (set-buffer buf) (current-local-map))) - (keys (where-is-internal sym map))) + (keys (with-current-buffer buf (where-is-internal sym)))) (if keys (concat "<" (mapconcat 'key-description From e47b4224c466c8321617582db3e6b400665aeede Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 18 Jan 2008 05:37:32 +0000 Subject: [PATCH 178/439] (ibuffer-mode): Fix typo in previous change. --- lisp/ChangeLog | 4 ++++ lisp/ibuffer.el | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 58a6d361ab3..987f31ac591 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-18 Glenn Morris + + * ibuffer.el (ibuffer-mode): Fix typo in previous change. + 2008-01-17 Vinicius Jose Latorre 2008-01-17 Miles Bader diff --git a/lisp/ibuffer.el b/lisp/ibuffer.el index 0a26311541c..12363c6f808 100644 --- a/lisp/ibuffer.el +++ b/lisp/ibuffer.el @@ -2516,7 +2516,7 @@ will be inserted before the group at point." (setq major-mode 'ibuffer-mode) (setq mode-name "Ibuffer") ;; Include state info next to the mode name. - (set (make-local-variable mode-line-process) + (set (make-local-variable 'mode-line-process) '((ibuffer-sorting-mode (:eval (symbol-name ibuffer-sorting-mode)) "view time") (ibuffer-sorting-reversep " [rev]") From 7d235bca82e15b04451246569261e5eb85dbcba1 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 18 Jan 2008 05:39:20 +0000 Subject: [PATCH 179/439] Re-arrange for font-lock. --- lisp/ChangeLog | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 987f31ac591..9984fd9dcd4 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -5,9 +5,9 @@ 2008-01-17 Vinicius Jose Latorre 2008-01-17 Miles Bader - * blank-mode.el: New file. Minor mode to visualise TAB, - (HARD) SPACE, NEWLINE. Miles Bader wrote the original - code for handling display table (via visws.el package), his code was + * blank-mode.el: New file. Minor mode to visualise (HARD) SPACE, + TAB, NEWLINE. Miles Bader wrote the original code + for handling display table (via visws.el package), his code was modified, but the main idea was kept. 2008-01-17 Glenn Morris From 279c44082ae75f8483460b5c7936416e8ef7df01 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 18 Jan 2008 05:41:09 +0000 Subject: [PATCH 180/439] Richard M. Stallman (custom-theme-recalc-face): Use face-spec-set rather than face-spec-recalc. --- lisp/ChangeLog | 5 +++++ lisp/custom.el | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9984fd9dcd4..50bce510858 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-18 Richard Stallman + + * custom.el (custom-theme-recalc-face): Use face-spec-set rather + than face-spec-recalc. + 2008-01-18 Glenn Morris * ibuffer.el (ibuffer-mode): Fix typo in previous change. diff --git a/lisp/custom.el b/lisp/custom.el index a0b1db517a2..7466913eb9a 100644 --- a/lisp/custom.el +++ b/lisp/custom.el @@ -1176,7 +1176,9 @@ This function returns nil if no custom theme specifies a value for VARIABLE." (defun custom-theme-recalc-face (face) "Set FACE according to currently enabled custom themes." (if (facep face) - (face-spec-recalc face))) + (face-spec-set face + (get (or (get face 'face-alias) face) + 'face-override-spec)))) ;;; XEmacs compability functions From d4f7fdc601f3eca0a09c3dd4ca23396dd5b531b6 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 18 Jan 2008 05:43:35 +0000 Subject: [PATCH 181/439] (ffap-alist): Remove space from RFC regexp. --- lisp/ChangeLog | 4 ++++ lisp/ffap.el | 5 ++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 50bce510858..9c95f77c428 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-18 Glenn Morris + + * ffap.el (ffap-alist): Remove space from RFC regexp. + 2008-01-18 Richard Stallman * custom.el (custom-theme-recalc-face): Use face-spec-set rather diff --git a/lisp/ffap.el b/lisp/ffap.el index 27cdd9cf512..c34478a30de 100644 --- a/lisp/ffap.el +++ b/lisp/ffap.el @@ -797,7 +797,10 @@ This uses ffap-file-exists-string, which may try adding suffixes from ("\\.bib\\'" . ffap-bib) ; search ffap-bib-path ("\\`\\." . ffap-home) ; .emacs, .bashrc, .profile ("\\`~/" . ffap-lcd) ; |~/misc/ffap.el.Z| - ("^[Rr][Ff][Cc][- #]?\\([0-9]+\\)" ; no $ + ;; This uses to have a blank, but ffap-string-at-point doesn't + ;; handle blanks. + ;; http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg01058.html + ("^[Rr][Ff][Cc][-#]?\\([0-9]+\\)" ; no $ . ffap-rfc) ; "100% RFC2100 compliant" (dired-mode . ffap-dired) ; maybe in a subdirectory ) From 95986dbebc31635179059b68c9a1c8923ffca50e Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 18 Jan 2008 05:45:26 +0000 Subject: [PATCH 182/439] Present tense. --- ChangeLog | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/ChangeLog b/ChangeLog index 80b38fefba2..b2900dfd336 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,7 +1,6 @@ 2008-01-17 Andreas Schwab - * configure.in (HAVE_LIB64_DIR): Renamed from - HAVE_X86_64_LIB64_DIR. + * configure.in (HAVE_LIB64_DIR): Rename from HAVE_X86_64_LIB64_DIR. 2008-01-17 Glenn Morris From a11ded73f4fa2d41ae0bc909f3fd5d5368964afc Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Fri, 18 Jan 2008 07:23:26 +0000 Subject: [PATCH 183/439] Add arch tagline --- lisp/blank-mode.el | 1 + 1 file changed, 1 insertion(+) diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el index ed235d5f531..3a57f2e971c 100644 --- a/lisp/blank-mode.el +++ b/lisp/blank-mode.el @@ -1278,4 +1278,5 @@ options are valid." (run-hooks 'blank-load-hook) +;; arch-tag: 1b1e2500-dbd4-4a26-8f7a-5a5edfd3c97e ;;; blank-mode.el ends here From 42b54a9bef555ebb700a9aa73c7a54e7b5177586 Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Fri, 18 Jan 2008 07:25:21 +0000 Subject: [PATCH 184/439] Add arch tagline --- lisp/blank-mode.el | 1 + 1 file changed, 1 insertion(+) diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el index ed235d5f531..3a57f2e971c 100644 --- a/lisp/blank-mode.el +++ b/lisp/blank-mode.el @@ -1278,4 +1278,5 @@ options are valid." (run-hooks 'blank-load-hook) +;; arch-tag: 1b1e2500-dbd4-4a26-8f7a-5a5edfd3c97e ;;; blank-mode.el ends here From e166638d11e7acb0e79523f984a111111fb71992 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Fri, 18 Jan 2008 14:12:44 +0000 Subject: [PATCH 185/439] Add a TODO note about vc-state. (vc-next-action): Register 'unregistered and 'ignored files. Use when and unless instead of if where appropriate. (vc-start-entry): Fix typo. (vc-status): Autoload it. --- lisp/ChangeLog | 10 +++++++- lisp/vc.el | 70 ++++++++++++++++++++++++++------------------------ 2 files changed, 46 insertions(+), 34 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9c95f77c428..36d57f9caa0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2008-01-18 Dan Nicolaescu + + * vc.el: Add a TODO note about vc-state. + (vc-next-action): Register 'unregistered and 'ignored files. Use + when and unless instead of if where appropriate. + (vc-start-entry): Fix typo. + (vc-status): Autoload it. + 2008-01-18 Glenn Morris * ffap.el (ffap-alist): Remove space from RFC regexp. @@ -12,7 +20,7 @@ * ibuffer.el (ibuffer-mode): Fix typo in previous change. 2008-01-17 Vinicius Jose Latorre -2008-01-17 Miles Bader + Miles Bader * blank-mode.el: New file. Minor mode to visualise (HARD) SPACE, TAB, NEWLINE. Miles Bader wrote the original code diff --git a/lisp/vc.el b/lisp/vc.el index ac83365613b..bb05625f577 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -537,6 +537,9 @@ ;; - make it easier to write logs, maybe C-x 4 a should add to the log ;; buffer if there's one instead of the ChangeLog. ;; +;; - make vc-state for all backends return 'unregistered instead of +;; nil for unregistered files, then update vc-next-action. +;; ;; - deal with push/pull operations. ;; ;; - decide if vc-status should replace vc-dired. @@ -1434,9 +1437,9 @@ merge in the changes into your working copy." revision) ;; Verify that the fileset is homogenous (dolist (file (cdr files)) - (if (not (vc-compatible-state (vc-state file) state)) - (error "Fileset is in a mixed-up state")) - (if (not (eq (vc-checkout-model file) model)) + (unless (vc-compatible-state (vc-state file) state) + (error "Fileset is in a mixed-up state")) + (unless (eq (vc-checkout-model file) model) (error "Fileset has mixed checkout models"))) ;; Check for buffers in the fileset not matching the on-disk contents. (dolist (file files) @@ -1458,13 +1461,15 @@ merge in the changes into your working copy." (error "Aborted")) ;; Now, check if we have unsaved changes. (vc-buffer-sync t) - (if (buffer-modified-p) - (or (y-or-n-p (message "Use %s on disk, keeping modified buffer? " file)) - (error "Aborted"))))))) + (when (buffer-modified-p) + (or (y-or-n-p (message "Use %s on disk, keeping modified buffer? " file)) + (error "Aborted"))))))) ;; Do the right thing (cond ;; Files aren't registered - ((not state) + ((or (not state) ;; RCS uses nil for unregistered files. + (eq state 'unregistered) + (eq state 'ignored)) (mapc 'vc-register files)) ;; Files are up-to-date, or need a merge and user specified a revision ((or (eq state 'up-to-date) (and verbose (eq state 'needs-patch))) @@ -1488,32 +1493,30 @@ merge in the changes into your working copy." (let ((ready-for-commit files)) ;; If files are edited but read-only, give user a chance to correct (dolist (file files) - (if (not (file-writable-p file)) - (progn - ;; Make the file+buffer read-write. - (unless (y-or-n-p (format "%s is edited but read-only; make it writable and continue?" file)) - (error "Aborted")) - (set-file-modes file (logior (file-modes file) 128)) - (let ((visited (get-file-buffer file))) - (if visited - (with-current-buffer visited - (toggle-read-only -1))))))) + (unless (file-writable-p file) + ;; Make the file+buffer read-write. + (unless (y-or-n-p (format "%s is edited but read-only; make it writable and continue?" file)) + (error "Aborted")) + (set-file-modes file (logior (file-modes file) 128)) + (let ((visited (get-file-buffer file))) + (when visited + (with-current-buffer visited + (toggle-read-only -1)))))) ;; Allow user to revert files with no changes (save-excursion (dolist (file files) (let ((visited (get-file-buffer file))) ;; For files with locking, if the file does not contain ;; any changes, just let go of the lock, i.e. revert. - (if (and (not (eq model 'implicit)) - (vc-workfile-unchanged-p file) - ;; If buffer is modified, that means the user just - ;; said no to saving it; in that case, don't revert, - ;; because the user might intend to save after - ;; finishing the log entry and committing. - (not (and visited (buffer-modified-p)))) - (progn - (vc-revert-file file) - (delete file ready-for-commit)))))) + (when (and (not (eq model 'implicit)) + (vc-workfile-unchanged-p file) + ;; If buffer is modified, that means the user just + ;; said no to saving it; in that case, don't revert, + ;; because the user might intend to save after + ;; finishing the log entry and committing. + (not (and visited (buffer-modified-p)))) + (vc-revert-file file) + (delete file ready-for-commit))))) ;; Remaining files need to be committed (if (not ready-for-commit) (message "No files remain to be committed") @@ -1539,16 +1542,16 @@ merge in the changes into your working copy." "%s is not up-to-date. Get latest revision? " (file-name-nondirectory file))) (vc-checkout file (eq model 'implicit) t) - (if (and (not (eq model 'implicit)) - (yes-or-no-p "Lock this revision? ")) - (vc-checkout file t))))) + (when (and (not (eq model 'implicit)) + (yes-or-no-p "Lock this revision? ")) + (vc-checkout file t))))) ;; needs-merge ((eq state 'needs-merge) (dolist (file files) - (if (yes-or-no-p (format + (when (yes-or-no-p (format "%s is not up-to-date. Merge in changes now? " (file-name-nondirectory file))) - (vc-maybe-resolve-conflicts file (vc-call merge-news file))))) + (vc-maybe-resolve-conflicts file (vc-call merge-news file))))) ;; unlocked-changes ((eq state 'unlocked-changes) @@ -1697,7 +1700,7 @@ INITIAL-CONTENTS is nil, do action immediately as if the user had entered COMMENT. If COMMENT is t, also do action immediately with an empty comment. Remember the file's buffer in `vc-parent-buffer' \(current one if no file). AFTER-HOOK specifies the local value -for vc-log-operation-hook." +for `vc-log-after-operation-hook'." (let ((parent (if (eq major-mode 'vc-dired-mode) ;; If we are called from VC dired, the parent buffer is @@ -2562,6 +2565,7 @@ With prefix arg READ-SWITCHES, specify a value to override ;; Must be in sync with vc-status-printer. (forward-char 25)) +;;;###autoload (defun vc-status (dir) "Show the VC status for DIR." (interactive "DVC status for directory: ") From 36611f0f4b978131442ef0892ccdbf34992c381d Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Fri, 18 Jan 2008 15:06:59 +0000 Subject: [PATCH 186/439] *** empty log message *** --- lisp/ChangeLog | 124 +++++++++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 124 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 36d57f9caa0..869f3d88705 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,127 @@ +2008-01-18 Carsten Dominik + + * textmodes/org.el: (org-entry-properties) Include the CLOCKSUM + special property. + (org-columns-edit-value): Do not allow to edit the special + CLOCKSUM property. + (org-flag-drawer): Use the original value of `outline-regexp'. + (org-remember-handler): Add invisible-ok flag to call to + `org-end-of-subtree' + (org-agenda-highlight-todo): Respect + `org-agenda-todo-keyword-format'. + (org-agenda-todo-keyword-format): New option. + (org-infile-export-plist): No restriction while searching for + options. + (org-remember-handler): Remove comments at the end of the buffer. + (org-remember-use-refile-when-interactive): New option. + (org-table-sort-lines): Make sure sorting works on link + descritions only, and ignores the link. + (org-sort-entries-or-items): Make sure the end of the subtree is + included. + (org-refile-use-outline-path): New allowed values `file' and + `full-file-path'. + (org-get-refile-targets): Respect new values for + `org-refile-use-outline-path'. + (org-agenda-get-restriction-and-command): DEL goes back to initial + list. + (org-export-as-xoxo): Restore point when done. + (org-open-file): Allow multiple %s in command. + (org-clock-in-switch-to-state): New option. + (org-first-list-item-p): New function. + (org-last-remember-storage-locations): New variable. + (org-get-refile-targets): Interpret the new maxlevel setting. + (org-refile-targets): New option `:maxlevel'. + (org-copy-subtree): Include empty lines before but not after + subtree. + (org-back-over-empty-lines, org-skip-whitespace): New functions. + (org-move-item-down, org-move-item-up): Include empty lines before + but not after item. + (org-first-sibling-p): New function. + (org-remember-apply-template): Defaults, completions and history + for template prompts. Also, interpret new `%!' escape. + (org-context-choices): New constant. + (org-bound-and-true-p): New macro. + (org-imenu-depth): New option. + (org-imenu-markers): New variable. + (org-imenu-new-marker, org-imenu-get-tree) + (org-speedbar-set-agenda-restriction): New functions. + (org-agenda-set-restriction-lock) + (org-agenda-remove-restriction-lock, org-agenda-maybe-redo): New + functions. + (org-agenda-restriction-lock): New face. + (org-agenda-restriction-lock-overlay) + (org-speedbar-restriction-lock-overlay): New variables. + (org-open-at-point): Removed obsolete way to do redirection in + shell links. + (org-imenu-and-speedbar): New customization group. + (org-entry-properties): Return keyword-less time strings. + (org-clock-heading-function): New option. + (org-clock-in): Use `org-clock-heading-function'. + (org-calendar-holiday): Try to use `calendar-check-holidays' + instead of the obsolete `check-calendar-holidays'. + (org-export-html-special-string-regexps): New constant. + (org-massive-special-regexp): New variable. + (org-compute-latex-and-specials-regexp) + (org-do-latex-and-special-faces): New functions. + (org-latex-and-export-specials): New face. + (org-highlight-latex-fragments-and-specials): New option. + (org-link-escape-chars): Use characters instead of strings. + (org-link-escape-chars-browser, org-link-escape) + (org-link-unescape): Use characters instead of strings. + (org-export-html-convert-sub-super, org-html-do-expand): Check for + protected text. + (org-emphasis-alist): Additional `verbatim' flag. + (org-set-emph-re): Handle the verbatim flag and compute + `org-verbatim-re'. + (org-cleaned-string-for-export): Protect verbatim elements. + (org-verbatim-re): New variable. + (org-hide-emphasis-markers): New option. + (org-additional-option-like-keywords): Add new keywords. + (org-get-entry): Renamed from `org-get-cleaned-entry'. + (org-icalendar-cleanup-string): New function for quoting icalendar + text. + (org-agenda-skip-scheduled-if-done): New option. + (org-agenda-get-scheduled, org-agenda-get-blocks): Use + `org-agenda-skip-scheduled-if-done'. + (org-prepare-agenda-buffers): Allow buffers as arguments. + (org-entry-properties): Add CATEGORY as a special property. + (org-use-property-inheritance): Allow a list of properties as a + value. + (org-eval-in-calendar): No longer update the prompt. + (org-read-date-popup-calendar): Renamed from + `org-popup-calendar-for-date-prompt'. + (org-read-date-display-live): New variable. + (org-read-date-display): New function. + (org-read-date-analyze): New function. + (org-remember-apply-template): Define `remember-finalize' if it is + not yet defined. + (org-remember-insinuate): New function. + (org-read-date-prefer-future): New option. + (org-read-date): Respect the setting of + `org-read-date-prefer-future'. Use `org-read-date-analyze'. + (org-set-font-lock-defaults): Use `org-archive-tag' instead of a + hardcoded string. + (org-remember-apply-template): Use `remember-finalize' instead of + `remember-buffer'. + (org-columns-compute, org-column-number-to-string) + (org-columns-uncompile-format, org-columns-compile-format) + (org-columns-compile-format): Handle printf format specifier. + (org-columns-new, org-column-number-to-string) + (org-columns-uncompile-format, org-columns-compile-format): + Support for new currency summary type. + (org-tree-to-indirect-buffer): Do not kill old buffer when + `org-indirect-buffer-display' is `new-frame'. + (org-indirect-buffer-display): Document that `new-frame' leads to + indiret buffer proliferation. + (org-agenda-list): Use `org-extend-today-until'. + (org-extend-today-until): New option. + (org-format-org-table-html): Use lower-case for tag. + (org-agenda-execute): New command. + (org-agenda-mode-map): Keybindings of "g" "G", "e" modified. + (org-select-remember-template): New function. + (org-remember-apply-template): Use `org-select-remember-template'. + (org-go-to-remember-target): New function. + 2008-01-18 Dan Nicolaescu * vc.el: Add a TODO note about vc-state. From 8c6fb58bdf92f9396b744b72f14a902ae135c771 Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Fri, 18 Jan 2008 15:11:02 +0000 Subject: [PATCH 187/439] (org-entry-properties): Include the CLOCKSUM special property. (org-columns-edit-value): Do not allow to edit the special CLOCKSUM property. (org-flag-drawer): Use the original value of `outline-regexp'. (org-remember-handler): Add invisible-ok flag to call to `org-end-of-subtree' (org-agenda-highlight-todo): Respect `org-agenda-todo-keyword-format'. (org-agenda-todo-keyword-format): New option. (org-infile-export-plist): No restriction while searching for options. (org-remember-handler): Remove comments at the end of the buffer. (org-remember-use-refile-when-interactive): New option. (org-table-sort-lines): Make sure sorting works on link descritions only, and ignores the link. (org-sort-entries-or-items): Make sure the end of the subtree is included. (org-refile-use-outline-path): New allowed values `file' and `full-file-path'. (org-get-refile-targets): Respect new values for `org-refile-use-outline-path'. (org-agenda-get-restriction-and-command): DEL goes back to initial list. (org-export-as-xoxo): Restore point when done. (org-open-file): Allow multiple %s in command. (org-clock-in-switch-to-state): New option. (org-first-list-item-p): New function. (org-last-remember-storage-locations): New variable. (org-get-refile-targets): Interpret the new maxlevel setting. (org-refile-targets): New option `:maxlevel'. (org-copy-subtree): Include empty lines before but not after subtree. (org-back-over-empty-lines, org-skip-whitespace): New functions. (org-move-item-down, org-move-item-up): Include empty lines before but not after item. (org-first-sibling-p): New function. (org-remember-apply-template): Defaults, completions and history for template prompts. Also, interpret new `%!' escape. (org-context-choices): New constant. (org-bound-and-true-p): New macro. (org-imenu-depth): New option. (org-imenu-markers): New variable. (org-imenu-new-marker, org-imenu-get-tree) (org-speedbar-set-agenda-restriction): New functions. (org-agenda-set-restriction-lock) (org-agenda-remove-restriction-lock, org-agenda-maybe-redo): New functions. (org-agenda-restriction-lock): New face. (org-agenda-restriction-lock-overlay) (org-speedbar-restriction-lock-overlay): New variables. (org-open-at-point): Removed obsolete way to do redirection in shell links. (org-imenu-and-speedbar): New customization group. (org-entry-properties): Return keyword-less time strings. (org-clock-heading-function): New option. (org-clock-in): Use `org-clock-heading-function'. (org-calendar-holiday): Try to use `calendar-check-holidays' instead of the obsolete `check-calendar-holidays'. (org-export-html-special-string-regexps): New constant. (org-massive-special-regexp): New variable. (org-compute-latex-and-specials-regexp) (org-do-latex-and-special-faces): New functions. (org-latex-and-export-specials): New face. (org-highlight-latex-fragments-and-specials): New option. (org-link-escape-chars): Use characters instead of strings. (org-link-escape-chars-browser, org-link-escape) (org-link-unescape): Use characters instead of strings. (org-export-html-convert-sub-super, org-html-do-expand): Check for protected text. (org-emphasis-alist): Additional `verbatim' flag. (org-set-emph-re): Handle the verbatim flag and compute `org-verbatim-re'. (org-cleaned-string-for-export): Protect verbatim elements. (org-verbatim-re): New variable. (org-hide-emphasis-markers): New option. (org-additional-option-like-keywords): Add new keywords. (org-get-entry): Renamed from `org-get-cleaned-entry'. (org-icalendar-cleanup-string): New function for quoting icalendar text. (org-agenda-skip-scheduled-if-done): New option. (org-agenda-get-scheduled, org-agenda-get-blocks): Use `org-agenda-skip-scheduled-if-done'. (org-prepare-agenda-buffers): Allow buffers as arguments. (org-entry-properties): Add CATEGORY as a special property. (org-use-property-inheritance): Allow a list of properties as a value. (org-eval-in-calendar): No longer update the prompt. (org-read-date-popup-calendar): Renamed from `org-popup-calendar-for-date-prompt'. (org-read-date-display-live): New variable. (org-read-date-display): New function. (org-read-date-analyze): New function. (org-remember-apply-template): Define `remember-finalize' if it is not yet defined. (org-remember-insinuate): New function. (org-read-date-prefer-future): New option. (org-read-date): Respect the setting of `org-read-date-prefer-future'. Use `org-read-date-analyze'. (org-set-font-lock-defaults): Use `org-archive-tag' instead of a hardcoded string. (org-remember-apply-template): Use `remember-finalize' instead of `remember-buffer'. (org-columns-compute, org-column-number-to-string) (org-columns-uncompile-format, org-columns-compile-format) (org-columns-compile-format): Handle printf format specifier. (org-columns-new, org-column-number-to-string) (org-columns-uncompile-format, org-columns-compile-format): Support for new currency summary type. (org-tree-to-indirect-buffer): Do not kill old buffer when `org-indirect-buffer-display' is `new-frame'. (org-indirect-buffer-display): Document that `new-frame' leads to indiret buffer proliferation. (org-agenda-list): Use `org-extend-today-until'. (org-extend-today-until): New option. (org-format-org-table-html): Use lower-case for tag. (org-agenda-execute): New command. (org-agenda-mode-map): Keybindings of "g" "G", "e" modified. (org-select-remember-template): New function. (org-remember-apply-template): Use `org-select-remember-template'. (org-go-to-remember-target): New function. --- lisp/ChangeLog | 17 +- lisp/textmodes/org.el | 3416 ++++++++++++++++++++++++++++------------- 2 files changed, 2362 insertions(+), 1071 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 869f3d88705..76d75ab42d9 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,6 +1,21 @@ 2008-01-18 Carsten Dominik - * textmodes/org.el: (org-entry-properties) Include the CLOCKSUM + * textmodes/org-publish.el (org-publish-current-project): Fix bug + with forcing publication. + + * textmodes/org.el (org-export-with-special-strings): New option. + (org-export-html-convert-special-strings): New function. + (org-html-do-expand): `org-export-html-convert-special-strings' + added to the list of conversion. + (org-infile-export-plist, org-get-current-options): Added support + for "-" in the #+OPTION line to let user switch on/off special + strings conversion. + (org-export-plist-vars): New :html-table-tag property. + (org-export-as-html, org-format-org-table-html) + (org-format-table-table-html) Use the :html-table-tag property + instead of the `org-export-html-table-tag' global value. + (org-additional-option-like-keywords): Added "TBLFM". + (org-entry-properties): Include the CLOCKSUM special property. (org-columns-edit-value): Do not allow to edit the special CLOCKSUM property. diff --git a/lisp/textmodes/org.el b/lisp/textmodes/org.el index 38038ec6720..9826a5b63a0 100644 --- a/lisp/textmodes/org.el +++ b/lisp/textmodes/org.el @@ -5,7 +5,7 @@ ;; Author: Carsten Dominik ;; Keywords: outlines, hypermedia, calendar, wp ;; Homepage: http://orgmode.org -;; Version: 5.13i +;; Version: 5.19a ;; ;; This file is part of GNU Emacs. ;; @@ -77,13 +77,14 @@ (require 'outline) (require 'noutline) ;; Other stuff we need. (require 'time-date) +(unless (fboundp 'time-subtract) (defalias 'time-subtract 'subtract-time)) (require 'easymenu) ;;;; Customization variables ;;; Version -(defconst org-version "5.13i" +(defconst org-version "5.19a" "The version number of the file org.el.") (defun org-version () (interactive) @@ -97,6 +98,10 @@ (get-text-property 0 'test (format "%s" x))) "Does format transport text properties?") +(defmacro org-bound-and-true-p (var) + "Return the value of symbol VAR if it is bound, else nil." + `(and (boundp (quote ,var)) ,var)) + (defmacro org-unmodified (&rest body) "Execute body without changing buffer-modified-p." `(set-buffer-modified-p @@ -251,7 +256,7 @@ Or return the original if not disputed." "Define a key, possibly translated, as returned by `org-key'." (define-key keymap (org-key key) def)) -(defcustom org-ellipsis 'org-ellipsis +(defcustom org-ellipsis nil "The ellipsis to use in the Org-mode outline. When nil, just use the standard three dots. When a string, use that instead, When a face, use the standart 3 dots, but with the specified face. @@ -332,6 +337,25 @@ After a match, group 1 contains the repeat expression.") :tag "Org Reveal Location" :group 'org-structure) +(defconst org-context-choice + '(choice + (const :tag "Always" t) + (const :tag "Never" nil) + (repeat :greedy t :tag "Individual contexts" + (cons + (choice :tag "Context" + (const agenda) + (const org-goto) + (const occur-tree) + (const tags-tree) + (const link-search) + (const mark-goto) + (const bookmark-jump) + (const isearch) + (const default)) + (boolean)))) + "Contexts for the reveal options.") + (defcustom org-show-hierarchy-above '((default . t)) "Non-nil means, show full hierarchy when revealing a location. Org-mode often shows locations in an org-mode file which might have @@ -350,22 +374,7 @@ contexts. Valid contexts are isearch when exiting from an incremental search default default for all contexts not set explicitly" :group 'org-reveal-location - :type '(choice - (const :tag "Always" t) - (const :tag "Never" nil) - (repeat :greedy t :tag "Individual contexts" - (cons - (choice :tag "Context" - (const agenda) - (const org-goto) - (const occur-tree) - (const tags-tree) - (const link-search) - (const mark-goto) - (const bookmark-jump) - (const isearch) - (const default)) - (boolean))))) + :type org-context-choice) (defcustom org-show-following-heading '((default . nil)) "Non-nil means, show following heading when revealing a location. @@ -378,22 +387,7 @@ use the command \\[org-reveal] to show more context. Instead of t, this can also be an alist specifying this option for different contexts. See `org-show-hierarchy-above' for valid contexts." :group 'org-reveal-location - :type '(choice - (const :tag "Always" t) - (const :tag "Never" nil) - (repeat :greedy t :tag "Individual contexts" - (cons - (choice :tag "Context" - (const agenda) - (const org-goto) - (const occur-tree) - (const tags-tree) - (const link-search) - (const mark-goto) - (const bookmark-jump) - (const isearch) - (const default)) - (boolean))))) + :type org-context-choice) (defcustom org-show-siblings '((default . nil) (isearch t)) "Non-nil means, show all sibling heading when revealing a location. @@ -409,22 +403,19 @@ use the command \\[org-reveal] to show more context. Instead of t, this can also be an alist specifying this option for different contexts. See `org-show-hierarchy-above' for valid contexts." :group 'org-reveal-location - :type '(choice - (const :tag "Always" t) - (const :tag "Never" nil) - (repeat :greedy t :tag "Individual contexts" - (cons - (choice :tag "Context" - (const agenda) - (const org-goto) - (const occur-tree) - (const tags-tree) - (const link-search) - (const mark-goto) - (const bookmark-jump) - (const isearch) - (const default)) - (boolean))))) + :type org-context-choice) + +(defcustom org-show-entry-below '((default . nil)) + "Non-nil means, show the entry below a headline when revealing a location. +Org-mode often shows locations in an org-mode file which might have +been invisible before. When this is set, the text below the headline that is +exposed is also shown. + +By default this is off for all contexts. +Instead of t, this can also be an alist specifying this option for different +contexts. See `org-show-hierarchy-above' for valid contexts." + :group 'org-reveal-location + :type org-context-choice) (defgroup org-cycle nil "Options concerning visibility cycling in Org-mode." @@ -568,7 +559,7 @@ and a boolean flag as cdr." (defcustom org-insert-heading-hook nil "Hook being run after inserting a new heading." :group 'org-edit-structure - :type 'boolean) + :type 'hook) (defcustom org-enable-fixed-width-editor t "Non-nil means, lines starting with \":\" are treated as fixed-width. @@ -658,7 +649,9 @@ with \\[org-ctrl-c-ctrl-c\\]." (defcustom org-archive-tag "ARCHIVE" "The tag that marks a subtree as archived. An archived subtree does not open during visibility cycling, and does -not contribute to the agenda listings." +not contribute to the agenda listings. +After changing this, font-lock must be restarted in the relevant buffers to +get the proper fontification." :group 'org-archive :group 'org-keywords :type 'string) @@ -767,6 +760,17 @@ information." (const :tag "Inherited tags" itags) (const :tag "Local tags" ltags))) +(defgroup org-imenu-and-speedbar nil + "Options concerning imenu and speedbar in Org-mode." + :tag "Org Imenu and Speedbar" + :group 'org-structure) + +(defcustom org-imenu-depth 2 + "The maximum level for Imenu access to Org-mode headlines. +This also applied for speedbar access." + :group 'org-imenu-and-speedbar + :type 'number) + (defgroup org-table nil "Options concerning tables in Org-mode." :tag "Org Table" @@ -892,7 +896,7 @@ alignment to the right border applies." :type 'number) (defgroup org-table-editing nil - "Bahavior of tables during editing in Org-mode." + "Behavior of tables during editing in Org-mode." :tag "Org Table Editing" :group 'org-table) @@ -1031,9 +1035,12 @@ links in Org-mode buffers can have an optional tag after a double colon, e.g. [[linkkey:tag][description]] If REPLACE is a string, the tag will simply be appended to create the link. -If the string contains \"%s\", the tag will be inserted there. REPLACE may -also be a function that will be called with the tag as the only argument to -create the link. See the manual for examples." +If the string contains \"%s\", the tag will be inserted there. + +REPLACE may also be a function that will be called with the tag as the +only argument to create the link, which should be returned as a string. + +See the manual for examples." :group 'org-link :type 'alist) @@ -1404,6 +1411,14 @@ When this variable is nil, `C-c C-c' give you the prompts, and :group 'org-remember :type 'boolean) +(defcustom org-remember-use-refile-when-interactive t + "Non-nil means, use refile to file a remember note. +This is only used when the the interactive mode for selecting a filing +location is used (see the variable `org-remember-store-without-prompt'). +When nil, the `org-goto' interface is used." + :group 'org-remember + :type 'boolean) + (defcustom org-remember-default-headline "" "The headline that should be the default location in the notes file. When filing remember notes, the cursor will start at that position. @@ -1416,9 +1431,9 @@ You can set this on a per-template basis with the variable "Templates for the creation of remember buffers. When nil, just let remember make the buffer. When not nil, this is a list of 5-element lists. In each entry, the first -element is a the name of the template, It should be a single short word. +element is the name of the template, which should be a single short word. The second element is a character, a unique key to select this template. -The third element is the template. The forth element is optional and can +The third element is the template. The fourth element is optional and can specify a destination file for remember items created with this template. The default file is given by `org-default-notes-file'. An optional fifth element can specify the headline in that file that should be offered @@ -1429,7 +1444,9 @@ The template specifies the structure of the remember buffer. It should have a first line starting with a star, to act as the org-mode headline. Furthermore, the following %-escapes will be replaced with content: - %^{prompt} prompt the user for a string and replace this sequence with it. + %^{prompt} Prompt the user for a string and replace this sequence with it. + A default value and a completion table ca be specified like this: + %^{prompt|default|completion2|completion3|...} %t time stamp, date only %T time stamp with date and time %u, %U like the above, but inactive time stamps @@ -1440,6 +1457,13 @@ Furthermore, the following %-escapes will be replaced with content: %i initial content, the region when remember is called with C-u. If %i is indented, the entire inserted text will be indented as well. + %c content of the clipboard, or current kill ring head + %^g prompt for tags, with completion on tags in target file + %^G prompt for tags, with completion all tags in all agenda files + %:keyword specific information for certain link types, see below + %[pathname] insert the contents of the file given by `pathname' + %(sexp) evaluate elisp `(sexp)' and replace with the result + %! Store this note immediately after filling the template %? After completing the template, position cursor here. @@ -1483,7 +1507,9 @@ calendar | %:type %:date" (defcustom org-reverse-note-order nil "Non-nil means, store new notes at the beginning of a file or entry. -When nil, new notes will be filed to the end of a file or entry." +When nil, new notes will be filed to the end of a file or entry. +This can also be a list with cons cells of regular expressions that +are matched against file names, and values." :group 'org-remember :type '(choice (const :tag "Reverse always" t) @@ -1491,6 +1517,51 @@ When nil, new notes will be filed to the end of a file or entry." (repeat :tag "By file name regexp" (cons regexp boolean)))) +(defcustom org-refile-targets nil + "Targets for refiling entries with \\[org-refile]. +This is list of cons cells. Each cell contains: +- a specification of the files to be considered, either a list of files, + or a symbol whose function or value fields will be used to retrieve + a file name or a list of file names. Nil means, refile to a different + heading in the current buffer. +- A specification of how to find candidate refile targets. This may be + any of + - a cons cell (:tag . \"TAG\") to identify refile targets by a tag. + This tag has to be present in all target headlines, inheritance will + not be considered. + - a cons cell (:todo . \"KEYWORD\") to identify refile targets by + todo keyword. + - a cons cell (:regexp . \"REGEXP\") with a regular expression matching + headlines that are refiling targets. + - a cons cell (:level . N). Any headline of level N is considered a target. + - a cons cell (:maxlevel . N). Any headline with level <= N is a target." +;; FIXME: what if there are a var and func with same name??? + :group 'org-remember + :type '(repeat + (cons + (choice :value org-agenda-files + (const :tag "All agenda files" org-agenda-files) + (const :tag "Current buffer" nil) + (function) (variable) (file)) + (choice :tag "Identify target headline by" + (cons :tag "Specific tag" (const :tag) (string)) + (cons :tag "TODO keyword" (const :todo) (string)) + (cons :tag "Regular expression" (const :regexp) (regexp)) + (cons :tag "Level number" (const :level) (integer)) + (cons :tag "Max Level number" (const :maxlevel) (integer)))))) + +(defcustom org-refile-use-outline-path nil + "Non-nil means, provide refile targets as paths. +So a level 3 headline will be available as level1/level2/level3. +When the value is `file', also include the file name (without directory) +into the path. When `full-file-path', include the full file path." + :group 'org-remember + :type '(choice + (const :tag "Not" nil) + (const :tag "Yes" t) + (const :tag "Start with file name" file) + (const :tag "Start with full file path" full-file-path))) + (defgroup org-todo nil "Options concerning TODO items in Org-mode." :tag "Org TODO" @@ -1712,6 +1783,15 @@ Nil means, clock will keep running until stopped explicitly with :group 'org-progress :type 'boolean) +(defcustom org-clock-in-switch-to-state nil + "Set task to a special todo state while clocking it. +The value should be the state to which the entry should be switched." + :group 'org-progress + :group 'org-todo + :type '(choice + (const :tag "Don't force a state" nil) + (string :tag "State"))) + (defgroup org-priorities nil "Priorities in Org-mode." :tag "Org Priorities" @@ -1795,13 +1875,52 @@ end of the second format." (concat "[" (substring f 1 -1) "]") f))) -(defcustom org-popup-calendar-for-date-prompt t +(defcustom org-read-date-prefer-future t + "Non-nil means, assume future for incomplete date input from user. +This affects the following situations: +1. The user gives a day, but no month. + For example, if today is the 15th, and you enter \"3\", Org-mode will + read this as the third of *next* month. However, if you enter \"17\", + it will be considered as *this* month. +2. The user gives a month but not a year. + For example, if it is april and you enter \"feb 2\", this will be read + as feb 2, *next* year. \"May 5\", however, will be this year. + +When this option is nil, the current month and year will always be used +as defaults." + :group 'org-time + :type 'boolean) + +(defcustom org-read-date-display-live t + "Non-nil means, display current interpretation of date prompt live. +This display will be in an overlay, in the minibuffer." + :group 'org-time + :type 'boolean) + +(defcustom org-read-date-popup-calendar t "Non-nil means, pop up a calendar when prompting for a date. In the calendar, the date can be selected with mouse-1. However, the minibuffer will also be active, and you can simply enter the date as well. When nil, only the minibuffer will be available." :group 'org-time :type 'boolean) +(if (fboundp 'defvaralias) + (defvaralias 'org-popup-calendar-for-date-prompt + 'org-read-date-popup-calendar)) + +(defcustom org-extend-today-until 0 + "The hour when your day really ends. +This has influence for the following applications: +- When switching the agenda to \"today\". It it is still earlier than + the time given here, the day recognized as TODAY is actually yesterday. +- When a date is read from the user and it is still before the time given + here, the current date and time will be assumed to be yesterday, 23:59. + +FIXME: +IMPORTANT: This is still a very experimental feature, it may disappear +again or it may be extended to mean more things." + :group 'org-time + :type 'number) (defcustom org-edit-timestamp-down-means-later nil "Non-nil means, S-down will increase the time in a time stamp. @@ -1816,6 +1935,13 @@ moved to the new date." :group 'org-time :type 'boolean) +(defcustom org-clock-heading-function nil + "When non-nil, should be a function to create `org-clock-heading'. +This is the string shown in the mode line when a clock is running. +The function is called with point at the beginning of the headline." + :group 'org-time ; FIXME: Should we have a separate group???? + :type 'function) + (defgroup org-tags nil "Options concerning tags in Org-mode." :tag "Org Tags" @@ -1929,16 +2055,23 @@ lined-up with respect to each other." (defcustom org-use-property-inheritance nil "Non-nil means, properties apply also for sublevels. -This can cause significant overhead when doing a search, so this is turned -off by default. +This setting is only relevant during property searches, not when querying +an entry with `org-entry-get'. To retrieve a property with inheritance, +you need to call `org-entry-get' with the inheritance flag. +Turning this on can cause significant overhead when doing a search, so +this is turned off by default. When nil, only the properties directly given in the current entry count. +The value may also be a list of properties that shouldhave inheritance. However, note that some special properties use inheritance under special circumstances (not in searches). Examples are CATEGORY, ARCHIVE, COLUMNS, and the properties ending in \"_ALL\" when they are used as descriptor for valid values of a property." :group 'org-properties - :type 'boolean) + :type '(choice + (const :tag "Not" nil) + (const :tag "Always" nil) + (repeat :tag "Specific properties" (string :tag "Property")))) (defcustom org-columns-default-format "%25ITEM %TODO %3PRIORITY %TAGS" "The default column format, if no other format has been defined. @@ -1998,7 +2131,7 @@ agenda file per line." (repeat :tag "List of files and directories" file) (file :tag "Store list in a file\n" :value "~/.agenda_files"))) -(defcustom org-agenda-file-regexp "\\.org\\'" +(defcustom org-agenda-file-regexp "\\`[^.].*\\.org\\'" "Regular expression to match files for `org-agenda-files'. If any element in the list in that variable contains a directory instead of a normal file, all files in that directory that are matched by this @@ -2318,6 +2451,11 @@ deadlines are always turned off when the item is DONE." :group 'org-agenda-skip :type 'boolean) +(defcustom org-agenda-skip-timestamp-if-done nil + "Non-nil means don't don't select item by timestamp or -range if it is DONE." + :group 'org-agenda-skip + :type 'boolean) + (defcustom org-timeline-show-empty-dates 3 "Non-nil means, `org-timeline' also shows dates without an entry. When nil, only the days which actually have entries are shown. @@ -2400,7 +2538,9 @@ Valid values are: current-window Display in the current window other-window Just display in another window. dedicated-frame Create one new frame, and re-use it each time. -new-frame Make a new frame each time." +new-frame Make a new frame each time. Note that in this case + previously-made indirect buffers are kept, and you need to + kill these buffers yourself." :group 'org-structure :group 'org-agenda-windows :type '(choice @@ -2542,18 +2682,19 @@ a grid line." :tag "Org Agenda Sorting" :group 'org-agenda) -(let ((sorting-choice - '(choice - (const time-up) (const time-down) - (const category-keep) (const category-up) (const category-down) - (const tag-down) (const tag-up) - (const priority-up) (const priority-down)))) +(defconst org-sorting-choice + '(choice + (const time-up) (const time-down) + (const category-keep) (const category-up) (const category-down) + (const tag-down) (const tag-up) + (const priority-up) (const priority-down)) + "Sorting choices.") - (defcustom org-agenda-sorting-strategy - '((agenda time-up category-keep priority-down) - (todo category-keep priority-down) - (tags category-keep priority-down)) - "Sorting structure for the agenda items of a single day. +(defcustom org-agenda-sorting-strategy + '((agenda time-up category-keep priority-down) + (todo category-keep priority-down) + (tags category-keep priority-down)) + "Sorting structure for the agenda items of a single day. This is a list of symbols which will be used in sequence to determine if an entry should be listed before another entry. The following symbols are recognized: @@ -2580,17 +2721,21 @@ the sequence given in `org-agenda-files'. Within each category sort by priority. Leaving out `category-keep' would mean that items will be sorted across -categories by priority." +categories by priority. + +Instead of a single list, this can also be a set of list for specific +contents, with a context symbol in the car of the list, any of +`agenda', `todo', `tags' for the corresponding agenda views." :group 'org-agenda-sorting :type `(choice - (repeat :tag "General" ,sorting-choice) + (repeat :tag "General" ,org-sorting-choice) (list :tag "Individually" (cons (const :tag "Strategy for Weekly/Daily agenda" agenda) - (repeat ,sorting-choice)) + (repeat ,org-sorting-choice)) (cons (const :tag "Strategy for TODO lists" todo) - (repeat ,sorting-choice)) + (repeat ,org-sorting-choice)) (cons (const :tag "Strategy for Tags matches" tags) - (repeat ,sorting-choice)))))) + (repeat ,org-sorting-choice))))) (defcustom org-sort-agenda-notime-is-late t "Non-nil means, items without time are considered late. @@ -2673,6 +2818,13 @@ See also the variables `org-agenda-remove-times-when-in-prefix' and "The compiled version of the most recently used prefix format. See the variable `org-agenda-prefix-format'.") +(defcustom org-agenda-todo-keyword-format "%-1s" + "Format for the TODO keyword in agenda lines. +Set this to something like \"%-12s\" if you want all TODO keywords +to occupy a fixed space in the agenda display." + :group 'org-agenda-line-format + :type 'string) + (defcustom org-agenda-scheduled-leaders '("Scheduled: " "Sched.%2dx: ") "Text preceeding scheduled items in the agenda view. THis is a list with two strings. The first applies when the item is @@ -2811,23 +2963,23 @@ This is a property list with the following properties: :tag "Org Export General" :group 'org-export) -(defcustom org-export-publishing-directory "." - "Path to the location where exported files should be located. -This path may be relative to the directory where the Org-mode file lives. -The default is to put them into the same directory as the Org-mode file. -The variable may also be an alist with export types `:html', `:ascii', -`:ical', `:LaTeX', or `:xoxo' and the corresponding directories. -If a directory path is relative, it is interpreted relative to the -directory where the exported Org-mode files lives." - :group 'org-export-general - :type '(choice - (directory) - (repeat - (cons - (choice :tag "Type" - (const :html) (const :LaTeX) - (const :ascii) (const :ical) (const :xoxo)) - (directory))))) +;; FIXME +(defvar org-export-publishing-directory nil) + +(defcustom org-export-with-special-strings t + "Non-nil means, interpret \"\-\", \"--\" and \"---\" for export. +When this option is turned on, these strings will be exported as: + + Org HTML LaTeX + -----+----------+-------- + \\- ­ \\- + -- – -- + --- — --- + ... … \ldots + +This option can also be set with the +OPTIONS line, e.g. \"-:nil\"." + :group 'org-export-translation + :type 'boolean) (defcustom org-export-language-setup '(("en" "Author" "Date" "Table of Contents") @@ -3032,6 +3184,20 @@ This option can also be set with the +OPTIONS line, e.g. \"^:nil\"." (const :tag "Only with braces" {}) (const :tag "Never interpret" nil))) +(defcustom org-export-with-special-strings t + "Non-nil means, interpret \"\-\", \"--\" and \"---\" for export. +When this option is turned on, these strings will be exported as: + +\\- : ­ +-- : – +--- : — + +Not all export backends support this, but HTML does. + +This option can also be set with the +OPTIONS line, e.g. \"-:nil\"." + :group 'org-export-translation + :type 'boolean) + (defcustom org-export-with-TeX-macros t "Non-nil means, interpret simple TeX-like macros when exporting. For example, HTML export converts \\alpha to α and \\AA to Å. @@ -3377,8 +3543,20 @@ Changing this variable requires a restart of Emacs to take effect." :group 'org-font-lock :type 'boolean) +(defcustom org-highlight-latex-fragments-and-specials nil + "Non-nil means, fontify what is treated specially by the exporters." + :group 'org-font-lock + :type 'boolean) + +(defcustom org-hide-emphasis-markers nil + "Non-nil mean font-lock should hide the emphasis marker characters." + :group 'org-font-lock + :type 'boolean) + (defvar org-emph-re nil "Regular expression for matching emphasis.") +(defvar org-verbatim-re nil + "Regular expression for matching verbatim text.") (defvar org-emphasis-regexp-components) ; defined just below (defvar org-emphasis-alist) ; defined just below (defun org-set-emph-re (var val) @@ -3393,33 +3571,53 @@ Changing this variable requires a restart of Emacs to take effect." (border (nth 2 e)) (body (nth 3 e)) (nl (nth 4 e)) - (stacked (nth 5 e)) + (stacked (and nil (nth 5 e))) ; stacked is no longer allowed, forced to nil (body1 (concat body "*?")) - (markers (mapconcat 'car org-emphasis-alist ""))) + (markers (mapconcat 'car org-emphasis-alist "")) + (vmarkers (mapconcat + (lambda (x) (if (eq (nth 4 x) 'verbatim) (car x) "")) + org-emphasis-alist ""))) ;; make sure special characters appear at the right position in the class (if (string-match "\\^" markers) (setq markers (concat (replace-match "" t t markers) "^"))) (if (string-match "-" markers) (setq markers (concat (replace-match "" t t markers) "-"))) + (if (string-match "\\^" vmarkers) + (setq vmarkers (concat (replace-match "" t t vmarkers) "^"))) + (if (string-match "-" vmarkers) + (setq vmarkers (concat (replace-match "" t t vmarkers) "-"))) (if (> nl 0) (setq body1 (concat body1 "\\(?:\n" body "*?\\)\\{0," (int-to-string nl) "\\}"))) ;; Make the regexp (setq org-emph-re - (concat "\\([" pre (if stacked markers) "]\\|^\\)" + (concat "\\([" pre (if (and nil stacked) markers) "]\\|^\\)" "\\(" "\\([" markers "]\\)" "\\(" + "[^" border "]\\|" "[^" border (if (and nil stacked) markers) "]" body1 "[^" border (if (and nil stacked) markers) "]" "\\)" "\\3\\)" - "\\([" post (if stacked markers) "]\\|$\\)"))))) + "\\([" post (if (and nil stacked) markers) "]\\|$\\)")) + (setq org-verbatim-re + (concat "\\([" pre "]\\|^\\)" + "\\(" + "\\([" vmarkers "]\\)" + "\\(" + "[^" border "]\\|" + "[^" border "]" + body1 + "[^" border "]" + "\\)" + "\\3\\)" + "\\([" post "]\\|$\\)"))))) (defcustom org-emphasis-regexp-components - '(" \t('\"" "- \t.,:?;'\")" " \t\r\n,\"'" "." 1 nil) - "Components used to build the reqular expression for emphasis. + '(" \t('\"" "- \t.,:?;'\")" " \t\r\n,\"'" "." 1) + "Components used to build the regular expression for emphasis. This is a list with 6 entries. Terminology: In an emphasis string like \" *strong word* \", we call the initial space PREMATCH, the final space POSTMATCH, the stars MARKERS, \"s\" and \"d\" are BORDER characters @@ -3432,10 +3630,7 @@ border The chars *forbidden* as border characters. body-regexp A regexp like \".\" to match a body character. Don't use non-shy groups here, and don't allow newline here. newline The maximum number of newlines allowed in an emphasis exp. -stacked Non-nil means, allow stacked styles. This works only in HTML - export. When this is set, all marker characters (as given in - `org-emphasis-alist') will be allowed as pre/post, aiding - inside-out matching. + Use customize to modify this, or restart Emacs after changing it." :group 'org-font-lock :set 'org-set-emph-re @@ -3445,16 +3640,17 @@ Use customize to modify this, or restart Emacs after changing it." (sexp :tag "Forbidden chars in border ") (sexp :tag "Regexp for body ") (integer :tag "number of newlines allowed") - (boolean :tag "Stacking allowed "))) + (option (boolean :tag "Stacking (DISABLED) ")))) (defcustom org-emphasis-alist '(("*" bold "" "") ("/" italic "" "") ("_" underline "" "") - ("=" org-code "" "") + ("=" org-code "" "" verbatim) + ("~" org-verbatim "" "" verbatim) ("+" (:strike-through t) "" "") ) -"Special syntax for emphasized text. + "Special syntax for emphasized text. Text starting and ending with a special character will be emphasized, for example *bold*, _underlined_ and /italic/. This variable sets the marker characters, the face to be used by font-lock for highlighting in Org-mode @@ -3469,7 +3665,8 @@ Use customize to modify this, or restart Emacs after changing it." (face :tag "Font-lock-face") (plist :tag "Face property list")) (string :tag "HTML start tag") - (string :tag "HTML end tag")))) + (string :tag "HTML end tag") + (option (const verbatim))))) ;;; The faces @@ -3508,6 +3705,7 @@ any other entries, and any resulting duplicates will be removed entirely." (t (or (assoc (car e) r) (push e r))))) (nreverse r))) (t specs))) +(put 'org-compatible-face 'lisp-indent-function 1) (defface org-hide '((((background light)) (:foreground "white")) @@ -3518,108 +3716,98 @@ color of the frame." :group 'org-faces) (defface org-level-1 ;; font-lock-function-name-face - (org-compatible-face - 'outline-1 - '((((class color) (min-colors 88) (background light)) (:foreground "Blue1")) - (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue")) - (((class color) (min-colors 16) (background light)) (:foreground "Blue")) - (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue")) - (((class color) (min-colors 8)) (:foreground "blue" :bold t)) - (t (:bold t)))) + (org-compatible-face 'outline-1 + '((((class color) (min-colors 88) (background light)) (:foreground "Blue1")) + (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue")) + (((class color) (min-colors 16) (background light)) (:foreground "Blue")) + (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue")) + (((class color) (min-colors 8)) (:foreground "blue" :bold t)) + (t (:bold t)))) "Face used for level 1 headlines." :group 'org-faces) (defface org-level-2 ;; font-lock-variable-name-face - (org-compatible-face - 'outline-2 - '((((class color) (min-colors 16) (background light)) (:foreground "DarkGoldenrod")) - (((class color) (min-colors 16) (background dark)) (:foreground "LightGoldenrod")) - (((class color) (min-colors 8) (background light)) (:foreground "yellow")) - (((class color) (min-colors 8) (background dark)) (:foreground "yellow" :bold t)) - (t (:bold t)))) + (org-compatible-face 'outline-2 + '((((class color) (min-colors 16) (background light)) (:foreground "DarkGoldenrod")) + (((class color) (min-colors 16) (background dark)) (:foreground "LightGoldenrod")) + (((class color) (min-colors 8) (background light)) (:foreground "yellow")) + (((class color) (min-colors 8) (background dark)) (:foreground "yellow" :bold t)) + (t (:bold t)))) "Face used for level 2 headlines." :group 'org-faces) (defface org-level-3 ;; font-lock-keyword-face - (org-compatible-face - 'outline-3 - '((((class color) (min-colors 88) (background light)) (:foreground "Purple")) - (((class color) (min-colors 88) (background dark)) (:foreground "Cyan1")) - (((class color) (min-colors 16) (background light)) (:foreground "Purple")) - (((class color) (min-colors 16) (background dark)) (:foreground "Cyan")) - (((class color) (min-colors 8) (background light)) (:foreground "purple" :bold t)) - (((class color) (min-colors 8) (background dark)) (:foreground "cyan" :bold t)) - (t (:bold t)))) + (org-compatible-face 'outline-3 + '((((class color) (min-colors 88) (background light)) (:foreground "Purple")) + (((class color) (min-colors 88) (background dark)) (:foreground "Cyan1")) + (((class color) (min-colors 16) (background light)) (:foreground "Purple")) + (((class color) (min-colors 16) (background dark)) (:foreground "Cyan")) + (((class color) (min-colors 8) (background light)) (:foreground "purple" :bold t)) + (((class color) (min-colors 8) (background dark)) (:foreground "cyan" :bold t)) + (t (:bold t)))) "Face used for level 3 headlines." :group 'org-faces) (defface org-level-4 ;; font-lock-comment-face - (org-compatible-face - 'outline-4 - '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick")) - (((class color) (min-colors 88) (background dark)) (:foreground "chocolate1")) - (((class color) (min-colors 16) (background light)) (:foreground "red")) - (((class color) (min-colors 16) (background dark)) (:foreground "red1")) - (((class color) (min-colors 8) (background light)) (:foreground "red" :bold t)) - (((class color) (min-colors 8) (background dark)) (:foreground "red" :bold t)) - (t (:bold t)))) + (org-compatible-face 'outline-4 + '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick")) + (((class color) (min-colors 88) (background dark)) (:foreground "chocolate1")) + (((class color) (min-colors 16) (background light)) (:foreground "red")) + (((class color) (min-colors 16) (background dark)) (:foreground "red1")) + (((class color) (min-colors 8) (background light)) (:foreground "red" :bold t)) + (((class color) (min-colors 8) (background dark)) (:foreground "red" :bold t)) + (t (:bold t)))) "Face used for level 4 headlines." :group 'org-faces) (defface org-level-5 ;; font-lock-type-face - (org-compatible-face - 'outline-5 - '((((class color) (min-colors 16) (background light)) (:foreground "ForestGreen")) - (((class color) (min-colors 16) (background dark)) (:foreground "PaleGreen")) - (((class color) (min-colors 8)) (:foreground "green")))) + (org-compatible-face 'outline-5 + '((((class color) (min-colors 16) (background light)) (:foreground "ForestGreen")) + (((class color) (min-colors 16) (background dark)) (:foreground "PaleGreen")) + (((class color) (min-colors 8)) (:foreground "green")))) "Face used for level 5 headlines." :group 'org-faces) (defface org-level-6 ;; font-lock-constant-face - (org-compatible-face - 'outline-6 - '((((class color) (min-colors 16) (background light)) (:foreground "CadetBlue")) - (((class color) (min-colors 16) (background dark)) (:foreground "Aquamarine")) - (((class color) (min-colors 8)) (:foreground "magenta")))) + (org-compatible-face 'outline-6 + '((((class color) (min-colors 16) (background light)) (:foreground "CadetBlue")) + (((class color) (min-colors 16) (background dark)) (:foreground "Aquamarine")) + (((class color) (min-colors 8)) (:foreground "magenta")))) "Face used for level 6 headlines." :group 'org-faces) (defface org-level-7 ;; font-lock-builtin-face - (org-compatible-face - 'outline-7 - '((((class color) (min-colors 16) (background light)) (:foreground "Orchid")) - (((class color) (min-colors 16) (background dark)) (:foreground "LightSteelBlue")) - (((class color) (min-colors 8)) (:foreground "blue")))) + (org-compatible-face 'outline-7 + '((((class color) (min-colors 16) (background light)) (:foreground "Orchid")) + (((class color) (min-colors 16) (background dark)) (:foreground "LightSteelBlue")) + (((class color) (min-colors 8)) (:foreground "blue")))) "Face used for level 7 headlines." :group 'org-faces) (defface org-level-8 ;; font-lock-string-face - (org-compatible-face - 'outline-8 - '((((class color) (min-colors 16) (background light)) (:foreground "RosyBrown")) - (((class color) (min-colors 16) (background dark)) (:foreground "LightSalmon")) - (((class color) (min-colors 8)) (:foreground "green")))) + (org-compatible-face 'outline-8 + '((((class color) (min-colors 16) (background light)) (:foreground "RosyBrown")) + (((class color) (min-colors 16) (background dark)) (:foreground "LightSalmon")) + (((class color) (min-colors 8)) (:foreground "green")))) "Face used for level 8 headlines." :group 'org-faces) (defface org-special-keyword ;; font-lock-string-face - (org-compatible-face - nil - '((((class color) (min-colors 16) (background light)) (:foreground "RosyBrown")) - (((class color) (min-colors 16) (background dark)) (:foreground "LightSalmon")) - (t (:italic t)))) + (org-compatible-face nil + '((((class color) (min-colors 16) (background light)) (:foreground "RosyBrown")) + (((class color) (min-colors 16) (background dark)) (:foreground "LightSalmon")) + (t (:italic t)))) "Face used for special keywords." :group 'org-faces) (defface org-drawer ;; font-lock-function-name-face - (org-compatible-face - nil - '((((class color) (min-colors 88) (background light)) (:foreground "Blue1")) - (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue")) - (((class color) (min-colors 16) (background light)) (:foreground "Blue")) - (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue")) - (((class color) (min-colors 8)) (:foreground "blue" :bold t)) - (t (:bold t)))) + (org-compatible-face nil + '((((class color) (min-colors 88) (background light)) (:foreground "Blue1")) + (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue")) + (((class color) (min-colors 16) (background light)) (:foreground "Blue")) + (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue")) + (((class color) (min-colors 8)) (:foreground "blue" :bold t)) + (t (:bold t)))) "Face used for drawers." :group 'org-faces) @@ -3628,15 +3816,14 @@ color of the frame." :group 'org-faces) (defface org-column - (org-compatible-face - nil - '((((class color) (min-colors 16) (background light)) - (:background "grey90")) - (((class color) (min-colors 16) (background dark)) - (:background "grey30")) - (((class color) (min-colors 8)) - (:background "cyan" :foreground "black")) - (t (:inverse-video t)))) + (org-compatible-face nil + '((((class color) (min-colors 16) (background light)) + (:background "grey90")) + (((class color) (min-colors 16) (background dark)) + (:background "grey30")) + (((class color) (min-colors 8)) + (:background "cyan" :foreground "black")) + (t (:inverse-video t)))) "Face for column display of entry properties." :group 'org-faces) @@ -3647,29 +3834,27 @@ color of the frame." :family (face-attribute 'default :family))) (defface org-warning - (org-compatible-face - 'font-lock-warning-face - '((((class color) (min-colors 16) (background light)) (:foreground "Red1" :bold t)) - (((class color) (min-colors 16) (background dark)) (:foreground "Pink" :bold t)) - (((class color) (min-colors 8) (background light)) (:foreground "red" :bold t)) - (((class color) (min-colors 8) (background dark)) (:foreground "red" :bold t)) - (t (:bold t)))) + (org-compatible-face 'font-lock-warning-face + '((((class color) (min-colors 16) (background light)) (:foreground "Red1" :bold t)) + (((class color) (min-colors 16) (background dark)) (:foreground "Pink" :bold t)) + (((class color) (min-colors 8) (background light)) (:foreground "red" :bold t)) + (((class color) (min-colors 8) (background dark)) (:foreground "red" :bold t)) + (t (:bold t)))) "Face for deadlines and TODO keywords." :group 'org-faces) (defface org-archived ; similar to shadow - (org-compatible-face - 'shadow - '((((class color grayscale) (min-colors 88) (background light)) - (:foreground "grey50")) - (((class color grayscale) (min-colors 88) (background dark)) - (:foreground "grey70")) - (((class color) (min-colors 8) (background light)) - (:foreground "green")) - (((class color) (min-colors 8) (background dark)) - (:foreground "yellow")))) - "Face for headline with the ARCHIVE tag." - :group 'org-faces) + (org-compatible-face 'shadow + '((((class color grayscale) (min-colors 88) (background light)) + (:foreground "grey50")) + (((class color grayscale) (min-colors 88) (background dark)) + (:foreground "grey70")) + (((class color) (min-colors 8) (background light)) + (:foreground "green")) + (((class color) (min-colors 8) (background dark)) + (:foreground "yellow")))) + "Face for headline with the ARCHIVE tag." + :group 'org-faces) (defface org-link '((((class color) (background light)) (:foreground "Purple" :underline t)) @@ -3679,8 +3864,8 @@ color of the frame." :group 'org-faces) (defface org-ellipsis - '((((class color) (background light)) (:foreground "DarkGoldenrod" :strike-through t)) - (((class color) (background dark)) (:foreground "LightGoldenrod" :strike-through t)) + '((((class color) (background light)) (:foreground "DarkGoldenrod" :underline t)) + (((class color) (background dark)) (:foreground "LightGoldenrod" :underline t)) (t (:strike-through t))) "Face for the ellipsis in folded text." :group 'org-faces) @@ -3712,32 +3897,29 @@ color of the frame." :group 'org-faces) (defface org-todo ; font-lock-warning-face - (org-compatible-face - nil - '((((class color) (min-colors 16) (background light)) (:foreground "Red1" :bold t)) - (((class color) (min-colors 16) (background dark)) (:foreground "Pink" :bold t)) - (((class color) (min-colors 8) (background light)) (:foreground "red" :bold t)) - (((class color) (min-colors 8) (background dark)) (:foreground "red" :bold t)) - (t (:inverse-video t :bold t)))) + (org-compatible-face nil + '((((class color) (min-colors 16) (background light)) (:foreground "Red1" :bold t)) + (((class color) (min-colors 16) (background dark)) (:foreground "Pink" :bold t)) + (((class color) (min-colors 8) (background light)) (:foreground "red" :bold t)) + (((class color) (min-colors 8) (background dark)) (:foreground "red" :bold t)) + (t (:inverse-video t :bold t)))) "Face for TODO keywords." :group 'org-faces) (defface org-done ;; font-lock-type-face - (org-compatible-face - nil - '((((class color) (min-colors 16) (background light)) (:foreground "ForestGreen" :bold t)) - (((class color) (min-colors 16) (background dark)) (:foreground "PaleGreen" :bold t)) - (((class color) (min-colors 8)) (:foreground "green")) - (t (:bold t)))) + (org-compatible-face nil + '((((class color) (min-colors 16) (background light)) (:foreground "ForestGreen" :bold t)) + (((class color) (min-colors 16) (background dark)) (:foreground "PaleGreen" :bold t)) + (((class color) (min-colors 8)) (:foreground "green")) + (t (:bold t)))) "Face used for todo keywords that indicate DONE items." :group 'org-faces) (defface org-headline-done ;; font-lock-string-face - (org-compatible-face - nil - '((((class color) (min-colors 16) (background light)) (:foreground "RosyBrown")) - (((class color) (min-colors 16) (background dark)) (:foreground "LightSalmon")) - (((class color) (min-colors 8) (background light)) (:bold nil)))) + (org-compatible-face nil + '((((class color) (min-colors 16) (background light)) (:foreground "RosyBrown")) + (((class color) (min-colors 16) (background dark)) (:foreground "LightSalmon")) + (((class color) (min-colors 8) (background light)) (:bold nil)))) "Face used to indicate that a headline is DONE. This face is only used if `org-fontify-done-headline' is set. If applies to the part of the headline after the DONE keyword." @@ -3756,84 +3938,91 @@ list of attributes, like (:foreground \"blue\" :weight bold :underline t)." (sexp :tag "face")))) (defface org-table ;; font-lock-function-name-face - (org-compatible-face - nil - '((((class color) (min-colors 88) (background light)) (:foreground "Blue1")) - (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue")) - (((class color) (min-colors 16) (background light)) (:foreground "Blue")) - (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue")) - (((class color) (min-colors 8) (background light)) (:foreground "blue")) - (((class color) (min-colors 8) (background dark))))) + (org-compatible-face nil + '((((class color) (min-colors 88) (background light)) (:foreground "Blue1")) + (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue")) + (((class color) (min-colors 16) (background light)) (:foreground "Blue")) + (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue")) + (((class color) (min-colors 8) (background light)) (:foreground "blue")) + (((class color) (min-colors 8) (background dark))))) "Face used for tables." :group 'org-faces) (defface org-formula - (org-compatible-face - nil - '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick")) - (((class color) (min-colors 88) (background dark)) (:foreground "chocolate1")) - (((class color) (min-colors 8) (background light)) (:foreground "red")) - (((class color) (min-colors 8) (background dark)) (:foreground "red")) - (t (:bold t :italic t)))) + (org-compatible-face nil + '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick")) + (((class color) (min-colors 88) (background dark)) (:foreground "chocolate1")) + (((class color) (min-colors 8) (background light)) (:foreground "red")) + (((class color) (min-colors 8) (background dark)) (:foreground "red")) + (t (:bold t :italic t)))) "Face for formulas." :group 'org-faces) (defface org-code - (org-compatible-face - nil - '((((class color grayscale) (min-colors 88) (background light)) - (:foreground "grey50")) - (((class color grayscale) (min-colors 88) (background dark)) - (:foreground "grey70")) - (((class color) (min-colors 8) (background light)) - (:foreground "green")) - (((class color) (min-colors 8) (background dark)) - (:foreground "yellow")))) - "Face for fixed-with text like code snippets." - :group 'org-faces - :version "22.1") + (org-compatible-face nil + '((((class color grayscale) (min-colors 88) (background light)) + (:foreground "grey50")) + (((class color grayscale) (min-colors 88) (background dark)) + (:foreground "grey70")) + (((class color) (min-colors 8) (background light)) + (:foreground "green")) + (((class color) (min-colors 8) (background dark)) + (:foreground "yellow")))) + "Face for fixed-with text like code snippets." + :group 'org-faces + :version "22.1") + +(defface org-verbatim + (org-compatible-face nil + '((((class color grayscale) (min-colors 88) (background light)) + (:foreground "grey50" :underline t)) + (((class color grayscale) (min-colors 88) (background dark)) + (:foreground "grey70" :underline t)) + (((class color) (min-colors 8) (background light)) + (:foreground "green" :underline t)) + (((class color) (min-colors 8) (background dark)) + (:foreground "yellow" :underline t)))) + "Face for fixed-with text like code snippets." + :group 'org-faces + :version "22.1") (defface org-agenda-structure ;; font-lock-function-name-face - (org-compatible-face - nil - '((((class color) (min-colors 88) (background light)) (:foreground "Blue1")) - (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue")) - (((class color) (min-colors 16) (background light)) (:foreground "Blue")) - (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue")) - (((class color) (min-colors 8)) (:foreground "blue" :bold t)) - (t (:bold t)))) + (org-compatible-face nil + '((((class color) (min-colors 88) (background light)) (:foreground "Blue1")) + (((class color) (min-colors 88) (background dark)) (:foreground "LightSkyBlue")) + (((class color) (min-colors 16) (background light)) (:foreground "Blue")) + (((class color) (min-colors 16) (background dark)) (:foreground "LightSkyBlue")) + (((class color) (min-colors 8)) (:foreground "blue" :bold t)) + (t (:bold t)))) "Face used in agenda for captions and dates." :group 'org-faces) (defface org-scheduled-today - (org-compatible-face - nil - '((((class color) (min-colors 88) (background light)) (:foreground "DarkGreen")) - (((class color) (min-colors 88) (background dark)) (:foreground "PaleGreen")) - (((class color) (min-colors 8)) (:foreground "green")) - (t (:bold t :italic t)))) + (org-compatible-face nil + '((((class color) (min-colors 88) (background light)) (:foreground "DarkGreen")) + (((class color) (min-colors 88) (background dark)) (:foreground "PaleGreen")) + (((class color) (min-colors 8)) (:foreground "green")) + (t (:bold t :italic t)))) "Face for items scheduled for a certain day." :group 'org-faces) (defface org-scheduled-previously - (org-compatible-face - nil - '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick")) - (((class color) (min-colors 88) (background dark)) (:foreground "chocolate1")) - (((class color) (min-colors 8) (background light)) (:foreground "red")) - (((class color) (min-colors 8) (background dark)) (:foreground "red" :bold t)) - (t (:bold t)))) + (org-compatible-face nil + '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick")) + (((class color) (min-colors 88) (background dark)) (:foreground "chocolate1")) + (((class color) (min-colors 8) (background light)) (:foreground "red")) + (((class color) (min-colors 8) (background dark)) (:foreground "red" :bold t)) + (t (:bold t)))) "Face for items scheduled previously, and not yet done." :group 'org-faces) (defface org-upcoming-deadline - (org-compatible-face - nil - '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick")) - (((class color) (min-colors 88) (background dark)) (:foreground "chocolate1")) - (((class color) (min-colors 8) (background light)) (:foreground "red")) - (((class color) (min-colors 8) (background dark)) (:foreground "red" :bold t)) - (t (:bold t)))) + (org-compatible-face nil + '((((class color) (min-colors 88) (background light)) (:foreground "Firebrick")) + (((class color) (min-colors 88) (background dark)) (:foreground "chocolate1")) + (((class color) (min-colors 8) (background light)) (:foreground "red")) + (((class color) (min-colors 8) (background dark)) (:foreground "red" :bold t)) + (t (:bold t)))) "Face for items scheduled previously, and not yet done." :group 'org-faces) @@ -3862,12 +4051,23 @@ month and 365.24 days for a year)." (number :tag "Fraction of head-warning time passed") (sexp :tag "Face")))) +;; FIXME: this is not a good face yet. +(defface org-agenda-restriction-lock + (org-compatible-face nil + '((((class color) (min-colors 88) (background light)) (:background "yellow1")) + (((class color) (min-colors 88) (background dark)) (:background "skyblue4")) + (((class color) (min-colors 16) (background light)) (:background "yellow1")) + (((class color) (min-colors 16) (background dark)) (:background "skyblue4")) + (((class color) (min-colors 8)) (:background "cyan" :foreground "black")) + (t (:inverse-video t)))) + "Face for showing the agenda restriction lock." + :group 'org-faces) + (defface org-time-grid ;; font-lock-variable-name-face - (org-compatible-face - nil - '((((class color) (min-colors 16) (background light)) (:foreground "DarkGoldenrod")) - (((class color) (min-colors 16) (background dark)) (:foreground "LightGoldenrod")) - (((class color) (min-colors 8)) (:foreground "yellow" :weight light)))) + (org-compatible-face nil + '((((class color) (min-colors 16) (background light)) (:foreground "DarkGoldenrod")) + (((class color) (min-colors 16) (background dark)) (:foreground "LightGoldenrod")) + (((class color) (min-colors 8)) (:foreground "yellow" :weight light)))) "Face used for time grids." :group 'org-faces) @@ -3883,7 +4083,24 @@ If it is less than 8, the level-1 face gets re-used for level N+1 etc." :type 'number :group 'org-faces) -;;; Function declarations. +;;; Functions and variables from ther packages +;; Declared here to avoid compiler warnings + +(eval-and-compile + (unless (fboundp 'declare-function) + (defmacro declare-function (fn file &optional arglist fileonly)))) + +;; XEmacs only +(defvar outline-mode-menu-heading) +(defvar outline-mode-menu-show) +(defvar outline-mode-menu-hide) +(defvar zmacs-regions) ; XEmacs regions + +;; Emacs only +(defvar mark-active) + +;; Various packages +;; FIXME: get the argument lists for the UNKNOWN stuff (declare-function add-to-diary-list "diary-lib" (date string specifier &optional marker globcolor literal)) (declare-function table--at-cell-p "table" (position &optional object at-column)) @@ -3899,6 +4116,8 @@ If it is less than 8, the level-1 face gets re-used for level N+1 etc." (declare-function bibtex-generate-autokey "bibtex" ()) (declare-function bibtex-parse-entry "bibtex" (&optional content)) (declare-function bibtex-url "bibtex" (&optional pos no-browse)) +(defvar calc-embedded-close-formula) +(defvar calc-embedded-open-formula) (declare-function calendar-astro-date-string "cal-julian" (&optional date)) (declare-function calendar-bahai-date-string "cal-bahai" (&optional date)) (declare-function calendar-check-holidays "holidays" (date)) @@ -3915,10 +4134,23 @@ If it is less than 8, the level-1 face gets re-used for level N+1 etc." (declare-function calendar-julian-date-string "cal-julian" (&optional date)) (declare-function calendar-mayan-date-string "cal-mayan" (&optional date)) (declare-function calendar-persian-date-string "cal-persia" (&optional date)) +(defvar calendar-mode-map) +(defvar original-date) ; dynamically scoped in calendar.el does scope this (declare-function cdlatex-tab "ext:cdlatex" ()) (declare-function dired-get-filename "dired" (&optional localp no-error-if-not-filep)) +(declare-function elmo-folder-exists-p "ext:elmo" (folder) t) +(declare-function elmo-message-entity-field "ext:elmo-msgdb" (entity field &optional type)) +(declare-function elmo-message-field "ext:elmo" (folder number field &optional type) t) +;; backward compatibility to old version of elmo +(declare-function elmo-msgdb-overview-get-entity "ext:elmo" (&rest unknown) t) +(defvar font-lock-unfontify-region-function) (declare-function gnus-article-show-summary "gnus-art" ()) (declare-function gnus-summary-last-subject "gnus-sum" ()) +(defvar gnus-other-frame-object) +(defvar gnus-group-name) +(defvar gnus-article-current) +(defvar Info-current-file) +(defvar Info-current-node) (declare-function mh-display-msg "mh-show" (msg-num folder-name)) (declare-function mh-find-path "mh-utils" ()) (declare-function mh-get-header-field "mh-utils" (field)) @@ -3934,19 +4166,25 @@ If it is less than 8, the level-1 face gets re-used for level N+1 etc." (declare-function mh-show-msg "mh-show" (msg)) (declare-function mh-show-show "mh-show" t t) (declare-function mh-visit-folder "mh-folder" (folder &optional range index-data)) +(defvar mh-progs) +(defvar mh-current-folder) +(defvar mh-show-folder-buffer) +(defvar mh-index-folder) +(defvar mh-searcher) (declare-function org-export-latex-cleaned-string "org-export-latex" (&optional commentsp)) (declare-function parse-time-string "parse-time" (string)) (declare-function remember "remember" (&optional initial)) (declare-function remember-buffer-desc "remember" ()) +(defvar remember-save-after-remembering) +(defvar remember-data-file) +(defvar remember-register) +(defvar remember-buffer) +(defvar remember-handler-functions) +(defvar remember-annotation-functions) (declare-function rmail-narrow-to-non-pruned-header "rmail" ()) (declare-function rmail-show-message "rmail" (&optional n no-summary)) (declare-function rmail-what-message "rmail" ()) -(declare-function elmo-folder-exists-p "ext:elmo" (folder) t) -(declare-function elmo-message-entity-field "ext:elmo-msgdb" (entity field &optional type)) -(declare-function elmo-message-field "ext:elmo" (folder number field &optional type) t) -;; In old (2003) versions of Wanderlust without elmo-message-entity. -(declare-function elmo-msgdb-overview-get-entity "ext:elmo-msgdb") -(declare-function wl-summary-buffer-msgdb "ext:wl-summary") +(defvar texmathp-why) (declare-function vm-beginning-of-message "ext:vm-page" ()) (declare-function vm-follow-summary-cursor "ext:vm-motion" ()) (declare-function vm-get-header-contents "ext:vm-summary" (message header-name-regexp &optional clump-sep)) @@ -3956,6 +4194,12 @@ If it is less than 8, the level-1 face gets re-used for level N+1 etc." (declare-function vm-su-message-id "ext:vm-summary" (m)) (declare-function vm-su-subject "ext:vm-summary" (m)) (declare-function vm-summarize "ext:vm-summary" (&optional display raise)) +(defvar vm-message-pointer) +(defvar vm-folder-directory) +(defvar w3m-current-url) +(defvar w3m-current-title) +;; backward compatibility to old version of wl +(declare-function wl-summary-buffer-msgdb "ext:wl-folder" (&rest unknown) t) (declare-function wl-folder-get-elmo-folder "ext:wl-folder" (entity &optional no-cache)) (declare-function wl-summary-goto-folder-subr "ext:wl-summary" (&optional name scan-type other-window sticky interactive scoring force-exit)) (declare-function wl-summary-jump-to-msg-by-message-id "ext:wl-summary" (&optional id)) @@ -3963,6 +4207,12 @@ If it is less than 8, the level-1 face gets re-used for level N+1 etc." (declare-function wl-summary-line-subject "ext:wl-summary" ()) (declare-function wl-summary-message-number "ext:wl-summary" ()) (declare-function wl-summary-redisplay "ext:wl-summary" (&optional arg)) +(defvar wl-summary-buffer-elmo-folder) +(defvar wl-summary-buffer-folder-name) +(declare-function speedbar-line-directory "speedbar" (&optional depth)) + +(defvar org-latex-regexps) +(defvar constants-unit-system) ;;; Variables for pre-computed regular expressions, all buffer local @@ -4137,7 +4387,7 @@ means to push this value onto the list in the variable.") ((equal key "CATEGORY") (if (string-match "[ \t]+$" value) (setq value (replace-match "" t t value))) - (setq cat (intern value))) + (setq cat value)) ((member key '("SEQ_TODO" "TODO")) (push (cons 'sequence (org-split-string value splitre)) kwds)) ((equal key "TYP_TODO") @@ -4179,7 +4429,9 @@ means to push this value onto the list in the variable.") (remove-text-properties 0 (length arch) '(face t fontified t) arch))) ))) - (and cat (org-set-local 'org-category cat)) + (when cat + (org-set-local 'org-category (intern cat)) + (push (cons "CATEGORY" cat) props)) (when prio (if (< (length prio) 3) (setq prio '("A" "C" "B"))) (setq prio (mapcar 'string-to-char prio)) @@ -4335,7 +4587,7 @@ means to push this value onto the list in the variable.") "\\|" org-closed-string "\\|" org-clock-string "\\)\\>\\)") ) - + (org-compute-latex-and-specials-regexp) (org-set-font-lock-defaults))) (defun org-remove-keyword-keys (list) @@ -4345,6 +4597,31 @@ means to push this value onto the list in the variable.") x)) list)) +;; FIXME: this could be done much better, using second characters etc. +(defun org-assign-fast-keys (alist) + "Assign fast keys to a keyword-key alist. +Respect keys that are already there." + (let (new e k c c1 c2 (char ?a)) + (while (setq e (pop alist)) + (cond + ((equal e '(:startgroup)) (push e new)) + ((equal e '(:endgroup)) (push e new)) + (t + (setq k (car e) c2 nil) + (if (cdr e) + (setq c (cdr e)) + ;; automatically assign a character. + (setq c1 (string-to-char + (downcase (substring + k (if (= (string-to-char k) ?@) 1 0))))) + (if (or (rassoc c1 new) (rassoc c1 alist)) + (while (or (rassoc char new) (rassoc char alist)) + (setq char (1+ char))) + (setq c2 c1)) + (setq c (or c2 char))) + (push (cons k c) new)))) + (nreverse new))) + ;;; Some variables ujsed in various places (defvar org-window-configuration nil @@ -4353,49 +4630,6 @@ means to push this value onto the list in the variable.") "Function to be called when `C-c C-c' is used. This is for getting out of special buffers like remember.") -;;; Foreign variables, to inform the compiler - -;; XEmacs only -(defvar outline-mode-menu-heading) -(defvar outline-mode-menu-show) -(defvar outline-mode-menu-hide) -(defvar zmacs-regions) ; XEmacs regions -;; Emacs only -(defvar mark-active) - -;; Packages that org-mode interacts with -(defvar calc-embedded-close-formula) -(defvar calc-embedded-open-formula) -(defvar font-lock-unfontify-region-function) -(defvar org-goto-start-pos) -(defvar vm-message-pointer) -(defvar vm-folder-directory) -(defvar wl-summary-buffer-elmo-folder) -(defvar wl-summary-buffer-folder-name) -(defvar gnus-other-frame-object) -(defvar gnus-group-name) -(defvar gnus-article-current) -(defvar w3m-current-url) -(defvar w3m-current-title) -(defvar mh-progs) -(defvar mh-current-folder) -(defvar mh-show-folder-buffer) -(defvar mh-index-folder) -(defvar mh-searcher) -(defvar calendar-mode-map) -(defvar Info-current-file) -(defvar Info-current-node) -(defvar texmathp-why) -(defvar remember-save-after-remembering) -(defvar remember-data-file) -(defvar remember-register) -(defvar remember-buffer) -(defvar annotation) ; from remember.el, dynamically scoped in `remember-mode' -(defvar initial) ; from remember.el, dynamically scoped in `remember-mode' -(defvar org-latex-regexps) -(defvar constants-unit-system) - -(defvar original-date) ; dynamically scoped in calendar.el does scope this ;; FIXME: Occasionally check by commenting these, to make sure ;; no other functions uses these, forgetting to let-bind them. @@ -4405,7 +4639,6 @@ This is for getting out of special buffers like remember.") (defvar date) (defvar description) - ;; Defined somewhere in this file, but used before definition. (defvar orgtbl-mode-menu) ; defined when orgtbl mode get initialized (defvar org-agenda-buffer-name) @@ -4498,8 +4731,10 @@ Works on both Emacs and XEmacs." (if org-ignore-region nil (if (featurep 'xemacs) - (region-active-p) - (use-region-p)))) + (and zmacs-regions (region-active-p)) + (if (fboundp 'use-region-p) + (use-region-p) + (and transient-mark-mode mark-active))))) ; Emacs 22 and before ;; Invisibility compatibility @@ -4627,6 +4862,10 @@ The following commands are available: ; (org-set-local 'comment-start "#") ;; FIXME: this breaks wrapping (org-set-local 'comment-padding " ") + ;; Imenu + (org-set-local 'imenu-create-index-function + 'org-imenu-get-tree) + ;; Make isearch reveal context (if (or (featurep 'xemacs) (not (boundp 'outline-isearch-open-invisible-function))) @@ -4707,7 +4946,7 @@ that will be added to PLIST. Returns the string that was modified." (defconst org-non-link-chars "]\t\n\r<>") (defvar org-link-types '("http" "https" "ftp" "mailto" "file" "news" "bbdb" "vm" - "wl" "mhe" "rmail" "gnus" "shell" "info" "elisp")) + "wl" "mhe" "rmail" "gnus" "shell" "info" "elisp" "message")) (defvar org-link-re-with-space nil "Matches a link with spaces, optional angular brackets around it.") (defvar org-link-re-with-space2 nil @@ -4752,7 +4991,7 @@ This should be called after the variable `org-link-types' has changed." "\\)>") org-plain-link-re (concat - "\\(" (mapconcat 'identity org-link-types "\\|") "\\):" + "\\<\\(" (mapconcat 'identity org-link-types "\\|") "\\):" "\\([^]\t\n\r<>,;() ]+\\)") org-bracket-link-regexp "\\[\\[\\([^][]+\\)\\]\\(\\[\\([^][]+\\)\\]\\)?\\]" @@ -4813,7 +5052,12 @@ The time stamps may be either active or inactive.") org-emphasis-alist))) (add-text-properties (match-beginning 2) (match-end 2) '(font-lock-multiline t)) - (backward-char 1)))) + (when org-hide-emphasis-markers + (add-text-properties (match-end 4) (match-beginning 5) + '(invisible org-link)) + (add-text-properties (match-beginning 3) (match-end 3) + '(invisible org-link))))) + (backward-char 1)) rtn)) (defun org-emphasize (&optional char) @@ -4928,10 +5172,10 @@ We use a macro so that the test can happen at compilation time." (ip (org-maybe-intangible (list 'invisible 'org-link 'rear-nonsticky org-nonsticky-props 'keymap org-mouse-map 'mouse-face 'highlight - 'help-echo help))) + 'font-lock-multiline t 'help-echo help))) (vp (list 'rear-nonsticky org-nonsticky-props 'keymap org-mouse-map 'mouse-face 'highlight - 'help-echo help))) + ' font-lock-multiline t 'help-echo help))) ;; We need to remove the invisible property here. Table narrowing ;; may have made some of this invisible. (remove-text-properties (match-beginning 0) (match-end 0) @@ -5001,6 +5245,97 @@ We use a macro so that the test can happen at compilation time." (goto-char e) t))) +(defvar org-latex-and-specials-regexp nil + "Regular expression for highlighting export special stuff.") +(defvar org-match-substring-regexp) +(defvar org-match-substring-with-braces-regexp) +(defvar org-export-html-special-string-regexps) + +(defun org-compute-latex-and-specials-regexp () + "Compute regular expression for stuff treated specially by exporters." + (if (not org-highlight-latex-fragments-and-specials) + (org-set-local 'org-latex-and-specials-regexp nil) + (let* + ((matchers (plist-get org-format-latex-options :matchers)) + (latexs (delq nil (mapcar (lambda (x) (if (member (car x) matchers) x)) + org-latex-regexps))) + (options (org-combine-plists (org-default-export-plist) + (org-infile-export-plist))) + (org-export-with-sub-superscripts (plist-get options :sub-superscript)) + (org-export-with-LaTeX-fragments (plist-get options :LaTeX-fragments)) + (org-export-with-TeX-macros (plist-get options :TeX-macros)) + (org-export-html-expand (plist-get options :expand-quoted-html)) + (org-export-with-special-strings (plist-get options :special-strings)) + (re-sub + (cond + ((equal org-export-with-sub-superscripts '{}) + (list org-match-substring-with-braces-regexp)) + (org-export-with-sub-superscripts + (list org-match-substring-regexp)) + (t nil))) + (re-latex + (if org-export-with-LaTeX-fragments + (mapcar (lambda (x) (nth 1 x)) latexs))) + (re-macros + (if org-export-with-TeX-macros + (list (concat "\\\\" + (regexp-opt + (append (mapcar 'car org-html-entities) + (if (boundp 'org-latex-entities) + org-latex-entities nil)) + 'words))) ; FIXME + )) + ;; (list "\\\\\\(?:[a-zA-Z]+\\)"))) + (re-special (if org-export-with-special-strings + (mapcar (lambda (x) (car x)) + org-export-html-special-string-regexps))) + (re-rest + (delq nil + (list + (if org-export-html-expand "@<[^>\n]+>") + )))) + (org-set-local + 'org-latex-and-specials-regexp + (mapconcat 'identity (append re-latex re-sub re-macros re-special + re-rest) "\\|"))))) + +(defface org-latex-and-export-specials + (let ((font (cond ((assq :inherit custom-face-attributes) + '(:inherit underline)) + (t '(:underline t))))) + `((((class grayscale) (background light)) + (:foreground "DimGray" ,@font)) + (((class grayscale) (background dark)) + (:foreground "LightGray" ,@font)) + (((class color) (background light)) + (:foreground "SaddleBrown")) + (((class color) (background dark)) + (:foreground "burlywood")) + (t (,@font)))) + "Face used to highlight math latex and other special exporter stuff." + :group 'org-faces) + +(defun org-do-latex-and-special-faces (limit) + "Run through the buffer and add overlays to links." + (when org-latex-and-specials-regexp + (let (rtn d) + (while (and (not rtn) (re-search-forward org-latex-and-specials-regexp + limit t)) + (if (not (memq (car-safe (get-text-property (1+ (match-beginning 0)) + 'face)) + '(org-code org-verbatim underline))) + (progn + (setq rtn t + d (cond ((member (char-after (1+ (match-beginning 0))) + '(?_ ?^)) 1) + (t 0))) + (font-lock-prepend-text-property + (+ d (match-beginning 0)) (match-end 0) + 'face 'org-latex-and-export-specials) + (add-text-properties (+ d (match-beginning 0)) (match-end 0) + '(font-lock-multiline t))))) + rtn))) + (defun org-restart-font-lock () "Restart font-lock-mode, to force refontification." (when (and (boundp 'font-lock-mode) font-lock-mode) @@ -5067,7 +5402,7 @@ between words." '("^[ \t]*\\(\\(|\\|\\+-[-+]\\).*\\S-\\)" (1 'org-table t)) ;; Table internals - '("| *\\(:?=[^|\n]*\\)" (1 'org-formula t)) + '("^[ \t]*|\\(?:.*?|\\)? *\\(:?=[^|\n]*\\)" (1 'org-formula t)) '("^[ \t]*| *\\([#*]\\) *|" (1 'org-formula t)) '("^[ \t]*|\\( *\\([$!_^/]\\) *|.*\\)|" (1 'org-formula t)) ;; Drawers @@ -5116,14 +5451,17 @@ between words." (if org-provide-checkbox-statistics '("\\[\\([0-9]*%\\)\\]\\|\\[\\([0-9]*\\)/\\([0-9]*\\)\\]" (0 (org-get-checkbox-statistics-face) t))) + (list (concat "^\\*+ \\(.*:" org-archive-tag ":.*\\)") + '(1 'org-archived prepend)) + ;; Specials + '(org-do-latex-and-special-faces) + ;; Code + '(org-activate-code (1 'org-code t)) ;; COMMENT (list (concat "^\\*+[ \t]+\\<\\(" org-comment-string "\\|" org-quote-string "\\)\\>") '(1 'org-special-keyword t)) '("^#.*" (0 'font-lock-comment-face t)) - '("^\\*+ \\(.*:ARCHIVE:.*\\)" (1 'org-archived prepend)) - ;; Code - '(org-activate-code (1 'org-code t)) ))) (setq org-font-lock-extra-keywords (delq nil org-font-lock-extra-keywords)) ;; Now set the full font-lock-keywords @@ -5348,12 +5686,12 @@ If KWD is a number, get the corresponding match group." (>= (match-end 0) pos)))) t (eq org-cycle-emulate-tab t)) - (if (and (looking-at "[ \n\r\t]") - (string-match "^[ \t]*$" (buffer-substring - (point-at-bol) (point)))) - (progn - (beginning-of-line 1) - (and (looking-at "[ \t]+") (replace-match "")))) +; (if (and (looking-at "[ \n\r\t]") +; (string-match "^[ \t]*$" (buffer-substring +; (point-at-bol) (point)))) +; (progn +; (beginning-of-line 1) +; (and (looking-at "[ \t]+") (replace-match "")))) (call-interactively (global-key-binding "\t"))) (t (save-excursion @@ -5421,6 +5759,17 @@ This function is the default value of the hook `org-cycle-hook'." ((eq state 'children) (or (org-subtree-end-visible-p) (recenter 1))) ((eq state 'subtree) (or (org-subtree-end-visible-p) (recenter 1)))))) +(defun org-compact-display-after-subtree-move () + (let (beg end) + (save-excursion + (if (org-up-heading-safe) + (progn + (hide-subtree) + (show-entry) + (show-children) + (org-cycle-show-empty-lines 'children) + (org-cycle-hide-drawers 'children)) + (org-overview))))) (defun org-cycle-show-empty-lines (state) "Show empty lines above all visible headlines. @@ -5511,6 +5860,8 @@ RET=jump to location [Q]uit and return to previous location \[Up]/[Down]=next/prev headline TAB=cycle visibility [/] org-occur" ) +(defvar org-goto-start-pos) ; dynamically scoped parameter + (defun org-goto () "Look up a different location in the current file, keeping current visibility. @@ -5634,8 +5985,10 @@ or nil." "Create indirect buffer and narrow it to current subtree. With numerical prefix ARG, go up to this level and then take that tree. If ARG is negative, go up that many levels. -Normally this command removes the indirect buffer previously made -with this command. However, when called with a C-u prefix, the last buffer +If `org-indirect-buffer-display' is not `new-frame', the command removes the +indirect buffer previously made with this command, to avoid proliferation of +indirect buffers. However, when you call the command with a `C-u' prefix, or +when `org-indirect-buffer-display' is `new-frame', the last buffer is kept so that you can work with several indirect buffers at the same time. If `org-indirect-buffer-display' is `dedicated-frame', the C-u prefix also requests that a new frame be made for the new buffer, so that the dedicated @@ -5655,8 +6008,9 @@ frame is not changed." (setq beg (point) heading (org-get-heading)) (org-end-of-subtree t) (setq end (point))) - (if (and (not arg) - (buffer-live-p org-last-indirect-buffer)) + (if (and (buffer-live-p org-last-indirect-buffer) + (not (eq org-indirect-buffer-display 'new-frame)) + (not arg)) (kill-buffer org-last-indirect-buffer)) (setq ibuf (org-get-indirect-buffer cbuf) org-last-indirect-buffer ibuf) @@ -5920,7 +6274,8 @@ would end up with no indentation after the change, nothing at all is done." col) (unless (save-excursion (end-of-line 1) (re-search-forward prohibit end t)) - (while (re-search-forward "^[ \t]+" end t) + (while (and (< (point) end) + (re-search-forward "^[ \t]+" end t)) (goto-char (match-end 0)) (setq col (current-column)) (if (< diff 0) (replace-match "")) @@ -5983,38 +6338,65 @@ is signaled in this case." 'outline-get-last-sibling)) (ins-point (make-marker)) (cnt (abs arg)) - beg end txt folded) + beg beg0 end txt folded ne-beg ne-end ne-ins ins-end) ;; Select the tree (org-back-to-heading) - (setq beg (point)) + (setq beg0 (point)) + (save-excursion + (setq ne-beg (org-back-over-empty-lines)) + (setq beg (point))) (save-match-data (save-excursion (outline-end-of-heading) (setq folded (org-invisible-p))) (outline-end-of-subtree)) (outline-next-heading) + (setq ne-end (org-back-over-empty-lines)) (setq end (point)) + (goto-char beg0) + (when (and (> arg 0) (org-first-sibling-p) (< ne-end ne-beg)) + ;; include less whitespace + (save-excursion + (goto-char beg) + (forward-line (- ne-beg ne-end)) + (setq beg (point)))) ;; Find insertion point, with error handling - (goto-char beg) (while (> cnt 0) (or (and (funcall movfunc) (looking-at outline-regexp)) - (progn (goto-char beg) + (progn (goto-char beg0) (error "Cannot move past superior level or buffer limit"))) (setq cnt (1- cnt))) (if (> arg 0) ;; Moving forward - still need to move over subtree - (progn (outline-end-of-subtree) - (outline-next-heading) - (if (not (or (looking-at (concat "^" outline-regexp)) - (bolp))) - (newline)))) + (progn (org-end-of-subtree t t) + (save-excursion + (org-back-over-empty-lines) + (or (bolp) (newline))))) + (setq ne-ins (org-back-over-empty-lines)) (move-marker ins-point (point)) (setq txt (buffer-substring beg end)) (delete-region beg end) + (outline-flag-region (1- beg) beg nil) + (outline-flag-region (1- (point)) (point) nil) (insert txt) (or (bolp) (insert "\n")) + (setq ins-end (point)) (goto-char ins-point) - (if folded (hide-subtree)) - (move-marker ins-point nil))) + (org-skip-whitespace) + (when (and (< arg 0) + (org-first-sibling-p) + (> ne-ins ne-beg)) + ;; Move whitespace back to beginning + (save-excursion + (goto-char ins-end) + (let ((kill-whole-line t)) + (kill-line (- ne-ins ne-beg)) (point))) + (insert (make-string (- ne-ins ne-beg) ?\n))) + (move-marker ins-point nil) + (org-compact-display-after-subtree-move) + (unless folded + (org-show-entry) + (show-children) + (org-cycle-hide-drawers 'children)))) (defvar org-subtree-clip "" "Clipboard for cut and paste of subtrees. @@ -6038,11 +6420,13 @@ With prefix arg N, cut this many sequential subtrees. This is a short-hand for marking the subtree and then copying it. If CUT is non-nil, actually cut the subtree." (interactive "p") - (let (beg end folded) + (let (beg end folded (beg0 (point))) (if (interactive-p) (org-back-to-heading nil) ; take what looks like a subtree (org-back-to-heading t)) ; take what is really there + (org-back-over-empty-lines) (setq beg (point)) + (skip-chars-forward " \t\r\n") (save-match-data (save-excursion (outline-end-of-heading) (setq folded (org-invisible-p))) @@ -6050,8 +6434,9 @@ If CUT is non-nil, actually cut the subtree." (outline-forward-same-level (1- n)) (error nil)) (org-end-of-subtree t t)) + (org-back-over-empty-lines) (setq end (point)) - (goto-char beg) + (goto-char beg0) (when (> end beg) (setq org-subtree-clip-folded folded) (if cut (kill-region beg end) (copy-region-as-kill beg end)) @@ -6127,11 +6512,14 @@ If optional TREE is given, use this text instead of the kill ring." (delete-region (point-at-bol) (point))) ;; Paste (beginning-of-line 1) + (org-back-over-empty-lines) ;; FIXME: correct fix???? (setq beg (point)) - (insert txt) - (unless (string-match "\n[ \t]*\\'" txt) (insert "\n")) + (insert-before-markers txt) ;; FIXME: correct fix???? + (unless (string-match "\n\\'" txt) (insert "\n")) (setq end (point)) (goto-char beg) + (skip-chars-forward " \t\n\r") + (setq beg (point)) ;; Shift if necessary (unless (= shift 0) (save-restriction @@ -6157,10 +6545,12 @@ which is OK for `org-paste-subtree'. If optional TXT is given, check this string instead of the current kill." (let* ((kill (or txt (and kill-ring (current-kill 0)) "")) (start-level (and kill - (string-match (concat "\\`" org-outline-regexp) kill) - (- (match-end 0) (match-beginning 0) 1))) + (string-match (concat "\\`\\([ \t\n\r]*?\n\\)?\\(" + org-outline-regexp "\\)") + kill) + (- (match-end 2) (match-beginning 2) 1))) (re (concat "^" org-outline-regexp)) - (start 1)) + (start (1+ (match-beginning 2)))) (if (not start-level) (progn nil) ;; does not even start with a heading @@ -6231,7 +6621,11 @@ WITH-CASE, the sorting considers case as well." (condition-case nil (progn (org-back-to-heading) t) (error nil))) ;; we will sort the children of the current headline (org-back-to-heading) - (setq start (point) end (org-end-of-subtree) what "children") + (setq start (point) + end (progn (org-end-of-subtree t t) + (org-back-over-empty-lines) + (point)) + what "children") (goto-char start) (show-subtree) (outline-next-heading)) @@ -6312,12 +6706,12 @@ WITH-CASE, the sorting considers case as well." (cond ((= dcst ?n) (string-to-number (buffer-substring (match-end 0) - (line-end-position)))) + (point-at-eol)))) ((= dcst ?a) - (buffer-substring (match-end 0) (line-end-position))) + (buffer-substring (match-end 0) (point-at-eol))) ((= dcst ?t) (if (re-search-forward org-ts-regexp - (line-end-position) t) + (point-at-eol) t) (org-time-string-to-time (match-string 0)) now)) ((= dcst ?f) @@ -6333,11 +6727,11 @@ WITH-CASE, the sorting considers case as well." ((= dcst ?n) (if (looking-at outline-regexp) (string-to-number (buffer-substring (match-end 0) - (line-end-position))) + (point-at-eol))) nil)) ((= dcst ?a) - (funcall case-func (buffer-substring (line-beginning-position) - (line-end-position)))) + (funcall case-func (buffer-substring (point-at-bol) + (point-at-eol)))) ((= dcst ?t) (if (re-search-forward org-ts-regexp (save-excursion @@ -6346,7 +6740,7 @@ WITH-CASE, the sorting considers case as well." (org-time-string-to-time (match-string 0)) now)) ((= dcst ?p) - (if (re-search-forward org-priority-regexp (line-end-position) t) + (if (re-search-forward org-priority-regexp (point-at-eol) t) (string-to-char (match-string 2)) org-default-priority)) ((= dcst ?r) @@ -6386,7 +6780,8 @@ If WITH-CASE is non-nil, the sorting will be case-sensitive." (setq extractfun 'string-to-number comparefun (if (= dcst sorting-type) '< '>))) ((= dcst ?a) - (setq extractfun (if with-case 'identity 'downcase) + (setq extractfun (if with-case (lambda(x) (org-sort-remove-invisible x)) + (lambda(x) (downcase (org-sort-remove-invisible x)))) comparefun (if (= dcst sorting-type) 'string< (lambda (a b) (and (not (string< a b)) @@ -6486,12 +6881,13 @@ Return t when things worked, nil when we are not in an item." ((org-on-heading-p) (setq beg (point) end (save-excursion (outline-next-heading) (point)))) ((org-at-item-checkbox-p) - (save-excursion + (let ((pos (point))) (replace-match (cond (arg "[-]") ((member (match-string 0) '("[ ]" "[-]")) "[X]") (t "[ ]")) - t t)) + t t) + (goto-char pos)) (throw 'exit t)) (t (error "Not at a checkbox or heading, and no active region"))) (save-excursion @@ -6710,27 +7106,49 @@ Error if not at a plain list, or if this is the first item in the list." (error (goto-char pos) (error "On first item"))))) +(defun org-first-list-item-p () + "Is this heading the item in a plain list?" + (unless (org-at-item-p) + (error "Not at a plain list item")) + (org-beginning-of-item) + (= (point) (save-excursion (org-beginning-of-item-list)))) + (defun org-move-item-down () "Move the plain list item at point down, i.e. swap with following item. Subitems (items with larger indentation) are considered part of the item, so this really moves item trees." (interactive) - (let (beg end ind ind1 (pos (point)) txt) + (let (beg beg0 end end0 ind ind1 (pos (point)) txt ne-end ne-beg) (org-beginning-of-item) - (setq beg (point)) + (setq beg0 (point)) + (save-excursion + (setq ne-beg (org-back-over-empty-lines)) + (setq beg (point))) + (goto-char beg0) (setq ind (org-get-indentation)) (org-end-of-item) - (setq end (point)) + (setq end0 (point)) (setq ind1 (org-get-indentation)) + (setq ne-end (org-back-over-empty-lines)) + (setq end (point)) + (goto-char beg0) + (when (and (org-first-list-item-p) (< ne-end ne-beg)) + ;; include less whitespace + (save-excursion + (goto-char beg) + (forward-line (- ne-beg ne-end)) + (setq beg (point)))) + (goto-char end0) (if (and (org-at-item-p) (= ind ind1)) (progn (org-end-of-item) + (org-back-over-empty-lines) (setq txt (buffer-substring beg end)) (save-excursion (delete-region beg end)) (setq pos (point)) (insert txt) - (goto-char pos) + (goto-char pos) (org-skip-whitespace) (org-maybe-renumber-ordered-list)) (goto-char pos) (error "Cannot move this item further down")))) @@ -6740,13 +7158,19 @@ so this really moves item trees." Subitems (items with larger indentation) are considered part of the item, so this really moves item trees." (interactive "p") - (let (beg end ind ind1 (pos (point)) txt) + (let (beg beg0 end end0 ind ind1 (pos (point)) txt + ne-beg ne-end ne-ins ins-end) (org-beginning-of-item) - (setq beg (point)) + (setq beg0 (point)) (setq ind (org-get-indentation)) + (save-excursion + (setq ne-beg (org-back-over-empty-lines)) + (setq beg (point))) + (goto-char beg0) (org-end-of-item) + (setq ne-end (org-back-over-empty-lines)) (setq end (point)) - (goto-char beg) + (goto-char beg0) (catch 'exit (while t (beginning-of-line 0) @@ -6765,12 +7189,23 @@ so this really moves item trees." (setq ind1 (org-get-indentation)) (if (and (org-at-item-p) (= ind ind1)) (progn + (setq ne-ins (org-back-over-empty-lines)) (setq txt (buffer-substring beg end)) (save-excursion (delete-region beg end)) (setq pos (point)) (insert txt) - (goto-char pos) + (setq ins-end (point)) + (goto-char pos) (org-skip-whitespace) + + (when (and (org-first-list-item-p) (> ne-ins ne-beg)) + ;; Move whitespace back to beginning + (save-excursion + (goto-char ins-end) + (let ((kill-whole-line t)) + (kill-line (- ne-ins ne-beg)) (point))) + (insert (make-string (- ne-ins ne-beg) ?\n))) + (org-maybe-renumber-ordered-list)) (goto-char pos) (error "Cannot move this item further up")))) @@ -7108,7 +7543,7 @@ off orgstruct-mode will *not* remove these additonal settings." (defun orgstruct-error () "Error when there is no default binding for a structure key." (interactive) - (error "This key is has no function outside structure elements")) + (error "This key has no function outside structure elements")) (defun orgstruct-setup () "Setup orgstruct keymaps." @@ -7255,7 +7690,8 @@ this heading." (this-buffer (current-buffer)) (org-archive-location org-archive-location) (re "^#\\+ARCHIVE:[ \t]+\\(\\S-.*\\S-\\)[ \t]*$") - ;; start of variables that will be used for savind context + ;; start of variables that will be used for saving context + ;; The compiler complains about them - keep them anyway! (file (abbreviate-file-name (buffer-file-name))) (time (format-time-string (substring (cdr org-time-stamp-formats) 1 -1) @@ -7472,7 +7908,8 @@ When TAG is non-nil, don't move trees, but mark them with the ARCHIVE tag." (save-excursion (beginning-of-line 1) (when (looking-at "^[ \t]*:[a-zA-Z][a-zA-Z0-9]*:") - (let ((b (match-end 0))) + (let ((b (match-end 0)) + (outline-regexp org-outline-regexp)) (if (re-search-forward "^[ \t]*:END:" (save-excursion (outline-next-heading) (point)) t) @@ -7491,7 +7928,7 @@ When TAG is non-nil, don't move trees, but mark them with the ARCHIVE tag." (goto-char beg) (if (looking-at (concat ".*:" org-archive-tag ":")) (message "%s" (substitute-command-keys - "Subtree is archived and stays closed. Use \\[org-force-cycle-archived] to cycle it anyway."))))))) + "Subtree is archived and stays closed. Use \\[org-force-cycle-archived] to cycle it anyway."))))))) (defun org-force-cycle-archived () "Cycle subtree even if it is archived." @@ -7833,19 +8270,23 @@ This is being used to correctly align a single field after TAB or RET.") (make-string sp2 ?\ ) "%%%s%ds" (make-string sp1 ?\ ) "|")) (hfmt1 (concat (make-string sp2 ?-) "%s" (make-string sp1 ?-) "+")) - emptystrings links dates narrow fmax f1 len c e) + emptystrings links dates emph narrow fmax f1 len c e) (untabify beg end) (remove-text-properties beg end '(org-cwidth t org-dwidth t display t)) ;; Check if we have links or dates (goto-char beg) (setq links (re-search-forward org-bracket-link-regexp end t)) (goto-char beg) + (setq emph (and org-hide-emphasis-markers + (re-search-forward org-emph-re end t))) + (goto-char beg) (setq dates (and org-display-custom-times (re-search-forward org-ts-regexp-both end t))) ;; Make sure the link properties are right (when links (goto-char beg) (while (org-activate-bracket-links end))) ;; Make sure the date properties are right (when dates (goto-char beg) (while (org-activate-dates end))) + (when emph (goto-char beg) (while (org-do-emphasis-faces end))) ;; Check if we are narrowing any columns (goto-char beg) @@ -7926,13 +8367,14 @@ This is being used to correctly align a single field after TAB or RET.") ;; With invisible characters, `format' does not get the field width right ;; So we need to make these fields wide by hand. - (when links + (when (or links emph) (loop for i from 0 upto (1- maxfields) do (setq len (nth i lengths)) (loop for j from 0 upto (1- (length fields)) do (setq c (nthcdr i (car (nthcdr j fields)))) (if (and (stringp (car c)) - (string-match org-bracket-link-regexp (car c)) + (text-property-any 0 (length (car c)) 'invisible 'org-link (car c)) +; (string-match org-bracket-link-regexp (car c)) (< (org-string-width (car c)) len)) (setcar c (concat (car c) (make-string (- len (org-string-width (car c))) ?\ ))))))) @@ -8656,7 +9098,11 @@ should be done in reverse order." (skip-chars-backward "^|") (setq ecol (1- (current-column))) (org-table-goto-column column) - (setq lns (mapcar (lambda(x) (cons (org-trim (substring x bcol ecol)) x)) + (setq lns (mapcar (lambda(x) (cons + (org-sort-remove-invisible + (nth (1- column) + (org-split-string x "[ \t]*|[ \t]*"))) + x)) (org-split-string (buffer-substring beg end) "\n"))) (setq lns (org-do-sort lns "Table" with-case sorting-type)) (delete-region beg end) @@ -8667,6 +9113,15 @@ should be done in reverse order." (org-table-goto-column thiscol) (message "%d lines sorted, based on column %d" (length lns) column))) +;; FIXME: maybe we will not need this? Table sorting is broken.... +(defun org-sort-remove-invisible (s) + (remove-text-properties 0 (length s) org-rm-props s) + (while (string-match org-bracket-link-regexp s) + (setq s (replace-match (if (match-end 2) + (match-string 3 s) + (match-string 1 s)) t t s))) + s) + (defun org-table-cut-region (beg end) "Copy region in table to the clipboard and blank all relevant fields." (interactive "r") @@ -9369,8 +9824,7 @@ of the new mark." (goto-line l1))) (if (not (= epos (point-at-eol))) (org-table-align)) (goto-line l) - (and (interactive-p) - (message "%s" (or (cdr (assoc new org-recalc-marks)) ""))))) + (and (interactive-p) (message "%s" (cdr (assoc new org-recalc-marks)))))) (defun org-table-maybe-recalculate-line () "Recompute the current line if marked for it, and if we haven't just done it." @@ -10682,7 +11136,7 @@ to execute outside of tables." (defun orgtbl-error () "Error when there is no default binding for a table key." (interactive) - (error "This key is has no function outside tables")) + (error "This key has no function outside tables")) (defun orgtbl-setup () "Setup orgtbl keymaps." @@ -11268,7 +11722,7 @@ value. Each function should check if it is responsible for creating this link (for example by looking at the major mode). If not, it must exit and return nil. If yes, it should return a non-nil value after a calling -`org-store-link-properties' with a list of properties and values. +`org-store-link-props' with a list of properties and values. Special properties are: :type The link prefix. like \"http\". This must be given. @@ -11288,8 +11742,9 @@ FOLLOW and PUBLISH are two functions. Both take the link path as an argument. FOLLOW should do whatever is necessary to follow the link, for example to find a file or display a mail message. + PUBLISH takes the path and retuns the string that should be used when -this document is published." +this document is published. FIMXE: This is actually not yet implemented." (add-to-list 'org-link-types type t) (org-make-link-regexps) (add-to-list 'org-link-protocols @@ -11377,10 +11832,10 @@ For file links, arg negates `org-context-in-file-links'." (if (fboundp 'elmo-message-entity) (elmo-message-entity wl-summary-buffer-elmo-folder msgnum) - (elmo-msgdb-overview-get-entity - msgnum (wl-summary-buffer-msgdb)))) + (elmo-msgdb-overview-get-entity + msgnum (wl-summary-buffer-msgdb)))) (from (wl-summary-line-from)) - (to (elmo-message-entity-field wl-message-entity 'to)) + (to (car (elmo-message-entity-field wl-message-entity 'to))) (subject (let (wl-thr-indent-string wl-parent-message-entity) (wl-summary-line-subject)))) (org-store-link-props :type "wl" :from from :to to @@ -11616,8 +12071,10 @@ according to FMT (default from `org-email-link-description-format')." (error "Empty link")) (when (stringp description) ;; Remove brackets from the description, they are fatal. - (while (string-match "\\[\\|\\]" description) - (setq description (replace-match "" t t description)))) + (while (string-match "\\[" description) + (setq description (replace-match "{" t t description))) + (while (string-match "\\]" description) + (setq description (replace-match "}" t t description)))) (when (equal (org-link-escape link) description) ;; No description needed, it is identical (setq description nil)) @@ -11629,29 +12086,29 @@ according to FMT (default from `org-email-link-description-format')." "]")) (defconst org-link-escape-chars - '((" " . "%20") - ("[" . "%5B") - ("]" . "%5d") - ("\340" . "%E0") ; `a - ("\342" . "%E2") ; ^a - ("\347" . "%E7") ; ,c - ("\350" . "%E8") ; `e - ("\351" . "%E9") ; 'e - ("\352" . "%EA") ; ^e - ("\356" . "%EE") ; ^i - ("\364" . "%F4") ; ^o - ("\371" . "%F9") ; `u - ("\373" . "%FB") ; ^u - (";" . "%3B") - ("?" . "%3F") - ("=" . "%3D") - ("+" . "%2B") + '((?\ . "%20") + (?\[ . "%5B") + (?\] . "%5D") + (?\340 . "%E0") ; `a + (?\342 . "%E2") ; ^a + (?\347 . "%E7") ; ,c + (?\350 . "%E8") ; `e + (?\351 . "%E9") ; 'e + (?\352 . "%EA") ; ^e + (?\356 . "%EE") ; ^i + (?\364 . "%F4") ; ^o + (?\371 . "%F9") ; `u + (?\373 . "%FB") ; ^u + (?\; . "%3B") + (?? . "%3F") + (?= . "%3D") + (?+ . "%2B") ) "Association list of escapes for some characters problematic in links. This is the list that is used for internal purposes.") (defconst org-link-escape-chars-browser - '((" " . "%20")) + '((?\ . "%20")) ; 32 for the SPC char "Association list of escapes for some characters problematic in links. This is the list that is used before handing over to the browser.") @@ -11659,12 +12116,14 @@ This is the list that is used before handing over to the browser.") "Escape charaters in TEXT that are problematic for links." (setq table (or table org-link-escape-chars)) (when text - (let ((re (mapconcat (lambda (x) (regexp-quote (car x))) + (let ((re (mapconcat (lambda (x) (regexp-quote + (char-to-string (car x)))) table "\\|"))) (while (string-match re text) (setq text (replace-match - (cdr (assoc (match-string 0 text) table)) + (cdr (assoc (string-to-char (match-string 0 text)) + table)) t t text))) text))) @@ -11677,7 +12136,7 @@ This is the list that is used before handing over to the browser.") (while (string-match re text) (setq text (replace-match - (car (rassoc (match-string 0 text) table)) + (char-to-string (car (rassoc (match-string 0 text) table))) t t text))) text))) @@ -11960,189 +12419,192 @@ the end of the current subtree. Normally, files will be opened by an appropriate application. If the optional argument IN-EMACS is non-nil, Emacs will visit the file." (interactive "P") - (move-marker org-open-link-marker (point)) - (setq org-window-config-before-follow-link (current-window-configuration)) - (org-remove-occur-highlights nil nil t) - (if (org-at-timestamp-p t) - (org-follow-timestamp-link) - (let (type path link line search (pos (point))) - (catch 'match - (save-excursion - (skip-chars-forward "^]\n\r") - (when (org-in-regexp org-bracket-link-regexp) - (setq link (org-link-unescape (org-match-string-no-properties 1))) - (while (string-match " *\n *" link) - (setq link (replace-match " " t t link))) - (setq link (org-link-expand-abbrev link)) - (if (string-match org-link-re-with-space2 link) - (setq type (match-string 1 link) path (match-string 2 link)) - (setq type "thisfile" path link)) - (throw 'match t))) + (catch 'abort + (move-marker org-open-link-marker (point)) + (setq org-window-config-before-follow-link (current-window-configuration)) + (org-remove-occur-highlights nil nil t) + (if (org-at-timestamp-p t) + (org-follow-timestamp-link) + (let (type path link line search (pos (point))) + (catch 'match + (save-excursion + (skip-chars-forward "^]\n\r") + (when (org-in-regexp org-bracket-link-regexp) + (setq link (org-link-unescape (org-match-string-no-properties 1))) + (while (string-match " *\n *" link) + (setq link (replace-match " " t t link))) + (setq link (org-link-expand-abbrev link)) + (if (string-match org-link-re-with-space2 link) + (setq type (match-string 1 link) path (match-string 2 link)) + (setq type "thisfile" path link)) + (throw 'match t))) - (when (get-text-property (point) 'org-linked-text) - (setq type "thisfile" - pos (if (get-text-property (1+ (point)) 'org-linked-text) - (1+ (point)) (point)) - path (buffer-substring - (previous-single-property-change pos 'org-linked-text) - (next-single-property-change pos 'org-linked-text))) - (throw 'match t)) + (when (get-text-property (point) 'org-linked-text) + (setq type "thisfile" + pos (if (get-text-property (1+ (point)) 'org-linked-text) + (1+ (point)) (point)) + path (buffer-substring + (previous-single-property-change pos 'org-linked-text) + (next-single-property-change pos 'org-linked-text))) + (throw 'match t)) - (save-excursion - (when (or (org-in-regexp org-angle-link-re) - (org-in-regexp org-plain-link-re)) - (setq type (match-string 1) path (match-string 2)) - (throw 'match t))) - (when (org-in-regexp "\\<\\([^><\n]+\\)\\>") - (setq type "tree-match" - path (match-string 1)) - (throw 'match t)) - (save-excursion - (when (org-in-regexp (org-re "\\(:[[:alnum:]_@:]+\\):[ \t]*$")) - (setq type "tags" + (save-excursion + (when (or (org-in-regexp org-angle-link-re) + (org-in-regexp org-plain-link-re)) + (setq type (match-string 1) path (match-string 2)) + (throw 'match t))) + (when (org-in-regexp "\\<\\([^><\n]+\\)\\>") + (setq type "tree-match" path (match-string 1)) - (while (string-match ":" path) - (setq path (replace-match "+" t t path))) - (throw 'match t)))) - (unless path - (error "No link found")) - ;; Remove any trailing spaces in path - (if (string-match " +\\'" path) - (setq path (replace-match "" t t path))) + (throw 'match t)) + (save-excursion + (when (org-in-regexp (org-re "\\(:[[:alnum:]_@:]+\\):[ \t]*$")) + (setq type "tags" + path (match-string 1)) + (while (string-match ":" path) + (setq path (replace-match "+" t t path))) + (throw 'match t)))) + (unless path + (error "No link found")) + ;; Remove any trailing spaces in path + (if (string-match " +\\'" path) + (setq path (replace-match "" t t path))) - (cond + (cond - ((assoc type org-link-protocols) - (funcall (nth 1 (assoc type org-link-protocols)) path)) + ((assoc type org-link-protocols) + (funcall (nth 1 (assoc type org-link-protocols)) path)) - ((equal type "mailto") - (let ((cmd (car org-link-mailto-program)) - (args (cdr org-link-mailto-program)) args1 - (address path) (subject "") a) - (if (string-match "\\(.*\\)::\\(.*\\)" path) - (setq address (match-string 1 path) - subject (org-link-escape (match-string 2 path)))) - (while args - (cond - ((not (stringp (car args))) (push (pop args) args1)) - (t (setq a (pop args)) - (if (string-match "%a" a) - (setq a (replace-match address t t a))) - (if (string-match "%s" a) - (setq a (replace-match subject t t a))) - (push a args1)))) - (apply cmd (nreverse args1)))) + ((equal type "mailto") + (let ((cmd (car org-link-mailto-program)) + (args (cdr org-link-mailto-program)) args1 + (address path) (subject "") a) + (if (string-match "\\(.*\\)::\\(.*\\)" path) + (setq address (match-string 1 path) + subject (org-link-escape (match-string 2 path)))) + (while args + (cond + ((not (stringp (car args))) (push (pop args) args1)) + (t (setq a (pop args)) + (if (string-match "%a" a) + (setq a (replace-match address t t a))) + (if (string-match "%s" a) + (setq a (replace-match subject t t a))) + (push a args1)))) + (apply cmd (nreverse args1)))) - ((member type '("http" "https" "ftp" "news")) - (browse-url (concat type ":" (org-link-escape - path org-link-escape-chars-browser)))) + ((member type '("http" "https" "ftp" "news")) + (browse-url (concat type ":" (org-link-escape + path org-link-escape-chars-browser)))) - ((string= type "tags") - (org-tags-view in-emacs path)) - ((string= type "thisfile") - (if in-emacs - (switch-to-buffer-other-window - (org-get-buffer-for-internal-link (current-buffer))) - (org-mark-ring-push)) - (let ((cmd `(org-link-search - ,path - ,(cond ((equal in-emacs '(4)) 'occur) - ((equal in-emacs '(16)) 'org-occur) - (t nil)) - ,pos))) - (condition-case nil (eval cmd) - (error (progn (widen) (eval cmd)))))) + ((member type '("message")) + (browse-url (concat type ":" path))) - ((string= type "tree-match") - (org-occur (concat "\\[" (regexp-quote path) "\\]"))) + ((string= type "tags") + (org-tags-view in-emacs path)) + ((string= type "thisfile") + (if in-emacs + (switch-to-buffer-other-window + (org-get-buffer-for-internal-link (current-buffer))) + (org-mark-ring-push)) + (let ((cmd `(org-link-search + ,path + ,(cond ((equal in-emacs '(4)) 'occur) + ((equal in-emacs '(16)) 'org-occur) + (t nil)) + ,pos))) + (condition-case nil (eval cmd) + (error (progn (widen) (eval cmd)))))) - ((string= type "file") - (if (string-match "::\\([0-9]+\\)\\'" path) - (setq line (string-to-number (match-string 1 path)) - path (substring path 0 (match-beginning 0))) - (if (string-match "::\\(.+\\)\\'" path) - (setq search (match-string 1 path) - path (substring path 0 (match-beginning 0))))) - (org-open-file path in-emacs line search)) + ((string= type "tree-match") + (org-occur (concat "\\[" (regexp-quote path) "\\]"))) - ((string= type "news") - (org-follow-gnus-link path)) + ((string= type "file") + (if (string-match "::\\([0-9]+\\)\\'" path) + (setq line (string-to-number (match-string 1 path)) + path (substring path 0 (match-beginning 0))) + (if (string-match "::\\(.+\\)\\'" path) + (setq search (match-string 1 path) + path (substring path 0 (match-beginning 0))))) + (if (string-match "[*?{]" (file-name-nondirectory path)) + (dired path) + (org-open-file path in-emacs line search))) - ((string= type "bbdb") - (org-follow-bbdb-link path)) + ((string= type "news") + (org-follow-gnus-link path)) - ((string= type "info") - (org-follow-info-link path)) + ((string= type "bbdb") + (org-follow-bbdb-link path)) - ((string= type "gnus") - (let (group article) - (if (not (string-match "\\`\\([^#]+\\)\\(#\\(.*\\)\\)?" path)) - (error "Error in Gnus link")) - (setq group (match-string 1 path) - article (match-string 3 path)) - (org-follow-gnus-link group article))) + ((string= type "info") + (org-follow-info-link path)) - ((string= type "vm") - (let (folder article) - (if (not (string-match "\\`\\([^#]+\\)\\(#\\(.*\\)\\)?" path)) - (error "Error in VM link")) - (setq folder (match-string 1 path) - article (match-string 3 path)) - ;; in-emacs is the prefix arg, will be interpreted as read-only - (org-follow-vm-link folder article in-emacs))) + ((string= type "gnus") + (let (group article) + (if (not (string-match "\\`\\([^#]+\\)\\(#\\(.*\\)\\)?" path)) + (error "Error in Gnus link")) + (setq group (match-string 1 path) + article (match-string 3 path)) + (org-follow-gnus-link group article))) - ((string= type "wl") - (let (folder article) - (if (not (string-match "\\`\\([^#]+\\)\\(#\\(.*\\)\\)?" path)) - (error "Error in Wanderlust link")) - (setq folder (match-string 1 path) - article (match-string 3 path)) - (org-follow-wl-link folder article))) + ((string= type "vm") + (let (folder article) + (if (not (string-match "\\`\\([^#]+\\)\\(#\\(.*\\)\\)?" path)) + (error "Error in VM link")) + (setq folder (match-string 1 path) + article (match-string 3 path)) + ;; in-emacs is the prefix arg, will be interpreted as read-only + (org-follow-vm-link folder article in-emacs))) - ((string= type "mhe") - (let (folder article) - (if (not (string-match "\\`\\([^#]+\\)\\(#\\(.*\\)\\)?" path)) - (error "Error in MHE link")) - (setq folder (match-string 1 path) - article (match-string 3 path)) - (org-follow-mhe-link folder article))) + ((string= type "wl") + (let (folder article) + (if (not (string-match "\\`\\([^#]+\\)\\(#\\(.*\\)\\)?" path)) + (error "Error in Wanderlust link")) + (setq folder (match-string 1 path) + article (match-string 3 path)) + (org-follow-wl-link folder article))) - ((string= type "rmail") - (let (folder article) - (if (not (string-match "\\`\\([^#]+\\)\\(#\\(.*\\)\\)?" path)) - (error "Error in RMAIL link")) - (setq folder (match-string 1 path) - article (match-string 3 path)) - (org-follow-rmail-link folder article))) + ((string= type "mhe") + (let (folder article) + (if (not (string-match "\\`\\([^#]+\\)\\(#\\(.*\\)\\)?" path)) + (error "Error in MHE link")) + (setq folder (match-string 1 path) + article (match-string 3 path)) + (org-follow-mhe-link folder article))) - ((string= type "shell") - (let ((cmd path)) - ;; The following is only for backward compatibility - (while (string-match "@{" cmd) (setq cmd (replace-match "<" t t cmd))) - (while (string-match "@}" cmd) (setq cmd (replace-match ">" t t cmd))) - (if (or (not org-confirm-shell-link-function) - (funcall org-confirm-shell-link-function - (format "Execute \"%s\" in shell? " - (org-add-props cmd nil - 'face 'org-warning)))) - (progn - (message "Executing %s" cmd) - (shell-command cmd)) - (error "Abort")))) + ((string= type "rmail") + (let (folder article) + (if (not (string-match "\\`\\([^#]+\\)\\(#\\(.*\\)\\)?" path)) + (error "Error in RMAIL link")) + (setq folder (match-string 1 path) + article (match-string 3 path)) + (org-follow-rmail-link folder article))) - ((string= type "elisp") - (let ((cmd path)) - (if (or (not org-confirm-elisp-link-function) - (funcall org-confirm-elisp-link-function - (format "Execute \"%s\" as elisp? " - (org-add-props cmd nil - 'face 'org-warning)))) - (message "%s => %s" cmd (eval (read cmd))) - (error "Abort")))) + ((string= type "shell") + (let ((cmd path)) + (if (or (not org-confirm-shell-link-function) + (funcall org-confirm-shell-link-function + (format "Execute \"%s\" in shell? " + (org-add-props cmd nil + 'face 'org-warning)))) + (progn + (message "Executing %s" cmd) + (shell-command cmd)) + (error "Abort")))) - (t - (browse-url-at-point))))) - (move-marker org-open-link-marker nil)) + ((string= type "elisp") + (let ((cmd path)) + (if (or (not org-confirm-elisp-link-function) + (funcall org-confirm-elisp-link-function + (format "Execute \"%s\" as elisp? " + (org-add-props cmd nil + 'face 'org-warning)))) + (message "%s => %s" cmd (eval (read cmd))) + (error "Abort")))) + + (t + (browse-url-at-point))))) + (move-marker org-open-link-marker nil))) ;;; File search @@ -12730,9 +13192,10 @@ If the file does not exist, an error is thrown." (cond ((and (stringp cmd) (not (string-match "^\\s-*$" cmd))) ;; Remove quotes around the file name - we'll use shell-quote-argument. - (if (string-match "['\"]%s['\"]" cmd) - (setq cmd (replace-match "%s" t t cmd))) - (setq cmd (format cmd (shell-quote-argument file))) + (while (string-match "['\"]%s['\"]" cmd) + (setq cmd (replace-match "%s" t t cmd))) + (while (string-match "%s" cmd) + (setq cmd (replace-match (shell-quote-argument file) t t cmd))) (save-window-excursion (start-process-shell-command cmd nil cmd))) ((or (stringp cmd) @@ -12775,7 +13238,18 @@ on the system \"/user@host:\"." (t nil))) -;;;; Hooks for remember.el +;;;; Hooks for remember.el, and refiling + +(defvar annotation) ; from remember.el, dynamically scoped in `remember-mode' +(defvar initial) ; from remember.el, dynamically scoped in `remember-mode' + +;;;###autoload +(defun org-remember-insinuate () + "Setup remember.el for use wiht Org-mode." + (require 'remember) + (setq remember-annotation-functions '(org-remember-annotation)) + (setq remember-handler-functions '(org-remember-handler)) + (add-hook 'remember-mode-hook 'org-remember-apply-template)) ;;;###autoload (defun org-remember-annotation () @@ -12795,44 +13269,54 @@ RET at beg-of-buf -> Append to file as level 2 headline (defvar org-remember-previous-location nil) (defvar org-force-remember-template-char) ;; dynamically scoped +(defun org-select-remember-template (&optional use-char) + (when org-remember-templates + (let* ((templates (mapcar (lambda (x) + (if (stringp (car x)) + (append (list (nth 1 x) (car x)) (cddr x)) + (append (list (car x) "") (cdr x)))) + org-remember-templates)) + (char (or use-char + (cond + ((= (length templates) 1) + (caar templates)) + ((and (boundp 'org-force-remember-template-char) + org-force-remember-template-char) + (if (stringp org-force-remember-template-char) + (string-to-char org-force-remember-template-char) + org-force-remember-template-char)) + (t + (message "Select template: %s" + (mapconcat + (lambda (x) + (cond + ((not (string-match "\\S-" (nth 1 x))) + (format "[%c]" (car x))) + ((equal (downcase (car x)) + (downcase (aref (nth 1 x) 0))) + (format "[%c]%s" (car x) + (substring (nth 1 x) 1))) + (t (format "[%c]%s" (car x) (nth 1 x))))) + templates " ")) + (let ((inhibit-quit t) (char0 (read-char-exclusive))) + (when (equal char0 ?\C-g) + (jump-to-register remember-register) + (kill-buffer remember-buffer)) + char0)))))) + (cddr (assoc char templates))))) + +(defvar x-last-selected-text) +(defvar x-last-selected-text-primary) + ;;;###autoload (defun org-remember-apply-template (&optional use-char skip-interactive) "Initialize *remember* buffer with template, invoke `org-mode'. This function should be placed into `remember-mode-hook' and in fact requires -to be run from that hook to fucntion properly." +to be run from that hook to function properly." + (unless (fboundp 'remember-finalize) + (defalias 'remember-finalize 'remember-buffer)) (if org-remember-templates - (let* ((templates (mapcar (lambda (x) - (if (stringp (car x)) - (append (list (nth 1 x) (car x)) (cddr x)) - (append (list (car x) "") (cdr x)))) - org-remember-templates)) - (char (or use-char - (cond - ((= (length templates) 1) - (caar templates)) - ((and (boundp 'org-force-remember-template-char) - org-force-remember-template-char) - (if (stringp org-force-remember-template-char) - (string-to-char org-force-remember-template-char) - org-force-remember-template-char)) - (t - (message "Select template: %s" - (mapconcat - (lambda (x) - (cond - ((not (string-match "\\S-" (nth 1 x))) - (format "[%c]" (car x))) - ((equal (downcase (car x)) - (downcase (aref (nth 1 x) 0))) - (format "[%c]%s" (car x) (substring (nth 1 x) 1))) - (t (format "[%c]%s" (car x) (nth 1 x))))) - templates " ")) - (let ((inhibit-quit t) (char0 (read-char-exclusive))) - (when (equal char0 ?\C-g) - (jump-to-register remember-register) - (kill-buffer remember-buffer)) - char0))))) - (entry (cddr (assoc char templates))) + (let* ((entry (org-select-remember-template use-char)) (tpl (car entry)) (plist-p (if org-store-link-plist t nil)) (file (if (and (nth 1 entry) (stringp (nth 1 entry)) @@ -12840,6 +13324,12 @@ to be run from that hook to fucntion properly." (nth 1 entry) org-default-notes-file)) (headline (nth 2 entry)) + (v-c (or (and (eq window-system 'x) + (fboundp 'x-cut-buffer-or-selection-value) + (x-cut-buffer-or-selection-value)) + (org-bound-and-true-p x-last-selected-text) + (org-bound-and-true-p x-last-selected-text-primary) + (and (> (length kill-ring) 0) (current-kill 0)))) (v-t (format-time-string (car org-time-stamp-formats) (org-current-time))) (v-T (format-time-string (cdr org-time-stamp-formats) (org-current-time))) (v-u (concat "[" (substring v-t 1 -1) "]")) @@ -12855,11 +13345,12 @@ to be run from that hook to fucntion properly." v-a)) (v-n user-full-name) (org-startup-folded nil) - org-time-was-given org-end-time-was-given x prompt char time) + org-time-was-given org-end-time-was-given x + prompt completions char time pos default histvar) (setq org-store-link-plist (append (list :annotation v-a :initial v-i) org-store-link-plist)) - (unless tpl (setq tpl "") (message "No template") (ding)) + (unless tpl (setq tpl "") (message "No template") (ding) (sit-for 1)) (erase-buffer) (insert (substitute-command-keys (format @@ -12876,7 +13367,7 @@ to be run from that hook to fucntion properly." (or (cdr org-remember-previous-location) "???")))) (insert tpl) (goto-char (point-min)) ;; Simple %-escapes - (while (re-search-forward "%\\([tTuUaiA]\\)" nil t) + (while (re-search-forward "%\\([tTuUaiAc]\\)" nil t) (when (and initial (equal (match-string 0) "%i")) (save-match-data (let* ((lead (buffer-substring @@ -12887,16 +13378,43 @@ to be run from that hook to fucntion properly." (replace-match (or (eval (intern (concat "v-" (match-string 1)))) "") t t)) + + ;; %[] Insert contents of a file. + (goto-char (point-min)) + (while (re-search-forward "%\\[\\(.+\\)\\]" nil t) + (let ((start (match-beginning 0)) + (end (match-end 0)) + (filename (expand-file-name (match-string 1)))) + (goto-char start) + (delete-region start end) + (condition-case error + (insert-file-contents filename) + (error (insert (format "%%![Couldn't insert %s: %s]" + filename error)))))) + ;; %() embedded elisp + (goto-char (point-min)) + (while (re-search-forward "%\\((.+)\\)" nil t) + (goto-char (match-beginning 0)) + (let ((template-start (point))) + (forward-char 1) + (let ((result + (condition-case error + (eval (read (current-buffer))) + (error (format "%%![Error: %s]" error))))) + (delete-region template-start (point)) + (insert result)))) + ;; From the property list (when plist-p (goto-char (point-min)) (while (re-search-forward "%\\(:[-a-zA-Z]+\\)" nil t) - (and (setq x (plist-get org-store-link-plist - (intern (match-string 1)))) + (and (setq x (or (plist-get org-store-link-plist + (intern (match-string 1))) "")) (replace-match x t t)))) + ;; Turn on org-mode in the remember buffer, set local variables (org-mode) - (org-set-local 'org-finish-function 'remember-buffer) + (org-set-local 'org-finish-function 'remember-finalize) (if (and file (string-match "\\S-" file) (not (file-directory-p file))) (org-set-local 'org-default-notes-file file)) (if (and headline (stringp headline) (string-match "\\S-" headline)) @@ -12908,6 +13426,15 @@ to be run from that hook to fucntion properly." prompt (if (match-end 2) (match-string 2))) (goto-char (match-beginning 0)) (replace-match "") + (setq completions nil default nil) + (when prompt + (setq completions (org-split-string prompt "|") + prompt (pop completions) + default (car completions) + histvar (intern (concat + "org-remember-template-prompt-history::" + (or prompt ""))) + completions (mapcar 'list completions))) (cond ((member char '("G" "g")) (let* ((org-last-tags-completion-table @@ -12933,33 +13460,92 @@ to be run from that hook to fucntion properly." (member char '("u" "U")) nil nil (list org-end-time-was-given))) (t - (insert (read-string - (if prompt (concat prompt ": ") "Enter string")))))) + (insert (org-completing-read + (concat (if prompt prompt "Enter string") + (if default (concat " [" default "]")) + ": ") + completions nil nil nil histvar default))))) (goto-char (point-min)) (if (re-search-forward "%\\?" nil t) (replace-match "") (and (re-search-forward "^[^#\n]" nil t) (backward-char 1)))) (org-mode) - (org-set-local 'org-finish-function 'remember-buffer))) + (org-set-local 'org-finish-function 'remember-finalize)) + (when (save-excursion + (goto-char (point-min)) + (re-search-forward "%!" nil t)) + (replace-match "") + (add-hook 'post-command-hook 'org-remember-finish-immediately 'append))) + +(defun org-remember-finish-immediately () + "File remember note immediately. +This should be run in `post-command-hook' and will remove itself +from that hook." + (remove-hook 'post-command-hook 'org-remember-finish-immediately) + (when org-finish-function + (funcall org-finish-function))) + ;;;###autoload -(defun org-remember (&optional org-force-remember-template-char) +(defun org-remember (&optional goto org-force-remember-template-char) "Call `remember'. If this is already a remember buffer, re-apply template. If there is an active region, make sure remember uses it as initial content -of the remember buffer." +of the remember buffer. + +When called interactively with a `C-u' prefix argument GOTO, don't remember +anything, just go to the file/headline where the selected template usually +stores its notes. With a double prefix arg `C-u C-u', go to the last +note stored by remember. + +Lisp programs can set ORG-FORCE-REMEMBER-TEMPLATE-CHAR to a character +associated with a template in `org-remember-templates'." + (interactive "P") + (cond + ((equal goto '(4)) (org-go-to-remember-target)) + ((equal goto '(16)) (org-remember-goto-last-stored)) + (t + (if (memq org-finish-function '(remember-buffer remember-finalize)) + (progn + (when (< (length org-remember-templates) 2) + (error "No other template available")) + (erase-buffer) + (let ((annotation (plist-get org-store-link-plist :annotation)) + (initial (plist-get org-store-link-plist :initial))) + (org-remember-apply-template)) + (message "Press C-c C-c to remember data")) + (if (org-region-active-p) + (remember (buffer-substring (point) (mark))) + (call-interactively 'remember)))))) + +(defun org-remember-goto-last-stored () + "Go to the location where the last remember note was stored." (interactive) - (if (eq org-finish-function 'remember-buffer) - (progn - (when (< (length org-remember-templates) 2) - (error "No other template available")) - (erase-buffer) - (let ((annotation (plist-get org-store-link-plist :annotation)) - (initial (plist-get org-store-link-plist :initial))) - (org-remember-apply-template)) - (message "Press C-c C-c to remember data")) - (if (org-region-active-p) - (remember (buffer-substring (point) (mark))) - (call-interactively 'remember)))) + (bookmark-jump "org-remember-last-stored") + (message "This is the last note stored by remember")) + +(defun org-go-to-remember-target (&optional template-key) + "Go to the target location of a remember template. +The user is queried for the template." + (interactive) + (let* ((entry (org-select-remember-template template-key)) + (file (nth 1 entry)) + (heading (nth 2 entry)) + visiting) + (unless (and file (stringp file) (string-match "\\S-" file)) + (setq file org-default-notes-file)) + (unless (and heading (stringp heading) (string-match "\\S-" heading)) + (setq heading org-remember-default-headline)) + (setq visiting (org-find-base-buffer-visiting file)) + (if (not visiting) (find-file-noselect file)) + (switch-to-buffer (or visiting (get-file-buffer file))) + (widen) + (goto-char (point-min)) + (if (re-search-forward + (concat "^\\*+[ \t]+" (regexp-quote heading) + (org-re "\\([ \t]+:[[:alnum:]@_:]*\\)?[ \t]*$")) + nil t) + (goto-char (match-beginning 0)) + (error "Target headline not found: %s" heading)))) (defvar org-note-abort nil) ; dynamically scoped @@ -13003,23 +13589,34 @@ See also the variable `org-reverse-note-order'." (while (looking-at "^[ \t]*\n\\|^##.*\n") (replace-match "")) (goto-char (point-max)) - (unless (equal (char-before) ?\n) (insert "\n")) + (beginning-of-line 1) + (while (looking-at "[ \t]*$\\|##.*") + (delete-region (1- (point)) (point-max)) + (beginning-of-line 1)) (catch 'quit (if org-note-abort (throw 'quit nil)) (let* ((txt (buffer-substring (point-min) (point-max))) (fastp (org-xor (equal current-prefix-arg '(4)) org-remember-store-without-prompt)) - (file (if fastp org-default-notes-file (org-get-org-file))) + (file (cond + (fastp org-default-notes-file) + ((and org-remember-use-refile-when-interactive + org-refile-targets) + org-default-notes-file) + (t (org-get-org-file)))) (heading org-remember-default-headline) - (visiting (org-find-base-buffer-visiting file)) + (visiting (and file (org-find-base-buffer-visiting file))) (org-startup-folded nil) (org-startup-align-all-tables nil) (org-goto-start-pos 1) spos exitcmd level indent reversed) (if (and (equal current-prefix-arg '(16)) org-remember-previous-location) (setq file (car org-remember-previous-location) - heading (cdr org-remember-previous-location))) + heading (cdr org-remember-previous-location) + fastp t)) (setq current-prefix-arg nil) + (if (string-match "[ \t\n]+\\'" txt) + (setq txt (replace-match "" t t txt))) ;; Modify text so that it becomes a nice subtree which can be inserted ;; into an org tree. (let* ((lines (split-string txt "\n")) @@ -13034,9 +13631,25 @@ See also the variable `org-reverse-note-order'." " (" (remember-buffer-desc) ")") indent " ")) (if (and org-adapt-indentation indent) - (setq lines (mapcar (lambda (x) (concat indent x)) lines))) + (setq lines (mapcar + (lambda (x) + (if (string-match "\\S-" x) + (concat indent x) x)) + lines))) (setq txt (concat first "\n" (mapconcat 'identity lines "\n")))) + (if (string-match "\n[ \t]*\n[ \t\n]*\\'" txt) + (setq txt (replace-match "\n\n" t t txt)) + (if (string-match "[ \t\n]*\\'" txt) + (setq txt (replace-match "\n" t t txt)))) + ;; Put the modified text back into the remember buffer, for refile. + (erase-buffer) + (insert txt) + (goto-char (point-min)) + (when (and org-remember-use-refile-when-interactive + (not fastp)) + (org-refile nil (or visiting (find-file-noselect file))) + (throw 'quit t)) ;; Find the file (if (not visiting) (find-file-noselect file)) (with-current-buffer (or visiting (get-file-buffer file)) @@ -13085,19 +13698,22 @@ See also the variable `org-reverse-note-order'." (org-get-heading 'notags))) (if reversed (outline-next-heading) - (org-end-of-subtree) + (org-end-of-subtree t) (if (not (bolp)) (if (looking-at "[ \t]*\n") (beginning-of-line 2) (end-of-line 1) (insert "\n")))) + (bookmark-set "org-remember-last-stored") (org-paste-subtree (org-get-legal-level level 1) txt)) ((eq exitcmd 'left) ;; before current + (bookmark-set "org-remember-last-stored") (org-paste-subtree level txt)) ((eq exitcmd 'right) ;; after current (org-end-of-subtree t) + (bookmark-set "org-remember-last-stored") (org-paste-subtree level txt)) (t (error "This should not happen")))) @@ -13107,6 +13723,7 @@ See also the variable `org-reverse-note-order'." (widen) (goto-char (point-max)) (if (not (bolp)) (newline)) + (bookmark-set "org-remember-last-stored") (org-paste-subtree (org-get-legal-level 1 1) txt))) ((and (bobp) reversed) @@ -13116,16 +13733,19 @@ See also the variable `org-reverse-note-order'." (goto-char (point-min)) (re-search-forward "^\\*+ " nil t) (beginning-of-line 1) + (bookmark-set "org-remember-last-stored") (org-paste-subtree 1 txt))) (t ;; Put it right there, with automatic level determined by ;; org-paste-subtree or from prefix arg + (bookmark-set "org-remember-last-stored") (org-paste-subtree (if (numberp current-prefix-arg) current-prefix-arg) txt))) (when remember-save-after-remembering (save-buffer) (if (not visiting) (kill-buffer (current-buffer))))))))) + t) ;; return t to indicate that we took care of this note. (defun org-get-org-file () @@ -13149,6 +13769,160 @@ See also the variable `org-reverse-note-order'." (throw 'exit (cdr entry)))) nil))))) +;;; Refiling + +(defvar org-refile-target-table nil + "The list of refile targets, created by `org-refile'.") + +(defvar org-agenda-new-buffers nil + "Buffers created to visit agenda files.") + +(defun org-get-refile-targets (&optional default-buffer) + "Produce a table with refile targets." + (let ((entries (or org-refile-targets '((nil . (:level . 1))))) + org-agenda-new-buffers targets txt re files f desc descre) + (with-current-buffer (or default-buffer (current-buffer)) + (while (setq entry (pop entries)) + (setq files (car entry) desc (cdr entry)) + (cond + ((null files) (setq files (list (current-buffer)))) + ((eq files 'org-agenda-files) + (setq files (org-agenda-files 'unrestricted))) + ((and (symbolp files) (fboundp files)) + (setq files (funcall files))) + ((and (symbolp files) (boundp files)) + (setq files (symbol-value files)))) + (if (stringp files) (setq files (list files))) + (cond + ((eq (car desc) :tag) + (setq descre (concat "^\\*+[ \t]+.*?:" (regexp-quote (cdr desc)) ":"))) + ((eq (car desc) :todo) + (setq descre (concat "^\\*+[ \t]+" (regexp-quote (cdr desc)) "[ \t]"))) + ((eq (car desc) :regexp) + (setq descre (cdr desc))) + ((eq (car desc) :level) + (setq descre (concat "^\\*\\{" (number-to-string + (if org-odd-levels-only + (1- (* 2 (cdr desc))) + (cdr desc))) + "\\}[ \t]"))) + ((eq (car desc) :maxlevel) + (setq descre (concat "^\\*\\{1," (number-to-string + (if org-odd-levels-only + (1- (* 2 (cdr desc))) + (cdr desc))) + "\\}[ \t]"))) + (t (error "Bad refiling target description %s" desc))) + (while (setq f (pop files)) + (save-excursion + (set-buffer (if (bufferp f) f (org-get-agenda-file-buffer f))) + (if (bufferp f) (setq f (buffer-file-name (buffer-base-buffer f)))) + (save-excursion + (save-restriction + (widen) + (goto-char (point-min)) + (while (re-search-forward descre nil t) + (goto-char (point-at-bol)) + (when (looking-at org-complex-heading-regexp) + (setq txt (match-string 4) + re (concat "^" (regexp-quote + (buffer-substring (match-beginning 1) + (match-end 4))))) + (if (match-end 5) (setq re (concat re "[ \t]+" + (regexp-quote + (match-string 5))))) + (setq re (concat re "[ \t]*$")) + (when org-refile-use-outline-path + (setq txt (mapconcat 'identity + (append + (if (eq org-refile-use-outline-path 'file) + (list (file-name-nondirectory + (buffer-file-name (buffer-base-buffer)))) + (if (eq org-refile-use-outline-path 'full-file-path) + (list (buffer-file-name (buffer-base-buffer))))) + (org-get-outline-path) + (list txt)) + "/"))) + (push (list txt f re (point)) targets)) + (goto-char (point-at-eol)))))))) + (org-release-buffers org-agenda-new-buffers) + (nreverse targets)))) + +(defun org-get-outline-path () + (let (rtn) + (save-excursion + (while (org-up-heading-safe) + (when (looking-at org-complex-heading-regexp) + (push (org-match-string-no-properties 4) rtn))) + rtn))) + +(defvar org-refile-history nil + "History for refiling operations.") + +(defun org-refile (&optional reversed-or-update default-buffer) + "Move the entry at point to another heading. +The list of target headings is compiled using the information in +`org-refile-targets', which see. This list is created upon first use, and +you can update it by calling this command with a double prefix (`C-u C-u'). +FIXME: Can we find a better way of updating? + +At the target location, the entry is filed as a subitem of the target heading. +Depending on `org-reverse-note-order', the new subitem will either be the +first of the last subitem. A single C-u prefix will toggle the value of this +variable for the duration of the command." + (interactive "P") + (if (equal reversed-or-update '(16)) + (progn + (setq org-refile-target-table (org-get-refile-targets default-buffer)) + (message "Refile targets updated (%d targets)" + (length org-refile-target-table))) + (when (or (not org-refile-target-table) + (assq nil org-refile-targets)) + (setq org-refile-target-table (org-get-refile-targets default-buffer))) + (unless org-refile-target-table + (error "No refile targets")) + (let* ((cbuf (current-buffer)) + (filename (buffer-file-name (buffer-base-buffer cbuf))) + (fname (and filename (file-truename filename))) + (tbl (mapcar + (lambda (x) + (if (not (equal fname (file-truename (nth 1 x)))) + (cons (concat (car x) " (" (file-name-nondirectory + (nth 1 x)) ")") + (cdr x)) + x)) + org-refile-target-table)) + (completion-ignore-case t) + pos it nbuf file re level reversed) + (when (setq it (completing-read "Refile to: " tbl + nil t nil 'org-refile-history)) + (setq it (assoc it tbl) + file (nth 1 it) + re (nth 2 it)) + (org-copy-special) + (save-excursion + (set-buffer (setq nbuf (or (find-buffer-visiting file) + (find-file-noselect file)))) + (setq reversed (org-notes-order-reversed-p)) + (if (equal reversed-or-update '(16)) (setq reversed (not reversed))) + (save-excursion + (save-restriction + (widen) + (goto-char (point-min)) + (unless (re-search-forward re nil t) + (error "Cannot find target location - try again with `C-u' prefix.")) + (goto-char (match-beginning 0)) + (looking-at outline-regexp) + (setq level (org-get-legal-level (funcall outline-level) 1)) + (goto-char (or (save-excursion + (if reversed + (outline-next-heading) + (outline-get-next-sibling))) + (point-max))) + (org-paste-subtree level)))) + (org-cut-special) + (message "Entry refiled to \"%s\"" (car it)))))) + ;;;; Dynamic blocks (defun org-find-dblock (name) @@ -13267,7 +14041,8 @@ This function can be used in a hook." (defconst org-additional-option-like-keywords '("BEGIN_HTML" "BEGIN_LaTeX" "END_HTML" "END_LaTeX" - "ORGTBL" "HTML:" "LaTeX:" "BEGIN:" "END:" "DATE:")) + "ORGTBL" "HTML:" "LaTeX:" "BEGIN:" "END:" "DATE:" "TBLFM" + "BEGIN_EXAMPLE" "END_EXAMPLE")) (defun org-complete (&optional arg) "Perform completion on word at point. @@ -13388,13 +14163,14 @@ At all other locations, this simply calls the value of (interactive) (save-excursion (org-back-to-heading) - (if (looking-at (concat outline-regexp - "\\( *\\<" org-comment-string "\\>[ \t]*\\)")) - (replace-match "" t t nil 1) - (if (looking-at outline-regexp) - (progn - (goto-char (match-end 0)) - (insert org-comment-string " ")))))) + (let (case-fold-search) + (if (looking-at (concat outline-regexp + "\\( *\\<" org-comment-string "\\>[ \t]*\\)")) + (replace-match "" t t nil 1) + (if (looking-at outline-regexp) + (progn + (goto-char (match-end 0)) + (insert org-comment-string " "))))))) (defvar org-last-todo-state-is-todo nil "This is non-nil when the last TODO state change led to a TODO state. @@ -13494,7 +14270,7 @@ For calling through lisp, arg is also interpreted in the following way: (or (looking-at (concat " +" org-todo-regexp " *")) (looking-at " *")) (let* ((match-data (match-data)) - (startpos (line-beginning-position)) + (startpos (point-at-bol)) (logging (save-match-data (org-entry-get nil "LOGGING" t))) (org-log-done (org-parse-local-options logging 'org-log-done)) (org-log-repeat (org-parse-local-options logging 'org-log-repeat)) @@ -13669,8 +14445,6 @@ Returns the new TODO keyword, or nil if no state change should occur." (save-window-excursion (if expert (set-buffer (get-buffer-create " *Org todo*")) -; (delete-other-windows) -; (split-window-vertically) (org-switch-to-buffer-other-window (get-buffer-create " *Org todo*"))) (erase-buffer) (org-set-local 'org-done-keywords done-keywords) @@ -13971,7 +14745,7 @@ The auto-repeater uses this.") (end-of-line 1) (if (not (bolp)) (let ((inhibit-read-only t)) (insert "\n"))) (indent-relative nil) - (insert " - " (pop lines)) + (insert "- " (pop lines)) (org-indent-line-function) (beginning-of-line 1) (looking-at "[ \t]*") @@ -13997,12 +14771,17 @@ t Show entries with a specific TODO keyword. T Show entries selected by a tags match. p Enter a property name and its value (both with completion on existing names/values) and show entries with that property. -r Show entries matching a regular expression" +r Show entries matching a regular expression +d Show deadlines due within `org-deadline-warning-days'." (interactive "P") (let (ans kwd value) - (message "Sparse tree: [r]egexp [t]odo-kwd [T]ag [p]roperty") + (message "Sparse tree: [/]regexp [t]odo-kwd [T]ag [p]roperty [d]eadlines [b]efore-date") (setq ans (read-char-exclusive)) (cond + ((equal ans ?d) + (call-interactively 'org-check-deadlines)) + ((equal ans ?b) + (call-interactively 'org-check-before-date)) ((equal ans ?t) (org-show-todo-tree '(4))) ((equal ans ?T) @@ -14015,7 +14794,7 @@ r Show entries matching a regular expression" (unless (string-match "\\`{.*}\\'" value) (setq value (concat "\"" value "\""))) (org-tags-sparse-tree arg (concat kwd "=" value))) - ((member ans '(?r ?R)) + ((member ans '(?r ?R ?/)) (call-interactively 'org-occur)) (t (error "No such sparse tree command \"%c\"" ans))))) @@ -14066,12 +14845,13 @@ How much context is shown depends upon the variables (let ((heading-p (org-on-heading-p t)) (hierarchy-p (org-get-alist-option org-show-hierarchy-above key)) (following-p (org-get-alist-option org-show-following-heading key)) + (entry-p (org-get-alist-option org-show-entry-below key)) (siblings-p (org-get-alist-option org-show-siblings key))) (catch 'exit ;; Show heading or entry text - (if heading-p + (if (and heading-p (not entry-p)) (org-flag-heading nil) ; only show the heading - (and (or (org-invisible-p) (org-invisible-p2)) + (and (or entry-p (org-invisible-p) (org-invisible-p2)) (org-show-hidden-entry))) ; show entire entry (when following-p ;; Show next sibling, or heading below text @@ -14306,11 +15086,13 @@ MATCH can contain positive and negative selection of tags, like If optional argument TODO_ONLY is non-nil, only select lines that are also TODO lines." (interactive "P") + (org-prepare-agenda-buffers (list (current-buffer))) (org-scan-tags 'sparse-tree (cdr (org-make-tags-matcher match)) todo-only)) (defvar org-cached-props nil) (defun org-cached-entry-get (pom property) - (if org-use-property-inheritance + (if (or (eq t org-use-property-inheritance) + (member property org-use-property-inheritance)) ;; Caching is not possible, check it directly (org-entry-get pom property 'inherit) ;; Get all properties, so that we can do complicated checks easily @@ -14348,7 +15130,7 @@ also TODO lines." (re (org-re "^&?\\([-+:]\\)?\\({[^}]+}\\|LEVEL=\\([0-9]+\\)\\|\\([[:alnum:]_]+\\)=\\({[^}]+}\\|\"[^\"]+\"\\)\\|[[:alnum:]_@]+\\)")) minus tag mm tagsmatch todomatch tagsmatcher todomatcher kwd matcher - orterms term orlist re-p level-p prop-p pn pv) + orterms term orlist re-p level-p prop-p pn pv cat-p gv) (if (string-match "/+" match) ;; match contains also a todo-matching request (progn @@ -14382,11 +15164,15 @@ also TODO lines." (prop-p (setq pn (match-string 4 term) pv (match-string 5 term) + cat-p (equal pn "CATEGORY") re-p (equal (string-to-char pv) ?{) pv (substring pv 1 -1)) + (if (equal pn "CATEGORY") + (setq gv '(get-text-property (point) 'org-category)) + (setq gv `(org-cached-entry-get nil ,pn))) (if re-p - `(string-match ,pv (or (org-cached-entry-get nil ,pn) "")) - `(equal ,pv (org-cached-entry-get nil ,pn)))) + `(string-match ,pv (or ,gv "")) + `(equal ,pv ,gv))) (t `(member ,(downcase tag) tags-list))) mm (if minus (list 'not mm) mm) term (substring term (match-end 0))) @@ -14842,7 +15628,8 @@ Returns the new tags string, or nil to not change the current settings." ;;; Setting and retrieving properties (defconst org-special-properties - '("TODO" "TAGS" "ALLTAGS" "DEADLINE" "SCHEDULED" "CLOCK" "PRIORITY") + '("TODO" "TAGS" "ALLTAGS" "DEADLINE" "SCHEDULED" "CLOCK" "PRIORITY" + "TIMESTAMP" "TIMESTAMP_IA") "The special properties valid in Org-mode. These are properties that are not defined in the property drawer, @@ -14938,11 +15725,12 @@ If WHICH is nil or `all', get all properties. If WHICH is (org-with-point-at pom (let ((clockstr (substring org-clock-string 0 -1)) (excluded '("TODO" "TAGS" "ALLTAGS" "PRIORITY")) - beg end range props sum-props key value) + beg end range props sum-props key value string) (save-excursion (when (condition-case nil (org-back-to-heading t) (error nil)) (setq beg (point)) (setq sum-props (get-text-property (point) 'org-summaries)) + (setq clocksum (get-text-property (point) :org-clock-minutes)) (outline-next-heading) (setq end (point)) (when (memq which '(all special)) @@ -14958,17 +15746,23 @@ If WHICH is nil or `all', get all properties. If WHICH is (when (setq value (org-get-tags-at)) (push (cons "ALLTAGS" (concat ":" (mapconcat 'identity value ":") ":")) props)) - (while (re-search-forward org-keyword-time-regexp end t) - (setq key (substring (org-match-string-no-properties 1) 0 -1)) - (unless (member key excluded) (push key excluded)) - (push (cons key - (if (equal key clockstr) - (org-no-properties - (org-trim - (buffer-substring - (match-beginning 2) (point-at-eol)))) - (org-match-string-no-properties 2))) - props))) + (while (re-search-forward org-maybe-keyword-time-regexp end t) + (setq key (if (match-end 1) (substring (org-match-string-no-properties 1) 0 -1)) + string (if (equal key clockstr) + (org-no-properties + (org-trim + (buffer-substring + (match-beginning 3) (goto-char (point-at-eol))))) + (substring (org-match-string-no-properties 3) 1 -1))) + (unless key + (if (= (char-after (match-beginning 3)) ?\[) + (setq key "TIMESTAMP_IA") + (setq key "TIMESTAMP"))) + (when (or (equal key clockstr) (not (assoc key props))) + (push (cons key string) props))) + + ) + (when (memq which '(all standard)) ;; Get the standard properties, like :PORP: ... (setq range (org-get-property-block beg end)) @@ -14981,6 +15775,11 @@ If WHICH is nil or `all', get all properties. If WHICH is value (org-trim (or (org-match-string-no-properties 2) ""))) (unless (member key excluded) (push (cons key (or value "")) props))))) + (if clocksum + (push (cons "CLOCKSUM" + (org-column-number-to-string (/ (float clocksum) 60.) + 'add_times)) + props)) (append sum-props (nreverse props))))))) (defun org-entry-get (pom property &optional inherit) @@ -15178,6 +15977,7 @@ internally: ARCHIVE, CATEGORY, SUMMARY, DESCRIPTION, LOCATION, and LOGGING." (and (equal (char-after) ?\n) (forward-char 1)) (org-skip-over-state-notes) (skip-chars-backward " \t\n\r") + (if (eq (char-before) ?*) (forward-char 1)) (let ((inhibit-read-only t)) (insert "\n:PROPERTIES:\n:END:")) (beginning-of-line 0) (indent-to-column indent) @@ -15613,6 +16413,8 @@ Where possible, use the standard interface for changing this line." org-columns-overlays))) nval eval allowed) (cond + ((equal key "CLOCKSUM") + (error "This special column cannot be edited")) ((equal key "ITEM") (setq eval '(org-with-point-at pom (org-edit-headline)))) @@ -15683,7 +16485,7 @@ Where possible, use the standard interface for changing this line." (key1 (concat key "_ALL")) (allowed (org-entry-get (point) key1 t)) nval) - ;; FIXME: Cover editing TODO, TAGS etc inbiffer settings.???? + ;; FIXME: Cover editing TODO, TAGS etc in-buffer settings.???? (setq nval (read-string "Allowed: " allowed)) (org-entry-put (cond ((marker-position org-entry-property-inherited-from) @@ -15700,7 +16502,7 @@ Where possible, use the standard interface for changing this line." (save-excursion (beginning-of-line 1) ;; `next-line' is needed here, because it skips invisible line. - (condition-case nil (org-no-warnings (next-line 1)) (error nil)) + (condition-case nil (org-no-warnings (next-line 1)) (error nil)) (setq hidep (org-on-heading-p 1))) (eval form) (and hidep (hide-entry)))) @@ -15800,7 +16602,7 @@ Where possible, use the standard interface for changing this line." (org-verify-version 'columns) (org-columns-remove-overlays) (move-marker org-columns-begin-marker (point)) - (let (beg end fmt cache maxwidths) + (let (beg end fmt cache maxwidths clocksump) (setq fmt (org-columns-get-format-and-top-level)) (save-excursion (goto-char org-columns-top-level-marker) @@ -15809,8 +16611,14 @@ Where possible, use the standard interface for changing this line." (org-columns-compute-all)) (setq end (or (condition-case nil (org-end-of-subtree t t) (error nil)) (point-max))) - (goto-char beg) ;; Get and cache the properties + (goto-char beg) + (when (assoc "CLOCKSUM" org-columns-current-fmt-compiled) + (setq clocksump t) + (save-excursion + (save-restriction + (narrow-to-region beg end) + (org-clock-sum)))) (while (re-search-forward (concat "^" outline-regexp) end t) (push (cons (org-current-line) (org-entry-properties)) cache)) (when cache @@ -15822,7 +16630,7 @@ Where possible, use the standard interface for changing this line." (org-columns-display-here (cdr x))) cache))))) -(defun org-columns-new (&optional prop title width op fmt) +(defun org-columns-new (&optional prop title width op fmt &rest rest) "Insert a new column, to the leeft o the current column." (interactive) (let ((editp (and prop (assoc prop org-columns-current-fmt-compiled))) @@ -15836,7 +16644,7 @@ Where possible, use the standard interface for changing this line." (setq width (string-to-number width)) (setq width nil)) (setq fmt (completing-read "Summary [none]: " - '(("none") ("add_numbers") ("add_times") ("checkbox")) + '(("none") ("add_numbers") ("currency") ("add_times") ("checkbox")) nil t)) (if (string-match "\\S-" fmt) (setq fmt (intern fmt)) @@ -16039,6 +16847,7 @@ display, or in the #+COLUMNS line of the current buffer." (level 0) (ass (assoc property org-columns-current-fmt-compiled)) (format (nth 4 ass)) + (printf (nth 5 ass)) (beg org-columns-top-level-marker) last-level val valflag flag end sumpos sum-alist sum str str1 useval) (save-excursion @@ -16058,7 +16867,7 @@ display, or in the #+COLUMNS line of the current buffer." ;; put the sum of lower levels here as a property (setq sum (aref lsum last-level) ; current sum flag (aref lflag last-level) ; any valid entries from children? - str (org-column-number-to-string sum format) + str (org-column-number-to-string sum format printf) str1 (org-add-props (copy-sequence str) nil 'org-computed t 'face 'bold) useval (if flag str1 (if valflag val "")) sum-alist (get-text-property sumpos 'org-summaries)) @@ -16072,7 +16881,6 @@ display, or in the #+COLUMNS line of the current buffer." (org-entry-put nil property (if flag str val))) ;; add current to current level accumulator (when (or flag valflag) - ;; FIXME: is this ok????????? (aset lsum level (+ (aref lsum level) (if flag sum (org-column-string-to-number (if flag str val) format)))) @@ -16115,7 +16923,7 @@ display, or in the #+COLUMNS line of the current buffer." (setq sum (+ (string-to-number (pop l)) (/ sum 60)))) sum))) -(defun org-column-number-to-string (n fmt) +(defun org-column-number-to-string (n fmt &optional printf) "Convert a computed column number to a string value, according to FMT." (cond ((eq fmt 'add_times) @@ -16125,6 +16933,9 @@ display, or in the #+COLUMNS line of the current buffer." (cond ((= n (floor n)) "[X]") ((> n 1.) "[-]") (t "[ ]"))) + (printf (format printf n)) + ((eq fmt 'currency) + (format "%.2f" n)) (t (number-to-string n)))) (defun org-column-string-to-number (s fmt) @@ -16141,17 +16952,20 @@ display, or in the #+COLUMNS line of the current buffer." (defun org-columns-uncompile-format (cfmt) "Turn the compiled columns format back into a string representation." - (let ((rtn "") e s prop title op width fmt) + (let ((rtn "") e s prop title op width fmt printf) (while (setq e (pop cfmt)) (setq prop (car e) title (nth 1 e) width (nth 2 e) op (nth 3 e) - fmt (nth 4 e)) + fmt (nth 4 e) + printf (nth 5 e)) (cond ((eq fmt 'add_times) (setq op ":")) ((eq fmt 'checkbox) (setq op "X")) - ((eq fmt 'add_numbers) (setq op "+"))) + ((eq fmt 'add_numbers) (setq op "+")) + ((eq fmt 'currency) (setq op "$"))) + (if (and op printf) (setq op (concat op ";" printf))) (if (equal title prop) (setq title nil)) (setq s (concat "%" (if width (number-to-string width)) prop @@ -16168,8 +16982,9 @@ property the property title the title field for the columns width the column width in characters, can be nil for automatic operator the operator if any -format the output format for computed results, derived from operator" - (let ((start 0) width prop title op f) +format the output format for computed results, derived from operator +printf a printf format for computed values" + (let ((start 0) width prop title op f printf) (setq org-columns-current-fmt-compiled nil) (while (string-match (org-re "%\\([0-9]+\\)?\\([[:alnum:]_-]+\\)\\(?:(\\([^)]+\\))\\)?\\(?:{\\([^}]+\\)}\\)?\\s-*") @@ -16179,13 +16994,18 @@ format the output format for computed results, derived from operator" prop (match-string 2 fmt) title (or (match-string 3 fmt) prop) op (match-string 4 fmt) - f nil) + f nil + printf nil) (if width (setq width (string-to-number width))) + (when (and op (string-match ";" op)) + (setq printf (substring op (match-end 0)) + op (substring op 0 (match-beginning 0)))) (cond ((equal op "+") (setq f 'add_numbers)) + ((equal op "$") (setq f 'currency)) ((equal op ":") (setq f 'add_times)) ((equal op "X") (setq f 'checkbox))) - (push (list prop title width op f) org-columns-current-fmt-compiled)) + (push (list prop title width op f printf) org-columns-current-fmt-compiled)) (setq org-columns-current-fmt-compiled (nreverse org-columns-current-fmt-compiled)))) @@ -16314,28 +17134,30 @@ So if you press just return without typing anything, the time stamp will represent the current date/time. If there is already a timestamp at the cursor, it will be modified." (interactive "P") - (let ((default-time - ;; Default time is either today, or, when entering a range, - ;; the range start. - (if (or (org-at-timestamp-p t) - (save-excursion - (re-search-backward - (concat org-ts-regexp "--?-?\\=") ; 1-3 minuses - (- (point) 20) t))) - (apply 'encode-time (org-parse-time-string (match-string 1))) - (current-time))) - org-time-was-given org-end-time-was-given time) + (let* ((ts nil) + (default-time + ;; Default time is either today, or, when entering a range, + ;; the range start. + (if (or (and (org-at-timestamp-p t) (setq ts (match-string 0))) + (save-excursion + (re-search-backward + (concat org-ts-regexp "--?-?\\=") ; 1-3 minuses + (- (point) 20) t))) + (apply 'encode-time (org-parse-time-string (match-string 1))) + (current-time))) + (default-input (and ts (org-get-compact-tod ts))) + org-time-was-given org-end-time-was-given time) (cond ((and (org-at-timestamp-p) (eq last-command 'org-time-stamp) (eq this-command 'org-time-stamp)) (insert "--") (setq time (let ((this-command this-command)) - (org-read-date arg 'totime nil nil default-time))) + (org-read-date arg 'totime nil nil default-time default-input))) (org-insert-time-stamp time (or org-time-was-given arg))) ((org-at-timestamp-p) (setq time (let ((this-command this-command)) - (org-read-date arg 'totime nil nil default-time))) + (org-read-date arg 'totime nil nil default-time default-input))) (when (org-at-timestamp-p) ; just to get the match data (replace-match "") (setq org-last-changed-timestamp @@ -16345,10 +17167,28 @@ at the cursor, it will be modified." (message "Timestamp updated")) (t (setq time (let ((this-command this-command)) - (org-read-date arg 'totime nil nil default-time))) + (org-read-date arg 'totime nil nil default-time default-input))) (org-insert-time-stamp time (or org-time-was-given arg) nil nil nil (list org-end-time-was-given)))))) +;; FIXME: can we use this for something else???? +;; like computing time differences????? +(defun org-get-compact-tod (s) + (when (string-match "\\(\\([012]?[0-9]\\):\\([0-5][0-9]\\)\\)\\(-\\(\\([012]?[0-9]\\):\\([0-5][0-9]\\)\\)\\)?" s) + (let* ((t1 (match-string 1 s)) + (h1 (string-to-number (match-string 2 s))) + (m1 (string-to-number (match-string 3 s))) + (t2 (and (match-end 4) (match-string 5 s))) + (h2 (and t2 (string-to-number (match-string 6 s)))) + (m2 (and t2 (string-to-number (match-string 7 s)))) + dh dm) + (if (not t2) + t1 + (setq dh (- h2 h1) dm (- m2 m1)) + (if (< dm 0) (setq dm (+ dm 60) dh (1- dh))) + (concat t1 "+" (number-to-string dh) + (if (/= 0 dm) (concat ":" (number-to-string dm)))))))) + (defun org-time-stamp-inactive (&optional arg) "Insert an inactive time stamp. An inactive time stamp is enclosed in square brackets instead of angle @@ -16369,9 +17209,13 @@ So these are more for recording a certain time/date." (defvar org-ans2) ; dynamically scoped parameter (defvar org-plain-time-of-day-regexp) ; defined below + +(defvar org-read-date-overlay nil) +(defvar org-dcst nil) ; dynamically scoped + (defun org-read-date (&optional with-time to-time from-string prompt - default-time) - "Read a date and make things smooth for the user. + default-time default-input) + "Read a date, possibly a time, and make things smooth for the user. The prompt will suggest to enter an ISO date, but you can also enter anything which will at least partially be understood by `parse-time-string'. Unrecognized parts of the date will default to the current day, month, year, @@ -16405,7 +17249,7 @@ While prompting, a calendar is popped up - you can also select the date with the mouse (button 1). The calendar shows a period of three months. To scroll it to other months, use the keys `>' and `<'. If you don't like the calendar, turn it off with - \(setq org-popup-calendar-for-date-prompt nil) + \(setq org-read-date-popup-calendar nil) With optional argument TO-TIME, the date will immediately be converted to an internal time. @@ -16414,29 +17258,35 @@ insert a time. Note that when WITH-TIME is not set, you can still enter a time, and this function will inform the calling routine about this change. The calling routine may then choose to change the format used to insert the time stamp into the buffer to include the time. -With optional argument FROM-STRING, read fomr this string instead from +With optional argument FROM-STRING, read from this string instead from the user. PROMPT can overwrite the default prompt. DEFAULT-TIME is the time/date that is used for everything that is not specified by the user." (require 'parse-time) (let* ((org-time-stamp-rounding-minutes (if (equal with-time '(16)) 0 org-time-stamp-rounding-minutes)) + (org-dcst org-display-custom-times) (ct (org-current-time)) (def (or default-time ct)) - ; (defdecode (decode-time def)) + (defdecode (decode-time def)) + (dummy (progn + (when (< (nth 2 defdecode) org-extend-today-until) + (setcar (nthcdr 2 defdecode) -1) + (setcar (nthcdr 1 defdecode) 59) + (setq def (apply 'encode-time defdecode) + defdecode (decode-time def))))) (calendar-move-hook nil) (view-diary-entries-initially nil) (view-calendar-holidays-initially nil) (timestr (format-time-string (if with-time "%Y-%m-%d %H:%M" "%Y-%m-%d") def)) (prompt (concat (if prompt (concat prompt " ") "") - (format "Date and/or time (default [%s]): " timestr))) - ans (org-ans0 "") org-ans1 org-ans2 delta deltan deltaw deltadef - second minute hour day month year tl wday wday1 pm h2 m2) + (format "Date+time [%s]: " timestr))) + ans (org-ans0 "") org-ans1 org-ans2 final) (cond (from-string (setq ans from-string)) - (org-popup-calendar-for-date-prompt + (org-read-date-popup-calendar (save-excursion (save-window-excursion (calendar) @@ -16458,6 +17308,12 @@ user." (org-defkey minibuffer-local-map [(meta shift right)] (lambda () (interactive) (org-eval-in-calendar '(calendar-forward-month 1)))) + (org-defkey minibuffer-local-map [(meta shift up)] + (lambda () (interactive) + (org-eval-in-calendar '(calendar-backward-year 1)))) + (org-defkey minibuffer-local-map [(meta shift down)] + (lambda () (interactive) + (org-eval-in-calendar '(calendar-forward-year 1)))) (org-defkey minibuffer-local-map [(shift up)] (lambda () (interactive) (org-eval-in-calendar '(calendar-backward-week 1)))) @@ -16479,15 +17335,75 @@ user." (unwind-protect (progn (use-local-map map) - (setq org-ans0 (read-string prompt "" nil nil)) + (add-hook 'post-command-hook 'org-read-date-display) + (setq org-ans0 (read-string prompt default-input nil nil)) ;; org-ans0: from prompt ;; org-ans1: from mouse click ;; org-ans2: from calendar motion (setq ans (concat org-ans0 " " (or org-ans1 org-ans2)))) - (use-local-map old-map)))))) + (remove-hook 'post-command-hook 'org-read-date-display) + (use-local-map old-map) + (when org-read-date-overlay + (org-delete-overlay org-read-date-overlay) + (setq org-read-date-overlay nil))))))) + (t ; Naked prompt only - (setq ans (read-string prompt "" nil timestr)))) - (org-detach-overlay org-date-ovl) + (unwind-protect + (setq ans (read-string prompt default-input nil timestr)) + (when org-read-date-overlay + (org-delete-overlay org-read-date-overlay) + (setq org-read-date-overlay nil))))) + + (setq final (org-read-date-analyze ans def defdecode)) + + (if to-time + (apply 'encode-time final) + (if (and (boundp 'org-time-was-given) org-time-was-given) + (format "%04d-%02d-%02d %02d:%02d" + (nth 5 final) (nth 4 final) (nth 3 final) + (nth 2 final) (nth 1 final)) + (format "%04d-%02d-%02d" (nth 5 final) (nth 4 final) (nth 3 final)))))) +(defvar def) +(defvar defdecode) +(defvar with-time) +(defun org-read-date-display () + "Display the currrent date prompt interpretation in the minibuffer." + (when org-read-date-display-live + (when org-read-date-overlay + (org-delete-overlay org-read-date-overlay)) + (let ((p (point))) + (end-of-line 1) + (while (not (equal (buffer-substring + (max (point-min) (- (point) 4)) (point)) + " ")) + (insert " ")) + (goto-char p)) + (let* ((ans (concat (buffer-substring (point-at-bol) (point-max)) + " " (or org-ans1 org-ans2))) + (org-end-time-was-given nil) + (f (org-read-date-analyze ans def defdecode)) + (fmts (if org-dcst + org-time-stamp-custom-formats + org-time-stamp-formats)) + (fmt (if (or with-time + (and (boundp 'org-time-was-given) org-time-was-given)) + (cdr fmts) + (car fmts))) + (txt (concat "=> " (format-time-string fmt (apply 'encode-time f))))) + (when (and org-end-time-was-given + (string-match org-plain-time-of-day-regexp txt)) + (setq txt (concat (substring txt 0 (match-end 0)) "-" + org-end-time-was-given + (substring txt (match-end 0))))) + (setq org-read-date-overlay + (make-overlay (1- (point-at-eol)) (point-at-eol))) + (org-overlay-display org-read-date-overlay txt 'secondary-selection)))) + +(defun org-read-date-analyze (ans def defdecode) + "Analyze the combined answer of the date prompt." + ;; FIXME: cleanup and comment + (let (delta deltan deltaw deltadef year month day + hour minute second wday pm h2 m2 tl wday1) (when (setq delta (org-read-date-get-relative ans (current-time) def)) (setq ans (replace-match "" t t ans) @@ -16530,22 +17446,32 @@ user." h2 (+ hour (string-to-number (match-string 3 ans))) minute (string-to-number (match-string 2 ans)) m2 (+ minute (if (match-end 5) (string-to-number (match-string 5 ans))0))) + (if (>= m2 60) (setq h2 (1+ h2) m2 (- m2 60))) (setq ans (replace-match (format "%02d:%02d-%02d:%02d" hour minute h2 m2) t t ans))) ;; Check if there is a time range - (when (and (boundp 'org-end-time-was-given) - (string-match org-plain-time-of-day-regexp ans) - (match-end 8)) - (setq org-end-time-was-given (match-string 8 ans)) - (setq ans (concat (substring ans 0 (match-beginning 7)) - (substring ans (match-end 7))))) + (when (boundp 'org-end-time-was-given) + (setq org-time-was-given nil) + (when (and (string-match org-plain-time-of-day-regexp ans) + (match-end 8)) + (setq org-end-time-was-given (match-string 8 ans)) + (setq ans (concat (substring ans 0 (match-beginning 7)) + (substring ans (match-end 7)))))) (setq tl (parse-time-string ans) - day (or (nth 3 tl) (string-to-number (format-time-string "%d" def))) - month (or (nth 4 tl) (string-to-number (format-time-string "%m" def))) - year (or (nth 5 tl) (string-to-number (format-time-string "%Y" def))) - hour (or (nth 2 tl) (string-to-number (format-time-string "%H" def))) - minute (or (nth 1 tl) (string-to-number (format-time-string "%M" def))) + day (or (nth 3 tl) (nth 3 defdecode)) + month (or (nth 4 tl) + (if (and org-read-date-prefer-future + (nth 3 tl) (< (nth 3 tl) (nth 3 defdecode))) + (1+ (nth 4 defdecode)) + (nth 4 defdecode))) + year (or (nth 5 tl) + (if (and org-read-date-prefer-future + (nth 4 tl) (< (nth 4 tl) (nth 4 defdecode))) + (1+ (nth 5 defdecode)) + (nth 5 defdecode))) + hour (or (nth 2 tl) (nth 2 defdecode)) + minute (or (nth 1 tl) (nth 1 defdecode)) second (or (nth 0 tl) 0) wday (nth 6 tl)) (when deltan @@ -16566,25 +17492,8 @@ user." (nth 2 tl)) (setq org-time-was-given t)) (if (< year 100) (setq year (+ 2000 year))) - (if to-time - (encode-time second minute hour day month year) - (if (or (nth 1 tl) (nth 2 tl)) - (format "%04d-%02d-%02d %02d:%02d" year month day hour minute) - (format "%04d-%02d-%02d" year month day))))) - -;(defun org-parse-for-shift (n1 n2 given-dec default-dec) -; (cond -; ((not (nth n1 given-dec)) -; (nth n1 default-dec)) -; ((or (> (nth n1 given-dec) (nth n1 (default-dec))) -; (not org-read-date-prefer-future)) -; (nth n1 given-dec)) -; (t (1+ -; (if (nth 3 given-dec) -; (nth 3 given-dec) -; (if (> (nth -; (setq given -; (if (and + (if (< year 1970) (setq year (nth 5 defdecode))) ; not representable + (list second minute hour day month year))) (defvar parse-time-weekdays) @@ -16631,17 +17540,18 @@ Also, store the cursor date in variable org-ans2." (time (encode-time 0 0 0 (nth 1 date) (nth 0 date) (nth 2 date)))) (setq org-ans2 (format-time-string "%Y-%m-%d" time)))) (org-move-overlay org-date-ovl (1- (point)) (1+ (point)) (current-buffer)) - (select-window sw) - ;; Update the prompt to show new default date - (save-excursion - (goto-char (point-min)) - (when (and org-ans2 - (re-search-forward "\\[[-0-9]+\\]" nil t) - (get-text-property (match-end 0) 'field)) - (let ((inhibit-read-only t)) - (replace-match (concat "[" org-ans2 "]") t t) - (add-text-properties (point-min) (1+ (match-end 0)) - (text-properties-at (1+ (point-min))))))))) + (select-window sw))) + +; ;; Update the prompt to show new default date +; (save-excursion +; (goto-char (point-min)) +; (when (and org-ans2 +; (re-search-forward "\\[[-0-9]+\\]" nil t) +; (get-text-property (match-end 0) 'field)) +; (let ((inhibit-read-only t)) +; (replace-match (concat "[" org-ans2 "]") t t) +; (add-text-properties (point-min) (1+ (match-end 0)) +; (text-properties-at (1+ (point-min))))))))) (defun org-calendar-select () "Return to `org-read-date' with the date currently selected. @@ -16820,6 +17730,20 @@ days. If the prefix is a raw \\[universal-argument] prefix, all deadlines are s (org-occur regexp nil callback) org-warn-days))) +(defun org-check-before-date (date) + "Check if there are deadlines or scheduled entries before DATE." + (interactive (list (org-read-date))) + (let ((case-fold-search nil) + (regexp (concat "\\<\\(" org-deadline-string + "\\|" org-scheduled-string + "\\) *<\\([^>]+\\)>")) + (callback + (lambda () (time-less-p + (org-time-string-to-time (match-string 2)) + (org-time-string-to-time date))))) + (message "%d entries before %s" + (org-occur regexp nil callback) date))) + (defun org-evaluate-time-range (&optional to-buffer) "Evaluate a time range by computing the difference between start and end. Normally the result is just printed in the echo area, but with prefix arg @@ -16868,10 +17792,12 @@ days in order to avoid rounding problems." h 0 m 0)) (if (not to-buffer) (message "%s" (org-make-tdiff-string y d h m)) - (when (org-at-table-p) - (goto-char match-end) - (setq align t) - (and (looking-at " *|") (goto-char (match-end 0)))) + (if (org-at-table-p) + (progn + (goto-char match-end) + (setq align t) + (and (looking-at " *|") (goto-char (match-end 0)))) + (goto-char match-end)) (if (looking-at "\\( *-? *[0-9]+y\\)?\\( *[0-9]+d\\)? *[0-9][0-9]:[0-9][0-9]") (replace-match "")) @@ -16920,7 +17846,10 @@ D may be an absolute day number, or a calendar-type list (month day year)." (defun org-calendar-holiday () "List of holidays, for Diary display in Org-mode." - (let ((hl (calendar-check-holidays date))) + (require 'holidays) + (let ((hl (funcall + (if (fboundp 'calendar-check-holidays) + 'calendar-check-holidays 'check-calendar-holidays) date))) (if hl (mapconcat 'identity hl "; ")))) (defun org-diary-sexp-entry (sexp entry date) @@ -16944,7 +17873,7 @@ D may be an absolute day number, or a calendar-type list (month day year)." (t nil)))) (defun org-diary-to-ical-string (frombuf) - "Get iCalendar entreis from diary entries in buffer FROMBUF. + "Get iCalendar entries from diary entries in buffer FROMBUF. This uses the icalendar.el library." (let* ((tmpdir (if (featurep 'xemacs) (temp-directory) @@ -17295,6 +18224,7 @@ belonging to the category \"Work\"." (if (equal filter '(4)) (setq filter (read-from-minibuffer "Regexp filter: "))) (let* ((cnt 0) ; count added events + (org-agenda-new-buffers nil) (today (org-date-to-gregorian (time-to-days (current-time)))) (files (org-agenda-files)) entries file) @@ -17319,7 +18249,7 @@ belonging to the category \"Work\"." (cadr (assoc 'category filter)) cat) (string-match (cadr (assoc 'headline filter)) evt)))))) - ;; FIXME Shall we remove text-properties for the appt text? + ;; FIXME: Shall we remove text-properties for the appt text? ;; (setq evt (set-text-properties 0 (length evt) nil evt)) (when (and ok tod) (setq tod (number-to-string tod) @@ -17329,6 +18259,7 @@ belonging to the category \"Work\"." (match-string 2 tod)))) (appt-add tod evt) (setq cnt (1+ cnt))))) entries) + (org-release-buffers org-agenda-new-buffers) (message "Added %d event%s for today" cnt (if (> cnt 1) "s" "")))) ;;; The clock for measuring work time. @@ -17363,9 +18294,17 @@ If necessary, clock-out of the currently active clock." (let (ts) (save-excursion (org-back-to-heading t) - (if (looking-at org-todo-line-regexp) - (setq org-clock-heading (match-string 3)) - (setq org-clock-heading "???")) + (when (and org-clock-in-switch-to-state + (not (looking-at (concat outline-regexp "[ \t]*" + org-clock-in-switch-to-state + "\\>")))) + (org-todo org-clock-in-switch-to-state)) + (if (and org-clock-heading-function + (functionp org-clock-heading-function)) + (setq org-clock-heading (funcall org-clock-heading-function)) + (if (looking-at org-complex-heading-regexp) + (setq org-clock-heading (match-string 4)) + (setq org-clock-heading "???"))) (setq org-clock-heading (propertize org-clock-heading 'face nil)) (org-clock-find-position) @@ -17483,6 +18422,9 @@ If there is no running clock, throw an error, unless FAIL-QUIETLY is set." (set-buffer (marker-buffer org-clock-marker)) (goto-char org-clock-marker) (delete-region (1- (point-at-bol)) (point-at-eol))) + (setq global-mode-string + (delq 'org-mode-line-string global-mode-string)) + (force-mode-line-update) (message "Clock canceled")) (defun org-clock-goto (&optional delete-windows) @@ -18019,8 +18961,10 @@ The following commands are available: (org-defkey org-agenda-mode-map "f" 'org-agenda-follow-mode) (org-defkey org-agenda-mode-map "l" 'org-agenda-log-mode) (org-defkey org-agenda-mode-map "D" 'org-agenda-toggle-diary) -(org-defkey org-agenda-mode-map "g" 'org-agenda-toggle-time-grid) +(org-defkey org-agenda-mode-map "G" 'org-agenda-toggle-time-grid) (org-defkey org-agenda-mode-map "r" 'org-agenda-redo) +(org-defkey org-agenda-mode-map "g" 'org-agenda-redo) +(org-defkey org-agenda-mode-map "e" 'org-agenda-execute) (org-defkey org-agenda-mode-map "q" 'org-agenda-quit) (org-defkey org-agenda-mode-map "x" 'org-agenda-exit) (org-defkey org-agenda-mode-map "\C-x\C-w" 'org-write-agenda) @@ -18237,6 +19181,7 @@ that have been changed along." (defvar org-agenda-restrict-begin (make-marker)) (defvar org-agenda-restrict-end (make-marker)) (defvar org-agenda-last-dispatch-buffer nil) +(defvar org-agenda-overriding-restriction nil) ;;;###autoload (defun org-agenda (arg &optional keys restriction) @@ -18266,6 +19211,7 @@ Pressing `<' twice means to restrict to the current subtree or region (interactive "P") (catch 'exit (let* ((prefix-descriptions nil) + (org-agenda-custom-commands-orig org-agenda-custom-commands) (org-agenda-custom-commands ;; normalize different versions (delq nil @@ -18281,11 +19227,12 @@ Pressing `<' twice means to restrict to the current subtree or region (buf (current-buffer)) (bfn (buffer-file-name (buffer-base-buffer))) entry key type match lprops ans) - ;; Turn off restriction - (put 'org-agenda-files 'org-restrict nil) - (setq org-agenda-restrict nil) - (move-marker org-agenda-restrict-begin nil) - (move-marker org-agenda-restrict-end nil) + ;; Turn off restriction unless there is an overriding one + (unless org-agenda-overriding-restriction + (put 'org-agenda-files 'org-restrict nil) + (setq org-agenda-restrict nil) + (move-marker org-agenda-restrict-begin nil) + (move-marker org-agenda-restrict-end nil)) ;; Delete old local properties (put 'org-agenda-redo-command 'org-lprops nil) ;; Remember where this call originated @@ -18295,7 +19242,7 @@ Pressing `<' twice means to restrict to the current subtree or region keys (car ans) restriction (cdr ans))) ;; Estabish the restriction, if any - (when restriction + (when (and (not org-agenda-overriding-restriction) restriction) (put 'org-agenda-files 'org-restrict (list bfn)) (cond ((eq restriction 'region) @@ -18349,7 +19296,9 @@ Pressing `<' twice means to restrict to the current subtree or region (org-let lprops '(funcall type match))) (t (error "Invalid custom agenda command type %s" type)))) (org-run-agenda-series (nth 1 entry) (cddr entry)))) - ((equal keys "C") (customize-variable 'org-agenda-custom-commands)) + ((equal keys "C") + (setq org-agenda-custom-commands org-agenda-custom-commands-orig) + (customize-variable 'org-agenda-custom-commands)) ((equal keys "a") (call-interactively 'org-agenda-list)) ((equal keys "t") (call-interactively 'org-todo-list)) ((equal keys "T") (org-call-with-arg 'org-todo-list (or arg '(4)))) @@ -18367,6 +19316,16 @@ Pressing `<' twice means to restrict to the current subtree or region ((equal keys "!") (customize-variable 'org-stuck-projects)) (t (error "Invalid agenda key")))))) +(defun org-agenda-normalize-custom-commands (cmds) + (delq nil + (mapcar + (lambda (x) + (cond ((stringp (cdr x)) nil) + ((stringp (nth 1 x)) x) + ((not (nth 1 x)) (cons (car x) (cons "" (cddr x)))) + (t (cons (car x) (cons "" (cdr x)))))) + cmds))) + (defun org-agenda-get-restriction-and-command (prefix-descriptions) "The user interface for selecting an agenda command." (catch 'exit @@ -18383,13 +19342,14 @@ Pressing `<' twice means to restrict to the current subtree or region (erase-buffer) (insert (eval-when-compile (let ((header -"Press key for an agenda command: < Buffer,subtree/region restriction --------------------------------- C Configure custom agenda commands +" +Press key for an agenda command: < Buffer,subtree/region restriction +-------------------------------- > Remove restriction a Agenda for current week or day e Export agenda views t List of all TODO entries T Entries with special TODO kwd m Match a TAGS query M Like m, but only TODO entries L Timeline for current buffer # List stuck projects (!=configure) -/ Multi-occur +/ Multi-occur C Configure custom agenda commands ") (start 0)) (while (string-match @@ -18405,10 +19365,10 @@ L Timeline for current buffer # List stuck projects (!=configure) (when (eq rmheader t) (goto-line 1) (re-search-forward ":" nil t) - (delete-region (match-end 0) (line-end-position)) + (delete-region (match-end 0) (point-at-eol)) (forward-char 1) (looking-at "-+") - (delete-region (match-end 0) (line-end-position)) + (delete-region (match-end 0) (point-at-eol)) (move-marker header-end (match-end 0))) (goto-char header-end) (delete-region (point) (point-max)) @@ -18461,10 +19421,12 @@ L Timeline for current buffer # List stuck projects (!=configure) (setq second-time t) (fit-window-to-buffer))) (message "Press key for agenda command%s:" - (if restrict-ok - (if restriction - (format " (restricted to %s)" restriction) - " (unrestricted)") + (if (or restrict-ok org-agenda-overriding-restriction) + (if org-agenda-overriding-restriction + " (restriction lock active)" + (if restriction + (format " (restricted to %s)" restriction) + " (unrestricted)")) "")) (setq c (read-char-exclusive)) (message "") @@ -18487,10 +19449,13 @@ L Timeline for current buffer # List stuck projects (!=configure) (message "Restriction is only possible in Org-mode buffers") (ding) (sit-for 1)) ((eq c ?1) + (org-agenda-remove-restriction-lock 'noupdate) (setq restriction 'buffer)) ((eq c ?0) + (org-agenda-remove-restriction-lock 'noupdate) (setq restriction (if region-p 'region 'subtree))) ((eq c ?<) + (org-agenda-remove-restriction-lock 'noupdate) (setq restriction (cond ((eq restriction 'buffer) @@ -18498,8 +19463,15 @@ L Timeline for current buffer # List stuck projects (!=configure) ((memq restriction '(subtree region)) nil) (t 'buffer)))) - ((and (equal selstring "") (memq c '(?a ?t ?m ?L ?C ?e ?T ?M ?# ?/))) + ((eq c ?>) + (org-agenda-remove-restriction-lock 'noupdate) + (setq restriction nil)) + ((and (equal selstring "") (memq c '(?a ?t ?m ?L ?C ?e ?T ?M ?# ?! ?/))) (throw 'exit (cons (setq selstring (char-to-string c)) restriction))) + ((and (> (length selstring) 0) (eq c ?\d)) + (delete-window) + (org-agenda-get-restriction-and-command prefix-descriptions)) + ((equal c ?q) (error "Abort")) (t (error "Invalid key %c" c)))))))) @@ -18678,7 +19650,7 @@ so the the export commands caneasily use it." ;;;###autoload (defmacro org-batch-store-agenda-views (&rest parameters) "Run all custom agenda commands that have a file argument." - (let ((cmds org-agenda-custom-commands) + (let ((cmds (org-agenda-normalize-custom-commands org-agenda-custom-commands)) (pop-up-frames nil) (dir default-directory) pars cmd thiscmdkey files opts) @@ -18689,8 +19661,8 @@ so the the export commands caneasily use it." (while cmds (setq cmd (pop cmds) thiscmdkey (car cmd) - opts (nth 3 cmd) - files (nth 4 cmd)) + opts (nth 4 cmd) + files (nth 5 cmd)) (if (stringp files) (setq files (list files))) (when files (eval (list 'let (append org-agenda-exporter-settings opts pars) @@ -18780,7 +19752,8 @@ is currently in place." (setq files (apply 'append (mapcar (lambda (f) (if (file-directory-p f) - (directory-files f t "\\.org\\'") + (directory-files f t + org-agenda-file-regexp) (list f))) files))) (if org-agenda-skip-unavailable-files @@ -18811,7 +19784,7 @@ the buffer and restores the previous window configuration." (message "New agenda file list installed")) nil 'local) (message "%s" (substitute-command-keys - "Edit list and finish with \\[save-buffer]"))) + "Edit list and finish with \\[save-buffer]"))) (customize-variable 'org-agenda-files))) (defun org-store-new-agenda-file-list (list) @@ -18896,7 +19869,7 @@ Optional argument FILE means, use this file instead of the current." (org-store-new-agenda-file-list files) (org-install-agenda-files-menu) (message "Removed file: %s" afile)) - (message "File was not in list: %s" afile)))) + (message "File was not in list: %s (not removed)" afile)))) (defun org-file-menu-entry (file) (vector file (list 'find-file file) t)) @@ -18985,10 +19958,9 @@ Optional argument FILE means, use this file instead of the current." (interactive) (mapc (lambda (o) (if (eq (org-overlay-get o 'org-type) 'org-priority) (org-delete-overlay o))) - (overlays-in (point-min) (point-max))) + (org-overlays-in (point-min) (point-max))) (save-excursion - (let ((ovs (org-overlays-in (point-min) (point-max))) - (inhibit-read-only t) + (let ((inhibit-read-only t) b e p ov h l) (goto-char (point-min)) (while (re-search-forward "\\[#\\(.\\)\\]" nil t) @@ -18997,7 +19969,7 @@ Optional argument FILE means, use this file instead of the current." l (or (get-char-property (point) 'org-lowest-priority) org-lowest-priority) p (string-to-char (match-string 1)) - b (match-beginning 0) e (line-end-position) + b (match-beginning 0) e (point-at-eol) ov (org-make-overlay b e)) (org-overlay-put ov 'face @@ -19019,8 +19991,10 @@ Optional argument FILE means, use this file instead of the current." (save-excursion (save-restriction (while (setq file (pop files)) - (org-check-agenda-file file) - (set-buffer (org-get-agenda-file-buffer file)) + (if (bufferp file) + (set-buffer file) + (org-check-agenda-file file) + (set-buffer (org-get-agenda-file-buffer file))) (widen) (setq bmp (buffer-modified-p)) (org-refresh-category-properties) @@ -19099,9 +20073,6 @@ no longer in use." (while org-agenda-markers (move-marker (pop org-agenda-markers) nil)))) -(defvar org-agenda-new-buffers nil - "Buffers created to visit agenda files.") - (defun org-get-agenda-file-buffer (file) "Get a buffer visiting FILE. If the buffer needs to be created, add it to the list of buffers which might be released later." @@ -19306,7 +20277,9 @@ given in `org-agenda-start-on-weekday'." org-agenda-start-on-weekday nil)) (thefiles (org-agenda-files)) (files thefiles) - (today (time-to-days (current-time))) + (today (time-to-days + (time-subtract (current-time) + (list 0 (* 3600 org-extend-today-until) 0)))) (sd (or start-day today)) (start (if (or (null org-agenda-start-on-weekday) (< org-agenda-ndays 7)) @@ -19579,11 +20552,12 @@ to skip this subtree. This is a function that can be put into (defun org-agenda-skip-entry-if (&rest conditions) "Skip entry if any of CONDITIONS is true. -See `org-agenda-skip-if for details." +See `org-agenda-skip-if' for details." (org-agenda-skip-if nil conditions)) + (defun org-agenda-skip-subtree-if (&rest conditions) "Skip entry if any of CONDITIONS is true. -See `org-agenda-skip-if for details." +See `org-agenda-skip-if' for details." (org-agenda-skip-if t conditions)) (defun org-agenda-skip-if (subtree conditions) @@ -19601,13 +20575,13 @@ notdeadline Check if there is no deadline regexp Check if regexp matches notregexp Check if regexp does not match. -The regexp is taken from the conditions list, it must com right after the -`regexp' of `notregexp' element. +The regexp is taken from the conditions list, it must come right after +the `regexp' or `notregexp' element. If any of these conditions is met, this function returns the end point of the entity, causing the search to continue from there. This is a function that can be put into `org-agenda-skip-function' for the duration of a command." - (let (beg end m r) + (let (beg end m) (org-back-to-heading t) (setq beg (point) end (if subtree @@ -19625,13 +20599,14 @@ that can be put into `org-agenda-skip-function' for the duration of a command." (and (memq 'notdeadline conditions) (not (re-search-forward org-deadline-time-regexp end t))) (and (setq m (memq 'regexp conditions)) - (stringp (setq r (nth 1 m))) + (stringp (nth 1 m)) (re-search-forward (nth 1 m) end t)) (and (setq m (memq 'notregexp conditions)) - (stringp (setq r (nth 1 m))) + (stringp (nth 1 m)) (not (re-search-forward (nth 1 m) end t)))) end))) +;;;###autoload (defun org-agenda-list-stuck-projects (&rest ignore) "Create agenda view for projects that are stuck. Stuck projects are project that have no next actions. For the definitions @@ -19898,14 +20873,6 @@ the documentation of `org-diary'." (setq results (append results rtn)))))))) results)))) -;; FIXME: this works only if the cursor is *not* at the -;; beginning of the entry -;(defun org-entry-is-done-p () -; "Is the current entry marked DONE?" -; (save-excursion -; (and (re-search-backward "[\r\n]\\*+ " nil t) -; (looking-at org-nl-done-regexp)))) - (defun org-entry-is-todo-p () (member (org-get-todo-state) org-not-done-keywords)) @@ -20027,7 +20994,7 @@ the documentation of `org-diary'." "\\|\\(<[0-9]+-[0-9]+-[0-9]+[^>\n]+?\\+[0-9]+[dwmy]>\\)" "\\|\\(<%%\\(([^>\n]+)\\)>\\)")) marker hdmarker deadlinep scheduledp donep tmp priority category - ee txt timestr tags b0 b3 e3) + ee txt timestr tags b0 b3 e3 head) (goto-char (point-min)) (while (re-search-forward regexp nil t) (setq b0 (match-beginning 0) @@ -20061,8 +21028,10 @@ the documentation of `org-diary'." (setq hdmarker (org-agenda-new-marker) tags (org-get-tags-at)) (looking-at "\\*+[ \t]+\\([^\r\n]+\\)") + (setq head (match-string 1)) + (and org-agenda-skip-timestamp-if-done donep (throw :skip t)) (setq txt (org-format-agenda-item - nil (match-string 1) category tags timestr nil + nil head category tags timestr nil remove-re))) (setq txt org-agenda-no-heading-message)) (setq priority (org-get-priority txt)) @@ -20334,7 +21303,8 @@ FRACTION is what fraction of the head-warning time has passed." (abbreviate-file-name buffer-file-name)))) (regexp org-tr-regexp) (d0 (calendar-absolute-from-gregorian date)) - marker hdmarker ee txt d1 d2 s1 s2 timestr category tags pos) + marker hdmarker ee txt d1 d2 s1 s2 timestr category tags pos + donep head) (goto-char (point-min)) (while (re-search-forward regexp nil t) (catch :skip @@ -20357,10 +21327,14 @@ FRACTION is what fraction of the head-warning time has passed." (setq hdmarker (org-agenda-new-marker (point))) (setq tags (org-get-tags-at)) (looking-at "\\*+[ \t]+\\([^\r\n]+\\)") + (setq head (match-string 1)) + (and org-agenda-skip-timestamp-if-done + (org-entry-is-done-p) + (throw :skip t)) (setq txt (org-format-agenda-item (format (if (= d1 d2) "" "(%d/%d): ") (1+ (- d0 d1)) (1+ (- d2 d1))) - (match-string 1) category tags + head category tags (if (= d0 d1) timestr)))) (setq txt org-agenda-no-heading-message)) (org-add-props txt props @@ -20521,7 +21495,7 @@ Any match of REMOVE-RE will be removed from TXT." 'extra extra 'dotime dotime)))) -(defvar org-agenda-sorting-strategy) ;; FIXME: can be removed? +(defvar org-agenda-sorting-strategy) ;; because the def is in a let form (defvar org-agenda-sorting-strategy-selected nil) (defun org-agenda-add-time-grid-maybe (list ndays todayp) @@ -20639,16 +21613,32 @@ HH:MM." (beginning-of-line 1) (setq re (get-text-property (point) 'org-todo-regexp)) (goto-char (+ (point) (or (get-text-property (point) 'prefix-length) 0))) - (and (looking-at (concat "[ \t]*\\.*" re)) - (add-text-properties (match-beginning 0) (match-end 0) - (list 'face (org-get-todo-face 0))))) + (when (looking-at (concat "[ \t]*\\.*" re " +")) + (add-text-properties (match-beginning 0) (match-end 0) + (list 'face (org-get-todo-face 0))) + (let ((s (buffer-substring (match-beginning 1) (match-end 1)))) + (delete-region (match-beginning 1) (1- (match-end 0))) + (goto-char (match-beginning 1)) + (insert (format org-agenda-todo-keyword-format s))))) (setq re (concat (get-text-property 0 'org-todo-regexp x)) pl (get-text-property 0 'prefix-length x)) - (and re (equal (string-match (concat "\\(\\.*\\)" re) x (or pl 0)) pl) - (add-text-properties - (or (match-end 1) (match-end 0)) (match-end 0) - (list 'face (org-get-todo-face (match-string 2 x))) - x)) +; (and re (equal (string-match (concat "\\(\\.*\\)" re) x (or pl 0)) pl) +; (add-text-properties +; (or (match-end 1) (match-end 0)) (match-end 0) +; (list 'face (org-get-todo-face (match-string 2 x))) +; x)) + (when (and re + (equal (string-match (concat "\\(\\.*\\)" re "\\( +\\)") + x (or pl 0)) pl)) + (add-text-properties + (or (match-end 1) (match-end 0)) (match-end 0) + (list 'face (org-get-todo-face (match-string 2 x))) + x) + (setq x (concat (substring x 0 (match-end 1)) + (format org-agenda-todo-keyword-format + (match-string 2 x)) + " " + (substring x (match-end 3))))) x))) (defsubst org-cmp-priority (a b) @@ -20703,6 +21693,85 @@ HH:MM." (eval (cons 'or org-agenda-sorting-strategy-selected)) '((-1 . t) (1 . nil) (nil . nil)))))) +;;; Agenda restriction lock + +(defvar org-agenda-restriction-lock-overlay (org-make-overlay 1 1) + "Overlay to mark the headline to which arenda commands are restricted.") +(org-overlay-put org-agenda-restriction-lock-overlay + 'face 'org-agenda-restriction-lock) +(org-overlay-put org-agenda-restriction-lock-overlay + 'help-echo "Agendas are currently limited to this subtree.") +(org-detach-overlay org-agenda-restriction-lock-overlay) +(defvar org-speedbar-restriction-lock-overlay (org-make-overlay 1 1) + "Overlay marking the agenda restriction line in speedbar.") +(org-overlay-put org-speedbar-restriction-lock-overlay + 'face 'org-agenda-restriction-lock) +(org-overlay-put org-speedbar-restriction-lock-overlay + 'help-echo "Agendas are currently limited to this item.") +(org-detach-overlay org-speedbar-restriction-lock-overlay) + +(defun org-agenda-set-restriction-lock (&optional type) + "Set restriction lock for agenda, to current subtree or file. +Restriction will be the file if TYPE is `file', or if type is the +universal prefix '(4), or if the cursor is before the first headline +in the file. Otherwise, restriction will be to the current subtree." + (interactive "P") + (and (equal type '(4)) (setq type 'file)) + (setq type (cond + (type type) + ((org-at-heading-p) 'subtree) + ((condition-case nil (org-back-to-heading t) (error nil)) + 'subtree) + (t 'file))) + (if (eq type 'subtree) + (progn + (setq org-agenda-restrict t) + (setq org-agenda-overriding-restriction 'subtree) + (put 'org-agenda-files 'org-restrict + (list (buffer-file-name (buffer-base-buffer)))) + (org-back-to-heading t) + (org-move-overlay org-agenda-restriction-lock-overlay (point) (point-at-eol)) + (move-marker org-agenda-restrict-begin (point)) + (move-marker org-agenda-restrict-end + (save-excursion (org-end-of-subtree t))) + (message "Locking agenda restriction to subtree")) + (put 'org-agenda-files 'org-restrict + (list (buffer-file-name (buffer-base-buffer)))) + (setq org-agenda-restrict nil) + (setq org-agenda-overriding-restriction 'file) + (move-marker org-agenda-restrict-begin nil) + (move-marker org-agenda-restrict-end nil) + (message "Locking agenda restriction to file")) + (setq current-prefix-arg nil) + (org-agenda-maybe-redo)) + +(defun org-agenda-remove-restriction-lock (&optional noupdate) + "Remove the agenda restriction lock." + (interactive "P") + (org-detach-overlay org-agenda-restriction-lock-overlay) + (org-detach-overlay org-speedbar-restriction-lock-overlay) + (setq org-agenda-overriding-restriction nil) + (setq org-agenda-restrict nil) + (put 'org-agenda-files 'org-restrict nil) + (move-marker org-agenda-restrict-begin nil) + (move-marker org-agenda-restrict-end nil) + (setq current-prefix-arg nil) + (message "Agenda restriction lock removed") + (or noupdate (org-agenda-maybe-redo))) + +(defun org-agenda-maybe-redo () + "If there is any window showing the agenda view, update it." + (let ((w (get-buffer-window org-agenda-buffer-name t)) + (w0 (selected-window))) + (when w + (select-window w) + (org-agenda-redo) + (select-window w0) + (if org-agenda-overriding-restriction + (message "Agenda view shifted to new %s restriction" + org-agenda-overriding-restriction) + (message "Agenda restriction lock removed"))))) + ;;; Agenda commands (defun org-agenda-check-type (error &rest types) @@ -20737,6 +21806,13 @@ Org-mode buffers visited directly by the user will not be touched." (setq org-agenda-new-buffers nil) (org-agenda-quit)) +(defun org-agenda-execute (arg) + "Execute another agenda command, keeping same window.\\ +So this is just a shortcut for `\\[org-agenda]', available in the agenda." + (interactive "P") + (let ((org-agenda-window-setup 'current-window)) + (org-agenda arg))) + (defun org-save-all-org-buffers () "Save all Org-mode buffers without user confirmation." (interactive) @@ -20773,7 +21849,9 @@ When this is the global TODO list, a prefix argument will be interpreted." (cond (tdpos (goto-char tdpos)) ((eq org-agenda-type 'agenda) - (let* ((sd (time-to-days (current-time))) + (let* ((sd (time-to-days + (time-subtract (current-time) + (list 0 (* 3600 org-extend-today-until) 0)))) (comp (org-agenda-compute-time-span sd org-agenda-span)) (org-agenda-overriding-arguments org-agenda-last-arguments)) (setf (nth 1 org-agenda-overriding-arguments) (car comp)) @@ -22037,6 +23115,7 @@ The images can be removed again with \\[org-ctrl-c-ctrl-c]." (:archived-trees . org-export-with-archived-trees) (:emphasize . org-export-with-emphasize) (:sub-superscript . org-export-with-sub-superscripts) + (:special-strings . org-export-with-special-strings) (:footnotes . org-export-with-footnotes) (:drawers . org-export-with-drawers) (:tags . org-export-with-tags) @@ -22050,10 +23129,11 @@ The images can be removed again with \\[org-ctrl-c-ctrl-c]." (:tables . org-export-with-tables) (:table-auto-headline . org-export-highlight-first-table-line) (:style . org-export-html-style) - (:agenda-style . org-agenda-export-html-style) ;; FIXME: Does this work???? + (:agenda-style . org-agenda-export-html-style) (:convert-org-links . org-export-html-link-org-files-as-html) (:inline-images . org-export-html-inline-images) (:html-extension . org-export-html-extension) + (:html-table-tag . org-export-html-table-tag) (:expand-quoted-html . org-export-html-expand) (:timestamp . org-export-html-with-timestamp) (:publishing-directory . org-export-publishing-directory) @@ -22074,50 +23154,53 @@ The images can be removed again with \\[org-ctrl-c-ctrl-c]." (defun org-infile-export-plist () "Return the property list with file-local settings for export." (save-excursion - (goto-char 0) - (let ((re (org-make-options-regexp - '("TITLE" "AUTHOR" "DATE" "EMAIL" "TEXT" "OPTIONS" "LANGUAGE"))) - p key val text options) - (while (re-search-forward re nil t) - (setq key (org-match-string-no-properties 1) - val (org-match-string-no-properties 2)) - (cond - ((string-equal key "TITLE") (setq p (plist-put p :title val))) - ((string-equal key "AUTHOR")(setq p (plist-put p :author val))) - ((string-equal key "EMAIL") (setq p (plist-put p :email val))) - ((string-equal key "DATE") (setq p (plist-put p :date val))) - ((string-equal key "LANGUAGE") (setq p (plist-put p :language val))) - ((string-equal key "TEXT") - (setq text (if text (concat text "\n" val) val))) - ((string-equal key "OPTIONS") (setq options val)))) - (setq p (plist-put p :text text)) - (when options - (let ((op '(("H" . :headline-levels) - ("num" . :section-numbers) - ("toc" . :table-of-contents) - ("\\n" . :preserve-breaks) - ("@" . :expand-quoted-html) - (":" . :fixed-width) - ("|" . :tables) - ("^" . :sub-superscript) - ("f" . :footnotes) - ("d" . :drawers) - ("tags" . :tags) - ("*" . :emphasize) - ("TeX" . :TeX-macros) - ("LaTeX" . :LaTeX-fragments) - ("skip" . :skip-before-1st-heading) - ("author" . :author-info) - ("timestamp" . :time-stamp-file))) - o) - (while (setq o (pop op)) - (if (string-match (concat (regexp-quote (car o)) - ":\\([^ \t\n\r;,.]*\\)") - options) - (setq p (plist-put p (cdr o) - (car (read-from-string - (match-string 1 options))))))))) - p))) + (save-restriction + (widen) + (goto-char 0) + (let ((re (org-make-options-regexp + '("TITLE" "AUTHOR" "DATE" "EMAIL" "TEXT" "OPTIONS" "LANGUAGE"))) + p key val text options) + (while (re-search-forward re nil t) + (setq key (org-match-string-no-properties 1) + val (org-match-string-no-properties 2)) + (cond + ((string-equal key "TITLE") (setq p (plist-put p :title val))) + ((string-equal key "AUTHOR")(setq p (plist-put p :author val))) + ((string-equal key "EMAIL") (setq p (plist-put p :email val))) + ((string-equal key "DATE") (setq p (plist-put p :date val))) + ((string-equal key "LANGUAGE") (setq p (plist-put p :language val))) + ((string-equal key "TEXT") + (setq text (if text (concat text "\n" val) val))) + ((string-equal key "OPTIONS") (setq options val)))) + (setq p (plist-put p :text text)) + (when options + (let ((op '(("H" . :headline-levels) + ("num" . :section-numbers) + ("toc" . :table-of-contents) + ("\\n" . :preserve-breaks) + ("@" . :expand-quoted-html) + (":" . :fixed-width) + ("|" . :tables) + ("^" . :sub-superscript) + ("-" . :special-strings) + ("f" . :footnotes) + ("d" . :drawers) + ("tags" . :tags) + ("*" . :emphasize) + ("TeX" . :TeX-macros) + ("LaTeX" . :LaTeX-fragments) + ("skip" . :skip-before-1st-heading) + ("author" . :author-info) + ("timestamp" . :time-stamp-file))) + o) + (while (setq o (pop op)) + (if (string-match (concat (regexp-quote (car o)) + ":\\([^ \t\n\r;,.]*\\)") + options) + (setq p (plist-put p (cdr o) + (car (read-from-string + (match-string 1 options))))))))) + p)))) (defun org-export-directory (type plist) (let* ((val (plist-get plist :publishing-directory)) @@ -22400,8 +23483,8 @@ The images can be removed again with \\[org-ctrl-c-ctrl-c]." ("prop") ("proptp"."∝") ("infin") ("infty"."∞") ("ang") ("angle"."∠") - ("and") ("vee"."∧") - ("or") ("wedge"."∨") + ("and") ("wedge"."∧") + ("or") ("vee"."∨") ("cap") ("cup") ("int") @@ -22526,6 +23609,8 @@ translations. There is currently no way for users to extend this.") (commentsp (plist-get parameters :comments)) (archived-trees (plist-get parameters :archived-trees)) (inhibit-read-only t) + (drawers org-drawers) + (exp-drawers (plist-get parameters :drawers)) (outline-regexp "\\*+ ") a b xx rtn p) @@ -22564,14 +23649,14 @@ translations. There is currently no way for users to extend this.") (if (> b a) (delete-region a b))))) ;; Get rid of drawers - (unless (eq t org-export-with-drawers) + (unless (eq t exp-drawers) (goto-char (point-min)) (let ((re (concat "^[ \t]*:\\(" - (mapconcat 'identity - (if (listp org-export-with-drawers) - org-export-with-drawers - org-drawers) - "\\|") + (mapconcat + 'identity + (org-delete-all exp-drawers + (copy-sequence drawers)) + "\\|") "\\):[ \t]*\n\\([^@]*?\n\\)?[ \t]*:END:[ \t]*\n"))) (while (re-search-forward re nil t) (replace-match "")))) @@ -22583,12 +23668,18 @@ translations. There is currently no way for users to extend this.") (replace-match "\\1(INVISIBLE)")) ;; Protect backend specific stuff, throw away the others. - (goto-char (point-min)) (let ((formatters `((,htmlp "HTML" "BEGIN_HTML" "END_HTML") (,asciip "ASCII" "BEGIN_ASCII" "END_ASCII") (,latexp "LaTeX" "BEGIN_LaTeX" "END_LaTeX"))) fmt) + (goto-char (point-min)) + (while (re-search-forward "^#\\+BEGIN_EXAMPLE[ \t]*\n" nil t) + (goto-char (match-end 0)) + (while (not (looking-at "#\\+END_EXAMPLE")) + (insert ": ") + (beginning-of-line 2))) + (goto-char (point-min)) (while (re-search-forward "^[ \t]*:.*\\(\n[ \t]*:.*\\)*" nil t) (add-text-properties (match-beginning 0) (match-end 0) '(org-protected t))) @@ -22620,6 +23711,13 @@ translations. There is currently no way for users to extend this.") (add-text-properties (point) (org-end-of-subtree t) '(org-protected t))) + ;; Protect verbatim elements + (goto-char (point-min)) + (while (re-search-forward org-verbatim-re nil t) + (add-text-properties (match-beginning 4) (match-end 4) + '(org-protected t)) + (goto-char (1+ (match-end 4)))) + ;; Remove subtrees that are commented (goto-char (point-min)) (while (re-search-forward re-commented nil t) @@ -22643,6 +23741,9 @@ translations. There is currently no way for users to extend this.") (require 'org-export-latex nil) (org-export-latex-cleaned-string)) + (when asciip + (org-export-ascii-clean-string)) + ;; Specific HTML stuff (when htmlp ;; Convert LaTeX fragments to images @@ -22890,6 +23991,8 @@ underlined headlines. The default is 3." :for-ascii t :skip-before-1st-heading (plist-get opt-plist :skip-before-1st-heading) + :drawers (plist-get opt-plist :drawers) + :verbatim-multiline t :archived-trees (plist-get opt-plist :archived-trees) :add-text (plist-get opt-plist :text)) @@ -23086,6 +24189,16 @@ underlined headlines. The default is 3." (goto-char beg))) (goto-char (point-min)))) +(defun org-export-ascii-clean-string () + "Do extra work for ASCII export" + (goto-char (point-min)) + (while (re-search-forward org-verbatim-re nil t) + (goto-char (match-end 2)) + (backward-delete-char 1) (insert "'") + (goto-char (match-beginning 2)) + (delete-char 1) (insert "`") + (goto-char (match-end 2)))) + (defun org-search-todo-below (line lines level) "Search the subtree below LINE for any TODO entries." (let ((rest (cdr (memq line lines))) @@ -23235,7 +24348,7 @@ Does include HTML export options as well as TODO and CATEGORY stuff." #+EMAIL: %s #+LANGUAGE: %s #+TEXT: Some descriptive text to be emitted. Several lines OK. -#+OPTIONS: H:%d num:%s toc:%s \\n:%s @:%s ::%s |:%s ^:%s f:%s *:%s TeX:%s LaTeX:%s skip:%s d:%s tags:%s +#+OPTIONS: H:%d num:%s toc:%s \\n:%s @:%s ::%s |:%s ^:%s -:%s f:%s *:%s TeX:%s LaTeX:%s skip:%s d:%s tags:%s #+CATEGORY: %s #+SEQ_TODO: %s #+TYP_TODO: %s @@ -23255,6 +24368,7 @@ Does include HTML export options as well as TODO and CATEGORY stuff." org-export-with-fixed-width org-export-with-tables org-export-with-sub-superscripts + org-export-with-special-strings org-export-with-footnotes org-export-with-emphasize org-export-with-TeX-macros @@ -23311,6 +24425,7 @@ this line is also exported in fixed-width font." (beg (if regionp (region-beginning) (point))) (end (if regionp (region-end))) (nlines (or arg (if (and beg end) (count-lines beg end) 1))) + (case-fold-search nil) (re "[ \t]*\\(:\\)") off) (if regionp @@ -23418,6 +24533,7 @@ in a window. A non-interactive call will only retunr the buffer." (switch-to-buffer-other-window rtn) rtn))) +(defvar html-table-tag nil) ; dynamically scoped into this. (defun org-export-as-html (arg &optional hidden ext-plist to-buffer body-only) "Export the outline as a pretty HTML file. @@ -23472,14 +24588,16 @@ the body tags themselves." (umax nil) (umax-toc nil) (filename (if to-buffer nil - (concat (file-name-as-directory - (org-export-directory :html opt-plist)) - (file-name-sans-extension - (or (and subtree-p - (org-entry-get (region-beginning) - "EXPORT_FILE_NAME" t)) - (file-name-nondirectory buffer-file-name))) - "." org-export-html-extension))) + (expand-file-name + (concat + (file-name-sans-extension + (or (and subtree-p + (org-entry-get (region-beginning) + "EXPORT_FILE_NAME" t)) + (file-name-nondirectory buffer-file-name))) + "." org-export-html-extension) + (file-name-as-directory + (org-export-directory :html opt-plist))))) (current-dir (if buffer-file-name (file-name-directory buffer-file-name) default-directory)) @@ -23500,6 +24618,7 @@ the body tags themselves." (file-name-sans-extension (file-name-nondirectory buffer-file-name))) "UNTITLED")) + (html-table-tag (plist-get opt-plist :html-table-tag)) (quote-re0 (concat "^[ \t]*" org-quote-string "\\>")) (quote-re (concat "^\\(\\*+\\)\\([ \t]+" org-quote-string "\\>\\)")) (inquote nil) @@ -23536,6 +24655,7 @@ the body tags themselves." :for-html t :skip-before-1st-heading (plist-get opt-plist :skip-before-1st-heading) + :drawers (plist-get opt-plist :drawers) :archived-trees (plist-get opt-plist :archived-trees) :add-text @@ -23572,7 +24692,7 @@ the body tags themselves." ;; Switch to the output buffer (set-buffer buffer) - (erase-buffer) + (let ((inhibit-read-only t)) (erase-buffer)) (fundamental-mode) (and (fboundp 'set-buffer-file-coding-system) @@ -23735,7 +24855,8 @@ lang=\"%s\" xml:lang=\"%s\"> (replace-match "\\2\n")) (insert line "\n") (while (and lines - (get-text-property 0 'org-protected (car lines))) + (or (= (length (car lines)) 0) + (get-text-property 0 'org-protected (car lines)))) (insert (pop lines) "\n")) (and par (insert "

\n"))) (throw 'nextline nil)) @@ -23771,7 +24892,8 @@ lang=\"%s\" xml:lang=\"%s\"> ;; replace "&" by "&", "<" and ">" by "<" and ">" ;; handle @<..> HTML tags (replace "@>..<" by "<..>") ;; Also handle sub_superscripts and checkboxes - (setq line (org-html-expand line)) + (or (string-match org-table-hline-regexp line) + (setq line (org-html-expand line))) ;; Format the links (setq start 0) @@ -23871,14 +24993,17 @@ lang=\"%s\" xml:lang=\"%s\"> ;; Does this contain a reference to a footnote? (when org-export-with-footnotes - (while (string-match "\\([^* \t].*?\\)\\[\\([0-9]+\\)\\]" line) - (let ((n (match-string 2 line))) - (setq line - (replace-match - (format - "%s%s" - (match-string 1 line) n n n) - t t line))))) + (setq start 0) + (while (string-match "\\([^* \t].*?\\)\\[\\([0-9]+\\)\\]" line start) + (if (get-text-property (match-beginning 2) 'org-protected line) + (setq start (match-end 2)) + (let ((n (match-string 2 line))) + (setq line + (replace-match + (format + "%s%s" + (match-string 1 line) n n n) + t t line)))))) (cond ((string-match "^\\(\\*+\\)[ \t]+\\(.*\\)" line) @@ -24008,7 +25133,7 @@ lang=\"%s\" xml:lang=\"%s\"> (pop local-list-num)) (setq local-list-indent nil in-local-list nil)) - (org-html-level-start 0 nil umax + (org-html-level-start 1 nil umax (and org-export-with-toc (<= level umax)) head-count) @@ -24019,8 +25144,13 @@ lang=\"%s\" xml:lang=\"%s\"> (insert "

" (nth 1 lang-words) ": " author "\n") (when email - (insert "<" - email ">\n")) + (if (listp (split-string email ",+ *")) + (mapc (lambda(e) + (insert "<" + e ">\n")) + (split-string email ",+ *")) + (insert "<" + email ">\n"))) (insert "

\n")) (when (and date org-export-time-stamp-file) (insert "

" @@ -24204,11 +25334,11 @@ lang=\"%s\" xml:lang=\"%s\"> (unless splice (push "\n" html)) (setq html (nreverse html)) (unless splice - ;; Put in COL tags with the alignment (unfortuntely often ignored...) + ;; Put in col tags with the alignment (unfortuntely often ignored...) (push (mapconcat (lambda (x) (setq gr (pop org-table-colgroup-info)) - (format "%s%s" + (format "%s%s" (if (memq gr '(:start :startend)) (prog1 (if colgropen "\n" "") @@ -24222,7 +25352,7 @@ lang=\"%s\" xml:lang=\"%s\"> fnum "") html) (if colgropen (setq html (cons (car html) (cons "" (cdr html))))) - (push org-export-html-table-tag html)) + (push html-table-tag html)) (concat (mapconcat 'identity html "\n") "\n"))) (defun org-table-clean-before-export (lines) @@ -24270,8 +25400,7 @@ If yes remove the column and the special lines." ((or (string-match "^\\([ \t]*\\)|-+\\+" x) (string-match "^\\([ \t]*\\)|[^|]*|" x)) ;; remove the first column - (replace-match "\\1|" t nil x)) - (t (error "This should not happen")))) + (replace-match "\\1|" t nil x)))) lines)))) (defun org-format-table-table-html (lines) @@ -24282,7 +25411,7 @@ But it has the disadvantage, that no cell- or row-spanning is allowed." (let (line field-buffer (head org-export-highlight-first-table-line) fields html empty) - (setq html (concat org-export-html-table-tag "\n")) + (setq html (concat html-table-tag "\n")) (while (setq line (pop lines)) (setq empty " ") (catch 'next-line @@ -24410,21 +25539,26 @@ If there are links in the string, don't modify these." "Apply all active conversions to translate special ASCII to HTML." (setq s (org-html-protect s)) (if org-export-html-expand - (while (string-match "@<\\([^&]*\\)>" s) - (setq s (replace-match "<\\1>" t nil s)))) + (let ((start 0)) + (while (string-match "@<\\([^&]*\\)>" s) + (setq s (replace-match "<\\1>" t nil s))))) (if org-export-with-emphasize (setq s (org-export-html-convert-emphasize s))) + (if org-export-with-special-strings + (setq s (org-export-html-convert-special-strings s))) (if org-export-with-sub-superscripts (setq s (org-export-html-convert-sub-super s))) (if org-export-with-TeX-macros (let ((start 0) wd ass) (while (setq start (string-match "\\\\\\([a-zA-Z]+\\)" s start)) - (setq wd (match-string 1 s)) - (if (setq ass (assoc wd org-html-entities)) - (setq s (replace-match (or (cdr ass) - (concat "&" (car ass) ";")) - t t s)) - (setq start (+ start (length wd))))))) + (if (get-text-property (match-beginning 0) 'org-protected s) + (setq start (match-end 0)) + (setq wd (match-string 1 s)) + (if (setq ass (assoc wd org-html-entities)) + (setq s (replace-match (or (cdr ass) + (concat "&" (car ass) ";")) + t t s)) + (setq start (+ start (length wd)))))))) s) (defun org-create-multibrace-regexp (left right n) @@ -24455,16 +25589,41 @@ stacked delimiters is N. Escaping delimiters is not possible." "\\(\\(?:\\*\\|[-+]?[^-+*!@#$%^_ \t\r\n,:\"?<>~;./{}=()]+\\)\\)\\)") "The regular expression matching a sub- or superscript.") -;(let ((s "a\\_b")) -; (and (string-match org-match-substring-regexp s) -; (conca t (match-string 1 s) ":::" (match-string 2 s)))) +(defvar org-match-substring-with-braces-regexp + (concat + "\\([^\\]\\)\\([_^]\\)\\(" + "\\(" (org-create-multibrace-regexp "{" "}" org-match-sexp-depth) "\\)" + "\\)") + "The regular expression matching a sub- or superscript, forcing braces.") + +(defconst org-export-html-special-string-regexps + '(("\\\\-" . "­") + ("---\\([^-]\\)" . "—\\1") + ("--\\([^-]\\)" . "–\\1") + ("\\.\\.\\." . "…")) + "Regular expressions for special string conversion.") + +(defun org-export-html-convert-special-strings (string) + "Convert special characters in STRING to HTML." + (let ((all org-export-html-special-string-regexps) + e a re rpl start) + (while (setq a (pop all)) + (setq re (car a) rpl (cdr a) start 0) + (while (string-match re string start) + (if (get-text-property (match-beginning 0) 'org-protected string) + (setq start (match-end 0)) + (setq string (replace-match rpl t nil string))))) + string)) (defun org-export-html-convert-sub-super (string) "Convert sub- and superscripts in STRING to HTML." (let (key c (s 0) (requireb (eq org-export-with-sub-superscripts '{}))) (while (string-match org-match-substring-regexp string s) - (if (and requireb (match-end 8)) - (setq s (match-end 2)) + (cond + ((and requireb (match-end 8)) (setq s (match-end 2))) + ((get-text-property (match-beginning 2) 'org-protected string) + (setq s (match-end 2))) + (t (setq s (match-end 1) key (if (string= (match-string 2 string) "_") "sub" "sup") c (or (match-string 8 string) @@ -24473,22 +25632,29 @@ stacked delimiters is N. Escaping delimiters is not possible." string (replace-match (concat (match-string 1 string) "<" key ">" c "") - t t string)))) + t t string))))) (while (string-match "\\\\\\([_^]\\)" string) (setq string (replace-match (match-string 1 string) t t string))) string)) (defun org-export-html-convert-emphasize (string) "Apply emphasis." - (let ((s 0)) + (let ((s 0) rpl) (while (string-match org-emph-re string s) (if (not (equal (substring string (match-beginning 3) (1+ (match-beginning 3))) (substring string (match-beginning 4) (1+ (match-beginning 4))))) - (setq string (replace-match - (concat "\\1" (nth 2 (assoc (match-string 3 string) org-emphasis-alist)) - "\\4" (nth 3 (assoc (match-string 3 string) org-emphasis-alist)) - "\\5") t nil string)) + (setq s (match-beginning 0) + rpl + (concat + (match-string 1 string) + (nth 2 (assoc (match-string 3 string) org-emphasis-alist)) + (match-string 4 string) + (nth 3 (assoc (match-string 3 string) + org-emphasis-alist)) + (match-string 5 string)) + string (replace-match rpl t t string) + s (+ s (- (length rpl) 2))) (setq s (1+ s)))) string)) @@ -24514,7 +25680,7 @@ stacked delimiters is N. Escaping delimiters is not possible." When TITLE is nil, just close all open levels." (org-close-par-maybe) (let ((l org-level-max)) - (while (>= l (1+ level)) + (while (>= l level) (if (aref org-levels-open (1- l)) (progn (org-html-level-close l umax) @@ -24660,10 +25826,14 @@ When COMBINE is non nil, add the category to each line." ts (match-string 0) inc t hd (org-get-heading) - summary (org-entry-get nil "SUMMARY") - desc (or (org-entry-get nil "DESCRIPTION") - (org-get-cleaned-entry org-icalendar-include-body)) - location (org-entry-get nil "LOCATION") + summary (org-icalendar-cleanup-string + (org-entry-get nil "SUMMARY")) + desc (org-icalendar-cleanup-string + (or (org-entry-get nil "DESCRIPTION") + (and org-icalendar-include-body (org-get-entry))) + t org-icalendar-include-body) + location (org-icalendar-cleanup-string + (org-entry-get nil "LOCATION")) category (org-get-category)) (if (looking-at re2) (progn @@ -24751,10 +25921,14 @@ END:VEVENT\n" (not (member org-archive-tag (org-get-tags-at))) ) (setq hd (match-string 3) - summary (org-entry-get nil "SUMMARY") - desc (or (org-entry-get nil "DESCRIPTION") - (org-get-cleaned-entry org-icalendar-include-body)) - location (org-entry-get nil "LOCATION")) + summary (org-icalendar-cleanup-string + (org-entry-get nil "SUMMARY")) + desc (org-icalendar-cleanup-string + (or (org-entry-get nil "DESCRIPTION") + (and org-icalendar-include-body (org-get-entry))) + t org-icalendar-include-body) + location (org-icalendar-cleanup-string + (org-entry-get nil "LOCATION"))) (if (string-match org-bracket-link-regexp hd) (setq hd (replace-match (if (match-end 3) (match-string 3 hd) (match-string 1 hd)) @@ -24783,24 +25957,38 @@ END:VTODO\n" (concat "\nDESCRIPTION: " desc) "") category pri status))))))))) -(defun org-get-cleaned-entry (what) - "Clean-up description string." - (when what - (save-excursion - (org-back-to-heading t) - (let ((s (buffer-substring (point-at-bol 2) (org-end-of-subtree t))) - (re (concat org-drawer-regexp "[^\000]*?:END:.*\n?")) +(defun org-icalendar-cleanup-string (s &optional is-body maxlength) + "Take out stuff and quote what needs to be quoted. +When IS-BODY is non-nil, assume that this is the body of an item, clean up +whitespace, newlines, drawers, and timestamps, and cut it down to MAXLENGTH +characters." + (if (not s) + nil + (when is-body + (let ((re (concat "\\(" org-drawer-regexp "\\)[^\000]*?:END:.*\n?")) (re2 (concat "^[ \t]*" org-keyword-time-regexp ".*\n?"))) (while (string-match re s) (setq s (replace-match "" t t s))) - (while (string-match re2 s) (setq s (replace-match "" t t s))) - (if (string-match "[ \t\r\n]+\\'" s) (setq s (replace-match "" t t s))) - (while (string-match "[ \t]*\n[ \t]*" s) - (setq s (replace-match "\\n" t t s))) - (setq s (org-trim s)) - (if (and (numberp what) - (> (length s) what)) - (substring s 0 what) - s))))) + (while (string-match re2 s) (setq s (replace-match "" t t s))))) + (let ((start 0)) + (while (string-match "\\([,;\\]\\)" s start) + (setq start (+ (match-beginning 0) 2) + s (replace-match "\\\\\\1" nil nil s)))) + (when is-body + (while (string-match "[ \t]*\n[ \t]*" s) + (setq s (replace-match "\\n" t t s)))) + (setq s (org-trim s)) + (if is-body + (if maxlength + (if (and (numberp maxlength) + (> (length s) maxlength)) + (setq s (substring s 0 maxlength))))) + s)) + +(defun org-get-entry () + "Clean-up description string." + (save-excursion + (org-back-to-heading t) + (buffer-substring (point-at-bol 2) (org-end-of-subtree t)))) (defun org-start-icalendar-file (name) "Start an iCalendar file by inserting the header." @@ -24856,8 +26044,8 @@ The XOXO buffer is named *xoxo-*" ;; Output everything as XOXO (with-current-buffer (get-buffer buffer) - (goto-char (point-min)) ;; CD: beginning-of-buffer is not allowed. - (let* ((opt-plist (org-combine-plists (org-default-export-plist) + (let* ((pos (point)) + (opt-plist (org-combine-plists (org-default-export-plist) (org-infile-export-plist))) (filename (concat (file-name-as-directory (org-export-directory :xoxo opt-plist)) @@ -24867,6 +26055,7 @@ The XOXO buffer is named *xoxo-*" (out (find-file-noselect filename)) (last-level 1) (hanging-li nil)) + (goto-char (point-min)) ;; CD: beginning-of-buffer is not allowed. ;; Check the output buffer is empty. (with-current-buffer out (erase-buffer)) ;; Kick off the output @@ -24919,6 +26108,7 @@ The XOXO buffer is named *xoxo-*" (org-export-as-xoxo-insert-into out "\n")) (org-export-as-xoxo-insert-into out "\n")) + (goto-char pos) ;; Finish the buffer off and clean it up. (switch-to-buffer-other-window out) (indent-region (point-min) (point-max) nil) @@ -25012,7 +26202,7 @@ The XOXO buffer is named *xoxo-*" (org-defkey org-mode-map "\C-c\C-d" 'org-deadline) (org-defkey org-mode-map "\C-c;" 'org-toggle-comment) (org-defkey org-mode-map "\C-c\C-v" 'org-show-todo-tree) -(org-defkey org-mode-map "\C-c\C-w" 'org-check-deadlines) +(org-defkey org-mode-map "\C-c\C-w" 'org-refile) (org-defkey org-mode-map "\C-c/" 'org-sparse-tree) ; Minor-mode reserved (org-defkey org-mode-map "\C-c\\" 'org-tags-sparse-tree) ; Minor-mode res. (org-defkey org-mode-map "\C-c\C-m" 'org-ctrl-c-ret) @@ -25035,12 +26225,15 @@ The XOXO buffer is named *xoxo-*" (org-defkey org-mode-map [(control ?\')] 'org-cycle-agenda-files) (org-defkey org-mode-map "\C-c[" 'org-agenda-file-to-front) (org-defkey org-mode-map "\C-c]" 'org-remove-file) +(org-defkey org-mode-map "\C-c\C-x<" 'org-agenda-set-restriction-lock) +(org-defkey org-mode-map "\C-c\C-x>" 'org-agenda-remove-restriction-lock) (org-defkey org-mode-map "\C-c-" 'org-ctrl-c-minus) (org-defkey org-mode-map "\C-c^" 'org-sort) (org-defkey org-mode-map "\C-c\C-c" 'org-ctrl-c-ctrl-c) (org-defkey org-mode-map "\C-c\C-k" 'org-kill-note-or-show-branches) (org-defkey org-mode-map "\C-c#" 'org-update-checkbox-count) (org-defkey org-mode-map "\C-m" 'org-return) +(org-defkey org-mode-map "\C-j" 'org-return-indent) (org-defkey org-mode-map "\C-c?" 'org-table-field-info) (org-defkey org-mode-map "\C-c " 'org-table-blank-field) (org-defkey org-mode-map "\C-c+" 'org-table-sum) @@ -25178,12 +26371,9 @@ because, in this case the deletion might narrow the column." (put 'org-delete-char 'flyspell-delayed t) (put 'org-delete-backward-char 'flyspell-delayed t) -(eval-after-load "pabbrev" - '(progn - (add-to-list 'pabbrev-expand-after-command-list - 'orgtbl-self-insert-command t) - (add-to-list 'pabbrev-expand-after-command-list - 'org-self-insert-command t))) +;; Make pabbrev-mode expand after org-mode commands +(put 'org-self-insert-command 'pabbrev-expand-after-command t) +(put 'orgybl-self-insert-command 'pabbrev-expand-after-command t) ;; How to do this: Measure non-white length of current string ;; If equal to column width, we should realign. @@ -25445,7 +26635,9 @@ This command does many different things, depending on context: links in this buffer. - If the cursor is on a numbered item in a plain list, renumber the - ordered list." + ordered list. + +- If the cursor is on a checkbox, toggle it." (interactive "P") (let ((org-enable-table-editor t)) (cond @@ -25510,18 +26702,24 @@ Also updates the keyword regular expressions." (let ((org-note-abort t)) (funcall org-finish-function)))) -(defun org-return () +(defun org-return (&optional indent) "Goto next table row or insert a newline. Calls `org-table-next-row' or `newline', depending on context. See the individual commands for more information." (interactive) (cond - ((bobp) (newline)) + ((bobp) (if indent (newline-and-indent) (newline))) ((org-at-table-p) (org-table-justify-field-maybe) (call-interactively 'org-table-next-row)) - (t (newline)))) + (t (if indent (newline-and-indent) (newline))))) +(defun org-return-indent () + (interactive) + "Goto next table row or insert a newline and indent. +Calls `org-table-next-row' or `newline-and-indent', depending on +context. See the individual commands for more information." + (org-return t)) (defun org-ctrl-c-minus () "Insert separator line in table or modify bullet type in list. @@ -25726,6 +26924,7 @@ See the individual commands for more information." :style toggle :selected org-log-done]) "--" ["Agenda Command..." org-agenda t] + ["Set Restriction Lock" org-agenda-set-restriction-lock t] ("File List for Agenda") ("Special views current file" ["TODO Tree" org-show-todo-tree t] @@ -25984,6 +27183,18 @@ really on, so that the block visually is on the match." (setq list (delete (pop elts) list))) list) +(defun org-back-over-empty-lines () + "Move backwards over witespace, to the beginning of the first empty line. +Returns the number o empty lines passed." + (let ((pos (point))) + (skip-chars-backward " \t\n\r") + (beginning-of-line 2) + (goto-char (min (point) pos)) + (count-lines (point) pos))) + +(defun org-skip-whitespace () + (skip-chars-forward " \t\n\r")) + (defun org-point-in-group (point group &optional context) "Check if POINT is in match-group GROUP. If CONTEXT is non-nil, return a list with CONTEXT and the boundaries of the @@ -26132,10 +27343,13 @@ not an indirect buffer" (setq column tcol) (goto-char pos) (beginning-of-line 1) - (looking-at "[ \t]*\\(\\S-+\\)[ \t]*") - (setq bullet (match-string 1) - btype (if (string-match "[0-9]" bullet) "n" bullet)) - (setq column (if (equal btype bullet-type) bcol tcol)))) + (if (looking-at "\\S-") + (progn + (looking-at "[ \t]*\\(\\S-+\\)[ \t]*") + (setq bullet (match-string 1) + btype (if (string-match "[0-9]" bullet) "n" bullet)) + (setq column (if (equal btype bullet-type) bcol tcol))) + (setq column (org-get-indentation))))) (t (setq column (org-get-indentation)))))) (goto-char pos) (if (<= (current-column) (current-indentation)) @@ -26144,7 +27358,7 @@ not an indirect buffer" (setq column (current-column)) (beginning-of-line 1) (if (looking-at - "\\([ \t]+\\)\\(:[0-9a-zA-Z]+:\\)[ \t]*\\(\\S-.*\\(\\S-\\|$\\)\\)") + "\\([ \t]+\\)\\(:[-_0-9a-zA-Z]+:\\)[ \t]*\\(\\S-.*\\(\\S-\\|$\\)\\)") (replace-match (concat "\\1" (format org-property-format (match-string 2) (match-string 3))) t nil)) @@ -26186,10 +27400,13 @@ not an indirect buffer" "Re-align a table, pass through to fill-paragraph if no table." (let ((table-p (org-at-table-p)) (table.el-p (org-at-table.el-p))) - (cond ((equal (char-after (point-at-bol)) ?*) t) ; skip headlines - (table.el-p t) ; skip table.el tables - (table-p (org-table-align) t) ; align org-mode tables - (t nil)))) ; call paragraph-fill + (cond ((and (equal (char-after (point-at-bol)) ?*) + (save-excursion (goto-char (point-at-bol)) + (looking-at outline-regexp))) + t) ; skip headlines + (table.el-p t) ; skip table.el tables + (table-p (org-table-align) t) ; align org-mode tables + (t nil)))) ; call paragraph-fill ;; For reference, this is the default value of adaptive-fill-regexp ;; "[ \t]*\\([-|#;>*]+[ \t]*\\|(?[0-9]+[.)][ \t]*\\)*" @@ -26321,6 +27538,20 @@ headline found, or nil if no higher level is found." (if (< level start-level) (throw 'exit level))) nil))) +(defun org-first-sibling-p () + "Is this heading the first child of its parents?" + (interactive) + (let ((re (concat "^" outline-regexp)) + level l) + (unless (org-at-heading-p t) + (error "Not at a heading")) + (setq level (funcall outline-level)) + (save-excursion + (if (not (re-search-backward re nil t)) + t + (setq l (funcall outline-level)) + (< l level))))) + (defun org-goto-sibling (&optional previous) "Goto the next sibling, even if it is invisible. When PREVIOUS is set, go to the previous sibling instead. Returns t @@ -26449,7 +27680,104 @@ Show the heading too, if it is currently invisible." (org-show-context 'isearch)) -;;;; Address problems with some other packages +;;;; Integration with and fixes for other packages + +;;; Imenu support + +(defvar org-imenu-markers nil + "All markers currently used by Imenu.") +(make-variable-buffer-local 'org-imenu-markers) + +(defun org-imenu-new-marker (&optional pos) + "Return a new marker for use by Imenu, and remember the marker." + (let ((m (make-marker))) + (move-marker m (or pos (point))) + (push m org-imenu-markers) + m)) + +(defun org-imenu-get-tree () + "Produce the index for Imenu." + (mapc (lambda (x) (move-marker x nil)) org-imenu-markers) + (setq org-imenu-markers nil) + (let* ((n org-imenu-depth) + (re (concat "^" outline-regexp)) + (subs (make-vector (1+ n) nil)) + (last-level 0) + m tree level head) + (save-excursion + (save-restriction + (widen) + (goto-char (point-max)) + (while (re-search-backward re nil t) + (setq level (org-reduced-level (funcall outline-level))) + (when (<= level n) + (looking-at org-complex-heading-regexp) + (setq head (org-match-string-no-properties 4) + m (org-imenu-new-marker)) + (org-add-props head nil 'org-imenu-marker m 'org-imenu t) + (if (>= level last-level) + (push (cons head m) (aref subs level)) + (push (cons head (aref subs (1+ level))) (aref subs level)) + (loop for i from (1+ level) to n do (aset subs i nil))) + (setq last-level level))))) + (aref subs 1))) + +(eval-after-load "imenu" + '(progn + (add-hook 'imenu-after-jump-hook + (lambda () (org-show-context 'org-goto))))) + +;; Speedbar support + +(defun org-speedbar-set-agenda-restriction () + "Restrict future agenda commands to the location at point in speedbar. +To get rid of the restriction, use \\[org-agenda-remove-restriction-lock]." + (interactive) + (let (p m tp np dir txt w) + (cond + ((setq p (text-property-any (point-at-bol) (point-at-eol) + 'org-imenu t)) + (setq m (get-text-property p 'org-imenu-marker)) + (save-excursion + (save-restriction + (set-buffer (marker-buffer m)) + (goto-char m) + (org-agenda-set-restriction-lock 'subtree)))) + ((setq p (text-property-any (point-at-bol) (point-at-eol) + 'speedbar-function 'speedbar-find-file)) + (setq tp (previous-single-property-change + (1+ p) 'speedbar-function) + np (next-single-property-change + tp 'speedbar-function) + dir (speedbar-line-directory) + txt (buffer-substring-no-properties (or tp (point-min)) + (or np (point-max)))) + (save-excursion + (save-restriction + (set-buffer (find-file-noselect + (let ((default-directory dir)) + (expand-file-name txt)))) + (unless (org-mode-p) + (error "Cannot restrict to non-Org-mode file")) + (org-agenda-set-restriction-lock 'file)))) + (t (error "Don't know how to restrict Org-mode's agenda"))) + (org-move-overlay org-speedbar-restriction-lock-overlay + (point-at-bol) (point-at-eol)) + (setq current-prefix-arg nil) + (org-agenda-maybe-redo))) + +(eval-after-load "speedbar" + '(progn + (speedbar-add-supported-extension ".org") + (define-key speedbar-file-key-map "<" 'org-speedbar-set-agenda-restriction) + (define-key speedbar-file-key-map "\C-c\C-x<" 'org-speedbar-set-agenda-restriction) + (define-key speedbar-file-key-map ">" 'org-agenda-remove-restriction-lock) + (define-key speedbar-file-key-map "\C-c\C-x>" 'org-agenda-remove-restriction-lock) + (add-hook 'speedbar-visiting-tag-hook + (lambda () (org-show-context 'org-goto))))) + + +;;; Fixes and Hacks ;; Make flyspell not check words in links, to not mess up our keymap (defun org-mode-flyspell-verify () @@ -26474,6 +27802,13 @@ Show the heading too, if it is currently invisible." (org-invisible-p))) (org-show-context 'bookmark-jump))) +;; Fix a bug in htmlize where there are text properties (face nil) +(eval-after-load "htmlize" + '(progn + (defadvice htmlize-faces-in-buffer (after org-no-nil-faces activate) + "Make sure there are no nil faces" + (setq ad-return-value (delq nil ad-return-value))))) + ;; Make session.el ignore our circular variable (eval-after-load "session" '(add-to-list 'session-globals-exclude 'org-mark-ring)) @@ -26482,7 +27817,7 @@ Show the heading too, if it is currently invisible." (defun org-closed-in-range () "Sparse tree of items closed in a certain time range. -Still experimental, may disappear in the furture." +Still experimental, may disappear in the future." (interactive) ;; Get the time interval from the user. (let* ((time1 (time-to-seconds @@ -26501,64 +27836,6 @@ Still experimental, may disappear in the furture." ;; make tree, check each match with the callback (org-occur "CLOSED: +\\[\\(.*?\\)\\]" nil callback))) -(defun org-fill-paragraph-experimental (&optional justify) - "Re-align a table, pass through to fill-paragraph if no table." - (let ((table-p (org-at-table-p)) - (table.el-p (org-at-table.el-p))) - (cond ((equal (char-after (point-at-bol)) ?*) t) ; skip headlines - (table.el-p t) ; skip table.el tables - (table-p (org-table-align) t) ; align org-mode tables - ((save-excursion - (let ((pos (1+ (point-at-eol)))) - (backward-paragraph 1) - (re-search-forward "\\\\\\\\[ \t]*$" pos t))) - (save-excursion - (save-restriction - (narrow-to-region (1+ (match-end 0)) (point-max)) - (fill-paragraph nil) - t))) - (t nil)))) ; call paragraph-fill - -;; FIXME: this needs a much better algorithm -(defun org-assign-fast-keys (alist) - "Assign fast keys to a keyword-key alist. -Respect keys that are already there." - (let (new e k c c1 c2 (char ?a)) - (while (setq e (pop alist)) - (cond - ((equal e '(:startgroup)) (push e new)) - ((equal e '(:endgroup)) (push e new)) - (t - (setq k (car e) c2 nil) - (if (cdr e) - (setq c (cdr e)) - ;; automatically assign a character. - (setq c1 (string-to-char - (downcase (substring - k (if (= (string-to-char k) ?@) 1 0))))) - (if (or (rassoc c1 new) (rassoc c1 alist)) - (while (or (rassoc char new) (rassoc char alist)) - (setq char (1+ char))) - (setq c2 c1)) - (setq c (or c2 char))) - (push (cons k c) new)))) - (nreverse new))) - -;(defcustom org-read-date-prefer-future nil -; "Non-nil means, when reading an incomplete date from the user, assume future. -;This affects the following situations: -;1. The user give a day, but no month. -; In this case, if the day number if after today, the current month will -; be used, otherwise the next month. -;2. The user gives a month but not a year. -; In this case, the the given month is after the current month, the current -; year will be used. Otherwise the next year will be used.; -; -;When nil, always the current month and year will be used." -; :group 'org-time ;???? -; :type 'boolean) - - ;;;; Finish up (provide 'org) @@ -26568,4 +27845,3 @@ Respect keys that are already there." ;; arch-tag: e77da1a7-acc7-4336-b19e-efa25af3f9fd ;;; org.el ends here - From 514a6ce6e40719e1a86f8d7698c4a5e55ff14707 Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Fri, 18 Jan 2008 15:11:17 +0000 Subject: [PATCH 188/439] (org-publish-current-project): Fix bug with forcing publication. --- lisp/textmodes/org-publish.el | 19 +++++++++---------- 1 file changed, 9 insertions(+), 10 deletions(-) diff --git a/lisp/textmodes/org-publish.el b/lisp/textmodes/org-publish.el index 66e0dd5d6fb..0a8e9019827 100644 --- a/lisp/textmodes/org-publish.el +++ b/lisp/textmodes/org-publish.el @@ -4,25 +4,25 @@ ;; Author: David O'Toole ;; Keywords: hypermedia, outlines -;; Version: 1.80a +;; Version: 1.80b -;; This file is free software; you can redistribute it and/or modify +;; This file is part of GNU Emacs. +;; +;; GNU Emacs is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by ;; the Free Software Foundation; either version 3, or (at your option) ;; any later version. -;; This file is distributed in the hope that it will be useful, +;; GNU Emacs is distributed in the hope that it will be useful, ;; but WITHOUT ANY WARRANTY; without even the implied warranty of ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the ;; GNU General Public License for more details. ;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to -;; the Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, ;; Boston, MA 02110-1301, USA. -;; This file is part of GNU Emacs. - ;;; Commentary: ;; Requires at least version 4.27 of org.el @@ -572,11 +572,10 @@ default is 'index.org'." With prefix argument, force publishing all files in project." (interactive "P") (save-window-excursion - (let* ((project-name (org-publish-get-project-from-filename (buffer-file-name))) - (org-publish-use-timestamps-flag (if force nil t))) + (let* ((project-name (org-publish-get-project-from-filename (buffer-file-name)))) (if (not project-name) (error "File %s is not part of any known project." (buffer-file-name))) - (org-publish project-name)))) + (org-publish project-name (if force nil t))))) ;;;###autoload From 36ad15539d7521ce6146d0569ceec94592a9d0ff Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Fri, 18 Jan 2008 15:14:45 +0000 Subject: [PATCH 189/439] New file --- lisp/ChangeLog | 29 +- lisp/textmodes/org-mouse.el | 1108 +++++++++++++++++++++++++++++++++++ 2 files changed, 1136 insertions(+), 1 deletion(-) create mode 100644 lisp/textmodes/org-mouse.el diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 76d75ab42d9..760d36d3c4c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,32 @@ -2008-01-18 Carsten Dominik +2008-01-18 Bastien Guerry + * textmodes/org-export-latex.el (org-export-latex-cleaned-string): + Fixed. + (org-export-latex-special-chars): Convert "..." in \ldots and skip + tables + (org-export-latex-fontify-headline): Changed parameter name + (org-export-as-latex): Handle export of subtrees + (org-export-latex-make-header): New argument TITLE + (org-export-latex-content): New argument EXCLUDE-LIST + (org-list-parse-list): New name for org-export-latex-parse-list + (org-export-latex-make-header): New name for + org-export-latex-make-preamble + (org-list-to-generic): New name of org-export-list-to-generic + (org-list-to-latex): New name of org-export-list-to-latex + (org-list-item-begin, org-list-end, org-list-insert-radio-list) + (org-list-send-list, org-list-to-texinfo) + (org-list-to-html): New functions + (org-export-latex-tables-column-borders) + (org-export-latex-default-class, org-export-latex-classes) + (org-export-latex-classes-sectioning) + (org-list-radio-list-templates): New options + (org-export-latex-header): New variable + (org-latex-entities): New constant + (org-export-latex-default-sectioning, org-export-latex-preamble) + (org-export-latex-prepare-text-option) + (org-export-latex-get-sectioning): Removed + +2008-01-18 Carsten Dominik * textmodes/org-publish.el (org-publish-current-project): Fix bug with forcing publication. diff --git a/lisp/textmodes/org-mouse.el b/lisp/textmodes/org-mouse.el new file mode 100644 index 00000000000..9d275c2d109 --- /dev/null +++ b/lisp/textmodes/org-mouse.el @@ -0,0 +1,1108 @@ +;;; org-mouse.el --- Better mouse support for org-mode + +;; Copyright (c) 2006 Piotr Zielinski, 2007, 2008 Free Software Foundation +;; +;; Author: Piotr Zielinski +;; Maintainer: Carsten Dominik +;; Version: 5.19 +;; +;; This file is part of GNU Emacs. +;; +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3, or (at your option) +;; any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;; +;;; Commentary: +;; +;; Org-mouse provides mouse support for org-mode. +;; +;; http://orgmode.org +;; +;; Org-mouse implements the following features: +;; * following links with the left mouse button (in Emacs 22) +;; * subtree expansion/collapse (org-cycle) with the left mouse button +;; * several context menus on the right mouse button: +;; + general text +;; + headlines +;; + timestamps +;; + priorities +;; + links +;; + tags +;; * promoting/demoting/moving subtrees with mouse-3 +;; + if the drag starts and ends in the same line then promote/demote +;; + otherwise move the subtree +;; +;; Use +;; --- +;; +;; To use this package, put the following line in your .emacs: +;; +;; (require 'org-mouse) +;; + +;; Fixme: +;; + deal with folding / unfolding issues + +;; TODO (This list is only theoretical, if you'd like to have some +;; feature implemented or a bug fix please send me an email, even if +;; something similar appears in the list below. This will help me get +;; the priorities right.): +;; +;; + org-store-link, insert link +;; + org tables +;; + occur with the current word/tag (same menu item) +;; + ctrl-c ctrl-c, for example, renumber the current list +;; + internal links + +;; Please email the maintainer with new feature suggestions / bugs + +;; History: +;; +;; SInce version 5.10: Changes are listed in the general org-mode docs. +;; +;; Version 5.09 +;; + Version number synchronization with Org-mode. +;; +;; Version 0.25 +;; + made compatible with org-mode 4.70 (thanks to Carsten for the patch) +;; +;; Version 0.24 +;; + minor changes to the table menu +;; +;; Version 0.23 +;; + preliminary support for tables and calculation marks +;; + context menu support for org-agenda-undo & org-sort-entries +;; +;; Version 0.22 +;; + handles undo support for the agenda buffer (requires org-mode >=4.58) +;; +;; Version 0.21 +;; + selected text activates its context menu +;; + shift-middleclick or right-drag inserts the text from the clipboard in the form of a link +;; +;; Version 0.20 +;; + the new "TODO Status" submenu replaces the "Cycle TODO" menu item +;; + the TODO menu can now list occurrences of a specific TODO keyword +;; + #+STARTUP line is now recognized +;; +;; Version 0.19 +;; + added support for dragging URLs to the org-buffer +;; +;; Version 0.18 +;; + added support for agenda blocks +;; +;; Version 0.17 +;; + toggle checkboxes with a single click +;; +;; Version 0.16 +;; + added support for checkboxes +;; +;; Version 0.15 +;; + org-mode now works with the Agenda buffer as well +;; +;; Version 0.14 +;; + added a menu option that converts plain list items to outline items +;; +;; Version 0.13 +;; + "Insert Heading" now inserts a sibling heading if the point is +;; on "***" and a child heading otherwise +;; +;; Version 0.12 +;; + compatible with Emacs 21 +;; + custom agenda commands added to the main menu +;; + moving trees should now work between windows in the same frame +;; +;; Version 0.11 +;; + fixed org-mouse-at-link (thanks to Carsten) +;; + removed [follow-link] bindings +;; +;; Version 0.10 +;; + added a menu option to remove highlights +;; + compatible with org-mode 4.21 now +;; +;; Version 0.08: +;; + trees can be moved/promoted/demoted by dragging with the right +;; mouse button (mouse-3) +;; + small changes in the above function +;; +;; Versions 0.01 -- 0.07: (I don't remember) + +(eval-when-compile (require 'cl)) +(require 'org) + +(defvar org-mouse-plain-list-regexp "\\([ \t]*\\)\\([-+*]\\|[0-9]+[.)]\\) " + "Regular expression that matches a plain list.") +(defvar org-mouse-direct t + "Internal variable indicating whether the current action is direct. + +If t, then the current action has been invoked directly through the buffer +it is intended to operate on. If nil, then the action has been invoked +indirectly, for example, through the agenda buffer.") + +(defgroup org-mouse nil + "Mouse support for org-mode." + :tag "Org Mouse" + :group 'org) + +(defcustom org-mouse-punctuation ":" + "Punctuation used when inserting text by drag and drop." + :group 'org-mouse + :type 'string) + + +(defun org-mouse-re-search-line (regexp) + "Search the current line for a given regular expression." + (beginning-of-line) + (re-search-forward regexp (point-at-eol) t)) + +(defun org-mouse-end-headline () + "Go to the end of current headline (ignoring tags)." + (interactive) + (end-of-line) + (skip-chars-backward "\t ") + (when (looking-back ":[A-Za-z]+:") + (skip-chars-backward ":A-Za-z") + (skip-chars-backward "\t "))) + +(defvar org-mouse-context-menu-function nil + "Function to create the context menu. +The value of this variable is the function invoked by +`org-mouse-context-menu' as the context menu.") +(make-variable-buffer-local 'org-mouse-context-menu-function) + +(defun org-mouse-show-context-menu (event prefix) + "Invoke the context menu. + +If the value of `org-mouse-context-menu-function' is a function, then +this function is called. Otherwise, the current major mode menu is used." + (interactive "@e \nP") + (if (and (= (event-click-count event) 1) + (or (not mark-active) + (sit-for (/ double-click-time 1000.0)))) + (progn + (select-window (posn-window (event-start event))) + (when (not (org-mouse-mark-active)) + (goto-char (posn-point (event-start event))) + (when (not (eolp)) (save-excursion (run-hooks 'post-command-hook))) + (let ((redisplay-dont-pause t)) + (sit-for 0))) + (if (functionp org-mouse-context-menu-function) + (funcall org-mouse-context-menu-function event) + (mouse-major-mode-menu event prefix))) + (setq this-command 'mouse-save-then-kill) + (mouse-save-then-kill event))) + + +(defun org-mouse-line-position () + "Returns `:beginning' or `:middle' or `:end', depending on the point position. + +If the point is at the end of the line, return `:end'. +If the point is separated from the beginning of the line only by white +space and *'s (`org-mouse-bolp'), return `:beginning'. Otherwise, +return `:middle'." + (cond + ((eolp) :end) + ((org-mouse-bolp) :beginning) + (t :middle))) + +(defun org-mouse-empty-line () + "Return non-nil iff the line contains only white space." + (save-excursion (beginning-of-line) (looking-at "[ \t]*$"))) + +(defun org-mouse-next-heading () + "Go to the next heading. +If there is none, ensure that the point is at the beginning of an empty line." + (unless (outline-next-heading) + (beginning-of-line) + (unless (org-mouse-empty-line) + (end-of-line) + (newline)))) + +(defun org-mouse-insert-heading () + "Insert a new heading, as `org-insert-heading'. + +If the point is at the :beginning (`org-mouse-line-position') of the line, +insert the new heading before the current line. Otherwise, insert it +after the current heading." + (interactive) + (case (org-mouse-line-position) + (:beginning (beginning-of-line) + (org-insert-heading)) + (t (org-mouse-next-heading) + (org-insert-heading)))) + +(defun org-mouse-timestamp-today (&optional shift units) + "Change the timestamp into SHIFT UNITS in the future. + +For the acceptable UNITS, see `org-timestamp-change'." + (interactive) + (flet ((org-read-date (&rest rest) (current-time))) + (org-time-stamp nil)) + (when shift + (org-timestamp-change shift units))) + +(defun org-mouse-keyword-menu (keywords function &optional selected itemformat) + "A helper function. + +Returns a menu fragment consisting of KEYWORDS. When a keyword +is selected by the user, FUNCTION is called with the selected +keyword as the only argument. + +If SELECTED is nil, then all items are normal menu items. If +SELECTED is a function, then each item is a checkbox, which is +enabled for a given keyword iff (funcall SELECTED keyword) return +non-nil. If SELECTED is neither nil nor a function, then the +items are radio buttons. A radio button is enabled for the +keyword `equal' to SELECTED. + +ITEMFORMAT governs formatting of the elements of KEYWORDS. If it +is a function, it is invoked with the keyword as the only +argument. If it is a string, it is interpreted as the format +string to (format ITEMFORMAT keyword). If it is neither a string +nor a function, elements of KEYWORDS are used directly. " + (mapcar + `(lambda (keyword) + (vector (cond + ((functionp ,itemformat) (funcall ,itemformat keyword)) + ((stringp ,itemformat) (format ,itemformat keyword)) + (t keyword)) + (list 'funcall ,function keyword) + :style (cond + ((null ,selected) t) + ((functionp ,selected) 'toggle) + (t 'radio)) + :selected (if (functionp ,selected) + (and (funcall ,selected keyword) t) + (equal ,selected keyword)))) + keywords)) + +(defun org-mouse-remove-match-and-spaces () + "Remove the match, make just one space around the point." + (interactive) + (replace-match "") + (just-one-space)) + +(defvar rest) +(defun org-mouse-replace-match-and-surround (newtext &optional fixedcase + literal string subexp) + "The same as `replace-match', but surrounds the replacement with spaces." + (apply 'replace-match rest) + (save-excursion + (goto-char (match-beginning (or subexp 0))) + (just-one-space) + (goto-char (match-end (or subexp 0))) + (just-one-space))) + + +(defun org-mouse-keyword-replace-menu (keywords &optional group itemformat + nosurround) + "A helper function. + +Returns a menu fragment consisting of KEYWORDS. When a keyword +is selected, group GROUP of the current match is replaced by the +keyword. The method ensures that both ends of the replacement +are separated from the rest of the text in the buffer by +individual spaces (unless NOSURROND is non-nil). + +The final entry of the menu is always \"None\", which removes the +match. + +ITEMFORMAT governs formatting of the elements of KEYWORDS. If it +is a function, it is invoked with the keyword as the only +argument. If it is a string, it is interpreted as the format +string to (format ITEMFORMAT keyword). If it is neither a string +nor a function, elements of KEYWORDS are used directly. +" + (setq group (or group 0)) + (let ((replace (org-mouse-match-closure + (if nosurround 'replace-match + 'org-mouse-replace-match-and-surround)))) + (append + (org-mouse-keyword-menu + keywords + `(lambda (keyword) (funcall ,replace keyword t t nil ,group)) + (match-string group) + itemformat) + `(["None" org-mouse-remove-match-and-spaces + :style radio + :selected ,(not (member (match-string group) keywords))])))) + +(defun org-mouse-show-headlines () + "Change the visibility of the current org buffer to only show headlines." + (interactive) + (let ((this-command 'org-cycle) + (last-command 'org-cycle) + (org-cycle-global-status nil)) + (org-cycle '(4)) + (org-cycle '(4)))) + +(defun org-mouse-show-overview () + "Change visibility of current org buffer to first-level headlines only." + (interactive) + (let ((org-cycle-global-status nil)) + (org-cycle '(4)))) + +(defun org-mouse-set-priority (priority) + "Set the priority of the current headline to PRIORITY." + (flet ((read-char-exclusive () priority)) + (org-priority))) + +(defvar org-mouse-priority-regexp "\\[#\\([A-Z]\\)\\]" + "Regular expression matching the priority indicator. +Differs from `org-priority-regexp' in that it doesn't contain the +leading '.*?'.") + +(defun org-mouse-get-priority (&optional default) + "Return the priority of the current headline. +DEFAULT is returned if no priority is given in the headline." + (save-excursion + (if (org-mouse-re-search-line org-mouse-priority-regexp) + (match-string 1) + (when default (char-to-string org-default-priority))))) + +;; (defun org-mouse-at-link () +;; (and (eq (get-text-property (point) 'face) 'org-link) +;; (save-excursion +;; (goto-char (previous-single-property-change (point) 'face)) +;; (or (looking-at org-bracket-link-regexp) +;; (looking-at org-angle-link-re) +;; (looking-at org-plain-link-re))))) + + +(defun org-mouse-delete-timestamp () + "Deletes the current timestamp as well as the preceding keyword. +SCHEDULED: or DEADLINE: or ANYTHINGLIKETHIS:" + (when (or (org-at-date-range-p) (org-at-timestamp-p)) + (replace-match "") ; delete the timestamp + (skip-chars-backward " :A-Z") + (when (looking-at " *[A-Z][A-Z]+:") + (replace-match "")))) + +(defun org-mouse-looking-at (regexp skipchars &optional movechars) + (save-excursion + (let ((point (point))) + (if (looking-at regexp) t + (skip-chars-backward skipchars) + (forward-char (or movechars 0)) + (when (looking-at regexp) + (> (match-end 0) point)))))) + +(defun org-mouse-priority-list () + (loop for priority from ?A to org-lowest-priority + collect (char-to-string priority))) + +(defun org-mouse-tag-menu () ;todo + (append + (let ((tags (org-split-string (org-get-tags) ":"))) + (org-mouse-keyword-menu + (sort (mapcar 'car (org-get-buffer-tags)) 'string-lessp) + `(lambda (tag) + (org-mouse-set-tags + (sort (if (member tag (quote ,tags)) + (delete tag (quote ,tags)) + (cons tag (quote ,tags))) + 'string-lessp))) + `(lambda (tag) (member tag (quote ,tags))) + )) + '("--" + ["Align Tags Here" (org-set-tags nil t) t] + ["Align Tags in Buffer" (org-set-tags t t) t] + ["Set Tags ..." (org-set-tags) t]))) + + + +(defun org-mouse-set-tags (tags) + (save-excursion + ;; remove existing tags first + (beginning-of-line) + (when (org-mouse-re-search-line ":\\(\\([A-Za-z_]+:\\)+\\)") + (replace-match "")) + + ;; set new tags if any + (when tags + (end-of-line) + (insert " :" (mapconcat 'identity tags ":") ":") + (org-set-tags nil t)))) + +(defun org-mouse-insert-checkbox () + (interactive) + (and (org-at-item-p) + (goto-char (match-end 0)) + (unless (org-at-item-checkbox-p) + (delete-horizontal-space) + (insert " [ ] ")))) + +(defun org-mouse-agenda-type (type) + (case type + ('tags "Tags: ") + ('todo "TODO: ") + ('tags-tree "Tags tree: ") + ('todo-tree "TODO tree: ") + ('occur-tree "Occur tree: ") + (t "Agenda command ???"))) + + +(defun org-mouse-list-options-menu (alloptions &optional function) + (let ((options (save-match-data + (split-string (match-string-no-properties 1))))) + (print options) + (loop for name in alloptions + collect + (vector name + `(progn + (replace-match + (mapconcat 'identity + (sort (if (member ',name ',options) + (delete ',name ',options) + (cons ',name ',options)) + 'string-lessp) + " ") + nil nil nil 1) + (when (functionp ',function) (funcall ',function))) + :style 'toggle + :selected (and (member name options) t))))) + +(defun org-mouse-clip-text (text maxlength) + (if (> (length text) maxlength) + (concat (substring text 0 (- maxlength 3)) "...") + text)) + +(defun org-mouse-popup-global-menu () + (popup-menu + `("Main Menu" + ["Show Overview" org-mouse-show-overview t] + ["Show Headlines" org-mouse-show-headlines t] + ["Show All" show-all t] + ["Remove Highlights" org-remove-occur-highlights + :visible org-occur-highlights] + "--" + ["Check Deadlines" + (if (functionp 'org-check-deadlines-and-todos) + (org-check-deadlines-and-todos org-deadline-warning-days) + (org-check-deadlines org-deadline-warning-days)) t] + ["Check TODOs" org-show-todo-tree t] + ("Check Tags" + ,@(org-mouse-keyword-menu + (sort (mapcar 'car (org-get-buffer-tags)) 'string-lessp) + '(lambda (tag) (org-tags-sparse-tree nil tag))) + "--" + ["Custom Tag ..." org-tags-sparse-tree t]) + ["Check Phrase ..." org-occur] + "--" + ["Display Agenda" org-agenda-list t] + ["Display Timeline" org-timeline t] + ["Display TODO List" org-todo-list t] + ("Display Tags" + ,@(org-mouse-keyword-menu + (sort (mapcar 'car (org-get-buffer-tags)) 'string-lessp) + '(lambda (tag) (org-tags-view nil tag))) + "--" + ["Custom Tag ..." org-tags-view t]) + ["Display Calendar" org-goto-calendar t] + "--" + ,@(org-mouse-keyword-menu + (mapcar 'car org-agenda-custom-commands) + '(lambda (key) + (eval `(flet ((read-char-exclusive () (string-to-char ,key))) + (org-agenda nil)))) + nil + '(lambda (key) + (let ((entry (assoc key org-agenda-custom-commands))) + (org-mouse-clip-text + (cond + ((stringp (nth 1 entry)) (nth 1 entry)) + ((stringp (nth 2 entry)) + (concat (org-mouse-agenda-type (nth 1 entry)) + (nth 2 entry))) + (t "Agenda Command '%s'")) + 30)))) + "--" + ["Delete Blank Lines" delete-blank-lines + :visible (org-mouse-empty-line)] + ["Insert Checkbox" org-mouse-insert-checkbox + :visible (and (org-at-item-p) (not (org-at-item-checkbox-p)))] + ["Insert Checkboxes" + (org-mouse-for-each-item 'org-mouse-insert-checkbox) + :visible (and (org-at-item-p) (not (org-at-item-checkbox-p)))] + ["Plain List to Outline" org-mouse-transform-to-outline + :visible (org-at-item-p)]))) + + +(defun org-mouse-get-context (contextlist context) + (let ((contextdata (assq context contextlist))) + (when contextdata + (save-excursion + (goto-char (second contextdata)) + (re-search-forward ".*" (third contextdata)))))) + +(defun org-mouse-for-each-item (function) + (save-excursion + (ignore-errors + (while t (org-previous-item))) + (ignore-errors + (while t + (funcall function) + (org-next-item))))) + +(defun org-mouse-bolp () + "Returns true if there only spaces, tabs, and '*', between the beginning of line and the point" + (save-excursion + (skip-chars-backward " \t*") (bolp))) + +(defun org-mouse-insert-item (text) + (case (org-mouse-line-position) + (:beginning ; insert before + (beginning-of-line) + (looking-at "[ \t]*") + (open-line 1) + (indent-to (- (match-end 0) (match-beginning 0))) + (insert "+ ")) + + (:middle ; insert after + (end-of-line) + (newline t) + (indent-relative) + (insert "+ ")) + + (:end ; insert text here + (skip-chars-backward " \t") + (kill-region (point) (point-at-eol)) + (unless (looking-back org-mouse-punctuation) + (insert (concat org-mouse-punctuation " "))))) + + (insert text) + (beginning-of-line)) + +(defadvice dnd-insert-text (around org-mouse-dnd-insert-text activate) + (if (eq major-mode 'org-mode) + (org-mouse-insert-item text) + ad-do-it)) + +(defadvice dnd-open-file (around org-mouse-dnd-open-file activate) + (if (eq major-mode 'org-mode) + (org-mouse-insert-item uri) + ad-do-it)) + +(defun org-mouse-match-closure (function) + (let ((match (match-data t))) + `(lambda (&rest rest) + (save-match-data + (set-match-data ',match) + (apply ',function rest))))) + +(defun org-mouse-todo-keywords () + (if (boundp 'org-todo-keywords-1) org-todo-keywords-1 org-todo-keywords)) + +(defun org-mouse-match-todo-keyword () + (save-excursion + (org-back-to-heading) + (if (looking-at outline-regexp) (goto-char (match-end 0))) + (or (looking-at (concat " +" org-todo-regexp " *")) + (looking-at " \\( *\\)")))) + +(defun org-mouse-yank-link (click) + (interactive "e") + ;; Give temporary modes such as isearch a chance to turn off. + (run-hooks 'mouse-leave-buffer-hook) + (mouse-set-point click) + (setq mouse-selection-click-count 0) + (delete-horizontal-space) + (insert-for-yank (concat " [[" (current-kill 0) "]] "))) + +(defun org-mouse-context-menu (&optional event) + (let ((stamp-prefixes (list org-deadline-string org-scheduled-string)) + (contextlist (org-context))) + (flet ((get-context (context) (org-mouse-get-context contextlist context))) + (cond + ((org-mouse-mark-active) + (let ((region-string (buffer-substring (region-beginning) (region-end)))) + (popup-menu + `(nil + ["Sparse Tree" (org-occur ',region-string)] + ["Find in Buffer" (occur ',region-string)] + ["Grep in Current Dir" + (grep (format "grep -rnH -e '%s' *" ',region-string))] + ["Grep in Parent Dir" + (grep (format "grep -rnH -e '%s' ../*" ',region-string))] + "--" + ["Convert to Link" + (progn (save-excursion (goto-char (region-beginning)) (insert "[[")) + (save-excursion (goto-char (region-end)) (insert "]]")))] + ["Insert Link Here" (org-mouse-yank-link ',event)])))) + + ((save-excursion (beginning-of-line) (looking-at "#\\+STARTUP: \\(.*\\)")) + (popup-menu + `(nil + ,@(org-mouse-list-options-menu (mapcar 'car org-startup-options) + 'org-mode-restart)))) + ((or (eolp) + (and (looking-at "\\( \\|\t\\)\\(+:[0-9a-zA-Z_:]+\\)?\\( \\|\t\\)+$") + (looking-back " \\|\t"))) + (org-mouse-popup-global-menu)) + ((get-context :checkbox) + (popup-menu + '(nil + ["Toggle" org-toggle-checkbox t] + ["Remove" org-mouse-remove-match-and-spaces t] + "" + ["All Clear" (org-mouse-for-each-item + (lambda () + (when (save-excursion (org-at-item-checkbox-p)) + (replace-match "[ ]"))))] + ["All Set" (org-mouse-for-each-item + (lambda () + (when (save-excursion (org-at-item-checkbox-p)) + (replace-match "[X]"))))] + ["All Toggle" (org-mouse-for-each-item 'org-toggle-checkbox) t] + ["All Remove" (org-mouse-for-each-item + (lambda () + (when (save-excursion (org-at-item-checkbox-p)) + (org-mouse-remove-match-and-spaces))))] + ))) + ((and (org-mouse-looking-at "\\b\\w+" "a-zA-Z0-9_") + (member (match-string 0) (org-mouse-todo-keywords))) + (popup-menu + `(nil + ,@(org-mouse-keyword-replace-menu (org-mouse-todo-keywords)) + "--" + ["Check TODOs" org-show-todo-tree t] + ["List all TODO keywords" org-todo-list t] + [,(format "List only %s" (match-string 0)) + (org-todo-list (match-string 0)) t] + ))) + ((and (org-mouse-looking-at "\\b[A-Z]+:" "A-Z") + (member (match-string 0) stamp-prefixes)) + (popup-menu + `(nil + ,@(org-mouse-keyword-replace-menu stamp-prefixes) + "--" + ["Check Deadlines" org-check-deadlines t] + ))) + ((org-mouse-looking-at org-mouse-priority-regexp "[]A-Z#") ; priority + (popup-menu `(nil ,@(org-mouse-keyword-replace-menu + (org-mouse-priority-list) 1 "Priority %s" t)))) + ((get-context :link) + (popup-menu + '(nil + ["Open" org-open-at-point t] + ["Open in Emacs" (org-open-at-point t) t] + "--" + ["Copy link" (kill-new (match-string 0))] + ["Cut link" + (progn + (kill-region (match-beginning 0) (match-end 0)) + (just-one-space))] + "--" + ["Grep for TODOs" + (grep (format "grep -nH -i 'todo\\|fixme' %s*" (match-string 2)))] +; ["Paste file link" ((insert "file:") (yank))] + ))) + ((org-mouse-looking-at ":\\([A-Za-z0-9_]+\\):" "A-Za-z0-9_" -1) ;tags + (popup-menu + `(nil + [,(format "Display '%s'" (match-string 1)) + (org-tags-view nil ,(match-string 1))] + [,(format "Sparse Tree '%s'" (match-string 1)) + (org-tags-sparse-tree nil ,(match-string 1))] + "--" + ,@(org-mouse-tag-menu)))) + ((org-at-timestamp-p) + (popup-menu + '(nil + ["Show Day" org-open-at-point t] + ["Change Timestamp" org-time-stamp t] + ["Delete Timestamp" (org-mouse-delete-timestamp) t] + ["Compute Time Range" org-evaluate-time-range (org-at-date-range-p)] + "--" + ["Set for Today" org-mouse-timestamp-today] + ["Set for Tomorrow" (org-mouse-timestamp-today 1 'day)] + ["Set in 1 Week" (org-mouse-timestamp-today 7 'day)] + ["Set in 2 Weeks" (org-mouse-timestamp-today 14 'day)] + ["Set in a Month" (org-mouse-timestamp-today 1 'month)] + "--" + ["+ 1 Day" (org-timestamp-change 1 'day)] + ["+ 1 Week" (org-timestamp-change 7 'day)] + ["+ 1 Month" (org-timestamp-change 1 'month)] + "--" + ["- 1 Day" (org-timestamp-change -1 'day)] + ["- 1 Week" (org-timestamp-change -7 'day)] + ["- 1 Month" (org-timestamp-change -1 'month)]))) + ((get-context :table-special) + (let ((mdata (match-data))) + (incf (car mdata) 2) + (store-match-data mdata)) + (message "match: %S" (match-string 0)) + (popup-menu `(nil ,@(org-mouse-keyword-replace-menu + '(" " "!" "^" "_" "$" "#" "*" "'") 0 + (lambda (mark) + (case (string-to-char mark) + (? "( ) Nothing Special") + (?! "(!) Column Names") + (?^ "(^) Field Names Above") + (?_ "(^) Field Names Below") + (?$ "($) Formula Parameters") + (?# "(#) Recalculation: Auto") + (?* "(*) Recalculation: Manual") + (?' "(') Recalculation: None"))) t)))) + ((assq :table contextlist) + (popup-menu + '(nil + ["Align Table" org-ctrl-c-ctrl-c] + ["Blank Field" org-table-blank-field] + ["Edit Field" org-table-edit-field] + "--" + ("Column" + ["Move Column Left" org-metaleft] + ["Move Column Right" org-metaright] + ["Delete Column" org-shiftmetaleft] + ["Insert Column" org-shiftmetaright] + "--" + ["Enable Narrowing" (setq org-table-limit-column-width (not org-table-limit-column-width)) :selected org-table-limit-column-width :style toggle]) + ("Row" + ["Move Row Up" org-metaup] + ["Move Row Down" org-metadown] + ["Delete Row" org-shiftmetaup] + ["Insert Row" org-shiftmetadown] + ["Sort lines in region" org-table-sort-lines (org-at-table-p)] + "--" + ["Insert Hline" org-table-insert-hline]) + ("Rectangle" + ["Copy Rectangle" org-copy-special] + ["Cut Rectangle" org-cut-special] + ["Paste Rectangle" org-paste-special] + ["Fill Rectangle" org-table-wrap-region]) + "--" + ["Set Column Formula" org-table-eval-formula] + ["Set Field Formula" (org-table-eval-formula '(4))] + ["Edit Formulas" org-table-edit-formulas] + "--" + ["Recalculate Line" org-table-recalculate] + ["Recalculate All" (org-table-recalculate '(4))] + ["Iterate All" (org-table-recalculate '(16))] + "--" + ["Toggle Recalculate Mark" org-table-rotate-recalc-marks] + ["Sum Column/Rectangle" org-table-sum + :active (or (org-at-table-p) (org-region-active-p))] + ["Field Info" org-table-field-info] + ["Debug Formulas" + (setq org-table-formula-debug (not org-table-formula-debug)) + :style toggle :selected org-table-formula-debug] + ))) + ((and (assq :headline contextlist) (not (eolp))) + (let ((priority (org-mouse-get-priority t))) + (popup-menu + `("Headline Menu" + ("Tags and Priorities" + ,@(org-mouse-keyword-menu + (org-mouse-priority-list) + '(lambda (keyword) + (org-mouse-set-priority (string-to-char keyword))) + priority "Priority %s") + "--" + ,@(org-mouse-tag-menu)) + ("TODO Status" + ,@(progn (org-mouse-match-todo-keyword) + (org-mouse-keyword-replace-menu (org-mouse-todo-keywords) + 1))) + ["Show Tags" + (with-current-buffer org-mouse-main-buffer (org-agenda-show-tags)) + :visible (not org-mouse-direct)] + ["Show Priority" + (with-current-buffer org-mouse-main-buffer (org-agenda-show-priority)) + :visible (not org-mouse-direct)] + ,@(if org-mouse-direct '("--") nil) + ["New Heading" org-mouse-insert-heading :visible org-mouse-direct] + ["Set Deadline" + (progn (org-mouse-end-headline) (insert " ") (org-deadline)) + :active (not (save-excursion + (org-mouse-re-search-line org-deadline-regexp)))] + ["Schedule Task" + (progn (org-mouse-end-headline) (insert " ") (org-schedule)) + :active (not (save-excursion + (org-mouse-re-search-line org-scheduled-regexp)))] + ["Insert Timestamp" + (progn (org-mouse-end-headline) (insert " ") (org-time-stamp nil)) t] +; ["Timestamp (inactive)" org-time-stamp-inactive t] + "--" + ["Archive Subtree" org-archive-subtree] + ["Cut Subtree" org-cut-special] + ["Copy Subtree" org-copy-special] + ["Paste Subtree" org-paste-special :visible org-mouse-direct] + ("Sort Children" + ["Alphabetically" (org-sort-entries nil ?a)] + ["Numerically" (org-sort-entries nil ?n)] + ["By Time/Date" (org-sort-entries nil ?t)] + "--" + ["Reverse Alphabetically" (org-sort-entries nil ?A)] + ["Reverse Numerically" (org-sort-entries nil ?N)] + ["Reverse By Time/Date" (org-sort-entries nil ?T)]) + "--" + ["Move Trees" org-mouse-move-tree :active nil] + )))) + (t + (org-mouse-popup-global-menu)))))) + +;; (defun org-mouse-at-regexp (regexp) +;; (save-excursion +;; (let ((point (point)) +;; (bol (progn (beginning-of-line) (point))) +;; (eol (progn (end-of-line) (point)))) +;; (goto-char point) +;; (re-search-backward regexp bol 1) +;; (and (not (eolp)) +;; (progn (forward-char) +;; (re-search-forward regexp eol t)) +;; (<= (match-beginning 0) point))))) + +(defun org-mouse-mark-active () + (and mark-active transient-mark-mode)) + +(defun org-mouse-in-region-p (pos) + (and (org-mouse-mark-active) + (>= pos (region-beginning)) + (< pos (region-end)))) + +(defun org-mouse-down-mouse (event) + (interactive "e") + (setq this-command last-command) + (unless (and (= 1 (event-click-count event)) + (org-mouse-in-region-p (posn-point (event-start event)))) + (mouse-drag-region event))) + +(add-hook 'org-mode-hook + '(lambda () + (setq org-mouse-context-menu-function 'org-mouse-context-menu) + +; (define-key org-mouse-map [follow-link] 'mouse-face) + (define-key org-mouse-map (if (featurep 'xemacs) [button3] [mouse-3]) nil) + (define-key org-mode-map [mouse-3] 'org-mouse-show-context-menu) + (define-key org-mode-map [down-mouse-1] 'org-mouse-down-mouse) + (define-key org-mouse-map [C-drag-mouse-1] 'org-mouse-move-tree) + (define-key org-mouse-map [C-down-mouse-1] 'org-mouse-move-tree-start) + (define-key org-mode-map [S-mouse-2] 'org-mouse-yank-link) + (define-key org-mode-map [drag-mouse-3] 'org-mouse-yank-link) + (define-key org-mouse-map [drag-mouse-3] 'org-mouse-move-tree) + (define-key org-mouse-map [down-mouse-3] 'org-mouse-move-tree-start) + + (font-lock-add-keywords nil + `((,outline-regexp + 0 `(face org-link mouse-face highlight keymap ,org-mouse-map) + 'prepend) + ("^[ \t]*\\([-+*]\\|[0-9]+[.)]\\) +" + (1 `(face org-link keymap ,org-mouse-map mouse-face highlight) 'prepend)) + ("^[ \t]*\\([-+*]\\|[0-9]+[.)]\\) +\\(\\[[ X]\\]\\)" + (2 `(face bold keymap ,org-mouse-map mouse-face highlight) t))) + t) + + (defadvice org-open-at-point (around org-mouse-open-at-point activate) + (let ((context (org-context))) + (cond + ((assq :headline-stars context) (org-cycle)) + ((assq :checkbox context) (org-toggle-checkbox)) + ((assq :item-bullet context) + (let ((org-cycle-include-plain-lists t)) (org-cycle))) + (t ad-do-it)))))) + +(defun org-mouse-move-tree-start (event) + (interactive "e") + (message "Same line: promote/demote, (***):move before, (text): make a child")) + + +(defun org-mouse-make-marker (position) + (with-current-buffer (window-buffer (posn-window position)) + (copy-marker (posn-point position)))) + +(defun org-mouse-move-tree (event) + ;; todo: handle movements between different buffers + (interactive "e") + (save-excursion + (let* ((start (org-mouse-make-marker (event-start event))) + (end (org-mouse-make-marker (event-end event))) + (sbuf (marker-buffer start)) + (ebuf (marker-buffer end))) + + (when (and sbuf ebuf) + (set-buffer sbuf) + (goto-char start) + (org-back-to-heading) + (if (and (eq sbuf ebuf) + (equal + (point) + (save-excursion (goto-char end) (org-back-to-heading) (point)))) + ;; if the same line then promote/demote + (if (>= end start) (org-demote-subtree) (org-promote-subtree)) + ;; if different lines then move + (org-cut-subtree) + + (set-buffer ebuf) + (goto-char end) + (org-back-to-heading) + (when (and (eq sbuf ebuf) + (equal + (point) + (save-excursion (goto-char start) + (org-back-to-heading) (point)))) + (outline-end-of-subtree) + (end-of-line) + (if (eobp) (newline) (forward-char))) + + (when (looking-at outline-regexp) + (let ((level (- (match-end 0) (match-beginning 0)))) + (when (> end (match-end 0)) + (outline-end-of-subtree) + (end-of-line) + (if (eobp) (newline) (forward-char)) + (setq level (1+ level))) + (org-paste-subtree level) + (save-excursion + (outline-end-of-subtree) + (when (bolp) (delete-char -1)))))))))) + + +(defun org-mouse-transform-to-outline () + (interactive) + (org-back-to-heading) + (let ((minlevel 1000) + (replace-text (concat (match-string 0) "* "))) + (beginning-of-line 2) + (save-excursion + (while (not (or (eobp) (looking-at outline-regexp))) + (when (looking-at org-mouse-plain-list-regexp) + (setq minlevel (min minlevel (- (match-end 1) (match-beginning 1))))) + (forward-line))) + (while (not (or (eobp) (looking-at outline-regexp))) + (when (and (looking-at org-mouse-plain-list-regexp) + (eq minlevel (- (match-end 1) (match-beginning 1)))) + (replace-match replace-text)) + (forward-line)))) + +(defvar _cmd) ;dynamically scoped from `org-with-remote-undo'. + +(defun org-mouse-do-remotely (command) +; (org-agenda-check-no-diary) + (when (get-text-property (point) 'org-marker) + (let* ((anticol (- (point-at-eol) (point))) + (marker (get-text-property (point) 'org-marker)) + (buffer (marker-buffer marker)) + (pos (marker-position marker)) + (hdmarker (get-text-property (point) 'org-hd-marker)) + (buffer-read-only nil) + (newhead "--- removed ---") + (org-mouse-direct nil) + (org-mouse-main-buffer (current-buffer))) + (when (eq (with-current-buffer buffer major-mode) 'org-mode) + (let ((endmarker (save-excursion + (set-buffer buffer) + (outline-end-of-subtree) + (forward-char 1) + (copy-marker (point))))) + (org-with-remote-undo buffer + (with-current-buffer buffer + (widen) + (goto-char pos) + (org-show-hidden-entry) + (save-excursion + (and (outline-next-heading) + (org-flag-heading nil))) ; show the next heading + (org-back-to-heading) + (setq marker (copy-marker (point))) + (goto-char (max (point-at-bol) (- (point-at-eol) anticol))) + (funcall command) + (message "_cmd: %S" _cmd) + (message "this-command: %S" this-command) + (unless (eq (marker-position marker) (marker-position endmarker)) + (setq newhead (org-get-heading)))) + + (beginning-of-line 1) + (save-excursion + (org-agenda-change-all-lines newhead hdmarker 'fixface)))) + t)))) + +(defun org-mouse-agenda-context-menu (&optional event) + (or (org-mouse-do-remotely 'org-mouse-context-menu) + (popup-menu + '("Agenda" + ("Agenda Files") + "--" + ["Undo" (progn (message "last command: %S" last-command) (setq this-command 'org-agenda-undo) (org-agenda-undo)) + :visible (if (eq last-command 'org-agenda-undo) + org-agenda-pending-undo-list + org-agenda-undo-list)] + ["Rebuild Buffer" org-agenda-redo t] + ["New Diary Entry" + org-agenda-diary-entry (org-agenda-check-type nil 'agenda 'timeline) t] + "--" + ["Goto Today" org-agenda-goto-today + (org-agenda-check-type nil 'agenda 'timeline) t] + ["Display Calendar" org-agenda-goto-calendar + (org-agenda-check-type nil 'agenda 'timeline) t] + ("Calendar Commands" + ["Phases of the Moon" org-agenda-phases-of-moon + (org-agenda-check-type nil 'agenda 'timeline)] + ["Sunrise/Sunset" org-agenda-sunrise-sunset + (org-agenda-check-type nil 'agenda 'timeline)] + ["Holidays" org-agenda-holidays + (org-agenda-check-type nil 'agenda 'timeline)] + ["Convert" org-agenda-convert-date + (org-agenda-check-type nil 'agenda 'timeline)] + "--" + ["Create iCalendar file" org-export-icalendar-combine-agenda-files t]) + "--" + ["Day View" org-agenda-day-view + :active (org-agenda-check-type nil 'agenda) + :style radio :selected (equal org-agenda-ndays 1)] + ["Week View" org-agenda-week-view + :active (org-agenda-check-type nil 'agenda) + :style radio :selected (equal org-agenda-ndays 7)] + "--" + ["Show Logbook entries" org-agenda-log-mode + :style toggle :selected org-agenda-show-log + :active (org-agenda-check-type nil 'agenda 'timeline)] + ["Include Diary" org-agenda-toggle-diary + :style toggle :selected org-agenda-include-diary + :active (org-agenda-check-type nil 'agenda)] + ["Use Time Grid" org-agenda-toggle-time-grid + :style toggle :selected org-agenda-use-time-grid + :active (org-agenda-check-type nil 'agenda)] + ["Follow Mode" org-agenda-follow-mode + :style toggle :selected org-agenda-follow-mode] + "--" + ["Quit" org-agenda-quit t] + ["Exit and Release Buffers" org-agenda-exit t] + )))) + +(defun org-mouse-get-gesture (event) + (let ((startxy (posn-x-y (event-start event))) + (endxy (posn-x-y (event-end event)))) + (if (< (car startxy) (car endxy)) :right :left))) + + +; (setq org-agenda-mode-hook nil) +(add-hook 'org-agenda-mode-hook + '(lambda () + (setq org-mouse-context-menu-function 'org-mouse-agenda-context-menu) + (define-key org-agenda-keymap + (if (featurep 'xemacs) [button3] [mouse-3]) + 'org-mouse-show-context-menu) + (define-key org-agenda-keymap [down-mouse-3] 'org-mouse-move-tree-start) + (define-key org-agenda-keymap [C-mouse-4] 'org-agenda-earlier) + (define-key org-agenda-keymap [C-mouse-5] 'org-agenda-later) + (define-key org-agenda-keymap [drag-mouse-3] + '(lambda (event) (interactive "e") + (case (org-mouse-get-gesture event) + (:left (org-agenda-earlier 1)) + (:right (org-agenda-later 1))))))) + +(provide 'org-mouse) From 76ed5e0157c14cf9fcd075db08296bd692a43fc7 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Fri, 18 Jan 2008 15:15:07 +0000 Subject: [PATCH 190/439] * movemail.c: Remove references to XENIX. * m/intel386.h: Remove references to XENIX. --- lib-src/ChangeLog | 4 ++++ lib-src/movemail.c | 10 +++------- src/ChangeLog | 4 ++++ src/m/intel386.h | 23 ----------------------- 4 files changed, 11 insertions(+), 30 deletions(-) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index bb28500d68d..c0d0bbbf41b 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-18 Dan Nicolaescu + + * movemail.c: Remove references to XENIX. + 2008-01-13 Dan Nicolaescu * movemail.c: diff --git a/lib-src/movemail.c b/lib-src/movemail.c index daf8c6166e6..1f95735878d 100644 --- a/lib-src/movemail.c +++ b/lib-src/movemail.c @@ -113,7 +113,7 @@ Boston, MA 02110-1301, USA. */ #define R_OK 4 #endif -#if defined (XENIX) || defined (WINDOWSNT) +#ifdef WINDOWSNT #include #endif @@ -388,13 +388,13 @@ main (argc, argv) if (indesc < 0) pfatal_with_name (inname); -#if defined (BSD_SYSTEM) || defined (XENIX) +#ifdef BSD_SYSTEM /* In case movemail is setuid to root, make sure the user can read the output file. */ /* This is desirable for all systems but I don't want to assume all have the umask system call */ umask (umask (0) & 0333); -#endif /* BSD_SYSTEM || XENIX */ +#endif /* BSD_SYSTEM */ outdesc = open (outname, O_WRONLY | O_CREAT | O_EXCL, 0666); if (outdesc < 0) pfatal_with_name (outname); @@ -422,15 +422,11 @@ main (argc, argv) #ifdef MAIL_USE_LOCKF status = lockf (indesc, F_LOCK, 0); #else /* not MAIL_USE_LOCKF */ -#ifdef XENIX - status = locking (indesc, LK_RLCK, 0L); -#else #ifdef WINDOWSNT status = locking (indesc, LK_RLCK, -1L); #else status = flock (indesc, LOCK_EX); #endif -#endif #endif /* not MAIL_USE_LOCKF */ #endif /* MAIL_USE_SYSTEM_LOCK */ } diff --git a/src/ChangeLog b/src/ChangeLog index b641635484b..d63c039592a 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-18 Dan Nicolaescu + + * m/intel386.h: Remove references to XENIX. + 2008-01-17 Andreas Schwab * m/amdx86-64.h (START_FILES, LIB_STANDARD): Use HAVE_LIB64_DIR diff --git a/src/m/intel386.h b/src/m/intel386.h index 17969dd16e4..680a2cc106d 100644 --- a/src/m/intel386.h +++ b/src/m/intel386.h @@ -142,28 +142,6 @@ NOTE-END */ /* #define VIRT_ADDR_VARIES */ -#ifdef XENIX -/* Define NO_REMAP if memory segmentation makes it not work well - to change the boundary between the text section and data section - when Emacs is dumped. If you define this, the preloaded Lisp - code will not be sharable; but that's better than failing completely. */ - -#define NO_REMAP - -/* Since cannot purify, use standard Xenix 386 startup code. */ - -#define START_FILES /lib/386/Sseg.o pre-crt0.o /lib/386/Scrt0.o - -/* These really use terminfo. */ - -#define LIBS_TERMCAP /lib/386/Slibcurses.a \ - /lib/386/Slibtinfo.a /lib/386/Slibx.a - -/* Standard libraries for this machine. Since `-l' doesn't work in `ld'. */ -/* '__fltused' is unresolved w/o Slibcfp.a */ -#define LIB_STANDARD /lib/386/Slibcfp.a /lib/386/Slibc.a -#else /* not XENIX */ - /* this brings in alloca() if we're using cc */ #ifdef USG #ifndef LIB_STANDARD @@ -177,7 +155,6 @@ NOTE-END */ #define NO_REMAP #define TEXT_START 0 #endif /* USG */ -#endif /* not XENIX */ #ifdef USG5_4 #define DATA_SEG_BITS 0x08000000 From db9c3fb18e09517bea7c6f1872d661f579c3cd86 Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Fri, 18 Jan 2008 15:17:35 +0000 Subject: [PATCH 191/439] (org-export-latex-cleaned-string): Fixed. (org-export-latex-special-chars): Convert "..." in \ldots and skip tables (org-export-latex-fontify-headline): Changed parameter name (org-export-as-latex): Handle export of subtrees (org-export-latex-make-header): New argument TITLE (org-export-latex-content): New argument EXCLUDE-LIST (org-list-parse-list): New name for org-export-latex-parse-list (org-export-latex-make-header): New name for org-export-latex-make-preamble (org-list-to-generic): New name of org-export-list-to-generic (org-list-to-latex): New name of org-export-list-to-latex (org-list-item-begin, org-list-end, org-list-insert-radio-list) (org-list-send-list, org-list-to-texinfo) (org-list-to-html): New functions (org-export-latex-tables-column-borders) (org-export-latex-default-class, org-export-latex-classes) (org-export-latex-classes-sectioning) (org-list-radio-list-templates): New options (org-export-latex-header): New variable (org-latex-entities): New constant (org-export-latex-default-sectioning, org-export-latex-preamble) (org-export-latex-prepare-text-option) (org-export-latex-get-sectioning): Removed --- doc/misc/ChangeLog | 21 + lisp/textmodes/org-export-latex.el | 1301 ++++++++++++++++++---------- 2 files changed, 856 insertions(+), 466 deletions(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index d8c801a2054..b9c71b7e7b3 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,24 @@ +2008-01-18 Carsten Dominik + + * org.texi: (Property inheritance): New section + (Conventions): New section. + (Structure editing): Document C-RET, the prefix arg to the cut/cpy + commands, and the new bindings for refiling. + (Sparse trees): Document the new special command for sparse trees. + (References): Be more clear about the counting of hilines. + (Handling links): Document M-p/n for accessing links. + (Fast access to TODO states): New section. + (Per file keywords): New section. + (Property inheritance): New section. + (Column attributes): New summary types. + (Capturing Column View): New section. + (The date/time prompt): Cover the new features in the date/time prompt. + Compactify the table of keys for the calendar remote control. + (Clocking work time): Document the new :scope parameter. + (Remember): Promoted to chapter. + (Quoted examples): New section. + (Enhancing text): New verbatim environments. + 2008-01-14 Michael Albinus * trampver.texi: Update release number. diff --git a/lisp/textmodes/org-export-latex.el b/lisp/textmodes/org-export-latex.el index d320a166f2b..7624af8aa0e 100644 --- a/lisp/textmodes/org-export-latex.el +++ b/lisp/textmodes/org-export-latex.el @@ -1,10 +1,10 @@ - ;;; org-export-latex.el --- LaTeX exporter for org-mode +;;; org-export-latex.el --- LaTeX exporter for org-mode ;; -;; Copyright (C) 2007, 2008 Free Software Foundation, Inc. +;; Copyright (c) 2007, 2008 Free Software Foundation, Inc. ;; ;; Emacs Lisp Archive Entry ;; Filename: org-export-latex.el -;; Version: 5.12 +;; Version: 5.19 ;; Author: Bastien Guerry ;; Maintainer: Bastien Guerry ;; Keywords: org, wp, tex @@ -18,31 +18,31 @@ ;; Free Software Foundation; either version 3, or (at your option) any ;; later version. ;; -;; GNU Emacs is distributed in the hope that it will be useful, but WITHOUT -;; ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or -;; FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for -;; more details. +;; GNU Emacs is distributed in the hope that it will be useful, but +;; WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU +;; General Public License for more details. ;; -;; You should have received a copy of the GNU General Public License along -;; with GNU Emacs; see the file COPYING. If not, write to the Free Software -;; Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA -;; 02110-1301, USA. +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the Free +;; Software Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, +;; MA 02110-1301, USA. ;; ;;; Commentary: ;; ;; This library implements a LaTeX exporter for org-mode. -;; +;; ;; Put this file into your load-path and the following into your ~/.emacs: ;; (require 'org-export-latex) -;; +;; ;; The interactive functions are similar to those of the HTML exporter: -;; +;; ;; M-x `org-export-as-latex' ;; M-x `org-export-as-latex-batch' ;; M-x `org-export-as-latex-to-buffer' ;; M-x `org-export-region-as-latex' ;; M-x `org-replace-region-by-latex' -;; +;; ;;; Code: (eval-when-compile @@ -52,15 +52,19 @@ (require 'org) ;;; Variables: -(defvar org-latex-options-plist nil) -(defvar org-latex-todo-keywords-1 nil) -(defvar org-latex-all-targets-regexp nil) -(defvar org-latex-add-level 0) -(defvar org-latex-sectioning-depth 0) +(defvar org-export-latex-class nil) +(defvar org-export-latex-header nil) +(defvar org-export-latex-append-header nil) +(defvar org-export-latex-options-plist nil) +(defvar org-export-latex-todo-keywords-1 nil) +(defvar org-export-latex-all-targets-re nil) +(defvar org-export-latex-add-level 0) +(defvar org-export-latex-sectioning "") +(defvar org-export-latex-sectioning-depth 0) (defvar org-export-latex-list-beginning-re "^\\([ \t]*\\)\\([-+*]\\|[0-9]+[.)]\\) +?") -(defvar org-latex-special-string-regexps +(defvar org-export-latex-special-string-regexps '(org-ts-regexp org-scheduled-string org-deadline-string @@ -71,28 +75,82 @@ (defvar re-quote) ; dynamically scoped from org.el (defvar commentsp) ; dynamically scoped from org.el -;;; Custom variables: -(defcustom org-export-latex-sectioning-alist - '((1 "\\section{%s}" "\\section*{%s}") - (2 "\\subsection{%s}" "\\subsection*{%s}") - (3 "\\subsubsection{%s}" "\\subsubsection*{%s}") - (4 "\\paragraph{%s}" "\\paragraph*{%s}") - (5 "\\subparagraph{%s}" "\\subparagraph*{%s}")) - "Alist of LaTeX commands for inserting sections. -Here is the structure of each cell: +;;; User variables: - \(level unnumbered-section numbered-section\) - -The %s formatter will be replaced by the title of the section." +(defcustom org-export-latex-default-class "article" + "The default LaTeX class." :group 'org-export-latex - :type 'alist) + :type '(string :tag "LaTeX class")) + +(defcustom org-export-latex-classes + '(("article" + "\\documentclass[11pt,a4paper]{article} +\\usepackage[utf8]{inputenc} +\\usepackage[T1]{fontenc} +\\usepackage{hyperref}" + ("\\section{%s}" . "\\section*{%s}") + ("\\subsection{%s}" . "\\subsection*{%s}") + ("\\subsubsection{%s}" . "\\subsubsection*{%s}") + ("\\paragraph{%s}" . "\\paragraph*{%s}") + ("\\subparagraph{%s}" . "\\subparagraph*{%s}")) + ("report" + "\\documentclass[11pt,a4paper]{report} +\\usepackage[utf8]{inputenc} +\\usepackage[T1]{fontenc} +\\usepackage{hyperref}" + ("\\part{%s}" . "\\part*{%s}") + ("\\chapter{%s}" . "\\chapter*{%s}") + ("\\section{%s}" . "\\section*{%s}") + ("\\subsection{%s}" . "\\subsection*{%s}") + ("\\subsubsection{%s}" . "\\subsubsection*{%s}")) + ("book" + "\\documentclass[11pt,a4paper]{book} +\\usepackage[utf8]{inputenc} +\\usepackage[T1]{fontenc} +\\usepackage{hyperref}" + ("\\part{%s}" . "\\part*{%s}") + ("\\chapter{%s}" . "\\chapter*{%s}") + ("\\section{%s}" . "\\section*{%s}") + ("\\subsection{%s}" . "\\subsection*{%s}") + ("\\subsubsection{%s}" . "\\subsubsection*{%s}"))) + "Alist of LaTeX classes and associated header and structure. +If #+LaTeX_CLASS is set in the buffer, use its value and the +associated information. Here is the structure of each cell: + + \(class-name + header-string + (unnumbered-section numbered-section\) + ...\) + +A %s formatter is mandatory in each section string and will be +replaced by the title of the section." + :group 'org-export-latex + :type '(repeat + (list (string :tag "LaTeX class") + (string :tag "LaTeX header") + (cons :tag "Level 1" + (string :tag "Numbered") + (string :tag "Unnumbered")) + (cons :tag "Level 2" + (string :tag "Numbered") + (string :tag "Unnumbered")) + (cons :tag "Level 3" + (string :tag "Numbered") + (string :tag "Unnumbered")) + (cons :tag "Level 4" + (string :tag "Numbered") + (string :tag "Unnumbered")) + (cons :tag "Level 5" + (string :tag "Numbered") + (string :tag "Unnumbered"))))) (defcustom org-export-latex-emphasis-alist '(("*" "\\textbf{%s}" nil) ("/" "\\emph{%s}" nil) ("_" "\\underline{%s}" nil) ("+" "\\texttt{%s}" nil) - ("=" "\\texttt{%s}" nil)) + ("=" "\\texttt{%s}" nil) + ("~" "\\texttt{%s}" t)) "Alist of LaTeX expressions to convert emphasis fontifiers. Each element of the list is a list of three elements. The first element is the character used as a marker for fontification. @@ -102,15 +160,6 @@ conversions." :group 'org-export-latex :type 'alist) -(defcustom org-export-latex-preamble - "\\documentclass[11pt,a4paper]{article} -\\usepackage[utf8]{inputenc} -\\usepackage[T1]{fontenc} -\\usepackage{hyperref}" - "Preamble to be inserted at the very beginning of the LaTeX export." - :group 'org-export-latex - :type 'string) - (defcustom org-export-latex-title-command "\\maketitle" "The command used to insert the title just after \\begin{document}. If this string contains the formatting specification \"%s\" then @@ -119,7 +168,7 @@ argument." :group 'org-export-latex :type 'string) -(defcustom org-export-latex-date-format +(defcustom org-export-latex-date-format "%d %B %Y" "Format string for \\date{...}." :group 'org-export-latex @@ -130,14 +179,15 @@ argument." :group 'org-export-latex :type 'boolean) +(defcustom org-export-latex-tables-column-borders nil + "When non-nil, group of columns are surrounded with borders, +XSeven if these borders are the outside borders of the table." + :group 'org-export-latex + :type 'boolean) + (defcustom org-export-latex-packages-alist nil - "Alist of packages to be inserted in the preamble. -Each cell is of the forma \( option . package \). - -For example: - -\(setq org-export-latex-packages-alist - '((\"french\" \"babel\"))" + "Alist of packages to be inserted in the header. +Each cell is of the forma \( \"option\" . \"package\" \)." :group 'org-export-latex :type 'alist) @@ -167,17 +217,42 @@ Don't remove the keys, just change their values." (defcustom org-export-latex-image-default-option "width=10em" "Default option for images." :group 'org-export-latex - :type '(string)) + :type 'string) (defcustom org-export-latex-coding-system nil "Coding system for the exported LaTex file." :group 'org-export-latex :type 'coding-system) -;; FIXME Do we want this one? -;; (defun org-export-as-latex-and-open (arg) ...) +(defcustom org-list-radio-list-templates + '((latex-mode "% BEGIN RECEIVE ORGLST %n +% END RECEIVE ORGLST %n +\\begin{comment} +#+ORGLST: SEND %n org-list-to-latex +| | | +\\end{comment}\n") + (texinfo-mode "@c BEGIN RECEIVE ORGLST %n +@c END RECEIVE ORGLST %n +@ignore +#+ORGLST: SEND %n org-list-to-texinfo +| | | +@end ignore\n") + (html-mode " + +\n")) + "Templates for radio lists in different major modes. +All occurrences of %n in a template will be replaced with the name of the +list, obtained by prompting the user." + :group 'org-plain-lists + :type '(repeat + (list (symbol :tag "Major mode") + (string :tag "Format")))) ;;; Autoload functions: + ;;;###autoload (defun org-export-as-latex-batch () "Call `org-export-as-latex', may be used in batch processing as @@ -199,7 +274,7 @@ No file is created. The prefix ARG is passed through to `org-export-as-latex'." (defun org-replace-region-by-latex (beg end) "Replace the region from BEG to END with its LaTeX export. It assumes the region has `org-mode' syntax, and then convert it to -LaTeX. This can be used in any buffer. For example, you could +LaTeX. This can be used in any buffer. For example, you could write an itemized list in `org-mode' syntax in an LaTeX buffer and then use this command to convert it." (interactive "r") @@ -255,7 +330,21 @@ in a window. A non-interactive call will only retunr the buffer." ;;;###autoload (defun org-export-as-latex (arg &optional hidden ext-plist to-buffer body-only) - "Export current buffer to a LaTeX file." + "Export current buffer to a LaTeX file. +If there is an active region, export only the region. The prefix +ARG specifies how many levels of the outline should become +headlines. The default is 3. Lower levels will be exported +depending on `org-export-latex-low-levels'. The default is to +convert them as description lists. When HIDDEN is non-nil, don't +display the LaTeX buffer. EXT-PLIST is a property list with +external parameters overriding org-mode's default settings, but +still inferior to file-local settings. When TO-BUFFER is +non-nil, create a buffer with that name and export to that +buffer. If TO-BUFFER is the symbol `string', don't leave any +buffer behind but just return the resulting LaTeX as a string. +When BODY-ONLY is set, don't produce the file header and footer, +simply return the content of \begin{document}...\end{document}, +without even the \begin{document} and \end{document} commands." (interactive "P") ;; Make sure we have a file name when we need it. (when (and (not (or to-buffer body-only)) @@ -268,9 +357,23 @@ in a window. A non-interactive call will only retunr the buffer." (message "Exporting to LaTeX...") (org-update-radio-target-regexp) - (org-export-latex-set-initial-vars ext-plist) + (org-export-latex-set-initial-vars ext-plist arg) (let* ((wcf (current-window-configuration)) - (opt-plist org-latex-options-plist) + (opt-plist org-export-latex-options-plist) + (region-p (org-region-active-p)) + (subtree-p + (when region-p + (save-excursion + (goto-char (region-beginning)) + (and (org-at-heading-p) + (>= (org-end-of-subtree t t) (region-end)))))) + (title (or (and subtree-p (org-export-get-title-from-subtree)) + (plist-get opt-plist :title) + (and (not + (plist-get opt-plist :skip-before-1st-heading)) + (org-export-grab-title-from-buffer)) + (file-name-sans-extension + (file-name-nondirectory buffer-file-name)))) (filename (concat (file-name-as-directory (org-export-directory :LaTeX ext-plist)) (file-name-sans-extension @@ -286,10 +389,11 @@ in a window. A non-interactive call will only retunr the buffer." "*Org LaTeX Export*")) (t (get-buffer-create to-buffer))) (find-file-noselect filename))) - (region-p (org-region-active-p)) (odd org-odd-levels-only) - (preamble (org-export-latex-make-preamble opt-plist)) - (skip (plist-get opt-plist :skip-before-1st-heading)) + (header (org-export-latex-make-header title opt-plist)) + (skip (if subtree-p nil + ;; never skip first lines when exporting a subtree + (plist-get opt-plist :skip-before-1st-heading))) (text (plist-get opt-plist :text)) (first-lines (if skip "" (org-export-latex-first-lines))) (coding-system (and (boundp 'buffer-file-coding-system) @@ -310,19 +414,21 @@ in a window. A non-interactive call will only retunr the buffer." :skip-before-1st-heading skip :LaTeX-fragments nil))) - (set-buffer buffer) + (set-buffer buffer) (erase-buffer) (and (fboundp 'set-buffer-file-coding-system) (set-buffer-file-coding-system coding-system-for-write)) - ;; insert the preamble and initial document commands + ;; insert the header and initial document commands (unless (or (eq to-buffer 'string) body-only) - (insert preamble)) + (insert header)) ;; insert text found in #+TEXT (when (and text (not (eq to-buffer 'string))) - (insert (org-export-latex-content text) "\n\n")) + (insert (org-export-latex-content + text '(lists tables fixed-width keywords)) + "\n\n")) ;; insert lines before the first headline (unless (or skip (eq to-buffer 'string)) @@ -342,7 +448,7 @@ in a window. A non-interactive call will only retunr the buffer." (when (re-search-forward "^\\(\\*+\\) " nil t) (let* ((asters (length (match-string 1))) (level (if odd (- asters 2) (- asters 1)))) - (setq org-latex-add-level + (setq org-export-latex-add-level (if odd (1- (/ (1+ asters) 2)) (1- asters))) (org-export-latex-parse-global level odd))))) @@ -358,16 +464,16 @@ in a window. A non-interactive call will only retunr the buffer." (current-buffer)) (set-window-configuration wcf)))) - ;;; Parsing functions: + (defun org-export-latex-parse-global (level odd) "Parse the current buffer recursively, starting at LEVEL. If ODD is non-nil, assume the buffer only contains odd sections. -Return A list reflecting the document structure." +Return a list reflecting the document structure." (save-excursion (goto-char (point-min)) (let* ((cnt 0) output - (depth org-latex-sectioning-depth)) + (depth org-export-latex-sectioning-depth)) (while (re-search-forward (concat "^\\(\\(?:\\*\\)\\{" (number-to-string (+ (if odd 2 1) level)) @@ -404,57 +510,11 @@ Return A list reflecting the document structure." `(occur . ,cnt) `(heading . ,heading) `(content . ,(org-export-latex-parse-content)) - `(subcontent . ,(org-export-latex-parse-subcontent + `(subcontent . ,(org-export-latex-parse-subcontent level odd))))))) (widen))) (list output)))) -(defun org-export-latex-parse-list (&optional delete) - "Parse the list at point. -Return a list containing first level items as strings and -sublevels as list of strings." - (let ((start (point)) - ;; Find the end of the list - (end (save-excursion - (catch 'exit - (while (or (looking-at org-export-latex-list-beginning-re) - (looking-at "^[ \t]+\\|^$")) - (if (eq (point) (point-max)) - (throw 'exit (point-max))) - (forward-line 1))) (point))) - output itemsep) - (while (re-search-forward org-export-latex-list-beginning-re end t) - (setq itemsep (if (save-match-data - (string-match "^[0-9]" (match-string 2))) - "[0-9]+\\(?:\\.\\|)\\)" "[-+]")) - (let* ((indent1 (match-string 1)) - (nextitem (save-excursion - (save-match-data - (or (and (re-search-forward - (concat "^" indent1 itemsep " *?") end t) - (match-beginning 0)) end)))) - (item (buffer-substring - (point) - (or (and (re-search-forward - org-export-latex-list-beginning-re end t) - (goto-char (match-beginning 0))) - (goto-char end)))) - (nextindent (match-string 1)) - (item (org-trim item)) - (item (if (string-match "^\\[.+\\]" item) - (replace-match "\\\\texttt{\\&}" - t nil item) item))) - (push item output) - (when (> (length nextindent) - (length indent1)) - (narrow-to-region (point) nextitem) - (push (org-export-latex-parse-list) output) - (widen)))) - (when delete (delete-region start end)) - (setq output (nreverse output)) - (push (if (string-match "^\\[0" itemsep) - 'ordered 'unordered) output))) - (defun org-export-latex-parse-content () "Extract the content of a section." (let ((beg (point)) @@ -487,7 +547,7 @@ CONTENT is an element of the list produced by "Export the list SUBCONTENT to LaTeX. SUBCONTENT is an alist containing information about the headline and its content." - (let ((num (plist-get org-latex-options-plist :section-numbers))) + (let ((num (plist-get org-export-latex-options-plist :section-numbers))) (mapc (lambda(x) (org-export-latex-subcontent x num)) subcontent))) (defun org-export-latex-subcontent (subcontent num) @@ -495,20 +555,20 @@ and its content." (let ((heading (org-export-latex-fontify-headline (cdr (assoc 'heading subcontent)))) (level (- (cdr (assoc 'level subcontent)) - org-latex-add-level)) + org-export-latex-add-level)) (occur (number-to-string (cdr (assoc 'occur subcontent)))) (content (cdr (assoc 'content subcontent))) (subcontent (cadr (assoc 'subcontent subcontent)))) - (cond + (cond ;; Normal conversion - ((<= level org-latex-sectioning-depth) - (let ((sec (assoc level org-export-latex-sectioning-alist))) - (insert (format (if num (cadr sec) (caddr sec)) heading) "\n")) + ((<= level org-export-latex-sectioning-depth) + (let ((sec (nth (1- level) org-export-latex-sectioning))) + (insert (format (if num (car sec) (cdr sec)) heading) "\n")) (insert (org-export-latex-content content)) (cond ((stringp subcontent) (insert subcontent)) ((listp subcontent) (org-export-latex-sub subcontent)))) ;; At a level under the hl option: we can drop this subsection - ((> level org-latex-sectioning-depth) + ((> level org-export-latex-sectioning-depth) (cond ((eq org-export-latex-low-levels 'description) (insert (format "\\begin{description}\n\n\\item[%s]\n\n" heading)) (insert (org-export-latex-content content)) @@ -521,52 +581,47 @@ and its content." (cond ((stringp subcontent) (insert subcontent)) ((listp subcontent) (org-export-latex-sub subcontent))))))))) - ;;; Exporting internals: -(defun org-export-latex-protect-string (string) - "Prevent further conversion for STRING by adding the -org-protect property." - (add-text-properties - 0 (length string) '(org-protected t) string) string) - -(defun org-export-latex-protect-char-in-string (char-list string) - "Add org-protected text-property to char from CHAR-LIST in STRING." - (with-temp-buffer - (save-match-data - (insert string) - (goto-char (point-min)) - (while (re-search-forward (regexp-opt char-list) nil t) - (add-text-properties (match-beginning 0) - (match-end 0) '(org-protected t))) - (buffer-string)))) - -(defun org-export-latex-set-initial-vars (ext-plist) +(defun org-export-latex-set-initial-vars (ext-plist level) "Store org local variables required for LaTeX export. -EXT-PLIST is an optional additional plist." - (setq org-latex-todo-keywords-1 org-todo-keywords-1 - org-latex-all-targets-regexp +EXT-PLIST is an optional additional plist. +LEVEL indicates the default depth for export." + (setq org-export-latex-todo-keywords-1 org-todo-keywords-1 + org-export-latex-all-targets-re (org-make-target-link-regexp (org-all-targets)) - org-latex-options-plist + org-export-latex-options-plist (org-combine-plists (org-default-export-plist) ext-plist (org-infile-export-plist)) - org-latex-sectioning-depth - (let ((hl-levels (plist-get org-latex-options-plist :headline-levels)) - (sec-depth (length org-export-latex-sectioning-alist))) - ;; Fall back on org-export-latex-sectioning-alist length if - ;; headline-levels goes beyond it - (if (> hl-levels sec-depth) sec-depth hl-levels)))) + org-export-latex-class + (save-excursion + (goto-char (point-min)) + (if (and (re-search-forward "^#\\+LaTeX_CLASS:[ \t]*\\([a-zA-Z]+\\)" nil t) + (assoc (match-string 1) org-export-latex-classes)) + (match-string 1) + org-export-latex-default-class)) + org-export-latex-header + (cadr (assoc org-export-latex-class org-export-latex-classes)) + org-export-latex-sectioning + (cddr (assoc org-export-latex-class org-export-latex-classes)) + org-export-latex-sectioning-depth + (or level + (let ((hl-levels + (plist-get org-export-latex-options-plist :headline-levels)) + (sec-depth (length org-export-latex-sectioning))) + (if (> hl-levels sec-depth) sec-depth hl-levels))))) -(defun org-export-latex-make-preamble (opt-plist) - "Make the LaTeX preamble and return it as a string. -Argument OPT-PLIST is the options plist for current buffer." - (let ((toc (plist-get opt-plist :table-of-contents))) - (concat +(defun org-export-latex-make-header (title opt-plist) + "Make the LaTeX header and return it as a string. +TITLE is the current title from the buffer or region. +OPT-PLIST is the options plist for current buffer." + (let ((toc (plist-get opt-plist :table-of-contents)) + (author (plist-get opt-plist :author))) + (concat (if (plist-get opt-plist :time-stamp-file) (format-time-string "% Created %Y-%m-%d %a %H:%M\n")) - - ;; insert LaTeX custom preamble - org-export-latex-preamble "\n" - + ;; insert LaTeX custom header + org-export-latex-header + "\n" ;; insert information on LaTeX packages (when org-export-latex-packages-alist (mapconcat (lambda(p) @@ -575,46 +630,34 @@ Argument OPT-PLIST is the options plist for current buffer." (format "\\usepackage[%s]{%s}" (car p) (cadr p)))) org-export-latex-packages-alist "\n")) - + ;; insert additional commands in the header + org-export-latex-append-header ;; insert the title - (format - "\\title{%s}\n" + (format + "\n\n\\title{%s}\n" ;; convert the title (org-export-latex-content - (or (plist-get opt-plist :title) - (and (not - (plist-get opt-plist :skip-before-1st-heading)) - (org-export-grab-title-from-buffer)) - (and buffer-file-name - (file-name-sans-extension - (file-name-nondirectory buffer-file-name))) - "UNTITLED"))) - + title '(lists tables fixed-width keywords))) ;; insert author info (if (plist-get opt-plist :author-info) - (format "\\author{%s}\n" - (or (plist-get opt-plist :author) user-full-name)) + (format "\\author{%s}\n" + (or author user-full-name)) (format "%%\\author{%s}\n" - (or (plist-get opt-plist :author) user-full-name))) - + (or author user-full-name))) ;; insert the date (format "\\date{%s}\n" - (format-time-string + (format-time-string (or (plist-get opt-plist :date) org-export-latex-date-format))) - ;; beginning of the document "\n\\begin{document}\n\n" - ;; insert the title command (if (string-match "%s" org-export-latex-title-command) - (format org-export-latex-title-command - (plist-get opt-plist :title)) + (format org-export-latex-title-command title) org-export-latex-title-command) "\n\n" - ;; table of contents - (when (and org-export-with-toc + (when (and org-export-with-toc (plist-get opt-plist :section-numbers)) (cond ((numberp toc) (format "\\setcounter{tocdepth}{%s}\n\\tableofcontents\n\n" @@ -628,8 +671,9 @@ COMMENTS is either nil to replace them with the empty string or a formatting string like %%%%s if we want to comment them out." (save-excursion (goto-char (point-min)) + (if (org-at-heading-p) (beginning-of-line 2)) (let* ((pt (point)) - (end (if (and (re-search-forward "^\\*" nil t) + (end (if (and (re-search-forward "^\\* " nil t) (not (eq pt (match-beginning 0)))) (goto-char (match-beginning 0)) (goto-char (point-max))))) @@ -643,10 +687,58 @@ formatting string like %%%%s if we want to comment them out." :skip-before-1st-heading nil :LaTeX-fragments nil))))) +(defun org-export-latex-content (content &optional exclude-list) + "Convert CONTENT string to LaTeX. +Don't perform conversions that are in EXCLUDE-LIST. Recognized +conversion types are: quotation-marks, emphasis, sub-superscript, +links, keywords, lists, tables, fixed-width" + (with-temp-buffer + (insert content) + (unless (memq 'quotation-marks exclude-list) + (org-export-latex-quotation-marks)) + (unless (memq 'emphasis exclude-list) + (when (plist-get org-export-latex-options-plist :emphasize) + (org-export-latex-fontify))) + (unless (memq 'sub-superscript exclude-list) + (org-export-latex-special-chars + (plist-get org-export-latex-options-plist :sub-superscript))) + (unless (memq 'links exclude-list) + (org-export-latex-links)) + (unless (memq 'keywords exclude-list) + (org-export-latex-keywords + (plist-get org-export-latex-options-plist :timestamps))) + (unless (memq 'lists exclude-list) + (org-export-latex-lists)) + (unless (memq 'tables exclude-list) + (org-export-latex-tables + (plist-get org-export-latex-options-plist :tables))) + (unless (memq 'fixed-width exclude-list) + (org-export-latex-fixed-width + (plist-get org-export-latex-options-plist :fixed-width))) + ;; return string + (buffer-substring (point-min) (point-max)))) + +(defun org-export-latex-protect-string (s) + "Prevent further conversion for string S by adding the +org-protect property." + (add-text-properties 0 (length s) '(org-protected t) s) s) + +(defun org-export-latex-protect-char-in-string (char-list string) + "Add org-protected text-property to char from CHAR-LIST in STRING." + (with-temp-buffer + (save-match-data + (insert string) + (goto-char (point-min)) + (while (re-search-forward (regexp-opt char-list) nil t) + (add-text-properties (match-beginning 0) + (match-end 0) '(org-protected t))) + (buffer-string)))) + (defun org-export-latex-keywords-maybe (remove-list) "Maybe remove keywords depending on rules in REMOVE-LIST." (goto-char (point-min)) - (let ((re-todo (mapconcat 'identity org-latex-todo-keywords-1 "\\|"))) + (let ((re-todo (mapconcat 'identity org-export-latex-todo-keywords-1 "\\|")) + (case-fold-search nil)) ;; convert TODO keywords (when (re-search-forward (concat "^\\(" re-todo "\\)") nil t) (if (plist-get remove-list :todo) @@ -664,48 +756,25 @@ formatting string like %%%%s if we want to comment them out." (replace-match "") (replace-match (format "\\texttt{%s}" (match-string 0)) t t))))) -(defun org-export-latex-fontify-headline (headline) - "Fontify special words in a HEADLINE." +(defun org-export-latex-fontify-headline (string) + "Fontify special words in string." (with-temp-buffer ;; FIXME: org-inside-LaTeX-fragment-p doesn't work when the $...$ is at ;; the beginning of the buffer - inserting "\n" is safe here though. - (insert "\n" headline) + (insert "\n" string) (goto-char (point-min)) - (when (plist-get org-latex-options-plist :emphasize) + (when (plist-get org-export-latex-options-plist :emphasize) (org-export-latex-fontify)) (org-export-latex-special-chars - (plist-get org-latex-options-plist :sub-superscript)) + (plist-get org-export-latex-options-plist :sub-superscript)) (org-export-latex-keywords-maybe org-export-latex-remove-from-headlines) (org-export-latex-links) (org-trim (buffer-substring-no-properties (point-min) (point-max))))) -(defun org-export-latex-content (content) - "Convert CONTENT string to LaTeX." - (with-temp-buffer - (insert content) - (org-export-latex-quotation-marks) - (when (plist-get org-latex-options-plist :emphasize) - (org-export-latex-fontify)) - (org-export-latex-special-chars - (plist-get org-latex-options-plist :sub-superscript)) - (org-export-latex-links) - (org-export-latex-keywords - (plist-get org-latex-options-plist :timestamps)) - (org-export-latex-lists) - (org-export-latex-tables - (plist-get org-latex-options-plist :tables)) - (org-export-latex-fixed-width - (plist-get org-latex-options-plist :fixed-width)) - ;; return string - (buffer-substring (point-min) (point-max)))) - (defun org-export-latex-quotation-marks () - "Export question marks depending on language conventions. -Local definition of the language overrides -`org-export-latex-quotation-marks-convention' which overrides -`org-export-default-language'." - (let* ((lang (plist-get org-latex-options-plist :language)) + "Export question marks depending on language conventions." + (let* ((lang (plist-get org-export-latex-options-plist :language)) (quote-rpl (if (equal lang "fr") '(("\\(\\s-\\)\"" "«~") ("\\(\\S-\\)\"" "~»") @@ -720,21 +789,6 @@ Local definition of the language overrides (org-if-unprotected (replace-match rpl t t))))) quote-rpl))) -;; | chars/string in Org | normal environment | math environment | -;; |-----------------------+-----------------------+-----------------------| -;; | & # % $ | \& \# \% \$ | \& \# \% \$ | -;; | { } _ ^ \ | \{ \} \_ \^ \\ | { } _ ^ \ | -;; |-----------------------+-----------------------+-----------------------| -;; | a_b and a^b | $a_b$ and $a^b$ | a_b and a^b | -;; | a_abc and a_{abc} | $a_a$bc and $a_{abc}$ | a_abc and a_{abc} | -;; | \tau and \mu | $\tau$ and $\mu$ | \tau and \mu | -;; |-----------------------+-----------------------+-----------------------| -;; | \_ \^ | \_ \^ | \_ \^ | -;; | \(a=\mu\mbox{m}\) | \(a=\mu\mbox{m}\) | \(a=\mu\mbox{m}\) | -;; | \[\beta^2-a=0\] | \[\beta^2-a=0\] | \[\beta^2-a=0\] | -;; | $x=22\tau$ | $x=22\tau$ | $x=22\tau$ | -;; | $$\alpha=\sqrt{a^3}$$ | $$\alpha=\sqrt{a^3}$$ | $$\alpha=\sqrt{a^3}$$ | - (defun org-export-latex-special-chars (sub-superscript) "Export special characters to LaTeX. If SUB-SUPERSCRIPT is non-nil, convert \\ and ^. @@ -744,7 +798,8 @@ See the `org-export-latex.el' code for a complete conversion table." (goto-char (point-min)) (while (re-search-forward c nil t) ;; Put the point where to check for org-protected - (unless (get-text-property (match-beginning 2) 'org-protected) + (unless (or (get-text-property (match-beginning 2) 'org-protected) + (org-at-table-p)) (cond ((member (match-string 2) '("\\$" "$")) (if (equal (match-string 2) "\\$") (replace-match (concat (match-string 1) "$" @@ -756,11 +811,15 @@ See the `org-export-latex.el' code for a complete conversion table." (replace-match (match-string 2) t t) (replace-match (concat (match-string 1) "\\" (match-string 2)) t t))) + ((equal (match-string 2) "...") + (replace-match + (concat (match-string 1) + (org-export-latex-protect-string "\\ldots{}")) t t)) ((equal (match-string 2) "~") (cond ((equal (match-string 1) "\\") nil) ((eq 'org-link (get-text-property 0 'face (match-string 2))) (replace-match (concat (match-string 1) "\\~") t t)) - (t (replace-match + (t (replace-match (org-export-latex-protect-string (concat (match-string 1) "\\~{}")) t t)))) ((member (match-string 2) '("{" "}")) @@ -791,6 +850,7 @@ See the `org-export-latex.el' code for a complete conversion table." "\\(.\\|^\\)\\({\\)" "\\(.\\|^\\)\\(}\\)" "\\(.\\|^\\)\\(~\\)" + "\\(.\\|^\\)\\(\\.\\.\\.\\)" ;; (?\< . "\\textless{}") ;; (?\> . "\\textgreater{}") ))) @@ -812,7 +872,7 @@ Convert CHAR depending on STRING-BEFORE and STRING-AFTER." (cond ((eq 1 (length string-after)) (concat string-before char string-after)) ((string-match "[({]?\\([^)}]+\\)[)}]?" string-after) - (format "%s%s{%s}" string-before char + (format "%s%s{%s}" string-before char (match-string 1 string-after)))))) ((and subsup (> (length string-after) 1) @@ -842,7 +902,7 @@ The conversion is made depending of STRING-BEFORE and STRING-AFTER." (string-match "^[ \t\n]" string-after))) ;; backslash might escape a character (like \#) or a user TeX ;; macro (like \setcounter) - (org-export-latex-protect-string + (org-export-latex-protect-string (concat string-before "\\" string-after))) ((and (string-match "^[ \t\n]" string-after) (string-match "[ \t\n]\\'" string-before)) @@ -854,19 +914,18 @@ The conversion is made depending of STRING-BEFORE and STRING-AFTER." (defun org-export-latex-keywords (timestamps) "Convert special keywords to LaTeX. -Regexps are those from `org-latex-special-string-regexps'." - (let ((rg org-latex-special-string-regexps) r) +Regexps are those from `org-export-latex-special-string-regexps'." + (let ((rg org-export-latex-special-string-regexps) r) (while (setq r (pop rg)) (goto-char (point-min)) (while (re-search-forward (eval r) nil t) (if (not timestamps) (replace-match (format "\\\\texttt{%s}" (match-string 0)) t) (replace-match "")))))) - + (defun org-export-latex-fixed-width (opt) "When OPT is non-nil convert fixed-width sections to LaTeX." (goto-char (point-min)) - ;; FIXME the search shouldn't be performed on already converted text (while (re-search-forward "^[ \t]*:" nil t) (if opt (progn (goto-char (match-beginning 0)) @@ -882,17 +941,351 @@ Regexps are those from `org-latex-special-string-regexps'." (match-string 2)) t t) (forward-line)))))) +(defun org-export-latex-tables (insert) + "Convert tables to LaTeX and INSERT it." + (goto-char (point-min)) + (while (re-search-forward "^\\([ \t]*\\)|" nil t) + ;; FIXME really need to save-excursion? + (save-excursion (org-table-align)) + (let* ((beg (org-table-begin)) + (end (org-table-end)) + (raw-table (buffer-substring-no-properties beg end)) + fnum fields line lines olines gr colgropen line-fmt align) + (if org-export-latex-tables-verbatim + (let* ((tbl (concat "\\begin{verbatim}\n" raw-table + "\\end{verbatim}\n"))) + (apply 'delete-region (list beg end)) + (insert tbl)) + (progn + (setq lines (split-string raw-table "\n" t)) + (apply 'delete-region (list beg end)) + (when org-export-table-remove-special-lines + (setq lines (org-table-clean-before-export lines))) + ;; make a formatting string to reflect aligment + (setq olines lines) + (while (and (not line-fmt) (setq line (pop olines))) + (unless (string-match "^[ \t]*|-" line) + (setq fields (org-split-string line "[ \t]*|[ \t]*")) + (setq fnum (make-vector (length fields) 0)) + (setq line-fmt + (mapconcat + (lambda (x) + (setq gr (pop org-table-colgroup-info)) + (format "%s%%s%s" + (cond ((eq gr ':start) + (prog1 (if colgropen "|" "") + (setq colgropen t))) + ((eq gr ':startend) + (prog1 (if colgropen "|" "|") + (setq colgropen nil))) + (t "")) + (if (memq gr '(:end :startend)) + (progn (setq colgropen nil) "|") + ""))) + fnum "")))) + ;; fix double || in line-fmt + (setq line-fmt (replace-regexp-in-string "||" "|" line-fmt)) + ;; maybe remove the first and last "|" + (when (and (not org-export-latex-tables-column-borders) + (string-match "^\\(|\\)?\\(.+\\)|$" line-fmt)) + (setq line-fmt (match-string 2 line-fmt))) + ;; format alignment + (setq align (apply 'format + (cons line-fmt + (mapcar (lambda (x) (if x "r" "l")) + org-table-last-alignment)))) + ;; prepare the table to send to orgtbl-to-latex + (setq lines + (mapcar + (lambda(elem) + (or (and (string-match "[ \t]*|-+" elem) 'hline) + (split-string (org-trim elem) "|" t))) + lines)) + (when insert + (insert (orgtbl-to-latex + lines `(:tstart ,(concat "\\begin{tabular}{" align "}"))) + "\n\n"))))))) + +(defun org-export-latex-fontify () + "Convert fontification to LaTeX." + (goto-char (point-min)) + (while (re-search-forward org-emph-re nil t) + ;; The match goes one char after the *string* + (let ((emph (assoc (match-string 3) + org-export-latex-emphasis-alist)) + rpl) + (unless (get-text-property (1- (point)) 'org-protected) + (setq rpl (concat (match-string 1) + (format (org-export-latex-protect-char-in-string + '("\\" "{" "}") (cadr emph)) + (match-string 4)) + (match-string 5))) + (if (caddr emph) + (setq rpl (org-export-latex-protect-string rpl))) + (replace-match rpl t t))) + (backward-char))) + +(defun org-export-latex-links () + ;; Make sure to use the LaTeX hyperref and graphicx package + ;; or send some warnings. + "Convert links to LaTeX." + (goto-char (point-min)) + (while (re-search-forward org-bracket-link-analytic-regexp nil t) + (org-if-unprotected + (goto-char (match-beginning 0)) + (let* ((re-radio org-export-latex-all-targets-re) + (remove (list (match-beginning 0) (match-end 0))) + (type (match-string 2)) + (raw-path (match-string 3)) + (full-raw-path (concat (match-string 1) raw-path)) + (desc (match-string 5)) + imgp radiop + ;; define the path of the link + (path (cond + ((member type '("http" "https" "ftp")) + (concat type ":" raw-path)) + ((and re-radio (string-match re-radio raw-path)) + (setq radiop t)) + ((equal type "mailto") + (concat type ":" raw-path)) + ((equal type "file") + (if (and (or (org-file-image-p (expand-file-name raw-path)) + (string-match "\\.eps$" raw-path)) + (equal desc full-raw-path)) + (setq imgp t) + (progn (when (string-match "\\(.+\\)::.+" raw-path) + (setq raw-path (match-string 1 raw-path))) + (if (file-exists-p raw-path) + (concat type "://" (expand-file-name raw-path)) + (concat type "://" (org-export-directory + :LaTeX org-export-latex-options-plist) + raw-path)))))))) + ;; process with link inserting + (apply 'delete-region remove) + (cond ((and imgp (plist-get org-export-latex-options-plist :inline-images)) + (insert (format "\\includegraphics[%s]{%s}" + ;; image option should be set be a comment line + org-export-latex-image-default-option + (expand-file-name raw-path)))) + (radiop (insert (format "\\hyperref[%s]{%s}" raw-path desc))) + (path (insert (format "\\href{%s}{%s}" path desc))) + (t (insert "\\texttt{" desc "}"))))))) + +(defvar org-latex-entities) ; defined below + +(defun org-export-latex-cleaned-string () + "Clean stuff in the LaTeX export." + + ;; Preserve line breaks + (goto-char (point-min)) + (while (re-search-forward "\\\\\\\\" nil t) + (add-text-properties (match-beginning 0) (match-end 0) + '(org-protected t))) + + ;; Convert LaTeX to \LaTeX{} + (goto-char (point-min)) + (let ((case-fold-search nil) rpl) + (while (re-search-forward "\\([^+_]\\)LaTeX" nil t) + (replace-match (org-export-latex-protect-string + (concat (match-string 1) "\\LaTeX{}")) t t))) + + ;; Convert horizontal rules + (goto-char (point-min)) + (while (re-search-forward "^----+.$" nil t) + (replace-match (org-export-latex-protect-string "\\hrule") t t)) + + ;; Protect LaTeX commands like \commad[...]{...} or \command{...} + (goto-char (point-min)) + (while (re-search-forward "\\\\[a-zA-Z]+\\(?:\\[.*\\]\\)?{.*}" nil t) + (add-text-properties (match-beginning 0) (match-end 0) + '(org-protected t))) + + ;; Protect LaTeX entities + (goto-char (point-min)) + (while (re-search-forward (regexp-opt org-latex-entities) nil t) + (add-text-properties (match-beginning 0) (match-end 0) + '(org-protected t))) + + ;; Replace radio links + (goto-char (point-min)) + (while (re-search-forward + (concat "<<>>?\\((INVISIBLE)\\)?") nil t) + (replace-match + (org-export-latex-protect-string + (format "\\label{%s}%s"(match-string 1) + (if (match-string 2) "" (match-string 1)))) t t)) + + ;; Delete @<...> constructs + (goto-char (point-min)) + ;; Thanks to Daniel Clemente for this regexp + (while (re-search-forward "@<\\(?:[^\"\n]\\|\".*\"\\)*?>" nil t) + (replace-match "")) + + ;; When converting to LaTeX, replace footnotes + ;; FIXME: don't protect footnotes from conversion + (when (plist-get org-export-latex-options-plist :footnotes) + (goto-char (point-min)) + (while (re-search-forward "\\[[0-9]+\\]" nil t) + (when (save-match-data + (save-excursion (beginning-of-line) + (looking-at "[^:|#]"))) + (let ((foot-beg (match-beginning 0)) + (foot-end (match-end 0)) + (foot-prefix (match-string 0)) + footnote footnote-rpl) + (save-excursion + (when (search-forward foot-prefix nil t) + (replace-match "") + (let ((end (save-excursion + (if (re-search-forward "^$\\|^#.*$\\|\\[[0-9]+\\]" nil t) + (match-beginning 0) (point-max))))) + (setq footnote (concat (org-trim (buffer-substring (point) end)) + " ")) ; prevent last } being part of a link + (delete-region (point) end)) + (goto-char foot-beg) + (delete-region foot-beg foot-end) + (unless (null footnote) + (setq footnote-rpl (format "\\footnote{%s}" footnote)) + (add-text-properties 0 10 '(org-protected t) footnote-rpl) + (add-text-properties (1- (length footnote-rpl)) + (length footnote-rpl) + '(org-protected t) footnote-rpl) + (insert footnote-rpl))))))) + + ;; Replace footnote section tag for LaTeX + (goto-char (point-min)) + (while (re-search-forward + (concat "^" footnote-section-tag-regexp) nil t) + (replace-match "")))) + +;;; List handling: + (defun org-export-latex-lists () + "Replace plain text lists in current buffer into LaTeX lists." "Convert lists to LaTeX." (goto-char (point-min)) (while (re-search-forward org-export-latex-list-beginning-re nil t) (beginning-of-line) - (org-export-list-to-latex - (org-export-latex-parse-list t)))) + (insert (org-list-to-latex (org-list-parse-list t)) "\n"))) + +(defun org-list-parse-list (&optional delete) + "Parse the list at point. +Return a list containing first level items as strings and +sublevels as a list of strings." + (let ((start (org-list-item-begin)) + (end (org-list-end)) + output itemsep) + (while (re-search-forward org-export-latex-list-beginning-re end t) + (setq itemsep (if (save-match-data + (string-match "^[0-9]" (match-string 2))) + "[0-9]+\\(?:\\.\\|)\\)" "[-+]")) + (let* ((indent1 (match-string 1)) + (nextitem (save-excursion + (save-match-data + (or (and (re-search-forward + (concat "^" indent1 itemsep " *?") end t) + (match-beginning 0)) end)))) + (item (buffer-substring + (point) + (or (and (re-search-forward + org-export-latex-list-beginning-re end t) + (goto-char (match-beginning 0))) + (goto-char end)))) + (nextindent (match-string 1)) + (item (org-trim item)) + (item (if (string-match "^\\[.+\\]" item) + (replace-match "\\\\texttt{\\&}" + t nil item) item))) + (push item output) + (when (> (length nextindent) + (length indent1)) + (narrow-to-region (point) nextitem) + (push (org-list-parse-list) output) + (widen)))) + (when delete (delete-region start end)) + (setq output (nreverse output)) + (push (if (string-match "^\\[0" itemsep) + 'ordered 'unordered) output))) + +(defun org-list-item-begin () + "Find the beginning of the list item and return its position." + (save-excursion + (if (not (or (looking-at org-export-latex-list-beginning-re) + (re-search-backward + org-export-latex-list-beginning-re nil t))) + (progn (goto-char (point-min)) (point)) + (match-beginning 0)))) + +(defun org-list-end () + "Find the end of the list and return its position." + (save-excursion + (catch 'exit + (while (or (looking-at org-export-latex-list-beginning-re) + (looking-at "^[ \t]+\\|^$")) + (if (eq (point) (point-max)) + (throw 'exit (point-max))) + (forward-line 1))) (point))) + +(defun org-list-insert-radio-list () + "Insert a radio list template appropriate for this major mode." + (interactive) + (let* ((e (assq major-mode org-list-radio-list-templates)) + (txt (nth 1 e)) + name pos) + (unless e (error "No radio list setup defined for %s" major-mode)) + (setq name (read-string "List name: ")) + (while (string-match "%n" txt) + (setq txt (replace-match name t t txt))) + (or (bolp) (insert "\n")) + (setq pos (point)) + (insert txt) + (goto-char pos))) + +(defun org-list-send-list (&optional maybe) + "Send a tranformed version of this list to the receiver position. +With argument MAYBE, fail quietly if no transformation is defined for +this list." + (interactive) + (catch 'exit + (unless (org-at-item-p) (error "Not at a list")) + (save-excursion + (goto-char (org-list-item-begin)) + (beginning-of-line 0) + (unless (looking-at "#\\+ORGLST: *SEND +\\([a-zA-Z0-9_]+\\) +\\([^ \t\r\n]+\\)\\( +.*\\)?") + (if maybe + (throw 'exit nil) + (error "Don't know how to transform this list")))) + (let* ((name (match-string 1)) + beg + (transform (intern (match-string 2))) + (txt (buffer-substring-no-properties + (org-list-item-begin) + (org-list-end))) + (list (org-list-parse-list))) + (unless (fboundp transform) + (error "No such transformation function %s" transform)) + (setq txt (funcall transform list)) + ;; Find the insertion place + (save-excursion + (goto-char (point-min)) + (unless (re-search-forward + (concat "BEGIN RECEIVE ORGLST +" name "\\([ \t]\\|$\\)") nil t) + (error "Don't know where to insert translated list")) + (goto-char (match-beginning 0)) + (beginning-of-line 2) + (setq beg (point)) + (unless (re-search-forward (concat "END RECEIVE ORGLST +" name) nil t) + (error "Cannot find end of insertion region")) + (beginning-of-line 1) + (delete-region beg (point)) + (goto-char beg) + (insert txt "\n")) + (message "List converted and installed at receiver location")))) + +(defun org-list-to-generic (list params) + "Convert a LIST parsed through `org-list-parse-list' to other formats. -(defun org-export-list-to-generic (list params) - "Convert a LIST parsed through `org-export-latex-parse-list' to other formats. - Valid parameters are :ustart String to start an unordered list @@ -929,237 +1322,213 @@ Valid parameters are (cond ((symbolp sublist) nil) ((stringp sublist) (setq rtn (concat rtn istart sublist iend isep))) - (t + (t (setq rtn (concat rtn ;; previous list lsep ;; list separator - (org-export-list-to-generic sublist p) + (org-list-to-generic sublist p) lsep ;; list separator ))))) (format wrapper rtn)))) -(defun org-export-list-to-latex (list) +(defun org-list-to-latex (list) "Convert LIST into a LaTeX list." - (insert - (org-export-list-to-generic - list '(:splicep nil :ostart "\\begin{enumerate}" :oend "\\end{enumerate}" - :ustart "\\begin{itemize}" :uend "\\end{itemize}" - :istart "\\item " :iend "" - :isep "\n" :lsep "\n")) - ;; Add a trailing \n after list conversion - "\n")) + (org-list-to-generic + list '(:splicep nil :ostart "\\begin{enumerate}" :oend "\\end{enumerate}" + :ustart "\\begin{itemize}" :uend "\\end{itemize}" + :istart "\\item " :iend "" + :isep "\n" :lsep "\n"))) -;; FIXME Use org-export-highlight-first-table-line ? -(defun org-export-latex-tables (insert) - "Convert tables to LaTeX and INSERT it." - (goto-char (point-min)) - (while (re-search-forward "^\\([ \t]*\\)|" nil t) - ;; FIXME really need to save-excursion? - (save-excursion (org-table-align)) - (let* ((beg (org-table-begin)) - (end (org-table-end)) - (raw-table (buffer-substring-no-properties beg end)) - fnum fields line lines olines gr colgropen line-fmt align) - (if org-export-latex-tables-verbatim - (let* ((tbl (concat "\\begin{verbatim}\n" raw-table - "\\end{verbatim}\n"))) - (apply 'delete-region (list beg end)) - (insert tbl)) - (progn - (setq lines (split-string raw-table "\n" t)) - (apply 'delete-region (list beg end)) - (when org-export-table-remove-special-lines - (setq lines (org-table-clean-before-export lines))) - ;; make a formatting string to reflect aligment - (setq olines lines) - (while (and (not line-fmt) (setq line (pop olines))) - (unless (string-match "^[ \t]*|-" line) - (setq fields (org-split-string line "[ \t]*|[ \t]*")) - (setq fnum (make-vector (length fields) 0)) - (setq line-fmt - (mapconcat - (lambda (x) - (setq gr (pop org-table-colgroup-info)) - (format "%s%%s%s" - (cond ((eq gr ':start) - (prog1 (if colgropen "|" "") - (setq colgropen t))) - ((eq gr ':startend) - (prog1 (if colgropen "|" "|") - (setq colgropen nil))) - (t "")) - (if (memq gr '(:end :startend)) - (progn (setq colgropen nil) "|") - ""))) - fnum "")))) - ;; maybe remove the first and last "|" - (when (string-match "^\\(|\\)?\\(.+\\)|$" line-fmt) - (setq line-fmt (match-string 2 line-fmt))) - ;; format alignment - (setq align (apply 'format - (cons line-fmt - (mapcar (lambda (x) (if x "r" "l")) - org-table-last-alignment)))) - ;; prepare the table to send to orgtbl-to-latex - (setq lines - (mapcar - (lambda(elem) - (or (and (string-match "[ \t]*|-+" elem) 'hline) - (split-string (org-trim elem) "|" t))) - lines)) - (when insert - (insert (orgtbl-to-latex - lines `(:tstart ,(concat "\\begin{tabular}{" align "}"))) - "\n\n"))))))) +(defun org-list-to-html (list) + "Convert LIST into a HTML list." + (org-list-to-generic + list '(:splicep nil :ostart "

    " :oend "
" + :ustart "
    " :uend "
" + :istart "
  • " :iend "
  • " + :isep "\n" :lsep "\n"))) -(defun org-export-latex-fontify () - "Convert fontification to LaTeX." - (goto-char (point-min)) - (while (re-search-forward org-emph-re nil t) - ;; The match goes one char after the *string* - (let ((emph (assoc (match-string 3) - org-export-latex-emphasis-alist)) - rpl) - (unless (get-text-property (1- (point)) 'org-protected) - (setq rpl (concat (match-string 1) - (format (org-export-latex-protect-char-in-string - '("\\" "{" "}") (cadr emph)) - (match-string 4)) - (match-string 5))) - (if (caddr emph) - (setq rpl (org-export-latex-protect-string rpl))) - (replace-match rpl t t))) - (backward-char))) +(defun org-list-to-texinfo (list) + "Convert LIST into a Texinfo list." + (org-list-to-generic + list '(:splicep nil :ostart "@itemize @minus" :oend "@end itemize" + :ustart "@enumerate" :uend "@end enumerate" + :istart "@item\n" :iend "" + :isep "\n" :lsep "\n"))) -(defun org-export-latex-links () - ;; Make sure to use the LaTeX hyperref and graphicx package - ;; or send some warnings. - "Convert links to LaTeX." - (goto-char (point-min)) - (while (re-search-forward org-bracket-link-analytic-regexp nil t) - (org-if-unprotected - (goto-char (match-beginning 0)) - (let* ((re-radio org-latex-all-targets-regexp) - (remove (list (match-beginning 0) (match-end 0))) - (type (match-string 2)) - (raw-path (match-string 3)) - (full-raw-path (concat (match-string 1) raw-path)) - (desc (match-string 5)) - imgp radiop - ;; define the path of the link - (path (cond - ((member type '("http" "https" "ftp")) - (concat type ":" raw-path)) - ((and re-radio (string-match re-radio raw-path)) - (setq radiop t)) - ((equal type "mailto") - (concat type ":" raw-path)) - ((equal type "file") - (if (and (or (org-file-image-p (expand-file-name raw-path)) - (string-match "\\.eps$" raw-path)) - (equal desc full-raw-path)) - (setq imgp t) - (progn (when (string-match "\\(.+\\)::.+" raw-path) - (setq raw-path (match-string 1 raw-path))) - (if (file-exists-p raw-path) - (concat type "://" (expand-file-name raw-path)) - (concat type "://" (org-export-directory - :LaTeX org-latex-options-plist) - raw-path)))))))) - ;; process with link inserting - (apply 'delete-region remove) - (cond ((and imgp (plist-get org-latex-options-plist :inline-images)) - (insert (format "\\includegraphics[%s]{%s}" - ;; image option should be set be a comment line - org-export-latex-image-default-option - (expand-file-name raw-path)))) - ;; FIXME: what about caption? image properties? - (radiop (insert (format "\\hyperref[%s]{%s}" raw-path desc))) - (path (insert (format "\\href{%s}{%s}" path desc))) - (t (insert "\\texttt{" desc "}"))))))) - -(defun org-export-latex-cleaned-string (&optional commentsp) - ;; FIXME remove commentsp call in org.el and here - "Clean stuff in the LaTeX export." - - ;; Preserve line breaks - (goto-char (point-min)) - (while (re-search-forward "\\\\\\\\" nil t) - (add-text-properties (match-beginning 0) (match-end 0) - '(org-protected t))) - - ;; Convert LaTeX to \LaTeX{} - (goto-char (point-min)) - (let ((case-fold-search nil) rpl) - (while (re-search-forward "\\([^+_]\\)LaTeX" nil t) - (replace-match (org-export-latex-protect-string - (concat (match-string 1) "\\LaTeX{}")) t t))) - - ;; Convert horizontal rules - (goto-char (point-min)) - (while (re-search-forward "^----+.$" nil t) - (replace-match (org-export-latex-protect-string "\\hrule") t t)) - - ;; Protect LaTeX \commands{...} - (goto-char (point-min)) - (while (re-search-forward "\\\\[a-zA-Z]+\\(?:\\[.*\\]\\)?{.*}" nil t) - (add-text-properties (match-beginning 0) (match-end 0) - '(org-protected t))) - - ;; Replace radio links - (goto-char (point-min)) - (while (re-search-forward - (concat "<<>>?\\((INVISIBLE)\\)?") nil t) - (replace-match - (org-export-latex-protect-string - (format "\\label{%s}%s"(match-string 1) - (if (match-string 2) "" (match-string 1)))) t t)) - - ;; Delete @<...> constructs - (goto-char (point-min)) - ;; Thanks to Daniel Clemente for this regexp - (while (re-search-forward "@<\\(?:[^\"\n]\\|\".*\"\\)*?>" nil t) - (replace-match "")) - - ;; When converting to LaTeX, replace footnotes - ;; FIXME: don't protect footnotes from conversion - (when (plist-get org-latex-options-plist :footnotes) - (goto-char (point-min)) - (while (re-search-forward "\\[[0-9]+\\]" nil t) - (when (save-match-data - (save-excursion (beginning-of-line) - (looking-at "[^:|#]"))) - (let ((foot-beg (match-beginning 0)) - (foot-end (match-end 0)) - (foot-prefix (match-string 0)) - footnote footnote-rpl) - (when (and (re-search-forward (regexp-quote foot-prefix) nil t)) - (replace-match "") - (let ((end (save-excursion - (if (re-search-forward "^$\\|^#.*$\\|\\[[0-9]+\\]" nil t) - (match-beginning 0) (point-max))))) - (setq footnote - (concat - (org-trim (buffer-substring (point) end)) - ;; FIXME stupid workaround for cases where - ;; `org-bracket-link-analytic-regexp' matches - ;; }. as part of the link. - " ")) - (delete-region (point) end))) - (goto-char foot-beg) - (delete-region foot-beg foot-end) - (setq footnote-rpl (format "\\footnote{%s}" footnote)) - (add-text-properties 0 10 '(org-protected t) footnote-rpl) - (add-text-properties (1- (length footnote-rpl)) - (length footnote-rpl) - '(org-protected t) footnote-rpl) - (insert footnote-rpl)))) - - ;; Replace footnote section tag for LaTeX - (goto-char (point-min)) - (while (re-search-forward - (concat "^" footnote-section-tag-regexp) nil t) - (replace-match "")))) +(defconst org-latex-entities + '("\\!" + "\\'" + "\\+" + "\\," + "\\-" + "\\:" + "\\;" + "\\<" + "\\=" + "\\>" + "\\Huge" + "\\LARGE" + "\\Large" + "\\Styles" + "\\\\" + "\\`" + "\\addcontentsline" + "\\address" + "\\addtocontents" + "\\addtocounter" + "\\addtolength" + "\\addvspace" + "\\alph" + "\\appendix" + "\\arabic" + "\\author" + "\\begin{array}" + "\\begin{center}" + "\\begin{description}" + "\\begin{enumerate}" + "\\begin{eqnarray}" + "\\begin{equation}" + "\\begin{figure}" + "\\begin{flushleft}" + "\\begin{flushright}" + "\\begin{itemize}" + "\\begin{list}" + "\\begin{minipage}" + "\\begin{picture}" + "\\begin{quotation}" + "\\begin{quote}" + "\\begin{tabbing}" + "\\begin{table}" + "\\begin{tabular}" + "\\begin{thebibliography}" + "\\begin{theorem}" + "\\begin{titlepage}" + "\\begin{verbatim}" + "\\begin{verse}" + "\\bf" + "\\bf" + "\\bibitem" + "\\bigskip" + "\\cdots" + "\\centering" + "\\circle" + "\\cite" + "\\cleardoublepage" + "\\clearpage" + "\\cline" + "\\closing" + "\\dashbox" + "\\date" + "\\ddots" + "\\dotfill" + "\\em" + "\\fbox" + "\\flushbottom" + "\\fnsymbol" + "\\footnote" + "\\footnotemark" + "\\footnotesize" + "\\footnotetext" + "\\frac" + "\\frame" + "\\framebox" + "\\hfill" + "\\hline" + "\\hrulespace" + "\\hspace" + "\\huge" + "\\hyphenation" + "\\include" + "\\includeonly" + "\\indent" + "\\input" + "\\it" + "\\kill" + "\\label" + "\\large" + "\\ldots" + "\\line" + "\\linebreak" + "\\linethickness" + "\\listoffigures" + "\\listoftables" + "\\location" + "\\makebox" + "\\maketitle" + "\\mark" + "\\mbox" + "\\medskip" + "\\multicolumn" + "\\multiput" + "\\newcommand" + "\\newcounter" + "\\newenvironment" + "\\newfont" + "\\newlength" + "\\newline" + "\\newpage" + "\\newsavebox" + "\\newtheorem" + "\\nocite" + "\\nofiles" + "\\noindent" + "\\nolinebreak" + "\\nopagebreak" + "\\normalsize" + "\\onecolumn" + "\\opening" + "\\oval" + "\\overbrace" + "\\overline" + "\\pagebreak" + "\\pagenumbering" + "\\pageref" + "\\pagestyle" + "\\par" + "\\parbox" + "\\put" + "\\raggedbottom" + "\\raggedleft" + "\\raggedright" + "\\raisebox" + "\\ref" + "\\rm" + "\\roman" + "\\rule" + "\\savebox" + "\\sc" + "\\scriptsize" + "\\setcounter" + "\\setlength" + "\\settowidth" + "\\sf" + "\\shortstack" + "\\signature" + "\\sl" + "\\small" + "\\smallskip" + "\\sqrt" + "\\tableofcontents" + "\\telephone" + "\\thanks" + "\\thispagestyle" + "\\tiny" + "\\title" + "\\tt" + "\\twocolumn" + "\\typein" + "\\typeout" + "\\underbrace" + "\\underline" + "\\usebox" + "\\usecounter" + "\\value" + "\\vdots" + "\\vector" + "\\verb" + "\\vfill" + "\\vline" + "\\vspace") + "A list of LaTeX commands to be protected when performing conversion.") (provide 'org-export-latex) From dbc28aaa524182e9a4eee0d1696b893a41b0d22d Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Fri, 18 Jan 2008 15:20:31 +0000 Subject: [PATCH 192/439] (Property inheritance): New section (Conventions): New section. (Structure editing): Document C-RET, the prefix arg to the cut/cpy commands, and the new bindings for refiling. (Sparse trees): Document the new special command for sparse trees. (References): Be more clear about the counting of hilines. (Handling links): Document M-p/n for accessing links. (Fast access to TODO states): New section. (Per file keywords): New section. (Property inheritance): New section. (Column attributes): New summary types. (Capturing Column View): New section. (The date/time prompt): Cover the new features in the date/time prompt. Compactify the table of keys for the calendar remote control. (Clocking work time): Document the new :scope parameter. (Remember): Promoted to chapter. (Quoted examples): New section. (Enhancing text): New verbatim environments. --- doc/misc/org.texi | 2046 +++++++++++++++++++++++++------------- etc/ChangeLog | 4 + etc/refcards/orgcard.tex | 41 +- 3 files changed, 1382 insertions(+), 709 deletions(-) diff --git a/doc/misc/org.texi b/doc/misc/org.texi index cee6bf24cf0..3583009e3c2 100644 --- a/doc/misc/org.texi +++ b/doc/misc/org.texi @@ -3,8 +3,8 @@ @setfilename ../../info/org @settitle Org Mode Manual -@set VERSION 5.07 -@set DATE August 2007 +@set VERSION 5.19 +@set DATE January 2008 @dircategory Emacs @direntry @@ -12,11 +12,11 @@ @end direntry @c Version and Contact Info -@set MAINTAINERSITE @uref{http://www.astro.uva.nl/~dominik/Tools/org/,maintainers webpage} +@set MAINTAINERSITE @uref{http://orgmode.org,maintainers webpage} @set AUTHOR Carsten Dominik @set MAINTAINER Carsten Dominik -@set MAINTAINEREMAIL @email{dominik at science dot uva dot nl} -@set MAINTAINERCONTACT @uref{mailto:dominik at science dot uva dot nl,contact the maintainer} +@set MAINTAINEREMAIL @email{carsten at orgmode dot org} +@set MAINTAINERCONTACT @uref{mailto:carsten at orgmode dot org,contact the maintainer} @c %**end of header @finalout @@ -35,7 +35,7 @@ @copying This manual is for Org-mode (version @value{VERSION}). -Copyright @copyright{} 2004, 2005, 2006, 2007 Free Software Foundation +Copyright @copyright{} 2004, 2005, 2006, 2007, 2008 Free Software Foundation @quotation Permission is granted to copy, distribute and/or modify this document @@ -81,8 +81,9 @@ Software Foundation raise funds for GNU development.'' * Hyperlinks:: Notes in context * TODO items:: Every tree branch can be a TODO item * Tags:: Tagging headlines and matching sets of tags -* Properties and columns:: -* Timestamps:: Assign date and time to items +* Properties and columns:: Storing information about an entry +* Dates and times:: Making items useful for planning +* Remember:: Quickly adding nodes to the outline tree * Agenda views:: Collecting information into views * Embedded LaTeX:: LaTeX fragments and formulas * Exporting:: Sharing and publishing of notes @@ -90,7 +91,7 @@ Software Foundation raise funds for GNU development.'' * Miscellaneous:: All the rest which did not fit elsewhere * Extensions and Hacking:: It is possible to write add-on code * History and Acknowledgments:: How Org-mode came into being -* Index:: The fast road to specific information +* Main Index:: * Key Index:: Key bindings and where they are described @detailmenu @@ -102,6 +103,7 @@ Introduction * Installation:: How to install a downloaded version of Org-mode * Activation:: How to activate Org-mode for certain buffers. * Feedback:: Bug reports, ideas, patches etc. +* Conventions:: Type-setting conventions in the manual Document Structure @@ -150,22 +152,16 @@ Hyperlinks * Link abbreviations:: Shortcuts for writing complex links * Search options:: Linking to a specific location * Custom searches:: When the default search is not enough -* Remember:: Org-trees store quick notes Internal links * Radio targets:: Make targets trigger links in plain text. -Remember - -* Setting up remember:: Some code for .emacs to get things going -* Remember templates:: Define the outline of different note types -* Storing notes:: Directly get the note to where it belongs - TODO items * TODO basics:: Marking and displaying TODO entries * TODO extensions:: Workflow and assignments +* Progress logging:: Dates and notes for progress * Priorities:: Some things are more important than others * Breaking down tasks:: Splitting a task into manageable pieces * Checkboxes:: Tick-off lists @@ -173,9 +169,16 @@ TODO items Extended use of TODO keywords * Workflow states:: From TODO to DONE in steps -* TODO types:: I do this, Fred the rest +* TODO types:: I do this, Fred does the rest * Multiple sets in one file:: Mixing it all, and still finding your way -* Per file keywords:: Different files, different requirements +* Fast access to TODO states:: Single letter selection of a state +* Per-file keywords:: Different files, different requirements +* Faces for TODO keywords:: Highlighting states + +Progress Logging + +* Closing items:: When was this entry marked DONE? +* Tracking TODO state changes:: When did the status change? Tags @@ -188,6 +191,7 @@ Properties and Columns * Property syntax:: How properties are spelled out * Special properties:: Access to other Org-mode features * Property searches:: Matching property values +* Property inheritance:: Passing values down the tree * Column view:: Tabular viewing and editing * Property API:: Properties for Lisp programmers @@ -195,18 +199,19 @@ Column View * Defining columns:: The COLUMNS format property * Using column view:: How to create and use column view +* Capturing Column View:: A dynamic block for column view Defining Columns * Scope of column definitions:: Where defined, where valid? * Column attributes:: Appearance and content of a column -Timestamps +Dates and Times * Time stamps:: Assigning a time to a tree entry * Creating timestamps:: Commands which insert timestamps * Deadlines and scheduling:: Planning your work -* Progress logging:: Documenting when what work was done. +* Clocking work time:: Creating timestamps @@ -218,11 +223,12 @@ Deadlines and Scheduling * Inserting deadline/schedule:: Planning items * Repeated tasks:: Items that show up again and again -Progress Logging +Remember -* Closing items:: When was this entry marked DONE? -* Tracking TODO state changes:: When did the status change? -* Clocking work time:: When exactly did you work on this item? +* Setting up remember:: Some code for .emacs to get things going +* Remember templates:: Define the outline of different note types +* Storing notes:: Directly get the note to where it belongs +* Refiling notes:: Moving a note or task to a project Agenda Views @@ -284,12 +290,14 @@ LaTeX export * LaTeX export commands:: How to invoke LaTeX export * Quoting LaTeX code:: Incorporating literal LaTeX code +* Sectioning structure:: Text interpretation by the exporter * Comment lines:: Some lines will not be exported * Initial text:: Text before the first headline * Footnotes:: Numbers like [1] +* Quoted examples:: Inserting quoted chnuks of text * Enhancing text:: Subscripts, symbols and more * Export options:: How to influence the export settings @@ -339,11 +347,12 @@ Extensions, Hooks and Hacking * Special agenda views:: Customized views * Using the property API:: Writing programs that use entry properties -Tables in arbitrary syntax +Tables and Lists in arbitrary syntax * Radio tables:: Sending and receiving * A LaTeX example:: Step by step, almost a tutorial * Translator functions:: Copy and modify +* Radio lists:: Doing the same for lists. @end detailmenu @end menu @@ -357,6 +366,7 @@ Tables in arbitrary syntax * Installation:: How to install a downloaded version of Org-mode * Activation:: How to activate Org-mode for certain buffers. * Feedback:: Bug reports, ideas, patches etc. +* Conventions:: Type-setting conventions in the manual @end menu @node Summary, Installation, Introduction, Introduction @@ -377,7 +387,7 @@ agenda that utilizes and smoothly integrates much of the Emacs calendar and diary. Plain text URL-like links connect to websites, emails, Usenet messages, BBDB entries, and any files related to the projects. For printing and sharing of notes, an Org-mode file can be exported as a -structured ASCII file, as HTML, or (todo and agenda items only) as an +structured ASCII file, as HTML, or (TODO and agenda items only) as an iCalendar file. It can also serve as a publishing tool for a set of linked webpages. @@ -404,7 +414,7 @@ example as: @r{@bullet{} full agenda and planner with deadlines and work scheduling} @r{@bullet{} environment to implement David Allen's GTD system} @r{@bullet{} a basic database application} -@r{@bullet{} simple hypertext system, with HTML export} +@r{@bullet{} simple hypertext system, with HTML and LaTeX export} @r{@bullet{} publishing tool to create a set of interlinked webpages} @end example @@ -419,7 +429,7 @@ the minor Orgstruct-mode. There is a website for Org-mode which provides links to the newest version of Org-mode, as well as additional information, frequently asked questions (FAQ), links to tutorials etc. This page is located at -@uref{http://www.astro.uva.nl/~dominik/Tools/org/}. +@uref{http://orgmode.org}. @page @@ -524,7 +534,7 @@ MY PROJECTS -*- mode: org; -*- the file's name is. See also the variable @code{org-insert-mode-line-in-empty-file}. -@node Feedback, , Activation, Introduction +@node Feedback, Conventions, Activation, Introduction @section Feedback @cindex feedback @cindex bug reports @@ -581,6 +591,27 @@ screen. Save this buffer to a file (for example using @kbd{C-x C-w}) and attach it to your bug report. @end enumerate +@node Conventions, , Feedback, Introduction +@section Typesetting conventions used in this manual + +Org-mode uses three types of keywords: TODO keywords, tags, and property +names. In this manual we use the following conventions: + +@table @code +@item TODO +@itemx WAITING +TODO keywords are written with all capitals, even if they are +user-defined. +@item boss +@itemx ARCHIVE +User-defined tags are written in lowercase; built-in tags with special +meaning are written with all capitals. +@item Release +@itemx PRIORITY +User-defined properties are capitalized; built-in properties with +special meaning are written with all capitals. +@end table + @node Document structure, Tables, Introduction, Top @chapter Document Structure @cindex document structure @@ -708,8 +739,10 @@ Show all. @item C-c C-r Reveal context around point, showing the current entry, the following heading and the hierarchy above. Useful for working near a location -exposed by a sparse tree command (@pxref{Sparse trees}) or an agenda -command (@pxref{Agenda commands}). With prefix arg show, on each +that has been exposed by a sparse tree command (@pxref{Sparse trees}) or +an agenda command (@pxref{Agenda commands}). With prefix arg show, on +each + level, all sibling headings. @kindex C-c C-x b @item C-c C-x b @@ -806,6 +839,10 @@ the beginning of any other line, the content of that line is made the new heading. If the command is used at the end of a folded subtree (i.e. behind the ellipses at the end of a headline), then a headline like the current one will be inserted after the end of the subtree. +@kindex C-@key{RET} +@item C-@key{RET} +Insert a new heading after the current subtree, same level as the +current headline. This command works from anywhere in the entry. @kindex M-S-@key{RET} @item M-S-@key{RET} Insert new TODO entry with same level as current heading. @@ -833,22 +870,27 @@ Move subtree down (swap with next subtree of same level). @item C-c C-x C-w @itemx C-c C-x C-k Kill subtree, i.e. remove it from buffer but save in kill ring. +With prefix arg, kill N sequential subtrees. @kindex C-c C-x M-w @item C-c C-x M-w -Copy subtree to kill ring. +Copy subtree to kill ring. With prefix arg, copy N sequential subtrees. @kindex C-c C-x C-y @item C-c C-x C-y Yank subtree from kill ring. This does modify the level of the subtree to make sure the tree fits in nicely at the yank position. The yank level can also be specified with a prefix arg, or by yanking after a headline marker like @samp{****}. +@kindex C-c C-w +@item C-c C-w +Refile entry to a different location. @xref{Refiling notes}. @kindex C-c ^ @item C-c ^ Sort same-level entries. When there is an active region, all entries in the region will be sorted. Otherwise the children of the current headline are sorted. The command prompts for the sorting method, which can be alphabetically, numerically, by time (using the first time stamp -in each entry), by priority, and each of these in reverse order. With a +in each entry), by priority, and each of these in reverse order. You +can also supply your own function to extract the sorting key. With a @kbd{C-u} prefix, sorting will be case-sensitive. With two @kbd{C-u C-u} prefixes, duplicate entries will also be removed. @end table @@ -956,16 +998,22 @@ current file, with the name derived by appending @file{_archive} to the current file name. For information and examples on how to change this, see the documentation string of the variable @code{org-archive-location}. There is also an in-buffer option for -setting this variable, for example +setting this variable, for example@footnote{For backward compatibility, +the following also works: If there are several such lines in a file, +each specifies the archive location for the text below it. The first +such line also applies to any text before its definition. However, +using this method is @emph{strongly} deprecated as it is incompatible +with the outline structure of the document. The correct method for +setting multiple archive locations in a buffer is using a property.}: @example #+ARCHIVE: %s_done:: @end example @noindent -You may have several such lines in the buffer, they will then be valid -for the entries following the line (the first will also apply to any -text before it). +If you would like to have a special ARCHIVE location for a single entry +or a (sub)tree, give the entry an @code{:ARCHIVE:} property with the +location as the value (@pxref{Properties and columns}). @node Sparse trees, Plain lists, Archiving, Document structure @section Sparse trees @@ -975,21 +1023,23 @@ text before it). @cindex occur, command An important feature of Org-mode is the ability to construct -@emph{sparse trees} for selected information in an outline tree. A -sparse tree means that the entire document is folded as much as -possible, but the selected information is made visible along with the -headline structure above it@footnote{See also the variables -@code{org-show-hierarchy-above}, @code{org-show-following-heading}, and -@code{org-show-siblings} for detailed control on how much context is -shown around each match.}. Just try it out and you will see immediately -how it works. +@emph{sparse trees} for selected information in an outline tree, so that +the entire document is folded as much as possible, but the selected +information is made visible along with the headline structure above +it@footnote{See also the variables @code{org-show-hierarchy-above}, +@code{org-show-following-heading}, and @code{org-show-siblings} for +detailed control on how much context is shown around each match.}. Just +try it out and you will see immediately how it works. -Org-mode contains several commands creating such trees. The most -basic one is @command{org-occur}: +Org-mode contains several commands creating such trees, all these +commands can be accessed through a dispatcher: @table @kbd @kindex C-c / @item C-c / +This prompts for an extra key to select a sparse-tree creating command. +@kindex C-c / r +@item C-c / r Occur. Prompts for a regexp and shows a sparse tree with all matches. If the match is in a headline, the headline is made visible. If the match is in the body of an entry, headline and body are made visible. @@ -1000,6 +1050,7 @@ when the buffer is changed by an editing command, or by pressing @kbd{C-c C-c}. When called with a @kbd{C-u} prefix argument, previous highlights are kept, so several calls to this command can be stacked. @end table + @noindent For frequently used sparse trees of specific search strings, you can use the variable @code{org-agenda-custom-commands} to define fast @@ -1015,8 +1066,8 @@ For example: @noindent will define the key @kbd{C-c a f} as a shortcut for creating a sparse tree matching the string @samp{FIXME}. -Other commands use sparse trees as well. For example @kbd{C-c -C-v} creates a sparse TODO tree (@pxref{TODO basics}). +The other sparse tree commands select headings based on TODO keywords, +tags, or properties and will be discussed later in this manual. @kindex C-c C-e v @cindex printing sparse trees @@ -1038,7 +1089,7 @@ part of the document and print the resulting file. Within an entry of the outline tree, hand-formatted lists can provide additional structure. They also provide a way to create lists of checkboxes (@pxref{Checkboxes}). Org-mode supports editing such lists, -and the HTML exporter (@pxref{Exporting}) does parse and format them. +and the HTML exporter (@pxref{Exporting}) parses and formats them. Org-mode knows ordered and unordered lists. Unordered list items start with @samp{-}, @samp{+}, or @samp{*}@footnote{When using @samp{*} as a @@ -1046,8 +1097,9 @@ bullet, lines must be indented or they will be seen as top-level headlines. Also, when you are hiding leading stars to get a clean outline view, plain list items starting with a star are visually indistinguishable from true headlines. In short: even though @samp{*} -is supported, it may be better not to use it for plain list items.} as -bullets. Ordered list items start with @samp{1.} or @samp{1)}. Items +is supported, it may be better to not use it for plain list items.} as +bullets. Ordered list items start with a numeral followed by either a +period or a right parenthesis, such as @samp{1.} or @samp{1)}. Items belonging to the same list must have the same indentation on the first line. In particular, if an ordered list reaches number @samp{10.}, then the 2--digit numbers must be written left-aligned with the other numbers @@ -1131,9 +1183,9 @@ the command chain with a cursor motion or so. @kindex C-c C-c @item C-c C-c If there is a checkbox (@pxref{Checkboxes}) in the item line, toggle the -state of the checkbox. If not, make this command makes sure that all -the items on this list level use the same bullet. Furthermore, if this -is an ordered list, make sure the numbering is ok. +state of the checkbox. If not, this command makes sure that all the +items on this list level use the same bullet. Furthermore, if this is +an ordered list, make sure the numbering is ok. @kindex C-c - @item C-c - Cycle the entire list level through the different itemize/enumerate @@ -1148,7 +1200,9 @@ With prefix arg, select the nth bullet from this list. Sometimes you want to keep information associated with an entry, but you normally don't want to see it. For this, Org-mode has @emph{drawers}. -Drawers need to be configured with the variable @code{org-drawers}, and +Drawers need to be configured with the variable +@code{org-drawers}@footnote{You can define drawers on a per-file basis +with a line like @code{#+DRAWERS: HIDDEN PROPERTIES STATE}}. Drawers look like this: @example @@ -1194,9 +1248,16 @@ silently in the shadow. @cindex tables @cindex editing tables -Org-mode has a very fast and intuitive table editor built-in. -Spreadsheet-like calculations are supported in connection with the -Emacs @file{calc} package. +Org-mode comes with a fast and intuitive table editor. Spreadsheet-like +calculations are supported in connection with the Emacs @file{calc} +package +@ifinfo +(@pxref{Calc,,,calc,Gnu Emacs Calculator Manual}). +@end ifinfo +@ifnotinfo +(see the Emacs Calculator manual for more information about the Emacs +calculator). +@end ifnotinfo @menu * Built-in table editor:: Simple tables @@ -1254,9 +1315,12 @@ unpredictable for you, configure the variables @item C-c | Convert the active region to table. If every line contains at least one TAB character, the function assumes that the material is tab separated. +If every line contains a comma, comma-separated values (CSV) are assumed. If not, lines are split at whitespace into fields. You can use a prefix -argument to indicate the minimum number of consecutive spaces required -to identify a field separator (default: just one).@* +argument to force a specific separator: @kbd{C-u} forces CSV, @kbd{C-u +C-u} forces TAB, and a numeric argument N indicates that at least N +consequtive spaces, or alternatively a TAB will be the separator. +@* If there is no active region, this command creates an empty Org-mode table. But it's easier just to start typing, like @kbd{|Name|Phone|Age @key{RET} |- @key{TAB}}. @@ -1388,18 +1452,14 @@ that are not fully visible (@pxref{Narrow columns}). When called with a @kbd{C-u} prefix, just make the full field visible, so that it can be edited in place. @c -@kindex C-c @key{TAB} -@item C-c @key{TAB} -This is an alias for @kbd{C-u C-c `} to make the current field fully -visible. -@c @item M-x org-table-import Import a file as a table. The table should be TAB- or whitespace -separated. Useful, for example, to import an Excel table or data from a -database, because these programs generally can write TAB-separated text -files. This command works by inserting the file into the buffer and -then converting the region to a table. Any prefix argument is passed on -to the converter, which uses it to determine the separator. +separated. Useful, for example, to import a spreadsheet table or data +from a database, because these programs generally can write +TAB-separated text files. This command works by inserting the file into +the buffer and then converting the region to a table. Any prefix +argument is passed on to the converter, which uses it to determine the +separator. @item C-c | Tables can also be imported by pasting tabular text into the org-mode buffer, selecting the pasted text with @kbd{C-x C-x} and then using the @@ -1407,7 +1467,7 @@ buffer, selecting the pasted text with @kbd{C-x C-x} and then using the @c @item M-x org-table-export Export the table as a TAB-separated file. Useful for data exchange with, -for example, Excel or database programs. +for example, spreadsheet or database programs. @end table If you don't like the automatic table editor because it gets in your @@ -1583,13 +1643,15 @@ The row specification only counts data lines and ignores horizontal separator lines (hlines). You can use absolute row numbers @samp{1}...@samp{N}, and row numbers relative to the current row like @samp{+3} or @samp{-1}. Or specify the row relative to one of the -hlines: @samp{I} refers to the first hline, @samp{II} to the second etc. -@samp{-I} refers to the first such line above the current line, -@samp{+I} to the first such line below the current line. You can also -write @samp{III+2} which is the second data line after the third hline -in the table. Relative row numbers like @samp{-3} will not cross hlines -if the current line is too close to the hline. Instead, the value -directly at the hline is used. +hlines: @samp{I} refers to the first hline@footnote{Note that only +hlines are counted that @emph{separate} table lines. If the table +starts with a hline above the header, it does not count.}, @samp{II} to +the second etc. @samp{-I} refers to the first such line above the +current line, @samp{+I} to the first such line below the current line. +You can also write @samp{III+2} which is the second data line after the +third hline in the table. Relative row numbers like @samp{-3} will not +cross hlines if the current line is too close to the hline. Instead, +the value directly at the hline is used. @samp{0} refers to the current row and column. Also, if you omit either the column or the row part of the reference, the current @@ -1656,8 +1718,8 @@ line like @noindent Also properties (@pxref{Properties and columns}) can be used as -constants in table formulas: For a property @samp{:XYZ:} use the name -@samp{$PROP_XYZ}, and the property will be searched in the current +constants in table formulas: For a property @samp{:Xyz:} use the name +@samp{$PROP_Xyz}, and the property will be searched in the current outline entry and in the hierarchy above it. If you have the @file{constants.el} package, it will also be used to resolve constants, including natural constants like @samp{$h} for Planck's constant, and @@ -2087,8 +2149,8 @@ series of degree @code{n} at location @code{x} for a couple of functions @chapter Hyperlinks @cindex hyperlinks -Just like HTML, Org-mode provides links inside a file, and external -links to other files, Usenet articles, emails, and much more. +Like HTML, Org-mode provides links inside a file, external links to +other files, Usenet articles, emails, and much more. @menu * Link format:: How links in Org-mode are formatted @@ -2099,7 +2161,6 @@ links to other files, Usenet articles, emails, and much more. * Link abbreviations:: Shortcuts for writing complex links * Search options:: Linking to a specific location * Custom searches:: When the default search is not enough -* Remember:: Org-trees store quick notes @end menu @node Link format, Internal links, Hyperlinks, Hyperlinks @@ -2304,20 +2365,21 @@ Insert a link. This prompts for a link to be inserted into the buffer. You can just type a link, using text for an internal link, or one of the link type prefixes mentioned in the examples above. All links stored during the current session are part of the history for this prompt, so -you can access them with @key{up} and @key{down}. Completion, on the -other hand, will help you to insert valid link prefixes like -@samp{http:} or @samp{ftp:}, including the prefixes defined through link -abbreviations (@pxref{Link abbreviations}). The link will be inserted -into the buffer@footnote{After insertion of a stored link, the link will -be removed from the list of stored links. To keep it in the list later -use, use a triple @kbd{C-u} prefix to @kbd{C-c C-l}, or configure the -option @code{org-keep-stored-link-after-insertion}.}, along with a -descriptive text. If some text was selected when this command is -called, the selected text becomes the default description.@* Note that -you don't have to use this command to insert a link. Links in Org-mode -are plain text, and you can type or paste them straight into the buffer. -By using this command, the links are automatically enclosed in double -brackets, and you will be asked for the optional descriptive text. +you can access them with @key{up} and @key{down} (or @kbd{M-p/n}). +Completion, on the other hand, will help you to insert valid link +prefixes like @samp{http:} or @samp{ftp:}, including the prefixes +defined through link abbreviations (@pxref{Link abbreviations}). The +link will be inserted into the buffer@footnote{After insertion of a +stored link, the link will be removed from the list of stored links. To +keep it in the list later use, use a triple @kbd{C-u} prefix to @kbd{C-c +C-l}, or configure the option +@code{org-keep-stored-link-after-insertion}.}, along with a descriptive +text. If some text was selected when this command is called, the +selected text becomes the default description.@* Note that you don't +have to use this command to insert a link. Links in Org-mode are plain +text, and you can type or paste them straight into the buffer. By using +this command, the links are automatically enclosed in double brackets, +and you will be asked for the optional descriptive text. @c @c If the link is a @samp{file:} link and @c the linked file is located in the same directory as the current file or @@ -2513,7 +2575,7 @@ to search the current file. For example, @code{[[file:::find me]]} does a search for @samp{find me} in the current file, just as @samp{[[find me]]} would. -@node Custom searches, Remember, Search options, Hyperlinks +@node Custom searches, , Search options, Hyperlinks @section Custom Searches @cindex custom search strings @cindex search strings, custom @@ -2537,194 +2599,26 @@ an implementation example. Search for @samp{BibTeX links} in the source file. -@node Remember, , Custom searches, Hyperlinks -@section Remember -@cindex @file{remember.el} - -Another way to create org entries with links to other files is through -the @i{remember} package by John Wiegley. @i{Remember} lets you store -quick notes with little interruption of your work flow. See -@uref{http://www.emacswiki.org/cgi-bin/wiki/RememberMode} for more -information. The notes produced by @i{Remember} can be stored in -different ways, and Org-mode files are a good target. Org-mode -significantly expands the possibilities of @i{remember}: You may define -templates for different note types, and to associate target files and -headlines with specific templates. It also allows you to select the -location where a note should be stored interactively, on the fly. - -@menu -* Setting up remember:: Some code for .emacs to get things going -* Remember templates:: Define the outline of different note types -* Storing notes:: Directly get the note to where it belongs -@end menu - -@node Setting up remember, Remember templates, Remember, Remember -@subsection Setting up remember - -The following customization will tell @i{remember} to use org files as -target, and to create annotations compatible with Org-mode links. - -@example -(setq org-directory "~/path/to/my/orgfiles/") -(setq org-default-notes-file "~/.notes") -(setq remember-annotation-functions '(org-remember-annotation)) -(setq remember-handler-functions '(org-remember-handler)) -(add-hook 'remember-mode-hook 'org-remember-apply-template) -@end example - -@node Remember templates, Storing notes, Setting up remember, Remember -@subsection Remember templates -@cindex templates, for remember - -In combination with Org-mode, you can use templates to generate -different types of @i{remember} notes. For example, if you would like -to use one template to create general TODO entries, another one for -journal entries, and a third one for collecting random ideas, you could -use: - -@example -(setq org-remember-templates - '((?t "* TODO %?\n %i\n %a" "~/org/TODO.org") - (?j "* %U %?\n\n %i\n %a" "~/org/JOURNAL.org") - (?i "* %^@{Title@}\n %i\n %a" "~/org/JOURNAL.org" "New Ideas"))) -@end example - -@noindent In these entries, the character specifies how to select the -template. The first string specifies the template. Two more (optional) -strings give the file in which, and the headline under which the new -note should be stored. The file defaults (if not present or @code{nil}) -to @code{org-default-notes-file}, the heading to -@code{org-remember-default-headline}. Both defaults help to get to the -storing location quickly, but you can change the location interactively -while storing the note. - -When you call @kbd{M-x remember} (or @kbd{M-x org-remember}) to remember -something, org will prompt for a key to select the template (if you have -more than one template) and then prepare the buffer like -@example -* TODO - [[file:link to where you called remember]] -@end example - -@noindent or - -@example -* [2006-03-21 Tue 15:37] - - [[file:link to where you called remember]] -@end example - -@noindent -During expansion of the template, special @kbd{%}-escapes allow dynamic -insertion of content: -@example -%^@{prompt@} @r{prompt the user for a string and replace this sequence with it.} -%t @r{time stamp, date only} -%T @r{time stamp with date and time} -%u, %U @r{like the above, but inactive time stamps} -%^t @r{like @code{%t}, but prompt for date. Similarly @code{%^T}, @code{%^u}, @code{%^U}} - @r{You may define a prompt like @code{%^@{Birthday@}t}} -%n @r{user name (taken from @code{user-full-name})} -%a @r{annotation, normally the link created with @code{org-store-link}} -%i @r{initial content, the region when remember is called with C-u.} - @r{The entire text will be indented like @code{%i} itself.} -%^g @r{prompt for tags, with completion on tags in target file.} -%^G @r{prompt for tags, with completion all tags in all agenda files.} -%:keyword @r{specific information for certain link types, see below} -@end example - -@noindent -For specific link types, the following keywords will be defined: - -@example -Link type | Available keywords --------------------+---------------------------------------------- -bbdb | %:name %:company -vm, wl, mh, rmail | %:type %:subject %:message-id - | %:from %:fromname %:fromaddress - | %:to %:toname %:toaddress - | %:fromto @r{(either "to NAME" or "from NAME")@footnote{This will always be the other, not the user. See the variable @code{org-from-is-user-regexp}.}} -gnus | %:group, @r{for messages also all email fields} -w3, w3m | %:url -info | %:file %:node -calendar | %:date" -@end example - -@noindent -To place the cursor after template expansion use: - -@example -%? @r{After completing the template, position cursor here.} -@end example - -@noindent -If you change you mind about which template to use, call -@code{org-remember} in the remember buffer. You may then select a new -template that will be filled with the previous context information. - -@node Storing notes, , Remember templates, Remember -@subsection Storing notes - -When you are finished preparing a note with @i{remember}, you have to press -@kbd{C-c C-c} to file the note away. The handler first prompts for a -target file - if you press @key{RET}, the value specified for the -template is used. Then the command offers the headings tree of the -selected file, with the cursor position at the default headline (if you -had specified one in the template). You can either immediately press -@key{RET} to get the note placed there. Or you can use the following -keys to find a better location: -@example -@key{TAB} @r{Cycle visibility.} -@key{down} / @key{up} @r{Next/previous visible headline.} -n / p @r{Next/previous visible headline.} -f / b @r{Next/previous headline same level.} -u @r{One level up.} -@c 0-9 @r{Digit argument.} -@end example -@noindent -Pressing @key{RET} or @key{left} or @key{right} -then leads to the following result. - -@multitable @columnfractions 0.2 0.15 0.65 -@item @b{Cursor position} @tab @b{Key} @tab @b{Note gets inserted} -@item buffer-start @tab @key{RET} @tab as level 2 heading at end of file -@item on headline @tab @key{RET} @tab as sublevel of the heading at cursor -@item @tab @key{left}/@key{right} @tab as same level, before/after current heading -@item not on headline @tab @key{RET} - @tab at cursor position, level taken from context. -@end multitable - -So a fast way to store the note to its default location is to press -@kbd{C-c C-c @key{RET} @key{RET}}. Even shorter would be @kbd{C-u C-c -C-c}, which does the same without even asking for a file or showing the -tree. - -Before inserting the text into a tree, the function ensures that the -text has a headline, i.e. a first line that starts with a @samp{*}. -If not, a headline is constructed from the current date and some -additional data. If the variable @code{org-adapt-indentation} is -non-nil, the entire text is also indented so that it starts in the -same column as the headline (after the asterisks). - @node TODO items, Tags, Hyperlinks, Top @chapter TODO items @cindex TODO items -Org-mode does not maintain TODO lists as a separate document. TODO -items are an integral part of the notes file, because TODO items -usually come up while taking notes! With Org-mode, you simply mark -any entry in a tree as being a TODO item. In this way, the -information is not duplicated, and the entire context from which the -item emerged is always present when you check. +Org-mode does not maintain TODO lists as separate documents. Instead, +TODO items are an integral part of the notes file, because TODO items +usually come up while taking notes! With Org-mode, simply mark any +entry in a tree as being a TODO item. In this way, information is not +duplicated, and the entire context from which the TODO item emerged is +always present. -Of course, this technique causes TODO items to be scattered throughout -your file. Org-mode provides methods to give you an overview over all -things you have to do. +Of course, this technique for managing TODO items scatters them +throughout your notes file. Org-mode compensates for this by providing +methods to give you an overview of all the things that you have to do. @menu * TODO basics:: Marking and displaying TODO entries * TODO extensions:: Workflow and assignments +* Progress logging:: Dates and notes for progress * Priorities:: Some things are more important than others * Breaking down tasks:: Splitting a task into manageable pieces * Checkboxes:: Tick-off lists @@ -2733,8 +2627,8 @@ things you have to do. @node TODO basics, TODO extensions, TODO items, TODO items @section Basic TODO functionality -Any headline can become a TODO item by starting it with the word TODO, -for example: +Any headline becomes a TODO item when it starts with the word +@samp{TODO}, for example: @example *** TODO Write letter to Sam Fortune @@ -2756,61 +2650,72 @@ Rotate the TODO state of the current item among The same rotation can also be done ``remotely'' from the timeline and agenda buffers with the @kbd{t} command key (@pxref{Agenda commands}). + +@kindex C-u C-c C-t +@item C-u C-c C-t +Select a specific keyword using completion or (if it has been set up) +the fast selection interface. + @kindex S-@key{right} @kindex S-@key{left} @item S-@key{right} @itemx S-@key{left} -Select the following/preceding TODO state, similar to cycling. Mostly -useful if more than two TODO states are possible (@pxref{TODO +Select the following/preceding TODO state, similar to cycling. Useful +mostly if more than two TODO states are possible (@pxref{TODO extensions}). @kindex C-c C-c @item C-c C-c -Use the fast tag interface to quickly and directly select a specific -TODO state. For this you need to assign keys to TODO state, like this: +Use the fast tag interface to directly select a specific TODO state. +For this you need to assign keys to TODO states, like this: @example #+SEQ_TODO: TODO(t) STARTED(s) WAITING(w) | DONE(d) @end example -@noindent See @ref{Per file keywords} and @ref{Setting tags} for more +@noindent See @ref{Per-file keywords} and @ref{Setting tags} for more information. @kindex C-c C-v +@kindex C-c / t @cindex sparse tree, for TODO @item C-c C-v +@itemx C-c / t View TODO items in a @emph{sparse tree} (@pxref{Sparse trees}). Folds the entire buffer, but shows all TODO items and the headings hierarchy above them. With prefix arg, search for a specific TODO. You will be prompted for the keyword, and you can also give a list of keywords like -@code{kwd1|kwd2|...}. With numerical prefix N, show the tree for the +@code{KWD1|KWD2|...}. With numerical prefix N, show the tree for the Nth keyword in the variable @code{org-todo-keywords}. With two prefix args, find all TODO and DONE entries. @kindex C-c a t @item C-c a t -Show the global TODO list. This collects the TODO items from all -agenda files (@pxref{Agenda views}) into a single buffer. The buffer is in -@code{agenda-mode}, so there are commands to examine and manipulate -the TODO entries directly from that buffer (@pxref{Agenda commands}). -@xref{Global TODO list}, for more information. +Show the global TODO list. Collects the TODO items from all agenda +files (@pxref{Agenda views}) into a single buffer. The new buffer will +be in @code{agenda-mode}, which provides commands to examine and +manipulate the TODO entries from the new buffer (@pxref{Agenda +commands}). @xref{Global TODO list}, for more information. @kindex S-M-@key{RET} @item S-M-@key{RET} Insert a new TODO entry below the current one. @end table -@node TODO extensions, Priorities, TODO basics, TODO items +@node TODO extensions, Progress logging, TODO basics, TODO items @section Extended use of TODO keywords @cindex extended TODO keywords -The default implementation of TODO entries is just two states: TODO and -DONE. You can use the TODO feature for more complicated things by -configuring the variable @code{org-todo-keywords}. With special setup, -the TODO keyword system can work differently in different files. +By default, marked TODO entries have one of only two states: TODO and +DONE. Org-mode allows you to classify TODO items in more complex ways +with @emph{TODO keywords} (stored in @code{org-todo-keywords}). With +special setup, the TODO keyword system can work differently in different +files. Note that @i{tags} are another way to classify headlines in general and TODO items in particular (@pxref{Tags}). @menu * Workflow states:: From TODO to DONE in steps -* TODO types:: I do this, Fred the rest +* TODO types:: I do this, Fred does the rest * Multiple sets in one file:: Mixing it all, and still finding your way -* Per file keywords:: Different files, different requirements +* Fast access to TODO states:: Single letter selection of a state +* Per-file keywords:: Different files, different requirements +* Faces for TODO keywords:: Highlighting states @end menu @node Workflow states, TODO types, TODO extensions, TODO extensions @@ -2875,7 +2780,7 @@ would use @kbd{C-3 C-c C-v}. To collect Lucy's items from all agenda files into a single buffer, you would use the prefix arg as well when creating the global todo list: @kbd{C-3 C-c t}. -@node Multiple sets in one file, Per file keywords, TODO types, TODO extensions +@node Multiple sets in one file, Fast access to TODO states, TODO types, TODO extensions @subsection Multiple keyword sets in one file @cindex todo keyword sets @@ -2918,10 +2823,34 @@ These keys jump from one TODO subset to the next. In the above example, would switch from @code{DONE} to @code{REPORT} in the example above. @end table -@node Per file keywords, , Multiple sets in one file, TODO extensions +@node Fast access to TODO states, Per-file keywords, Multiple sets in one file, TODO extensions +@subsection Fast access to TODO states + +If you would like to quickly change an entry to an arbitrary TODO state +instead of cycling through the states, you can set up keys for +single-letter access to the states. This is done by adding the section +key after each keyword, in parenthesis. For example: + +@lisp +(setq org-todo-keywords + '((sequence "TODO(t)" "|" "DONE(d)") + (sequence "REPORT(r)" "BUG(b)" "KNOWNCAUSE(k)" "|" "FIXED(f)") + (sequence "|" "CANCELED(c)"))) +@end lisp + +If you then press @code{C-u C-c C-t} followed by the selection key, the +entry will be switched to this state. @key{SPC} can be used to remove +any TODO keyword from an entry. Should you like this way of selecting +TODO states a lot, you might want to set the variable +@code{org-use-fast-todo-selection} to @code{t} and make this behavior +the default. Check also the variable +@code{org-fast-tag-selection-include-todo}, it allows to change the TODO +state through the tags interface (@pxref{Setting tags}). + +@node Per-file keywords, Faces for TODO keywords, Fast access to TODO states, TODO extensions @subsection Setting up keywords for individual files @cindex keyword options -@cindex per file keywords +@cindex per-file keywords It can be very useful to use different aspects of the TODO mechanism in different files. For file-local settings, you need to add special lines @@ -2961,24 +2890,124 @@ Org-mode is activated after visiting a file. @kbd{C-c C-c} with the cursor in a line starting with @samp{#+} is simply restarting Org-mode for the current buffer.}. -@node Priorities, Breaking down tasks, TODO extensions, TODO items +@node Faces for TODO keywords, , Per-file keywords, TODO extensions +@subsection Faces for TODO keywords +@cindex faces, for TODO keywords + +Org-mode highlights TODO keywords with special faces: @code{org-todo} +for keywords indicating that an item still has to be acted upon, and +@code{org-done} for keywords indicating that an item is finished. If +you are using more than 2 different states, you might want to use +special faces for some of them. This can be done using the variable +@code{org-todo-keyword-faces}. For example: + +@lisp +(setq org-todo-keyword-faces + '(("TODO" . org-warning) + ("DEFERRED" . shadow) + ("CANCELED" . (:foreground "blue" :weight bold)))) +@end lisp + +@page +@node Progress logging, Priorities, TODO extensions, TODO items +@section Progress Logging +@cindex progress logging +@cindex logging, of progress + +Org-mode can automatically record a time stamp and even a note when you +mark a TODO item as DONE, or even each time you change the state of +a TODO item. + +@menu +* Closing items:: When was this entry marked DONE? +* Tracking TODO state changes:: When did the status change? +@end menu + +@node Closing items, Tracking TODO state changes, Progress logging, Progress logging +@subsection Closing items + +If you want to keep track of @emph{when} a certain TODO item was +finished, turn on logging with@footnote{The corresponding in-buffer +setting is: @code{#+STARTUP: logdone}. You may also set this for the +scope of a subtree by adding a @code{:LOGGING:} property with one or more +of the logging keywords in the value.} + +@lisp +(setq org-log-done t) +@end lisp + +@noindent +Then each time you turn a TODO entry into DONE using either @kbd{C-c +C-t} in the Org-mode buffer or @kbd{t} in the agenda buffer, a line +@samp{CLOSED: [timestamp]} will be inserted just after the headline. If +you turn the entry back into a TODO item through further state cycling, +that line will be removed again. In the timeline (@pxref{Timeline}) and +in the agenda (@pxref{Weekly/Daily agenda}), you can then use the +@kbd{l} key to display the TODO items closed on each day, giving you an +overview of what has been done on a day. If you want to record a note +along with the timestamp, use@footnote{The corresponding in-buffer +setting is: @code{#+STARTUP: lognotedone}} + +@lisp +(setq org-log-done '(done)) +@end lisp + +@node Tracking TODO state changes, , Closing items, Progress logging +@subsection Tracking TODO state changes + +When TODO keywords are used as workflow states (@pxref{Workflow +states}), you might want to keep track of when a state change occurred +and record a note about this change. With the setting@footnote{The +corresponding in-buffer setting is: @code{#+STARTUP: lognotestate}.} + +@lisp +(setq org-log-done '(state)) +@end lisp + +@noindent +each state change will prompt you for a note that will be attached to +the current headline. If you press @kbd{C-c C-c} without typing +anything into the note buffer, only the time of the state change will be +noted. Very likely you do not want this verbose tracking all the time, +so it is probably better to configure this behavior with in-buffer +options. For example, if you are tracking purchases, put these into a +separate file that contains: + +@example +#+SEQ_TODO: TODO(t) ORDERED(o) INVOICE(i) PAYED(p) | RECEIVED(r) +#+STARTUP: lognotestate +@end example + +If you only need to take a note for some of the states, mark those +states with an additional @samp{@@}, like this: + +@example +#+SEQ_TODO: TODO(t) ORDERED(o@@) INVOICE(i@@) PAYED(p) | RECEIVED(r) +#+STARTUP: lognotestate +@end example + +@node Priorities, Breaking down tasks, Progress logging, TODO items @section Priorities @cindex priorities -If you use Org-mode extensively to organize your work, you may end up -with a number of TODO entries so large that you'd like to prioritize -them. This can be done by placing a @emph{priority cookie} into the -headline, like this +If you use Org-mode extensively, you may end up enough TODO items that +it starts to make sense to prioritize them. Prioritizing can be done by +placing a @emph{priority cookie} into the headline of a TODO item, like +this @example *** TODO [#A] Write letter to Sam Fortune @end example @noindent -With its standard setup, Org-mode supports priorities @samp{A}, -@samp{B}, and @samp{C}. @samp{A} is the highest priority. An entry -without a cookie is treated as priority @samp{B}. Priorities make a -difference only in the agenda (@pxref{Weekly/Daily agenda}). +By default, Org-mode supports three priorities: @samp{A}, @samp{B}, and +@samp{C}. @samp{A} is the highest priority. An entry without a cookie +is treated as priority @samp{B}. Priorities make a difference only in +the agenda (@pxref{Weekly/Daily agenda}); outside the agenda, they have +no inherent meaning to Org-mode. + +Priorities can be attached to any outline tree entries; they do not need +to be TODO items. @table @kbd @kindex @kbd{C-c ,} @@ -2993,8 +3022,9 @@ agenda buffer with the @kbd{,} command (@pxref{Agenda commands}). @kindex S-@key{down} @item S-@key{up} @itemx S-@key{down} -Increase/decrease priority of current headline. Note that these keys -are also used to modify time stamps (@pxref{Creating timestamps}). +Increase/decrease priority of current headline@footnote{See also the +option @code{org-priority-start-cycle-with-default'}.}. Note that these +keys are also used to modify time stamps (@pxref{Creating timestamps}). Furthermore, these keys are also used by CUA-mode (@pxref{Conflicts}). @end table @@ -3026,13 +3056,15 @@ of checkboxes to identify (a hierarchy of) a large number of subtasks @section Checkboxes @cindex checkboxes -Every item in a plain list (@pxref{Plain lists}) can be made a checkbox -by starting it with the string @samp{[ ]}. This feature is similar to -TODO items (@pxref{TODO items}), but more lightweight. Checkboxes are -not included into the global TODO list, so they are often great to split -a task into a number of simple steps. Or you can use them in a shopping -list. To toggle a checkbox, use @kbd{C-c C-c}, or try Piotr Zielinski's -@file{org-mouse.el}. Here is an example of a checkbox list. +Every item in a plain list (@pxref{Plain lists}) can be made into a +checkbox by starting it with the string @samp{[ ]}. This feature is +similar to TODO items (@pxref{TODO items}), but is more lightweight. +Checkboxes are not included into the global TODO list, so they are often +great to split a task into a number of simple steps. Or you can use +them in a shopping list. To toggle a checkbox, use @kbd{C-c C-c}, or +use the mouse (thanks to Piotr Zielinski's @file{org-mouse.el}). + +Here is an example of a checkbox list. @example * TODO Organize party [3/6] @@ -3048,16 +3080,17 @@ list. To toggle a checkbox, use @kbd{C-c C-c}, or try Piotr Zielinski's @cindex statistics, for checkboxes @cindex checkbox statistics The @samp{[3/6]} and @samp{[1/3]} in the first and second line are -cookies indicating how many checkboxes are present in this entry, and -how many of them have been checked off. This can give you an idea on -how many checkboxes remain, even without opening a folded entry. The -cookies can be placed into a headline or into (the first line of) a -plain list item. Each cookie covers all checkboxes structurally below -that headline/item. You have to insert the cookie yourself by typing -either @samp{[/]} or @samp{[%]}. In the first case you get an @samp{n -out of m} result, in the second case you get information about the +cookies indicating how many checkboxes present in this entry have been +checked off, and the total number of checkboxes are present. This can +give you an idea on how many checkboxes remain, even without opening a +folded entry. The cookies can be placed into a headline or into (the +first line of) a plain list item. Each cookie covers all checkboxes +structurally below the headline/item on which the cookie appear. You +have to insert the cookie yourself by typing either @samp{[/]} or +@samp{[%]}. With @samp{[/]} you get an @samp{n out of m} result, as in +the examples above. With @samp{[%]} you get information about the percentage of checkboxes checked (in the above example, this would be -@samp{[50%]} and @samp{[33%], respectively}). +@samp{[50%]} and @samp{[33%]}, respectively). @noindent The following commands work with checkboxes: @@ -3096,7 +3129,6 @@ delete boxes or add/change them by hand, use this command to get things back into synch. Or simply toggle any checkbox twice with @kbd{C-c C-c}. @end table - @node Tags, Properties and columns, TODO items, Top @chapter Tags @cindex tags @@ -3104,14 +3136,15 @@ back into synch. Or simply toggle any checkbox twice with @kbd{C-c C-c}. @cindex matching, tags @cindex sparse tree, tag based -If you wish to implement a system of labels and contexts for -cross-correlating information, an excellent way is to assign @i{tags} to -headlines. Org-mode has extensive support for using tags. +An excellent way to implement labels and contexts for cross-correlating +information is to assign @i{tags} to headlines. Org-mode has extensive +support for tags. -Every headline can contain a list of tags, at the end of the headline. -Tags are normal words containing letters, numbers, @samp{_}, and -@samp{@@}. Tags must be preceded and followed by a single colon; like -@samp{:WORK:}. Several tags can be specified like @samp{:WORK:URGENT:}. +Every headline can contain a list of tags; they occur at the end of the +headline. Tags are normal words containing letters, numbers, @samp{_}, +and @samp{@@}. Tags must be preceded and followed by a single colon, +e.g., @samp{:WORK:}. Several tags can be specified, as in +@samp{:work:URGENT:}. @menu * Tag inheritance:: Tags use the tree structure of the outline @@ -3121,6 +3154,7 @@ Tags are normal words containing letters, numbers, @samp{_}, and @node Tag inheritance, Setting tags, Tags, Tags @section Tag inheritance +@cindex tag inheritance @cindex inheritance, of tags @cindex sublevels, inclusion into tags match @@ -3129,20 +3163,21 @@ heading has a certain tag, all subheadings will inherit the tag as well. For example, in the list @example -* Meeting with the French group :WORK: -** Summary by Frank :BOSS:NOTES: -*** TODO Prepare slides for him :ACTION: +* Meeting with the French group :work: +** Summary by Frank :boss:notes: +*** TODO Prepare slides for him :action: @end example @noindent -the final heading will have the tags @samp{:WORK:}, @samp{:BOSS:}, -@samp{:NOTES:}, and @samp{:ACTION:}. When executing tag searches and +the final heading will have the tags @samp{:work:}, @samp{:boss:}, +@samp{:notes:}, and @samp{:action:} even though the final heading is not +explicitly marked with those tags. When executing tag searches and Org-mode finds that a certain headline matches the search criterion, it -will not check any sublevel headline, assuming that these likely also -match, and that the list of matches can become very long. This may -not be what you want, however, and you can influence inheritance and -searching using the variables @code{org-use-tag-inheritance} and -@code{org-tags-match-list-sublevels}. +will not check any sublevel headline, assuming that these also match and +that the list of matches could become very long because of that. If you +do want the subevels be tested and listed as well, you may set the +variable @code{org-tags-match-list-sublevels}. To turn off tag +inheritance entirely, use the variable @code{org-use-tag-inheritance}. @node Setting tags, Tag searches, Tag inheritance, Tags @section Setting tags @@ -3174,13 +3209,13 @@ of tags with the variable @code{org-tag-alist}. Finally you can set the default tags for a given file with lines like @example -#+TAGS: @@WORK @@HOME @@TENNISCLUB -#+TAGS: Laptop Car PC Sailboat +#+TAGS: @@work @@home @@tennisclub +#+TAGS: laptop car pc sailboat @end example If you have globally defined your preferred set of tags using the variable @code{org-tag-alist}, but would like to use a dynamic tag list -in a specific file: Just add an empty TAGS option line to that file: +in a specific file, add an empty TAGS option line to that file: @example #+TAGS: @@ -3193,13 +3228,13 @@ single key per tag. To function efficiently, you should assign unique keys to most tags. This can be done globally with @lisp -(setq org-tag-alist '(("@@WORK" . ?w) ("@@HOME" . ?h) ("Laptop" . ?l))) +(setq org-tag-alist '(("@@work" . ?w) ("@@home" . ?h) ("laptop" . ?l))) @end lisp @noindent or on a per-file basis with @example -#+TAGS: @@WORK(w) @@HOME(h) @@TENNISCLUB(t) Laptop(l) PC(p) +#+TAGS: @@work(w) @@home(h) @@tennisclub(t) laptop(l) pc(p) @end example @noindent @@ -3209,11 +3244,11 @@ curly braces@footnote{In @code{org-mode-alist} use groups are allowed.} @example -#+TAGS: @{ @@WORK(w) @@HOME(h) @@TENNISCLUB(t) @} Laptop(l) PC(p) +#+TAGS: @{ @@work(w) @@home(h) @@tennisclub(t) @} laptop(l) pc(p) @end example -@noindent you indicate that at most one of @samp{@@WORK}, @samp{@@HOME}, -and @samp{@@TENNISCLUB} should be selected. +@noindent you indicate that at most one of @samp{@@work}, @samp{@@home}, +and @samp{@@tennisclub} should be selected. @noindent Don't forget to press @kbd{C-c C-c} with the cursor in one of these lines to activate any changes. @@ -3255,10 +3290,10 @@ selection window. @noindent This method lets you assign tags to a headline with very few keys. With -the above setup, you could clear the current tags and set @samp{@@HOME}, -@samp{Laptop} and @samp{PC} tags with just the following keys: @kbd{C-c -C-c @key{SPC} h l p @key{RET}}. Switching from @samp{@@HOME} to -@samp{@@WORK} would be done with @kbd{C-c C-c w @key{RET}} or +the above setup, you could clear the current tags and set @samp{@@home}, +@samp{laptop} and @samp{pc} tags with just the following keys: @kbd{C-c +C-c @key{SPC} h l p @key{RET}}. Switching from @samp{@@home} to +@samp{@@work} would be done with @kbd{C-c C-c w @key{RET}} or alternatively with @kbd{C-c C-c C-c w}. Adding the non-predefined tag @samp{Sarah} could be done with @kbd{C-c C-c @key{TAB} S a r a h @key{RET} @key{RET}}. @@ -3279,12 +3314,14 @@ when you press an extra @kbd{C-c}. @cindex tag searches @cindex searching for tags -Once a tags system has been set up, it can be used to collect related +Once a system of tags has been set up, it can be used to collect related information into special lists. @table @kbd @kindex C-c \ +@kindex C-c / T @item C-c \ +@itemx C-c / T Create a sparse tree with all headlines matching a tags search. With a @kbd{C-u} prefix argument, ignore headlines that are not a TODO line. @kindex C-c a m @@ -3307,14 +3344,14 @@ positive selection. The AND operator @samp{&} is optional when @samp{+} or @samp{-} is present. Examples: @table @samp -@item +WORK-BOSS -Select headlines tagged @samp{:WORK:}, but discard those also tagged -@samp{:BOSS:}. -@item WORK|LAPTOP -Selects lines tagged @samp{:WORK:} or @samp{:LAPTOP:}. -@item WORK|LAPTOP&NIGHT -Like before, but require the @samp{:LAPTOP:} lines to be tagged also -@samp{NIGHT}. +@item +work-boss +Select headlines tagged @samp{:work:}, but discard those also tagged +@samp{:boss:}. +@item work|laptop +Selects lines tagged @samp{:work:} or @samp{:laptop:}. +@item work|laptop&night +Like before, but require the @samp{:laptop:} lines to be tagged also +@samp{:night:}. @end table @cindex TODO keyword matching, with tags search @@ -3330,48 +3367,65 @@ M}, or equivalently start the todo part after the slash with @samp{!}. Examples: @table @samp -@item WORK/WAITING -Select @samp{:WORK:}-tagged TODO lines with the specific TODO +@item work/WAITING +Select @samp{:work:}-tagged TODO lines with the specific TODO keyword @samp{WAITING}. -@item WORK/!-WAITING-NEXT -Select @samp{:WORK:}-tagged TODO lines that are neither @samp{WAITING} +@item work/!-WAITING-NEXT +Select @samp{:work:}-tagged TODO lines that are neither @samp{WAITING} nor @samp{NEXT} -@item WORK/+WAITING|+NEXT -Select @samp{:WORK:}-tagged TODO lines that are either @samp{WAITING} or +@item work/+WAITING|+NEXT +Select @samp{:work:}-tagged TODO lines that are either @samp{WAITING} or @samp{NEXT}. @end table @cindex regular expressions, with tags search Any element of the tag/todo match can be a regular expression - in this case it must be enclosed in curly braces. For example, -@samp{WORK+@{^BOSS.*@}} matches headlines that contain the tag -@samp{WORK} and any tag @i{starting} with @samp{BOSS}. +@samp{work+@{^boss.*@}} matches headlines that contain the tag +@samp{:work:} and any tag @i{starting} with @samp{boss}. -@cindex level, require for tags match -You can also require a headline to be of a certain level, by writing -instead of any TAG an expression like @samp{LEVEL=3}. For example, a -search @samp{+LEVEL=3+BOSS/-DONE} lists all level three headlines that -have the tag BOSS and are @emph{not} marked with the todo keyword DONE. +@cindex level, require for tags/property match +@cindex category, require for tags/property match +You can also require a headline to be of a certain level or category, by +writing instead of any TAG an expression like @samp{LEVEL=3} or +@samp{CATEGORY="work"}, respectively. For example, a search +@samp{+LEVEL=3+boss/-DONE} lists all level three headlines that have the +tag @samp{boss} and are @emph{not} marked with the todo keyword DONE. -@node Properties and columns, Timestamps, Tags, Top +@node Properties and columns, Dates and times, Tags, Top @chapter Properties and Columns @cindex properties Properties are a set of key-value pairs associated with an entry. There are two main applications for properties in Org-mode. First, properties -are like tags, but with a value. For example, in a file where you -document bugs and plan releases of a piece of software, instead of using -tags like @code{:release_1:}, @code{:release_2:}, it can be more -efficient to use a property @code{RELEASE} with a value @code{1.0} or -@code{2.0}. Second, you can use properties to implement (very basic) -database capabilities in an Org-mode buffer, for example to create a -list of Music CD's you own. You can edit and view properties +are like tags, but with a value. Second, you can use properties to +implement (very basic) database capabilities in an Org-mode buffer. For +an example of the first application, imagine maintaining a file where +you document bugs and plan releases of a piece of software. Instead of +using tags like @code{:release_1:}, @code{:release_2:}, one can use a +property, say @code{:Release:}, that in different subtrees has different +values, such as @code{1.0} or @code{2.0}. For an example of the second +application of properties, imagine keeping track of one's music CD's, +where properties could be things such as the album artist, date of +release, number of tracks, and so on. + +Properties can be conveiently edited and viewed in column view +(@pxref{Column view}). + +Properties are like tags, but with a value. For example, in a file +where you document bugs and plan releases of a piece of software, +instead of using tags like @code{:release_1:}, @code{:release_2:}, it +can be more efficient to use a property @code{:Release:} with a value +@code{1.0} or @code{2.0}. Second, you can use properties to implement +(very basic) database capabilities in an Org-mode buffer, for example to +create a list of Music CD's you own. You can edit and view properties conveniently in column view (@pxref{Column view}). @menu * Property syntax:: How properties are spelled out * Special properties:: Access to other Org-mode features * Property searches:: Matching property values +* Property inheritance:: Passing values down the tree * Column view:: Tabular viewing and editing * Property API:: Properties for Lisp programmers @end menu @@ -3399,8 +3453,8 @@ first, and the value after it. Here is an example: :END: @end example -You may define the allowed values for a particular property @samp{XYZ} -by setting a property @samp{XYZ_ALL}. This special property is +You may define the allowed values for a particular property @samp{:Xyz:} +by setting a property @samp{:Xyz_ALL:}. This special property is @emph{inherited}, so if you set it in a level 1 entry, it will apply to the entire tree. When allowed values are defined, setting the corresponding property becomes easier and is less prone to typing @@ -3434,6 +3488,10 @@ The following commands help to work with properties: @item M-@key{TAB} After an initial colon in a line, complete property keys. All keys used in the current file will be offered as possible completions. +@kindex C-c C-x p +@item C-c C-x p +Set a property. This prompts for a property name and a value. If +necessary, the property drawer is created as well. @item M-x org-insert-property-drawer Insert a property drawer into the current entry. The drawer will be inserted early in the entry, but after the lines with planning @@ -3452,6 +3510,9 @@ Switch property at point to the next/previous allowed value. Remove a property from the current entry. @item C-c C-c D Globally remove a property, from all entries in the current file. +@item C-c C-c c +Compute the property at point, using the operator and scope from the +nearest column format definition. @end table @node Special properties, Property searches, Property syntax, Properties and columns @@ -3461,9 +3522,9 @@ Globally remove a property, from all entries in the current file. Special properties provide alternative access method to Org-mode features discussed in the previous chapters, like the TODO state or the priority of an entry. This interface exists so that you can include -these states into columns view (@pxref{Column view}). The following -property names are special and should not be used as keys in the -properties drawer: +these states into columns view (@pxref{Column view}), or to use them in +queries. The following property names are special and should not be +used as keys in the properties drawer: @example TODO @r{The TODO keyword of the entry.} @@ -3472,27 +3533,81 @@ ALLTAGS @r{All tags, including inherited ones.} PRIORITY @r{The priority of the entry, a string with a single letter.} DEADLINE @r{The deadline time string, without the angular brackets.} SCHEDULED @r{The scheduling time stamp, without the angular brackets.} +TIMESTAMP @r{The first keyword-less time stamp in the entry.} +TIMESTAMP_IA @r{The first inactive time stamp in the entry.} +CLOCKSUM @r{The sum of CLOCK intervals in the subtree. @code{org-clock-sum}} + @r{must be run first to compute the values.} @end example -@node Property searches, Column view, Special properties, Properties and columns +@node Property searches, Property inheritance, Special properties, Properties and columns @section Property searches @cindex properties, searching +@cindex properties, inheritance +@cindex searching, of properties +@cindex inheritance, of properties To create sparse trees and special lists with selection based on properties, the same commands are used as for tag searches (@pxref{Tag searches}), and the same logic applies. For example, a search string @example -+WORK-BOSS+PRIORITY="A"+coffee="unlimited"+with=@{Sarah\|Denny@} ++work-boss+PRIORITY="A"+Coffee="unlimited"+With=@{Sarah\|Denny@} @end example @noindent -finds entries tagged @samp{:WORK:} but not @samp{:BOSS:}, which -also have a priority value @samp{A}, a @samp{:coffee:} property with the -value @samp{unlimited}, and a @samp{:with:} property that is matched by +finds entries tagged @samp{:work:} but not @samp{:boss:}, which +also have a priority value @samp{A}, a @samp{:Coffee:} property with the +value @samp{unlimited}, and a @samp{:With:} property that is matched by the regular expression @samp{Sarah\|Denny}. -@node Column view, Property API, Property searches, Properties and columns +You can configure Org-mode to use property inheritance during a search, +see @ref{Property inheritance} for details. + +There is also a special command for creating sparse trees based on a +single property: + +@table @kbd +@kindex C-c / p +@item C-c / p +Create a sparse tree based on the value of a property. This first +prompts for the name of a property, and then for a value. A sparse tree +is created with all entries that define this property with the given +value. If you enclose the value into curly braces, it is interpreted as +a regular expression and matched against the property values. +@end table + +@node Property inheritance, Column view, Property searches, Properties and columns +@section Property Inheritance + +The outline structure of Org-mode documents lends itself for an +inheritance model of properties: If the parent in a tree has a certain +property, the children can inherit this property. Org-mode does not +turn this on by default, because it can slow down property searches +significantly and is often not needed. However, if you find inheritance +useful, you can turn it on by setting the variable +@code{org-use-property-inheritance}. It may be set to @code{t}, to make +all properties inherited from the parent, or to a list of properties +that should be inherited. + +Org-mode has a few properties for which inheritance is hard-coded, at +least for the special applications for which they are used: + +@table @code +@item COLUMNS +The @code{:COLUMNS:} property defines the format of column view +(@pxref{Column view}). It is inherited in the sense that the level +where a @code{:COLUMNS:} property is defined is used as the starting +point for a column view table, independently of the location in the +subtree from where columns view is turned on. +@item CATEGORY +For agenda view, a category set through a @code{:CATEGORY:} property +applies to the entire subtree. +@item ARCHIVE +For archiving, the @code{:ARCHIVE:} property may define the archive +location for the entire subtree (@pxref{Moving subtrees}). +@end table + +@node Column view, Property API, Property inheritance, Properties and columns @section Column View A great way to view and edit properties in an outline tree is @@ -3512,6 +3627,7 @@ queries have collected selected items, possibly from a number of files. @menu * Defining columns:: The COLUMNS format property * Using column view:: How to create and use column view +* Capturing Column View:: A dynamic block for column view @end menu @node Defining columns, Using column view, Column view, Column view @@ -3536,8 +3652,9 @@ To define a column format for an entire file, use a line like #+COLUMNS: %25ITEM %TAGS %PRIORITY %TODO @end example -To specify a format that only applies to a specific tree, add a COLUMNS -property to the top node of that tree, for example +To specify a format that only applies to a specific tree, add a +@code{:COLUMNS:} property to the top node of that tree, for example: + @example ** Top node for columns view :PROPERTIES: @@ -3545,7 +3662,7 @@ property to the top node of that tree, for example :END: @end example -If a @code{COLUMNS} property is present in an entry, it defines columns +If a @code{:COLUMNS:} property is present in an entry, it defines columns for the entry itself, and for the entire subtree below it. Since the column definition is part of the hierarchical structure of the document, you can define columns on level 1 that are general enough for all @@ -3574,9 +3691,11 @@ property @r{The property that should be edited in this column.} @{summary-type@} @r{The summary type. If specified, the column values for} @r{parent nodes are computed from the children.} @r{Supported summary types are:} - @{+@} @r{Sum numbers in this column.} - @{:@} @r{Sum times, HH:MM:SS, plain numbers are hours.} - @{X@} @r{Checkbox status, [X] if all children are [X].} + @{+@} @r{Sum numbers in this column.} + @{+;%.1f@} @r{Like @samp{+}, but format result with @samp{%.1f}.} + @{$@} @r{Currency, short for @samp{+;%.2f}.} + @{:@} @r{Sum times, HH:MM:SS, plain numbers are hours.} + @{X@} @r{Checkbox status, [X] if all children are [X].} @end example @noindent @@ -3584,7 +3703,8 @@ Here is an example for a complete columns definition, along with allowed values. @example -:COLUMNS: %20ITEM %9Approved(Approved?)@{X@} %Owner %11Status %10Time_Spent@{:@} +:COLUMNS: %20ITEM %9Approved(Approved?)@{X@} %Owner %11Status \@footnote{Please note that the COLUMNS definition must be on a single line - it is wrapped here only because of formatting constraints.} + %10Time_Estimate@{:@} %CLOCKSUM :Owner_ALL: Tammy Mark Karl Lisa Don :Status_ALL: "In progress" "Not started yet" "Finished" "" :Approved_ALL: "[ ]" "[X]" @@ -3599,11 +3719,13 @@ field @samp{Approved}. When no width is given after the @samp{%} character, the column will be exactly as wide as it needs to be in order to fully display all values. The @samp{Approved} column does have a modified title (@samp{Approved?}, with a question mark). Summaries will -be created for the @samp{Time_Spent} column by adding time duration +be created for the @samp{Time_Estimate} column by adding time duration expressions like HH:MM, and for the @samp{Approved} column, by providing -an @samp{[X]} status if all children have been checked. +an @samp{[X]} status if all children have been checked. The +@samp{CLOCKSUM} column is special, it lists the sum of CLOCK intervals +in the subtree. -@node Using column view, , Defining columns, Column view +@node Using column view, Capturing Column View, Defining columns, Column view @subsection Using Column View @table @kbd @@ -3611,9 +3733,9 @@ an @samp{[X]} status if all children have been checked. @kindex C-c C-x C-c @item C-c C-x C-c Create the column view for the local environment. This command searches -the hierarchy, up from point, for a @code{COLUMNS} property that defines +the hierarchy, up from point, for a @code{:COLUMNS:} property that defines a format. When one is found, the column view table is established for -the entire tree, starting from the entry that contains the @code{COLUMNS} +the entire tree, starting from the entry that contains the @code{:COLUMNS:} property. If none is found, the format is taken from the @code{#+COLUMNS} line or from the variable @code{org-columns-default-format}, and column view is established for the current entry and its subtree. @@ -3638,6 +3760,9 @@ Edit the property at point. For the special properties, this will invoke the same interface that you normally use to change that property. For example, when editing a TAGS property, the tag completion or fast selection interface will pop up. +@kindex C-c C-c +@item C-c C-c +When there is a checkbox at point, toggle it. @kindex v @item v View the full value of this property. This is useful if the width of @@ -3661,6 +3786,62 @@ Insert a new column, to the right of the current column. Delete the current column. @end table +@node Capturing Column View, , Using column view, Column view +@subsection Capturing Column View + +Since column view is just an overlay over a buffer, it cannot be +exported or printed directly. If you want to capture a column view, use +the dynamic block (@pxref{Dynamic blocks}). The frame of this block +looks like this: + +@example +* The column view +#+BEGIN: columnview :hlines 1 :id "label" + +#+END: +@end example + +@noindent This dynamic block has the following parameters: + +@table @code +@item :id +This is most important parameter. Column view is a feature that is +often localized to a certain (sub)tree, and the capture block might be +in a different location in the file. To identify the tree whose view to +capture, you can use 3 values: +@example +local @r{use the tree in which the capture block is located} +global @r{make a global view, including all headings in the file} +"label" @r{call column view in the tree that has and @code{:ID:}} + @r{property with the value @i{label}} +@end example +@item :hlines +When @code{t}, insert a hline after every line. When a number N, insert +a hline before each headline with level @code{<= N}. +@item :vlines +When set to @code{t}, enforce column groups to get vertical lines. +@end table + +@noindent +The following commands insert or update the dynamic block: + +@table @kbd +@kindex C-c C-x r +@item C-c C-x r +Insert a dynamic block capturing a column view. You will be prompted +for the scope or id of the view. +@kindex C-c C-c +@item C-c C-c +@kindex C-c C-x C-u +@itemx C-c C-x C-u +Update dynamical block at point. The cursor needs to be in the +@code{#+BEGIN} line of the dynamic block. +@kindex C-u C-c C-x C-u +@item C-u C-c C-x C-u +Update all dynamic blocks (@pxref{Dynamic blocks}). This is useful if +you have several clocktable blocks in a buffer. +@end table + @node Property API, , Column view, Properties and columns @section The Property API @cindex properties, API @@ -3671,23 +3852,29 @@ be used by Emacs Lisp programs to work with properties and to implement features based on them. For more information see @ref{Using the property API}. -@node Timestamps, Agenda views, Properties and columns, Top -@chapter Timestamps +@node Dates and times, Remember, Properties and columns, Top +@chapter Dates and Times +@cindex dates +@cindex times @cindex time stamps @cindex date stamps -Items can be labeled with timestamps to make them useful for project -planning. +To assist project planning, TODO items can be labeled with a date and/or +a time. The specially formatted string carrying the date and time +information is called a @emph{timestamp} in Org-mode. This may be a +little confusing because timestamp is often used as indicating when +something was created or last changed. However, in Org-mode this term +is used in a much wider sense. @menu * Time stamps:: Assigning a time to a tree entry * Creating timestamps:: Commands which insert timestamps * Deadlines and scheduling:: Planning your work -* Progress logging:: Documenting when what work was done. +* Clocking work time:: @end menu -@node Time stamps, Creating timestamps, Timestamps, Timestamps +@node Time stamps, Creating timestamps, Dates and times, Dates and times @section Time stamps, deadlines and scheduling @cindex time stamps @cindex ranges, time @@ -3698,20 +3885,19 @@ planning. A time stamp is a specification of a date (possibly with time or a range of times) in a special format, either @samp{<2003-09-16 Tue>} or @samp{<2003-09-16 Tue 09:39>} or @samp{<2003-09-16 Tue -12:00-12:30>}@footnote{This is the standard ISO date/time format. If -you cannot get used to these, see @ref{Custom time format}}. A time -stamp can appear anywhere in the headline or body of an org-tree entry. -Its presence causes entries to be shown on specific dates in the agenda +12:00-12:30>}@footnote{This is the standard ISO date/time format. To +use an alternative format, see @ref{Custom time format}.}. A time stamp +can appear anywhere in the headline or body of an org-tree entry. Its +presence causes entries to be shown on specific dates in the agenda (@pxref{Weekly/Daily agenda}). We distinguish: @table @var -@item Plain time stamp +@item Plain time stamp; Event; Appointment @cindex timestamp A simple time stamp just assigns a date/time to an item. This is just -like writing down an appointment in a paper agenda, or like writing down -an event in a diary, when you want to take note of when something -happened. In the timeline and agenda displays, the headline of an entry -associated with a plain time stamp will be shown exactly on that date. +like writing down an appointment or event in a paper agenda. In the +timeline and agenda displays, the headline of an entry associated with a +plain time stamp will be shown exactly on that date. @example * Meet Peter at the movies <2006-11-01 Wed 19:15> @@ -3764,7 +3950,7 @@ angular ones. These time stamps are inactive in the sense that they do @end table -@node Creating timestamps, Deadlines and scheduling, Time stamps, Timestamps +@node Creating timestamps, Deadlines and scheduling, Time stamps, Dates and times @section Creating timestamps @cindex creating timestamps @cindex timestamps, creating @@ -3842,22 +4028,52 @@ into the following column). @cindex date, reading in minibuffer @cindex time, reading in minibuffer -When Org-mode prompts for a date/time, the prompt suggests to enter an -ISO date. But it will in fact accept any string containing some date -and/or time information. You can, for example, use @kbd{C-y} to paste a -(possibly multi-line) string copied from an email message. Org-mode -will find whatever information is in there and will replace anything not -specified with the current date and time. For example: +When Org-mode prompts for a date/time, the default is shown as an ISO +date, and the prompt therefore seems to ask for an ISO date. But it +will in fact accept any string containing some date and/or time +information, and it is really smart about interpreting your input. You +can, for example, use @kbd{C-y} to paste a (possibly multi-line) string +copied from an email message. Org-mode will find whatever information +is in there and derive anything you have not specified from the +@emph{default date and time}. The default is usually the current date +and time, but when modifying an existing time stamp, or when entering +the second stamp of a range, it is taken from the stamp in the buffer. +When filling in information, Org-mode assumes that most of the time you +will want to enter a date in the future: If you omit the month/year and +the given day/month is @i{before} today, it will assume that you mean a +future date@footnote{See the variable +@code{org-read-date-prefer-future}.}. + +For example, lets assume that today is @b{June 13, 2006}. Here is how +various inputs will be interpreted, the items filled in by Org-mode are +in @b{bold}. @example - 3-2-5 --> 2003-02-05 - feb 15 --> currentyear-02-15 - sep 12 9 --> 2009-09-12 - 12:45 --> today 12:45 - 22 sept 0:34 --> currentyear-09-22 0:34 - 12 --> currentyear-currentmonth-12 - Fri --> nearest Friday (today or later) - +4 --> 4 days from now (if +N is the only thing given) +3-2-5 --> 2003-02-05 +14 --> @b{2006}-@b{06}-14 +12 --> @b{2006}-@b{07}-12 +Fri --> nearest Friday (defaultdate or later) +sep 15 --> @b{2006}-11-15 +feb 15 --> @b{2007}-02-15 +sep 12 9 --> 2009-09-12 +12:45 --> @b{2006}-@b{06}-@b{13} 12:45 +22 sept 0:34 --> @b{2006}-09-22 0:34 +@end example + +Furthermore you can specify a relative date by giving, as the +@emph{first} thing in the input: a plus/minus sign, a number and a +letter [dwmy] to indicate change in days weeks, months, years. With a +single plus or minus, the date is always relative to today. With a +double plus or minus, it is relative to the default date. If instead of +a single letter, you use the abbreviation of day name, the date will be +the nth such day. E.g. + +@example ++4d --> four days from today ++4 --> same as above ++2w --> two weeks from today +++5 --> five days from default date ++2tue --> second tuesday from now. @end example The function understands English month and weekday abbreviations. If @@ -3873,38 +4089,30 @@ prompt, either by clicking on a date in the calendar, or by pressing information entered at the prompt. You can control the calendar fully from the minibuffer: -@table @kbd @kindex < -@item < -Scroll calendar backwards by one month. @kindex > -@item > -Scroll calendar forwards by one month. @kindex mouse-1 -@item mouse-1 -Select date by clicking on it. @kindex S-@key{right} -@item S-@key{right} -One day forward. @kindex S-@key{left} -@item S-@key{left} -One day back. @kindex S-@key{down} -@item S-@key{down} -One week forward. @kindex S-@key{up} -@item S-@key{up} -One week back. @kindex M-S-@key{right} -@item M-S-@key{right} -One month forward. @kindex M-S-@key{left} -@item M-S-@key{left} -One month back. @kindex @key{RET} -@item @key{RET} -Choose date in calendar (only if nothing was typed into minibuffer). -@end table +@example +> / < @r{Scroll calendar forward/backward by one month.} +mouse-1 @r{Select date by clicking on it.} +S-@key{right}/@key{left} @r{One day forward/backward.} +S-@key{down}/@key{up} @r{One week forward/backward.} +M-S-@key{right}/@key{left} @r{One month forward/backward.} +@key{RET} @r{Choose date in calendar.} +@end example + +The actions of the date/time prompt may seem complex, but I asure you +they will grow on you. To help you understand what is going on, the +current interpretation of your input will be displayed live in the +minibuffer@footnote{If you find this distracting, turn the display of +with @code{org-read-date-display-live}.}. @node Custom time format, , The date/time prompt, Creating timestamps @subsection Custom time format @@ -3953,20 +4161,23 @@ format is shorter, things do work as expected. @end itemize -@node Deadlines and scheduling, Progress logging, Creating timestamps, Timestamps +@node Deadlines and scheduling, Clocking work time, Creating timestamps, Dates and times @section Deadlines and Scheduling -A time stamp may be preceded by special keywords to facilitate planning -of work: +A time stamp may be preceded by special keywords to facilitate planning: @table @var @item DEADLINE @cindex DEADLINE keyword -The task (most likely a TODO item) is supposed to be finished on that -date, and it will be listed then. In addition, the compilation for -@emph{today} will carry a warning about the approaching or missed -deadline, starting @code{org-deadline-warning-days} before the due date, -and continuing until the entry is marked DONE. An example: + +Meaning: the task (most likely a TODO item, though not necessarily) is supposed +to be finished on that date. + +On the deadline date, the task will be listed in the agenda. In +addition, the agenda for @emph{today} will carry a warning about the +approaching or missed deadline, starting +@code{org-deadline-warning-days} before the due date, and continuing +until the entry is marked DONE. An example: @example *** TODO write article about the Earth for the Guide @@ -3980,9 +4191,12 @@ period of 5 days @code{DEADLINE: <2004-02-29 Sun -5d>}. @item SCHEDULED @cindex SCHEDULED keyword -You are planning to start working on that task on the given date. The -headline will be listed under the given date@footnote{It will still be -listed on that date after it has been marked DONE. If you don't like + +Meaning: you are planning to start working on that task on the given +date. + +The headline will be listed under the given date@footnote{It will still +be listed on that date after it has been marked DONE. If you don't like this, set the variable @code{org-agenda-skip-scheduled-if-done}.}. In addition, a reminder that the scheduled date has passed will be present in the compilation for @emph{today}, until the entry is marked DONE. @@ -3992,8 +4206,29 @@ I.e., the task will automatically be forwarded until completed. *** TODO Call Trillian for a date on New Years Eve. SCHEDULED: <2004-12-25 Sat> @end example + +@noindent +@b{Important:} Scheduling an item in Org-mode should @i{not} be +understood in the same way that we understand @i{scheduling a meeting}. +Setting a date for a meeting is just a simple appointment, you should +mark this entry with a simple plain time stamp, to get this item shown +on the date where it applies. This is a frequent mis-understanding from +Org-users. In Org-mode, @i{scheduling} means setting a date when you +want to start working on an action item. @end table +You may use time stamps with repeaters in scheduling and deadline +entries. Org-mode will issue early and late warnings based on the +assumption that the time stamp represents the @i{nearest instance} of +the repeater. However, the use of diary sexp entries like +@c +@code{<%%(diary-float t 42)>} +@c +in scheduling and deadline timestamps is limited. Org-mode does not +know enough about the internals of each sexp function to issue early and +late warnings. However, it will show the item on each day where the +sexp entry matches. + @menu * Inserting deadline/schedule:: Planning items * Repeated tasks:: Items that show up again and again @@ -4010,35 +4245,40 @@ an item: @kindex C-c C-d @item C-c C-d Insert @samp{DEADLINE} keyword along with a stamp. The insertion will -happen in the line directly following the headline. +happen in the line directly following the headline. When called with a +prefix arg, an existing deadline will be removed from the entry. @c FIXME Any CLOSED timestamp will be removed.???????? @c -@kindex C-c C-w +@kindex C-c / d @cindex sparse tree, for deadlines -@item C-c C-w +@item C-c / d Create a sparse tree with all deadlines that are either past-due, or which will become due within @code{org-deadline-warning-days}. With @kbd{C-u} prefix, show all deadlines in the file. With a numeric -prefix, check that many days. For example, @kbd{C-1 C-c C-w} shows +prefix, check that many days. For example, @kbd{C-1 C-c / d} shows all deadlines due tomorrow. @c @kindex C-c C-s @item C-c C-s Insert @samp{SCHEDULED} keyword along with a stamp. The insertion will happen in the line directly following the headline. Any CLOSED -timestamp will be removed. +timestamp will be removed. When called with a prefix argument, remove +the scheduling date from the entry. @end table @node Repeated tasks, , Inserting deadline/schedule, Deadlines and scheduling @subsection Repeated Tasks -Some tasks need to be repeated again and again, and Org-mode therefore -allows to use a repeater in a DEADLINE or SCHEDULED time stamp, for -example: +Some tasks need to be repeated again and again. Org-mode helps to +organize such tasks using a so-called repeater in a DEADLINE or +SCHEDULED time stamp. In the following example @example ** TODO Pay the rent DEADLINE: <2005-10-01 Sat +1m> @end example +the @code{+1m} is a repeater; the intended interpretation is that the +task has a deadline on <2005-10-01> and repeats itself every (one) month +starting from that time. Deadlines and scheduled items produce entries in the agenda when they are over-due, so it is important to be able to mark such an entry as @@ -4057,9 +4297,11 @@ actually switch the date like this: DEADLINE: <2005-11-01 Tue +1m> @end example -You will also be prompted for a note that will be put under the DEADLINE -line to keep a record that you actually acted on the previous instance -of this deadline. +You will also be prompted for a note@footnote{You can change this using +the option @code{org-log-repeat}, or the @code{#+STARTUP} options +@code{logrepeat} and @code{nologrepeat}.} that will be put under the +DEADLINE line to keep a record that you actually acted on the previous +instance of this deadline. As a consequence of shifting the base date, this entry will no longer be visible in the agenda when checking past dates, but all future instances @@ -4068,77 +4310,8 @@ will be visible. You may have both scheduling and deadline information for a specific task - just make sure that the repeater intervals on both are the same. -@node Progress logging, , Deadlines and scheduling, Timestamps -@section Progress Logging -@cindex progress logging -@cindex logging, of progress - -Org-mode can automatically record a time stamp when you mark a TODO item -as DONE, or even each time when you change the state of a TODO item. -You can also measure precisely the time you spent on specific items in a -project by starting and stopping a clock when you start and stop working -on an aspect of a project. - -@menu -* Closing items:: When was this entry marked DONE? -* Tracking TODO state changes:: When did the status change? -* Clocking work time:: When exactly did you work on this item? -@end menu - -@node Closing items, Tracking TODO state changes, Progress logging, Progress logging -@subsection Closing items - -If you want to keep track of @emph{when} a certain TODO item was -finished, turn on logging with@footnote{The corresponding in-buffer -setting is: @code{#+STARTUP: logdone}} - -@lisp -(setq org-log-done t) -@end lisp - -@noindent -Then each time you turn a TODO entry into DONE using either @kbd{C-c -C-t} in the Org-mode buffer or @kbd{t} in the agenda buffer, a line -@samp{CLOSED: [timestamp]} will be inserted just after the headline. If -you turn the entry back into a TODO item through further state cycling, -that line will be removed again. In the timeline (@pxref{Timeline}) and -in the agenda (@pxref{Weekly/Daily agenda}), you can then use the -@kbd{l} key to display the TODO items closed on each day, giving you an -overview of what has been done on a day. If you want to record a note -along with the timestamp, use@footnote{The corresponding in-buffer -setting is: @code{#+STARTUP: lognotedone}} - -@lisp -(setq org-log-done '(done)) -@end lisp - -@node Tracking TODO state changes, Clocking work time, Closing items, Progress logging -@subsection Tracking TODO state changes - -When TODO keywords are used as workflow states (@pxref{Workflow -states}), you might want to keep track of when a state change occurred, -and you may even want to attach notes to that state change. With the -setting - -@lisp -(setq org-log-done '(state)) -@end lisp - -@noindent -each state change will prompt you for a note that will be attached to -the current headline. Very likely you do not want this verbose tracking -all the time, so it is probably better to configure this behavior with -in-buffer options. For example, if you are tracking purchases, put -these into a separate file that starts with: - -@example -#+SEQ_TODO: TODO ORDERED INVOICE PAYED RECEIVED SENT -#+STARTUP: lognotestate -@end example - - -@node Clocking work time, , Tracking TODO state changes, Progress logging -@subsection Clocking work time +@node Clocking work time, , Deadlines and scheduling, Dates and times +@section Clocking work time Org-mode allows you to clock the time you spent on specific tasks in a project. When you start working on an item, you can start the clock. @@ -4150,7 +4323,10 @@ also computes the total time spent on each subtree of a project. @kindex C-c C-x C-i @item C-c C-x C-i Start the clock on the current item (clock-in). This inserts the CLOCK -keyword together with a timestamp. +keyword together with a timestamp. If this is not the first clocking of +this item, the multiple CLOCK lines will be wrapped into a +@code{:CLOCK:} drawer (see also the variable +@code{org-clock-into-drawer}. @kindex C-c C-x C-o @item C-c C-x C-o Stop the clock (clock-out). The inserts another timestamp at the same @@ -4173,6 +4349,10 @@ if it is running in this same item. @item C-c C-x C-x Cancel the current clock. This is useful if a clock was started by mistake, or if you ended up working on something else. +@kindex C-c C-x C-j +@item C-c C-x C-j +Jump to the entry that contains the currently running clock, an another +window. @kindex C-c C-x C-d @item C-c C-x C-d Display time summaries for each subtree in the current buffer. This @@ -4184,18 +4364,29 @@ when you change the buffer (see variable @kindex C-c C-x C-r @item C-c C-x C-r Insert a dynamic block (@pxref{Dynamic blocks}) containing a clock -report as an org-mode table into the current file. +report as an org-mode table into the current file. When the cursor is +at an existing clock table, just update it. When called with a prefix +argument, jump to the first clock report in the current document and +update it. @example -#+BEGIN: clocktable :maxlevel 2 :emphasize nil +#+BEGIN: clocktable :maxlevel 2 :emphasize nil :scope file #+END: clocktable @end example @noindent -If such a block already exists, its content is replaced by the new -table. The @samp{BEGIN} line can specify options: +If such a block already exists at point, its content is replaced by the +new table. The @samp{BEGIN} line can specify options: @example -:maxlevels @r{Maximum level depth to which times are listed in the table.} +:maxlevel @r{Maximum level depth to which times are listed in the table.} :emphasize @r{When @code{t}, emphasize level one and level two items} +:scope @r{The scope to consider. This can be any of the following:} + nil @r{the current buffer or narrowed region} + file @r{the full current buffer} + subtree @r{the subtree where the clocktable is located} + treeN @r{the surrounding level N tree, for example @code{tree3}} + tree @r{the surrounding level 1 tree} + agenda @r{all agenda files} + ("file"..) @r{scan these files} :block @r{The time block to consider. This block is specified relative} @r{to the current time and may be any of these keywords:} @r{@code{today}, @code{yesterday}, @code{thisweek}, @code{lastweek},} @@ -4203,9 +4394,10 @@ table. The @samp{BEGIN} line can specify options: :tstart @r{A time string specifying when to start considering times} :tend @r{A time string specifying when to stop considering times} @end example -So to get a clock summary for the current day, you could write +So to get a clock summary of the current level 1 tree, for the current +day, you could write @example -#+BEGIN: clocktable :maxlevel 2 :block today +#+BEGIN: clocktable :maxlevel 2 :block today :scope tree1 #+END: clocktable @end example @@ -4218,6 +4410,12 @@ only to fit it onto the manual.} #+END: clocktable @end example +@kindex C-c C-c +@item C-c C-c +@kindex C-c C-x C-u +@itemx C-c C-x C-u +Update dynamical block at point. The cursor needs to be in the +@code{#+BEGIN} line of the dynamic block. @kindex C-u C-c C-x C-u @item C-u C-c C-x C-u Update all dynamic blocks (@pxref{Dynamic blocks}). This is useful if @@ -4228,14 +4426,230 @@ The @kbd{l} key may be used in the timeline (@pxref{Timeline}) and in the agenda (@pxref{Weekly/Daily agenda}) to show which tasks have been worked on or closed during a day. -@node Agenda views, Embedded LaTeX, Timestamps, Top +@node Remember, Agenda views, Dates and times, Top +@chapter Remember +@cindex @file{remember.el} + +The @i{Remember} package by John Wiegley lets you store quick notes with +little interruption of your work flow. See +@uref{http://www.emacswiki.org/cgi-bin/wiki/RememberMode} for more +information. It is an excellent way to add new notes and tasks to +Org-mode files. Org-mode significantly expands the possibilities of +@i{remember}: You may define templates for different note types, and +associate target files and headlines with specific templates. It also +allows you to select the location where a note should be stored +interactively, on the fly. + +@menu +* Setting up remember:: Some code for .emacs to get things going +* Remember templates:: Define the outline of different note types +* Storing notes:: Directly get the note to where it belongs +* Refiling notes:: Moving a note or task to a project +@end menu + +@node Setting up remember, Remember templates, Remember, Remember +@section Setting up remember + +The following customization will tell @i{remember} to use org files as +target, and to create annotations compatible with Org-mode links. + +@example +(org-remember-insinuate) +(setq org-directory "~/path/to/my/orgfiles/") +(setq org-default-notes-file (concat org-directory "/notes.org")) +(define-key global-map "\C-cr" 'org-remember) +@end example + +The last line binds the command @code{org-remember} to a global +key@footnote{Please select your own key, @kbd{C-c r} is only a +suggestion.}. @code{org-remember} basically just calls @code{remember}, +but it makes a few things easier: If there is an active region, it will +automatically copy the region into the remember buffer. It also allows +to jump to the buffer and location where remember notes are being +stored: Just call @code{org-remember} with a prefix argument. + +@node Remember templates, Storing notes, Setting up remember, Remember +@section Remember templates +@cindex templates, for remember + +In combination with Org-mode, you can use templates to generate +different types of @i{remember} notes. For example, if you would like +to use one template to create general TODO entries, another one for +journal entries, and a third one for collecting random ideas, you could +use: + +@example +(setq org-remember-templates + '(("Todo" ?t "* TODO %?\n %i\n %a" "~/org/TODO.org" "Tasks") + ("Journal" ?j "* %U %?\n\n %i\n %a" "~/org/JOURNAL.org") + ("Idea" ?i "* %^@{Title@}\n %i\n %a" "~/org/JOURNAL.org" "New Ideas"))) +@end example + +@noindent In these entries, the first string is just a name, and the +character specifies how to select the template. It is useful if the +character is also the first letter of the name. The next string +specifies the template. Two more (optional) strings give the file in +which, and the headline under which the new note should be stored. The +file (if not present or @code{nil}) defaults to +@code{org-default-notes-file}, the heading to +@code{org-remember-default-headline}. + +When you call @kbd{M-x remember} (or @kbd{M-x org-remember}) to remember +something, org will prompt for a key to select the template (if you have +more than one template) and then prepare the buffer like +@example +* TODO + [[file:link to where you called remember]] +@end example + +@noindent +During expansion of the template, special @kbd{%}-escapes allow dynamic +insertion of content: +@example +%^@{prompt@} @r{prompt the user for a string and replace this sequence with it.} + @r{You may specify a default value and a completion table with} + @r{%^@{prompt|default|completion2|completion3...@}} + @r{The arrow keys access a prompt-specific history.} +%t @r{time stamp, date only} +%T @r{time stamp with date and time} +%u, %U @r{like the above, but inactive time stamps} +%^t @r{like @code{%t}, but prompt for date. Similarly @code{%^T}, @code{%^u}, @code{%^U}} + @r{You may define a prompt like @code{%^@{Birthday@}t}} +%n @r{user name (taken from @code{user-full-name})} +%a @r{annotation, normally the link created with @code{org-store-link}} +%A @r{like @code{%a}, but prompt for the description part} +%i @r{initial content, the region when remember is called with C-u.} + @r{The entire text will be indented like @code{%i} itself.} +%c @r{Content of the clipboard, or current kill ring head.} +%^g @r{prompt for tags, with completion on tags in target file.} +%^G @r{prompt for tags, with completion all tags in all agenda files.} +%:keyword @r{specific information for certain link types, see below} +%[pathname] @r{insert the contents of the file given by @code{pathname}} +%(sexp) @r{evaluate elisp @code{(sexp)} and replace with the result} +%! @r{immediately store note after completing the template} + @r{(skipping the @kbd{C-c C-c} that normally triggers storing)} +@end example + +@noindent +For specific link types, the following keywords will be +defined@footnote{If you define your own link types (@pxref{Adding +hyperlink types}), any property you store with +@code{org-store-link-props} can be accessed in remember templates in a +similar way.}: + +@example +Link type | Available keywords +-------------------+---------------------------------------------- +bbdb | %:name %:company +vm, wl, mh, rmail | %:type %:subject %:message-id + | %:from %:fromname %:fromaddress + | %:to %:toname %:toaddress + | %:fromto @r{(either "to NAME" or "from NAME")@footnote{This will always be the other, not the user. See the variable @code{org-from-is-user-regexp}.}} +gnus | %:group, @r{for messages also all email fields} +w3, w3m | %:url +info | %:file %:node +calendar | %:date" +@end example + +@noindent +To place the cursor after template expansion use: + +@example +%? @r{After completing the template, position cursor here.} +@end example + +@noindent +If you change you mind about which template to use, call +@code{org-remember} in the remember buffer. You may then select a new +template that will be filled with the previous context information. + +@node Storing notes, Refiling notes, Remember templates, Remember +@section Storing notes + +When you are finished preparing a note with @i{remember}, you have to +press @kbd{C-c C-c} to file the note away. The handler will store the +note in the file and under the headline specified in the template, or it +will use the default file and headlines. The window configuration will +be restored, sending you back to the working context before the call to +@code{remember}. To re-use the location found during the last call to +@code{remember}, exit the remember buffer with @kbd{C-u C-u C-c C-c}, +i.e. specify a double prefix argument to @kbd{C-c C-c}. + +If you want to store the note directly to a different place, use +@kbd{C-u C-c C-c} instead to exit remember@footnote{Configure the +variable @code{org-remember-store-without-prompt} to make this behavior +the default.}. The handler will then first prompt for a target file - +if you press @key{RET}, the value specified for the template is used. +Then the command offers the headings tree of the selected file, with the +cursor position at the default headline (if you had specified one in the +template). You can either immediately press @key{RET} to get the note +placed there. Or you can use the following keys to find a different +location: +@example +@key{TAB} @r{Cycle visibility.} +@key{down} / @key{up} @r{Next/previous visible headline.} +n / p @r{Next/previous visible headline.} +f / b @r{Next/previous headline same level.} +u @r{One level up.} +@c 0-9 @r{Digit argument.} +@end example +@noindent +Pressing @key{RET} or @key{left} or @key{right} +then leads to the following result. + +@multitable @columnfractions 0.2 0.15 0.65 +@item @b{Cursor position} @tab @b{Key} @tab @b{Note gets inserted} +@item on headline @tab @key{RET} @tab as sublevel of the heading at cursor, first or last +@item @tab @tab depending on @code{org-reverse-note-order}. +@item @tab @key{left}/@key{right} @tab as same level, before/after current heading +@item buffer-start @tab @key{RET} @tab as level 2 heading at end of file or level 1 at beginning +@item @tab @tab depending on @code{org-reverse-note-order}. +@item not on headline @tab @key{RET} + @tab at cursor position, level taken from context. +@end multitable + +Before inserting the text into a tree, the function ensures that the +text has a headline, i.e. a first line that starts with a @samp{*}. If +not, a headline is constructed from the current date and some additional +data. If you have indented the text of the note below the headline, the +indentation will be adapted if inserting the note into the tree requires +demotion from level 1. + +@node Refiling notes, , Storing notes, Remember +@section Refiling notes +@cindex refiling notes + +Remember is usually used to quickly capture notes and tasks into one or +a few capture lists. When reviewing the captured data, you may want to +refile some of the entries into a different list, for example into a +project. Cutting, finding the right location and then pasting the note +is cumbersome. To simplify this process, you can use the following +special command: + +@table @kbd +@kindex C-c C-w +@item C-c C-w +Refile the entry at point. This command offers possible locations for +refiling the entry and lets you select one with completion. The item is +filed below the target heading as a subitem. Depending on +@code{org-reverse-note-order}, it will be either the first of last +subitem, and you can toggle the value of this variable for the duration +of the command by using a @kbd{C-u} prefix.@* By default, all level 1 +headlines in the current buffer are considered to be targets, but you +can have more complex definitions across a number of files. See the +variable @code{org-refile-targets} for details. The list of targets is +compiled upon first use, you can update it by using a double prefix +argument (@kbd{C-u C-u}) to this command. +@end table + +@node Agenda views, Embedded LaTeX, Remember, Top @chapter Agenda Views @cindex agenda views Due to the way Org-mode works, TODO items, time-stamped items, and tagged headlines can be scattered throughout a file or even a number of -files. To get an overview over open action items, or over events that -are important for a particular date, this information must be collected, +files. To get an overview of open action items, or of events that are +important for a particular date, this information must be collected, sorted and displayed in an organized way. Org-mode can select items based on various criteria, and display them @@ -4287,14 +4701,18 @@ window configuration is restored when the agenda exits: @cindex agenda files @cindex files for agenda -The information to be shown is collected from all @emph{agenda files}, -the files listed in the variable @code{org-agenda-files}@footnote{If the -value of that variable is not a list, but a single file name, then the -list of agenda files will be maintained in that external file.}. Thus even -if you only work with a single Org-mode file, this file should be put -into that list@footnote{When using the dispatcher, pressing @kbd{1} -before selecting a command will actually limit the command to the -current file, and ignore @code{org-agenda-files} until the next +The information to be shown is normally collected from all @emph{agenda +files}, the files listed in the variable +@code{org-agenda-files}@footnote{If the value of that variable is not a +list, but a single file name, then the list of agenda files will be +maintained in that external file.}. If a directory is part of this list, +all files with the extension @file{.org} in this directory will be part +of the list. + +Thus even if you only work with a single Org-mode file, this file should +be put into that list@footnote{When using the dispatcher, pressing +@kbd{<} before selecting a command will actually limit the command to +the current file, and ignore @code{org-agenda-files} until the next dispatcher command.}. You can customize @code{org-agenda-files}, but the easiest way to maintain it is through the following commands @@ -4319,6 +4737,42 @@ Cycle through agenda file list, visiting one file after the other. The Org menu contains the current list of files and can be used to visit any of them. +If you would like to focus the agenda temporarily onto a file not in +this list, or onto just one file in the list or even only a subtree in a +file, this can be done in different ways. For a single agenda command, +you may press @kbd{<} once or several times in the dispatcher +(@pxref{Agenda dispatcher}). To restrict the agenda scope for an +extended period, use the following commands: + +@table @kbd +@kindex C-c C-x < +@item C-c C-x < +Permanently restrict the agenda to the current subtree. When with a +prefix argument, or with the cursor before the first headline in a file, +the agenda scope is set to the entire file. This restriction remains in +effect until removed with @kbd{C-c C-x >}, or by typing either @kbd{<} +or @kbd{>} in the agenda dispatcher. If there is a window displaying an +agenda view, the new restriction takes effect immediately. +@kindex C-c C-x < +@item C-c C-x < +Remove the permanent restriction created by @kbd{C-c C-x <}. +@end table + +@noindent +When working with @file{Speedbar}, you can use the following commands in +the speedbar frame: +@table @kbd +@kindex < +@item < @r{in the speedbar frame} +Permanently restrict the agenda to the item at the cursor in the +speedbar frame, either an Org-mode file or a subtree in such a file. +If there is a window displaying an agenda view, the new restriction takes +effect immediately. +@kindex < +@item > @r{in the speedbar frame} +Lift the restriction again. +@end table + @node Agenda dispatcher, Built-in agenda views, Agenda files, Agenda views @section The agenda dispatcher @cindex agenda dispatcher @@ -4341,14 +4795,23 @@ tags and properties}). Create the timeline view for the current buffer (@pxref{Timeline}). @item # @r{/} ! Create a list of stuck projects (@pxref{Stuck projects}). -@item 1 -Restrict an agenda command to the current buffer. After pressing -@kbd{1}, you still need to press the character selecting the command. -@item 0 +@item / +Search for a regular expression in all agenda files and additionally in +the files listed in @code{org-agenda-multi-occur-extra-files}. This +uses the Emacs command @code{multi-occur}. A prefix argument can be +used to specify the number of context lines for each match, default is +1. +@item < +Restrict an agenda command to the current buffer@footnote{For backward +compatibility, you can also press @kbd{1} to restrict to the current +buffer.}. After pressing @kbd{<}, you still need to press the character +selecting the command. +@item < < If there is an active region, restrict the following agenda command to -the region. Otherwise, restrict it to the current subtree. After -pressing @kbd{0}, you still need to press the character selecting the -command. +the region. Otherwise, restrict it to the current subtree@footnote{For +backward compatibility, you can also press @kbd{0} to restrict to the +current buffer.}. After pressing @kbd{< <}, you still need to press the +character selecting the command. @end table You can also define custom commands that will be accessible through the @@ -4384,10 +4847,12 @@ paper agenda, showing all the tasks for the current week or day. @kindex C-c a a @item C-c a a Compile an agenda for the current week from a list of org files. The -agenda shows the entries for each day. With a @kbd{C-u} prefix (or -when the variable @code{org-agenda-include-all-todo} is @code{t}), all -unfinished TODO items (including those without a date) are also listed at -the beginning of the buffer, before the first date.@* +agenda shows the entries for each day. With a numeric +prefix@footnote{For backward compatibility, the universal prefix +@kbd{C-u} causes all TODO entries to be listed before the agenda. This +feature is deprecated, use the dedicated TODO list, or a block agenda +instead.} (like @kbd{C-u 2 1 C-c a a}) you may set the number of days +to be displayed (see also the variable @code{org-agenda-ndays}) @end table Remote editing from the agenda buffer means, for example, that you can @@ -4443,6 +4908,18 @@ will be made in the agenda: %%(diary-anniversary 2 10 1869) Mahatma Gandhi would be %d years old @end example +@subsubheading Appointment reminders +@cindex @file{appt.el} +@cindex appointment reminders + +Org can interact with Emacs appointments notification facility. + +To add all the appointments of your agenda files, use the command +@code{org-agenda-to-appt}. This commands also lets you filter through +the list of your appointments and add only those belonging to a specific +category or matching a regular expression. See the docstring for +details. + @node Global TODO list, Matching tags and properties, Weekly/Daily agenda, Built-in agenda views @subsection The global TODO list @cindex global TODO list @@ -4512,8 +4989,8 @@ to them and collect them into an agenda buffer. @item C-c a m Produce a list of all headlines that match a given set of tags. The command prompts for a selection criterion, which is a boolean logic -expression with tags, like @samp{+WORK+URGENT-WITHBOSS} or -@samp{WORK|HOME} (@pxref{Tags}). If you often need a specific search, +expression with tags, like @samp{+work+urgent-withboss} or +@samp{work|home} (@pxref{Tags}). If you often need a specific search, define a custom command for it (@pxref{Agenda dispatcher}). @kindex C-c a M @item C-c a M @@ -4616,16 +5093,27 @@ associated with the item. @cindex category The category is a broad label assigned to each agenda item. By default, the category is simply derived from the file name, but you can also -specify it with a special line in the buffer, like this: +specify it with a special line in the buffer, like this@footnote{For +backward compatibility, the following also works: If there are several +such lines in a file, each specifies the category for the text below it. +The first category also applies to any text before the first CATEGORY +line. However, using this method is @emph{strongly} deprecated as it is +incompatible with the outline structure of the document. The correct +method for setting multiple categories in a buffer is using a +property.}: @example #+CATEGORY: Thesis @end example -If there are several such lines in a file, each specifies the category -for the text below it (but the first category also applies to any text -before the first CATEGORY line). The display in the agenda buffer looks -best if the category is not longer than 10 characters. +@noindent +If you would like to have a special CATEGORY for a single entry or a +(sub)tree, give the entry a @code{:CATEGORY:} property with the location +as the value (@pxref{Properties and columns}). + +@noindent +The display in the agenda buffer looks best if the category is not +longer than 10 characters. @node Time-of-day specifications, Sorting of agenda items, Categories, Presentation and sorting @subsection Time-of-Day Specifications @@ -4725,10 +5213,10 @@ the other commands, the cursor needs to be in the desired line. @cindex motion commands in agenda @kindex n @item n -Next line (same as @key{up}). +Next line (same as @key{up} and @kbd{C-p}). @kindex p @item p -Previous line (same as @key{down}). +Previous line (same as @key{down} and @kbd{C-n}). @tsubheading{View/GoTo org file} @kindex mouse-3 @kindex @key{SPC} @@ -4807,7 +5295,9 @@ argument is interpreted to create a selective list for a specific TODO keyword. @c @kindex s +@kindex C-x C-s @item s +@itemx C-x C-s Save all Org-mode buffers in the current Emacs session. @c @kindex @key{right} @@ -4860,7 +5350,8 @@ inheritance, this may be more than the tags listed in the line itself. @c @kindex : @item : -Set tags for the current headline. +Set tags for the current headline. If there is an active region in the +agenda, change a tag for all headings in the region. @c @kindex a @item a @@ -4931,6 +5422,10 @@ Stop the previously started clock. @item X Cancel the currently running clock. +@kindex J +@item J +Jump to the running clock in another window. + @tsubheading{Calendar commands} @cindex calendar commands, from agenda @kindex c @@ -5035,19 +5530,28 @@ search types: (setq org-agenda-custom-commands '(("w" todo "WAITING") ("W" todo-tree "WAITING") - ("u" tags "+BOSS-URGENT") - ("v" tags-todo "+BOSS-URGENT") - ("U" tags-tree "+BOSS-URGENT") - ("f" occur-tree "\\"))) + ("u" tags "+boss-urgent") + ("v" tags-todo "+boss-urgent") + ("U" tags-tree "+boss-urgent") + ("f" occur-tree "\\") + ("h" . "HOME+Name tags searches") ; description for "h" prefix + ("hl" tags "+home+Lisa") + ("hp" tags "+home+Peter") + ("hk" tags "+home+Kim"))) @end group @end lisp @noindent -The initial single-character string in each entry defines the character -you have to press after the dispatcher command @kbd{C-c a} in order to -access the command. The second parameter is the search type, followed -by the string or regular expression to be used for the matching. The -example above will therefore define: +The initial string in each entry defines the keys you have to press +after the dispatcher command @kbd{C-c a} in order to access the command. +Usually this will be just a single character, but if you have many +similar commands, you can also define two-letter combinations where the +first character is the same in several combinations and serves as a +prefix key@footnote{You can provide a description for a prefix key by +inserting a cons cell with the prefix and the description.}. The second +parameter is the search type, followed by the string or regular +expression to be used for the matching. The example above will +therefore define: @table @kbd @item C-c a w @@ -5057,8 +5561,8 @@ keyword as the same search, but only in the current buffer and displaying the results as a sparse tree @item C-c a u -as a global tags search for headlines marked @samp{:BOSS:} but not -@samp{:URGENT:} +as a global tags search for headlines marked @samp{:boss:} but not +@samp{:urgent:} @item C-c a v as the same search as @kbd{C-c a u}, but limiting the search to headlines that are also TODO items @@ -5067,7 +5571,11 @@ as the same search as @kbd{C-c a u}, but only in the current buffer and displaying the result as a sparse tree @item C-c a f to create a sparse tree (again: current buffer only) with all entries -containing the word @samp{FIXME}. +containing the word @samp{FIXME} +@item C-c a h +as a prefix command for a HOME tags search where you have to press an +additional key (@kbd{l}, @kbd{p} or @kbd{k}) to select a name (Lisa, +Peter, or Kim) as additional tag to match. @end table @node Block agenda, Setting Options, Storing searches, Custom agenda views @@ -5088,12 +5596,12 @@ matching commands discussed above: @code{todo}, @code{tags}, and (setq org-agenda-custom-commands '(("h" "Agenda and Home-related tasks" ((agenda) - (tags-todo "HOME") - (tags "GARDEN"))) + (tags-todo "home") + (tags "garden"))) ("o" "Agenda and Office-related tasks" ((agenda) - (tags-todo "WORK") - (tags "OFFICE"))))) + (tags-todo "work") + (tags "office"))))) @end group @end lisp @@ -5101,7 +5609,7 @@ matching commands discussed above: @code{todo}, @code{tags}, and This will define @kbd{C-c a h} to create a multi-block view for stuff you need to attend to at home. The resulting agenda buffer will contain your agenda for the current week, all TODO items that carry the tag -@samp{HOME}, and also all lines tagged with @samp{GARDEN}. Finally the +@samp{home}, and also all lines tagged with @samp{garden}. Finally the command @kbd{C-c a o} provides a similar view for office tasks. @@ -5122,7 +5630,7 @@ right spot in @code{org-agenda-custom-commands}. For example: '(("w" todo "WAITING" ((org-agenda-sorting-strategy '(priority-down)) (org-agenda-prefix-format " Mixed: "))) - ("U" tags-tree "+BOSS-URGENT" + ("U" tags-tree "+boss-urgent" ((org-show-following-heading nil) (org-show-hierarchy-above nil))))) @end group @@ -5130,7 +5638,7 @@ right spot in @code{org-agenda-custom-commands}. For example: @noindent Now the @kbd{C-c a w} command will sort the collected entries only by -priority, and the prefix format is modified to just say @samp{ Mixed:} +priority, and the prefix format is modified to just say @samp{ Mixed: } instead of giving the category of the entry. The sparse tags tree of @kbd{C-c a U} will now turn out ultra-compact, because neither the headline hierarchy above the match, nor the headline following the match @@ -5152,14 +5660,14 @@ the results for GARDEN tags query in the opposite order, (setq org-agenda-custom-commands '(("h" "Agenda and Home-related tasks" ((agenda) - (tags-todo "HOME") - (tags "GARDEN" + (tags-todo "home") + (tags "garden" ((org-agenda-sorting-strategy '(priority-up))))) ((org-agenda-sorting-strategy '(priority-down)))) ("o" "Agenda and Office-related tasks" ((agenda) - (tags-todo "WORK") - (tags "OFFICE"))))) + (tags-todo "work") + (tags "office"))))) @end group @end lisp @@ -5218,14 +5726,14 @@ or absolute. ("Y" alltodo "" nil ("todo.html" "todo.txt" "todo.ps")) ("h" "Agenda and Home-related tasks" ((agenda) - (tags-todo "HOME") - (tags "GARDEN")) + (tags-todo "home") + (tags "garden")) nil ("~/views/home.html")) ("o" "Agenda and Office-related tasks" ((agenda) - (tags-todo "WORK") - (tags "OFFICE")) + (tags-todo "work") + (tags "office")) nil ("~/views/office.ps")))) @end group @@ -5283,6 +5791,7 @@ or, if you need to modify some parameters @example emacs -eval '(org-batch-store-agenda-views \ org-agenda-ndays 30 \ + org-agenda-start-day "2007-11-01" \ org-agenda-include-diary nil \ org-agenda-files (quote ("~/org/project.org")))' \ -kill @@ -5665,7 +6174,8 @@ will be @file{myfile.txt}. The file will be overwritten without warning. If there is an active region, only the region will be exported. If the selected region is a single tree, the tree head will become the document title. If the tree head entry has or inherits an -EXPORT_FILE_NAME property, that name will be used for the export. +@code{:EXPORT_FILE_NAME:} property, that name will be used for the +export. @kindex C-c C-e v a @item C-c C-e v a Export only the visible part of the document. @@ -5720,8 +6230,8 @@ Export as HTML file @file{myfile.html}. For an org file will be overwritten without warning. If there is an active region, only the region will be exported. If the selected region is a single tree, the tree head will become the document title. If the tree head entry -has or inherits an EXPORT_FILE_NAME property, that name will be used for -the export. +has or inherits an @code{:EXPORT_FILE_NAME:} property, that name will be +used for the export. @kindex C-c C-e b @item C-c C-e b Export as HTML file and immediately open it with a browser. @@ -5729,7 +6239,7 @@ Export as HTML file and immediately open it with a browser. @item C-c C-e H Export to a temporary buffer, do not create a file. @kindex C-c C-e R -@item C-c C-e H +@item C-c C-e R Export the active region to a temporary buffer. With prefix arg, do not produce file header and foot, but just the plain HTML section for the region. This is good for cut-and-paste operations. @@ -5877,6 +6387,7 @@ Org-mode contains a La@TeX{} exporter written by Bastien Guerry. @menu * LaTeX export commands:: How to invoke LaTeX export * Quoting LaTeX code:: Incorporating literal LaTeX code +* Sectioning structure:: @end menu @node LaTeX export commands, Quoting LaTeX code, LaTeX export, LaTeX export @@ -5920,7 +6431,7 @@ with a prefix argument. For example, @noindent creates two levels of headings and does the rest as items. -@node Quoting LaTeX code, , LaTeX export commands, LaTeX export +@node Quoting LaTeX code, Sectioning structure, LaTeX export commands, LaTeX export @subsection Quoting LaTeX code Embedded La@TeX{} as described in @ref{Embedded LaTeX} will be correctly @@ -5939,6 +6450,23 @@ constructs: All lines between these markers are exported literally #+END_LaTeX @end example + + + +@node Sectioning structure, , Quoting LaTeX code, LaTeX export +@subsection Sectioning structure +@cindex LaTeX class +@cindex LaTeX sectioning structure + +By default, the La@TeX{} output uses the class @code{article}. + +You can change this globally by setting a different value for +@code{org-export-latex-default-class} or locally by adding an option +like @code{#+LaTeX_CLASS: myclass} in your file. The class should be +listed in @code{org-export-latex-classes}, where you can also define the +sectioning structure for each class. + + @node XOXO export, iCalendar export, LaTeX export, Exporting @section XOXO export @cindex XOXO export @@ -5985,6 +6513,11 @@ Create a single large iCalendar file from all files in @code{org-combined-agenda-icalendar-file}. @end table +The export will honor SUMMARY, DESCRIPTION and LOCATION properties if +the selected entries have them. If not, the summary will be derived +from the headline, and the description from the body (limited to +@code{org-icalendar-include-body} characters). + How this calendar is best read and updated, depends on the application you are using. The FAQ covers this issue. @@ -5999,6 +6532,7 @@ in order to produce better output. * Comment lines:: Some lines will not be exported * Initial text:: Text before the first headline * Footnotes:: Numbers like [1] +* Quoted examples:: Inserting quoted chnuks of text * Enhancing text:: Subscripts, symbols and more * Export options:: How to influence the export settings @end menu @@ -6056,7 +6590,7 @@ construct: #+TEXT: This goes between the table of contents and the first headline @end example -@node Footnotes, Enhancing text, Initial text, Text interpretation +@node Footnotes, Quoted examples, Initial text, Text interpretation @subsection Footnotes @cindex footnotes @cindex @file{footnote.el} @@ -6068,7 +6602,7 @@ the Emacs package @file{footnote.el} to create footnotes. For example: The org-mode homepage[1] clearly needs help from a good web designer. -[1] The link is: http://www.astro.uva.nl/~dominik/Tools/org +[1] The link is: http://orgmode.org @end example @noindent @@ -6081,14 +6615,48 @@ if you are too used to this binding, you could use @code{org-replace-disputed-keys} and @code{org-disputed-keys} to change the settings in Org-mode. -@node Enhancing text, Export options, Footnotes, Text interpretation +@node Quoted examples, Enhancing text, Footnotes, Text interpretation +@subsection Quoted examples +@cindex quoted examples +@cindex examples, quoted +@cindex text, fixed width +@cindex fixed width text + +When writing technical documents, you often need to insert examples that +are not further interpreted by Org-mode. For historical reasons, there +are several ways to do this: + +@itemize @bullet +@item +If a headline starts with the word @samp{QUOTE}, the text below the +headline will be typeset as fixed-width, to allow quoting of computer +codes etc. +@item +Lines starting with @samp{:} are also typeset in fixed-width font. +@table @kbd +@kindex C-c : +@item C-c : +Toggle fixed-width for entry (QUOTE) or region, see below. +@end table +@item +Finally, text between +@example +#+BEGIN_EXAMPLE +quoted text +#+END_EXAMPLE +@end example +will also be exported in this way. +@end itemize + + +@node Enhancing text, Export options, Quoted examples, Text interpretation @subsection Enhancing text for export @cindex enhancing text @cindex richer text Some of the export backends of Org-mode allow for sophisticated text formatting, this is true in particular for the HTML and La@TeX{} -backends. Org-mode has a number of typing conventions that allow to +backends. Org-mode has a number of typing conventions that allow to produce a richly formatted output. @itemize @bullet @@ -6103,11 +6671,12 @@ backend supports lists. See @xref{Plain lists}. @cindex underlined text @cindex bold text @cindex italic text +@cindex verbatim text @item -You can make words @b{*bold*}, @i{/italic/}, _underlined_, -@code{=code=}, and even @samp{+strikethrough+}@footnote{but remember -that strikethrough is typographically evil and should @i{never} be -used.}. +You can make words @b{*bold*}, @i{/italic/}, _underlined_, @code{=code=} +and @code{~verbatim~}, and, if you must, @samp{+strikethrough+}. Text +in the code and verbatim string is not processed for org-mode specific +syntax, it is exported verbatim. @cindex horizontal rules, in exported files @item @@ -6137,11 +6706,27 @@ font. @item C-c : Toggle fixed-width for entry (QUOTE) or region, see below. @end table +Finally, text between +@example +#+BEGIN_EXAMPLE +quoted text +#+END_EXAMPLE +@end example +will also be exported in this way. @cindex linebreak, forced @item A double backslash @emph{at the end of a line} enforces a line break at this position. + +@cindex HTML entities, LaTeX entities +@item +Strings like @code{\alpha} will be exported as @code{α}, in the +HTML output. These strings are exported as @code{$\alpha$} in the +La@TeX{} output. Similarly, @code{\nbsp} will become @code{ } in +HTML and in La@TeX{}. This applies for a long list of entities, see +the variable @code{org-html-entities} for the complete list. +@c FIXME @end itemize If these conversions conflict with your habits of typing ASCII text, @@ -6172,6 +6757,7 @@ Insert template with export options, see example below. @example #+TITLE: the title to be shown (default is the buffer name) #+AUTHOR: the author (default taken from @code{user-full-name}) +#+DATE: A date, fixed, of a format string for @code{format-time-string} #+EMAIL: his/her email address (default from @code{user-mail-address}) #+LANGUAGE: language for HTML, e.g. @samp{en} (@code{org-export-default-language}) #+TEXT: Some descriptive text to be inserted at the beginning. @@ -6191,6 +6777,7 @@ you can: @cindex tables @cindex @TeX{}-like syntax for sub- and superscripts @cindex footnotes +@cindex special strings @cindex emphasized text @cindex @TeX{} macros @cindex La@TeX{} fragments @@ -6207,6 +6794,7 @@ toc: @r{turn on/off table of contents, or set level limit (integer)} ^: @r{turn on/off @TeX{}-like syntax for sub- and superscripts. If} @r{you write "^:@{@}", @code{a_@{b@}} will be interpreted, but} @r{the simple @code{a_b} will be left as it is.} +-: @r{turn on/off conversion of special strings.} f: @r{turn on/off foototes like this[1].} *: @r{turn on/off emphasized text (bold, italic, underlined)} TeX: @r{turn on/off simple @TeX{} macros in plain text} @@ -6214,6 +6802,7 @@ LaTeX: @r{turn on/off La@TeX{} fragments} skip: @r{turn on/off skipping the text before the first heading} author: @r{turn on/off inclusion of author name/email into exported file} timestamp: @r{turn on/off inclusion creation time into exported file} +d: @r{turn on/off inclusion of drawers} @end example These options take effect in both the HTML and La@TeX{} export, except @@ -6274,11 +6863,11 @@ Each element of the list configures one project, and may be in one of the two following forms: @lisp -("project-name" :property value :property value ...) +("project-name" :property value :property value ...) @r{or} -("project-name" :components ("project-name" "project-name" ...)) +("project-name" :components ("project-name" "project-name" ...)) @end lisp @@ -6378,6 +6967,7 @@ respective variable for details. @item @code{:archived-trees} @tab @code{org-export-with-archived-trees} @item @code{:emphasize} @tab @code{org-export-with-emphasize} @item @code{:sub-superscript} @tab @code{org-export-with-sub-superscripts} +@item @code{:special-strings} @tab @code{org-export-with-special-strings} @item @code{:TeX-macros} @tab @code{org-export-with-TeX-macros} @item @code{:LaTeX-fragments} @tab @code{org-export-with-LaTeX-fragments} @item @code{:fixed-width} @tab @code{org-export-with-fixed-width} @@ -6399,14 +6989,16 @@ respective variable for details. @item @code{:email} @tab @code{user-mail-address} @end multitable +If you use several email addresses, separate them by a semi-column. + Most of the @code{org-export-with-*} variables have the same effect in both HTML and La@TeX{} exporters, except for @code{:TeX-macros} and @code{:LaTeX-fragments}, respectively @code{nil} and @code{t} in the La@TeX{} export. -When a property is given a value in org-publish-project-alist, its -setting overrides the value of the corresponding user variable (if any) -during publishing. Options set within a file (@pxref{Export +When a property is given a value in @code{org-publish-project-alist}, +its setting overrides the value of the corresponding user variable (if +any) during publishing. Options set within a file (@pxref{Export options}), however, override everything. @node Publishing links, Project page index, Publishing options, Configuration @@ -6422,7 +7014,7 @@ you publish them to HTML. You may also link to related files, such as images. Provided you are careful with relative pathnames, and provided you have also configured -org-publish to upload the related files, these links will work +@code{org-publish} to upload the related files, these links will work too. @ref{Complex example} for an example of this usage. Sometime an Org-mode file to be published may contain links that are @@ -6681,13 +7273,16 @@ for all subsequent lines until the next @samp{#+CATEGORY} line, or the end of the file. The first such line also applies to any entries before it. @item #+COLUMNS: %25ITEM ..... Set the default format for columns view. This format applies when -columns view is invoked in location where no COLUMNS property applies. +columns view is invoked in location where no @code{COLUMNS} property +applies. @item #+CONSTANTS: name1=value1 ... Set file-local values for constants to be used in table formulas. This line set the local variable @code{org-table-formula-constants-local}. -The global version of theis variable is +The global version of this variable is @code{org-table-formula-constants}. -corresponding +@item #+DRAWERS: NAME1 ..... +Set the file-local set of drawers. The corresponding global variable is +@code{org-drawers}. @item #+LINK: linkword replace These lines (several are allowed) specify link abbreviations. @xref{Link abbreviations}. The corresponding variable is @@ -6723,8 +7318,9 @@ variable is @code{org-startup-align-all-tables}, with a default value align @r{align all tables} noalign @r{don't align tables on startup} @end example -Logging TODO state changes and clock intervals (variable -@code{org-log-done}) can be configured using these options. +Logging TODO state changes and clock intervals (variables +@code{org-log-done} and @code{org-log-repeat}) can be configured using +these options. @cindex @code{logdone}, STARTUP keyword @cindex @code{nologging}, STARTUP keyword @cindex @code{lognotedone}, STARTUP keyword @@ -6776,7 +7372,7 @@ this file, and (potentially) the corresponding @emph{fast tag selection} keys. The corresponding variable is @code{org-tag-alist}. @item #+TBLFM: This line contains the formulas for the table directly above the line. -@item #+TITLE:, #+AUTHOR:, #+EMAIL:, #+LANGUAGE:, #+TEXT:, #+OPTIONS: +@item #+TITLE:, #+AUTHOR:, #+EMAIL:, #+LANGUAGE:, #+TEXT:, #+OPTIONS, #+DATE: These lines provide settings for exporting files. For more details see @ref{Export options}. @item #+SEQ_TODO: #+TYP_TODO: @@ -6830,6 +7426,9 @@ of the checkbox. @item If the cursor is on a numbered item in a plain list, renumber the ordered list. +@item +If the cursor is on the @code{#+BEGIN} line of a dynamical block, the +block is updated. @end itemize @node Clean view, TTY keys, The very busy C-c C-c key, Miscellaneous @@ -6937,18 +7536,17 @@ org-convert-to-oddeven-levels}. @section Using org-mode on a tty @cindex tty keybindings -Org-mode uses a number of keys that are not accessible on a tty. This -applies to most special keys like cursor keys, @key{TAB} and -@key{RET}, when these are combined with modifier keys like @key{Meta} -and/or @key{Shift}. Org-mode uses these bindings because it needs to -provide keys for a large number of commands, and because these keys -appeared particularly easy to remember. In order to still be able to -access the core functionality of Org-mode on a tty, alternative -bindings are provided. Here is a complete list of these bindings, -which are obviously more cumbersome to use. Note that sometimes a -work-around can be better. For example changing a time stamp is -really only fun with @kbd{S-@key{cursor}} keys. On a tty you would -rather use @kbd{C-c .} to re-insert the timestamp. +Because Org-mode contains a large number of commands, by default much of +Org-mode's core commands are bound to keys that are generally not +accessible on a tty, such as the cursor keys (@key{left}, @key{right}, +@key{up}, @key{down}), @key{TAB} and @key{RET}, in particular when used +together with modifiers like @key{Meta} and/or @key{Shift}. To access +these commands on a tty when special keys are unavailable, the following +alternative bindings can be used. The tty bindings below will likely be +more cumbersome; you may find for some of the bindings below that a +customized work-around suits you better. For example, changing a time +stamp is really only fun with @kbd{S-@key{cursor}} keys, whereas on a +tty you would rather use @kbd{C-c .} to re-insert the timestamp. @multitable @columnfractions 0.15 0.2 0.2 @item @b{Default} @tab @b{Alternative 1} @tab @b{Alternative 2} @@ -7013,10 +7611,27 @@ setup. See the installation instructions in the file @cindex @file{cdlatex.el} Org-mode can make use of the cdlatex package to efficiently enter La@TeX{} fragments into Org-mode files. See @ref{CDLaTeX mode}. +@item @file{imenu.el} by Ake Stenhoff and Lars Lindberg +@cindex @file{imenu.el} +Imenu allows menu access to an index of items in a file. Org-mode +supports imenu - all you need to do to get the index is the following: +@lisp +(add-hook 'org-mode-hook + (lambda () 'imenu-add-to-menubar "Imenu")) +@end lisp +By default the index is two levels deep - you can modify the depth using +the option @code{org-imenu-depth}. @item @file{remember.el} by John Wiegley @cindex @file{remember.el} Org mode cooperates with remember, see @ref{Remember}. @file{Remember.el} is not part of Emacs, find it on the web. +@item @file{speedbar.el} by Eric M. Ludlam +@cindex @file{speedbar.el} +Speedbar is a package that creates a special frame displaying files and +index items in files. Org-mode supports speedbar and allows you to +drill into Org-mode files directly from the speedbar. It also allows to +restrict the scope of agenda commands to a file or a subtree by using +the command @kbd{<} in the speedbar frame. @cindex @file{table.el} @item @file{table.el} by Takaaki Ota @kindex C-c C-c @@ -7070,13 +7685,12 @@ is loaded @emph{before} @file{allout.el}, for example by putting @cindex @file{CUA.el} @item @file{CUA.el} by Kim. F. Storm -Keybindings in Org-mode conflict with the @kbd{S-} keys -used by CUA-mode (as well as pc-select-mode and s-region-mode) to -select and extend the region. If you want to use one of these -packages along with Org-mode, configure the variable -@code{org-CUA-compatible}. When set, Org-mode will move the following -keybindings in Org-mode files, and in the agenda buffer (but not -during date selection). +Keybindings in Org-mode conflict with the @kbd{S-} keys used by +CUA-mode (as well as pc-select-mode and s-region-mode) to select and +extend the region. If you want to use one of these packages along with +Org-mode, configure the variable @code{org-replace-disputed-keys}. When +set, Org-mode will move the following keybindings in Org-mode files, and +in the agenda buffer (but not during date selection). @example S-UP -> M-p S-DOWN -> M-n @@ -7197,6 +7811,12 @@ blogs. @url{http://www.cognition.ens.fr/~guerry/blorg.html}. @item @file{org2rem.el} by Bastien Guerry Translates Org-mode files into something readable by Remind. @url{http://www.cognition.ens.fr/~guerry/u/org2rem.el}. +@item @file{org-toc.el} by Bastien Guerry +Produces a simple table of contents of an Org-mode file, for easy +navigation. @url{http://www.cognition.ens.fr/~guerry/u/org-registry.el}. +@item @file{org-registry.el} by Bastien Guerry +Find which Org-file link to a certain document. +@url{http://www.cognition.ens.fr/~guerry/u/org2rem.el}. @end table @page @@ -7299,15 +7919,18 @@ the link description when the link is later inserted into tan Org-mode buffer with @kbd{C-c C-l}. @node Tables in arbitrary syntax, Dynamic blocks, Adding hyperlink types, Extensions and Hacking -@section Tables in arbitrary syntax +@section Tables and Lists in arbitrary syntax @cindex tables, in other modes +@cindex lists, in other modes @cindex orgtbl-mode Since Orgtbl-mode can be used as a minor mode in arbitrary buffers, a frequent feature request has been to make it work with native tables in -specific languages, for example La@TeX{}. However, this is extremely hard -to do in a general way, would lead to a customization nightmare, and -would take away much of the simplicity of the Orgtbl-mode table editor. +specific languages, for example La@TeX{}. However, this is extremely +hard to do in a general way, would lead to a customization nightmare, +and would take away much of the simplicity of the Orgtbl-mode table +editor. + This appendix describes a different approach. We keep the Orgtbl-mode table in its native format (the @i{source table}), and use a custom @@ -7316,10 +7939,17 @@ function to @i{translate} the table to the correct syntax, and to the burden of writing conversion functions on the user, but it allows for a very flexible system. +Bastien added the ability to do the same with lists. You can use Org's +facilities to edit and structure lists by turning @code{orgstruct-mode} +on, then locally exporting such lists in another format (HTML, La@TeX{} +or TeXInfo.) + + @menu * Radio tables:: Sending and receiving * A LaTeX example:: Step by step, almost a tutorial * Translator functions:: Copy and modify +* Radio lists:: Doing the same for lists. @end menu @node Radio tables, A LaTeX example, Tables in arbitrary syntax, Tables in arbitrary syntax @@ -7388,7 +8018,7 @@ key. @end itemize @node A LaTeX example, Translator functions, Radio tables, Tables in arbitrary syntax -@subsection A LaTeX example +@subsection A LaTeX example of radio tables @cindex LaTeX, and orgtbl-mode The best way to wrap the source table in La@TeX{} is to use the @@ -7492,7 +8122,7 @@ may also be a property list with column numbers and formats, for example applied. @end table -@node Translator functions, , A LaTeX example, Tables in arbitrary syntax +@node Translator functions, Radio lists, A LaTeX example, Tables in arbitrary syntax @subsection Translator functions @cindex HTML, and orgtbl-mode @cindex translator function @@ -7565,6 +8195,49 @@ containing the formatted table. If you write a generally useful translator, please post it on @code{emacs-orgmode@@gnu.org} so that others can benefit from your work. +@node Radio lists, , Translator functions, Tables in arbitrary syntax +@subsection Radio lists +@cindex radio lists +@cindex org-list-insert-radio-list + +Sending and receiving radio lists works exactly the same way than +sending and receiving radio tables (@pxref{Radio tables}) @footnote{You +need to load the @code{org-export-latex.el} package to use radio lists +since the relevant code is there for now.}. As for radio tables, you +can insert radio lists templates in HTML, La@TeX{} and TeXInfo modes by +calling @code{org-list-insert-radio-list}. + +Here are the differences with radio tables: + +@itemize @minus +@item +Use @code{ORGLST} instead of @code{ORGTBL}. +@item +The available translation functions for radio lists don't take +parameters. +@item +`C-c C-c' will work when pressed on the first item of the list. +@end itemize + +Here is a La@TeX{} example. Let's say that you have this in your +La@TeX{} file: + +@example +% BEGIN RECEIVE ORGLST to-buy +% END RECEIVE ORGLST to-buy +\begin@{comment@} +#+ORGLIST: SEND to-buy orgtbl-to-latex +- a new house +- a new computer + + a new keyboard + + a new mouse +- a new life +\end@{comment@} +@end example + +Pressing `C-c C-c' on @code{a new house} and will insert the converted +La@TeX{} list between the two marker lines. + @node Dynamic blocks, Special agenda views, Tables in arbitrary syntax, Extensions and Hacking @section Dynamic blocks @cindex dynamic blocks @@ -7651,7 +8324,7 @@ search should continue from there. (defun my-skip-unless-waiting () "Skip trees that are not waiting" (let ((subtree-end (save-excursion (org-end-of-subtree t)))) - (if (re-search-forward ":WAITING:" subtree-end t) + (if (re-search-forward ":waiting:" subtree-end t) nil ; tag found, do not skip subtree-end))) ; tag not found, continue after end of subtree @end lisp @@ -7683,8 +8356,9 @@ Skip current entry if it has a deadline. @item '(org-agenda-skip-entry-if 'scheduled 'deadline) Skip current entry if it has a deadline, or if it is scheduled. @item '(org-agenda-skip-entry 'regexp "regular expression") -Skip current entry if the regular expression contained in the variable -@code{org-agenda-skip-regexp} matches in the entry. +Skip current entry if the regular expression matches in the entry. +@item '(org-agenda-skip-entry 'notregexp "regular expression") +Skip current entry unless the regular expression matches. @item '(org-agenda-skip-subtree-if 'regexp "regular expression") Same as above, but check and skip the entire subtree. @end table @@ -7696,7 +8370,7 @@ like this, even without defining a special function: (org-add-agenda-custom-command '("b" todo "PROJECT" ((org-agenda-skip-function '(org-agenda-skip-subtree-if - 'regexp ":WAITING:")) + 'regexp ":waiting:")) (org-agenda-overriding-header "Projects waiting for something: ")))) @end lisp @@ -7722,7 +8396,9 @@ If WHICH is nil or `all', get all properties. If WHICH is @defun org-entry-get pom property &optional inherit Get value of PROPERTY for entry at point-or-marker POM. If INHERIT is non-nil and the entry does not have the property, -then also check higher levels of the hierarchy. +then also check higher levels of the hierarchy. This function ignores +the value of @code{org-use-property-inheritance} and requires the +explicit INHERIT flag. @end defun @defun org-entry-delete pom property @@ -7741,7 +8417,7 @@ Get all property keys in the current buffer. Insert a property drawer at point. @end defun -@node History and Acknowledgments, Index, Extensions and Hacking, Top +@node History and Acknowledgments, Main Index, Extensions and Hacking, Top @appendix History and Acknowledgments @cindex acknowledgments @cindex history @@ -7814,11 +8490,10 @@ HTML agendas. @i{John Foerch} figured out how to make incremental search show context around a match in a hidden outline tree. @item -@i{Niels Giessen} had the idea to automatically archive DONE trees. +@i{Niels Giesen} had the idea to automatically archive DONE trees. @item @i{Bastien Guerry} wrote the La@TeX{} exporter and has been prolific with patches, ideas, and bug reports. -to Org-mode. @item @i{Kai Grossjohann} pointed out key-binding conflicts with other packages. @item @@ -7830,13 +8505,16 @@ provided frequent feedback and some patches. @item @i{Jason F. McBrayer} suggested agenda export to CSV format. @item +@i{Max Mikhanosha} came up with the idea of refiling. +@item @i{Dmitri Minaev} sent a patch to set priority limits on a per-file basis. @item @i{Stefan Monnier} provided a patch to keep the Emacs-Lisp compiler happy. @item -@i{Rick Moynihan} proposed to allow multiple TODO sequences in a file. +@i{Rick Moynihan} proposed to allow multiple TODO sequences in a file +and to be able to quickly restrict the agenda to a subtree. @item @i{Todd Neal} provided patches for links to Info files and elisp forms. @item @@ -7914,12 +8592,12 @@ and contributed various ideas and code snippets. @end itemize -@node Index, Key Index, History and Acknowledgments, Top -@unnumbered Index +@node Main Index, Key Index, History and Acknowledgments, Top +@unnumbered The Main Index @printindex cp -@node Key Index, , Index, Top +@node Key Index, , Main Index, Top @unnumbered Key Index @printindex ky diff --git a/etc/ChangeLog b/etc/ChangeLog index 1795f023d5f..55e7c2474f3 100644 --- a/etc/ChangeLog +++ b/etc/ChangeLog @@ -1,3 +1,7 @@ +2008-01-18 Carsten Dominik + + * refcards/orgcard.tex: Update to Org-mode version 5.19. + 2008-01-12 Eli Zaretskii * MACHINES: Add an explicit list of platforms that are no longer diff --git a/etc/refcards/orgcard.tex b/etc/refcards/orgcard.tex index 014f4655289..0a231547d03 100644 --- a/etc/refcards/orgcard.tex +++ b/etc/refcards/orgcard.tex @@ -1,8 +1,8 @@ % Reference Card for Org Mode -\def\orgversionnumber{5.03} -\def\versionyear{2007} % latest update +\def\orgversionnumber{5.19} +\def\versionyear{2008} % latest update \def\year{2008} % latest copyright year -% + %**start of header \newcount\columnsperpage \newcount\letterpaper @@ -12,17 +12,11 @@ \columnsperpage=3 -% Set letterpaper to 0 for A4 paper, 1 for letter (US) paper. Useful +% Set letterpapaer to 0 for A4 paper, 1 for letter (US) paper. Useful % only when columnsperpage is 2 or 3. \letterpaper=0 -% PDF output layout. 0 for A4, 1 for letter (US), a `l' is added for -% a landscape layout. - -\input pdflayout.sty -\pdflayout=(0l) - % Nothing else needs to be changed below this line. % Copyright (C) 1987, 1993, 1996, 1997, 2001, 2002, 2003, 2004, % 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @@ -31,7 +25,7 @@ % GNU Emacs is free software; you can redistribute it and/or modify % it under the terms of the GNU General Public License as published by -% the Free Software Foundation; either version 3, or (at your option) +% the Free Software Foundation; either version 2, or (at your option) % any later version. % GNU Emacs is distributed in the hope that it will be useful, @@ -314,6 +308,7 @@ \section{Motion} \section{Structure Editing} \key{insert new heading/item at current level}{M-RET} +\key{insert new heading after subtree}{C-RET} \key{insert new TODO entry/checkbox item}{M-S-RET} \key{promote current heading up one level}{M-LEFT} @@ -322,6 +317,7 @@ \section{Structure Editing} \key{demote current subtree down one level}{M-S-RIGHT} \key{move subtree/list item up/down}{M-S-UP/DOWN} +\key{refile subtree}{C-c C-w} \key{kill subtree}{C-c C-x C-w} \key{copy subtree}{C-c C-x M-w} \key{yank subtree}{C-c C-x C-y} @@ -342,10 +338,10 @@ \section{Archiving} \section{Filtering and Sparse Trees} -\key{show sparse tree for all matches of a regexp}{C-c /} +% FIXME: this is garbage +\key{construct a sparse tree by various criteria}{C-c /} \key{view TODO's in sparse tree}{C-c C-v} \key{global TODO list in agenda mode}{C-c t$^1$} -\key{create sparse tree with all deadlines due}{C-c C-w} \key{time sorted view of current org file}{C-c a L} %\key{agenda for the week}{C-c a$^1$} %\key{agenda for date at cursor}{C-c C-o} @@ -552,9 +548,11 @@ \section{Tags} \section{Properties and Column View} +\key{set property}{C-c C-x p} \key{special commands in property lines}{C-c C-c} \key{next/previous allowed value}{S-left/right} \key{turn on column view}{C-c C-x C-c} +\key{capture columns view in dynamic block}{C-c C-x r} \key{quit column view}{q} \key{next/previous allowed value}{S-left/right} @@ -575,7 +573,7 @@ \section{Timestamps} \key{Like \kbd{C-c .} but make stamp inactive}{C-c !} % FIXME \key{insert DEADLINE timestamp}{C-c C-d} \key{insert SCHEDULED timestamp}{C-c C-s} -\key{create sparse tree with all deadlines due}{C-c C-w} +\key{create sparse tree with all deadlines due}{C-c / d} \key{the time between 2 dates in a time range}{C-c C-y} \key{change timestamp at cursor by $\pm 1$ day}{S-RIGHT/LEFT$^3$} \key{change year/month/day at cursor by $\pm 1$}{S-UP/DOWN$^3$} @@ -606,6 +604,7 @@ \section{Agenda Views} \key{add/move current file to front of agenda}{C-c [} \key{remove current file from your agenda}{C-c ]} \key{cycle through agenda file list}{C-'} +\key{set/remove restriction lock}{C-c C-x } \key{compile agenda for the current week}{C-c a a$^1$} \key{compile global TODO list}{C-c a t$^1$} @@ -618,13 +617,6 @@ \section{Agenda Views} \key{configure stuck projects}{C-c a !$^1$} \key{agenda for date at cursor}{C-c C-o} -\vskip 1mm -To set categories, add lines like$^2$: -\vskip -1mm -\beginexample% -\#+CATEGORY: MyCateg -\endexample - {\bf Commands available in an agenda buffer} {\bf View Org file} @@ -658,7 +650,7 @@ \section{Agenda Views} \key{kill item and source}{C-k} \key{archive the subtree}{\$} \key{show tags of current headline}{T} -\key{set tags for current headline}{:} +\key{set tags for current headline/region}{:} \key{toggle ARCHIVE tag}{a} \key{set priority of current item}{p} \key{raise/lower priority of current item}{S-UP/DOWN$^3$} @@ -669,9 +661,8 @@ \section{Agenda Views} \key{insert new entry into diary}{i} \newcolumn -\key{start the clock on current item (clock-in)}{I} -\key{stop the clock (clock-out)}{O} -\key{cancel current clock}{X} +\key{start/stop/cancel the clock on current item}{I / O / X} +\key{jump to running clock entry}{J} {\bf Misc} From 7b4d0413052abd65c7920783c7b27a68a228c592 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Fri, 18 Jan 2008 16:51:59 +0000 Subject: [PATCH 193/439] *** empty log message *** --- doc/misc/ChangeLog | 4 +- lisp/ChangeLog | 91 +++++++++++++++++++++------------------------- 2 files changed, 44 insertions(+), 51 deletions(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index b9c71b7e7b3..0c425b04c09 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,8 +1,8 @@ 2008-01-18 Carsten Dominik - * org.texi: (Property inheritance): New section + * org.texi (Property inheritance): New section. (Conventions): New section. - (Structure editing): Document C-RET, the prefix arg to the cut/cpy + (Structure editing): Document C-RET, the prefix arg to the cut/copy commands, and the new bindings for refiling. (Sparse trees): Document the new special command for sparse trees. (References): Be more clear about the counting of hilines. diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 760d36d3c4c..3cb8779df67 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,34 +1,35 @@ -2008-01-18 Bastien Guerry +2008-01-18 Bastien Guerry * textmodes/org-export-latex.el (org-export-latex-cleaned-string): Fixed. - (org-export-latex-special-chars): Convert "..." in \ldots and skip - tables - (org-export-latex-fontify-headline): Changed parameter name - (org-export-as-latex): Handle export of subtrees - (org-export-latex-make-header): New argument TITLE - (org-export-latex-content): New argument EXCLUDE-LIST - (org-list-parse-list): New name for org-export-latex-parse-list + (org-export-latex-special-chars): Convert "..." in \ldots + and skip tables. + (org-export-latex-fontify-headline): Changed parameter name. + (org-export-as-latex): Handle export of subtrees. + (org-export-latex-make-header): New argument TITLE. + (org-export-latex-content): New argument EXCLUDE-LIST. + (org-list-parse-list): New name for org-export-latex-parse-list. (org-export-latex-make-header): New name for - org-export-latex-make-preamble - (org-list-to-generic): New name of org-export-list-to-generic - (org-list-to-latex): New name of org-export-list-to-latex + org-export-latex-make-preamble. + (org-list-to-generic): New name of org-export-list-to-generic. + (org-list-to-latex): New name of org-export-list-to-latex. (org-list-item-begin, org-list-end, org-list-insert-radio-list) (org-list-send-list, org-list-to-texinfo) - (org-list-to-html): New functions + (org-list-to-html): New functions. (org-export-latex-tables-column-borders) (org-export-latex-default-class, org-export-latex-classes) (org-export-latex-classes-sectioning) - (org-list-radio-list-templates): New options - (org-export-latex-header): New variable - (org-latex-entities): New constant + (org-list-radio-list-templates): New options. + (org-export-latex-header): New variable. + (org-latex-entities): New constant. (org-export-latex-default-sectioning, org-export-latex-preamble) (org-export-latex-prepare-text-option) - (org-export-latex-get-sectioning): Removed + (org-export-latex-get-sectioning): Remove. -2008-01-18 Carsten Dominik - * textmodes/org-publish.el (org-publish-current-project): Fix bug - with forcing publication. +2008-01-18 Carsten Dominik + + * textmodes/org-publish.el (org-publish-current-project): + Fix bug with forcing publication. * textmodes/org.el (org-export-with-special-strings): New option. (org-export-html-convert-special-strings): New function. @@ -42,18 +43,15 @@ (org-format-table-table-html) Use the :html-table-tag property instead of the `org-export-html-table-tag' global value. (org-additional-option-like-keywords): Added "TBLFM". - (org-entry-properties): Include the CLOCKSUM - special property. + (org-entry-properties): Include the CLOCKSUM special property. (org-columns-edit-value): Do not allow to edit the special CLOCKSUM property. (org-flag-drawer): Use the original value of `outline-regexp'. (org-remember-handler): Add invisible-ok flag to call to - `org-end-of-subtree' - (org-agenda-highlight-todo): Respect - `org-agenda-todo-keyword-format'. + `org-end-of-subtree'. + (org-agenda-highlight-todo): Respect `org-agenda-todo-keyword-format'. (org-agenda-todo-keyword-format): New option. - (org-infile-export-plist): No restriction while searching for - options. + (org-infile-export-plist): No restriction while searching for options. (org-remember-handler): Remove comments at the end of the buffer. (org-remember-use-refile-when-interactive): New option. (org-table-sort-lines): Make sure sorting works on link @@ -64,8 +62,7 @@ `full-file-path'. (org-get-refile-targets): Respect new values for `org-refile-use-outline-path'. - (org-agenda-get-restriction-and-command): DEL goes back to initial - list. + (org-agenda-get-restriction-and-command): DEL goes back to initial list. (org-export-as-xoxo): Restore point when done. (org-open-file): Allow multiple %s in command. (org-clock-in-switch-to-state): New option. @@ -73,8 +70,7 @@ (org-last-remember-storage-locations): New variable. (org-get-refile-targets): Interpret the new maxlevel setting. (org-refile-targets): New option `:maxlevel'. - (org-copy-subtree): Include empty lines before but not after - subtree. + (org-copy-subtree): Include empty lines before but not after subtree. (org-back-over-empty-lines, org-skip-whitespace): New functions. (org-move-item-down, org-move-item-up): Include empty lines before but not after item. @@ -87,9 +83,8 @@ (org-imenu-markers): New variable. (org-imenu-new-marker, org-imenu-get-tree) (org-speedbar-set-agenda-restriction): New functions. - (org-agenda-set-restriction-lock) - (org-agenda-remove-restriction-lock, org-agenda-maybe-redo): New - functions. + (org-agenda-set-restriction-lock, org-agenda-remove-restriction-lock) + (org-agenda-maybe-redo): New functions. (org-agenda-restriction-lock): New face. (org-agenda-restriction-lock-overlay) (org-speedbar-restriction-lock-overlay): New variables. @@ -110,8 +105,8 @@ (org-link-escape-chars): Use characters instead of strings. (org-link-escape-chars-browser, org-link-escape) (org-link-unescape): Use characters instead of strings. - (org-export-html-convert-sub-super, org-html-do-expand): Check for - protected text. + (org-export-html-convert-sub-super, org-html-do-expand): + Check for protected text. (org-emphasis-alist): Additional `verbatim' flag. (org-set-emph-re): Handle the verbatim flag and compute `org-verbatim-re'. @@ -120,15 +115,13 @@ (org-hide-emphasis-markers): New option. (org-additional-option-like-keywords): Add new keywords. (org-get-entry): Renamed from `org-get-cleaned-entry'. - (org-icalendar-cleanup-string): New function for quoting icalendar - text. + (org-icalendar-cleanup-string): New function for quoting icalendar text. (org-agenda-skip-scheduled-if-done): New option. - (org-agenda-get-scheduled, org-agenda-get-blocks): Use - `org-agenda-skip-scheduled-if-done'. + (org-agenda-get-scheduled, org-agenda-get-blocks): + Use `org-agenda-skip-scheduled-if-done'. (org-prepare-agenda-buffers): Allow buffers as arguments. (org-entry-properties): Add CATEGORY as a special property. - (org-use-property-inheritance): Allow a list of properties as a - value. + (org-use-property-inheritance): Allow a list of properties as a value. (org-eval-in-calendar): No longer update the prompt. (org-read-date-popup-calendar): Renamed from `org-popup-calendar-for-date-prompt'. @@ -139,8 +132,8 @@ not yet defined. (org-remember-insinuate): New function. (org-read-date-prefer-future): New option. - (org-read-date): Respect the setting of - `org-read-date-prefer-future'. Use `org-read-date-analyze'. + (org-read-date): Respect the setting of `org-read-date-prefer-future'. + Use `org-read-date-analyze'. (org-set-font-lock-defaults): Use `org-archive-tag' instead of a hardcoded string. (org-remember-apply-template): Use `remember-finalize' instead of @@ -167,8 +160,8 @@ 2008-01-18 Dan Nicolaescu * vc.el: Add a TODO note about vc-state. - (vc-next-action): Register 'unregistered and 'ignored files. Use - when and unless instead of if where appropriate. + (vc-next-action): Register 'unregistered and 'ignored files. + Use when and unless instead of if where appropriate. (vc-start-entry): Fix typo. (vc-status): Autoload it. @@ -185,8 +178,8 @@ * ibuffer.el (ibuffer-mode): Fix typo in previous change. -2008-01-17 Vinicius Jose Latorre - Miles Bader +2008-01-17 Vinicius Jose Latorre + Miles Bader * blank-mode.el: New file. Minor mode to visualise (HARD) SPACE, TAB, NEWLINE. Miles Bader wrote the original code @@ -869,7 +862,7 @@ * progmodes/grep.el (grep-find-ignored-directories): Initialize from the value of vc-directory-exclusion-list. - * vc-hooks (vc-directory-exclusion-list): Include "_darcs", + * vc-hooks (vc-directory-exclusion-list): Include "_darcs", even though we don't have a back end for darcs yet. 2008-01-02 Karl Fogel @@ -940,7 +933,7 @@ * vc-svn.el (vc-svn-parse-status): Set the `unregisted' property correctly. - * vc.el (vc-dired-hook): Speed tuning. Replace a vc-backend call + * vc.el (vc-dired-hook): Speed tuning. Replace a vc-backend call with vc-state. (vc-next-action): Fix vc-transfer-file call. From 3b98658e6157246b19bb7095cc62c35fc5e50b83 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 18 Jan 2008 17:32:25 +0000 Subject: [PATCH 194/439] Remove copyright from author with assignment, merge years into FSF years. --- lisp/textmodes/org-mouse.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/textmodes/org-mouse.el b/lisp/textmodes/org-mouse.el index 9d275c2d109..f33440c3c2f 100644 --- a/lisp/textmodes/org-mouse.el +++ b/lisp/textmodes/org-mouse.el @@ -1,6 +1,6 @@ ;;; org-mouse.el --- Better mouse support for org-mode -;; Copyright (c) 2006 Piotr Zielinski, 2007, 2008 Free Software Foundation +;; Copyright (C) 2006, 2007, 2008 Free Software Foundation ;; ;; Author: Piotr Zielinski ;; Maintainer: Carsten Dominik From cec1df02a4865dd4b7a48944e3d398828671134b Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Fri, 18 Jan 2008 20:09:26 +0000 Subject: [PATCH 195/439] (doc-view-pdf/ps->png): Make sure we a have a valid cwd. (doc-view-insert-image): Do something if the image is missing. (doc-view-mode): Don't use file-remote-p. --- lisp/ChangeLog | 33 +++++++++++++++++------------- lisp/doc-view.el | 53 +++++++++++++++++++++++++++++++----------------- 2 files changed, 53 insertions(+), 33 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3cb8779df67..182812f2c7a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,28 +1,33 @@ +2008-01-18 Stefan Monnier + + * doc-view.el (doc-view-pdf/ps->png): Make sure we a have a valid cwd. + (doc-view-insert-image): Do something if the image is missing. + (doc-view-mode): Don't use file-remote-p. + 2008-01-18 Bastien Guerry - * textmodes/org-export-latex.el (org-export-latex-cleaned-string): - Fixed. - (org-export-latex-special-chars): Convert "..." in \ldots + * textmodes/org-export-latex.el (org-export-latex-cleaned-string): Fix. + (org-export-latex-special-chars): Convert "..." in \ldots and skip tables. - (org-export-latex-fontify-headline): Changed parameter name. - (org-export-as-latex): Handle export of subtrees. + (org-export-latex-fontify-headline): Change parameter name. + (org-export-as-latex): Handle export of subtrees. (org-export-latex-make-header): New argument TITLE. (org-export-latex-content): New argument EXCLUDE-LIST. (org-list-parse-list): New name for org-export-latex-parse-list. - (org-export-latex-make-header): New name for + (org-export-latex-make-header): New name for org-export-latex-make-preamble. (org-list-to-generic): New name of org-export-list-to-generic. (org-list-to-latex): New name of org-export-list-to-latex. (org-list-item-begin, org-list-end, org-list-insert-radio-list) (org-list-send-list, org-list-to-texinfo) (org-list-to-html): New functions. - (org-export-latex-tables-column-borders) + (org-export-latex-tables-column-borders) (org-export-latex-default-class, org-export-latex-classes) (org-export-latex-classes-sectioning) (org-list-radio-list-templates): New options. - (org-export-latex-header): New variable. + (org-export-latex-header): New variable. (org-latex-entities): New constant. - (org-export-latex-default-sectioning, org-export-latex-preamble) + (org-export-latex-default-sectioning, org-export-latex-preamble) (org-export-latex-prepare-text-option) (org-export-latex-get-sectioning): Remove. @@ -35,14 +40,14 @@ (org-export-html-convert-special-strings): New function. (org-html-do-expand): `org-export-html-convert-special-strings' added to the list of conversion. - (org-infile-export-plist, org-get-current-options): Added support + (org-infile-export-plist, org-get-current-options): Add support for "-" in the #+OPTION line to let user switch on/off special strings conversion. (org-export-plist-vars): New :html-table-tag property. (org-export-as-html, org-format-org-table-html) (org-format-table-table-html) Use the :html-table-tag property instead of the `org-export-html-table-tag' global value. - (org-additional-option-like-keywords): Added "TBLFM". + (org-additional-option-like-keywords): Add "TBLFM". (org-entry-properties): Include the CLOCKSUM special property. (org-columns-edit-value): Do not allow to edit the special CLOCKSUM property. @@ -88,7 +93,7 @@ (org-agenda-restriction-lock): New face. (org-agenda-restriction-lock-overlay) (org-speedbar-restriction-lock-overlay): New variables. - (org-open-at-point): Removed obsolete way to do redirection in + (org-open-at-point): Remove obsolete way to do redirection in shell links. (org-imenu-and-speedbar): New customization group. (org-entry-properties): Return keyword-less time strings. @@ -114,7 +119,7 @@ (org-verbatim-re): New variable. (org-hide-emphasis-markers): New option. (org-additional-option-like-keywords): Add new keywords. - (org-get-entry): Renamed from `org-get-cleaned-entry'. + (org-get-entry): Rename from `org-get-cleaned-entry'. (org-icalendar-cleanup-string): New function for quoting icalendar text. (org-agenda-skip-scheduled-if-done): New option. (org-agenda-get-scheduled, org-agenda-get-blocks): @@ -123,7 +128,7 @@ (org-entry-properties): Add CATEGORY as a special property. (org-use-property-inheritance): Allow a list of properties as a value. (org-eval-in-calendar): No longer update the prompt. - (org-read-date-popup-calendar): Renamed from + (org-read-date-popup-calendar): Rename from `org-popup-calendar-for-date-prompt'. (org-read-date-display-live): New variable. (org-read-date-display): New function. diff --git a/lisp/doc-view.el b/lisp/doc-view.el index 23bf4096e93..ba4aadb1e6b 100644 --- a/lisp/doc-view.el +++ b/lisp/doc-view.el @@ -100,10 +100,9 @@ ;;; Todo: ;; - better menu. -;; - don't use `find-file'. ;; - Bind slicing to a drag event. ;; - doc-view-fit-doc-to-window and doc-view-fit-window-to-doc. -;; - zoom a the region around the cursor (like xdvi). +;; - zoom the region around the cursor (like xdvi). ;; - get rid of the silly arrow in the fringe. ;; - improve anti-aliasing (pdf-utils gets it better). @@ -558,13 +557,16 @@ Should be invoked when the cached images aren't up-to-date." (defun doc-view-pdf/ps->png (pdf-ps png) "Convert PDF-PS to PNG asynchronously." (setq doc-view-current-converter-process - (apply 'start-process - (append (list "pdf/ps->png" doc-view-conversion-buffer - doc-view-ghostscript-program) - doc-view-ghostscript-options - (list (format "-r%d" (round doc-view-resolution))) - (list (concat "-sOutputFile=" png)) - (list pdf-ps))) + ;; Make sure the process is started in an existing directory, + ;; (rather than some file-name-handler-managed dir, for example). + (let ((default-directory (file-name-directory pdf-ps))) + (apply 'start-process + (append (list "pdf/ps->png" doc-view-conversion-buffer + doc-view-ghostscript-program) + doc-view-ghostscript-options + (list (format "-r%d" (round doc-view-resolution))) + (list (concat "-sOutputFile=" png)) + (list pdf-ps)))) mode-line-process (list (format ":%s" doc-view-current-converter-process))) (process-put doc-view-current-converter-process 'buffer (current-buffer)) @@ -705,13 +707,23 @@ ARGS is a list of image descriptors." (when doc-view-pending-cache-flush (clear-image-cache) (setq doc-view-pending-cache-flush nil)) - (let ((image (apply 'create-image file 'png nil args))) - (setq doc-view-current-image image) - (move-overlay doc-view-current-overlay (point-min) (point-max)) - (overlay-put doc-view-current-overlay 'display - (if doc-view-current-slice - (list (cons 'slice doc-view-current-slice) image) - image)))) + (if (null file) + ;; We're trying to display a page that doesn't exist. Typically happens + ;; if the conversion process somehow failed. Better not signal an + ;; error here because it could prevent a subsequent reconversion from + ;; fixing the problem. + (progn + (setq doc-view-current-image nil) + (move-overlay doc-view-current-overlay (point-min) (point-max)) + (overlay-put doc-view-current-overlay 'display + "Cannot display this page! Probably a conversion failure!")) + (let ((image (apply 'create-image file 'png nil args))) + (setq doc-view-current-image image) + (move-overlay doc-view-current-overlay (point-min) (point-max)) + (overlay-put doc-view-current-overlay 'display + (if doc-view-current-slice + (list (cons 'slice doc-view-current-slice) image) + image))))) (defun doc-view-sort (a b) "Return non-nil if A should be sorted before B. @@ -952,9 +964,12 @@ toggle between displaying the document or editing it as text." (file-name-nondirectory (file-name-sans-extension buffer-file-name)) doc-view-cache-directory)) - ((or - (not (file-exists-p buffer-file-name)) - (file-remote-p buffer-file-name)) + ;; Is the file readable by local processes? + ;; We used to use `file-remote-p' but it's unclear what it's + ;; supposed to return nil for things like local files accessed via + ;; `su' or via file://... + ((let ((file-name-handler-alist nil)) + (not (file-readable-p buffer-file-name))) (expand-file-name (file-name-nondirectory buffer-file-name) doc-view-cache-directory)) From 64a7c220b34248e33ca25c3e6dde0e6e178b9fda Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Fri, 18 Jan 2008 22:50:17 +0000 Subject: [PATCH 196/439] (syms_of_buffer) : Fix docstring. --- src/buffer.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/buffer.c b/src/buffer.c index 57d88b0f791..6cbaabf85ec 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -5559,7 +5559,8 @@ its hooks should not expect certain variables such as DEFVAR_PER_BUFFER ("mode-name", ¤t_buffer->mode_name, Qnil, - doc: /* Pretty name of current buffer's major mode (a string). */); + doc: /* Pretty name of current buffer's major mode. +Usually a string. See `mode-line-format' for other possible forms. */); DEFVAR_PER_BUFFER ("local-abbrev-table", ¤t_buffer->abbrev_table, Qnil, doc: /* Local (mode-specific) abbrev table of current buffer. */); From 5ab612e823bb32aed3514c26b58e5aa7c0fab136 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Fri, 18 Jan 2008 23:32:58 +0000 Subject: [PATCH 197/439] * vc.el: Make vc-status asynchronous. (vc-update-vc-status-buffer): New function broken out of ... (vc-status-refresh): ... here. Pass vc-update-vc-status-buffer to the dir-status backend function. * vc-hg.el (vc-hg-dir-status): Compute the status asynchronously. Move the output processing to ... (vc-hg-after-dir-status): ... here. Call the function passed as an argument with the results. --- lisp/ChangeLog | 12 ++++++++++++ lisp/vc-hg.el | 44 +++++++++++++++++++++++++------------------- lisp/vc.el | 20 ++++++++++++++------ 3 files changed, 51 insertions(+), 25 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 182812f2c7a..a629893a38d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,15 @@ +2008-01-18 Dan Nicolaescu + + * vc.el: Make vc-status asynchronous. + (vc-update-vc-status-buffer): New function broken out of ... + (vc-status-refresh): ... here. Pass vc-update-vc-status-buffer to + the dir-status backend function. + + * vc-hg.el (vc-hg-dir-status): Compute the status asynchronously. + Move the output processing to ... + (vc-hg-after-dir-status): ... here. Call the function passed as + an argument with the results. + 2008-01-18 Stefan Monnier * doc-view.el (doc-view-pdf/ps->png): Make sure we a have a valid cwd. diff --git a/lisp/vc-hg.el b/lisp/vc-hg.el index fe441d984f7..c3c3b5577f3 100644 --- a/lisp/vc-hg.el +++ b/lisp/vc-hg.el @@ -480,35 +480,41 @@ REV is the revision to check out into WORKFILE." (define-derived-mode vc-hg-incoming-mode vc-hg-log-view-mode "Hg-Incoming") - ;; XXX Experimental function for the vc-dired replacement. -(defun vc-hg-dir-status (dir) - "Return a list of conses (file . state) for DIR." - (with-temp-buffer - (vc-hg-command (current-buffer) nil dir "status") - (goto-char (point-min)) - (let ((status-char nil) - (file nil) - (translation '((?= . up-to-date) - (?C . up-to-date) - (?A . added) - (?R . removed) - (?M . edited) - (?I . ignored) - (?! . deleted) - (?? . unregistered))) - (translated nil) +(defun vc-hg-after-dir-status (update-function buff) + (let ((status-char nil) + (file nil) + (translation '((?= . up-to-date) + (?C . up-to-date) + (?A . added) + (?R . removed) + (?M . edited) + (?I . ignored) + (?! . deleted) + (?? . unregistered))) + (translated nil) (result nil)) + (goto-char (point-min)) (while (not (eobp)) (setq status-char (char-after)) (setq file (buffer-substring-no-properties (+ (point) 2) - (line-end-position))) + (line-end-position))) (setq translated (assoc status-char translation)) (when (and translated (not (eq (cdr translated) 'up-to-date))) (push (cons file (cdr translated)) result)) (forward-line)) - result))) + (funcall update-function result buff))) + +;; XXX Experimental function for the vc-dired replacement. +(defun vc-hg-dir-status (dir update-function status-buffer) + "Return a list of conses (file . state) for DIR." + (with-current-buffer + (get-buffer-create + (expand-file-name " *VC-hg* tmp status" dir)) + (vc-hg-command (current-buffer) 'async dir "status") + (vc-exec-after + `(vc-hg-after-dir-status (quote ,update-function) ,status-buffer)))) ;; XXX this adds another top level menu, instead figure out how to ;; replace the Log-View menu. diff --git a/lisp/vc.el b/lisp/vc.el index bb05625f577..a0f8ce1702c 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -544,8 +544,6 @@ ;; ;; - decide if vc-status should replace vc-dired. ;; -;; - vc-status should be made asynchronous. -;; ;; - vc-status needs a menu, mouse bindings and some color bling. ;;; Code: @@ -2622,16 +2620,26 @@ With prefix arg READ-SWITCHES, specify a value to override (put 'vc-status-mode 'mode-class 'special) +(defun vc-update-vc-status-buffer (entries buffer) + (with-current-buffer buffer + (dolist (entry entries) + (ewoc-enter-last vc-status + (vc-status-create-fileinfo (cdr entry) (car entry)))) + (ewoc-goto-node vc-status (ewoc-nth vc-status 0)))) + (defun vc-status-refresh () "Refresh the contents of the VC status buffer." (interactive) ;; This is not very efficient; ewoc could use a new function here. (ewoc-filter vc-status (lambda (node) nil)) (let ((backend (vc-responsible-backend default-directory))) - (dolist (entry (vc-call-backend backend 'dir-status default-directory)) - (ewoc-enter-last vc-status - (vc-status-create-fileinfo (cdr entry) (car entry))))) - (ewoc-goto-node vc-status (ewoc-nth vc-status 0))) + ;; Call the dir-status backend function. dir-status is supposed to + ;; be asynchronous. It should compute the results and call the + ;; function passed as a an arg to update the vc-status buffer with + ;; the results. + (vc-call-backend + backend 'dir-status default-directory + #'vc-update-vc-status-buffer (current-buffer)))) (defun vc-status-next-line (arg) "Go to the next line. From f8e89f1963db357d4572f0411cd618d32a077fe8 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Fri, 18 Jan 2008 23:45:04 +0000 Subject: [PATCH 198/439] * vc-svn.el (vc-svn-dir-status): New function. --- lisp/ChangeLog | 4 ++++ lisp/vc-svn.el | 23 +++++++++++++++++++++++ 2 files changed, 27 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index a629893a38d..4f1526e0bc3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-18 Tom Tromey + + * vc-svn.el (vc-svn-dir-status): New function. + 2008-01-18 Dan Nicolaescu * vc.el: Make vc-status asynchronous. diff --git a/lisp/vc-svn.el b/lisp/vc-svn.el index e463e138490..b8d04d67c70 100644 --- a/lisp/vc-svn.el +++ b/lisp/vc-svn.el @@ -158,6 +158,29 @@ If you want to force an empty list of arguments, use t." (vc-svn-command t 0 nil "status" (if localp "-v" "-u")) (vc-svn-parse-status)))) +(defun vc-svn-dir-status (dir) + "Return a list of conses (FILE . STATE) for DIR." + (with-temp-buffer + (let ((default-directory (file-name-as-directory dir)) + (state-map '((?A . added) + (?C . edited) + (?D . removed) + (?I . ignored) + (?M . edited) + (?R . removed) + (?? . unregistered) + ;; This is what vc-svn-parse-status does. + (?~ . edited))) + result) + (vc-svn-command t 0 nil "status") + (goto-char (point-min)) + (while (re-search-forward "^\\(.\\)..... \\(.*\\)$" nil t) + (let ((state (cdr (assq (aref (match-string 1) 0) state-map))) + (filename (match-string 2))) + (when state + (setq result (cons (cons filename state) result))))) + result))) + (defun vc-svn-working-revision (file) "SVN-specific version of `vc-working-revision'." ;; There is no need to consult RCS headers under SVN, because we From fcd094c7fc8ee6bcfdda6617d4989cb0f0798b01 Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Sat, 19 Jan 2008 03:13:35 +0000 Subject: [PATCH 199/439] Add arch tagline --- lisp/textmodes/org-mouse.el | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lisp/textmodes/org-mouse.el b/lisp/textmodes/org-mouse.el index f33440c3c2f..f91dc3af853 100644 --- a/lisp/textmodes/org-mouse.el +++ b/lisp/textmodes/org-mouse.el @@ -1106,3 +1106,5 @@ SCHEDULED: or DEADLINE: or ANYTHINGLIKETHIS:" (:right (org-agenda-later 1))))))) (provide 'org-mouse) + +;; arch-tag: ff1ae557-3529-41a3-95c6-baaebdcc280f From 69c43ff730922b9a55920ac1c0601e057eac9766 Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Sat, 19 Jan 2008 04:36:40 +0000 Subject: [PATCH 200/439] ("TeX"): Correct the mappings for \v{k} and \vk. --- leim/ChangeLog | 5 +++++ leim/quail/latin-ltx.el | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/leim/ChangeLog b/leim/ChangeLog index ecdd73992e7..cc29276bed1 100644 --- a/leim/ChangeLog +++ b/leim/ChangeLog @@ -1,3 +1,8 @@ +2008-01-14 Aidan Kehoe + + * quail/latin-ltx.el ("TeX"): Correct the mappings for \v{k} and + \vk. + 2007-12-15 Richard Stallman * quail/latin-post.el ("scandinavian-postfix"): Doc fix. diff --git a/leim/quail/latin-ltx.el b/leim/quail/latin-ltx.el index ed21f57a53a..81230d19734 100644 --- a/leim/quail/latin-ltx.el +++ b/leim/quail/latin-ltx.el @@ -263,7 +263,7 @@ system, including many technical ones. Examples: ("\\v{G}" ?Ǧ) ("\\vG" ?Ǧ) ("\\v{g}" ?ǧ) ("\\vg" ?ǧ) ("\\v{K}" ?Ǩ) ("\\vK" ?Ǩ) - ("\\v{k}" ?k) ("\\vk" ?k) + ("\\v{k}" ?Ç©) ("\\vk" ?Ç©) ("\\v{\\j}" ?ǰ) ("\\vj" ?ǰ) ("\\'{G}" ?Ç´) ("\\'G" ?Ç´) From c3b232e48e3200d4a3350f73213709e1bf12145c Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Sat, 19 Jan 2008 05:11:02 +0000 Subject: [PATCH 201/439] (set_window_buffer): Don't unnecessarily reset hscroll and vscroll if we're setting window-buffer to the value it already has. --- src/ChangeLog | 5 +++++ src/window.c | 33 +++++++++++++++++++++++---------- 2 files changed, 28 insertions(+), 10 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index d63c039592a..2f30dfcf807 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-01-19 Stefan Monnier + + * window.c (set_window_buffer): Don't unnecessarily reset hscroll and + vscroll if we're setting window-buffer to the value it already has. + 2008-01-18 Dan Nicolaescu * m/intel386.h: Remove references to XENIX. diff --git a/src/window.c b/src/window.c index f1e37b756ab..bf36cbc032f 100644 --- a/src/window.c +++ b/src/window.c @@ -3321,6 +3321,7 @@ set_window_buffer (window, buffer, run_hooks_p, keep_margins_p) struct window *w = XWINDOW (window); struct buffer *b = XBUFFER (buffer); int count = SPECPDL_INDEX (); + int samebuf = EQ (buffer, w->buffer); w->buffer = buffer; @@ -3339,16 +3340,28 @@ set_window_buffer (window, buffer, run_hooks_p, keep_margins_p) XSETFASTINT (w->window_end_vpos, 0); bzero (&w->last_cursor, sizeof w->last_cursor); w->window_end_valid = Qnil; - w->hscroll = w->min_hscroll = make_number (0); - w->vscroll = 0; - set_marker_both (w->pointm, buffer, BUF_PT (b), BUF_PT_BYTE (b)); - set_marker_restricted (w->start, - make_number (b->last_window_start), - buffer); - w->start_at_line_beg = Qnil; - w->force_start = Qnil; - XSETFASTINT (w->last_modified, 0); - XSETFASTINT (w->last_overlay_modified, 0); + if (!(keep_margins_p && samebuf)) + { /* If we're not actually changing the buffer, Don't reset hscroll and + vscroll. This case happens for example when called from + change_frame_size_1, where we use a dummy call to + Fset_window_buffer on the frame's selected window (and no other) + just in order to run window-configuration-change-hook. + Resetting hscroll and vscroll here is problematic for things like + image-mode and doc-view-mode since it resets the image's position + whenever we resize the frame. */ + w->hscroll = w->min_hscroll = make_number (0); + w->vscroll = 0; + set_marker_both (w->pointm, buffer, BUF_PT (b), BUF_PT_BYTE (b)); + set_marker_restricted (w->start, + make_number (b->last_window_start), + buffer); + w->start_at_line_beg = Qnil; + w->force_start = Qnil; + XSETFASTINT (w->last_modified, 0); + XSETFASTINT (w->last_overlay_modified, 0); + } + /* Maybe we could move this into the `if' but it's not obviously safe and + I doubt it's worth the trouble. */ windows_or_buffers_changed++; /* We must select BUFFER for running the window-scroll-functions. From 823e0ebb51743ee935104b98badfa4a015ff231a Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Sat, 19 Jan 2008 05:22:33 +0000 Subject: [PATCH 202/439] (Qauto_hscroll_mode): New var. (syms_of_xdisp): Initialize it. (hscroll_window_tree): Use it to lookup `auto-hscroll-mode' in each window's buffer. (hscroll_windows): Don't check automatic_hscrolling_p here. --- src/ChangeLog | 6 ++++++ src/xdisp.c | 27 ++++++++++++--------------- 2 files changed, 18 insertions(+), 15 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 2f30dfcf807..3e11968fb58 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,11 @@ 2008-01-19 Stefan Monnier + * xdisp.c (Qauto_hscroll_mode): New var. + (syms_of_xdisp): Initialize it. + (hscroll_window_tree): Use it to lookup `auto-hscroll-mode' in each + window's buffer. + (hscroll_windows): Don't check automatic_hscrolling_p here. + * window.c (set_window_buffer): Don't unnecessarily reset hscroll and vscroll if we're setting window-buffer to the value it already has. diff --git a/src/xdisp.c b/src/xdisp.c index 19ee4a0a92d..dfa18bfacb7 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -689,6 +689,7 @@ int trace_move; point visible. */ int automatic_hscrolling_p; +Lisp_Object Qauto_hscroll_mode; /* How close to the margin can point get before the window is scrolled horizontally. */ @@ -10381,11 +10382,12 @@ hscroll_window_tree (window) /* Scroll when cursor is inside this scroll margin. */ h_margin = hscroll_margin * WINDOW_FRAME_COLUMN_WIDTH (w); - if ((XFASTINT (w->hscroll) - && w->cursor.x <= h_margin) - || (cursor_row->enabled_p - && cursor_row->truncated_on_right_p - && (w->cursor.x >= text_area_width - h_margin))) + if (!NILP (Fbuffer_local_value (Qauto_hscroll_mode, w->buffer)) + && ((XFASTINT (w->hscroll) + && w->cursor.x <= h_margin) + || (cursor_row->enabled_p + && cursor_row->truncated_on_right_p + && (w->cursor.x >= text_area_width - h_margin)))) { struct it it; int hscroll; @@ -10475,16 +10477,9 @@ static int hscroll_windows (window) Lisp_Object window; { - int hscrolled_p; - - if (automatic_hscrolling_p) - { - hscrolled_p = hscroll_window_tree (window); - if (hscrolled_p) - clear_desired_matrices (XFRAME (WINDOW_FRAME (XWINDOW (window)))); - } - else - hscrolled_p = 0; + int hscrolled_p = hscroll_window_tree (window); + if (hscrolled_p) + clear_desired_matrices (XFRAME (WINDOW_FRAME (XWINDOW (window)))); return hscrolled_p; } @@ -24387,6 +24382,8 @@ the frame's other specifications determine how to blink the cursor off. */); DEFVAR_BOOL ("auto-hscroll-mode", &automatic_hscrolling_p, doc: /* *Non-nil means scroll the display automatically to make point visible. */); automatic_hscrolling_p = 1; + Qauto_hscroll_mode = intern ("auto-hscroll-mode"); + staticpro (&Qauto_hscroll_mode); DEFVAR_INT ("hscroll-margin", &hscroll_margin, doc: /* *How many columns away from the window edge point is allowed to get From e69c4cae1801f1578819d72dd6c798c4e0b09dde Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Sat, 19 Jan 2008 05:27:20 +0000 Subject: [PATCH 203/439] (list_processes_1): Don't use SCHARS on a nil buffer name. --- src/ChangeLog | 2 ++ src/process.c | 7 +++++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 3e11968fb58..0667c484acb 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,7 @@ 2008-01-19 Stefan Monnier + * process.c (list_processes_1): Don't use SCHARS on a nil buffer name. + * xdisp.c (Qauto_hscroll_mode): New var. (syms_of_xdisp): Initialize it. (hscroll_window_tree): Use it to lookup `auto-hscroll-mode' in each diff --git a/src/process.c b/src/process.c index 8e932be7b0c..c7ca36a847f 100644 --- a/src/process.c +++ b/src/process.c @@ -1359,8 +1359,11 @@ list_processes_1 (query_only) w_proc = i; if (!NILP (p->buffer)) { - if (NILP (XBUFFER (p->buffer)->name) && w_buffer < 8) - w_buffer = 8; /* (Killed) */ + if (NILP (XBUFFER (p->buffer)->name)) + { + if (w_buffer < 8) + w_buffer = 8; /* (Killed) */ + } else if ((i = SCHARS (XBUFFER (p->buffer)->name), (i > w_buffer))) w_buffer = i; } From 38b5ca4a1bf83b3d18473fc8928b9ee0537e3e21 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Sat, 19 Jan 2008 05:34:29 +0000 Subject: [PATCH 204/439] (doc-view-goto-page): Don't move point any more, now that the hscroll behavior was fixed. (doc-view-mode): Disable auto-hscroll-mode. --- lisp/ChangeLog | 8 +++++++- lisp/doc-view.el | 10 ++++------ 2 files changed, 11 insertions(+), 7 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4f1526e0bc3..b3f873c73e3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,6 +1,12 @@ +2008-01-19 Stefan Monnier + + * doc-view.el (doc-view-goto-page): Don't move point any more, now that + the hscroll behavior was fixed. + (doc-view-mode): Disable auto-hscroll-mode. + 2008-01-18 Tom Tromey - * vc-svn.el (vc-svn-dir-status): New function. + * vc-svn.el (vc-svn-dir-status): New function. 2008-01-18 Dan Nicolaescu diff --git a/lisp/doc-view.el b/lisp/doc-view.el index ba4aadb1e6b..034eace3dfb 100644 --- a/lisp/doc-view.el +++ b/lisp/doc-view.el @@ -99,6 +99,7 @@ ;;; Todo: +;; - share more code with image-mode again. ;; - better menu. ;; - Bind slicing to a drag event. ;; - doc-view-fit-doc-to-window and doc-view-fit-window-to-doc. @@ -356,12 +357,7 @@ the (uncompressed, extracted) file residing in ;; Update the buffer (doc-view-insert-image (nth (1- page) doc-view-current-files) :pointer 'arrow) - (overlay-put doc-view-current-overlay 'help-echo doc-view-current-info) - (goto-char (point-min)) - ;; This seems to be needed for set-window-hscroll (in - ;; image-forward-hscroll) to do something useful, I don't have time to - ;; debug this now. :-( --Stef - (forward-char))) + (overlay-put doc-view-current-overlay 'help-echo doc-view-current-info))) (defun doc-view-next-page (&optional arg) "Browse ARG pages forward." @@ -994,6 +990,8 @@ toggle between displaying the document or editing it as text." (set (make-local-variable 'mode-line-position) '(" P" (:eval (number-to-string doc-view-current-page)) "/" (:eval (number-to-string (length doc-view-current-files))))) + ;; Don't scroll unless the user specifically asked for it. + (set (make-local-variable 'auto-hscroll-mode) nil) (set (make-local-variable 'cursor-type) nil) (use-local-map doc-view-mode-map) (set (make-local-variable 'after-revert-hook) 'doc-view-reconvert-doc) From 5a7a1dde2c0cc502c3db47bb867b14534f741867 Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Sat, 19 Jan 2008 05:55:50 +0000 Subject: [PATCH 205/439] (detect_coding_iso2022): New arg latin_extra_code_state. Allow Latin extra codes only when *latin_extra_code_state is nonzero. (detect_coding_mask): If there is a NULL byte, detect the encoding as UTF-16 or binary. If Latin extra codes exist, detect the encoding as ISO-2022 only when there's no other proper encoding is found. --- src/ChangeLog | 10 +++++ src/coding.c | 117 +++++++++++++++++++++++++++++++++++++++----------- 2 files changed, 103 insertions(+), 24 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index b28c1d9ac05..034315cf7cc 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,13 @@ +2008-01-19 Kenichi Handa + + * coding.c (detect_coding_iso2022): New arg + latin_extra_code_state. Allow Latin extra codes only + when *latin_extra_code_state is nonzero. + (detect_coding_mask): If there is a NULL byte, detect the encoding + as UTF-16 or binary. If Latin extra codes exist, detect the + encoding as ISO-2022 only when there's no other proper encoding is + found. + 2008-01-17 Jason Rumney * xterm.c (handle_one_xevent): Revert to counting chars not bytes. diff --git a/src/coding.c b/src/coding.c index 716eb98a87f..dd201ae61d6 100644 --- a/src/coding.c +++ b/src/coding.c @@ -1410,12 +1410,17 @@ enum iso_code_class_type iso_code_class[256]; CODING_CATEGORY_MASK_ISO_7_ELSE CODING_CATEGORY_MASK_ISO_8_ELSE are set. If a code which should never appear in ISO2022 is found, - returns 0. */ + returns 0. + + If *latin_extra_code_state is zero and Latin extra codes are found, + set *latin_extra_code_state to 1 and return 0. If it is nonzero, + accept Latin extra codes. */ static int -detect_coding_iso2022 (src, src_end, multibytep) +detect_coding_iso2022 (src, src_end, multibytep, latin_extra_code_state) unsigned char *src, *src_end; int multibytep; + int *latin_extra_code_state; { int mask = CODING_CATEGORY_MASK_ISO; int mask_found = 0; @@ -1578,6 +1583,11 @@ detect_coding_iso2022 (src, src_end, multibytep) if (VECTORP (Vlatin_extra_code_table) && !NILP (XVECTOR (Vlatin_extra_code_table)->contents[c])) { + if (! *latin_extra_code_state) + { + *latin_extra_code_state = 1; + return 0; + } if (coding_system_table[CODING_CATEGORY_IDX_ISO_8_1]->flags & CODING_FLAG_ISO_LATIN_EXTRA) newmask |= CODING_CATEGORY_MASK_ISO_8_1; @@ -1604,6 +1614,11 @@ detect_coding_iso2022 (src, src_end, multibytep) { int newmask = 0; + if (! *latin_extra_code_state) + { + *latin_extra_code_state = 1; + return 0; + } if (coding_system_table[CODING_CATEGORY_IDX_ISO_8_1]->flags & CODING_FLAG_ISO_LATIN_EXTRA) newmask |= CODING_CATEGORY_MASK_ISO_8_1; @@ -4131,6 +4146,8 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) unsigned char *src = source, *src_end = source + src_bytes; unsigned int mask, utf16_examined_p, iso2022_examined_p; int i; + int null_byte_found; + int latin_extra_code_state = 1; /* At first, skip all ASCII characters and control characters except for three ISO2022 specific control characters. */ @@ -4139,21 +4156,36 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) ascii_skip_code[ISO_CODE_ESC] = 0; label_loop_detect_coding: - while (src < src_end && ascii_skip_code[*src]) src++; + null_byte_found = 0; + /* We stop this loop before the last byte because it may be a NULL + anchor byte. */ + while (src < src_end - 1 && ascii_skip_code[*src]) + null_byte_found |= (! *src++); + if (ascii_skip_code[*src]) + src++; + else if (! null_byte_found) + { + unsigned char *p = src + 1; + while (p < src_end - 1) + null_byte_found |= (! *p++); + } *skip = src - source; if (src >= src_end) - /* We found nothing other than ASCII. There's nothing to do. */ + /* We found nothing other than ASCII (and NULL byte). There's + nothing to do. */ return 0; c = *src; /* The text seems to be encoded in some multilingual coding system. Now, try to find in which coding system the text is encoded. */ - if (c < 0x80) + if (! null_byte_found && c < 0x80) { /* i.e. (c == ISO_CODE_ESC || c == ISO_CODE_SI || c == ISO_CODE_SO) */ /* C is an ISO2022 specific control code of C0. */ - mask = detect_coding_iso2022 (src, src_end, multibytep); + latin_extra_code_state = 1; + mask = detect_coding_iso2022 (src, src_end, multibytep, + &latin_extra_code_state); if (mask == 0) { /* No valid ISO2022 code follows C. Try again. */ @@ -4181,21 +4213,27 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) if (multibytep && c == LEADING_CODE_8_BIT_CONTROL) c = src[1] - 0x20; - if (c < 0xA0) + if (null_byte_found) + { + try = (CODING_CATEGORY_MASK_UTF_16_BE + | CODING_CATEGORY_MASK_UTF_16_LE); + } + else if (c < 0xA0) { /* C is the first byte of SJIS character code, or a leading-code of Emacs' internal format (emacs-mule), or the first byte of UTF-16. */ try = (CODING_CATEGORY_MASK_SJIS - | CODING_CATEGORY_MASK_EMACS_MULE - | CODING_CATEGORY_MASK_UTF_16_BE - | CODING_CATEGORY_MASK_UTF_16_LE); + | CODING_CATEGORY_MASK_EMACS_MULE + | CODING_CATEGORY_MASK_UTF_16_BE + | CODING_CATEGORY_MASK_UTF_16_LE); /* Or, if C is a special latin extra code, or is an ISO2022 specific control code of C1 (SS2 or SS3), or is an ISO2022 control-sequence-introducer (CSI), we should also consider the possibility of ISO2022 codings. */ - if ((VECTORP (Vlatin_extra_code_table) + if ((latin_extra_code_state + && VECTORP (Vlatin_extra_code_table) && !NILP (XVECTOR (Vlatin_extra_code_table)->contents[c])) || (c == ISO_CODE_SS2 || c == ISO_CODE_SS3) || (c == ISO_CODE_CSI @@ -4205,7 +4243,7 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) && src + 1 < src_end && src[1] == ']'))))) try |= (CODING_CATEGORY_MASK_ISO_8_ELSE - | CODING_CATEGORY_MASK_ISO_8BIT); + | CODING_CATEGORY_MASK_ISO_8BIT); } else /* C is a character of ISO2022 in graphic plane right, @@ -4213,29 +4251,36 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) or the first byte of BIG5's 2-byte code, or the first byte of UTF-8/16. */ try = (CODING_CATEGORY_MASK_ISO_8_ELSE - | CODING_CATEGORY_MASK_ISO_8BIT - | CODING_CATEGORY_MASK_SJIS - | CODING_CATEGORY_MASK_BIG5 - | CODING_CATEGORY_MASK_UTF_8 - | CODING_CATEGORY_MASK_UTF_16_BE - | CODING_CATEGORY_MASK_UTF_16_LE); + | CODING_CATEGORY_MASK_ISO_8BIT + | CODING_CATEGORY_MASK_SJIS + | CODING_CATEGORY_MASK_BIG5 + | CODING_CATEGORY_MASK_UTF_8 + | CODING_CATEGORY_MASK_UTF_16_BE + | CODING_CATEGORY_MASK_UTF_16_LE); /* Or, we may have to consider the possibility of CCL. */ - if (coding_system_table[CODING_CATEGORY_IDX_CCL] + if (! null_byte_found + && coding_system_table[CODING_CATEGORY_IDX_CCL] && (coding_system_table[CODING_CATEGORY_IDX_CCL] ->spec.ccl.valid_codes)[c]) try |= CODING_CATEGORY_MASK_CCL; mask = 0; - utf16_examined_p = iso2022_examined_p = 0; if (priorities) { + /* At first try detection with Latin extra codes not-allowed. + If no proper coding system is found because of Latin extra + codes, try detection with Latin extra codes allowed. */ + latin_extra_code_state = 0; + label_retry: + utf16_examined_p = iso2022_examined_p = 0; for (i = 0; i < CODING_CATEGORY_IDX_MAX; i++) { if (!iso2022_examined_p && (priorities[i] & try & CODING_CATEGORY_MASK_ISO)) { - mask |= detect_coding_iso2022 (src, src_end, multibytep); + mask |= detect_coding_iso2022 (src, src_end, multibytep, + &latin_extra_code_state); iso2022_examined_p = 1; } else if (priorities[i] & try & CODING_CATEGORY_MASK_SJIS) @@ -4256,16 +4301,40 @@ detect_coding_mask (source, src_bytes, priorities, skip, multibytep) else if (priorities[i] & try & CODING_CATEGORY_MASK_CCL) mask |= detect_coding_ccl (src, src_end, multibytep); else if (priorities[i] & CODING_CATEGORY_MASK_RAW_TEXT) - mask |= CODING_CATEGORY_MASK_RAW_TEXT; + { + if (latin_extra_code_state == 1) + { + /* Detection of ISO-2022 based coding system + failed because of Latin extra codes. Before + falling back to raw-text, try again with + Latin extra codes allowed. */ + latin_extra_code_state = 2; + try = (mask | CODING_CATEGORY_MASK_ISO_8_ELSE + | CODING_CATEGORY_MASK_ISO_8BIT); + goto label_retry; + } + mask |= CODING_CATEGORY_MASK_RAW_TEXT; + } else if (priorities[i] & CODING_CATEGORY_MASK_BINARY) - mask |= CODING_CATEGORY_MASK_BINARY; + { + if (latin_extra_code_state == 1) + { + /* See the above comment. */ + latin_extra_code_state = 2; + try = (mask | CODING_CATEGORY_MASK_ISO_8_ELSE + | CODING_CATEGORY_MASK_ISO_8BIT); + goto label_retry; + } + mask |= CODING_CATEGORY_MASK_BINARY; + } if (mask & priorities[i]) return priorities[i]; } return CODING_CATEGORY_MASK_RAW_TEXT; } if (try & CODING_CATEGORY_MASK_ISO) - mask |= detect_coding_iso2022 (src, src_end, multibytep); + mask |= detect_coding_iso2022 (src, src_end, multibytep, + &latin_extra_code_state); if (try & CODING_CATEGORY_MASK_SJIS) mask |= detect_coding_sjis (src, src_end, multibytep); if (try & CODING_CATEGORY_MASK_BIG5) From 5169d86148ea4edac7726c094e179dad1751dfe3 Mon Sep 17 00:00:00 2001 From: Kenichi Handa Date: Sat, 19 Jan 2008 12:50:35 +0000 Subject: [PATCH 206/439] *** empty log message *** --- leim/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/leim/ChangeLog b/leim/ChangeLog index cc29276bed1..e098945cdd9 100644 --- a/leim/ChangeLog +++ b/leim/ChangeLog @@ -1,4 +1,4 @@ -2008-01-14 Aidan Kehoe +2008-01-14 Aidan Kehoe (tiny change) * quail/latin-ltx.el ("TeX"): Correct the mappings for \v{k} and \vk. From 404967ca97ee9da387d06a6d79371bbb3fb7c2bb Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 19 Jan 2008 14:04:35 +0000 Subject: [PATCH 207/439] Add comment before kill-buffer-if-not-modified. --- lisp/view.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/view.el b/lisp/view.el index bdf7f6a5728..c89fd692152 100644 --- a/lisp/view.el +++ b/lisp/view.el @@ -238,6 +238,10 @@ This is local in each buffer, once it is used.") ;;; Commands that enter or exit view mode. +;; This is used when view mode is exited, to make sure we don't try to +;; kill a buffer modified by the user. A buffer in view mode can +;; become modified if the user types C-x C-q, edits the buffer, then +;; types C-x C-q again to return to view mode. (defun kill-buffer-if-not-modified (buf) "Like `kill-buffer', but does nothing if the buffer is modified." (let ((buf (or (bufferp buf) (get-buffer buf)))) From 3df7f6458d0ad30331f8e3f00ccf818e6424da1c Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Sat, 19 Jan 2008 15:13:09 +0000 Subject: [PATCH 208/439] (blank-style, blank-chars, blank-hspace-regexp, blank-space-regexp, blank-tab-regexp, blank-trailing-regexp, blank-space-before-tab-regexp, blank-global-modes, blank-mode, global-blank-mode): Doc fixes. (blank, blank-space-face, blank-hspace-face, blank-tab-face, blank-newline-face, blank-trailing-face, blank-line-face, blank-space-before-tab-face, blank-display-mappings, blank-chars-value-list, blank-style-value-list, blank-toggle-options, global-blank-toggle-options, blank-help-text, blank-interactive-char, blank-turn-on, blank-turn-off, blank-color-on, blank-color-off): Fix typos in docstrings. --- lisp/ChangeLog | 24 ++++- lisp/blank-mode.el | 228 ++++++++++++++++++++++----------------------- 2 files changed, 133 insertions(+), 119 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1611261964b..fbf675d8f7e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,10 +1,24 @@ +2008-01-19 Juanma Barranquero + + * blank-mode.el (blank-style, blank-chars, blank-hspace-regexp) + (blank-space-regexp, blank-tab-regexp, blank-trailing-regexp) + (blank-space-before-tab-regexp, blank-global-modes, blank-mode) + (global-blank-mode): Doc fixes. + (blank, blank-space-face, blank-hspace-face, blank-tab-face) + (blank-newline-face, blank-trailing-face, blank-line-face) + (blank-space-before-tab-face, blank-display-mappings) + (blank-chars-value-list, blank-style-value-list, blank-toggle-options) + (global-blank-toggle-options, blank-help-text, blank-interactive-char) + (blank-turn-on, blank-turn-off, blank-color-on, blank-color-off): + Fix typos in docstrings. + 2008-01-18 Richard Stallman * icomplete.el (icomplete-get-keys): Look up KEYS using all maps in proper buffer. -2008-01-17 Vinicius Jose Latorre -2008-01-17 Miles Bader +2008-01-17 Vinicius Jose Latorre + Miles Bader * blank-mode.el: New file. Minor mode to visualise TAB, (HARD) SPACE, NEWLINE. Miles Bader wrote the original @@ -143,7 +157,7 @@ * vc-hg.el (vc-hg-diff): Don't pass an empty string. -2008-01-09 Wilson Snyder +2008-01-09 Wilson Snyder * progmodes/verilog-mode.el (top-level): Fix spacing. (verilog-mode-version, verilog-mode-release-date): Update version @@ -610,8 +624,8 @@ (verilog-emacs-features, verilog-auto-ascii-enum) (verilog-insert-indices): Escape braces in doc strings. -2007-12-08 Michael McNamara - Wilson Snyder +2007-12-08 Michael McNamara + Wilson Snyder * progmodes/verilog-mode.el: New file. diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el index 3a57f2e971c..112562af576 100644 --- a/lisp/blank-mode.el +++ b/lisp/blank-mode.el @@ -1,4 +1,4 @@ -;;; blank-mode.el --- minor mode to visualise TAB, (HARD) SPACE, NEWLINE +;;; blank-mode.el --- minor mode to visualize TAB, (HARD) SPACE, NEWLINE ;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 ;; Free Software Foundation, Inc. @@ -33,10 +33,10 @@ ;; Introduction ;; ------------ ;; -;; This package is a minor mode to visualise blanks (TAB, (HARD) SPACE +;; This package is a minor mode to visualize blanks (TAB, (HARD) SPACE ;; and NEWLINE). ;; -;; blank-mode uses two ways to visualise blanks: faces and display +;; blank-mode uses two ways to visualize blanks: faces and display ;; table. ;; ;; * Faces are used to highlight the background with a color. @@ -47,7 +47,7 @@ ;; of line (?\xB6), at SPACEs (?\xB7) and at TABs (?\xBB). ;; ;; The `blank-style' and `blank-chars' variables are used to select -;; which way should be used to visualise blanks. +;; which way should be used to visualize blanks. ;; ;; Note that when blank-mode is turned on, blank-mode saves the ;; font-lock state, that is, if font-lock is on or off. And @@ -94,7 +94,7 @@ ;; `global-blank-toggle-options'. For example: ;; ;; (autoload 'blank-mode "blank-mode" -;; "Toggle blank visualisation." t) +;; "Toggle blank visualization." t) ;; (autoload 'blank-toggle-options "blank-mode" ;; "Toggle local `blank-mode' options." t) ;; @@ -175,26 +175,26 @@ ;; Below it's shown a brief description of blank-mode options, please, ;; see the options declaration in the code for a long documentation. ;; -;; `blank-style' Specify the visualisation style. +;; `blank-style' Specify the visualization style. ;; ;; `blank-chars' Specify which kind of blank is -;; visualised. +;; visualized. ;; -;; `blank-space-face' Face used to visualise SPACE. +;; `blank-space-face' Face used to visualize SPACE. ;; -;; `blank-hspace-face' Face used to visualise HARD SPACE. +;; `blank-hspace-face' Face used to visualize HARD SPACE. ;; -;; `blank-tab-face' Face used to visualise TAB. +;; `blank-tab-face' Face used to visualize TAB. ;; -;; `blank-newline-face' Face used to visualise NEWLINE char +;; `blank-newline-face' Face used to visualize NEWLINE char ;; mapping. ;; -;; `blank-trailing-face' Face used to visualise trailing +;; `blank-trailing-face' Face used to visualize trailing ;; blanks. ;; -;; `blank-line-face' Face used to visualise "long" lines. +;; `blank-line-face' Face used to visualize "long" lines. ;; -;; `blank-space-before-tab-face' Face used to visualise SPACEs +;; `blank-space-before-tab-face' Face used to visualize SPACEs ;; before TAB. ;; ;; `blank-space-regexp' Specify SPACE characters regexp. @@ -268,7 +268,7 @@ (defgroup blank nil - "Visualise blanks (TAB, (HARD) SPACE and NEWLINE)." + "Visualize blanks (TAB, (HARD) SPACE and NEWLINE)." :link '(emacs-library-link :tag "Source Lisp File" "blank-mode.el") :version "22.2" :group 'wp @@ -276,17 +276,17 @@ (defcustom blank-style '(mark color) - "*Specify the visualisation style. + "*Specify the visualization style. It's a list which element value can be: - mark display mappings are visualised. + mark display mappings are visualized. - color faces are visualised. + color faces are visualized. Any other value is ignored. -If it's nil, don't visualise TABs, (HARD) SPACEs and NEWLINEs. +If nil, don't visualize TABs, (HARD) SPACEs and NEWLINEs. See also `blank-display-mappings' for documentation." :type '(repeat :tag "Style of Blank" @@ -298,26 +298,26 @@ See also `blank-display-mappings' for documentation." (defcustom blank-chars '(tabs spaces trailing lines space-before-tab newline) - "*Specify which kind of blank is visualised. + "*Specify which kind of blank is visualized. It's a list which element value can be: - trailing trailing blanks are visualised. + trailing trailing blanks are visualized. - tabs TABs are visualised. + tabs TABs are visualized. - spaces SPACEs and HARD SPACEs are visualised. + spaces SPACEs and HARD SPACEs are visualized. lines lines whose length is greater than `blank-line-length' are highlighted. - space-before-tab SPACEs before TAB are visualised. + space-before-tab SPACEs before TAB are visualized. - newline NEWLINEs are visualised. + newline NEWLINEs are visualized. -Any other element value is ignored. +Any other value is ignored. -If it's nil, don't visualise TABs, (HARD) SPACEs and NEWLINEs. +If nil, don't visualize TABs, (HARD) SPACEs and NEWLINEs. Used when `blank-style' has `color' as an element. If `blank-chars' has `newline' as an element, used when `blank-style' @@ -336,7 +336,7 @@ has `mark' as an element." (defcustom blank-space-face 'blank-space-face - "*Symbol face used to visualise SPACE. + "*Symbol face used to visualize SPACE. Used when `blank-style' has `color' as an element." :type 'face @@ -349,12 +349,12 @@ Used when `blank-style' has `color' as an element." (((class color) (background light)) (:background "LightYellow" :foreground "aquamarine3")) (t (:inverse-video t))) - "Face used to visualise SPACE." + "Face used to visualize SPACE." :group 'blank) (defcustom blank-hspace-face 'blank-hspace-face - "*Symbol face used to visualise HARD SPACE. + "*Symbol face used to visualize HARD SPACE. Used when `blank-style' has `color' as an element." :type 'face @@ -367,12 +367,12 @@ Used when `blank-style' has `color' as an element." (((class color) (background light)) (:background "LemonChiffon3" :foreground "aquamarine3")) (t (:inverse-video t))) - "Face used to visualise HARD SPACE." + "Face used to visualize HARD SPACE." :group 'blank) (defcustom blank-tab-face 'blank-tab-face - "*Symbol face used to visualise TAB. + "*Symbol face used to visualize TAB. Used when `blank-style' has `color' as an element." :type 'face @@ -385,12 +385,12 @@ Used when `blank-style' has `color' as an element." (((class color) (background light)) (:background "beige" :foreground "aquamarine3")) (t (:inverse-video t))) - "Face used to visualise TAB." + "Face used to visualize TAB." :group 'blank) (defcustom blank-newline-face 'blank-newline-face - "*Symbol face used to visualise NEWLINE char mapping. + "*Symbol face used to visualize NEWLINE char mapping. See `blank-display-mappings'. @@ -406,14 +406,14 @@ and `blank-chars' has `newline' as an element." (((class color) (background light)) (:background "linen" :foreground "aquamarine3" :bold t)) (t (:bold t :underline t))) - "Face used to visualise NEWLINE char mapping. + "Face used to visualize NEWLINE char mapping. See `blank-display-mappings'." :group 'blank) (defcustom blank-trailing-face 'blank-trailing-face - "*Symbol face used to visualise traling blanks. + "*Symbol face used to visualize traling blanks. Used when `blank-style' has `color' as an element." :type 'face @@ -423,14 +423,14 @@ Used when `blank-style' has `color' as an element." (defface blank-trailing-face ; 'trailing-whitespace '((((class mono)) (:inverse-video t :bold t :underline t)) (t (:background "red1" :foreground "yellow" :bold t))) - "Face used to visualise trailing blanks." + "Face used to visualize trailing blanks." :group 'blank) (defcustom blank-line-face 'blank-line-face - "*Symbol face used to visualise \"long\" lines. + "*Symbol face used to visualize \"long\" lines. -See `blank-line-legnth'. +See `blank-line-length'. Used when `blank-style' has `color' as an element." :type 'face @@ -440,14 +440,14 @@ Used when `blank-style' has `color' as an element." (defface blank-line-face '((((class mono)) (:inverse-video t :bold t :underline t)) (t (:background "gray20" :foreground "violet"))) - "Face used to visualise \"long\" lines. + "Face used to visualize \"long\" lines. See `blank-line-length'." :group 'blank) (defcustom blank-space-before-tab-face 'blank-space-before-tab-face - "*Symbol face used to visualise SPACEs before TAB. + "*Symbol face used to visualize SPACEs before TAB. Used when `blank-style' has `color' as an element." :type 'face @@ -457,7 +457,7 @@ Used when `blank-style' has `color' as an element." (defface blank-space-before-tab-face '((((class mono)) (:inverse-video t :bold t :underline t)) (t (:background "DarkOrange" :foreground "firebrick"))) - "Face used to visualise SPACEs before TAB." + "Face used to visualize SPACEs before TAB." :group 'blank) @@ -469,18 +469,18 @@ If you're using `mule' package, it may exist other characters besides: \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \"\\xF20\" -that it should be considered HARD SPACE. +that should be considered HARD SPACE. Here are some examples: \"\\\\(^\\xA0+\\\\)\" \ -visualise only leading HARD SPACEs. +visualize only leading HARD SPACEs. \"\\\\(\\xA0+$\\\\)\" \ -visualise only trailing HARD SPACEs. +visualize only trailing HARD SPACEs. \"\\\\(^\\xA0+\\\\|\\xA0+$\\\\)\" \ -visualise leading and/or trailing HARD SPACEs. +visualize leading and/or trailing HARD SPACEs. \"\\t\\\\(\\xA0+\\\\)\\t\" \ -visualise only HARD SPACEs between TABs. +visualize only HARD SPACEs between TABs. NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. Use exactly one pair of enclosing \\\\( and \\\\). @@ -495,15 +495,15 @@ Used when `blank-style' has `color' as an element, and "*Specify SPACE characters regexp. If you're using `mule' package, it may exist other characters -besides \" \" that it should be considered SPACE. +besides \" \" that should be considered SPACE. Here are some examples: - \"\\\\(^ +\\\\)\" visualise only leading SPACEs. - \"\\\\( +$\\\\)\" visualise only trailing SPACEs. + \"\\\\(^ +\\\\)\" visualize only leading SPACEs. + \"\\\\( +$\\\\)\" visualize only trailing SPACEs. \"\\\\(^ +\\\\| +$\\\\)\" \ -visualise leading and/or trailing SPACEs. - \"\\t\\\\( +\\\\)\\t\" visualise only SPACEs between TABs. +visualize leading and/or trailing SPACEs. + \"\\t\\\\( +\\\\)\\t\" visualize only SPACEs between TABs. NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. Use exactly one pair of enclosing \\\\( and \\\\). @@ -518,15 +518,15 @@ Used when `blank-style' has `color' as an element, and "*Specify TAB characters regexp. If you're using `mule' package, it may exist other characters -besides \"\\t\" that it should be considered TAB. +besides \"\\t\" that should be considered TAB. Here are some examples: - \"\\\\(^\\t+\\\\)\" visualise only leading TABs. - \"\\\\(\\t+$\\\\)\" visualise only trailing TABs. + \"\\\\(^\\t+\\\\)\" visualize only leading TABs. + \"\\\\(\\t+$\\\\)\" visualize only trailing TABs. \"\\\\(^\\t+\\\\|\\t+$\\\\)\" \ -visualise leading and/or trailing TABs. - \" \\\\(\\t+\\\\) \" visualise only TABs between SPACEs. +visualize leading and/or trailing TABs. + \" \\\\(\\t+\\\\) \" visualize only TABs between SPACEs. NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. Use exactly one pair of enclosing \\\\( and \\\\). @@ -546,9 +546,9 @@ If you're using `mule' package, it may exist other characters besides: \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ \"\\xF20\" -that it should be considered blank. +that should be considered blank. -NOTE: DOES NOT enclose by \\\\( and \\\\) the elements to highlight. +NOTE: DO NOT enclose by \\\\( and \\\\) the elements to highlight. `blank-mode' surrounds this regexp by \"\\\\(\\\\(\" and \"\\\\)+\\\\)$\". @@ -566,7 +566,7 @@ If you're using `mule' package, it may exist other characters besides: \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ \"\\xF20\" -that it should be considered blank. +that should be considered blank. Used when `blank-style' has `color' as an element, and `blank-chars' has `space-before-tab' as an element." @@ -627,7 +627,7 @@ VECTOR is a vector of characters to be displayed in place of CHAR. The NEWLINE character is displayed using the face given by `blank-newline-face' variable. The characters in the vector to be -displayed will not have applied this face if the character code is +displayed will not have this face applied if the character code is above #x1FFFF. Used when `blank-style' has `mark' as an element." @@ -650,7 +650,7 @@ Global `blank-mode' is controlled by the command `global-blank-mode'. If nil, means no modes have `blank-mode' automatically turned on. If t, all modes that support `blank-mode' have it automatically turned on. -If a list, it should be a list of `major-mode' symbol names for +Else it should be a list of `major-mode' symbol names for which `blank-mode' should be automatically turned on. The sense of the list is negated if it begins with `not'. For example: @@ -674,11 +674,11 @@ modes only." ;;;###autoload (define-minor-mode blank-mode - "Toggle blank minor mode visualisation (bl on modeline). + "Toggle blank minor mode visualization (\"bl\" on modeline). -If ARG is null, toggle blank visualisation. -If ARG is a number and is greater than zero, turn on -visualisation; otherwise, turn off visualisation. +If ARG is null, toggle blank visualization. +If ARG is a number greater than zero, turn on visualization; +otherwise, turn off visualization. Only useful with a windowing system." :lighter " bl" :init-value nil @@ -698,11 +698,11 @@ Only useful with a windowing system." (define-minor-mode global-blank-mode - "Toggle blank global minor mode visualisation (BL on modeline). + "Toggle blank global minor mode visualization (\"BL\" on modeline). -If ARG is null, toggle blank visualisation. -If ARG is a number and is greater than zero, turn on -visualisation; otherwise, turn off visualisation. +If ARG is null, toggle blank visualization. +If ARG is a number greater than zero, turn on visualization; +otherwise, turn off visualization. Only useful with a windowing system." :lighter " BL" :init-value nil @@ -766,14 +766,14 @@ Only useful with a windowing system." lines newline ) - "List of valid `blank-chars' value.") + "List of valid `blank-chars' values.") (defconst blank-style-value-list '(color mark ) - "List of valid `blank-style' value.") + "List of valid `blank-style' values.") (defconst blank-toggle-option-alist @@ -824,27 +824,27 @@ restart local blank-mode. Interactively, it reads one of the following chars: CHAR MEANING - t toggle TAB visualisation - s toggle SPACE and HARD SPACE visualisation - r toggle trailing blanks visualisation - b toggle SPACEs before TAB visualisation - l toggle \"long lines\" visualisation - n toggle NEWLINE visualisation + t toggle TAB visualization + s toggle SPACE and HARD SPACE visualization + r toggle trailing blanks visualization + b toggle SPACEs before TAB visualization + l toggle \"long lines\" visualization + n toggle NEWLINE visualization c toggle color faces m toggle visual mark x restore `blank-chars' value z restore `blank-style' value ? display brief help -Non-interactively, ARG should be a symbol or a list of symbol. +Non-interactively, ARG should be a symbol or a list of symbols. The valid symbols are: - tabs toggle TAB visualisation - spaces toggle SPACE and HARD SPACE visualisation - trailing toggle trailing blanks visualisation - space-before-tab toggle SPACEs before TAB visualisation - lines toggle \"long lines\" visualisation - newline toggle NEWLINE visualisation + tabs toggle TAB visualization + spaces toggle SPACE and HARD SPACE visualization + trailing toggle trailing blanks visualization + space-before-tab toggle SPACEs before TAB visualization + lines toggle \"long lines\" visualization + newline toggle NEWLINE visualization color toggle color faces mark toggle visual mark blank-chars restore `blank-chars' value @@ -881,27 +881,27 @@ restart global blank-mode. Interactively, it reads one of the following chars: CHAR MEANING - t toggle TAB visualisation - s toggle SPACE and HARD SPACE visualisation - r toggle trailing blanks visualisation - b toggle SPACEs before TAB visualisation - l toggle \"long lines\" visualisation - n toggle NEWLINE visualisation + t toggle TAB visualization + s toggle SPACE and HARD SPACE visualization + r toggle trailing blanks visualization + b toggle SPACEs before TAB visualization + l toggle \"long lines\" visualization + n toggle NEWLINE visualization c toggle color faces m toggle visual mark x restore `blank-chars' value z restore `blank-style' value ? display brief help -Non-interactively, ARG should be a symbol or a list of symbol. +Non-interactively, ARG should be a symbol or a list of symbols. The valid symbols are: - tabs toggle TAB visualisation - spaces toggle SPACE and HARD SPACE visualisation - trailing toggle trailing blanks visualisation - space-before-tab toggle SPACEs before TAB visualisation - lines toggle \"long lines\" visualisation - newline toggle NEWLINE visualisation + tabs toggle TAB visualization + spaces toggle SPACE and HARD SPACE visualization + trailing toggle trailing blanks visualization + space-before-tab toggle SPACEs before TAB visualization + lines toggle \"long lines\" visualization + newline toggle NEWLINE visualization color toggle color faces mark toggle visual mark blank-chars restore `blank-chars' value @@ -942,12 +942,12 @@ Only useful with a windowing system." "\ blank-mode toggle options: - [] t - toggle TAB visualisation - [] s - toggle SPACE and HARD SPACE visualisation - [] r - toggle trailing blanks visualisation - [] b - toggle SPACEs before TAB visualisation - [] l - toggle \"long lines\" visualisation - [] n - toggle NEWLINE visualisation + [] t - toggle TAB visualization + [] s - toggle SPACE and HARD SPACE visualization + [] r - toggle trailing blanks visualization + [] b - toggle SPACEs before TAB visualization + [] l - toggle \"long lines\" visualization + [] n - toggle NEWLINE visualization [] c - toggle color faces [] m - toggle visual mark @@ -1013,12 +1013,12 @@ uses a global context. It reads one of the following chars: CHAR MEANING - t toggle TAB visualisation - s toggle SPACE and HARD SPACE visualisation - r toggle trailing blanks visualisation - b toggle SPACEs before TAB visualisation - l toggle \"long lines\" visualisation - n toggle NEWLINE visualisation + t toggle TAB visualization + s toggle SPACE and HARD SPACE visualization + r toggle trailing blanks visualization + b toggle SPACEs before TAB visualization + l toggle \"long lines\" visualization + n toggle NEWLINE visualization c toggle color faces m toggle visual mark x restore `blank-chars' value @@ -1098,7 +1098,7 @@ options are valid." (defun blank-turn-on () - "Turn on blank visualisation." + "Turn on blank visualization." (setq blank-active-style (if (listp blank-style) blank-style (list blank-style))) @@ -1112,7 +1112,7 @@ options are valid." (defun blank-turn-off () - "Turn off blank visualisation." + "Turn off blank visualization." (and (memq 'color blank-active-style) (blank-color-off)) (and (memq 'mark blank-active-style) @@ -1120,7 +1120,7 @@ options are valid." (defun blank-color-on () - "Turn on color visualisation." + "Turn on color visualization." (when blank-active-chars (unless blank-font-lock (setq blank-font-lock t @@ -1176,7 +1176,7 @@ options are valid." (defun blank-color-off () - "Turn off color visualisation." + "Turn off color visualization." (when blank-active-chars (when blank-font-lock (setq blank-font-lock nil From c041e2d1a31cd24b54651d1b9a993d26a0c4a021 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Sat, 19 Jan 2008 15:24:59 +0000 Subject: [PATCH 209/439] *** empty log message *** --- src/ChangeLog | 12 +++++------- 1 file changed, 5 insertions(+), 7 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 034315cf7cc..1ec2ad7aa85 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,12 +1,10 @@ 2008-01-19 Kenichi Handa - * coding.c (detect_coding_iso2022): New arg - latin_extra_code_state. Allow Latin extra codes only - when *latin_extra_code_state is nonzero. + * coding.c (detect_coding_iso2022): New arg latin_extra_code_state. + Allow Latin extra codes only when *latin_extra_code_state is nonzero. (detect_coding_mask): If there is a NULL byte, detect the encoding - as UTF-16 or binary. If Latin extra codes exist, detect the - encoding as ISO-2022 only when there's no other proper encoding is - found. + as UTF-16 or binary. If Latin extra codes exist, detect the encoding + as ISO-2022 only when no other proper encoding is found. 2008-01-17 Jason Rumney @@ -14,7 +12,7 @@ * w32term.c (w32_read_socket) : Decode characters outside the unicode range available in MULE by locale-coding-system. - Improve dbcs lead byte detection. Set event timestamp and modifiers + Improve dbcs lead byte detection. Set event timestamp and modifiers earlier. 2008-01-17 Glenn Morris From f3a221cf73ddcb68d168d2a3e81c4ad60881525e Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sat, 19 Jan 2008 16:29:08 +0000 Subject: [PATCH 210/439] (hide-ifdef-shadow): New option. (hide-ifdef-shadow): New face. (hide-ifdef-toggle-shadowing): New function to toggle between shadowing and making code invisible. (hide-ifdef-mode-submap): Add binding for hide-ifdef-toggle-shadowing. (hide-ifdef-mode-menu): Add entry for hide-ifdef-toggle-shadowing. (hide-ifdef-region-internal): Give new overlay hide-ifdef property. Shadow text when hide-ifdef-shadow is non-nil. (hif-show-ifdef-region): Remove overlays with hide-ifdef property set. (hif-hide-line): Use when instead of if. (hide-ifdef-initially, hide-ifdef-read-only, hide-ifdef-lines): Remove unneeded * from doc-strings. --- lisp/ChangeLog | 18 +++++++++++++ lisp/progmodes/hideif.el | 56 +++++++++++++++++++++++++++++++--------- 2 files changed, 62 insertions(+), 12 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b3f873c73e3..cab7c60b452 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,21 @@ +2008-01-19 Martin Rudalics + + * progmodes/hideif.el (hide-ifdef-shadow): New option. + (hide-ifdef-shadow): New face. + (hide-ifdef-toggle-shadowing): New function to toggle between + shadowing and making code invisible. + (hide-ifdef-mode-submap): Add binding for + hide-ifdef-toggle-shadowing. + (hide-ifdef-mode-menu): Add entry for + hide-ifdef-toggle-shadowing. + (hide-ifdef-region-internal): Give new overlay hide-ifdef + property. Shadow text when hide-ifdef-shadow is non-nil. + (hif-show-ifdef-region): Remove overlays with hide-ifdef + property set. + (hif-hide-line): Use when instead of if. + (hide-ifdef-initially, hide-ifdef-read-only, hide-ifdef-lines): + Remove unneeded * from doc-strings. + 2008-01-19 Stefan Monnier * doc-view.el (doc-view-goto-page): Don't move point any more, now that diff --git a/lisp/progmodes/hideif.el b/lisp/progmodes/hideif.el index 126b5310ccc..0d2bf1a656a 100644 --- a/lisp/progmodes/hideif.el +++ b/lisp/progmodes/hideif.el @@ -128,6 +128,7 @@ (define-key map "\C-s" 'show-ifdef-block) (define-key map "\C-q" 'hide-ifdef-toggle-read-only) + (define-key map "\C-w" 'hide-ifdef-toggle-shadowing) (substitute-key-definition 'toggle-read-only 'hide-ifdef-toggle-outside-read-only map) map) @@ -155,7 +156,9 @@ ["Use an alist" hide-ifdef-use-define-alist t] ["Undefine a variable" hide-ifdef-undef t] ["Toggle read only" hide-ifdef-toggle-read-only - :style toggle :selected hide-ifdef-read-only])) + :style toggle :selected hide-ifdef-read-only] + ["Toggle shadowing" hide-ifdef-toggle-shadowing + :style toggle :selected hide-ifdef-shadow])) (defvar hide-ifdef-hiding nil "Non-nil when text may be hidden.") @@ -256,9 +259,12 @@ how the hiding is done: (end-of-line 2))) (defun hide-ifdef-region-internal (start end) - (remove-overlays start end 'invisible 'hide-ifdef) + (remove-overlays start end 'hide-ifdef t) (let ((o (make-overlay start end))) - (overlay-put o 'invisible 'hide-ifdef))) + (overlay-put o 'hide-ifdef t) + (if hide-ifdef-shadow + (overlay-put o 'face 'hide-ifdef-shadow) + (overlay-put o 'invisible 'hide-ifdef)))) (defun hide-ifdef-region (start end) "START is the start of a #if or #else form. END is the ending part. @@ -270,7 +276,7 @@ Everything including these lines is made invisible." (defun hif-show-ifdef-region (start end) "Everything between START and END is made visible." - (remove-overlays start end 'invisible 'hide-ifdef)) + (remove-overlays start end 'hide-ifdef t)) ;;===%%SF%% evaluation (Start) === @@ -740,11 +746,11 @@ Point is left unchanged." (defun hif-hide-line (point) "Hide the line containing point. Does nothing if `hide-ifdef-lines' is nil." - (if hide-ifdef-lines - (save-excursion - (goto-char point) - (hide-ifdef-region-internal (line-beginning-position) - (progn (hif-end-of-line) (point)))))) + (when hide-ifdef-lines + (save-excursion + (goto-char point) + (hide-ifdef-region-internal + (line-beginning-position) (progn (hif-end-of-line) (point)))))) ;;; Hif-Possibly-Hide @@ -829,22 +835,33 @@ It does not do the work that's pointless to redo on a recursive entry." ;;;###autoload (defcustom hide-ifdef-initially nil - "*Non-nil means call `hide-ifdefs' when Hide-Ifdef mode is first activated." + "Non-nil means call `hide-ifdefs' when Hide-Ifdef mode is first activated." :type 'boolean :group 'hide-ifdef) ;;;###autoload (defcustom hide-ifdef-read-only nil - "*Set to non-nil if you want buffer to be read-only while hiding text." + "Set to non-nil if you want buffer to be read-only while hiding text." :type 'boolean :group 'hide-ifdef) ;;;###autoload (defcustom hide-ifdef-lines nil - "*Non-nil means hide the #ifX, #else, and #endif lines." + "Non-nil means hide the #ifX, #else, and #endif lines." :type 'boolean :group 'hide-ifdef) +;;;###autoload +(defcustom hide-ifdef-shadow nil + "Non-nil means shadow text instead of hiding it." + :type 'boolean + :group 'hide-ifdef) + +;;;###autoload +(defface hide-ifdef-shadow '((t (:inherit shadow))) + "Face for shadowing ifdef blocks." + :group 'hide-ifdef) + (defun hide-ifdef-toggle-read-only () "Toggle `hide-ifdef-read-only'." (interactive) @@ -866,6 +883,21 @@ It does not do the work that's pointless to redo on a recursive entry." hif-outside-read-only)) (force-mode-line-update)) +(defun hide-ifdef-toggle-shadowing () + "Toggle shadowing." + (interactive) + (set (make-local-variable 'hide-ifdef-shadow) (not hide-ifdef-shadow)) + (message "Shadowing %s" (if hide-ifdef-shadow "ON" "OFF")) + (save-restriction + (widen) + (dolist (overlay (overlays-in (point-min) (point-max))) + (when (overlay-get overlay 'hide-ifdef) + (if hide-ifdef-shadow + (progn + (overlay-put overlay 'invisible nil) + (overlay-put overlay 'face 'hide-ifdef-shadow)) + (overlay-put overlay 'face nil) + (overlay-put overlay 'invisible 'hide-ifdef)))))) (defun hide-ifdef-define (var) "Define a VAR so that #ifdef VAR would be included." From c222c25fd0a2b9631c732b1cb561796d0b584c8a Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sat, 19 Jan 2008 16:32:23 +0000 Subject: [PATCH 211/439] * vc-svn.el (vc-svn-after-dir-status): New function. (vc-svn-dir-status): Run svn asynchronously. --- lisp/ChangeLog | 5 +++++ lisp/vc-svn.el | 50 ++++++++++++++++++++++++++++---------------------- 2 files changed, 33 insertions(+), 22 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index cab7c60b452..30ab6bda2a8 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-19 Tom Tromey + + * vc-svn.el (vc-svn-after-dir-status): New function. + (vc-svn-dir-status): Run svn asynchronously. + 2008-01-19 Martin Rudalics * progmodes/hideif.el (hide-ifdef-shadow): New option. diff --git a/lisp/vc-svn.el b/lisp/vc-svn.el index b8d04d67c70..b3db2df7f69 100644 --- a/lisp/vc-svn.el +++ b/lisp/vc-svn.el @@ -158,28 +158,34 @@ If you want to force an empty list of arguments, use t." (vc-svn-command t 0 nil "status" (if localp "-v" "-u")) (vc-svn-parse-status)))) -(defun vc-svn-dir-status (dir) - "Return a list of conses (FILE . STATE) for DIR." - (with-temp-buffer - (let ((default-directory (file-name-as-directory dir)) - (state-map '((?A . added) - (?C . edited) - (?D . removed) - (?I . ignored) - (?M . edited) - (?R . removed) - (?? . unregistered) - ;; This is what vc-svn-parse-status does. - (?~ . edited))) - result) - (vc-svn-command t 0 nil "status") - (goto-char (point-min)) - (while (re-search-forward "^\\(.\\)..... \\(.*\\)$" nil t) - (let ((state (cdr (assq (aref (match-string 1) 0) state-map))) - (filename (match-string 2))) - (when state - (setq result (cons (cons filename state) result))))) - result))) +(defun vc-svn-after-dir-status (callback buffer) + (let ((state-map '((?A . added) + (?C . edited) + (?D . removed) + (?I . ignored) + (?M . edited) + (?R . removed) + (?? . unregistered) + ;; This is what vc-svn-parse-status does. + (?~ . edited))) + result) + (goto-char (point-min)) + (while (re-search-forward "^\\(.\\)..... \\(.*\\)$" nil t) + (let ((state (cdr (assq (aref (match-string 1) 0) state-map))) + (filename (match-string 2))) + (when state + (setq result (cons (cons filename state) result))))) + (funcall callback result buffer))) + +(defun vc-svn-dir-status (dir callback buffer) + "Run 'svn status' for DIR and update BUFFER via CALLBACK. +CALLBACK is called as (CALLBACK RESULT BUFFER), where +RESULT is a list of conses (FILE . STATE) for directory DIR." + (with-current-buffer (get-buffer-create + (generate-new-buffer-name " *vc svn status*")) + (vc-svn-command (current-buffer) 'async nil "status") + (vc-exec-after + `(vc-svn-after-dir-status (quote ,callback) ,buffer)))) (defun vc-svn-working-revision (file) "SVN-specific version of `vc-working-revision'." From fc9a9287570dfefe8ca48134050b00b1bda6fa89 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sat, 19 Jan 2008 18:32:34 +0000 Subject: [PATCH 212/439] * progmodes/sh-script.el (sh-basic-offset): * progmodes/cc-vars.el (c-syntactic-indentation) (c-syntactic-indentation-in-macros): Mark as safe. --- lisp/ChangeLog | 6 ++++++ lisp/progmodes/cc-vars.el | 2 ++ lisp/progmodes/sh-script.el | 1 + 3 files changed, 9 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index fbf675d8f7e..8f7c6e73504 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-19 Dan Nicolaescu + + * progmodes/sh-script.el (sh-basic-offset): + * progmodes/cc-vars.el (c-syntactic-indentation) + (c-syntactic-indentation-in-macros): Mark as safe. + 2008-01-19 Juanma Barranquero * blank-mode.el (blank-style, blank-chars, blank-hspace-regexp) diff --git a/lisp/progmodes/cc-vars.el b/lisp/progmodes/cc-vars.el index 7596dc60b5f..425dddf16a0 100644 --- a/lisp/progmodes/cc-vars.el +++ b/lisp/progmodes/cc-vars.el @@ -315,6 +315,7 @@ e.g. `c-special-indent-hook'." :type 'boolean :group 'c) (make-variable-buffer-local 'c-syntactic-indentation) +(put 'c-syntactic-indentation 'safe-local-variable 'booleanp) (defcustom c-syntactic-indentation-in-macros t "*Enable syntactic analysis inside macros. @@ -333,6 +334,7 @@ countered easily by surrounding the statements by a block \(or even better with the \"do { ... } while \(0)\" trick)." :type 'boolean :group 'c) +(put 'c-syntactic-indentation-in-macros 'safe-local-variable 'booleanp) (defcustom-c-stylevar c-comment-only-line-offset 0 "*Extra offset for line which contains only the start of a comment. diff --git a/lisp/progmodes/sh-script.el b/lisp/progmodes/sh-script.el index d81281dc4f2..4fe9926af8d 100644 --- a/lisp/progmodes/sh-script.el +++ b/lisp/progmodes/sh-script.el @@ -1205,6 +1205,7 @@ Can be set to a number, or to nil which means leave it as is." This value is used for the `+' and `-' symbols in an indentation variable." :type 'integer :group 'sh-indentation) +(put 'sh-basic-offset 'safe-local-variable 'integerp) (defcustom sh-indent-comment nil "*How a comment line is to be indented. From ef6d86b5eb64fc519d0271bdfe2ba244d219fe83 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sat, 19 Jan 2008 18:46:48 +0000 Subject: [PATCH 213/439] *** empty log message *** --- etc/NEWS | 3 +++ 1 file changed, 3 insertions(+) diff --git a/etc/NEWS b/etc/NEWS index 42e51b1fbc3..87822ef0d85 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -280,6 +280,9 @@ considered for update. ** eldoc highlights the function argument under point with the face `eldoc-highlight-function-argument'. +** hide-ifdef-mode permits to shadow ifdef-blocks instead of hiding them. +See option `hide-ifdef-shadow' and function `hide-ifdef-toggle-shadowing'. + +++ ** defcustom accepts new keyword arguments, `:safe' and `:risky', which set a variable's `safe-local-variable' and `risky-local-variable' property. From 569382c2b4e38392a41052a6ecbc97b92760bf4b Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sat, 19 Jan 2008 18:53:05 +0000 Subject: [PATCH 214/439] (Buffer Modification): Fix typo. --- lispref/ChangeLog | 6 +++++- lispref/buffers.texi | 4 ++-- 2 files changed, 7 insertions(+), 3 deletions(-) diff --git a/lispref/ChangeLog b/lispref/ChangeLog index 0d42aac5c85..7febc50fdef 100644 --- a/lispref/ChangeLog +++ b/lispref/ChangeLog @@ -1,3 +1,7 @@ +2008-01-19 Martin Rudalics + + * buffers.texi (Buffer Modification): Fix typo. + 2008-01-04 Richard Stallman * display.texi (Faces): Don't talk about internal face vector as arg @@ -38,7 +42,7 @@ 2007-11-24 Richard Stallman - * display.texi (Refresh Screen, Forcing Redisplay): + * display.texi (Refresh Screen, Forcing Redisplay): Clarify the text and move items around. 2007-11-15 Martin Rudalics diff --git a/lispref/buffers.texi b/lispref/buffers.texi index d2bbc9bb4d9..658da3a1df2 100644 --- a/lispref/buffers.texi +++ b/lispref/buffers.texi @@ -584,7 +584,7 @@ The counter can wrap around occasionally. This function returns @var{buffer}'s character-change modification-count. Changes to text properties leave this counter unchanged; however, each time text is inserted or removed from the buffer, the counter is reset -to the value that would be returned @code{buffer-modified-tick}. +to the value that would be returned by @code{buffer-modified-tick}. By comparing the values returned by two @code{buffer-chars-modified-tick} calls, you can tell whether a character change occurred in that buffer in between the calls. If @var{buffer} is @code{nil} (or omitted), the @@ -783,7 +783,7 @@ are selected for display in a window (@pxref{Displaying Buffers}), and to the end when they are buried (see @code{bury-buffer}, below). There are no functions available to the Lisp programmer which directly manipulate the buffer list. - + In addition to the fundamental Emacs buffer list, each frame has its own version of the buffer list, in which the buffers that have been selected in that frame come first, starting with the buffers most From c884b4d795f85c56aede59eb8b4cf7e17003d5e9 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sat, 19 Jan 2008 20:13:59 +0000 Subject: [PATCH 215/439] Add a "Simple Tasks" TODO category. --- etc/TODO | 14 ++++++++++++++ 1 file changed, 14 insertions(+) diff --git a/etc/TODO b/etc/TODO index dfc5637e625..355a65fbde0 100644 --- a/etc/TODO +++ b/etc/TODO @@ -12,6 +12,20 @@ it best. Since Emacs is an FSF-copyrighted package, please be prepared to sign legal papers to transfer the copyright on your work to the FSF. +* Simple tasks. These don't require much emacs knowledge, they are +suitable for anyone from beginners to experts. + +** Major modes should have a menu entry. Examples of modes that do +not have one at the moment and probably should: text-mode, +change-log-mode, conf-*-mode. + +** Change the text for the mode-line tooltips to not use things like C-x 0. +In general make sure that tooltips have obvious meanings. Check if +all items on the mode-line have a suitable tooltip. + +** Check what minor modes don't use define-minor-mode and convert them +to use it. + * Small but important fixes needed in existing features: ** Make "emacs --daemon" start emacs without showing any frame. From f2357ea13b8a734d22daea14cabe8e8e2fa5713e Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sun, 20 Jan 2008 03:56:50 +0000 Subject: [PATCH 216/439] Martin Svenson (tiny change) (python-imports): Default to "None". --- lisp/progmodes/python.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index bef282f5e98..3a393a7a4eb 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -1889,7 +1889,8 @@ Uses `python-beginning-of-block', `python-end-of-block'." ;;;; Completion. -(defvar python-imports nil +;; http://lists.gnu.org/archive/html/bug-gnu-emacs/2008-01/msg00076.html +(defvar python-imports "None" "String of top-level import statements updated by `python-find-imports'.") (make-variable-buffer-local 'python-imports) From 9ce3eb9a3f063114a137e6c25328d0d100760fcb Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sun, 20 Jan 2008 03:57:19 +0000 Subject: [PATCH 217/439] Martin Svenson (tiny change) (python-imports): Default to "None". --- lisp/ChangeLog | 4 ++++ lisp/progmodes/python.el | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8f7c6e73504..20aadb3c658 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-20 Martin Svenson (tiny change) + + * progmodes/python.el (python-imports): Default to "None". + 2008-01-19 Dan Nicolaescu * progmodes/sh-script.el (sh-basic-offset): diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index 18494681a9d..c82a55ace8e 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -1866,7 +1866,8 @@ Uses `python-beginning-of-block', `python-end-of-block'." ;;;; Completion. -(defvar python-imports nil +;; http://lists.gnu.org/archive/html/bug-gnu-emacs/2008-01/msg00076.html +(defvar python-imports "None" "String of top-level import statements updated by `python-find-imports'.") (make-variable-buffer-local 'python-imports) From 6c64cd0434447a1b5caa1755abc7a35ab5966b41 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sun, 20 Jan 2008 04:01:05 +0000 Subject: [PATCH 218/439] Quote all calls to "auxiliary skeleton"s to prevent infloops. --- lisp/ChangeLog | 5 +++++ lisp/progmodes/python.el | 10 +++++----- 2 files changed, 10 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 20aadb3c658..ac7bef8b4c9 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-20 Glenn Morris + + * progmodes/python.el: Quote all calls to "auxiliary skeleton"s to + prevent infloops. + 2008-01-20 Martin Svenson (tiny change) * progmodes/python.el (python-imports): Default to "None". diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index c82a55ace8e..ae863df3b5d 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -2052,7 +2052,7 @@ The default contents correspond to the elements of `python-skeletons'.") < ; Avoid wrong indentation after block opening. "elif " str ":" \n > _ \n nil) - (python-else) | ^) + '(python-else) | ^) (define-skeleton python-else "Auxiliary skeleton." @@ -2066,24 +2066,24 @@ The default contents correspond to the elements of `python-skeletons'.") "Condition: " "while " str ":" \n > _ \n - (python-else) | ^) + '(python-else) | ^) (def-python-skeleton for "Target, %s: " "for " str " in " (skeleton-read "Expression, %s: ") ":" \n > _ \n - (python-else) | ^) + '(python-else) | ^) (def-python-skeleton try/except nil "try:" \n > _ \n ("Exception, %s: " - < "except " str (python-target) ":" \n + < "except " str '(python-target) ":" \n > _ \n nil) < "except:" \n > _ \n - (python-else) | ^) + '(python-else) | ^) (define-skeleton python-target "Auxiliary skeleton." From f2c6de6aed9864b659d9abb60b109bd21d65474f Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sun, 20 Jan 2008 04:02:15 +0000 Subject: [PATCH 219/439] Quote all calls to "auxiliary skeleton"s to prevent infloops. --- lisp/ChangeLog | 9 +++++++++ lisp/progmodes/python.el | 10 +++++----- 2 files changed, 14 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 30ab6bda2a8..e24f1039787 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,12 @@ +2008-01-20 Glenn Morris + + * progmodes/python.el: Quote all calls to "auxiliary skeleton"s to + prevent infloops. + +2008-01-20 Martin Svenson (tiny change) + + * progmodes/python.el (python-imports): Default to "None". + 2008-01-19 Tom Tromey * vc-svn.el (vc-svn-after-dir-status): New function. diff --git a/lisp/progmodes/python.el b/lisp/progmodes/python.el index 3a393a7a4eb..39fe096309d 100644 --- a/lisp/progmodes/python.el +++ b/lisp/progmodes/python.el @@ -2077,7 +2077,7 @@ The default contents correspond to the elements of `python-skeletons'." < ; Avoid wrong indentation after block opening. "elif " str ":" \n > _ \n nil) - (python-else) | ^) + '(python-else) | ^) (define-skeleton python-else "Auxiliary skeleton." @@ -2091,24 +2091,24 @@ The default contents correspond to the elements of `python-skeletons'." "Condition: " "while " str ":" \n > _ \n - (python-else) | ^) + '(python-else) | ^) (def-python-skeleton for "Target, %s: " "for " str " in " (skeleton-read "Expression, %s: ") ":" \n > _ \n - (python-else) | ^) + '(python-else) | ^) (def-python-skeleton try/except nil "try:" \n > _ \n ("Exception, %s: " - < "except " str (python-target) ":" \n + < "except " str '(python-target) ":" \n > _ \n nil) < "except:" \n > _ \n - (python-else) | ^) + '(python-else) | ^) (define-skeleton python-target "Auxiliary skeleton." From 0b6799c345f8b7ffd5295fce000c615928ab7cde Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Sun, 20 Jan 2008 05:17:57 +0000 Subject: [PATCH 220/439] Merge from gnus--devo--0 Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1001 --- doc/misc/ChangeLog | 8 ++ doc/misc/gnus-news.texi | 13 +++ etc/GNUS-NEWS | 15 ++- lisp/ChangeLog | 56 +++++++--- lisp/gnus/ChangeLog | 71 ++++++++---- lisp/gnus/gnus-art.el | 69 +++++++----- lisp/gnus/gnus-registry.el | 219 +++++++++++++++++++++++-------------- lisp/gnus/gnus-sum.el | 4 +- lisp/net/imap.el | 20 +++- 9 files changed, 328 insertions(+), 147 deletions(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index 0c425b04c09..a69f32a976e 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,11 @@ +2008-01-18 Katsumi Yamaoka + + * gnus-news.texi: Mention gnus-article-describe-bindings. + +2008-01-18 Katsumi Yamaoka + + * gnus-news.texi: Mention gnus-article-wide-reply-with-original. + 2008-01-18 Carsten Dominik * org.texi (Property inheritance): New section. diff --git a/doc/misc/gnus-news.texi b/doc/misc/gnus-news.texi index e9549779232..8fcab4fc717 100644 --- a/doc/misc/gnus-news.texi +++ b/doc/misc/gnus-news.texi @@ -140,6 +140,19 @@ inline @acronym{PGP} signed messages. @xref{Flowed text, ,Flowed text, emacs-mime, The Emacs MIME Manual}. (New in Gnus 5.10.7) @c This entry is also present in the node "Oort Gnus". +@item Now the new command @kbd{S W} +(@code{gnus-article-wide-reply-with-original}) for a wide reply in the +article buffer yanks a text that is in the active region, if it is set, +as well as the @kbd{R} (@code{gnus-article-reply-with-original}) command. +Note that the @kbd{R} command in the article buffer no longer accepts a +prefix argument, which was used to make it do a wide reply. +@xref{Article Keymap}. + +@item The new command @kbd{C-h b} +(@code{gnus-article-describe-bindings}) used in the article buffer now +shows not only the article commands but also the real summary commands +that are accessible from the article buffer. + @end itemize @item Changes in Message mode diff --git a/etc/GNUS-NEWS b/etc/GNUS-NEWS index ee36984393d..5e41dd0bc4f 100644 --- a/etc/GNUS-NEWS +++ b/etc/GNUS-NEWS @@ -58,7 +58,7 @@ Articles::. ** International host names (IDNA) can now be decoded inside article bodies using `W i' (`gnus-summary-idna-message'). This requires that GNU Libidn -() has been installed. +(`http://www.gnu.org/software/libidn/') has been installed. ** The non-ASCII group names handling has been much improved. The back ends that fully support non-ASCII group names are now `nntp', `nnml', @@ -106,13 +106,24 @@ From Newsgroups::. ** You can replace MIME parts with external bodies. See `gnus-mime-replace-part' and `gnus-article-replace-part'. *Note MIME -Commands::, *Note Using MIME::. +Commands::, *note Using MIME::. ** The option `mm-fill-flowed' can be used to disable treatment of format=flowed messages. Also, flowed text is disabled when sending inline PGP signed messages. *Note Flowed text: (emacs-mime)Flowed text. (New in Gnus 5.10.7) +** Now the new command `S W' (`gnus-article-wide-reply-with-original') for +a wide reply in the article buffer yanks a text that is in the active +region, if it is set, as well as the `R' +(`gnus-article-reply-with-original') command. Note that the `R' command +in the article buffer no longer accepts a prefix argument, which was +used to make it do a wide reply. *Note Article Keymap::. + +** The new command `C-h b' (`gnus-article-describe-bindings') used in the +article buffer now shows not only the article commands but also the real +summary commands that are accessible from the article buffer. + * Changes in Message mode diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e24f1039787..9d845f233e3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,14 @@ +2008-01-19 Reiner Steib + + * net/imap.el (imap-ping-server): New variable. + (imap-opened): On add extra ping if imap-ping-server is non-nil. + (imap-ping-server): Minor doc string fixes. + +2008-01-19 Knut Anders Hatlen (tiny change) + + * net/imap.el (imap-ping-server): New function. + (imap-opened): Call imap-ping-server. + 2008-01-20 Glenn Morris * progmodes/python.el: Quote all calls to "auxiliary skeleton"s to @@ -108,9 +119,11 @@ (org-flag-drawer): Use the original value of `outline-regexp'. (org-remember-handler): Add invisible-ok flag to call to `org-end-of-subtree'. - (org-agenda-highlight-todo): Respect `org-agenda-todo-keyword-format'. + (org-agenda-highlight-todo): Respect + `org-agenda-todo-keyword-format'. (org-agenda-todo-keyword-format): New option. - (org-infile-export-plist): No restriction while searching for options. + (org-infile-export-plist): No restriction while searching for + options. (org-remember-handler): Remove comments at the end of the buffer. (org-remember-use-refile-when-interactive): New option. (org-table-sort-lines): Make sure sorting works on link @@ -121,7 +134,8 @@ `full-file-path'. (org-get-refile-targets): Respect new values for `org-refile-use-outline-path'. - (org-agenda-get-restriction-and-command): DEL goes back to initial list. + (org-agenda-get-restriction-and-command): DEL goes back to initial + list. (org-export-as-xoxo): Restore point when done. (org-open-file): Allow multiple %s in command. (org-clock-in-switch-to-state): New option. @@ -129,7 +143,8 @@ (org-last-remember-storage-locations): New variable. (org-get-refile-targets): Interpret the new maxlevel setting. (org-refile-targets): New option `:maxlevel'. - (org-copy-subtree): Include empty lines before but not after subtree. + (org-copy-subtree): Include empty lines before but not after + subtree. (org-back-over-empty-lines, org-skip-whitespace): New functions. (org-move-item-down, org-move-item-up): Include empty lines before but not after item. @@ -142,7 +157,8 @@ (org-imenu-markers): New variable. (org-imenu-new-marker, org-imenu-get-tree) (org-speedbar-set-agenda-restriction): New functions. - (org-agenda-set-restriction-lock, org-agenda-remove-restriction-lock) + (org-agenda-set-restriction-lock) + (org-agenda-remove-restriction-lock) (org-agenda-maybe-redo): New functions. (org-agenda-restriction-lock): New face. (org-agenda-restriction-lock-overlay) @@ -164,8 +180,8 @@ (org-link-escape-chars): Use characters instead of strings. (org-link-escape-chars-browser, org-link-escape) (org-link-unescape): Use characters instead of strings. - (org-export-html-convert-sub-super, org-html-do-expand): - Check for protected text. + (org-export-html-convert-sub-super, org-html-do-expand): Check for + protected text. (org-emphasis-alist): Additional `verbatim' flag. (org-set-emph-re): Handle the verbatim flag and compute `org-verbatim-re'. @@ -174,13 +190,15 @@ (org-hide-emphasis-markers): New option. (org-additional-option-like-keywords): Add new keywords. (org-get-entry): Rename from `org-get-cleaned-entry'. - (org-icalendar-cleanup-string): New function for quoting icalendar text. + (org-icalendar-cleanup-string): New function for quoting icalendar + text. (org-agenda-skip-scheduled-if-done): New option. - (org-agenda-get-scheduled, org-agenda-get-blocks): - Use `org-agenda-skip-scheduled-if-done'. + (org-agenda-get-scheduled, org-agenda-get-blocks): Use + `org-agenda-skip-scheduled-if-done'. (org-prepare-agenda-buffers): Allow buffers as arguments. (org-entry-properties): Add CATEGORY as a special property. - (org-use-property-inheritance): Allow a list of properties as a value. + (org-use-property-inheritance): Allow a list of properties as a + value. (org-eval-in-calendar): No longer update the prompt. (org-read-date-popup-calendar): Rename from `org-popup-calendar-for-date-prompt'. @@ -191,8 +209,8 @@ not yet defined. (org-remember-insinuate): New function. (org-read-date-prefer-future): New option. - (org-read-date): Respect the setting of `org-read-date-prefer-future'. - Use `org-read-date-analyze'. + (org-read-date): Respect the setting of + `org-read-date-prefer-future'. Use `org-read-date-analyze'. (org-set-font-lock-defaults): Use `org-archive-tag' instead of a hardcoded string. (org-remember-apply-template): Use `remember-finalize' instead of @@ -1482,6 +1500,12 @@ * newcomment.el (comment-region-default): Don't triple the comment starter if the first region line isn't indented enough. +2007-12-21 Teodor Zlatanov + + * net/imap.el (imap-authenticate): Use current-buffer instead of + buffer, for the cases where imap-authenticate is called with a nil + buffer parameter. + 2007-12-21 Martin Rudalics * autoinsert.el (auto-insert-alist): Remove nonsensical precision @@ -2172,6 +2196,12 @@ * textmodes/reftex-toc.el (reftex-make-separate-toc-frame): Try x-focus-frame before focus-frame. Only try focus-frame on XEmacs. +2007-12-03 Nathan J. Williams (tiny change) + + * net/imap.el (imap-mailbox-status-asynch): Upcase STATUS items. + (imap-parse-status): Upcase status-att for servers that sends them + lower-case (e.g., MS Exchange 2007). + 2007-12-03 Karl Fogel * saveplace.el (save-place-quiet): Remove, reverting 2007-12-02T19:54:46Z!kfogel@red-bean.com. diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index e3d4fcb0abc..569789888dd 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog @@ -1,3 +1,54 @@ +2008-01-18 Katsumi Yamaoka + + * gnus-art.el (gnus-article-describe-bindings): Make it possible to use + xrefs, i.e. [back] and [forward] buttons, in *Help* buffer. + +2008-01-18 Teodor Zlatanov + + * gnus-registry.el (gnus-registry-trim): Use append, not concat. + +2008-01-17 Katsumi Yamaoka + + * gnus-art.el (gnus-article-read-summary-keys): Work for some `A' + prefix keys. + (gnus-article-read-summary-send-keys): Use gnus-character-to-event. + (gnus-article-describe-bindings): Simplify; move XEmacs stuff to + gnus-xmas.el. + +2008-01-16 Teodor Zlatanov + + * gnus-registry.el (gnus-registry-marks, gnus-registry-default-mark): + Add new variables for article mark management. + (gnus-registry-extra-entries-precious, gnus-registry-trim): Define a + list of extra data entries which, when present, will indicate that the + article ID should not be trimmed from the registry. + (gnus-registry-mark-article, gnus-registry-article-marks): Remove these + functions. + (gnus-registry-read-mark): New function to read a mark name from the + user. + (gnus-registry-set-article-mark, gnus-registry-remove-article-mark) + (gnus-registry-set-article-mark-internal): New functions to add and + remove marks. + (gnus-registry-get-article-marks): New function to show the marks for + an article, or retrieve them for further use. + +2008-01-16 Katsumi Yamaoka + + * gnus-art.el (gnus-article-describe-bindings): Show all `S' prefix + keys when no argument is given. + +2008-01-12 Reiner Steib + + * gnus-sum.el (gnus-article-sort-by-random) + (gnus-thread-sort-by-random): Fix doc strings. Reported by + jidanni@jidanni.org. + +2008-01-11 Katsumi Yamaoka + + * gnus-art.el (gnus-article-describe-bindings): New function. + (gnus-article-read-summary-keys): Use it. + (gnus-article-mode-map): Bind `C-h b' to it. + 2008-01-10 Katsumi Yamaoka * gnus-art.el (gnus-article-read-summary-keys): Work for `C-h' on @@ -5,8 +56,6 @@ (gnus-article-describe-key, gnus-article-describe-key-briefly): Protect against non-character events. - * lpath.el: Fbind map-keymap for Emacs 21. - 2008-01-09 Reiner Steib * gnus-group.el (gnus-group-read-ephemeral-gmane-group-url): New @@ -31,9 +80,6 @@ (gnus-article-reply-with-original): Ignore prefix argument. (gnus-article-wide-reply-with-original): New function. - * lpath.el: Fbind character-to-event and set-keymap-default-binding for - Emacs 21. - 2008-01-08 Katsumi Yamaoka * gnus-bookmark.el (gnus-bookmark-mouse-available-p): Don't test for @@ -55,12 +101,6 @@ * mml-sec.el, sieve-manage.el, smime.el: Simplify loading of password-cache or password. Suggested by Glenn Morris . -2007-12-21 Teodor Zlatanov - - * imap.el (imap-authenticate): Use current-buffer instead of buffer, - for the cases where imap-authenticate is called with a nil buffer - parameter. - 2007-12-19 Katsumi Yamaoka * gnus-art.el (gnus-article-browse-html-parts): Work for two or more @@ -364,12 +404,6 @@ * message.el (message-ignored-supersedes-headers): Add "X-ID". -2007-12-03 Nathan J. Williams (tiny change) - - * imap.el (imap-mailbox-status-asynch): Upcase STATUS items. - (imap-parse-status): Upcase status-att for servers that sends them - lower-case (e.g., MS Exchange 2007). - 2007-12-03 Lars Magne Ingebrigtsen * gnus-sum.el (gnus-uu-extract-map): Add a command for the yenc @@ -837,9 +871,6 @@ * webmail.el (webmail-debug): Replace mapcar called for effect with dolist. - * gnus-xmas.el (gnus-group-add-icon): Replace mapcar called for effect - with mapc. - 2007-10-24 Katsumi Yamaoka * gnus-agent.el (gnus-agent-read-agentview, gnus-agent-save-alist) diff --git a/lisp/gnus/gnus-art.el b/lisp/gnus/gnus-art.el index f34f8f7376a..6e41f413609 100644 --- a/lisp/gnus/gnus-art.el +++ b/lisp/gnus/gnus-art.el @@ -4215,6 +4215,7 @@ If variable `gnus-use-long-file-name' is non-nil, it is "F" gnus-article-followup-with-original "\C-hk" gnus-article-describe-key "\C-hc" gnus-article-describe-key-briefly + "\C-hb" gnus-article-describe-bindings "\C-d" gnus-article-read-summary-keys "\M-*" gnus-article-read-summary-keys @@ -6241,9 +6242,10 @@ not have a face in `gnus-article-boring-faces'." "Zc" "ZC" "ZE" "ZQ" "ZZ" "Zn" "ZR" "ZG" "ZN" "ZP" "=" "^" "\M-^" "|")) (nosave-but-article - '("A\r")) + '("A " "A<" "A>" "AM" "AP" "AR" "AT" "A\C-?" "A\M-\r" "A\r" "Ab" "Ae" + "An" "Ap" [?A (meta return)] [?A delete])) (nosave-in-article - '("\C-d")) + '("AS" "\C-d")) (up-to-top '("n" "Gn" "p" "Gp")) keys new-sum-point) @@ -6260,27 +6262,7 @@ not have a face in `gnus-article-boring-faces'." (cond ((eq (aref keys (1- (length keys))) ?\C-h) - (if (featurep 'xemacs) - (let ((keymap (with-current-buffer gnus-article-current-summary - (copy-keymap (current-local-map))))) - (map-keymap - (lambda (key def) - (define-key keymap (vector ?S key) def)) - gnus-article-send-map) - (with-temp-buffer - (setq major-mode 'gnus-article-mode) - (use-local-map keymap) - (describe-bindings (substring keys 0 -1)))) - (let ((keymap (make-sparse-keymap)) - (map (copy-keymap gnus-article-send-map))) - (define-key keymap "S" map) - (define-key map [t] nil) - (set-keymap-parent keymap - (with-current-buffer gnus-article-current-summary - (current-local-map))) - (with-temp-buffer - (use-local-map keymap) - (describe-bindings (substring keys 0 -1)))))) + (gnus-article-describe-bindings (substring keys 0 -1))) ((or (member keys nosaves) (member keys nosave-but-article) (member keys nosave-in-article)) @@ -6368,9 +6350,7 @@ not have a face in `gnus-article-boring-faces'." (defun gnus-article-read-summary-send-keys () (interactive) - (let ((unread-command-events (list (if (featurep 'xemacs) - (character-to-event ?S) - ?S)))) + (let ((unread-command-events (list (gnus-character-to-event ?S)))) (gnus-article-read-summary-keys))) (defun gnus-article-describe-key (key) @@ -6418,6 +6398,43 @@ KEY is a string or a vector." (describe-key-briefly (read-key-sequence nil t) insert))) (describe-key-briefly key insert))) +;;`gnus-agent-mode' in gnus-agent.el will define it. +(defvar gnus-agent-summary-mode) + +(defun gnus-article-describe-bindings (&optional prefix) + "Show a list of all defined keys, and their definitions. +The optional argument PREFIX, if non-nil, should be a key sequence; +then we display only bindings that start with that prefix." + (interactive) + (gnus-article-check-buffer) + (let ((keymap (copy-keymap gnus-article-mode-map)) + (map (copy-keymap gnus-article-send-map)) + (sumkeys (where-is-internal 'gnus-article-read-summary-keys)) + agent) + (define-key keymap "S" map) + (define-key map [t] nil) + (with-current-buffer gnus-article-current-summary + (set-keymap-parent map (key-binding "S")) + (let (def gnus-pick-mode) + (dolist (key sumkeys) + (when (setq def (key-binding key)) + (define-key keymap key def)))) + (when (boundp 'gnus-agent-summary-mode) + (setq agent gnus-agent-summary-mode))) + (with-temp-buffer + (use-local-map keymap) + (set (make-local-variable 'gnus-agent-summary-mode) agent) + (describe-bindings prefix)) + (let ((item `((lambda (prefix) + (save-excursion + (set-buffer ,(current-buffer)) + (gnus-article-describe-bindings prefix))) + ,prefix))) + (with-current-buffer (if (fboundp 'help-buffer) + (let (help-xref-following) (help-buffer)) + "*Help*") ;; Emacs 21 + (setq help-xref-stack-item item))))) + (defun gnus-article-reply-with-original (&optional wide) "Start composing a reply mail to the current message. The text in the region will be yanked. If the region isn't active, diff --git a/lisp/gnus/gnus-registry.el b/lisp/gnus/gnus-registry.el index b879c90e91f..4c2e77e4d46 100644 --- a/lisp/gnus/gnus-registry.el +++ b/lisp/gnus/gnus-registry.el @@ -78,6 +78,17 @@ :test 'equal) "*The article registry by Message ID.") +(defcustom gnus-registry-marks + '(Important Work Personal To-Do Later) + "List of marks that `gnus-registry-mark-article' will offer for completion." + :group 'gnus-registry + :type '(repeat symbol)) + +(defcustom gnus-registry-default-mark 'To-Do + "The default mark." + :group 'gnus-registry + :type 'symbol) + (defcustom gnus-registry-unfollowed-groups '("delayed$" "drafts$" "queue$" "INBOX$") "List of groups that gnus-registry-split-fancy-with-parent won't return. The group names are matched, they don't have to be fully @@ -129,6 +140,16 @@ way." :group 'gnus-registry :type 'boolean) +(defcustom gnus-registry-extra-entries-precious '(marks) + "What extra entries are precious, meaning they won't get trimmed. +When you save the Gnus registry, it's trimmed to be no longer +than `gnus-registry-max-entries' (which is nil by default, so no +trimming happens). Any entries with extra data in this list (by +default, marks are included, so articles with marks are +considered precious) will not be trimmed." + :group 'gnus-registry + :type '(repeat symbol)) + (defcustom gnus-registry-cache-file (nnheader-concat (or gnus-dribble-directory gnus-home-directory "~/") @@ -313,30 +334,50 @@ way." (defun gnus-registry-trim (alist) "Trim alist to size, using gnus-registry-max-entries. -Also, drop all gnus-registry-ignored-groups matches." - (if (null gnus-registry-max-entries) +Also, drop all gnus-registry-ignored-groups matches. +Any entries with extra data (marks, currently) are left alone." + (if (null gnus-registry-max-entries) alist ; just return the alist ;; else, when given max-entries, trim the alist (let* ((timehash (make-hash-table - :size 4096 + :size 20000 + :test 'equal)) + (precious (make-hash-table + :size 20000 :test 'equal)) (trim-length (- (length alist) gnus-registry-max-entries)) - (trim-length (if (natnump trim-length) trim-length 0))) + (trim-length (if (natnump trim-length) trim-length 0)) + precious-list junk-list) (maphash (lambda (key value) - (puthash key (gnus-registry-fetch-extra key 'mtime) timehash)) + (let ((extra (gnus-registry-fetch-extra key))) + (dolist (item gnus-registry-extra-entries-precious) + (dolist (e extra) + (when (equal (nth 0 e) item) + (puthash key t precious) + (return)))) + (puthash key (gnus-registry-fetch-extra key 'mtime) timehash))) gnus-registry-hashtb) - - ;; we use the return value of this setq, which is the trimmed alist - (setq alist - (nthcdr - trim-length - (sort alist - (lambda (a b) - (time-less-p - (or (cdr (gethash (car a) timehash)) '(0 0 0)) - (or (cdr (gethash (car b) timehash)) '(0 0 0)))))))))) + (dolist (item alist) + (let ((key (nth 0 item))) + (if (gethash key precious) + (push item precious-list) + (push item junk-list)))) + + (sort + junk-list + (lambda (a b) + (let ((t1 (or (cdr (gethash (car a) timehash)) + '(0 0 0))) + (t2 (or (cdr (gethash (car b) timehash)) + '(0 0 0)))) + (time-less-p t1 t2)))) + + ;; we use the return value of this setq, which is the trimmed alist + (setq alist (append precious-list + (nthcdr trim-length junk-list)))))) + (defun gnus-registry-action (action data-header from &optional to method) (let* ((id (mail-header-id data-header)) (subject (gnus-string-remove-all-properties @@ -577,6 +618,7 @@ See the Info node `(gnus)Fancy Mail Splitting' for more details." (assoc article (gnus-data-list nil))))) nil)) +;;; this should be redone with catch/throw (defun gnus-registry-grep-in-list (word list) (when word (memq nil @@ -586,80 +628,91 @@ See the Info node `(gnus)Fancy Mail Splitting' for more details." (string-match word x)) list))))) -(defun gnus-registry-mark-article (article &optional mark remove) - "Mark ARTICLE with MARK in the Gnus registry or remove MARK. -MARK can be any symbol. If ARTICLE is nil, then the -`gnus-current-article' will be marked. If MARK is nil, -`gnus-registry-flag-default' will be used." - (interactive "nArticle number: ") - (let ((article (or article gnus-current-article)) - (mark (or mark 'gnus-registry-flag-default)) - article-id) - (unless article - (error "No article on current line")) - (setq article-id - (gnus-registry-fetch-message-id-fast gnus-current-article)) - (unless article-id - (error "No article ID could be retrieved")) - (let* ( - ;; all the marks for this article - (marks (gnus-registry-fetch-extra-flags article-id)) - ;; the marks without the mark of interest - (cleaned-marks (delq mark marks)) - ;; the new marks we want to use - (new-marks (if remove - cleaned-marks - (cons mark cleaned-marks)))) - (apply 'gnus-registry-store-extra-flags ; set the extra flags - article-id ; for the message ID - new-marks) - (gnus-registry-fetch-extra-flags article-id)))) -(defun gnus-registry-article-marks (article) - "Get the Gnus registry marks for ARTICLE. -If ARTICLE is nil, then the `gnus-current-article' will be -used." - (interactive "nArticle number: ") - (let ((article (or article gnus-current-article)) - article-id) - (unless article - (error "No article on current line")) - (setq article-id - (gnus-registry-fetch-message-id-fast gnus-current-article)) - (unless article-id - (error "No article ID could be retrieved")) - (gnus-message 1 - "Message ID %s, Registry flags: %s" - article-id - (concat (gnus-registry-fetch-extra-flags article-id))))) - +(defun gnus-registry-read-mark () + "Read a mark name from the user with completion." + (let ((mark (gnus-completing-read-with-default + (symbol-name gnus-registry-default-mark) + "Label" + (mapcar (lambda (x) ; completion list + (cons (symbol-name x) x)) + gnus-registry-marks)))) + (when (stringp mark) + (intern mark)))) -;;; if this extends to more than 'flags, it should be improved to be more generic. -(defun gnus-registry-fetch-extra-flags (id) - "Get the flags of a message, based on the message ID. -Returns a list of symbol flags or nil." - (car-safe (cdr (gnus-registry-fetch-extra id 'flags)))) +(defun gnus-registry-set-article-mark (&rest articles) + "Apply a mark to process-marked ARTICLES." + (interactive (gnus-summary-work-articles current-prefix-arg)) + (gnus-registry-set-article-mark-internal (gnus-registry-read-mark) articles nil t)) -(defun gnus-registry-has-extra-flag (id flag) - "Checks if a message has `flag', based on the message ID." - (memq flag (gnus-registry-fetch-extra-flags id))) +(defun gnus-registry-remove-article-mark (&rest articles) + "Remove a mark from process-marked ARTICLES." + (interactive (gnus-summary-work-articles current-prefix-arg)) + (gnus-registry-set-article-mark-internal (gnus-registry-read-mark) articles t t)) -(defun gnus-registry-store-extra-flags (id &rest flag-list) - "Set the flags of a message, based on the message ID. -The `flag-list' can be nil, in which case no flags are left." - (gnus-registry-store-extra-entry id 'flags (list flag-list))) +(defun gnus-registry-set-article-mark-internal (mark articles &optional remove show-message) + "Apply a mark to a list of ARTICLES." + (let ((article-id-list + (mapcar 'gnus-registry-fetch-message-id-fast articles))) + (dolist (id article-id-list) + (let* ( + ;; all the marks for this article without the mark of + ;; interest + (marks + (delq mark (gnus-registry-fetch-extra-marks id))) + ;; the new marks we want to use + (new-marks (if remove + marks + (cons mark marks)))) + (when show-message + (gnus-message 1 "%s mark %s with message ID %s, resulting in %S" + (if remove "Removing" "Adding") + mark id new-marks)) + + (apply 'gnus-registry-store-extra-marks ; set the extra marks + id ; for the message ID + new-marks))))) -(defun gnus-registry-delete-extra-flags (id &rest flag-delete-list) - "Delete the message flags in `flag-delete-list', based on the message ID." - (let ((flags (gnus-registry-fetch-extra-flags id))) - (when flags - (dolist (flag flag-delete-list) - (setq flags (delq flag flags)))) - (gnus-registry-store-extra-flags id (car flags)))) +(defun gnus-registry-get-article-marks (&rest articles) + "Get the Gnus registry marks for ARTICLES and show them if interactive. +Uses process/prefix conventions. For multiple articles, +only the last one's marks are returned." + (interactive (gnus-summary-work-articles 1)) + (let (marks) + (dolist (article articles) + (let ((article-id + (gnus-registry-fetch-message-id-fast article))) + (setq marks (gnus-registry-fetch-extra-marks article-id)))) + (when (interactive-p) + (gnus-message 1 "Marks are %S" marks)) + marks)) -(defun gnus-registry-delete-all-extra-flags (id) - "Delete all the flags for a message ID." - (gnus-registry-store-extra-flags id nil)) +;;; if this extends to more than 'marks, it should be improved to be more generic. +(defun gnus-registry-fetch-extra-marks (id) + "Get the marks of a message, based on the message ID. +Returns a list of symbol marks or nil." + (car-safe (cdr (gnus-registry-fetch-extra id 'marks)))) + +(defun gnus-registry-has-extra-mark (id mark) + "Checks if a message has `mark', based on the message ID `id'." + (memq mark (gnus-registry-fetch-extra-marks id))) + +(defun gnus-registry-store-extra-marks (id &rest mark-list) + "Set the marks of a message, based on the message ID. +The `mark-list' can be nil, in which case no marks are left." + (gnus-registry-store-extra-entry id 'marks (list mark-list))) + +(defun gnus-registry-delete-extra-marks (id &rest mark-delete-list) + "Delete the message marks in `mark-delete-list', based on the message ID." + (let ((marks (gnus-registry-fetch-extra-marks id))) + (when marks + (dolist (mark mark-delete-list) + (setq marks (delq mark marks)))) + (gnus-registry-store-extra-marks id (car marks)))) + +(defun gnus-registry-delete-all-extra-marks (id) + "Delete all the marks for a message ID." + (gnus-registry-store-extra-marks id nil)) (defun gnus-registry-fetch-extra (id &optional entry) "Get the extra data of a message, based on the message ID. diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el index beccca289bc..52eab645d4e 100644 --- a/lisp/gnus/gnus-sum.el +++ b/lisp/gnus/gnus-sum.el @@ -4797,11 +4797,11 @@ using some other form will lead to serious barfage." (gnus-thread-header h1) (gnus-thread-header h2))) (defsubst gnus-article-sort-by-random (h1 h2) - "Sort articles by article number." + "Sort articles randomly." (zerop (random 2))) (defun gnus-thread-sort-by-random (h1 h2) - "Sort threads by root article number." + "Sort threads randomly." (gnus-article-sort-by-random (gnus-thread-header h1) (gnus-thread-header h2))) diff --git a/lisp/net/imap.el b/lisp/net/imap.el index 0ee4de6fee8..27b434541ce 100644 --- a/lisp/net/imap.el +++ b/lisp/net/imap.el @@ -1150,6 +1150,13 @@ necessary. If nil, the buffer name is generated." (when imap-stream buffer)))) +(defcustom imap-ping-server t + "If non-nil, check if IMAP is open. +See the function `imap-ping-server'." + :version "23.0" ;; No Gnus + :group 'imap + :type 'boolean) + (defun imap-opened (&optional buffer) "Return non-nil if connection to imap server in BUFFER is open. If BUFFER is nil then the current buffer is used." @@ -1157,7 +1164,18 @@ If BUFFER is nil then the current buffer is used." (buffer-live-p buffer) (with-current-buffer buffer (and imap-process - (memq (process-status imap-process) '(open run)))))) + (memq (process-status imap-process) '(open run)) + (if imap-ping-server + (imap-ping-server) + t))))) + +(defun imap-ping-server (&optional buffer) + "Ping the IMAP server in BUFFER with a \"NOOP\" command. +Return non-nil if the server responds, and nil if it does not +respond. If BUFFER is nil, the current buffer is used." + (condition-case () + (imap-ok-p (imap-send-command-wait "NOOP" buffer)) + (error nil))) (defun imap-authenticate (&optional user passwd buffer) "Authenticate to server in BUFFER, using current buffer if nil. From f6f461323d9a844722c8f92d6549c797e13e19df Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Sun, 20 Jan 2008 05:20:30 +0000 Subject: [PATCH 221/439] Merge from gnus--rel--5.10 Revision: emacs@sv.gnu.org/emacs--rel--22--patch-193 --- lisp/gnus/ChangeLog | 6 ++++++ lisp/gnus/gnus-sum.el | 4 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 589b95800d3..355fa36e91a 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog @@ -1,3 +1,9 @@ +2008-01-12 Reiner Steib + + * gnus-sum.el (gnus-article-sort-by-random) + (gnus-thread-sort-by-random): Fix doc strings. Reported by + jidanni@jidanni.org. + 2007-12-18 Reiner Steib * gnus-draft.el (gnus-draft-send-message): Mention process/prefix diff --git a/lisp/gnus/gnus-sum.el b/lisp/gnus/gnus-sum.el index b6386e652ea..f5544bb7fd3 100644 --- a/lisp/gnus/gnus-sum.el +++ b/lisp/gnus/gnus-sum.el @@ -4645,11 +4645,11 @@ using some other form will lead to serious barfage." (gnus-thread-header h1) (gnus-thread-header h2))) (defsubst gnus-article-sort-by-random (h1 h2) - "Sort articles by article number." + "Sort articles randomly." (zerop (random 2))) (defun gnus-thread-sort-by-random (h1 h2) - "Sort threads by root article number." + "Sort threads randomly." (gnus-article-sort-by-random (gnus-thread-header h1) (gnus-thread-header h2))) From 8abe0f97764a932f9e15863a93014fefff484ed6 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sun, 20 Jan 2008 10:34:18 +0000 Subject: [PATCH 222/439] (undo_inhibit_record_point): New variable. (syms_of_undo): Initialize it. (record_point): Don't record point when undo_inhibit_record_point is set. --- src/ChangeLog | 7 +++++++ src/undo.c | 18 +++++++++++++++++- 2 files changed, 24 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 0667c484acb..73a1164915e 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,10 @@ +2008-01-20 Martin Rudalics + + * undo.c (undo_inhibit_record_point): New variable. + (syms_of_undo): Initialize it. + (record_point): Don't record point when undo_inhibit_record_point + is set. + 2008-01-19 Stefan Monnier * process.c (list_processes_1): Don't use SCHARS on a nil buffer name. diff --git a/src/undo.c b/src/undo.c index bf528e23935..77590e4ace8 100644 --- a/src/undo.c +++ b/src/undo.c @@ -53,8 +53,12 @@ Lisp_Object Qapply; an undo-boundary. */ Lisp_Object pending_boundary; +/* Nonzero means do not record point in record_point. */ + +int undo_inhibit_record_point; + /* Record point as it was at beginning of this command (if necessary) - And prepare the undo info for recording a change. + and prepare the undo info for recording a change. PT is the position of point that will naturally occur as a result of the undo record that will be added just after this command terminates. */ @@ -64,6 +68,14 @@ record_point (pt) { int at_boundary; + /* Don't record position of pt when undo_inhibit_record_point holds. + Needed to avoid inserting a position record in buffer-undo-list + when last_point_position has not been set up correctly by + command_loop_1, for example, when running a repeat-repeat-char + event. */ + if (undo_inhibit_record_point) + return; + /* Allocate a cons cell to be the undo boundary after this command. */ if (NILP (pending_boundary)) pending_boundary = Fcons (Qnil, Qnil); @@ -719,6 +731,10 @@ If it returns nil, the other forms of truncation are done. Garbage collection is inhibited around the call to this function, so it must make sure not to do a lot of consing. */); Vundo_outer_limit_function = Qnil; + + DEFVAR_BOOL ("undo-inhibit-record-point", &undo_inhibit_record_point, + doc: /* Non-nil means do not record `point' in `buffer-undo-list'. */); + undo_inhibit_record_point = 0; } /* arch-tag: d546ee01-4aed-4ffb-bb8b-eefaae50d38a From 9a407f82620ff5c6e43de9911e95c3266b1d469b Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sun, 20 Jan 2008 10:35:27 +0000 Subject: [PATCH 223/439] (repeat-undo-count): New variable. (repeat): For self-insertions make undo boundary only after 20 repetitions. Inhibit point recording when repeat-repeat-char is non-nil. --- lisp/ChangeLog | 7 +++++++ lisp/repeat.el | 43 ++++++++++++++++++++++++++++++++----------- 2 files changed, 39 insertions(+), 11 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9d845f233e3..800fb5a0571 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2008-01-20 Martin Rudalics + + * repeat.el (repeat-undo-count): New variable. + (repeat): For self-insertions make undo boundary only after 20 + repetitions. Inhibit point recording when repeat-repeat-char is + non-nil. + 2008-01-19 Reiner Steib * net/imap.el (imap-ping-server): New variable. diff --git a/lisp/repeat.el b/lisp/repeat.el index 8e97abf32e9..fdeec47f7c4 100644 --- a/lisp/repeat.el +++ b/lisp/repeat.el @@ -200,6 +200,14 @@ this function is always whether the value of `this-command' would've been (defvar repeat-previous-repeated-command nil "The previous repeated command.") +;; The following variable counts repeated self-insertions. The idea is +;; that repeating a self-insertion command and subsequently undoing it +;; should have almost the same effect as if the characters were inserted +;; manually. The basic difference is that we leave in one undo-boundary +;; between the original insertion and its first repetition. +(defvar repeat-undo-count nil + "Number of self-insertions since last `undo-boundary'.") + ;;;###autoload (defun repeat (repeat-arg) "Repeat most recently executed command. @@ -246,12 +254,6 @@ recently executed command not bound to an input event\"." ;; needs to be saved. (let ((repeat-repeat-char (if (eq repeat-on-final-keystroke t) - ;; The following commented out since it's equivalent to - ;; last-comment-char (martin 2007-08-29). -;;; ;; allow any final input event that was a character -;;; (when (eq last-command-char -;;; last-command-event) -;;; last-command-char) last-command-char ;; allow only specified final keystrokes (car (memq last-command-char @@ -293,11 +295,22 @@ recently executed command not bound to an input event\"." (i 0)) ;; Run pre- and post-command hooks for self-insertion too. (run-hooks 'pre-command-hook) + (cond + ((not repeat-undo-count)) + ((< repeat-undo-count 20) + ;; Don't make an undo-boundary here. + (setq repeat-undo-count (1+ repeat-undo-count))) + (t + ;; Make an undo-boundary after 20 repetitions only. + (undo-boundary) + (setq repeat-undo-count 1))) (while (< i count) (repeat-self-insert insertion) (setq i (1+ i))) (run-hooks 'post-command-hook))) (let ((indirect (indirect-function last-repeatable-command))) + ;; Make each repetition undo separately. + (undo-boundary) (if (or (stringp indirect) (vectorp indirect)) ;; Bind real-last-command so that executing the macro does @@ -314,12 +327,20 @@ recently executed command not bound to an input event\"." ;; (only 32 repetitions are possible given the default value of 200 for ;; max-lisp-eval-depth), but if I now locally disable the repeat char I ;; can iterate indefinitely here around a single level of recursion. - (let (repeat-on-final-keystroke) + (let (repeat-on-final-keystroke + ;; Bind `undo-inhibit-record-point' to t in order to avoid + ;; recording point in `buffer-undo-list' here. We have to + ;; do this since the command loop does not set the last + ;; position of point thus confusing the point recording + ;; mechanism when inserting or deleting text. + (undo-inhibit-record-point t)) (setq real-last-command 'repeat) - (while (eq (read-event) repeat-repeat-char) - ;; Make each repetition undo separately. - (undo-boundary) - (repeat repeat-arg)) + (setq repeat-undo-count 1) + (unwind-protect + (while (eq (read-event) repeat-repeat-char) + (repeat repeat-arg)) + ;; Make sure `repeat-undo-count' is reset. + (setq repeat-undo-count nil)) (setq unread-command-events (list last-input-event)))))) (defun repeat-self-insert (string) From b5e791bdb7a00e8ea9e6854e55fd959237f06100 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 20 Jan 2008 19:56:43 +0000 Subject: [PATCH 224/439] (vc-svn-registered): Make it work for non-existent files. --- lisp/ChangeLog | 5 +++++ lisp/vc-svn.el | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 800fb5a0571..65556e2eb65 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-20 Dan Nicolaescu + + * vc-svn.el (vc-svn-registered): Make it work for non-existent + files. + 2008-01-20 Martin Rudalics * repeat.el (repeat-undo-count): New variable. diff --git a/lisp/vc-svn.el b/lisp/vc-svn.el index b3db2df7f69..368d9f36166 100644 --- a/lisp/vc-svn.el +++ b/lisp/vc-svn.el @@ -132,8 +132,8 @@ If you want to force an empty list of arguments, use t." ;; an `error' by vc-do-command. (error nil)))) (when (eq 0 status) - (not (memq (vc-svn-parse-status file) - '(ignored unregistered)))))))) + (let ((parsed (vc-svn-parse-status file))) + (and parsed (not (memq parsed '(ignored unregistered)))))))))) (defun vc-svn-state (file &optional localp) "SVN-specific version of `vc-state'." From f1e22adaab1610a6b4805ab69aebfb98c29d1916 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 20 Jan 2008 20:01:24 +0000 Subject: [PATCH 225/439] * vc-hg.el (vc-hg-registered): Make it work for non-existent files. --- lisp/ChangeLog | 1 + lisp/vc-hg.el | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 65556e2eb65..5d9d50e7a64 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,6 @@ 2008-01-20 Dan Nicolaescu + * vc-hg.el (vc-hg-registered): * vc-svn.el (vc-svn-registered): Make it work for non-existent files. diff --git a/lisp/vc-hg.el b/lisp/vc-hg.el index c3c3b5577f3..7b7ca3b7f6d 100644 --- a/lisp/vc-hg.el +++ b/lisp/vc-hg.el @@ -149,7 +149,7 @@ (when (vc-hg-root file) ; short cut (let ((state (vc-hg-state file))) ; expensive (vc-file-setprop file 'vc-state state) - (not (memq state '(ignored unregistered)))))) + (and state (not (memq state '(ignored unregistered))))))) (defun vc-hg-state (file) "Hg-specific version of `vc-state'." From d048f3bf74f10a336e5a7bc8fb270415e1816fed Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Sun, 20 Jan 2008 20:23:04 +0000 Subject: [PATCH 226/439] (vc-process-sentinel): Set mode-line-process. (vc-exec-after): Likewise, for the `run' process status. --- lisp/vc.el | 21 ++++++++++++++++----- 1 file changed, 16 insertions(+), 5 deletions(-) diff --git a/lisp/vc.el b/lisp/vc.el index a0f8ce1702c..26cf32999b6 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -959,6 +959,12 @@ BUF defaults to \"*vc*\", can be a string and will be created if necessary." (defun vc-process-sentinel (p s) (let ((previous (process-get p 'vc-previous-sentinel))) + (setq mode-line-process + (let ((status (process-status p))) + ;; Leave mode-line uncluttered, normally. + ;; (Let known any weirdness in-form-ally. ;-) --ttn + (unless (eq 'exit status) + (format " (%s)" status)))) (if previous (funcall previous p s)) (with-current-buffer (process-buffer p) (let (vc-sentinel-movepoint) @@ -999,6 +1005,11 @@ Else, add CODE to the process' sentinel." (eval code)) ;; If a process is running, add CODE to the sentinel ((eq (process-status proc) 'run) + (setq mode-line-process + ;; Deliberate overstatement, but power law respected. + ;; (The message is ephemeral, so we make it loud.) --ttn + (propertize " (incomplete / in progress)" + 'face 'compilation-warning)) (let ((previous (process-sentinel proc))) (unless (eq previous 'vc-process-sentinel) (process-put proc 'vc-previous-sentinel previous)) @@ -2572,7 +2583,7 @@ With prefix arg READ-SWITCHES, specify a value to override (cd dir) (vc-status-mode)) -(defvar vc-status-mode-map +(defvar vc-status-mode-map (let ((map (make-keymap))) (suppress-keymap map) ;; Marking. @@ -2637,8 +2648,8 @@ With prefix arg READ-SWITCHES, specify a value to override ;; be asynchronous. It should compute the results and call the ;; function passed as a an arg to update the vc-status buffer with ;; the results. - (vc-call-backend - backend 'dir-status default-directory + (vc-call-backend + backend 'dir-status default-directory #'vc-update-vc-status-buffer (current-buffer)))) (defun vc-status-next-line (arg) @@ -2731,11 +2742,11 @@ If a prefix argument is given, move by that many lines." (defun vc-status-marked-files () "Return the list of marked files" - (mapcar + (mapcar (lambda (elem) (expand-file-name (vc-status-fileinfo->name elem))) (ewoc-collect - vc-status + vc-status (lambda (crt) (vc-status-fileinfo->marked crt))))) ;;; End experimental code. From 56618a0ac34383631bc6bedd43c2839f573137da Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Sun, 20 Jan 2008 20:23:46 +0000 Subject: [PATCH 227/439] (ibuffer-mode): Fix last change. --- lisp/ChangeLog | 17 +++++++++-------- lisp/ibuffer.el | 3 ++- 2 files changed, 11 insertions(+), 9 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5d9d50e7a64..2842e98eb66 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,8 +1,11 @@ +2008-01-20 Stefan Monnier + + * ibuffer.el (ibuffer-mode): Fix last change. + 2008-01-20 Dan Nicolaescu * vc-hg.el (vc-hg-registered): - * vc-svn.el (vc-svn-registered): Make it work for non-existent - files. + * vc-svn.el (vc-svn-registered): Make it work for non-existent files. 2008-01-20 Martin Rudalics @@ -33,8 +36,8 @@ 2008-01-19 Tom Tromey - * vc-svn.el (vc-svn-after-dir-status): New function. - (vc-svn-dir-status): Run svn asynchronously. + * vc-svn.el (vc-svn-after-dir-status): New function. + (vc-svn-dir-status): Run svn asynchronously. 2008-01-19 Martin Rudalics @@ -42,10 +45,8 @@ (hide-ifdef-shadow): New face. (hide-ifdef-toggle-shadowing): New function to toggle between shadowing and making code invisible. - (hide-ifdef-mode-submap): Add binding for - hide-ifdef-toggle-shadowing. - (hide-ifdef-mode-menu): Add entry for - hide-ifdef-toggle-shadowing. + (hide-ifdef-mode-submap): Add binding for hide-ifdef-toggle-shadowing. + (hide-ifdef-mode-menu): Add entry for hide-ifdef-toggle-shadowing. (hide-ifdef-region-internal): Give new overlay hide-ifdef property. Shadow text when hide-ifdef-shadow is non-nil. (hif-show-ifdef-region): Remove overlays with hide-ifdef diff --git a/lisp/ibuffer.el b/lisp/ibuffer.el index 12363c6f808..9765c307061 100644 --- a/lisp/ibuffer.el +++ b/lisp/ibuffer.el @@ -2517,7 +2517,8 @@ will be inserted before the group at point." (setq mode-name "Ibuffer") ;; Include state info next to the mode name. (set (make-local-variable 'mode-line-process) - '((ibuffer-sorting-mode (:eval (symbol-name ibuffer-sorting-mode)) + '(" by " + (ibuffer-sorting-mode (:eval (symbol-name ibuffer-sorting-mode)) "view time") (ibuffer-sorting-reversep " [rev]") (ibuffer-auto-mode " (Auto)") From d827669cbba06c3998e19358f4d259a21d22a770 Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Sun, 20 Jan 2008 20:24:30 +0000 Subject: [PATCH 228/439] *** empty log message *** --- lisp/ChangeLog | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2842e98eb66..ac453cbc91e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-20 Thien-Thi Nguyen + + * vc.el (vc-process-sentinel): Set mode-line-process. + (vc-exec-after): Likewise, for the `run' process status. + 2008-01-20 Stefan Monnier * ibuffer.el (ibuffer-mode): Fix last change. From 5d7ba920f32752273262e7cdb521ba71aaf3d81e Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Sun, 20 Jan 2008 20:25:46 +0000 Subject: [PATCH 229/439] (ibuffer-mode): Fix last change. --- lisp/ibuffer.el | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/lisp/ibuffer.el b/lisp/ibuffer.el index 9765c307061..dcf840fc584 100644 --- a/lisp/ibuffer.el +++ b/lisp/ibuffer.el @@ -2531,9 +2531,11 @@ will be inserted before the group at point." (setq header-line-format (if ibuffer-use-header-line ;; Display the part that won't be in the mode-line. - (mapcar (lambda (elem) (if (eq (car-safe elem) 'header-line-format) - (nth 2 elem) elem)) - mode-line-process))) + (list* "" mode-name + (mapcar (lambda (elem) + (if (eq (car-safe elem) 'header-line-format) + (nth 2 elem) elem)) + mode-line-process)))) (setq buffer-read-only t) (buffer-disable-undo) From 3c2e52cde9960da063b34e7c7abdd08969623f2f Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Sun, 20 Jan 2008 20:29:47 +0000 Subject: [PATCH 230/439] (vc-process-sentinel): Fix bug introduced in last change: Set mode-line-process with P's buffer made temporarily current. --- lisp/vc.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/vc.el b/lisp/vc.el index 26cf32999b6..497ba1e0df4 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -958,13 +958,14 @@ BUF defaults to \"*vc*\", can be a string and will be created if necessary." (defvar vc-sentinel-movepoint) ;Dynamically scoped. (defun vc-process-sentinel (p s) - (let ((previous (process-get p 'vc-previous-sentinel))) + (with-current-buffer (process-buffer p) (setq mode-line-process (let ((status (process-status p))) ;; Leave mode-line uncluttered, normally. ;; (Let known any weirdness in-form-ally. ;-) --ttn (unless (eq 'exit status) - (format " (%s)" status)))) + (format " (%s)" status))))) + (let ((previous (process-get p 'vc-previous-sentinel))) (if previous (funcall previous p s)) (with-current-buffer (process-buffer p) (let (vc-sentinel-movepoint) From cf32108ec4fa2c2ce99071d97ccdbfe29e6b0921 Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Sun, 20 Jan 2008 23:17:25 +0000 Subject: [PATCH 231/439] (CYGWIN) [USING_SH]: Disable mapping of file permissions to NTFS ACLs. --- nt/ChangeLog | 5 +++++ nt/gmake.defs | 10 ++++++++++ 2 files changed, 15 insertions(+) diff --git a/nt/ChangeLog b/nt/ChangeLog index 033a73b51d0..88c633c8c39 100644 --- a/nt/ChangeLog +++ b/nt/ChangeLog @@ -1,3 +1,8 @@ +2008-01-20 Jason Rumney + + * gmake.defs (CYGWIN) [USING_SH]: Disable mapping of file + permissions to NTFS ACLs. + 2007-10-20 Eli Zaretskii * configure.bat (docflags, doldflags): New variables. diff --git a/nt/gmake.defs b/nt/gmake.defs index e782c203e76..6bc5e247886 100644 --- a/nt/gmake.defs +++ b/nt/gmake.defs @@ -99,6 +99,16 @@ sh_output := $(shell echo foo") ifeq "$(sh_output)" "" NEW_CYGWIN = 1 endif + +# By default, newer versions of Cygwin mess with NTFS ACLs in an +# attempt to emulate traditional posix file permissions. This can +# cause bad effects, such as .exe files that are missing the +# FILE_EXECUTE/FILE_GENERIC_EXECUTE permissions when they are created +# with Cygwin commands that don't expect to be creating executable +# files. Then when we later use a non-Cygwin program to create the +# real .exe, the previous Cygwin defined ACL sticks. +CYGWIN=nontsec +export CYGWIN endif ALL_DEPS = $^ From a0d892d475cbdabda101d2da3111c25efb43e6e0 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Mon, 21 Jan 2008 00:44:43 +0000 Subject: [PATCH 232/439] (org-unmodified, org-cycle-emulate-tab, org-descriptive-links, org-link-file-path-type, org-remember-use-refile-when-interactive, org-agenda-skip-timestamp-if-done, org-agenda-scheduled-leaders, org-export-ascii-bullets, org-agenda-deadline-faces, turn-on-orgstruct++, orgtbl-to-texinfo, org-mhe-get-header, org-batch-agenda, org-batch-agenda-csv, org-fix-agenda-info, org-kill-note-or-show-branches): Fix typos in docstrings. --- lisp/textmodes/org.el | 56 +++++++++++++++++++++---------------------- 1 file changed, 28 insertions(+), 28 deletions(-) diff --git a/lisp/textmodes/org.el b/lisp/textmodes/org.el index 9826a5b63a0..75e84e51719 100644 --- a/lisp/textmodes/org.el +++ b/lisp/textmodes/org.el @@ -103,7 +103,7 @@ `(and (boundp (quote ,var)) ,var)) (defmacro org-unmodified (&rest body) - "Execute body without changing buffer-modified-p." + "Execute body without changing `buffer-modified-p'." `(set-buffer-modified-p (prog1 (buffer-modified-p) ,@body))) @@ -454,7 +454,7 @@ of the buffer." "Where should `org-cycle' emulate TAB. nil Never white Only in completely white lines -whitestart Only at the beginning of lines, before the first non-white char. +whitestart Only at the beginning of lines, before the first non-white char t Everywhere except in headlines exc-hl-bol Everywhere except at the start of a headline If TAB is used in a place where it does not emulate TAB, the current subtree @@ -1046,7 +1046,7 @@ See the manual for examples." (defcustom org-descriptive-links t "Non-nil means, hide link part and only show description of bracket links. -Bracket links are like [[link][descritpion]]. This variable sets the initial +Bracket links are like [[link][descritpion]]. This variable sets the initial state in new org-mode buffers. The setting can then be toggled on a per-buffer basis from the Org->Hyperlinks menu." :group 'org-link @@ -1056,10 +1056,10 @@ per-buffer basis from the Org->Hyperlinks menu." "How the path name in file links should be stored. Valid values are: -relative relative to the current directory, i.e. the directory of the file +relative Relative to the current directory, i.e. the directory of the file into which the link is being inserted. -absolute absolute path, if possible with ~ for home directory. -noabbrev absolute path, no abbreviation of home directory. +absolute Absolute path, if possible with ~ for home directory. +noabbrev Absolute path, no abbreviation of home directory. adaptive Use relative path for files in the current directory and sub- directories of it. For other files, use an absolute path." :group 'org-link @@ -1413,7 +1413,7 @@ When this variable is nil, `C-c C-c' give you the prompts, and (defcustom org-remember-use-refile-when-interactive t "Non-nil means, use refile to file a remember note. -This is only used when the the interactive mode for selecting a filing +This is only used when the interactive mode for selecting a filing location is used (see the variable `org-remember-store-without-prompt'). When nil, the `org-goto' interface is used." :group 'org-remember @@ -2452,7 +2452,7 @@ deadlines are always turned off when the item is DONE." :type 'boolean) (defcustom org-agenda-skip-timestamp-if-done nil - "Non-nil means don't don't select item by timestamp or -range if it is DONE." + "Non-nil means don't select item by timestamp or -range if it is DONE." :group 'org-agenda-skip :type 'boolean) @@ -2827,7 +2827,7 @@ to occupy a fixed space in the agenda display." (defcustom org-agenda-scheduled-leaders '("Scheduled: " "Sched.%2dx: ") "Text preceeding scheduled items in the agenda view. -THis is a list with two strings. The first applies when the item is +This is a list with two strings. The first applies when the item is scheduled on the current day. The second applies when it has been scheduled previously, it may contain a %d to capture how many days ago the item was scheduled." @@ -3304,7 +3304,7 @@ In the given sequence, these characters will be used for level 1, 2, ..." (defcustom org-export-ascii-bullets '(?* ?+ ?-) "Bullet characters for headlines converted to lists in ASCII export. -The first character is is used for the first lest level generated in this +The first character is used for the first lest level generated in this way, and so on. If there are more levels than characters given here, the list will be repeated. Note that plain lists will keep the same bullets as the have in the @@ -4031,8 +4031,8 @@ list of attributes, like (:foreground \"blue\" :weight bold :underline t)." (0.5 . org-upcoming-deadline) (0.0 . default)) "Faces for showing deadlines in the agenda. -This is a list of cons cells. The cdr of each cess is a face to be used, -and it can also just be a like like '(:foreground \"yellow\"). +This is a list of cons cells. The cdr of each cell is a face to be used, +and it can also just be like '(:foreground \"yellow\"). Each car is a fraction of the head-warning time that must have passed for this the face in the cdr to be used for display. The numbers must be given in descending order. The head-warning time is normally taken @@ -7205,7 +7205,7 @@ so this really moves item trees." (let ((kill-whole-line t)) (kill-line (- ne-ins ne-beg)) (point))) (insert (make-string (- ne-ins ne-beg) ?\n))) - + (org-maybe-renumber-ordered-list)) (goto-char pos) (error "Cannot move this item further up")))) @@ -7528,7 +7528,7 @@ C-c C-c Set tags / toggle checkbox" "Unconditionally turn on `orgstruct-mode', and force org-mode indentations. In addition to setting orgstruct-mode, this also exports all indentation and autofilling variables from org-mode into the buffer. Note that turning -off orgstruct-mode will *not* remove these additonal settings." +off orgstruct-mode will *not* remove these additional settings." (orgstruct-mode 1) (let (var val) (mapc @@ -11659,9 +11659,9 @@ TeXInfo are: %s for the original field value. For example, to wrap everything in @kbd{}, you could use :fmt \"@kbd{%s}\". This may also be a property list with column numbers and - formats. for example :fmt (2 \"@kbd{%s}\" 4 \"@code{%s}\"). + formats. For example :fmt (2 \"@kbd{%s}\" 4 \"@code{%s}\"). -:cf \"f1 f2..\" The column fractions for the table. Bye default these +:cf \"f1 f2..\" The column fractions for the table. By default these are computed automatically from the width of the columns under org-mode. @@ -13040,8 +13040,8 @@ use sequences." (mh-show-buffer-message-number)))) (defun org-mhe-get-header (header) - "Return a header of the message in folder mode. This will create a -show buffer for the corresponding message. If you have a more clever + "Return a header of the message in folder mode. This will create a +show buffer for the corresponding message. If you have a more clever idea..." (let* ((folder (org-mhe-get-message-folder)) (num (org-mhe-get-message-num)) @@ -13745,7 +13745,7 @@ See also the variable `org-reverse-note-order'." (when remember-save-after-remembering (save-buffer) (if (not visiting) (kill-buffer (current-buffer))))))))) - + t) ;; return t to indicate that we took care of this note. (defun org-get-org-file () @@ -13847,7 +13847,7 @@ See also the variable `org-reverse-note-order'." (goto-char (point-at-eol)))))))) (org-release-buffers org-agenda-new-buffers) (nreverse targets)))) - + (defun org-get-outline-path () (let (rtn) (save-excursion @@ -15776,7 +15776,7 @@ If WHICH is nil or `all', get all properties. If WHICH is (unless (member key excluded) (push (cons key (or value "")) props))))) (if clocksum - (push (cons "CLOCKSUM" + (push (cons "CLOCKSUM" (org-column-number-to-string (/ (float clocksum) 60.) 'add_times)) props)) @@ -17501,8 +17501,8 @@ user." "Check string S for special relative date string. TODAY and DEFAULT are internal times, for today and for a default. Return shift list (N what def-flag) -WHAT is \"d\", \"w\", \"m\", or \"y\" for day. week, month, year. -N is the number if WHATs to shift +WHAT is \"d\", \"w\", \"m\", or \"y\" for day, week, month, year. +N is the number of WHATs to shift. DEF-FLAG is t when a double ++ or -- indicates shift relative to the DEFAULT date rather than TODAY." (when (string-match @@ -19471,7 +19471,7 @@ L Timeline for current buffer # List stuck projects (!=configure) ((and (> (length selstring) 0) (eq c ?\d)) (delete-window) (org-agenda-get-restriction-and-command prefix-descriptions)) - + ((equal c ?q) (error "Abort")) (t (error "Invalid key %c" c)))))))) @@ -19518,7 +19518,7 @@ L Timeline for current buffer # List stuck projects (!=configure) "Run an agenda command in batch mode and send the result to STDOUT. If CMD-KEY is a string of length 1, it is used as a key in `org-agenda-custom-commands' and triggers this command. If it is a -longer string is is used as a tags/todo match string. +longer string it is used as a tags/todo match string. Paramters are alternating variable names and values that will be bound before running the agenda command." (let (pars) @@ -19543,7 +19543,7 @@ before running the agenda command." "Run an agenda command in batch mode and send the result to STDOUT. If CMD-KEY is a string of length 1, it is used as a key in `org-agenda-custom-commands' and triggers this command. If it is a -longer string is is used as a tags/todo match string. +longer string it is used as a tags/todo match string. Paramters are alternating variable names and values that will be bound before running the agenda command. @@ -19600,7 +19600,7 @@ agenda-day The day in the agenda where this is listed" (defun org-fix-agenda-info (props) "Make sure all properties on an agenda item have a canonical form, -so the the export commands caneasily use it." +so the export commands can easily use it." (let (tmp re) (when (setq tmp (plist-get props 'tags)) (setq props (plist-put props 'tags (mapconcat 'identity tmp ":")))) @@ -26695,7 +26695,7 @@ Also updates the keyword regular expressions." (message "Org-mode restarted to refresh keyword and special line setup")) (defun org-kill-note-or-show-branches () - "If this is a Note buffer, abort storing the note. Else call `show-branches'." + "If this is a Note buffer, abort storing the note. Else call `show-branches'." (interactive) (if (not org-finish-function) (call-interactively 'show-branches) From 43530341912354c83d9ea9974ba829bb6b59e388 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Mon, 21 Jan 2008 00:53:31 +0000 Subject: [PATCH 233/439] *** empty log message *** --- lisp/ChangeLog | 31 ++++++++++++++++++------------- 1 file changed, 18 insertions(+), 13 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ac453cbc91e..fd8d5b4ad8f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,14 @@ +2008-01-21 Juanma Barranquero + + * textmodes/org.el (org-unmodified, org-cycle-emulate-tab) + (org-descriptive-links, org-link-file-path-type) + (org-remember-use-refile-when-interactive) + (org-agenda-skip-timestamp-if-done, org-agenda-scheduled-leaders) + (org-export-ascii-bullets, org-agenda-deadline-faces) + (turn-on-orgstruct++, orgtbl-to-texinfo, org-mhe-get-header) + (org-batch-agenda, org-batch-agenda-csv, org-fix-agenda-info) + (org-kill-note-or-show-branches): Fix typos in docstrings. + 2008-01-20 Thien-Thi Nguyen * vc.el (vc-process-sentinel): Set mode-line-process. @@ -35,7 +46,7 @@ * progmodes/python.el: Quote all calls to "auxiliary skeleton"s to prevent infloops. -2008-01-20 Martin Svenson (tiny change) +2008-01-20 Martin Svenson (tiny change) * progmodes/python.el (python-imports): Default to "None". @@ -54,8 +65,7 @@ (hide-ifdef-mode-menu): Add entry for hide-ifdef-toggle-shadowing. (hide-ifdef-region-internal): Give new overlay hide-ifdef property. Shadow text when hide-ifdef-shadow is non-nil. - (hif-show-ifdef-region): Remove overlays with hide-ifdef - property set. + (hif-show-ifdef-region): Remove overlays with hide-ifdef property set. (hif-hide-line): Use when instead of if. (hide-ifdef-initially, hide-ifdef-read-only, hide-ifdef-lines): Remove unneeded * from doc-strings. @@ -141,8 +151,7 @@ (org-agenda-highlight-todo): Respect `org-agenda-todo-keyword-format'. (org-agenda-todo-keyword-format): New option. - (org-infile-export-plist): No restriction while searching for - options. + (org-infile-export-plist): No restriction while searching for options. (org-remember-handler): Remove comments at the end of the buffer. (org-remember-use-refile-when-interactive): New option. (org-table-sort-lines): Make sure sorting works on link @@ -153,8 +162,7 @@ `full-file-path'. (org-get-refile-targets): Respect new values for `org-refile-use-outline-path'. - (org-agenda-get-restriction-and-command): DEL goes back to initial - list. + (org-agenda-get-restriction-and-command): DEL goes back to initial list. (org-export-as-xoxo): Restore point when done. (org-open-file): Allow multiple %s in command. (org-clock-in-switch-to-state): New option. @@ -162,8 +170,7 @@ (org-last-remember-storage-locations): New variable. (org-get-refile-targets): Interpret the new maxlevel setting. (org-refile-targets): New option `:maxlevel'. - (org-copy-subtree): Include empty lines before but not after - subtree. + (org-copy-subtree): Include empty lines before but not after subtree. (org-back-over-empty-lines, org-skip-whitespace): New functions. (org-move-item-down, org-move-item-up): Include empty lines before but not after item. @@ -209,15 +216,13 @@ (org-hide-emphasis-markers): New option. (org-additional-option-like-keywords): Add new keywords. (org-get-entry): Rename from `org-get-cleaned-entry'. - (org-icalendar-cleanup-string): New function for quoting icalendar - text. + (org-icalendar-cleanup-string): New function for quoting icalendar text. (org-agenda-skip-scheduled-if-done): New option. (org-agenda-get-scheduled, org-agenda-get-blocks): Use `org-agenda-skip-scheduled-if-done'. (org-prepare-agenda-buffers): Allow buffers as arguments. (org-entry-properties): Add CATEGORY as a special property. - (org-use-property-inheritance): Allow a list of properties as a - value. + (org-use-property-inheritance): Allow a list of properties as a value. (org-eval-in-calendar): No longer update the prompt. (org-read-date-popup-calendar): Rename from `org-popup-calendar-for-date-prompt'. From adcc05dc927c33cfe8c03c761a11de26756ff5d7 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Mon, 21 Jan 2008 04:46:12 +0000 Subject: [PATCH 234/439] Move defcustoms and defface to start of file. --- lisp/progmodes/hideif.el | 63 ++++++++++++++++++++-------------------- 1 file changed, 32 insertions(+), 31 deletions(-) diff --git a/lisp/progmodes/hideif.el b/lisp/progmodes/hideif.el index 0d2bf1a656a..b0f3cc9e3af 100644 --- a/lisp/progmodes/hideif.el +++ b/lisp/progmodes/hideif.el @@ -1,7 +1,7 @@ ;;; hideif.el --- hides selected code within ifdef -;; Copyright (C) 1988, 1994, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 -;; Free Software Foundation, Inc. +;; Copyright (C) 1988, 1994, 2001, 2002, 2003, 2004, 2005, 2006, 2007, +;; 2008 Free Software Foundation, Inc. ;; Author: Daniel LaLiberte ;; Maintainer: FSF @@ -114,6 +114,36 @@ "Hide selected code within `ifdef'." :group 'c) +;;;###autoload +(defcustom hide-ifdef-initially nil + "Non-nil means call `hide-ifdefs' when Hide-Ifdef mode is first activated." + :type 'boolean + :group 'hide-ifdef) + +;;;###autoload +(defcustom hide-ifdef-read-only nil + "Set to non-nil if you want buffer to be read-only while hiding text." + :type 'boolean + :group 'hide-ifdef) + +;;;###autoload +(defcustom hide-ifdef-lines nil + "Non-nil means hide the #ifX, #else, and #endif lines." + :type 'boolean + :group 'hide-ifdef) + +;;;###autoload +(defcustom hide-ifdef-shadow nil + "Non-nil means shadow text instead of hiding it." + :type 'boolean + :group 'hide-ifdef) + +;;;###autoload +(defface hide-ifdef-shadow '((t (:inherit shadow))) + "Face for shadowing ifdef blocks." + :group 'hide-ifdef) + + (defvar hide-ifdef-mode-submap ;; Set up the submap that goes after the prefix key. (let ((map (make-sparse-keymap))) @@ -833,35 +863,6 @@ It does not do the work that's pointless to redo on a recursive entry." ;;===%%SF%% exports (Start) === -;;;###autoload -(defcustom hide-ifdef-initially nil - "Non-nil means call `hide-ifdefs' when Hide-Ifdef mode is first activated." - :type 'boolean - :group 'hide-ifdef) - -;;;###autoload -(defcustom hide-ifdef-read-only nil - "Set to non-nil if you want buffer to be read-only while hiding text." - :type 'boolean - :group 'hide-ifdef) - -;;;###autoload -(defcustom hide-ifdef-lines nil - "Non-nil means hide the #ifX, #else, and #endif lines." - :type 'boolean - :group 'hide-ifdef) - -;;;###autoload -(defcustom hide-ifdef-shadow nil - "Non-nil means shadow text instead of hiding it." - :type 'boolean - :group 'hide-ifdef) - -;;;###autoload -(defface hide-ifdef-shadow '((t (:inherit shadow))) - "Face for shadowing ifdef blocks." - :group 'hide-ifdef) - (defun hide-ifdef-toggle-read-only () "Toggle `hide-ifdef-read-only'." (interactive) From a1e8139657344bbea722654c1d569e9e8dc8e1e6 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Mon, 21 Jan 2008 04:47:10 +0000 Subject: [PATCH 235/439] (org-entry-properties): Let-bind `clocksum'. --- lisp/ChangeLog | 6 ++++++ lisp/textmodes/org.el | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index fd8d5b4ad8f..eadbd4dedb6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-21 Glenn Morris + + * progmodes/hideif.el: Move defcustoms and defface to start of file. + + * textmodes/org.el (org-entry-properties): Let-bind `clocksum'. + 2008-01-21 Juanma Barranquero * textmodes/org.el (org-unmodified, org-cycle-emulate-tab) diff --git a/lisp/textmodes/org.el b/lisp/textmodes/org.el index 75e84e51719..00a3bc2d195 100644 --- a/lisp/textmodes/org.el +++ b/lisp/textmodes/org.el @@ -15725,7 +15725,7 @@ If WHICH is nil or `all', get all properties. If WHICH is (org-with-point-at pom (let ((clockstr (substring org-clock-string 0 -1)) (excluded '("TODO" "TAGS" "ALLTAGS" "PRIORITY")) - beg end range props sum-props key value string) + beg end range props sum-props key value string clocksum) (save-excursion (when (condition-case nil (org-back-to-heading t) (error nil)) (setq beg (point)) From 8ca7e0f152417725530073c8fbe2b0f99dcdb823 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Mon, 21 Jan 2008 06:47:22 +0000 Subject: [PATCH 236/439] Updated from master source. --- ChangeLog | 4 ++++ config.guess | 47 ++++++++++++++++++++++++++++----------------- config.sub | 54 +++++++++++++++++++++++++++++++++++++++++++--------- 3 files changed, 79 insertions(+), 26 deletions(-) diff --git a/ChangeLog b/ChangeLog index 5d993d114f4..f78606d7367 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-01-21 Dan Nicolaescu + + * config.guess, config.sub: Updated from master source. + 2008-01-17 Glenn Morris * configure.in (HAVE_X86_64_LIB64_DIR): Also set on s390x systems. diff --git a/config.guess b/config.guess index 1b63f307a6f..ca2a03ca4f1 100755 --- a/config.guess +++ b/config.guess @@ -1,10 +1,10 @@ #! /bin/sh # Attempt to guess a canonical system name. -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006, 2007 -# Free Software Foundation, Inc. +# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 +# Free Software Foundation, Inc. -timestamp='2007-02-26' +timestamp='2008-01-08' # This file is free software; you can redistribute it and/or modify it # under the terms of the GNU General Public License as published by @@ -56,8 +56,8 @@ version="\ GNU config.guess ($timestamp) Originally written by Per Bothner. -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -Free Software Foundation, Inc. +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, +2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -330,7 +330,7 @@ case "${UNAME_MACHINE}:${UNAME_SYSTEM}:${UNAME_RELEASE}:${UNAME_VERSION}" in sun4*:SunOS:5.*:* | tadpole*:SunOS:5.*:*) echo sparc-sun-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; - i86pc:SunOS:5.*:*) + i86pc:SunOS:5.*:* | i86xen:SunOS:5.*:*) echo i386-pc-solaris2`echo ${UNAME_RELEASE}|sed -e 's/[^.]*//'` exit ;; sun4*:SunOS:6*:*) @@ -532,7 +532,7 @@ EOF echo rs6000-ibm-aix3.2 fi exit ;; - *:AIX:*:[45]) + *:AIX:*:[456]) IBM_CPU_ID=`/usr/sbin/lsdev -C -c processor -S available | sed 1q | awk '{ print $1 }'` if /usr/sbin/lsattr -El ${IBM_CPU_ID} | grep ' POWER' >/dev/null 2>&1; then IBM_ARCH=rs6000 @@ -791,12 +791,18 @@ EOF i*:PW*:*) echo ${UNAME_MACHINE}-pc-pw32 exit ;; - x86:Interix*:[3456]*) - echo i586-pc-interix${UNAME_RELEASE} - exit ;; - EM64T:Interix*:[3456]* | authenticamd:Interix*:[3456]*) - echo x86_64-unknown-interix${UNAME_RELEASE} - exit ;; + *:Interix*:[3456]*) + case ${UNAME_MACHINE} in + x86) + echo i586-pc-interix${UNAME_RELEASE} + exit ;; + EM64T | authenticamd) + echo x86_64-unknown-interix${UNAME_RELEASE} + exit ;; + IA64) + echo ia64-unknown-interix${UNAME_RELEASE} + exit ;; + esac ;; [345]86:Windows_95:* | [345]86:Windows_98:* | [345]86:Windows_NT:*) echo i${UNAME_MACHINE}-pc-mks exit ;; @@ -830,7 +836,14 @@ EOF echo ${UNAME_MACHINE}-pc-minix exit ;; arm*:Linux:*:*) - echo ${UNAME_MACHINE}-unknown-linux-gnu + eval $set_cc_for_build + if echo __ARM_EABI__ | $CC_FOR_BUILD -E - 2>/dev/null \ + | grep -q __ARM_EABI__ + then + echo ${UNAME_MACHINE}-unknown-linux-gnu + else + echo ${UNAME_MACHINE}-unknown-linux-gnueabi + fi exit ;; avr32*:Linux:*:*) echo ${UNAME_MACHINE}-unknown-linux-gnu @@ -951,8 +964,8 @@ EOF x86_64:Linux:*:*) echo x86_64-unknown-linux-gnu exit ;; - xtensa:Linux:*:*) - echo xtensa-unknown-linux-gnu + xtensa*:Linux:*:*) + echo ${UNAME_MACHINE}-unknown-linux-gnu exit ;; i*86:Linux:*:*) # The BFD linker knows what the default object file format is, so diff --git a/config.sub b/config.sub index c8d69e9a05f..6759825a5b7 100755 --- a/config.sub +++ b/config.sub @@ -1,10 +1,10 @@ #! /bin/sh # Configuration validation subroutine script. -# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006, 2007 -# Free Software Foundation, Inc. +# Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, +# 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 +# Free Software Foundation, Inc. -timestamp='2007-02-26' +timestamp='2008-01-16' # This file is (in principle) common to ALL GNU software. # The presence of a machine in this file suggests that SOME GNU software @@ -72,8 +72,8 @@ Report bugs and patches to ." version="\ GNU config.sub ($timestamp) -Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, 2004, 2005 -Free Software Foundation, Inc. +Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 1999, 2000, 2001, +2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. This is free software; see the source for copying conditions. There is NO warranty; not even for MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE." @@ -369,10 +369,14 @@ case $basic_machine in | v850-* | v850e-* | vax-* \ | we32k-* \ | x86-* | x86_64-* | xc16x-* | xps100-* | xscale-* | xscalee[bl]-* \ - | xstormy16-* | xtensa-* \ + | xstormy16-* | xtensa*-* \ | ymp-* \ | z8k-*) ;; + # Recognize the basic CPU types without company name, with glob match. + xtensa*) + basic_machine=$basic_machine-unknown + ;; # Recognize the various machine names and aliases which stand # for a CPU type and a company and sometimes even an OS. 386bsd) @@ -443,6 +447,14 @@ case $basic_machine in basic_machine=ns32k-sequent os=-dynix ;; + blackfin) + basic_machine=bfin-unknown + os=-linux + ;; + blackfin-*) + basic_machine=bfin-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; c90) basic_machine=c90-cray os=-unicos @@ -475,8 +487,8 @@ case $basic_machine in basic_machine=craynv-cray os=-unicosmp ;; - cr16c) - basic_machine=cr16c-unknown + cr16) + basic_machine=cr16-unknown os=-elf ;; crds | unos) @@ -668,6 +680,14 @@ case $basic_machine in basic_machine=m68k-isi os=-sysv ;; + m68knommu) + basic_machine=m68k-unknown + os=-linux + ;; + m68knommu-*) + basic_machine=m68k-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; m88k-omron*) basic_machine=m88k-omron ;; @@ -683,6 +703,10 @@ case $basic_machine in basic_machine=i386-pc os=-mingw32 ;; + mingw32ce) + basic_machine=arm-unknown + os=-mingw32ce + ;; miniframe) basic_machine=m68000-convergent ;; @@ -809,6 +833,14 @@ case $basic_machine in basic_machine=i860-intel os=-osf ;; + parisc) + basic_machine=hppa-unknown + os=-linux + ;; + parisc-*) + basic_machine=hppa-`echo $basic_machine | sed 's/^[^-]*-//'` + os=-linux + ;; pbd) basic_machine=sparc-tti ;; @@ -1017,6 +1049,10 @@ case $basic_machine in basic_machine=tic6x-unknown os=-coff ;; + tile*) + basic_machine=tile-unknown + os=-linux-gnu + ;; tx39) basic_machine=mipstx39-unknown ;; From dcb4156958af974a982e5d39230787563e311f7a Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Mon, 21 Jan 2008 09:35:45 +0000 Subject: [PATCH 237/439] *** empty log message *** --- admin/FOR-RELEASE | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index feb509aece5..d4b432600e2 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -34,6 +34,11 @@ to the hack introduced on 2005-07-01 to fix some other Cleartype problem. ** henman@it.to-be.co.jp 09 Aug 2006: ispell.el problem on Cygwin. (Did we decide that is unreproducible?) +** lennart.borgman@gmail.com 09 Jan 2008: ps-print-buffer-with-faces hangs +If no printer is connected to the printer port that Emacs is printing +to, I/O to that port hangs in the system calls. Emacs should avoid +defaulting to a printer port that is not in use. + * BUGS WAITING FOR MORE USER INPUT ** undefined reference getopt_long From 1ec6ded98799401fdf9535bb6cd3510dfee4d76a Mon Sep 17 00:00:00 2001 From: YAMAMOTO Mitsuharu Date: Mon, 21 Jan 2008 09:59:25 +0000 Subject: [PATCH 238/439] (x_scroll_bar_create): Initialize bar->redraw_needed_p. (XTset_vertical_scroll_bar): Redraw scroll bar if bar->redraw_needed_p is set even without positional changes. (x_scroll_bar_clear): Set bar->redraw_needed_p. --- src/macterm.c | 32 ++++++++++++++++++++++++++------ 1 file changed, 26 insertions(+), 6 deletions(-) diff --git a/src/macterm.c b/src/macterm.c index 82bd085a9b2..b110f0372fc 100644 --- a/src/macterm.c +++ b/src/macterm.c @@ -4998,6 +4998,7 @@ x_scroll_bar_create (w, top, left, width, height, disp_top, disp_height) XSETINT (bar->start, 0); XSETINT (bar->end, 0); bar->dragging = Qnil; + bar->redraw_needed_p = Qnil; #ifdef USE_TOOLKIT_SCROLL_BARS bar->track_top = Qnil; bar->track_height = Qnil; @@ -5193,10 +5194,20 @@ XTset_vertical_scroll_bar (w, portion, whole, position) BLOCK_INPUT; /* If already correctly positioned, do nothing. */ - if (!(XINT (bar->left) == sb_left - && XINT (bar->top) == top - && XINT (bar->width) == sb_width - && XINT (bar->height) == height)) + if (XINT (bar->left) == sb_left + && XINT (bar->top) == top + && XINT (bar->width) == sb_width + && XINT (bar->height) == height) + { + if (!NILP (bar->redraw_needed_p)) + { +#if USE_CG_DRAWING + mac_prepare_for_quickdraw (f); +#endif + Draw1Control (SCROLL_BAR_CONTROL_HANDLE (bar)); + } + } + else { /* Since toolkit scroll bars are smaller than the space reserved for them on the frame, we have to clear "under" them. */ @@ -5229,6 +5240,8 @@ XTset_vertical_scroll_bar (w, portion, whole, position) UNBLOCK_INPUT; } + bar->redraw_needed_p = Qnil; + #ifdef USE_TOOLKIT_SCROLL_BARS if (NILP (bar->track_top)) { @@ -5581,8 +5594,15 @@ void x_scroll_bar_clear (f) FRAME_PTR f; { - XTcondemn_scroll_bars (f); - XTjudge_scroll_bars (f); + Lisp_Object bar; + + /* We can have scroll bars even if this is 0, + if we just turned off scroll bar mode. + But in that case we should not clear them. */ + if (FRAME_HAS_VERTICAL_SCROLL_BARS (f)) + for (bar = FRAME_SCROLL_BARS (f); VECTORP (bar); + bar = XSCROLL_BAR (bar)->next) + XSCROLL_BAR (bar)->redraw_needed_p = Qt; } From 223b3d1da9d4d73216b3e58f4e8c3d6b2e56739a Mon Sep 17 00:00:00 2001 From: YAMAMOTO Mitsuharu Date: Mon, 21 Jan 2008 09:59:58 +0000 Subject: [PATCH 239/439] (struct scroll_bar): New member `redraw_needed_p'. --- src/ChangeLog | 9 +++++++++ src/macterm.h | 3 +++ 2 files changed, 12 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index 1ec2ad7aa85..1c4b08d24d7 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,12 @@ +2008-01-21 YAMAMOTO Mitsuharu + + * macterm.c (x_scroll_bar_create): Initialize bar->redraw_needed_p. + (XTset_vertical_scroll_bar): Redraw scroll bar if bar->redraw_needed_p + is set even without positional changes. + (x_scroll_bar_clear): Set bar->redraw_needed_p. + + * macterm.h (struct scroll_bar): New member `redraw_needed_p'. + 2008-01-19 Kenichi Handa * coding.c (detect_coding_iso2022): New arg latin_extra_code_state. diff --git a/src/macterm.h b/src/macterm.h index e596a148dcd..69d987b0cdc 100644 --- a/src/macterm.h +++ b/src/macterm.h @@ -435,6 +435,9 @@ struct scroll_bar { being dragged, this is Qnil. */ Lisp_Object dragging; + /* t if redraw needed in the next XTset_vertical_scroll_bar call. */ + Lisp_Object redraw_needed_p; + #ifdef USE_TOOLKIT_SCROLL_BARS /* The position and size of the scroll bar handle track area in pixels, relative to the frame. */ From 88fd26a1c7be6bbc8b0ab1eb00abcfb6dafe74a1 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Mon, 21 Jan 2008 12:06:59 +0000 Subject: [PATCH 240/439] (server-log-time-function): New function. (server-log): Use it. --- lisp/ChangeLog | 5 +++++ lisp/server.el | 11 +++++++---- 2 files changed, 12 insertions(+), 4 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index eadbd4dedb6..db2bb83bf38 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-21 Juanma Barranquero + + * server.el (server-log-time-function): New function. + (server-log): Use it. + 2008-01-21 Glenn Morris * progmodes/hideif.el: Move defcustoms and defface to start of file. diff --git a/lisp/server.el b/lisp/server.el index 8e14ffa3826..2087af26b10 100644 --- a/lisp/server.el +++ b/lisp/server.el @@ -291,17 +291,20 @@ If NOFRAME is non-nil, let the frames live. (To be used from (server-log "Deleted" proc)))) +(defvar server-log-time-function 'current-time-string + "Function to generate timestamps for the *server* buffer.") + (defun server-log (string &optional client) "If a *server* buffer exists, write STRING to it for logging purposes. If CLIENT is non-nil, add a description of it to the logged message." (when (get-buffer "*server*") (with-current-buffer "*server*" (goto-char (point-max)) - (insert (current-time-string) + (insert (funcall server-log-time-function) (cond - ((null client) " ") - ((listp client) (format " %s: " (car client))) - (t (format " %s: " client))) + ((null client) " ") + ((listp client) (format " %s: " (car client))) + (t (format " %s: " client))) string) (or (bolp) (newline))))) From 482cfc3a9551ae8b876640f5e314da9a7974f223 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Mon, 21 Jan 2008 12:43:46 +0000 Subject: [PATCH 241/439] Fix problem with cleanning blank faces when turniing off blank-mode. Eliminate -face suffix. --- lisp/ChangeLog | 18 ++++++++++ lisp/blank-mode.el | 88 +++++++++++++++++++++++----------------------- 2 files changed, 62 insertions(+), 44 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ac7bef8b4c9..7633804d2d5 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,21 @@ +2008-01-21 Vinicius Jose Latorre + + * blank-mode.el: Fix a problem of cleaning blank faces when turning off + blank-mode in some buffers (like *info* buffers). Reported by Juanma + Barranquero . Eliminate `-face' suffix of all + blank-mode faces. Doc fix. New version 8.1. + (blank-turn-on, blank-turn-off): Replace (and CONDITION BODY) by (when + CONDITION BODY). + (blank-space-face): Face/option name replaced by blank-space. + (blank-hspace-face): Face/option name replaced by blank-hspace. + (blank-tab-face): Face/option name replaced by blank-tab. + (blank-newline-face): Face/option name replaced by blank-newline. + (blank-trailing-face): Face/option name replaced by blank-trailing. + (blank-line-face): Face/option name replaced by blank-line. + (blank-space-before-tab-face): Face/option name replaced by + blank-space-before-tab. + (blank-color-on, blank-color-off, blank-display-char-on): Fix code. + 2008-01-20 Glenn Morris * progmodes/python.el: Quote all calls to "auxiliary skeleton"s to diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el index 112562af576..9d36ebde6ae 100644 --- a/lisp/blank-mode.el +++ b/lisp/blank-mode.el @@ -6,7 +6,7 @@ ;; Author: Vinicius Jose Latorre ;; Maintainer: Vinicius Jose Latorre ;; Keywords: data, wp -;; Version: 8.0 +;; Version: 8.1 ;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre ;; This file is part of GNU Emacs. @@ -180,22 +180,22 @@ ;; `blank-chars' Specify which kind of blank is ;; visualized. ;; -;; `blank-space-face' Face used to visualize SPACE. +;; `blank-space' Face used to visualize SPACE. ;; -;; `blank-hspace-face' Face used to visualize HARD SPACE. +;; `blank-hspace' Face used to visualize HARD SPACE. ;; -;; `blank-tab-face' Face used to visualize TAB. +;; `blank-tab' Face used to visualize TAB. ;; -;; `blank-newline-face' Face used to visualize NEWLINE char +;; `blank-newline' Face used to visualize NEWLINE char ;; mapping. ;; -;; `blank-trailing-face' Face used to visualize trailing +;; `blank-trailing' Face used to visualize trailing ;; blanks. ;; -;; `blank-line-face' Face used to visualize "long" lines. +;; `blank-line' Face used to visualize "long" lines. ;; -;; `blank-space-before-tab-face' Face used to visualize SPACEs -;; before TAB. +;; `blank-space-before-tab' Face used to visualize SPACEs before +;; TAB. ;; ;; `blank-space-regexp' Specify SPACE characters regexp. ;; @@ -335,7 +335,7 @@ has `mark' as an element." :group 'blank) -(defcustom blank-space-face 'blank-space-face +(defcustom blank-space 'blank-space "*Symbol face used to visualize SPACE. Used when `blank-style' has `color' as an element." @@ -343,7 +343,7 @@ Used when `blank-style' has `color' as an element." :group 'blank) -(defface blank-space-face +(defface blank-space '((((class color) (background dark)) (:background "grey20" :foreground "aquamarine3")) (((class color) (background light)) @@ -353,7 +353,7 @@ Used when `blank-style' has `color' as an element." :group 'blank) -(defcustom blank-hspace-face 'blank-hspace-face +(defcustom blank-hspace 'blank-hspace "*Symbol face used to visualize HARD SPACE. Used when `blank-style' has `color' as an element." @@ -361,7 +361,7 @@ Used when `blank-style' has `color' as an element." :group 'blank) -(defface blank-hspace-face ; 'nobreak-space +(defface blank-hspace ; 'nobreak-space '((((class color) (background dark)) (:background "grey24" :foreground "aquamarine3")) (((class color) (background light)) @@ -371,7 +371,7 @@ Used when `blank-style' has `color' as an element." :group 'blank) -(defcustom blank-tab-face 'blank-tab-face +(defcustom blank-tab 'blank-tab "*Symbol face used to visualize TAB. Used when `blank-style' has `color' as an element." @@ -379,7 +379,7 @@ Used when `blank-style' has `color' as an element." :group 'blank) -(defface blank-tab-face +(defface blank-tab '((((class color) (background dark)) (:background "grey22" :foreground "aquamarine3")) (((class color) (background light)) @@ -389,7 +389,7 @@ Used when `blank-style' has `color' as an element." :group 'blank) -(defcustom blank-newline-face 'blank-newline-face +(defcustom blank-newline 'blank-newline "*Symbol face used to visualize NEWLINE char mapping. See `blank-display-mappings'. @@ -400,7 +400,7 @@ and `blank-chars' has `newline' as an element." :group 'blank) -(defface blank-newline-face +(defface blank-newline '((((class color) (background dark)) (:background "grey26" :foreground "aquamarine3" :bold t)) (((class color) (background light)) @@ -412,7 +412,7 @@ See `blank-display-mappings'." :group 'blank) -(defcustom blank-trailing-face 'blank-trailing-face +(defcustom blank-trailing 'blank-trailing "*Symbol face used to visualize traling blanks. Used when `blank-style' has `color' as an element." @@ -420,14 +420,14 @@ Used when `blank-style' has `color' as an element." :group 'blank) -(defface blank-trailing-face ; 'trailing-whitespace +(defface blank-trailing ; 'trailing-whitespace '((((class mono)) (:inverse-video t :bold t :underline t)) (t (:background "red1" :foreground "yellow" :bold t))) "Face used to visualize trailing blanks." :group 'blank) -(defcustom blank-line-face 'blank-line-face +(defcustom blank-line 'blank-line "*Symbol face used to visualize \"long\" lines. See `blank-line-length'. @@ -437,7 +437,7 @@ Used when `blank-style' has `color' as an element." :group 'blank) -(defface blank-line-face +(defface blank-line '((((class mono)) (:inverse-video t :bold t :underline t)) (t (:background "gray20" :foreground "violet"))) "Face used to visualize \"long\" lines. @@ -446,7 +446,7 @@ See `blank-line-length'." :group 'blank) -(defcustom blank-space-before-tab-face 'blank-space-before-tab-face +(defcustom blank-space-before-tab 'blank-space-before-tab "*Symbol face used to visualize SPACEs before TAB. Used when `blank-style' has `color' as an element." @@ -454,7 +454,7 @@ Used when `blank-style' has `color' as an element." :group 'blank) -(defface blank-space-before-tab-face +(defface blank-space-before-tab '((((class mono)) (:inverse-video t :bold t :underline t)) (t (:background "DarkOrange" :foreground "firebrick"))) "Face used to visualize SPACEs before TAB." @@ -595,7 +595,7 @@ Used when `blank-style' has `color' as an element, and (?\x920 [?\x924] [?_]) ; hard space - currency (?\xE20 [?\xE24] [?_]) ; hard space - currency (?\xF20 [?\xF24] [?_]) ; hard space - currency - ;; NEWLINE is displayed using the face `blank-newline-face' + ;; NEWLINE is displayed using the face `blank-newline' (?\n [?$ ?\n]) ; end-of-line - dollar sign ;; (?\n [?\u21B5 ?\n] [?$ ?\n]) ; end-of-line - downwards arrow ;; (?\n [?\xB6 ?\n] [?$ ?\n]) ; end-of-line - pilcrow @@ -626,9 +626,9 @@ VECTOR is a vector of characters to be displayed in place of CHAR. that character is displayed unmodified. The NEWLINE character is displayed using the face given by -`blank-newline-face' variable. The characters in the vector to be -displayed will not have this face applied if the character code is -above #x1FFFF. +`blank-newline' variable. The characters in the vector to be +displayed will not have this face applied if the character code +is above #x1FFFF. Used when `blank-style' has `mark' as an element." :type '(repeat @@ -1105,18 +1105,18 @@ options are valid." (setq blank-active-chars (if (listp blank-chars) blank-chars (list blank-chars))) - (and (memq 'color blank-active-style) - (blank-color-on)) - (and (memq 'mark blank-active-style) - (blank-display-char-on))) + (when (memq 'color blank-active-style) + (blank-color-on)) + (when (memq 'mark blank-active-style) + (blank-display-char-on))) (defun blank-turn-off () "Turn off blank visualization." - (and (memq 'color blank-active-style) - (blank-color-off)) - (and (memq 'mark blank-active-style) - (blank-display-char-off))) + (when (memq 'color blank-active-style) + (blank-color-off)) + (when (memq 'mark blank-active-style) + (blank-display-char-off))) (defun blank-color-on () @@ -1135,16 +1135,16 @@ options are valid." nil (list ;; Show SPACEs - (list blank-space-regexp 1 blank-space-face t) + (list blank-space-regexp 1 blank-space t) ;; Show HARD SPACEs - (list blank-hspace-regexp 1 blank-hspace-face t)) + (list blank-hspace-regexp 1 blank-hspace t)) t)) (when (memq 'tabs blank-active-chars) (font-lock-add-keywords nil (list ;; Show TABs - (list blank-tab-regexp 1 blank-tab-face t)) + (list blank-tab-regexp 1 blank-tab t)) t)) (when (memq 'trailing blank-active-chars) (font-lock-add-keywords @@ -1152,7 +1152,7 @@ options are valid." (list ;; Show trailing blanks (list (concat "\\(\\(" blank-trailing-regexp "\\)+\\)$") - 1 blank-trailing-face t)) + 1 blank-trailing t)) t)) (when (memq 'lines blank-active-chars) (font-lock-add-keywords @@ -1161,7 +1161,7 @@ options are valid." ;; Show "long" lines (list (concat "^\\(.\\{" (int-to-string blank-line-length) ",\\}\\)$") - 1 blank-line-face t)) + 1 blank-line t)) t)) (when (memq 'space-before-tab blank-active-chars) (font-lock-add-keywords @@ -1169,7 +1169,7 @@ options are valid." (list ;; Show SPACEs before TAB (list blank-space-before-tab-regexp - 1 blank-space-before-tab-face t)) + 1 blank-space-before-tab t)) t)) ;; now turn on font lock and highlight blanks (font-lock-mode 1))) @@ -1178,11 +1178,11 @@ options are valid." (defun blank-color-off () "Turn off color visualization." (when blank-active-chars + ;; turn off font lock + (font-lock-mode 0) (when blank-font-lock (setq blank-font-lock nil font-lock-keywords blank-font-lock-keywords)) - ;; turn off font lock - (font-lock-mode 0) ;; restore original font lock state (font-lock-mode blank-font-lock-mode))) @@ -1252,7 +1252,7 @@ options are valid." (or (eq (aref vec i) ?\n) (> (aref vec i) #x1FFFF) (aset vec i (make-glyph-code (aref vec i) - blank-newline-face))))) + blank-newline))))) ;; Display mapping (aset buffer-display-table (car entry) vec)) ;; Newline char - don't display it From 040f578c57c69724835561134dd9d01480f043a3 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Mon, 21 Jan 2008 12:45:58 +0000 Subject: [PATCH 242/439] Fix problem with cleanning blank faces when turniing off blank-mode. Eliminate -face suffix. --- lisp/ChangeLog | 32 +++++ lisp/blank-mode.el | 300 ++++++++++++++++++++++----------------------- 2 files changed, 182 insertions(+), 150 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index db2bb83bf38..7b05fb9c568 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,35 @@ +2008-01-21 Vinicius Jose Latorre + + * blank-mode.el: Fix a problem of cleaning blank faces when turning off + blank-mode in some buffers (like *info* buffers). Reported by Juanma + Barranquero . Eliminate `-face' suffix of all + blank-mode faces. Doc fix. New version 8.1. + (blank-turn-on, blank-turn-off): Replace (and CONDITION BODY) by (when + CONDITION BODY). + (blank-space-face): Face/option name replaced by blank-space. + (blank-hspace-face): Face/option name replaced by blank-hspace. + (blank-tab-face): Face/option name replaced by blank-tab. + (blank-newline-face): Face/option name replaced by blank-newline. + (blank-trailing-face): Face/option name replaced by blank-trailing. + (blank-line-face): Face/option name replaced by blank-line. + (blank-space-before-tab-face): Face/option name replaced by + blank-space-before-tab. + (blank-color-on, blank-color-off, blank-display-char-on): Fix code. + + * blank-mode.el: Install all patches done by Juanma Barranquero + in emacs-22 branch. + (blank-style, blank-chars, blank-hspace-regexp) + (blank-space-regexp, blank-tab-regexp, blank-trailing-regexp) + (blank-space-before-tab-regexp, blank-global-modes, blank-mode) + (global-blank-mode): Doc fixes. + (blank, blank-space-face, blank-hspace-face, blank-tab-face) + (blank-newline-face, blank-trailing-face, blank-line-face) + (blank-space-before-tab-face, blank-display-mappings) + (blank-chars-value-list, blank-style-value-list, blank-toggle-options) + (global-blank-toggle-options, blank-help-text, blank-interactive-char) + (blank-turn-on, blank-turn-off, blank-color-on, blank-color-off): + Fix typos in docstrings. + 2008-01-21 Juanma Barranquero * server.el (server-log-time-function): New function. diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el index 3a57f2e971c..9d36ebde6ae 100644 --- a/lisp/blank-mode.el +++ b/lisp/blank-mode.el @@ -1,4 +1,4 @@ -;;; blank-mode.el --- minor mode to visualise TAB, (HARD) SPACE, NEWLINE +;;; blank-mode.el --- minor mode to visualize TAB, (HARD) SPACE, NEWLINE ;; Copyright (C) 2000, 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 ;; Free Software Foundation, Inc. @@ -6,7 +6,7 @@ ;; Author: Vinicius Jose Latorre ;; Maintainer: Vinicius Jose Latorre ;; Keywords: data, wp -;; Version: 8.0 +;; Version: 8.1 ;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre ;; This file is part of GNU Emacs. @@ -33,10 +33,10 @@ ;; Introduction ;; ------------ ;; -;; This package is a minor mode to visualise blanks (TAB, (HARD) SPACE +;; This package is a minor mode to visualize blanks (TAB, (HARD) SPACE ;; and NEWLINE). ;; -;; blank-mode uses two ways to visualise blanks: faces and display +;; blank-mode uses two ways to visualize blanks: faces and display ;; table. ;; ;; * Faces are used to highlight the background with a color. @@ -47,7 +47,7 @@ ;; of line (?\xB6), at SPACEs (?\xB7) and at TABs (?\xBB). ;; ;; The `blank-style' and `blank-chars' variables are used to select -;; which way should be used to visualise blanks. +;; which way should be used to visualize blanks. ;; ;; Note that when blank-mode is turned on, blank-mode saves the ;; font-lock state, that is, if font-lock is on or off. And @@ -94,7 +94,7 @@ ;; `global-blank-toggle-options'. For example: ;; ;; (autoload 'blank-mode "blank-mode" -;; "Toggle blank visualisation." t) +;; "Toggle blank visualization." t) ;; (autoload 'blank-toggle-options "blank-mode" ;; "Toggle local `blank-mode' options." t) ;; @@ -175,27 +175,27 @@ ;; Below it's shown a brief description of blank-mode options, please, ;; see the options declaration in the code for a long documentation. ;; -;; `blank-style' Specify the visualisation style. +;; `blank-style' Specify the visualization style. ;; ;; `blank-chars' Specify which kind of blank is -;; visualised. +;; visualized. ;; -;; `blank-space-face' Face used to visualise SPACE. +;; `blank-space' Face used to visualize SPACE. ;; -;; `blank-hspace-face' Face used to visualise HARD SPACE. +;; `blank-hspace' Face used to visualize HARD SPACE. ;; -;; `blank-tab-face' Face used to visualise TAB. +;; `blank-tab' Face used to visualize TAB. ;; -;; `blank-newline-face' Face used to visualise NEWLINE char +;; `blank-newline' Face used to visualize NEWLINE char ;; mapping. ;; -;; `blank-trailing-face' Face used to visualise trailing +;; `blank-trailing' Face used to visualize trailing ;; blanks. ;; -;; `blank-line-face' Face used to visualise "long" lines. +;; `blank-line' Face used to visualize "long" lines. ;; -;; `blank-space-before-tab-face' Face used to visualise SPACEs -;; before TAB. +;; `blank-space-before-tab' Face used to visualize SPACEs before +;; TAB. ;; ;; `blank-space-regexp' Specify SPACE characters regexp. ;; @@ -268,7 +268,7 @@ (defgroup blank nil - "Visualise blanks (TAB, (HARD) SPACE and NEWLINE)." + "Visualize blanks (TAB, (HARD) SPACE and NEWLINE)." :link '(emacs-library-link :tag "Source Lisp File" "blank-mode.el") :version "22.2" :group 'wp @@ -276,17 +276,17 @@ (defcustom blank-style '(mark color) - "*Specify the visualisation style. + "*Specify the visualization style. It's a list which element value can be: - mark display mappings are visualised. + mark display mappings are visualized. - color faces are visualised. + color faces are visualized. Any other value is ignored. -If it's nil, don't visualise TABs, (HARD) SPACEs and NEWLINEs. +If nil, don't visualize TABs, (HARD) SPACEs and NEWLINEs. See also `blank-display-mappings' for documentation." :type '(repeat :tag "Style of Blank" @@ -298,26 +298,26 @@ See also `blank-display-mappings' for documentation." (defcustom blank-chars '(tabs spaces trailing lines space-before-tab newline) - "*Specify which kind of blank is visualised. + "*Specify which kind of blank is visualized. It's a list which element value can be: - trailing trailing blanks are visualised. + trailing trailing blanks are visualized. - tabs TABs are visualised. + tabs TABs are visualized. - spaces SPACEs and HARD SPACEs are visualised. + spaces SPACEs and HARD SPACEs are visualized. lines lines whose length is greater than `blank-line-length' are highlighted. - space-before-tab SPACEs before TAB are visualised. + space-before-tab SPACEs before TAB are visualized. - newline NEWLINEs are visualised. + newline NEWLINEs are visualized. -Any other element value is ignored. +Any other value is ignored. -If it's nil, don't visualise TABs, (HARD) SPACEs and NEWLINEs. +If nil, don't visualize TABs, (HARD) SPACEs and NEWLINEs. Used when `blank-style' has `color' as an element. If `blank-chars' has `newline' as an element, used when `blank-style' @@ -335,62 +335,62 @@ has `mark' as an element." :group 'blank) -(defcustom blank-space-face 'blank-space-face - "*Symbol face used to visualise SPACE. +(defcustom blank-space 'blank-space + "*Symbol face used to visualize SPACE. Used when `blank-style' has `color' as an element." :type 'face :group 'blank) -(defface blank-space-face +(defface blank-space '((((class color) (background dark)) (:background "grey20" :foreground "aquamarine3")) (((class color) (background light)) (:background "LightYellow" :foreground "aquamarine3")) (t (:inverse-video t))) - "Face used to visualise SPACE." + "Face used to visualize SPACE." :group 'blank) -(defcustom blank-hspace-face 'blank-hspace-face - "*Symbol face used to visualise HARD SPACE. +(defcustom blank-hspace 'blank-hspace + "*Symbol face used to visualize HARD SPACE. Used when `blank-style' has `color' as an element." :type 'face :group 'blank) -(defface blank-hspace-face ; 'nobreak-space +(defface blank-hspace ; 'nobreak-space '((((class color) (background dark)) (:background "grey24" :foreground "aquamarine3")) (((class color) (background light)) (:background "LemonChiffon3" :foreground "aquamarine3")) (t (:inverse-video t))) - "Face used to visualise HARD SPACE." + "Face used to visualize HARD SPACE." :group 'blank) -(defcustom blank-tab-face 'blank-tab-face - "*Symbol face used to visualise TAB. +(defcustom blank-tab 'blank-tab + "*Symbol face used to visualize TAB. Used when `blank-style' has `color' as an element." :type 'face :group 'blank) -(defface blank-tab-face +(defface blank-tab '((((class color) (background dark)) (:background "grey22" :foreground "aquamarine3")) (((class color) (background light)) (:background "beige" :foreground "aquamarine3")) (t (:inverse-video t))) - "Face used to visualise TAB." + "Face used to visualize TAB." :group 'blank) -(defcustom blank-newline-face 'blank-newline-face - "*Symbol face used to visualise NEWLINE char mapping. +(defcustom blank-newline 'blank-newline + "*Symbol face used to visualize NEWLINE char mapping. See `blank-display-mappings'. @@ -400,64 +400,64 @@ and `blank-chars' has `newline' as an element." :group 'blank) -(defface blank-newline-face +(defface blank-newline '((((class color) (background dark)) (:background "grey26" :foreground "aquamarine3" :bold t)) (((class color) (background light)) (:background "linen" :foreground "aquamarine3" :bold t)) (t (:bold t :underline t))) - "Face used to visualise NEWLINE char mapping. + "Face used to visualize NEWLINE char mapping. See `blank-display-mappings'." :group 'blank) -(defcustom blank-trailing-face 'blank-trailing-face - "*Symbol face used to visualise traling blanks. +(defcustom blank-trailing 'blank-trailing + "*Symbol face used to visualize traling blanks. Used when `blank-style' has `color' as an element." :type 'face :group 'blank) -(defface blank-trailing-face ; 'trailing-whitespace +(defface blank-trailing ; 'trailing-whitespace '((((class mono)) (:inverse-video t :bold t :underline t)) (t (:background "red1" :foreground "yellow" :bold t))) - "Face used to visualise trailing blanks." + "Face used to visualize trailing blanks." :group 'blank) -(defcustom blank-line-face 'blank-line-face - "*Symbol face used to visualise \"long\" lines. +(defcustom blank-line 'blank-line + "*Symbol face used to visualize \"long\" lines. -See `blank-line-legnth'. +See `blank-line-length'. Used when `blank-style' has `color' as an element." :type 'face :group 'blank) -(defface blank-line-face +(defface blank-line '((((class mono)) (:inverse-video t :bold t :underline t)) (t (:background "gray20" :foreground "violet"))) - "Face used to visualise \"long\" lines. + "Face used to visualize \"long\" lines. See `blank-line-length'." :group 'blank) -(defcustom blank-space-before-tab-face 'blank-space-before-tab-face - "*Symbol face used to visualise SPACEs before TAB. +(defcustom blank-space-before-tab 'blank-space-before-tab + "*Symbol face used to visualize SPACEs before TAB. Used when `blank-style' has `color' as an element." :type 'face :group 'blank) -(defface blank-space-before-tab-face +(defface blank-space-before-tab '((((class mono)) (:inverse-video t :bold t :underline t)) (t (:background "DarkOrange" :foreground "firebrick"))) - "Face used to visualise SPACEs before TAB." + "Face used to visualize SPACEs before TAB." :group 'blank) @@ -469,18 +469,18 @@ If you're using `mule' package, it may exist other characters besides: \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \"\\xF20\" -that it should be considered HARD SPACE. +that should be considered HARD SPACE. Here are some examples: \"\\\\(^\\xA0+\\\\)\" \ -visualise only leading HARD SPACEs. +visualize only leading HARD SPACEs. \"\\\\(\\xA0+$\\\\)\" \ -visualise only trailing HARD SPACEs. +visualize only trailing HARD SPACEs. \"\\\\(^\\xA0+\\\\|\\xA0+$\\\\)\" \ -visualise leading and/or trailing HARD SPACEs. +visualize leading and/or trailing HARD SPACEs. \"\\t\\\\(\\xA0+\\\\)\\t\" \ -visualise only HARD SPACEs between TABs. +visualize only HARD SPACEs between TABs. NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. Use exactly one pair of enclosing \\\\( and \\\\). @@ -495,15 +495,15 @@ Used when `blank-style' has `color' as an element, and "*Specify SPACE characters regexp. If you're using `mule' package, it may exist other characters -besides \" \" that it should be considered SPACE. +besides \" \" that should be considered SPACE. Here are some examples: - \"\\\\(^ +\\\\)\" visualise only leading SPACEs. - \"\\\\( +$\\\\)\" visualise only trailing SPACEs. + \"\\\\(^ +\\\\)\" visualize only leading SPACEs. + \"\\\\( +$\\\\)\" visualize only trailing SPACEs. \"\\\\(^ +\\\\| +$\\\\)\" \ -visualise leading and/or trailing SPACEs. - \"\\t\\\\( +\\\\)\\t\" visualise only SPACEs between TABs. +visualize leading and/or trailing SPACEs. + \"\\t\\\\( +\\\\)\\t\" visualize only SPACEs between TABs. NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. Use exactly one pair of enclosing \\\\( and \\\\). @@ -518,15 +518,15 @@ Used when `blank-style' has `color' as an element, and "*Specify TAB characters regexp. If you're using `mule' package, it may exist other characters -besides \"\\t\" that it should be considered TAB. +besides \"\\t\" that should be considered TAB. Here are some examples: - \"\\\\(^\\t+\\\\)\" visualise only leading TABs. - \"\\\\(\\t+$\\\\)\" visualise only trailing TABs. + \"\\\\(^\\t+\\\\)\" visualize only leading TABs. + \"\\\\(\\t+$\\\\)\" visualize only trailing TABs. \"\\\\(^\\t+\\\\|\\t+$\\\\)\" \ -visualise leading and/or trailing TABs. - \" \\\\(\\t+\\\\) \" visualise only TABs between SPACEs. +visualize leading and/or trailing TABs. + \" \\\\(\\t+\\\\) \" visualize only TABs between SPACEs. NOTE: Enclose always by \\\\( and \\\\) the elements to highlight. Use exactly one pair of enclosing \\\\( and \\\\). @@ -546,9 +546,9 @@ If you're using `mule' package, it may exist other characters besides: \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ \"\\xF20\" -that it should be considered blank. +that should be considered blank. -NOTE: DOES NOT enclose by \\\\( and \\\\) the elements to highlight. +NOTE: DO NOT enclose by \\\\( and \\\\) the elements to highlight. `blank-mode' surrounds this regexp by \"\\\\(\\\\(\" and \"\\\\)+\\\\)$\". @@ -566,7 +566,7 @@ If you're using `mule' package, it may exist other characters besides: \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ \"\\xF20\" -that it should be considered blank. +that should be considered blank. Used when `blank-style' has `color' as an element, and `blank-chars' has `space-before-tab' as an element." @@ -595,7 +595,7 @@ Used when `blank-style' has `color' as an element, and (?\x920 [?\x924] [?_]) ; hard space - currency (?\xE20 [?\xE24] [?_]) ; hard space - currency (?\xF20 [?\xF24] [?_]) ; hard space - currency - ;; NEWLINE is displayed using the face `blank-newline-face' + ;; NEWLINE is displayed using the face `blank-newline' (?\n [?$ ?\n]) ; end-of-line - dollar sign ;; (?\n [?\u21B5 ?\n] [?$ ?\n]) ; end-of-line - downwards arrow ;; (?\n [?\xB6 ?\n] [?$ ?\n]) ; end-of-line - pilcrow @@ -626,9 +626,9 @@ VECTOR is a vector of characters to be displayed in place of CHAR. that character is displayed unmodified. The NEWLINE character is displayed using the face given by -`blank-newline-face' variable. The characters in the vector to be -displayed will not have applied this face if the character code is -above #x1FFFF. +`blank-newline' variable. The characters in the vector to be +displayed will not have this face applied if the character code +is above #x1FFFF. Used when `blank-style' has `mark' as an element." :type '(repeat @@ -650,7 +650,7 @@ Global `blank-mode' is controlled by the command `global-blank-mode'. If nil, means no modes have `blank-mode' automatically turned on. If t, all modes that support `blank-mode' have it automatically turned on. -If a list, it should be a list of `major-mode' symbol names for +Else it should be a list of `major-mode' symbol names for which `blank-mode' should be automatically turned on. The sense of the list is negated if it begins with `not'. For example: @@ -674,11 +674,11 @@ modes only." ;;;###autoload (define-minor-mode blank-mode - "Toggle blank minor mode visualisation (bl on modeline). + "Toggle blank minor mode visualization (\"bl\" on modeline). -If ARG is null, toggle blank visualisation. -If ARG is a number and is greater than zero, turn on -visualisation; otherwise, turn off visualisation. +If ARG is null, toggle blank visualization. +If ARG is a number greater than zero, turn on visualization; +otherwise, turn off visualization. Only useful with a windowing system." :lighter " bl" :init-value nil @@ -698,11 +698,11 @@ Only useful with a windowing system." (define-minor-mode global-blank-mode - "Toggle blank global minor mode visualisation (BL on modeline). + "Toggle blank global minor mode visualization (\"BL\" on modeline). -If ARG is null, toggle blank visualisation. -If ARG is a number and is greater than zero, turn on -visualisation; otherwise, turn off visualisation. +If ARG is null, toggle blank visualization. +If ARG is a number greater than zero, turn on visualization; +otherwise, turn off visualization. Only useful with a windowing system." :lighter " BL" :init-value nil @@ -766,14 +766,14 @@ Only useful with a windowing system." lines newline ) - "List of valid `blank-chars' value.") + "List of valid `blank-chars' values.") (defconst blank-style-value-list '(color mark ) - "List of valid `blank-style' value.") + "List of valid `blank-style' values.") (defconst blank-toggle-option-alist @@ -824,27 +824,27 @@ restart local blank-mode. Interactively, it reads one of the following chars: CHAR MEANING - t toggle TAB visualisation - s toggle SPACE and HARD SPACE visualisation - r toggle trailing blanks visualisation - b toggle SPACEs before TAB visualisation - l toggle \"long lines\" visualisation - n toggle NEWLINE visualisation + t toggle TAB visualization + s toggle SPACE and HARD SPACE visualization + r toggle trailing blanks visualization + b toggle SPACEs before TAB visualization + l toggle \"long lines\" visualization + n toggle NEWLINE visualization c toggle color faces m toggle visual mark x restore `blank-chars' value z restore `blank-style' value ? display brief help -Non-interactively, ARG should be a symbol or a list of symbol. +Non-interactively, ARG should be a symbol or a list of symbols. The valid symbols are: - tabs toggle TAB visualisation - spaces toggle SPACE and HARD SPACE visualisation - trailing toggle trailing blanks visualisation - space-before-tab toggle SPACEs before TAB visualisation - lines toggle \"long lines\" visualisation - newline toggle NEWLINE visualisation + tabs toggle TAB visualization + spaces toggle SPACE and HARD SPACE visualization + trailing toggle trailing blanks visualization + space-before-tab toggle SPACEs before TAB visualization + lines toggle \"long lines\" visualization + newline toggle NEWLINE visualization color toggle color faces mark toggle visual mark blank-chars restore `blank-chars' value @@ -881,27 +881,27 @@ restart global blank-mode. Interactively, it reads one of the following chars: CHAR MEANING - t toggle TAB visualisation - s toggle SPACE and HARD SPACE visualisation - r toggle trailing blanks visualisation - b toggle SPACEs before TAB visualisation - l toggle \"long lines\" visualisation - n toggle NEWLINE visualisation + t toggle TAB visualization + s toggle SPACE and HARD SPACE visualization + r toggle trailing blanks visualization + b toggle SPACEs before TAB visualization + l toggle \"long lines\" visualization + n toggle NEWLINE visualization c toggle color faces m toggle visual mark x restore `blank-chars' value z restore `blank-style' value ? display brief help -Non-interactively, ARG should be a symbol or a list of symbol. +Non-interactively, ARG should be a symbol or a list of symbols. The valid symbols are: - tabs toggle TAB visualisation - spaces toggle SPACE and HARD SPACE visualisation - trailing toggle trailing blanks visualisation - space-before-tab toggle SPACEs before TAB visualisation - lines toggle \"long lines\" visualisation - newline toggle NEWLINE visualisation + tabs toggle TAB visualization + spaces toggle SPACE and HARD SPACE visualization + trailing toggle trailing blanks visualization + space-before-tab toggle SPACEs before TAB visualization + lines toggle \"long lines\" visualization + newline toggle NEWLINE visualization color toggle color faces mark toggle visual mark blank-chars restore `blank-chars' value @@ -942,12 +942,12 @@ Only useful with a windowing system." "\ blank-mode toggle options: - [] t - toggle TAB visualisation - [] s - toggle SPACE and HARD SPACE visualisation - [] r - toggle trailing blanks visualisation - [] b - toggle SPACEs before TAB visualisation - [] l - toggle \"long lines\" visualisation - [] n - toggle NEWLINE visualisation + [] t - toggle TAB visualization + [] s - toggle SPACE and HARD SPACE visualization + [] r - toggle trailing blanks visualization + [] b - toggle SPACEs before TAB visualization + [] l - toggle \"long lines\" visualization + [] n - toggle NEWLINE visualization [] c - toggle color faces [] m - toggle visual mark @@ -1013,12 +1013,12 @@ uses a global context. It reads one of the following chars: CHAR MEANING - t toggle TAB visualisation - s toggle SPACE and HARD SPACE visualisation - r toggle trailing blanks visualisation - b toggle SPACEs before TAB visualisation - l toggle \"long lines\" visualisation - n toggle NEWLINE visualisation + t toggle TAB visualization + s toggle SPACE and HARD SPACE visualization + r toggle trailing blanks visualization + b toggle SPACEs before TAB visualization + l toggle \"long lines\" visualization + n toggle NEWLINE visualization c toggle color faces m toggle visual mark x restore `blank-chars' value @@ -1098,29 +1098,29 @@ options are valid." (defun blank-turn-on () - "Turn on blank visualisation." + "Turn on blank visualization." (setq blank-active-style (if (listp blank-style) blank-style (list blank-style))) (setq blank-active-chars (if (listp blank-chars) blank-chars (list blank-chars))) - (and (memq 'color blank-active-style) - (blank-color-on)) - (and (memq 'mark blank-active-style) - (blank-display-char-on))) + (when (memq 'color blank-active-style) + (blank-color-on)) + (when (memq 'mark blank-active-style) + (blank-display-char-on))) (defun blank-turn-off () - "Turn off blank visualisation." - (and (memq 'color blank-active-style) - (blank-color-off)) - (and (memq 'mark blank-active-style) - (blank-display-char-off))) + "Turn off blank visualization." + (when (memq 'color blank-active-style) + (blank-color-off)) + (when (memq 'mark blank-active-style) + (blank-display-char-off))) (defun blank-color-on () - "Turn on color visualisation." + "Turn on color visualization." (when blank-active-chars (unless blank-font-lock (setq blank-font-lock t @@ -1135,16 +1135,16 @@ options are valid." nil (list ;; Show SPACEs - (list blank-space-regexp 1 blank-space-face t) + (list blank-space-regexp 1 blank-space t) ;; Show HARD SPACEs - (list blank-hspace-regexp 1 blank-hspace-face t)) + (list blank-hspace-regexp 1 blank-hspace t)) t)) (when (memq 'tabs blank-active-chars) (font-lock-add-keywords nil (list ;; Show TABs - (list blank-tab-regexp 1 blank-tab-face t)) + (list blank-tab-regexp 1 blank-tab t)) t)) (when (memq 'trailing blank-active-chars) (font-lock-add-keywords @@ -1152,7 +1152,7 @@ options are valid." (list ;; Show trailing blanks (list (concat "\\(\\(" blank-trailing-regexp "\\)+\\)$") - 1 blank-trailing-face t)) + 1 blank-trailing t)) t)) (when (memq 'lines blank-active-chars) (font-lock-add-keywords @@ -1161,7 +1161,7 @@ options are valid." ;; Show "long" lines (list (concat "^\\(.\\{" (int-to-string blank-line-length) ",\\}\\)$") - 1 blank-line-face t)) + 1 blank-line t)) t)) (when (memq 'space-before-tab blank-active-chars) (font-lock-add-keywords @@ -1169,20 +1169,20 @@ options are valid." (list ;; Show SPACEs before TAB (list blank-space-before-tab-regexp - 1 blank-space-before-tab-face t)) + 1 blank-space-before-tab t)) t)) ;; now turn on font lock and highlight blanks (font-lock-mode 1))) (defun blank-color-off () - "Turn off color visualisation." + "Turn off color visualization." (when blank-active-chars + ;; turn off font lock + (font-lock-mode 0) (when blank-font-lock (setq blank-font-lock nil font-lock-keywords blank-font-lock-keywords)) - ;; turn off font lock - (font-lock-mode 0) ;; restore original font lock state (font-lock-mode blank-font-lock-mode))) @@ -1252,7 +1252,7 @@ options are valid." (or (eq (aref vec i) ?\n) (> (aref vec i) #x1FFFF) (aset vec i (make-glyph-code (aref vec i) - blank-newline-face))))) + blank-newline))))) ;; Display mapping (aset buffer-display-table (car entry) vec)) ;; Newline char - don't display it From b49fd377e88c4e6517342e2b61a6f0db2a0eab83 Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Mon, 21 Jan 2008 14:03:09 +0000 Subject: [PATCH 243/439] (vc-process-sentinel): After calling the previous sentinel, do nothing if the process' buffer is not live. --- lisp/ChangeLog | 5 +++++ lisp/vc.el | 61 ++++++++++++++++++++++++++------------------------ 2 files changed, 37 insertions(+), 29 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7b05fb9c568..b3e010f9b93 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-21 Thien-Thi Nguyen + + * vc.el (vc-process-sentinel): After calling the previous + sentinel, do nothing if the process' buffer is not live. + 2008-01-21 Vinicius Jose Latorre * blank-mode.el: Fix a problem of cleaning blank faces when turning off diff --git a/lisp/vc.el b/lisp/vc.el index 497ba1e0df4..ffe38a68521 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -958,36 +958,39 @@ BUF defaults to \"*vc*\", can be a string and will be created if necessary." (defvar vc-sentinel-movepoint) ;Dynamically scoped. (defun vc-process-sentinel (p s) - (with-current-buffer (process-buffer p) - (setq mode-line-process - (let ((status (process-status p))) - ;; Leave mode-line uncluttered, normally. - ;; (Let known any weirdness in-form-ally. ;-) --ttn - (unless (eq 'exit status) - (format " (%s)" status))))) - (let ((previous (process-get p 'vc-previous-sentinel))) + (let ((previous (process-get p 'vc-previous-sentinel)) + (buf (process-buffer p))) (if previous (funcall previous p s)) - (with-current-buffer (process-buffer p) - (let (vc-sentinel-movepoint) - ;; Normally, we want async code such as sentinels to not move point. - (save-excursion - (goto-char (process-mark p)) - (let ((cmds (process-get p 'vc-sentinel-commands))) - (process-put p 'vc-sentinel-commands nil) - (dolist (cmd cmds) - ;; Each sentinel may move point and the next one should be run - ;; at that new point. We could get the same result by having - ;; each sentinel read&set process-mark, but since `cmd' needs - ;; to work both for async and sync processes, this would be - ;; difficult to achieve. - (vc-exec-after cmd)))) - ;; But sometimes the sentinels really want to move point. - (if vc-sentinel-movepoint - (let ((win (get-buffer-window (current-buffer) 0))) - (if (not win) - (goto-char vc-sentinel-movepoint) - (with-selected-window win - (goto-char vc-sentinel-movepoint))))))))) + ;; Impatient users sometime kill "slow" buffers; check liveness + ;; to avoid "error in process sentinel: Selecting deleted buffer". + (when (buffer-live-p buf) + (with-current-buffer buf + (setq mode-line-process + (let ((status (process-status p))) + ;; Leave mode-line uncluttered, normally. + ;; (Let known any weirdness in-form-ally. ;-) --ttn + (unless (eq 'exit status) + (format " (%s)" status)))) + (let (vc-sentinel-movepoint) + ;; Normally, we want async code such as sentinels to not move point. + (save-excursion + (goto-char (process-mark p)) + (let ((cmds (process-get p 'vc-sentinel-commands))) + (process-put p 'vc-sentinel-commands nil) + (dolist (cmd cmds) + ;; Each sentinel may move point and the next one should be run + ;; at that new point. We could get the same result by having + ;; each sentinel read&set process-mark, but since `cmd' needs + ;; to work both for async and sync processes, this would be + ;; difficult to achieve. + (vc-exec-after cmd)))) + ;; But sometimes the sentinels really want to move point. + (if vc-sentinel-movepoint + (let ((win (get-buffer-window (current-buffer) 0))) + (if (not win) + (goto-char vc-sentinel-movepoint) + (with-selected-window win + (goto-char vc-sentinel-movepoint)))))))))) (defun vc-exec-after (code) "Eval CODE when the current buffer's process is done. From ce4059eea09eec6b083d6546ec8ad177be2c4c4d Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Mon, 21 Jan 2008 17:16:52 +0000 Subject: [PATCH 244/439] (unhandled-file-name-directory): Add handler. (url-handler-unhandled-file-name-directory): New fun. --- lisp/url/ChangeLog | 5 +++++ lisp/url/url-handlers.el | 8 ++++++++ 2 files changed, 13 insertions(+) diff --git a/lisp/url/ChangeLog b/lisp/url/ChangeLog index 040a6a46d81..723fb986b0d 100644 --- a/lisp/url/ChangeLog +++ b/lisp/url/ChangeLog @@ -1,3 +1,8 @@ +2008-01-21 Stefan Monnier + + * url-handlers.el (unhandled-file-name-directory): Add handler. + (url-handler-unhandled-file-name-directory): New fun. + 2008-01-07 Michael Albinus * url-handlers.el (url-file-handler): Autoload. diff --git a/lisp/url/url-handlers.el b/lisp/url/url-handlers.el index 8dd9792f467..92658051df4 100644 --- a/lisp/url/url-handlers.el +++ b/lisp/url/url-handlers.el @@ -153,6 +153,7 @@ the arguments that would have been passed to OPERATION." (put 'file-name-absolute-p 'url-file-handlers (lambda (&rest ignored) t)) (put 'expand-file-name 'url-file-handlers 'url-handler-expand-file-name) (put 'directory-file-name 'url-file-handlers 'url-handler-directory-file-name) +(put 'unhandled-file-name-directory 'url-file-handlers 'url-handler-unhandled-file-name-directory) ;; (put 'file-name-as-directory 'url-file-handlers 'url-handler-file-name-as-directory) ;; These are operations that we do not support yet (DAV!!!) @@ -184,6 +185,13 @@ the arguments that would have been passed to OPERATION." (if (string-match "//\\'" dir) dir (url-run-real-handler 'directory-file-name (list dir)))) +(defun url-handler-unhandled-file-name-directory (filename) + ;; Copied from tramp.el. This is used as the cwd for subprocesses: + ;; without it running call-process or start-process in a URL directory + ;; signals an error. + ;; FIXME: we can do better if `filename' is a "file://" URL. + (expand-file-name "~/")) + ;; The actual implementation ;;;###autoload (defun url-copy-file (url newname &optional ok-if-already-exists keep-time) From d405bc15fc6e676f2c6af2afd06cf7c730f0f82d Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Mon, 21 Jan 2008 19:48:56 +0000 Subject: [PATCH 245/439] (outline-up-heading): Fix check for top level to avoid infinite looping in hide-other. --- lisp/ChangeLog | 5 +++++ lisp/outline.el | 4 ++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b3e010f9b93..91ea02a2dbb 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-21 Martin Rudalics + + * outline.el (outline-up-heading): Fix check for top level to + avoid infinite looping in hide-other. + 2008-01-21 Thien-Thi Nguyen * vc.el (vc-process-sentinel): After calling the previous diff --git a/lisp/outline.el b/lisp/outline.el index f075a474810..40340e10f42 100644 --- a/lisp/outline.el +++ b/lisp/outline.el @@ -971,8 +971,8 @@ If INVISIBLE-OK is non-nil, also consider invisible lines." (or (eq last-command 'outline-up-heading) (push-mark))) (outline-back-to-heading invisible-ok) (let ((start-level (funcall outline-level))) - (if (eq start-level 1) - (error "Already at top level of the outline")) + (when (<= start-level 1) + (error "Already at top level of the outline")) (while (and (> start-level 1) (> arg 0) (not (bobp))) (let ((level start-level)) (while (not (or (< level start-level) (bobp))) From d2e4a6c90428e7bce7ee7d71e2cc5b2ee0ee40d9 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Mon, 21 Jan 2008 20:01:19 +0000 Subject: [PATCH 246/439] * dbus.texi (Errors and Events): New macro dbus-ignore-errors. --- doc/misc/ChangeLog | 4 ++++ doc/misc/dbus.texi | 12 +++++++++--- 2 files changed, 13 insertions(+), 3 deletions(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index a69f32a976e..47e521f537c 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,7 @@ +2008-01-21 Michael Albinus + + * dbus.texi (Errors and Events): New macro dbus-ignore-errors. + 2008-01-18 Katsumi Yamaoka * gnus-news.texi: Mention gnus-article-describe-bindings. diff --git a/doc/misc/dbus.texi b/doc/misc/dbus.texi index 506716e8d92..27550337b39 100644 --- a/doc/misc/dbus.texi +++ b/doc/misc/dbus.texi @@ -674,9 +674,15 @@ there is a type mismatch, the Lisp error @code{wrong-type-argument} @code{D-Bus ARG} is raised. All errors raised by D-Bus are signaled with the error symbol -@code{dbus-error}. As usual, such an error can be trapped with a -@code{condition-case} form. If possible, error messages from D-Bus -are appended to the @code{dbus-error}. +@code{dbus-error}. If possible, error messages from D-Bus are +appended to the @code{dbus-error}. + +@defspec dbus-ignore-errors forms@dots{} +This executes @var{forms} exactly like a @code{progn}, except that +@code{dbus-error} errors are ignored during the @var{forms}. These +errors can be made visible when variable @code{dbus-debug} is set to +@code{t}. +@end defspec Incoming D-Bus messages are handled as Emacs events (see @pxref{Misc Events, , , elisp}). The generated event has this form: From 246a286b9b7ddfe6854cb06112f7a91b13626aa9 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Mon, 21 Jan 2008 20:06:15 +0000 Subject: [PATCH 247/439] * net/dbus.el (dbus-ignore-errors): New macro. (dbus-unregister-object): New defun. Moved from dbusbind.c. (dbus-handle-event, dbus-list-activatable-names, dbus-list-names) (dbus-list-queued-owners, dbus-get-name-owner, dbus-introspect) (dbus-get-signatures): Apply `dbus-ignore-errors'. --- lisp/net/dbus.el | 185 +++++++++++++++++++++++++++-------------------- 1 file changed, 107 insertions(+), 78 deletions(-) diff --git a/lisp/net/dbus.el b/lisp/net/dbus.el index 83075762b73..ef84db1ccf7 100644 --- a/lisp/net/dbus.el +++ b/lisp/net/dbus.el @@ -46,6 +46,17 @@ (defconst dbus-interface-introspectable "org.freedesktop.DBus.Introspectable" "The interface supported by introspectable objects.") +(defmacro dbus-ignore-errors (&rest body) + "Execute BODY; signal D-Bus error when `dbus-debug' is non-nil. +Otherwise, return result of last form in BODY, or all other errors." + `(condition-case err + (progn ,@body) + (dbus-error (when dbus-debug (signal (car err) (cdr err)))))) + +(put 'dbus-ignore-errors 'lisp-indent-function 0) +(put 'dbus-ignore-errors 'edebug-form-spec '(form symbolp body)) +(font-lock-add-keywords 'emacs-lisp-mode '("\\")) + ;;; Hash table of registered functions. @@ -64,6 +75,35 @@ hash table." dbus-registered-functions-table) result)) +(defun dbus-unregister-object (object) + "Unregister OBJECT from D-Bus. +OBJECT must be the result of a preceding `dbus-register-method' +or `dbus-register-signal' call. It returns t if OBJECT has been +unregistered, nil otherwise." + ;; Check parameter. + (unless (and (consp object) (not (null (car object))) (consp (cdr object))) + (signal 'wrong-type-argument (list 'D-Bus object))) + + ;; Find the corresponding entry in the hash table. + (let* ((key (car object)) + (value (gethash key dbus-registered-functions-table))) + ;; Loop over the registered functions. + (while (consp value) + ;; (car value) has the structure (UNAME SERVICE PATH HANDLER). + ;; (cdr object) has the structure ((SERVICE PATH HANDLER) ...). + (if (not (equal (cdr (car value)) (car (cdr object)))) + (setq value (cdr value)) + ;; Compute new hash value. If it is empty, remove it from + ;; hash table. + (unless + (puthash + key + (delete (car value) (gethash key dbus-registered-functions-table)) + dbus-registered-functions-table) + (remhash key dbus-registered-functions-table)) + (setq value t))) + value)) + (defun dbus-name-owner-changed-handler (&rest args) "Reapplies all member registrations to D-Bus. This handler is applied when a \"NameOwnerChanged\" signal has @@ -110,15 +150,13 @@ usage: (dbus-name-owner-changed-handler service old-owner new-owner)" args)))))) ;; Register the handler. -(condition-case nil - (progn - (dbus-register-signal - :system dbus-service-dbus dbus-path-dbus dbus-interface-dbus - "NameOwnerChanged" 'dbus-name-owner-changed-handler) - (dbus-register-signal - :session dbus-service-dbus dbus-path-dbus dbus-interface-dbus - "NameOwnerChanged" 'dbus-name-owner-changed-handler)) - (dbus-error)) +(dbus-ignore-errors + (dbus-register-signal + :system dbus-service-dbus dbus-path-dbus dbus-interface-dbus + "NameOwnerChanged" 'dbus-name-owner-changed-handler) + (dbus-register-signal + :session dbus-service-dbus dbus-path-dbus dbus-interface-dbus + "NameOwnerChanged" 'dbus-name-owner-changed-handler)) ;;; D-Bus events. @@ -168,16 +206,15 @@ part of the event, is called with arguments ARGS." (interactive "e") ;; We don't want to raise an error, because this function is called ;; in the event handling loop. - (condition-case err - (let (result) - (dbus-check-event event) - (setq result (apply (nth 7 event) (nthcdr 8 event))) - (unless (consp result) (setq result (cons result nil))) - ;; Return a message when serial is not nil. - (when (not (null (nth 2 event))) - (apply 'dbus-method-return - (nth 1 event) (nth 2 event) (nth 3 event) result))) - (dbus-error (when dbus-debug (signal (car err) (cdr err)))))) + (dbus-ignore-errors + (let (result) + (dbus-check-event event) + (setq result (apply (nth 7 event) (nthcdr 8 event))) + (unless (consp result) (setq result (cons result nil))) + ;; Return a message when serial is not nil. + (when (not (null (nth 2 event))) + (apply 'dbus-method-return-internal + (nth 1 event) (nth 2 event) (nth 3 event) result))))) (defun dbus-event-bus-name (event) "Return the bus name the event is coming from. @@ -238,11 +275,10 @@ well formed." "Return the D-Bus service names which can be activated as list. The result is a list of strings, which is nil when there are no activatable service names at all." - (condition-case nil - (dbus-call-method - :system dbus-service-dbus - dbus-path-dbus dbus-interface-dbus "ListActivatableNames") - (dbus-error))) + (dbus-ignore-errors + (dbus-call-method + :system dbus-service-dbus + dbus-path-dbus dbus-interface-dbus "ListActivatableNames"))) (defun dbus-list-names (bus) "Return the service names registered at D-Bus BUS. @@ -250,10 +286,9 @@ The result is a list of strings, which is nil when there are no registered service names at all. Well known names are strings like \"org.freedesktop.DBus\". Names starting with \":\" are unique names for services." - (condition-case nil - (dbus-call-method - bus dbus-service-dbus dbus-path-dbus dbus-interface-dbus "ListNames") - (dbus-error))) + (dbus-ignore-errors + (dbus-call-method + bus dbus-service-dbus dbus-path-dbus dbus-interface-dbus "ListNames"))) (defun dbus-list-known-names (bus) "Retrieve all services which correspond to a known name in BUS. @@ -267,20 +302,18 @@ A service has a known name if it doesn't start with \":\"." "Return the unique names registered at D-Bus BUS and queued for SERVICE. The result is a list of strings, or nil when there are no queued name owners service names at all." - (condition-case nil - (dbus-call-method - bus dbus-service-dbus dbus-path-dbus - dbus-interface-dbus "ListQueuedOwners" service) - (dbus-error))) + (dbus-ignore-errors + (dbus-call-method + bus dbus-service-dbus dbus-path-dbus + dbus-interface-dbus "ListQueuedOwners" service))) (defun dbus-get-name-owner (bus service) "Return the name owner of SERVICE registered at D-Bus BUS. The result is either a string, or nil if there is no name owner." - (condition-case nil - (dbus-call-method - bus dbus-service-dbus dbus-path-dbus - dbus-interface-dbus "GetNameOwner" service) - (dbus-error))) + (dbus-ignore-errors + (dbus-call-method + bus dbus-service-dbus dbus-path-dbus + dbus-interface-dbus "GetNameOwner" service))) (defun dbus-introspect (bus service path) "Return the introspection data of SERVICE in D-Bus BUS at object path PATH. @@ -291,10 +324,9 @@ Example: \(dbus-introspect :system \"org.freedesktop.Hal\" \"/org/freedesktop/Hal/devices/computer\")" - (condition-case nil - (dbus-call-method - bus service path dbus-interface-introspectable "Introspect") - (dbus-error))) + (dbus-ignore-errors + (dbus-call-method + bus service path dbus-interface-introspectable "Introspect"))) (if nil ;; Must be reworked. Shall we offer D-Bus signatures at all? (defun dbus-get-signatures (bus interface signal) @@ -310,42 +342,39 @@ the third parameter is of type array of integer. If INTERFACE or SIGNAL do not exist, or if they do not support the D-Bus method org.freedesktop.DBus.Introspectable.Introspect, the function returns nil." - (condition-case nil - (let ((introspect-xml - (with-temp-buffer - (insert (dbus-introspect bus interface)) - (xml-parse-region (point-min) (point-max)))) - node interfaces signals args result) - ;; Get the root node. - (setq node (xml-node-name introspect-xml)) - ;; Get all interfaces. - (setq interfaces (xml-get-children node 'interface)) - (while interfaces - (when (string-equal (xml-get-attribute (car interfaces) 'name) - interface) - ;; That's the requested interface. Check for signals. - (setq signals (xml-get-children (car interfaces) 'signal)) - (while signals - (when (string-equal (xml-get-attribute (car signals) 'name) - signal) - ;; The signal we are looking for. - (setq args (xml-get-children (car signals) 'arg)) - (while args - (unless (xml-get-attribute (car args) 'type) - ;; This shouldn't happen, let's escape. - (signal 'dbus-error "")) - ;; We append the signature. - (setq - result (append result - (list (xml-get-attribute (car args) 'type)))) - (setq args (cdr args))) - (setq signals nil)) - (setq signals (cdr signals))) - (setq interfaces nil)) - (setq interfaces (cdr interfaces))) - result) - ;; We ignore `dbus-error'. There might be no introspectable interface. - (dbus-error nil))) + (dbus-ignore-errors + (let ((introspect-xml + (with-temp-buffer + (insert (dbus-introspect bus interface)) + (xml-parse-region (point-min) (point-max)))) + node interfaces signals args result) + ;; Get the root node. + (setq node (xml-node-name introspect-xml)) + ;; Get all interfaces. + (setq interfaces (xml-get-children node 'interface)) + (while interfaces + (when (string-equal (xml-get-attribute (car interfaces) 'name) + interface) + ;; That's the requested interface. Check for signals. + (setq signals (xml-get-children (car interfaces) 'signal)) + (while signals + (when (string-equal (xml-get-attribute (car signals) 'name) signal) + ;; The signal we are looking for. + (setq args (xml-get-children (car signals) 'arg)) + (while args + (unless (xml-get-attribute (car args) 'type) + ;; This shouldn't happen, let's escape. + (signal 'dbus-error nil)) + ;; We append the signature. + (setq + result (append result + (list (xml-get-attribute (car args) 'type)))) + (setq args (cdr args))) + (setq signals nil)) + (setq signals (cdr signals))) + (setq interfaces nil)) + (setq interfaces (cdr interfaces))) + result))) ) ;; (if nil ... (provide 'dbus) From 22b04708edb530bf64b7f0d88488cc0d067e2c98 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Mon, 21 Jan 2008 20:11:58 +0000 Subject: [PATCH 248/439] * net/dbus.el (dbus-ignore-errors): New macro. (dbus-unregister-object): New defun. Moved from dbusbind.c. (dbus-handle-event, dbus-list-activatable-names, dbus-list-names) (dbus-list-queued-owners, dbus-get-name-owner, dbus-introspect) (dbus-get-signatures): Apply `dbus-ignore-errors'. --- lisp/ChangeLog | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 91ea02a2dbb..acf92d5eb48 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2008-01-21 Michael Albinus + + * net/dbus.el (dbus-ignore-errors): New macro. + (dbus-unregister-object): New defun. Moved from dbusbind.c. + (dbus-handle-event, dbus-list-activatable-names, dbus-list-names) + (dbus-list-queued-owners, dbus-get-name-owner, dbus-introspect) + (dbus-get-signatures): Apply `dbus-ignore-errors'. + 2008-01-21 Martin Rudalics * outline.el (outline-up-heading): Fix check for top level to From 8c7a4ac525e888da28f53a984c555e077e51935e Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Mon, 21 Jan 2008 20:19:16 +0000 Subject: [PATCH 249/439] * dbusbind.el (Fdbus_method_return_internal): Renamed from Fdbus_method_return. (Fdbus_unregister_object): Moved to dbus.el. (Fdbus_call_method, Fdbus_method_return_internal) (Fdbus_send_signal): Debug messages improved. --- src/ChangeLog | 8 +++ src/dbusbind.c | 134 +++++++++++++++++++------------------------------ 2 files changed, 61 insertions(+), 81 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 73a1164915e..0a798a670a0 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,11 @@ +2008-01-21 Michael Albinus + + * dbusbind.el (Fdbus_method_return_internal): Renamed from + Fdbus_method_return. + (Fdbus_unregister_object): Moved to dbus.el. + (Fdbus_call_method, Fdbus_method_return_internal) + (Fdbus_send_signal): Debug messages improved. + 2008-01-20 Martin Rudalics * undo.c (undo_inhibit_record_point): New variable. diff --git a/src/dbusbind.c b/src/dbusbind.c index 136cea9adb4..badcf1f14d7 100644 --- a/src/dbusbind.c +++ b/src/dbusbind.c @@ -33,11 +33,10 @@ Boston, MA 02110-1301, USA. */ /* Subroutines. */ Lisp_Object Qdbus_get_unique_name; Lisp_Object Qdbus_call_method; -Lisp_Object Qdbus_method_return; +Lisp_Object Qdbus_method_return_internal; Lisp_Object Qdbus_send_signal; Lisp_Object Qdbus_register_signal; Lisp_Object Qdbus_register_method; -Lisp_Object Qdbus_unregister_object; /* D-Bus error symbol. */ Lisp_Object Qdbus_error; @@ -833,14 +832,22 @@ usage: (dbus-call-method BUS SERVICE PATH INTERFACE METHOD &rest ARGS) */) /* Append parameters to the message. */ for (i = 5; i < nargs; ++i) { - - XD_DEBUG_VALID_LISP_OBJECT_P (args[i]); - XD_DEBUG_MESSAGE ("Parameter%d %s", - i-4, SDATA (format2 ("%s", args[i], Qnil))); - dtype = XD_OBJECT_TO_DBUS_TYPE (args[i]); if (XD_DBUS_TYPE_P (args[i])) - ++i; + { + XD_DEBUG_VALID_LISP_OBJECT_P (args[i]); + XD_DEBUG_VALID_LISP_OBJECT_P (args[i+1]); + XD_DEBUG_MESSAGE ("Parameter%d %s %s", i-4, + SDATA (format2 ("%s", args[i], Qnil)), + SDATA (format2 ("%s", args[i+1], Qnil))); + ++i; + } + else + { + XD_DEBUG_VALID_LISP_OBJECT_P (args[i]); + XD_DEBUG_MESSAGE ("Parameter%d %s", i-4, + SDATA (format2 ("%s", args[i], Qnil))); + } /* Check for valid signature. We use DBUS_TYPE_INVALID as indication that there is no parent type. */ @@ -872,7 +879,8 @@ usage: (dbus-call-method BUS SERVICE PATH INTERFACE METHOD &rest ARGS) */) { /* Loop over the parameters of the D-Bus reply message. Construct a Lisp list, which is returned by `dbus-call-method'. */ - while ((dtype = dbus_message_iter_get_arg_type (&iter)) != DBUS_TYPE_INVALID) + while ((dtype = dbus_message_iter_get_arg_type (&iter)) + != DBUS_TYPE_INVALID) { result = Fcons (xd_retrieve_arg (dtype, &iter), result); dbus_message_iter_next (&iter); @@ -880,7 +888,7 @@ usage: (dbus-call-method BUS SERVICE PATH INTERFACE METHOD &rest ARGS) */) } else { - /* No arguments: just return nil. */ + /* No arguments: just return nil. */ } /* Cleanup. */ @@ -895,12 +903,13 @@ usage: (dbus-call-method BUS SERVICE PATH INTERFACE METHOD &rest ARGS) */) RETURN_UNGCPRO (Fnreverse (result)); } -DEFUN ("dbus-method-return", Fdbus_method_return, Sdbus_method_return, +DEFUN ("dbus-method-return-internal", Fdbus_method_return_internal, + Sdbus_method_return_internal, 3, MANY, 0, - doc: /* Return to method SERIAL on the D-Bus BUS. + doc: /* Return for message SERIAL on the D-Bus BUS. This is an internal function, it shall not be used outside dbus.el. -usage: (dbus-method-return BUS SERIAL SERVICE &rest ARGS) */) +usage: (dbus-method-return-internal BUS SERIAL SERVICE &rest ARGS) */) (nargs, args) int nargs; register Lisp_Object *args; @@ -948,14 +957,22 @@ usage: (dbus-method-return BUS SERIAL SERVICE &rest ARGS) */) /* Append parameters to the message. */ for (i = 3; i < nargs; ++i) { - - XD_DEBUG_VALID_LISP_OBJECT_P (args[i]); - XD_DEBUG_MESSAGE ("Parameter%d %s", - i-2, SDATA (format2 ("%s", args[i], Qnil))); - dtype = XD_OBJECT_TO_DBUS_TYPE (args[i]); if (XD_DBUS_TYPE_P (args[i])) - ++i; + { + XD_DEBUG_VALID_LISP_OBJECT_P (args[i]); + XD_DEBUG_VALID_LISP_OBJECT_P (args[i+1]); + XD_DEBUG_MESSAGE ("Parameter%d %s %s", i-2, + SDATA (format2 ("%s", args[i], Qnil)), + SDATA (format2 ("%s", args[i+1], Qnil))); + ++i; + } + else + { + XD_DEBUG_VALID_LISP_OBJECT_P (args[i]); + XD_DEBUG_MESSAGE ("Parameter%d %s", i-2, + SDATA (format2 ("%s", args[i], Qnil))); + } /* Check for valid signature. We use DBUS_TYPE_INVALID as indication that there is no parent type. */ @@ -1064,13 +1081,22 @@ usage: (dbus-send-signal BUS SERVICE PATH INTERFACE SIGNAL &rest ARGS) */) /* Append parameters to the message. */ for (i = 5; i < nargs; ++i) { - XD_DEBUG_VALID_LISP_OBJECT_P (args[i]); - XD_DEBUG_MESSAGE ("Parameter%d %s", - i-4, SDATA (format2 ("%s", args[i], Qnil))); - dtype = XD_OBJECT_TO_DBUS_TYPE (args[i]); if (XD_DBUS_TYPE_P (args[i])) - ++i; + { + XD_DEBUG_VALID_LISP_OBJECT_P (args[i]); + XD_DEBUG_VALID_LISP_OBJECT_P (args[i+1]); + XD_DEBUG_MESSAGE ("Parameter%d %s %s", i-4, + SDATA (format2 ("%s", args[i], Qnil)), + SDATA (format2 ("%s", args[i+1], Qnil))); + ++i; + } + else + { + XD_DEBUG_VALID_LISP_OBJECT_P (args[i]); + XD_DEBUG_MESSAGE ("Parameter%d %s", i-4, + SDATA (format2 ("%s", args[i], Qnil))); + } /* Check for valid signature. We use DBUS_TYPE_INVALID as indication that there is no parent type. */ @@ -1392,56 +1418,6 @@ used for composing the returning D-Bus message. */) return list2 (key, list3 (service, path, handler)); } -DEFUN ("dbus-unregister-object", Fdbus_unregister_object, - Sdbus_unregister_object, - 1, 1, 0, - doc: /* Unregister OBJECT from the D-Bus. -OBJECT must be the result of a preceding `dbus-register-signal' or -`dbus-register-method' call. It returns t if OBJECT has been -unregistered, nil otherwise. */) - (object) - Lisp_Object object; -{ - Lisp_Object value; - struct gcpro gcpro1; - - /* Check parameter. */ - if (!(CONSP (object) && (!NILP (CAR_SAFE (object))) - && CONSP (CDR_SAFE (object)))) - wrong_type_argument (intern ("D-Bus"), object); - - /* Find the corresponding entry in the hash table. */ - value = Fgethash (CAR_SAFE (object), Vdbus_registered_functions_table, Qnil); - - /* Loop over the registered functions. */ - while (!NILP (value)) - { - GCPRO1 (value); - - /* (car value) has the structure (UNAME SERVICE PATH HANDLER). - (cdr object) has the structure ((SERVICE PATH HANDLER) ...). */ - if (!NILP (Fequal (CDR_SAFE (CAR_SAFE (value)), - CAR_SAFE (CDR_SAFE (object))))) - { - /* Compute new hash value. */ - value = Fdelete (CAR_SAFE (value), - Fgethash (CAR_SAFE (object), - Vdbus_registered_functions_table, Qnil)); - if (NILP (value)) - Fremhash (CAR_SAFE (object), Vdbus_registered_functions_table); - else - Fputhash (CAR_SAFE (object), value, - Vdbus_registered_functions_table); - RETURN_UNGCPRO (Qt); - } - UNGCPRO; - value = CDR_SAFE (value); - } - - /* Return. */ - return Qnil; -} - void syms_of_dbusbind () @@ -1455,9 +1431,9 @@ syms_of_dbusbind () staticpro (&Qdbus_call_method); defsubr (&Sdbus_call_method); - Qdbus_method_return = intern ("dbus-method-return"); - staticpro (&Qdbus_method_return); - defsubr (&Sdbus_method_return); + Qdbus_method_return_internal = intern ("dbus-method-return-internal"); + staticpro (&Qdbus_method_return_internal); + defsubr (&Sdbus_method_return_internal); Qdbus_send_signal = intern ("dbus-send-signal"); staticpro (&Qdbus_send_signal); @@ -1471,10 +1447,6 @@ syms_of_dbusbind () staticpro (&Qdbus_register_method); defsubr (&Sdbus_register_method); - Qdbus_unregister_object = intern ("dbus-unregister-object"); - staticpro (&Qdbus_unregister_object); - defsubr (&Sdbus_unregister_object); - Qdbus_error = intern ("dbus-error"); staticpro (&Qdbus_error); Fput (Qdbus_error, Qerror_conditions, From 460dadc9a8897506e788d1ea61e018c7090b5844 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Mon, 21 Jan 2008 22:21:28 +0000 Subject: [PATCH 250/439] Fix ChangeLog entry. --- lisp/ChangeLog | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index acf92d5eb48..35cf2d449c4 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -34,9 +34,9 @@ blank-space-before-tab. (blank-color-on, blank-color-off, blank-display-char-on): Fix code. - * blank-mode.el: Install all patches done by Juanma Barranquero - in emacs-22 branch. - (blank-style, blank-chars, blank-hspace-regexp) +2008-01-21 Juanma Barranquero + + * blank-mode.el (blank-style, blank-chars, blank-hspace-regexp) (blank-space-regexp, blank-tab-regexp, blank-trailing-regexp) (blank-space-before-tab-regexp, blank-global-modes, blank-mode) (global-blank-mode): Doc fixes. From eb9d158f69e56b4bf23db1f627c6cc1c53953634 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Mon, 21 Jan 2008 22:32:44 +0000 Subject: [PATCH 251/439] (Exiting): Fix typo. Reported by D. E. Evans . --- man/ChangeLog | 7 ++++++- man/entering.texi | 2 +- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/man/ChangeLog b/man/ChangeLog index c8dd0cf1fda..444ca5c004f 100644 --- a/man/ChangeLog +++ b/man/ChangeLog @@ -1,3 +1,8 @@ +2008-01-21 Juanma Barranquero + + * entering.texi (Exiting): Fix typo. + Reported by D. E. Evans . + 2007-12-18 Reiner Steib * gnus.texi (Group Parameters): Reorder the text and add a note about @@ -21,7 +26,7 @@ * search.texi (Query Replace): Make exp of query-replace more self-contained, and clarify. - + * cc-mode.texi (Getting Started): Change @ref to @pxref. 2007-12-14 Sven Joachim diff --git a/man/entering.texi b/man/entering.texi index 3c79a69c084..8a29fd632cf 100644 --- a/man/entering.texi +++ b/man/entering.texi @@ -122,7 +122,7 @@ systems, you can only get back to the shell from which Emacs was run @vindex cannot-suspend Suspending can fail if you run Emacs under a shell that doesn't -support suspendion of its subjobs, even if the system itself does +support suspension of its subjobs, even if the system itself does support it. In such a case, you can set the variable @code{cannot-suspend} to a non-@code{nil} value to force @kbd{C-z} to start an inferior shell. From 650276d5e69dbc6b1e0ca9ac7ff7f06f12c644e7 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Mon, 21 Jan 2008 22:48:51 +0000 Subject: [PATCH 252/439] *** empty log message *** --- doc/emacs/ChangeLog | 5 +++++ doc/emacs/entering.texi | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/doc/emacs/ChangeLog b/doc/emacs/ChangeLog index 282ca6f1d52..fd1ace2e69d 100644 --- a/doc/emacs/ChangeLog +++ b/doc/emacs/ChangeLog @@ -1,3 +1,8 @@ +2008-01-21 Juanma Barranquero + + * entering.texi (Exiting): Fix typo. + Reported by D. E. Evans . + 2007-12-31 Martin Rudalics * glossary.texi (Glossary): Fix typo. diff --git a/doc/emacs/entering.texi b/doc/emacs/entering.texi index e338a6a8619..3737e4685e3 100644 --- a/doc/emacs/entering.texi +++ b/doc/emacs/entering.texi @@ -122,7 +122,7 @@ systems, you can only get back to the shell from which Emacs was run @vindex cannot-suspend Suspending can fail if you run Emacs under a shell that doesn't -support suspendion of its subjobs, even if the system itself does +support suspension of its subjobs, even if the system itself does support it. In such a case, you can set the variable @code{cannot-suspend} to a non-@code{nil} value to force @kbd{C-z} to start an inferior shell. From 10edbb1ac92ec50bd4847cbbba783f97a6d18792 Mon Sep 17 00:00:00 2001 From: Reiner Steib Date: Mon, 21 Jan 2008 23:10:32 +0000 Subject: [PATCH 253/439] (cvs-menu): Improve cvs-mode-find-file, cvs-mode-find-file-other-window. Add cvs-mode-diff-yesterday and manual entry. --- lisp/ChangeLog | 6 ++++++ lisp/pcvs-defs.el | 8 ++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 35cf2d449c4..5045c30b3e4 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-21 Reiner Steib + + * pcvs-defs.el (cvs-menu): Improve cvs-mode-find-file, + cvs-mode-find-file-other-window. Add cvs-mode-diff-yesterday and + manual entry. + 2008-01-21 Michael Albinus * net/dbus.el (dbus-ignore-errors): New macro. diff --git a/lisp/pcvs-defs.el b/lisp/pcvs-defs.el index fa6f2b1c050..a4e7fde0f51 100644 --- a/lisp/pcvs-defs.el +++ b/lisp/pcvs-defs.el @@ -404,8 +404,8 @@ This variable is buffer local and only used in the *cvs* buffer.") (easy-menu-define cvs-menu cvs-mode-map "Menu used in `cvs-mode'." '("CVS" - ["Open file.." cvs-mode-find-file t] - [" ..other window" cvs-mode-find-file-other-window t] + ["Open file" cvs-mode-find-file t] + ["Open in other window" cvs-mode-find-file-other-window t] ["Display in other window" cvs-mode-display-file t] ["Interactive merge" cvs-mode-imerge t] ("View diff" @@ -413,6 +413,7 @@ This variable is buffer local and only used in the *cvs* buffer.") ["Current diff" cvs-mode-diff t] ["Diff with head" cvs-mode-diff-head t] ["Diff with vendor" cvs-mode-diff-vendor t] + ["Diff against yesterday" cvs-mode-diff-yesterday t] ["Diff with backup" cvs-mode-diff-backup t]) ["View log" cvs-mode-log t] ["View status" cvs-mode-status t] @@ -437,6 +438,9 @@ This variable is buffer local and only used in the *cvs* buffer.") ["Unmark all" cvs-mode-unmark-all-files t] ["Hide handled" cvs-mode-remove-handled t] "----" + ["PCL-CVS Manual" (lambda () (interactive) + (info "(pcl-cvs)Top")) t] + "----" ["Quit" cvs-mode-quit t])) ;;;; From f52749ed49f1793cf6d89f4f37039b6d70ae291c Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 22 Jan 2008 06:39:44 +0000 Subject: [PATCH 254/439] (vc-diff-sentinel): Do not write a footer if there were differences. --- lisp/ChangeLog | 5 +++++ lisp/vc.el | 12 ++++++------ 2 files changed, 11 insertions(+), 6 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5045c30b3e4..6fd1b706a9c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-22 Glenn Morris + + * vc.el (vc-diff-sentinel): Do not write a footer if there were + differences. + 2008-01-21 Reiner Steib * pcvs-defs.el (cvs-menu): Improve cvs-mode-find-file, diff --git a/lisp/vc.el b/lisp/vc.el index ffe38a68521..38338d7f395 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -1,7 +1,8 @@ ;;; vc.el --- drive a version-control system from within Emacs ;; Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, -;; 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. +;; 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2008 +;; Free Software Foundation, Inc. ;; Author: FSF (see below for full credits) ;; Maintainer: Andre Spiegel @@ -1951,11 +1952,10 @@ the buffer contents as a comment." ;; possibility of an empty output is for an async process, in which case ;; it's important to insert the "diffs end here" message in the buffer ;; since the user may miss a message in the echo area. - (when verbose - (let ((inhibit-read-only t)) - (if (eq (buffer-size) 0) - (insert "No differences found.\n") - (insert (format "\n\nDiffs between %s and %s end here." rev1-name rev2-name))))) + (and verbose + (zerop (buffer-size)) + (let ((inhibit-read-only t)) + (insert "No differences found.\n"))) (goto-char (point-min)) (shrink-window-if-larger-than-buffer)) From 0dedb2bee0e945c11f5cbabc8a79f389da05d424 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Tue, 22 Jan 2008 06:56:23 +0000 Subject: [PATCH 255/439] (hide-ifdef-initially, hide-ifdef-read-only) (hide-ifdef-lines, hide-ifdef-shadow, hide-ifdef-shadow): Remove autoload cookies. --- lisp/ChangeLog | 4 ++++ lisp/progmodes/hideif.el | 5 ----- 2 files changed, 4 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6fd1b706a9c..448943d5857 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,9 @@ 2008-01-22 Glenn Morris + * progmodes/hideif.el (hide-ifdef-initially, hide-ifdef-read-only) + (hide-ifdef-lines, hide-ifdef-shadow, hide-ifdef-shadow): + Remove autoload cookies. + * vc.el (vc-diff-sentinel): Do not write a footer if there were differences. diff --git a/lisp/progmodes/hideif.el b/lisp/progmodes/hideif.el index b0f3cc9e3af..a55883b666a 100644 --- a/lisp/progmodes/hideif.el +++ b/lisp/progmodes/hideif.el @@ -114,31 +114,26 @@ "Hide selected code within `ifdef'." :group 'c) -;;;###autoload (defcustom hide-ifdef-initially nil "Non-nil means call `hide-ifdefs' when Hide-Ifdef mode is first activated." :type 'boolean :group 'hide-ifdef) -;;;###autoload (defcustom hide-ifdef-read-only nil "Set to non-nil if you want buffer to be read-only while hiding text." :type 'boolean :group 'hide-ifdef) -;;;###autoload (defcustom hide-ifdef-lines nil "Non-nil means hide the #ifX, #else, and #endif lines." :type 'boolean :group 'hide-ifdef) -;;;###autoload (defcustom hide-ifdef-shadow nil "Non-nil means shadow text instead of hiding it." :type 'boolean :group 'hide-ifdef) -;;;###autoload (defface hide-ifdef-shadow '((t (:inherit shadow))) "Face for shadowing ifdef blocks." :group 'hide-ifdef) From 1966aa849b2901a6c371af76a56d1a2e15adad59 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Tue, 22 Jan 2008 10:14:18 +0000 Subject: [PATCH 256/439] New entry. --- etc/ChangeLog | 6 +++++- etc/DEVEL.HUMOR | 10 ++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/etc/ChangeLog b/etc/ChangeLog index 55e7c2474f3..8e783c871fb 100644 --- a/etc/ChangeLog +++ b/etc/ChangeLog @@ -1,3 +1,7 @@ +2008-01-22 Juanma Barranquero + + * DEVEL.HUMOR: New entry. + 2008-01-18 Carsten Dominik * refcards/orgcard.tex: Update to Org-mode version 5.19. @@ -34,7 +38,7 @@ * images/icons/emacs_16.png, images/icons/emacs_24.png * images/icons/emacs_32.png, images/icons/emacs_48.png: Rename to - hicolor/16x16/apps/emacs.png hicolor/24x24/apps/emacs.png + hicolor/16x16/apps/emacs.png, hicolor/24x24/apps/emacs.png, hicolor/32x32/apps/emacs.png and hicolor/48x48/apps/emacs.png. * images/icons/README (Author): Update for renaming. diff --git a/etc/DEVEL.HUMOR b/etc/DEVEL.HUMOR index 10353c6517a..8b9430bd305 100644 --- a/etc/DEVEL.HUMOR +++ b/etc/DEVEL.HUMOR @@ -184,3 +184,13 @@ constants with anything like the universality of e and pi." "[...] So please do not delete anything." "Done." -- RMS and David Kastrup + +---------------------------------------------------------------------- + + "I guess that can work in some circumstances, but it bypasses the +printer drivers. Couldn't that lead to problems for the printer +drivers?" + "Current research is that software does not suffer feelings of +depression or loneliness when it is left out or the picture, so I +wouldn't worry about it too much." + -- Lennart Borgman and Jason Rumney From 8f4dc101ae41e11eb8a23241f2d9b3ee6d56001a Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Tue, 22 Jan 2008 15:22:54 +0000 Subject: [PATCH 257/439] * pop.c (pop_stat, pop_last): Fix last fix. --- lib-src/ChangeLog | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index 2bb60522966..d98a441f8d8 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-22 Chong Yidong + + * pop.c (pop_stat, pop_last): Fix last fix. + 2008-01-10 Chong Yidong * pop.c (pop_stat, pop_last): Check validity of string-to-integer From e11ebb0c4025f7ee43713ca875afb642b0eec806 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Tue, 22 Jan 2008 15:28:56 +0000 Subject: [PATCH 258/439] Fix typo. --- etc/DEVEL.HUMOR | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etc/DEVEL.HUMOR b/etc/DEVEL.HUMOR index 8b9430bd305..091c267579b 100644 --- a/etc/DEVEL.HUMOR +++ b/etc/DEVEL.HUMOR @@ -191,6 +191,6 @@ constants with anything like the universality of e and pi." printer drivers. Couldn't that lead to problems for the printer drivers?" "Current research is that software does not suffer feelings of -depression or loneliness when it is left out or the picture, so I +depression or loneliness when it is left out of the picture, so I wouldn't worry about it too much." -- Lennart Borgman and Jason Rumney From cc8ce247d5c81de71d4d744be86342d729a17c65 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Tue, 22 Jan 2008 15:36:05 +0000 Subject: [PATCH 259/439] (pop_stat, pop_last): Fix last fix. --- lib-src/pop.c | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/lib-src/pop.c b/lib-src/pop.c index 5dc5de75583..7b9b191add7 100644 --- a/lib-src/pop.c +++ b/lib-src/pop.c @@ -381,25 +381,18 @@ pop_stat (server, count, size) errno = 0; *count = strtol (&fromserver[4], &end_ptr, 10); /* Check validity of string-to-integer conversion. */ - if (fromserver[4] == 0 || *end_ptr != 0 || errno) + if (fromserver + 4 == end_ptr || *end_ptr != ' ' || errno) { strcpy (pop_error, "Unexpected response from POP server in pop_stat"); pop_trash (server); return (-1); } - fromserver = index (&fromserver[4], ' '); - if (! fromserver) - { - strcpy (pop_error, - "Badly formatted response from server in pop_stat"); - pop_trash (server); - return (-1); - } + fromserver = end_ptr; errno = 0; *size = strtol (fromserver + 1, &end_ptr, 10); - if (*(fromserver + 1) == 0 || *end_ptr != 0 || errno) + if (fromserver + 1 == end_ptr || errno) { strcpy (pop_error, "Unexpected response from POP server in pop_stat"); pop_trash (server); @@ -933,7 +926,7 @@ pop_last (server) int count; errno = 0; count = strtol (&fromserver[4], &end_ptr, 10); - if (fromserver[4] == 0 || *end_ptr != 0 || errno) + if (fromserver + 4 == end_ptr || errno) { strcpy (pop_error, "Unexpected response from server in pop_last"); pop_trash (server); From 702123a8235c5590d9b16365d6131b9bcc1f54a4 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Tue, 22 Jan 2008 15:38:40 +0000 Subject: [PATCH 260/439] * pop.c (pop_stat, pop_last): Fix last fix. --- lib-src/ChangeLog | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index c0d0bbbf41b..05d8af126bb 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-22 Chong Yidong + + * pop.c (pop_stat, pop_last): Fix last fix. + 2008-01-18 Dan Nicolaescu * movemail.c: Remove references to XENIX. From 59a431d6ee62d1d30a737eeb0927ab00c7c5ff4b Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Tue, 22 Jan 2008 15:38:49 +0000 Subject: [PATCH 261/439] (pop_stat, pop_last): Fix last fix. --- lib-src/pop.c | 15 ++++----------- 1 file changed, 4 insertions(+), 11 deletions(-) diff --git a/lib-src/pop.c b/lib-src/pop.c index 814575f06d5..f15a3fb23b6 100644 --- a/lib-src/pop.c +++ b/lib-src/pop.c @@ -381,25 +381,18 @@ pop_stat (server, count, size) errno = 0; *count = strtol (&fromserver[4], &end_ptr, 10); /* Check validity of string-to-integer conversion. */ - if (fromserver[4] == 0 || *end_ptr != 0 || errno) + if (fromserver + 4 == end_ptr || *end_ptr != ' ' || errno) { strcpy (pop_error, "Unexpected response from POP server in pop_stat"); pop_trash (server); return (-1); } - fromserver = index (&fromserver[4], ' '); - if (! fromserver) - { - strcpy (pop_error, - "Badly formatted response from server in pop_stat"); - pop_trash (server); - return (-1); - } + fromserver = end_ptr; errno = 0; *size = strtol (fromserver + 1, &end_ptr, 10); - if (*(fromserver + 1) == 0 || *end_ptr != 0 || errno) + if (fromserver + 1 == end_ptr || errno) { strcpy (pop_error, "Unexpected response from POP server in pop_stat"); pop_trash (server); @@ -933,7 +926,7 @@ pop_last (server) int count; errno = 0; count = strtol (&fromserver[4], &end_ptr, 10); - if (fromserver[4] == 0 || *end_ptr != 0 || errno) + if (fromserver + 4 == end_ptr || errno) { strcpy (pop_error, "Unexpected response from server in pop_last"); pop_trash (server); From 645b6388d5bae5304098c1e773694beffc3478e9 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Tue, 22 Jan 2008 15:43:44 +0000 Subject: [PATCH 262/439] ** Make longlines-mode wrap lines based on screen position instead of character position, so that variable-width fonts can be handled properly. --- etc/TODO | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/etc/TODO b/etc/TODO index ce2dec9861e..8698e5c8001 100644 --- a/etc/TODO +++ b/etc/TODO @@ -175,6 +175,10 @@ specified filters, specified timers, and specified hooks. * Other features we would like: +** Make longlines-mode wrap lines based on screen position instead + of character position, so that variable-width fonts can be handled + properly. + ** Remove the default toggling behavior of minor modes when called from elisp rather than interactively. This a trivial one-liner in easy-mode.el. ** Create a category of errors called `user-error' for errors which are From 22f9eb9e4f09de5570ba5ede033b0a8f0973a0e9 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Tue, 22 Jan 2008 15:44:14 +0000 Subject: [PATCH 263/439] ** Make longlines-mode wrap lines based on screen position instead of character position, so that variable-width fonts can be handled properly. --- etc/TODO | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/etc/TODO b/etc/TODO index 355a65fbde0..42f9c4fd3e0 100644 --- a/etc/TODO +++ b/etc/TODO @@ -194,6 +194,10 @@ specified filters, specified timers, and specified hooks. * Other features we would like: +** Make longlines-mode wrap lines based on screen position instead + of character position, so that variable-width fonts can be handled + properly. + ** Allow frames(terminals) created by emacsclient to inherit their environment from the emacsclient process. ** Remove the default toggling behavior of minor modes when called from elisp From dfbe40f2145a3df3b4296aaefa3456bb46d19a3b Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Tue, 22 Jan 2008 23:59:24 +0000 Subject: [PATCH 264/439] Fix dates for ChangeLog merge entries Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1007 --- lisp/ChangeLog | 28 ++++++++++++++-------------- src/ChangeLog | 6 +++--- 2 files changed, 17 insertions(+), 17 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 46d26d1a652..6261d014487 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,15 +1,15 @@ -2008-01-19 Dan Nicolaescu +2008-01-23 Dan Nicolaescu * progmodes/sh-script.el (sh-basic-offset): * progmodes/cc-vars.el (c-syntactic-indentation) (c-syntactic-indentation-in-macros): Mark as safe. -2008-01-18 Richard Stallman +2008-01-23 Richard Stallman * icomplete.el (icomplete-get-keys): Look up KEYS using all maps in proper buffer. -2008-01-17 Vinicius Jose Latorre +2008-01-23 Vinicius Jose Latorre Miles Bader * blank-mode.el: New file. Minor mode to visualise TAB, @@ -17,13 +17,13 @@ code for handling display table (via visws.el package), his code was modified, but the main idea was kept. -2008-01-16 Alan Mackenzie +2008-01-23 Alan Mackenzie * progmodes/cc-vars.el (c-constant-symbol): Put this defun inside an eval-and-compile, so as to permit byte-compiling (e.g. in bootstrap). -2008-01-16 Juanma Barranquero +2008-01-23 Juanma Barranquero * frame.el (display-mm-height, display-mm-width): * whitespace.el (whitespace-check-leading-whitespace) @@ -33,14 +33,14 @@ (whitespace-check-ateol-whitespace): * progmodes/ada-xref.el (ada-convert-file-name): Fix typo in docstring. -2008-01-15 Dan Nicolaescu +2008-01-23 Dan Nicolaescu * vc-arch.el (vc-arch-delete-rej-if-obsolete): Remove the after-save-hook so that it is not called multiple times. * vc-svn.el (vc-svn-resolve-when-done): Likewise. -2008-01-12 Eli Zaretskii +2008-01-23 Eli Zaretskii * view.el (view-file-other-window, view-file-other-frame): Don't kill the buffer if it is modified. Doc fixes. @@ -55,16 +55,16 @@ current-window-configuration. Fix second argument in the call to view-mode-enter. Doc fix. -2008-01-11 Richard Stallman +2008-01-23 Richard Stallman * subr.el (atomic-change-group): Prevent undo list truncation. -2008-01-10 Dan Nicolaescu +2008-01-23 Dan Nicolaescu * files.el (safe-local-eval-forms): Mark (add-hook 'write-file-hooks 'time-stamp) as safe. -2008-01-10 Nick Roberts +2008-01-23 Nick Roberts * comint.el (comint-insert-input): Set point first. @@ -73,7 +73,7 @@ (gdb-frame-handler): Use buffer-file-name instead of buffer-name in case of duplicate file names. -2008-01-10 Dan Nicolaescu +2008-01-23 Dan Nicolaescu * progmodes/verilog-mode.el (verilog-mode-map): Don't bind C-M-a, C-M-e and C-M-h for emacs, they work by default. @@ -85,17 +85,17 @@ (verilog-mark-defun): Only do something useful for XEmacs, emacs does not need it. -2008-01-09 Wilson Snyder +2008-01-23 Wilson Snyder * progmodes/verilog-mode.el (verilog-booleanp): New function for backward compatibility. Replace all uses of booleanp with verilog-booleanp. -2008-01-09 Dan Nicolaescu +2008-01-23 Dan Nicolaescu * vc-hg.el (vc-hg-diff): Don't pass an empty string. -2008-01-09 Wilson Snyder +2008-01-23 Wilson Snyder * progmodes/verilog-mode.el (top-level): Fix spacing. (verilog-mode-version, verilog-mode-release-date): Update version diff --git a/src/ChangeLog b/src/ChangeLog index b28fecb971a..09fbe99a8f2 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,4 +1,4 @@ -2008-01-21 YAMAMOTO Mitsuharu +2008-01-23 YAMAMOTO Mitsuharu * macterm.c (x_scroll_bar_create): Initialize bar->redraw_needed_p. (XTset_vertical_scroll_bar): Redraw scroll bar if bar->redraw_needed_p @@ -7,7 +7,7 @@ * macterm.h (struct scroll_bar): New member `redraw_needed_p'. -2008-01-17 Jason Rumney +2008-01-23 Jason Rumney * xterm.c (handle_one_xevent): Revert to counting chars not bytes. @@ -16,7 +16,7 @@ Improve dbcs lead byte detection. Set event timestamp and modifiers earlier. -2008-01-11 YAMAMOTO Mitsuharu +2008-01-23 YAMAMOTO Mitsuharu * mac.c (mac_emacs_pid) [MAC_OSX]: New variable. [MAC_OSX] (init_mac_osx_environment): Initialize it. From 93e45e6392fb63d949d3d6bf31d1293108979753 Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Wed, 23 Jan 2008 00:52:17 +0000 Subject: [PATCH 265/439] (printer-name): Do not set on MS Windows. --- lisp/ChangeLog | 4 ++++ lisp/lpr.el | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7633804d2d5..28d0cc19003 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-23 Jason Rumney + + * lpr.el (printer-name): Do not set on MS Windows. + 2008-01-21 Vinicius Jose Latorre * blank-mode.el: Fix a problem of cleaning blank faces when turning off diff --git a/lisp/lpr.el b/lisp/lpr.el index 6083cc5016b..7f11d3efe8a 100644 --- a/lisp/lpr.el +++ b/lisp/lpr.el @@ -47,7 +47,7 @@ ;;;###autoload (defcustom printer-name - (and lpr-windows-system "PRN") + (and (memq system-type '(emx ms-dos)) "PRN") "*The name of a local printer to which data is sent for printing. \(Note that PostScript files are sent to `ps-printer-name', which see.\) From ef95e7cfabd10af365fb6a11cf96261595a7a256 Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Wed, 23 Jan 2008 00:53:37 +0000 Subject: [PATCH 266/439] Fixed default printer-name. --- admin/FOR-RELEASE | 5 ----- 1 file changed, 5 deletions(-) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index d4b432600e2..feb509aece5 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -34,11 +34,6 @@ to the hack introduced on 2005-07-01 to fix some other Cleartype problem. ** henman@it.to-be.co.jp 09 Aug 2006: ispell.el problem on Cygwin. (Did we decide that is unreproducible?) -** lennart.borgman@gmail.com 09 Jan 2008: ps-print-buffer-with-faces hangs -If no printer is connected to the printer port that Emacs is printing -to, I/O to that port hangs in the system calls. Emacs should avoid -defaulting to a printer port that is not in use. - * BUGS WAITING FOR MORE USER INPUT ** undefined reference getopt_long From e941ed90f24a18777c379f0bfe82ffe6edaf1511 Mon Sep 17 00:00:00 2001 From: Nick Roberts Date: Wed, 23 Jan 2008 01:17:37 +0000 Subject: [PATCH 267/439] *** empty log message *** --- man/ChangeLog | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/man/ChangeLog b/man/ChangeLog index 444ca5c004f..470ec73c4fe 100644 --- a/man/ChangeLog +++ b/man/ChangeLog @@ -1,3 +1,8 @@ +2008-01-23 Kevin Ryde + + * custom.texi (Mouse Buttons): Update elisp xref to "Click Events" on + click count. + 2008-01-21 Juanma Barranquero * entering.texi (Exiting): Fix typo. From d1a3b360777284a04c1ab469d441906da193d716 Mon Sep 17 00:00:00 2001 From: Nick Roberts Date: Wed, 23 Jan 2008 01:19:17 +0000 Subject: [PATCH 268/439] (Mouse Buttons): Update elisp xref to "Click Events" on click count. --- man/custom.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/man/custom.texi b/man/custom.texi index 135c939a55c..826124be357 100644 --- a/man/custom.texi +++ b/man/custom.texi @@ -1881,7 +1881,7 @@ twice. types; clicks beyond the third generate additional triple-click events. However, the full number of clicks is recorded in the event list, so if you know Emacs Lisp you can distinguish if you really want to -(@pxref{Accessing Events,,, elisp, The Emacs Lisp Reference Manual}). +(@pxref{Click Events,,, elisp, The Emacs Lisp Reference Manual}). We don't recommend distinct meanings for more than three clicks, but sometimes it is useful for subsequent clicks to cycle through the same set of three meanings, so that four clicks are equivalent to one From 8b1de1b56a34249a9b948ee7f28d3a0aefbb38be Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Wed, 23 Jan 2008 03:43:32 +0000 Subject: [PATCH 269/439] Rename EMACS_ARG_Y to OPTION_DEFAULT_OFF, and EMACS_ARG_N to OPTION_DEFAULT_ON. --- ChangeLog | 7 +++ configure.in | 126 +++++++++++++++++++++++++++------------------------ 2 files changed, 74 insertions(+), 59 deletions(-) diff --git a/ChangeLog b/ChangeLog index d019bf4f8cc..e324c06b45b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,10 @@ +2008-01-23 Tom Tromey + + * configure.in (OPTION_DEFAULT_ON, OPTION_DEFAULT_OFF): New + macros. + (EMACS_ARG_Y, EMACS_ARG_N): Remove. + Update all users. + 2008-01-21 Dan Nicolaescu * config.guess, config.sub: Updated from master source. diff --git a/configure.in b/configure.in index 00b219db21e..be7f5d0fed1 100644 --- a/configure.in +++ b/configure.in @@ -43,47 +43,63 @@ gamedir='${localstatedir}/games/emacs' gameuser=games -dnl Autoconf is so much less fun under VMS, maybe -dnl because everything is less fun under VMS. --ttn -AC_DEFUN([EMACS_ARG_Y],[dnl -AC_ARG_WITH([$1],[AS_HELP_STRING([--with-$1],[$2])],[$3],[$4])dnl -])dnl -AC_DEFUN([EMACS_ARG_N],[dnl -AC_ARG_WITH([$1],[AS_HELP_STRING([--without-$1],[$2])],[$3],[$4])dnl +dnl OPTION_DEFAULT_OFF(NAME, HELP-STRING) +dnl Create a new --with option that defaults to being disabled. +dnl NAME is the base name of the option. The shell variable with_NAME +dnl will be set to either the user's value (if the option is +dnl specified; 'yes' for a plain --with-NAME) or to 'no' (if the +dnl option is not specified). Note that the shell variable name is +dnl constructed as autoconf does, by replacing non-alphanumeric +dnl characters with "_". +dnl HELP-STRING is the help text for the option. +AC_DEFUN([OPTION_DEFAULT_OFF], [dnl + AC_ARG_WITH([$1],[AS_HELP_STRING([--with-$1],[$2])],[],[dnl + m4_bpatsubst([with_$1], [[^0-9a-z]], [_])=no])dnl ])dnl -EMACS_ARG_N([gcc],[don't use GCC to compile Emacs if GCC is found]) +dnl OPTION_DEFAULT_ON(NAME, HELP-STRING) +dnl Create a new --with option that defaults to being enabled. NAME +dnl is the base name of the option. The shell variable with_NAME +dnl will be set either to 'no' (for a plain --without-NAME) or to +dnl 'yes' (if the option is not specified). Note that the shell +dnl variable name is constructed as autoconf does, by replacing +dnl non-alphanumeric characters with "_". +dnl HELP-STRING is the help text for the option. +AC_DEFUN([OPTION_DEFAULT_ON], [dnl + AC_ARG_WITH([$1],[AS_HELP_STRING([--without-$1],[$2])],[],[dnl + m4_bpatsubst([with_$1], [[^0-9a-z]], [_])=yes])dnl +])dnl -EMACS_ARG_N([pop],[don't support POP mail retrieval with movemail], -[if test "$withval" = yes; then +OPTION_DEFAULT_ON([gcc],[don't use GCC to compile Emacs if GCC is found]) + +OPTION_DEFAULT_ON([pop],[don't support POP mail retrieval with movemail]) +if test "$with_pop" = yes; then AC_DEFINE(MAIL_USE_POP) -else : -fi], -AC_DEFINE(MAIL_USE_POP)) +fi AH_TEMPLATE(MAIL_USE_POP, [Define to support POP mail retrieval.])dnl -EMACS_ARG_Y([kerberos],[support Kerberos-authenticated POP], -[if test "$withval" = yes; then +OPTION_DEFAULT_OFF([kerberos],[support Kerberos-authenticated POP]) +if test "$with_kerberos" = yes; then AC_DEFINE(KERBEROS) -fi]) +fi AH_TEMPLATE(KERBEROS, [Define to support Kerberos-authenticated POP mail retrieval.])dnl -EMACS_ARG_Y([kerberos5],[support Kerberos version 5 authenticated POP], -[if test "${with_kerberos5+set}" = set; then - if test "${with_kerberos+set}" != set; then +OPTION_DEFAULT_OFF([kerberos5],[support Kerberos version 5 authenticated POP]) +if test "${with_kerberos5}" = yes; then + if test "${with_kerberos}" != yes; then with_kerberos=yes AC_DEFINE(KERBEROS) fi AC_DEFINE(KERBEROS5, 1, [Define to use Kerberos 5 instead of Kerberos 4.]) -fi]) +fi -EMACS_ARG_Y([hesiod],[support Hesiod to get the POP server host], -[if test "$withval" = yes; then +OPTION_DEFAULT_OFF([hesiod],[support Hesiod to get the POP server host]) +if test "$with_hesiod" = yes; then AC_DEFINE(HESIOD, 1, [Define to support using a Hesiod database to find the POP server.]) -fi]) +fi -EMACS_ARG_N([sound],[don't compile with sound support]) +OPTION_DEFAULT_ON([sound],[don't compile with sound support]) dnl This should be the last --with option, because --with-x is dnl added later on when we find the path of X, and it's best to @@ -106,20 +122,28 @@ this option's value should be `yes', `no', `lucid', `athena', `motif' or `gtk'. with_x_toolkit=$val ]) -EMACS_ARG_Y([xpm],[use -lXpm for displaying XPM images]) -EMACS_ARG_Y([jpeg],[use -ljpeg for displaying JPEG images]) -EMACS_ARG_Y([tiff],[use -ltiff for displaying TIFF images]) -EMACS_ARG_Y([gif],[use -lgif (or -lungif) for displaying GIF images]) -EMACS_ARG_Y([png],[use -lpng for displaying PNG images]) -EMACS_ARG_Y([gpm],[use -lgpm for mouse support on a GNU/Linux console]) -EMACS_ARG_Y([rsvg],[use -lrsvg-2 for displaying SVG images]) -EMACS_ARG_Y([gtk],[use GTK (same as --with-x-toolkit=gtk)]) -EMACS_ARG_Y([pkg-config-prog],[Path to pkg-config for finding GTK and librsvg]) -EMACS_ARG_N([toolkit-scroll-bars],[don't use Motif or Xaw3d scroll bars]) -EMACS_ARG_N([xaw3d],[don't use Xaw3d]) -EMACS_ARG_N([xim],[don't use X11 XIM]) -EMACS_ARG_N([carbon],[don't use Carbon GUI on Mac OS X]) -EMACS_ARG_Y([dbus],[use D-Bus]) +OPTION_DEFAULT_OFF([xpm],[use -lXpm for displaying XPM images]) +OPTION_DEFAULT_OFF([jpeg],[use -ljpeg for displaying JPEG images]) +OPTION_DEFAULT_OFF([tiff],[use -ltiff for displaying TIFF images]) +OPTION_DEFAULT_OFF([gif],[use -lgif (or -lungif) for displaying GIF images]) +OPTION_DEFAULT_OFF([png],[use -lpng for displaying PNG images]) +OPTION_DEFAULT_OFF([gpm],[use -lgpm for mouse support on a GNU/Linux console]) +OPTION_DEFAULT_OFF([rsvg],[use -lrsvg-2 for displaying SVG images]) +OPTION_DEFAULT_OFF([gtk],[use GTK (same as --with-x-toolkit=gtk)]) +OPTION_DEFAULT_ON([toolkit-scroll-bars],[don't use Motif or Xaw3d scroll bars]) +OPTION_DEFAULT_ON([xaw3d],[don't use Xaw3d]) +OPTION_DEFAULT_ON([xim],[don't use X11 XIM]) +OPTION_DEFAULT_ON([carbon],[don't use Carbon GUI on Mac OS X]) +OPTION_DEFAULT_ON([dbus],[use D-Bus]) + +AC_ARG_WITH([pkg-config-prog],dnl + [AS_HELP_STRING([--with-pkg-config-prog=PATH], + [Path to pkg-config for finding GTK and librsvg])]) +if test "X${with_pkg_config_prog}" != X; then + if test "${with_pkg_config_prog}" != yes; then + PKG_CONFIG="${with_pkg_config_prog}" + fi +fi AC_ARG_ENABLE(carbon-app, [AS_HELP_STRING([--enable-carbon-app@<:@=DIR@:>@], @@ -1089,9 +1113,7 @@ dnl also defines GSTUFF_PKG_ERRORS on error AC_DEFUN([PKG_CHECK_MODULES], [ succeeded=no - if test -z "$PKG_CONFIG"; then - AC_PATH_PROG(PKG_CONFIG, pkg-config, no) - fi + AC_PATH_PROG(PKG_CONFIG, pkg-config, no) if test "$PKG_CONFIG" = "no" ; then ifelse([$4], , [AC_MSG_ERROR([ @@ -1147,10 +1169,6 @@ if test "${with_sound}" != "no"; then ALSA_REQUIRED=1.0.0 ALSA_MODULES="alsa >= $ALSA_REQUIRED" - dnl Check if --with-pkg-config-prog has been given. - if test "X${with_pkg_config_prog}" != X; then - PKG_CONFIG="${with_pkg_config_prog}" - fi PKG_CHECK_MODULES(ALSA, $ALSA_MODULES, HAVE_ALSA=yes, HAVE_ALSA=no) if test $HAVE_ALSA = yes; then SAVE_CFLAGS="$CFLAGS" @@ -1639,11 +1657,6 @@ fi HAVE_RSVG=no if test "${HAVE_X11}" = "yes" || test "${HAVE_CARBON}" = "yes"; then if test "${with_rsvg}" != "no"; then - dnl Check if `--with-pkg-config-prog' has been given. - if test "X${with_pkg_config_prog}" != X; then - PKG_CONFIG="${with_pkg_config_prog}" - fi - RSVG_REQUIRED=2.0.0 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED" @@ -1674,10 +1687,6 @@ if test "${with_gtk}" = "yes" || test "$USE_X_TOOLKIT" = "gtk" || \ GTK_REQUIRED=2.6 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED" - dnl Check if --with-pkg-config-prog has been given. - if test "X${with_pkg_config_prog}" != X; then - PKG_CONFIG="${with_pkg_config_prog}" - fi dnl Checks for libraries. PKG_CHECK_MODULES(GTK, $GTK_MODULES, pkg_check_gtk=yes, pkg_check_gtk=no) if test "$pkg_check_gtk" = "no" && test "$USE_X_TOOLKIT" != "maybe"; then @@ -1765,21 +1774,20 @@ dnl D-Bus has been tested under GNU/Linux only. Must be adapted for dnl other platforms. Support for higher D-Bus versions but 1.0 is dnl also not configured. HAVE_DBUS=no +AC_MSG_CHECKING([maybe dbus]) if test "${with_dbus}" = "yes"; then PKG_CHECK_MODULES(DBUS, dbus-1 >= 1.0, HAVE_DBUS=yes, HAVE_DBUS=no) if test "$HAVE_DBUS" = yes; then AC_DEFINE(HAVE_DBUS, 1, [Define to 1 if using D-Bus.]) fi + AC_MSG_RESULT($HAVE_DBUS) +else + AC_MSG_RESULT(no bub) fi ### Link with -lXft if available to work around a bug. HAVE_XFT=maybe if test "${HAVE_GTK}" = "yes"; then - dnl Check if --with-pkg-config-prog has been given. - if test "X${with_pkg_config_prog}" != X; then - PKG_CONFIG="${with_pkg_config_prog}" - fi - PKG_CHECK_MODULES(XFT, xft >= 0.13.0, , HAVE_XFT=no) if test "$HAVE_XFT" != no; then OLD_CFLAGS="$CPPFLAGS" From 1eee1145aaa05343f501a129be20f695f2f3a552 Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Wed, 23 Jan 2008 03:50:45 +0000 Subject: [PATCH 270/439] configure.in: Remove initial whitespace in pkg-config-prog. --- ChangeLog | 4 ++++ configure.in | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index e324c06b45b..48ab267907b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-01-23 Michael Olson + + * configure.in (pkg-config-prog): Remove initial whitespace. + 2008-01-23 Tom Tromey * configure.in (OPTION_DEFAULT_ON, OPTION_DEFAULT_OFF): New diff --git a/configure.in b/configure.in index be7f5d0fed1..91a23e74f74 100644 --- a/configure.in +++ b/configure.in @@ -137,7 +137,7 @@ OPTION_DEFAULT_ON([carbon],[don't use Carbon GUI on Mac OS X]) OPTION_DEFAULT_ON([dbus],[use D-Bus]) AC_ARG_WITH([pkg-config-prog],dnl - [AS_HELP_STRING([--with-pkg-config-prog=PATH], +[AS_HELP_STRING([--with-pkg-config-prog=PATH], [Path to pkg-config for finding GTK and librsvg])]) if test "X${with_pkg_config_prog}" != X; then if test "${with_pkg_config_prog}" != yes; then From 00b9c9273a5e40aff580f446ec7a4bddd23e6789 Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Wed, 23 Jan 2008 04:00:10 +0000 Subject: [PATCH 271/439] configure: Regenerate. --- ChangeLog | 2 + configure | 197 +++++++++++++++++++++++++++++++----------------------- 2 files changed, 116 insertions(+), 83 deletions(-) diff --git a/ChangeLog b/ChangeLog index 48ab267907b..8781c18be12 100644 --- a/ChangeLog +++ b/ChangeLog @@ -2,6 +2,8 @@ * configure.in (pkg-config-prog): Remove initial whitespace. + * configure: Regenerate. + 2008-01-23 Tom Tromey * configure.in (OPTION_DEFAULT_ON, OPTION_DEFAULT_OFF): New diff --git a/configure b/configure index fe96275bd42..26a5a8ba152 100755 --- a/configure +++ b/configure @@ -1352,13 +1352,14 @@ Optional Packages: --with-gpm use -lgpm for mouse support on a GNU/Linux console --with-rsvg use -lrsvg-2 for displaying SVG images --with-gtk use GTK (same as --with-x-toolkit=gtk) - --with-pkg-config-prog Path to pkg-config for finding GTK and librsvg --without-toolkit-scroll-bars don't use Motif or Xaw3d scroll bars --without-xaw3d don't use Xaw3d --without-xim don't use X11 XIM --without-carbon don't use Carbon GUI on Mac OS X - --with-dbus use D-Bus + --without-dbus use D-Bus + --with-pkg-config-prog=PATH + Path to pkg-config for finding GTK and librsvg --with-x use the X Window System Some influential environment variables: @@ -1836,49 +1837,57 @@ gameuser=games + # Check whether --with-gcc was given. if test "${with_gcc+set}" = set; then withval=$with_gcc; +else + with_gcc=yes fi # Check whether --with-pop was given. if test "${with_pop+set}" = set; then - withval=$with_pop; if test "$withval" = yes; then + withval=$with_pop; +else + with_pop=yes +fi + +if test "$with_pop" = yes; then cat >>confdefs.h <<\_ACEOF #define MAIL_USE_POP 1 _ACEOF -else : fi -else - cat >>confdefs.h <<\_ACEOF -#define MAIL_USE_POP 1 -_ACEOF - -fi - # Check whether --with-kerberos was given. if test "${with_kerberos+set}" = set; then - withval=$with_kerberos; if test "$withval" = yes; then + withval=$with_kerberos; +else + with_kerberos=no +fi + +if test "$with_kerberos" = yes; then cat >>confdefs.h <<\_ACEOF #define KERBEROS 1 _ACEOF fi -fi - # Check whether --with-kerberos5 was given. if test "${with_kerberos5+set}" = set; then - withval=$with_kerberos5; if test "${with_kerberos5+set}" = set; then - if test "${with_kerberos+set}" != set; then + withval=$with_kerberos5; +else + with_kerberos5=no +fi + +if test "${with_kerberos5}" = yes; then + if test "${with_kerberos}" != yes; then with_kerberos=yes cat >>confdefs.h <<\_ACEOF #define KERBEROS 1 @@ -1891,26 +1900,29 @@ cat >>confdefs.h <<\_ACEOF _ACEOF fi -fi - # Check whether --with-hesiod was given. if test "${with_hesiod+set}" = set; then - withval=$with_hesiod; if test "$withval" = yes; then + withval=$with_hesiod; +else + with_hesiod=no +fi + +if test "$with_hesiod" = yes; then cat >>confdefs.h <<\_ACEOF #define HESIOD 1 _ACEOF fi -fi - # Check whether --with-sound was given. if test "${with_sound+set}" = set; then withval=$with_sound; +else + with_sound=yes fi @@ -1943,87 +1955,119 @@ fi # Check whether --with-xpm was given. if test "${with_xpm+set}" = set; then withval=$with_xpm; +else + with_xpm=no fi # Check whether --with-jpeg was given. if test "${with_jpeg+set}" = set; then withval=$with_jpeg; +else + with_jpeg=no fi # Check whether --with-tiff was given. if test "${with_tiff+set}" = set; then withval=$with_tiff; +else + with_tiff=no fi # Check whether --with-gif was given. if test "${with_gif+set}" = set; then withval=$with_gif; +else + with_gif=no fi # Check whether --with-png was given. if test "${with_png+set}" = set; then withval=$with_png; +else + with_png=no fi # Check whether --with-gpm was given. if test "${with_gpm+set}" = set; then withval=$with_gpm; +else + with_gpm=no fi # Check whether --with-rsvg was given. if test "${with_rsvg+set}" = set; then withval=$with_rsvg; +else + with_rsvg=no fi # Check whether --with-gtk was given. if test "${with_gtk+set}" = set; then withval=$with_gtk; +else + with_gtk=no fi +# Check whether --with-toolkit-scroll-bars was given. +if test "${with_toolkit_scroll_bars+set}" = set; then + withval=$with_toolkit_scroll_bars; +else + with_toolkit_scroll_bars=yes +fi + + +# Check whether --with-xaw3d was given. +if test "${with_xaw3d+set}" = set; then + withval=$with_xaw3d; +else + with_xaw3d=yes +fi + + +# Check whether --with-xim was given. +if test "${with_xim+set}" = set; then + withval=$with_xim; +else + with_xim=yes +fi + + +# Check whether --with-carbon was given. +if test "${with_carbon+set}" = set; then + withval=$with_carbon; +else + with_carbon=yes +fi + + +# Check whether --with-dbus was given. +if test "${with_dbus+set}" = set; then + withval=$with_dbus; +else + with_dbus=yes +fi + + + # Check whether --with-pkg-config-prog was given. if test "${with_pkg_config_prog+set}" = set; then withval=$with_pkg_config_prog; fi - -# Check whether --with-toolkit-scroll-bars was given. -if test "${with_toolkit_scroll_bars+set}" = set; then - withval=$with_toolkit_scroll_bars; +if test "X${with_pkg_config_prog}" != X; then + if test "${with_pkg_config_prog}" != yes; then + PKG_CONFIG="${with_pkg_config_prog}" + fi fi - -# Check whether --with-xaw3d was given. -if test "${with_xaw3d+set}" = set; then - withval=$with_xaw3d; -fi - - -# Check whether --with-xim was given. -if test "${with_xim+set}" = set; then - withval=$with_xim; -fi - - -# Check whether --with-carbon was given. -if test "${with_carbon+set}" = set; then - withval=$with_carbon; -fi - - -# Check whether --with-dbus was given. -if test "${with_dbus+set}" = set; then - withval=$with_dbus; -fi - - # Check whether --enable-carbon-app was given. if test "${enable_carbon_app+set}" = set; then enableval=$enable_carbon_app; carbon_appdir_x=${enableval} @@ -5985,14 +6029,10 @@ fi ALSA_REQUIRED=1.0.0 ALSA_MODULES="alsa >= $ALSA_REQUIRED" - if test "X${with_pkg_config_prog}" != X; then - PKG_CONFIG="${with_pkg_config_prog}" - fi succeeded=no - if test -z "$PKG_CONFIG"; then - # Extract the first word of "pkg-config", so it can be a program name with args. + # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } @@ -6033,7 +6073,6 @@ echo "${ECHO_T}no" >&6; } fi - fi if test "$PKG_CONFIG" = "no" ; then HAVE_ALSA=no @@ -10618,18 +10657,13 @@ fi HAVE_RSVG=no if test "${HAVE_X11}" = "yes" || test "${HAVE_CARBON}" = "yes"; then if test "${with_rsvg}" != "no"; then - if test "X${with_pkg_config_prog}" != X; then - PKG_CONFIG="${with_pkg_config_prog}" - fi - RSVG_REQUIRED=2.0.0 RSVG_MODULE="librsvg-2.0 >= $RSVG_REQUIRED" succeeded=no - if test -z "$PKG_CONFIG"; then - # Extract the first word of "pkg-config", so it can be a program name with args. + # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } @@ -10670,7 +10704,6 @@ echo "${ECHO_T}no" >&6; } fi - fi if test "$PKG_CONFIG" = "no" ; then : @@ -10753,14 +10786,10 @@ echo "$as_me: error: Conflicting options, --with-gtk is incompatible with --with GTK_REQUIRED=2.6 GTK_MODULES="gtk+-2.0 >= $GTK_REQUIRED glib-2.0 >= $GLIB_REQUIRED" - if test "X${with_pkg_config_prog}" != X; then - PKG_CONFIG="${with_pkg_config_prog}" - fi succeeded=no - if test -z "$PKG_CONFIG"; then - # Extract the first word of "pkg-config", so it can be a program name with args. + # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } @@ -10801,7 +10830,6 @@ echo "${ECHO_T}no" >&6; } fi - fi if test "$PKG_CONFIG" = "no" ; then pkg_check_gtk=no @@ -11515,12 +11543,13 @@ _ACEOF fi HAVE_DBUS=no +{ echo "$as_me:$LINENO: checking maybe dbus" >&5 +echo $ECHO_N "checking maybe dbus... $ECHO_C" >&6; } if test "${with_dbus}" = "yes"; then succeeded=no - if test -z "$PKG_CONFIG"; then - # Extract the first word of "pkg-config", so it can be a program name with args. + # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } @@ -11561,7 +11590,6 @@ echo "${ECHO_T}no" >&6; } fi - fi if test "$PKG_CONFIG" = "no" ; then HAVE_DBUS=no @@ -11619,20 +11647,20 @@ cat >>confdefs.h <<\_ACEOF _ACEOF fi + { echo "$as_me:$LINENO: result: $HAVE_DBUS" >&5 +echo "${ECHO_T}$HAVE_DBUS" >&6; } +else + { echo "$as_me:$LINENO: result: no bub" >&5 +echo "${ECHO_T}no bub" >&6; } fi ### Link with -lXft if available to work around a bug. HAVE_XFT=maybe if test "${HAVE_GTK}" = "yes"; then - if test "X${with_pkg_config_prog}" != X; then - PKG_CONFIG="${with_pkg_config_prog}" - fi - succeeded=no - if test -z "$PKG_CONFIG"; then - # Extract the first word of "pkg-config", so it can be a program name with args. + # Extract the first word of "pkg-config", so it can be a program name with args. set dummy pkg-config; ac_word=$2 { echo "$as_me:$LINENO: checking for $ac_word" >&5 echo $ECHO_N "checking for $ac_word... $ECHO_C" >&6; } @@ -11673,7 +11701,6 @@ echo "${ECHO_T}no" >&6; } fi - fi if test "$PKG_CONFIG" = "no" ; then HAVE_XFT=no @@ -18099,11 +18126,13 @@ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -#include +#include /* for off_t */ + #include int main () { -return fseeko (stdin, 0, 0) && (fseeko) (stdin, 0, 0); +int (*fp) (FILE *, off_t, int) = fseeko; + return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); ; return 0; } @@ -18143,11 +18172,13 @@ cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #define _LARGEFILE_SOURCE 1 -#include +#include /* for off_t */ + #include int main () { -return fseeko (stdin, 0, 0) && (fseeko) (stdin, 0, 0); +int (*fp) (FILE *, off_t, int) = fseeko; + return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); ; return 0; } From f2c8de749380962f547f2e714f1096c5ad731abf Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 23 Jan 2008 05:46:13 +0000 Subject: [PATCH 272/439] (org-export-latex-cleaned-string): Fix declaration. --- lisp/textmodes/org.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/textmodes/org.el b/lisp/textmodes/org.el index 00a3bc2d195..bc63a962b9c 100644 --- a/lisp/textmodes/org.el +++ b/lisp/textmodes/org.el @@ -4171,7 +4171,7 @@ If it is less than 8, the level-1 face gets re-used for level N+1 etc." (defvar mh-show-folder-buffer) (defvar mh-index-folder) (defvar mh-searcher) -(declare-function org-export-latex-cleaned-string "org-export-latex" (&optional commentsp)) +(declare-function org-export-latex-cleaned-string "org-export-latex" ()) (declare-function parse-time-string "parse-time" (string)) (declare-function remember "remember" (&optional initial)) (declare-function remember-buffer-desc "remember" ()) From a025cb2f916b40dd553c68e602ee5776718563ab Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 23 Jan 2008 05:47:31 +0000 Subject: [PATCH 273/439] Fix merge errors (duplicates). --- lisp/ChangeLog | 18 ++++-------------- 1 file changed, 4 insertions(+), 14 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6261d014487..665552955d9 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-23 Glenn Morris + + * textmodes/org.el (org-export-latex-cleaned-string): Fix declaration. + 2008-01-23 Dan Nicolaescu * progmodes/sh-script.el (sh-basic-offset): @@ -9,20 +13,6 @@ * icomplete.el (icomplete-get-keys): Look up KEYS using all maps in proper buffer. -2008-01-23 Vinicius Jose Latorre - Miles Bader - - * blank-mode.el: New file. Minor mode to visualise TAB, - (HARD) SPACE, NEWLINE. Miles Bader wrote the original - code for handling display table (via visws.el package), his code was - modified, but the main idea was kept. - -2008-01-23 Alan Mackenzie - - * progmodes/cc-vars.el (c-constant-symbol): Put this defun inside - an eval-and-compile, so as to permit byte-compiling (e.g. in - bootstrap). - 2008-01-23 Juanma Barranquero * frame.el (display-mm-height, display-mm-width): From 1d51ea25e33cfdc19eb3c4e96ae5ecc6eb628cc3 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 23 Jan 2008 05:49:24 +0000 Subject: [PATCH 274/439] Add 2008 to copyright years. --- doc/emacs/Makefile.in | 2 +- doc/emacs/makefile.w32-in | 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/doc/emacs/Makefile.in b/doc/emacs/Makefile.in index f84c0866469..4527c3c767f 100644 --- a/doc/emacs/Makefile.in +++ b/doc/emacs/Makefile.in @@ -1,7 +1,7 @@ #### Makefile for the Emacs Manual # Copyright (C) 1994, 1996, 1997, 1998, 1999, 2000, 2001, 2002, 2003, -# 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +# 2004, 2005, 2006, 2007, 2008 Free Software Foundation, Inc. # This file is part of GNU Emacs. diff --git a/doc/emacs/makefile.w32-in b/doc/emacs/makefile.w32-in index d34ab66de4b..99b9e173f65 100644 --- a/doc/emacs/makefile.w32-in +++ b/doc/emacs/makefile.w32-in @@ -1,6 +1,7 @@ #### -*- Makefile -*- for the Emacs Manual -# Copyright (C) 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +# Copyright (C) 2003, 2004, 2005, 2006, 2007, 2008 +# Free Software Foundation, Inc. # This file is part of GNU Emacs. From 7cc04609cb5789a7e736d666af22f65671f706ce Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 23 Jan 2008 07:06:54 +0000 Subject: [PATCH 275/439] * configure.in (xtensa): Match more configurations. * configure: Regenerate. --- ChangeLog | 6 ++++++ configure | 10 +++++----- configure.in | 2 +- 3 files changed, 12 insertions(+), 6 deletions(-) diff --git a/ChangeLog b/ChangeLog index f78606d7367..63ec131c45b 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2008-01-23 Dan Nicolaescu + + * configure.in (xtensa): Match more configurations. + + * configure: Regenerate. + 2008-01-21 Dan Nicolaescu * config.guess, config.sub: Updated from master source. diff --git a/configure b/configure index 859f6b74881..c262d134757 100755 --- a/configure +++ b/configure @@ -412,10 +412,10 @@ else fi test \$exitcode = 0") || { - echo Please tell bug-autoconf@gnu.org about your system, - echo including any error possibly output before this message. - echo This can help us improve future autoconf versions. - echo Configuration will now proceed without shell functions. + echo No shell found that supports shell functions. + echo Please tell autoconf@gnu.org about your system, + echo including any error possibly output before this + echo message } @@ -3174,7 +3174,7 @@ _ACEOF ;; ## Tensilica Xtensa Linux-based GNU system - xtensa-*-linux-gnu* ) + xtensa*-*-linux-* ) machine=xtensa opsys=gnu-linux ;; diff --git a/configure.in b/configure.in index 2320ea18370..fc2a624487d 100644 --- a/configure.in +++ b/configure.in @@ -1209,7 +1209,7 @@ dnl see the `changequote' comment above. ;; ## Tensilica Xtensa Linux-based GNU system - xtensa-*-linux-gnu* ) + xtensa*-*-linux-* ) machine=xtensa opsys=gnu-linux ;; From c92926105acdd9c3d65b85cb04b48bdd3678cc69 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 23 Jan 2008 07:58:52 +0000 Subject: [PATCH 276/439] Add 2008 to copyright years. --- etc/refcards/pdflayout.sty | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/etc/refcards/pdflayout.sty b/etc/refcards/pdflayout.sty index 187ffee867b..9ee83cd187b 100644 --- a/etc/refcards/pdflayout.sty +++ b/etc/refcards/pdflayout.sty @@ -1,4 +1,4 @@ -% Copyright (C) 2007 Free Software Foundation, Inc. +% Copyright (C) 2007, 2008 Free Software Foundation, Inc. % This file is part of GNU Emacs. From 3f06493efec9d8048c2ec1fee06c180b41e721a2 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 23 Jan 2008 07:59:47 +0000 Subject: [PATCH 277/439] Add copyright header. --- admin/notes/multi-tty | 3 +++ 1 file changed, 3 insertions(+) diff --git a/admin/notes/multi-tty b/admin/notes/multi-tty index 5895f59bddc..c20364ec576 100644 --- a/admin/notes/multi-tty +++ b/admin/notes/multi-tty @@ -1,5 +1,8 @@ -*- coding: utf-8; mode: text; -*- +Copyright (C) 2007, 2008 Free Software Foundation, Inc. +See the end of the file for license conditions. + From README.multi-tty in the multi-tty branch. Some of this information may be out of date. From 0d5f855c4e87f3b45179f2013225acf995ca95d8 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 23 Jan 2008 08:00:43 +0000 Subject: [PATCH 278/439] Add 2008 to copyright years. --- src/.gdbinit | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/.gdbinit b/src/.gdbinit index ad7b666f188..2d38a214a0b 100644 --- a/src/.gdbinit +++ b/src/.gdbinit @@ -1,5 +1,6 @@ # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +# 2002, 2003, 2004, 2005, 2006, 2007, 2008 +# Free Software Foundation, Inc. # # This file is part of GNU Emacs. # From 087c3d13164d0f056dd163a6ced997123f2495d1 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Wed, 23 Jan 2008 08:01:01 +0000 Subject: [PATCH 279/439] Add 2008 to copyright years. --- src/.gdbinit | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/src/.gdbinit b/src/.gdbinit index 851322059a8..e983e43ca83 100644 --- a/src/.gdbinit +++ b/src/.gdbinit @@ -1,5 +1,6 @@ # Copyright (C) 1992, 1993, 1994, 1995, 1996, 1997, 1998, 2000, 2001, -# 2002, 2003, 2004, 2005, 2006, 2007 Free Software Foundation, Inc. +# 2002, 2003, 2004, 2005, 2006, 2007, 2008 +# Free Software Foundation, Inc. # # This file is part of GNU Emacs. # From c23346134dbe7f2a836a758f58132f90b2d56757 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Wed, 23 Jan 2008 10:29:49 +0000 Subject: [PATCH 280/439] (hide-ifdef-shadow): Add version number for defcustom. (hide-ifdef-shadow): Add version number for defface. --- lisp/ChangeLog | 6 ++++++ lisp/progmodes/hideif.el | 6 ++++-- 2 files changed, 10 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 665552955d9..5b2f3faa8da 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-23 Martin Rudalics + + * progmodes/hideif.el (hide-ifdef-shadow): Add version number + for defcustom. + (hide-ifdef-shadow): Add version number for defface. + 2008-01-23 Glenn Morris * textmodes/org.el (org-export-latex-cleaned-string): Fix declaration. diff --git a/lisp/progmodes/hideif.el b/lisp/progmodes/hideif.el index a55883b666a..4560836cb0b 100644 --- a/lisp/progmodes/hideif.el +++ b/lisp/progmodes/hideif.el @@ -132,11 +132,13 @@ (defcustom hide-ifdef-shadow nil "Non-nil means shadow text instead of hiding it." :type 'boolean - :group 'hide-ifdef) + :group 'hide-ifdef + :version "23.1") (defface hide-ifdef-shadow '((t (:inherit shadow))) "Face for shadowing ifdef blocks." - :group 'hide-ifdef) + :group 'hide-ifdef + :version "23.1") (defvar hide-ifdef-mode-submap From 5deae9b3b1d19a5fa885e023cf221c1ffb06adc8 Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Wed, 23 Jan 2008 10:48:57 +0000 Subject: [PATCH 281/439] *** empty log message *** --- lisp/ChangeLog | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5b2f3faa8da..7ca82203e2f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,12 @@ +2008-01-23 Carsten Dominik + + * replace.el (occur-mode-find-occurrence-hook): New hook that can + be used to reveal or highlight the location of a match. + (occur-mode-goto-occurrence) + (occur-mode-goto-occurrence-other-window) + (occur-mode-display-occurrence): Run + `occur-mode-find-occurrence-hook'. + 2008-01-23 Martin Rudalics * progmodes/hideif.el (hide-ifdef-shadow): Add version number From 8e62d5e855c245b2d576b7e1ce7aa11e94061cbd Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Wed, 23 Jan 2008 10:49:31 +0000 Subject: [PATCH 282/439] * replace.el (occur-mode-find-occurrence-hook): New hook that can be used to reveal or highlight the location of a match. (occur-mode-goto-occurrence) (occur-mode-goto-occurrence-other-window) (occur-mode-display-occurrence): Run `occur-mode-find-occurrence-hook'. --- lisp/replace.el | 16 +++++++++++++--- 1 file changed, 13 insertions(+), 3 deletions(-) diff --git a/lisp/replace.el b/lisp/replace.el index 0217e73e44c..3680d574e8c 100644 --- a/lisp/replace.el +++ b/lisp/replace.el @@ -789,6 +789,13 @@ See `occur-revert-function'.") :type 'hook :group 'matching) +(defcustom occur-mode-find-occurrence-hook nil + "Hook run by Occur after locating an occurrence. +This will be called with the cursor position at the occurrence. An application +for this is to reveal context in an outline-mode when the occurrence is hidden." + :type 'hook + :group 'matching) + (put 'occur-mode 'mode-class 'special) (defun occur-mode () "Major mode for output from \\[occur]. @@ -837,14 +844,16 @@ Alternatively, click \\[occur-mode-mouse-goto] on an item to go to it. same-window-buffer-names same-window-regexps) (pop-to-buffer (marker-buffer pos)) - (goto-char pos))) + (goto-char pos) + (run-hooks 'occur-mode-find-occurrence-hook))) (defun occur-mode-goto-occurrence-other-window () "Go to the occurrence the current line describes, in another window." (interactive) (let ((pos (occur-mode-find-occurrence))) (switch-to-buffer-other-window (marker-buffer pos)) - (goto-char pos))) + (goto-char pos) + (run-hooks 'occur-mode-find-occurrence-hook))) (defun occur-mode-display-occurrence () "Display in another window the occurrence the current line describes." @@ -858,7 +867,8 @@ Alternatively, click \\[occur-mode-mouse-goto] on an item to go to it. ;; This is the way to set point in the proper window. (save-selected-window (select-window window) - (goto-char pos)))) + (goto-char pos) + (run-hooks 'occur-mode-find-occurrence-hook)))) (defun occur-find-match (n search message) (if (not n) (setq n 1)) From 3b3cb3369582bf9ab53425b40b64373a2ce576cc Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Wed, 23 Jan 2008 16:35:18 +0000 Subject: [PATCH 283/439] Add TODO items. --- lisp/ChangeLog | 4 ++++ lisp/vc.el | 19 +++++++++++++++++-- 2 files changed, 21 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 7ca82203e2f..acfe79e8b38 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-23 Dan Nicolaescu + + * vc.el: Add TODO items. + 2008-01-23 Carsten Dominik * replace.el (occur-mode-find-occurrence-hook): New hook that can diff --git a/lisp/vc.el b/lisp/vc.el index 38338d7f395..aaac484fb7b 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -530,8 +530,10 @@ ;; - vc-update/vc-merge should deal with VC systems that don't ;; update/merge on a file basis, but on a whole repository basis. ;; -;; - vc-register should register multiple files at a time. The -;; `register' backend function already supports that. +;; - the backend sometimes knows when a file it opens has been marked +;; by the VCS as having a "conflict". Find a way to pass this info - +;; to VC so that it can turn on smerge-mode when opening such a +;; file. ;; ;; - the *VC-log* buffer needs font-locking. ;; @@ -541,11 +543,24 @@ ;; - make vc-state for all backends return 'unregistered instead of ;; nil for unregistered files, then update vc-next-action. ;; +;; - add a generic mechanism for remembering the current branch names, +;; display the branch name in the mode-line. Replace +;; vc-cvs-sticky-tag with that. +;; +;; - vc-register should register a fileset at a time. The backends +;; already support this, only the front-end needs to be change to +;; handle multiple files at a time. +;; +;; - add a mechanism to for ignoring files. +;; ;; - deal with push/pull operations. ;; ;; - decide if vc-status should replace vc-dired. ;; ;; - vc-status needs a menu, mouse bindings and some color bling. +;; +;; - "snapshots" should be renamed to "branches", and thoroughly reworked. +;; ;;; Code: From a0a5183aa32e2c8e4e69f954194822b150c3b6a0 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Wed, 23 Jan 2008 20:45:03 +0000 Subject: [PATCH 284/439] * net/tramp.el (tramp-remote-process-environment): Set "LC_ALL=C". (tramp-end-of-output): Add `tramp-rsh-end-of-line' into the regexp. (tramp-find-shell, tramp-open-connection-setup-interactive-shell): Don't send `tramp-rsh-end-of-line' additionally, when setting the prompt. (tramp-wait-for-output): Distinguish different prompt formats. (tramp-get-test-nt-command): Don't check for "\n" in the prompt. (tramp-local-host-p): Check whether temp directory is writable. --- lisp/ChangeLog | 14 ++++++++++++- lisp/net/tramp.el | 50 +++++++++++++++++++++++------------------------ 2 files changed, 37 insertions(+), 27 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index acfe79e8b38..62c718c8a61 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,4 +1,16 @@ -2008-01-23 Dan Nicolaescu +2008-01-23 Michael Albinus + + * net/tramp.el (tramp-remote-process-environment): Set "LC_ALL=C". + (tramp-end-of-output): Add `tramp-rsh-end-of-line' into the + regexp. + (tramp-find-shell, tramp-open-connection-setup-interactive-shell): + Don't send `tramp-rsh-end-of-line' additionally, when setting the + prompt. + (tramp-wait-for-output): Distinguish different prompt formats. + (tramp-get-test-nt-command): Don't check for "\n" in the prompt. + (tramp-local-host-p): Check whether temp directory is writable. + +22008-01-23 Dan Nicolaescu * vc.el: Add TODO items. diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 3969f992a8c..7c3153fc0be 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -914,7 +914,7 @@ directories for POSIX compatible commands." (string :tag "Directory")))) (defcustom tramp-remote-process-environment - `("HISTFILE=$HOME/.tramp_history" "HISTSIZE=1" "LC_CTYPE=C" "LC_TIME=C" + `("HISTFILE=$HOME/.tramp_history" "HISTSIZE=1" "LC_ALL=C" ,(concat "TERM=" tramp-terminal-type) "CDPATH=" "HISTORY=" "MAIL=" "MAILCHECK=" "MAILPATH=" "autocorrect=" "correct=") @@ -1433,9 +1433,11 @@ means to use always cached values for the directory contents." ;;; Internal Variables: (defvar tramp-end-of-output - (concat - "///" (md5 (concat - (prin1-to-string process-environment) (current-time-string)))) + (format + "%s///%s%s" + tramp-rsh-end-of-line + (md5 (concat (prin1-to-string process-environment) (current-time-string))) + tramp-rsh-end-of-line) "String used to recognize end of output.") (defvar tramp-current-method nil @@ -5360,22 +5362,14 @@ file exists and nonzero exit status otherwise." vec (format "PROMPT_COMMAND='' PS1='$ ' PS2='' PS3='' exec %s" shell) t)) + ;; Setting prompts. (tramp-message vec 5 "Setting remote shell prompt...") - ;; Douglas Gray Stephens says that we - ;; must use "\n" here, not tramp-rsh-end-of-line. Kai left the - ;; last tramp-rsh-end-of-line, Douglas wanted to replace that, - ;; as well. - (tramp-send-command - vec - (format "PS1='%s%s%s'" - tramp-rsh-end-of-line - tramp-end-of-output - tramp-rsh-end-of-line) - t) + (tramp-send-command vec (format "PS1='%s'" tramp-end-of-output) t) (tramp-send-command vec "PS2=''" t) (tramp-send-command vec "PS3=''" t) (tramp-send-command vec "PROMPT_COMMAND=''" t) (tramp-message vec 5 "Setting remote shell prompt...done")) + (t (tramp-message vec 5 "Remote `%s' groks tilde expansion, good" (tramp-get-method-parameter @@ -5668,13 +5662,7 @@ process to set up. VEC specifies the connection." ;; We can set $PS1 to `tramp-end-of-output' only when the echo has ;; been disabled. Otherwise, the echo of the command would be ;; regarded as prompt already. - (tramp-send-command - vec - (format "PS1='%s%s%s'" - tramp-rsh-end-of-line - tramp-end-of-output - tramp-rsh-end-of-line) - t) + (tramp-send-command vec (format "PS1='%s'" tramp-end-of-output) t) (tramp-send-command vec "PS2=''" t) (tramp-send-command vec "PS3=''" t) (tramp-send-command vec "PROMPT_COMMAND=''" t) @@ -6249,7 +6237,11 @@ function waits for output unless NOOUTPUT is set." (with-current-buffer (process-buffer proc) ;; Initially, `tramp-end-of-output' is "$ ". There might be ;; leading escape sequences, which must be ignored. - (let* ((regexp (format "^[^$\n]*%s\r?$" (regexp-quote tramp-end-of-output))) + (let* ((regexp + (if (string-match (regexp-quote "\n") tramp-end-of-output) + (mapconcat + 'identity (split-string tramp-end-of-output "\n") "\r?\n") + (format "^[^$\n]*%s\r?$" (regexp-quote tramp-end-of-output)))) (found (tramp-wait-for-regexp proc timeout regexp))) (if found (let (buffer-read-only) @@ -6737,7 +6729,14 @@ necessary only. This function will be used in file name completion." (and (stringp host) (string-match - (concat "^" (regexp-opt (list "localhost" (system-name)) t) "$") host)))) + (concat "^" (regexp-opt (list "localhost" (system-name)) t) "$") host) + ;; The local temp directory must be writable for the other user. + (file-writable-p + (tramp-make-tramp-file-name + (tramp-file-name-method vec) + (tramp-file-name-user vec) + host + (tramp-compat-temporary-file-directory)))))) ;; Variables local to connection. @@ -6833,8 +6832,7 @@ necessary only. This function will be used in file name completion." vec (format "( %s / -nt / )" (tramp-get-test-command vec))) (with-current-buffer (tramp-get-buffer vec) (goto-char (point-min)) - (when (looking-at - (format "\n%s\r?\n" (regexp-quote tramp-end-of-output))) + (when (looking-at (regexp-quote tramp-end-of-output)) (format "%s %%s -nt %%s" (tramp-get-test-command vec))))) (progn (tramp-send-command From 881c0f33dde8ea52d1dff18969cb843b96c3aad1 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 24 Jan 2008 04:46:59 +0000 Subject: [PATCH 285/439] Remove out-of-date section of commentary. --- lisp/progmodes/hideif.el | 6 ------ 1 file changed, 6 deletions(-) diff --git a/lisp/progmodes/hideif.el b/lisp/progmodes/hideif.el index 4560836cb0b..83ffb5f7a0e 100644 --- a/lisp/progmodes/hideif.el +++ b/lisp/progmodes/hideif.el @@ -99,12 +99,6 @@ ;; ;; Written by Brian Marick, at Gould, Computer Systems Division, Urbana IL. ;; Extensively modified by Daniel LaLiberte (while at Gould). -;; -;; You may freely modify and distribute this, but keep a record -;; of modifications and send comments to: -;; liberte@a.cs.uiuc.edu or ihnp4!uiucdcs!liberte -;; I will continue to upgrade hide-ifdef-mode -;; with your contributions. ;;; Code: From 478975a92ab0e5d966082be1b565bb3792bfd987 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 24 Jan 2008 04:49:39 +0000 Subject: [PATCH 286/439] (gpm-mouse-start): Declare as a function. --- lisp/ChangeLog | 12 +++++++----- lisp/t-mouse.el | 6 +++++- 2 files changed, 12 insertions(+), 6 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 62c718c8a61..0272d6cbec1 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,8 +1,11 @@ +2008-01-24 Glenn Morris + + * t-mouse.el (gpm-mouse-start): Declare as a function. + 2008-01-23 Michael Albinus * net/tramp.el (tramp-remote-process-environment): Set "LC_ALL=C". - (tramp-end-of-output): Add `tramp-rsh-end-of-line' into the - regexp. + (tramp-end-of-output): Add `tramp-rsh-end-of-line' into the regexp. (tramp-find-shell, tramp-open-connection-setup-interactive-shell): Don't send `tramp-rsh-end-of-line' additionally, when setting the prompt. @@ -10,7 +13,7 @@ (tramp-get-test-nt-command): Don't check for "\n" in the prompt. (tramp-local-host-p): Check whether temp directory is writable. -22008-01-23 Dan Nicolaescu +2008-01-23 Dan Nicolaescu * vc.el: Add TODO items. @@ -20,8 +23,7 @@ be used to reveal or highlight the location of a match. (occur-mode-goto-occurrence) (occur-mode-goto-occurrence-other-window) - (occur-mode-display-occurrence): Run - `occur-mode-find-occurrence-hook'. + (occur-mode-display-occurrence): Run `occur-mode-find-occurrence-hook'. 2008-01-23 Martin Rudalics diff --git a/lisp/t-mouse.el b/lisp/t-mouse.el index 1a000f37470..a89fe142551 100644 --- a/lisp/t-mouse.el +++ b/lisp/t-mouse.el @@ -4,7 +4,8 @@ ;; Maintainer: FSF ;; Keywords: mouse gpm linux -;; Copyright (C) 1994, 1995, 1998, 2006, 2007, 2008 Free Software Foundation, Inc. +;; Copyright (C) 1994, 1995, 1998, 2006, 2007, 2008 +;; Free Software Foundation, Inc. ;; This file is part of GNU Emacs. @@ -39,6 +40,9 @@ ;;; Code: +;; Prevent warning when compiling in an Emacs without gpm support. +(declare-function gpm-mouse-start "term.c" ()) + ;;;###autoload (define-obsolete-function-alias 't-mouse-mode 'gpm-mouse-mode "23.1") ;;;###autoload From bf9a7ece32985dea7fbbb23852c3b68d3d9ef8b1 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 24 Jan 2008 04:50:50 +0000 Subject: [PATCH 287/439] Standardize dbus-related messages. --- ChangeLog | 9 +++++---- configure.in | 7 ++----- 2 files changed, 7 insertions(+), 9 deletions(-) diff --git a/ChangeLog b/ChangeLog index 8781c18be12..de0e388afb1 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,13 +1,14 @@ +2008-01-24 Glenn Morris + + * configure.in: Standardize dbus-related messages. + 2008-01-23 Michael Olson * configure.in (pkg-config-prog): Remove initial whitespace. - * configure: Regenerate. - 2008-01-23 Tom Tromey - * configure.in (OPTION_DEFAULT_ON, OPTION_DEFAULT_OFF): New - macros. + * configure.in (OPTION_DEFAULT_ON, OPTION_DEFAULT_OFF): New macros. (EMACS_ARG_Y, EMACS_ARG_N): Remove. Update all users. diff --git a/configure.in b/configure.in index 91a23e74f74..a13c1f31378 100644 --- a/configure.in +++ b/configure.in @@ -1771,18 +1771,14 @@ if test "${HAVE_GTK}" = "yes"; then fi dnl D-Bus has been tested under GNU/Linux only. Must be adapted for -dnl other platforms. Support for higher D-Bus versions but 1.0 is +dnl other platforms. Support for higher D-Bus versions than 1.0 is dnl also not configured. HAVE_DBUS=no -AC_MSG_CHECKING([maybe dbus]) if test "${with_dbus}" = "yes"; then PKG_CHECK_MODULES(DBUS, dbus-1 >= 1.0, HAVE_DBUS=yes, HAVE_DBUS=no) if test "$HAVE_DBUS" = yes; then AC_DEFINE(HAVE_DBUS, 1, [Define to 1 if using D-Bus.]) fi - AC_MSG_RESULT($HAVE_DBUS) -else - AC_MSG_RESULT(no bub) fi ### Link with -lXft if available to work around a bug. @@ -2971,6 +2967,7 @@ echo " Does Emacs use a gif library? ${HAVE_GIF} $ac_ echo " Does Emacs use -lpng? ${HAVE_PNG}" echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}" echo " Does Emacs use -lgpm? ${HAVE_GPM}" +echo " Does Emacs use -ldbus? ${HAVE_DBUS}" echo " Does Emacs use X toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}" echo From 4599d0ec2152952709e6f9302d44f453a4db7391 Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Thu, 24 Jan 2008 07:47:38 +0000 Subject: [PATCH 288/439] Merge from gnus--devo--0 Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1009 --- lisp/gnus/ChangeLog | 8 ++++++++ lisp/gnus/gnus-art.el | 4 +--- lisp/gnus/mm-decode.el | 5 ++++- lisp/gnus/mml.el | 9 +++++++-- 4 files changed, 20 insertions(+), 6 deletions(-) diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 569789888dd..dbba5fd608e 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog @@ -1,3 +1,11 @@ +2008-01-23 Katsumi Yamaoka + + * gnus-art.el (gnus-insert-mime-button): Don't decode description. + + * mm-decode.el (mm-dissect-buffer): Decode description. + + * mml.el (mml-to-mime): Encode message header first. + 2008-01-18 Katsumi Yamaoka * gnus-art.el (gnus-article-describe-bindings): Make it possible to use diff --git a/lisp/gnus/gnus-art.el b/lisp/gnus/gnus-art.el index 6e41f413609..f93a304be46 100644 --- a/lisp/gnus/gnus-art.el +++ b/lisp/gnus/gnus-art.el @@ -5455,9 +5455,7 @@ N is the numerical prefix." (mail-content-type-get (mm-handle-type handle) 'url) "")) (gnus-tmp-type (mm-handle-media-type handle)) - (gnus-tmp-description - (mail-decode-encoded-word-string (or (mm-handle-description handle) - ""))) + (gnus-tmp-description (or (mm-handle-description handle) "")) (gnus-tmp-dots (if (if displayed (car displayed) (mm-handle-displayed-p handle)) diff --git a/lisp/gnus/mm-decode.el b/lisp/gnus/mm-decode.el index 8e88ffca6bb..f832a9c28e1 100644 --- a/lisp/gnus/mm-decode.el +++ b/lisp/gnus/mm-decode.el @@ -570,7 +570,10 @@ Postpone undisplaying of viewers for types in ;; creates unibyte buffers. This `if', though not a perfect ;; solution, avoids most of them. (if from - (setq from (cadr (mail-extract-address-components from)))))) + (setq from (cadr (mail-extract-address-components from)))) + (if description + (setq description (mail-decode-encoded-word-string + description))))) (if (or (not ctl) (not (string-match "/" (car ctl)))) (mm-dissect-singlepart diff --git a/lisp/gnus/mml.el b/lisp/gnus/mml.el index 04f8ef4e462..2b5987e5e6e 100644 --- a/lisp/gnus/mml.el +++ b/lisp/gnus/mml.el @@ -875,14 +875,19 @@ If HANDLES is non-nil, use it instead reparsing the buffer." (defun mml-to-mime () "Translate the current buffer from MML to MIME." - (message-encode-message-body) + ;; `message-encode-message-body' will insert an encoded Content-Description + ;; header in the message header if the body contains a single part + ;; that is specified by a user with a MML tag containing a description + ;; token. So, we encode the message header first to prevent the encoded + ;; Content-Description header from being encoded again. (save-restriction (message-narrow-to-headers-or-head) ;; Skip past any From_ headers. (while (looking-at "From ") (forward-line 1)) (let ((mail-parse-charset message-default-charset)) - (mail-encode-encoded-word-buffer)))) + (mail-encode-encoded-word-buffer))) + (message-encode-message-body)) (defun mml-insert-mime (handle &optional no-markup) (let (textp buffer mmlp) From 4ac7bfcf33552cede980210847b56707c0c2d2cc Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Thu, 24 Jan 2008 08:01:54 +0000 Subject: [PATCH 289/439] Add a TODO item about missing files. (vc-exec-after): Add a tooltip to the new mode-line item. --- lisp/ChangeLog | 6 ++++++ lisp/vc.el | 11 +++++++++-- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 0272d6cbec1..c08c62621d5 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-24 Dan Nicolaescu + + * vc.el: Add a TODO item about missing files. + (vc-exec-after): Add a tooltip to the new mode-line item. + + 2008-01-24 Glenn Morris * t-mouse.el (gpm-mouse-start): Declare as a function. diff --git a/lisp/vc.el b/lisp/vc.el index aaac484fb7b..b51a706a2a6 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -559,6 +559,11 @@ ;; ;; - vc-status needs a menu, mouse bindings and some color bling. ;; +;; - vc-status needs to show missing files. It probably needs to have +;; another state for those files. The user might want to restore +;; them, or remove them from the VCS. C-x v v might also need +;; adjustments. +;; ;; - "snapshots" should be renamed to "branches", and thoroughly reworked. ;; @@ -1028,8 +1033,10 @@ Else, add CODE to the process' sentinel." (setq mode-line-process ;; Deliberate overstatement, but power law respected. ;; (The message is ephemeral, so we make it loud.) --ttn - (propertize " (incomplete / in progress)" - 'face 'compilation-warning)) + (propertize " (incomplete/in progress)" + 'face 'compilation-warning + 'help-echo + "A VC command is in progress in this buffer")) (let ((previous (process-sentinel proc))) (unless (eq previous 'vc-process-sentinel) (process-put proc 'vc-previous-sentinel previous)) From 2ee455eaa3cc38e47a5dd29f630b02f19e92c294 Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Thu, 24 Jan 2008 08:48:42 +0000 Subject: [PATCH 290/439] Delete eol whitespace; nfc. --- lisp/vc.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/vc.el b/lisp/vc.el index b51a706a2a6..74bfd045b54 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -1035,7 +1035,7 @@ Else, add CODE to the process' sentinel." ;; (The message is ephemeral, so we make it loud.) --ttn (propertize " (incomplete/in progress)" 'face 'compilation-warning - 'help-echo + 'help-echo "A VC command is in progress in this buffer")) (let ((previous (process-sentinel proc))) (unless (eq previous 'vc-process-sentinel) From fddde1f0b5f04dcb96360fb1f88b0aa0d1f251ed Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Thu, 24 Jan 2008 08:54:00 +0000 Subject: [PATCH 291/439] Handle dead buffers in async filters/sentinels. (vc-process-filter): Do nothing if buffer not live. (vc-diff-finish): Rename from vc-diff-sentinel. No longer take REV1-NAME and REV2-NAME. Instead, take BUFFER-NAME. Do nothing if buffer not live. Don't do window resize if no window displays buffer. (vc-diff-internal): Use vc-diff-finish. --- lisp/ChangeLog | 10 +++++++++- lisp/vc.el | 42 +++++++++++++++++++++++------------------- 2 files changed, 32 insertions(+), 20 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c08c62621d5..370f63021b3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,9 +1,17 @@ +2008-01-24 Thien-Thi Nguyen + + * vc.el (vc-process-filter): Do nothing if buffer not live. + (vc-diff-finish): Rename from vc-diff-sentinel. + No longer take REV1-NAME and REV2-NAME. + Instead, take BUFFER-NAME. Do nothing if buffer not live. + Don't do window resize if no window displays buffer. + (vc-diff-internal): Use vc-diff-finish. + 2008-01-24 Dan Nicolaescu * vc.el: Add a TODO item about missing files. (vc-exec-after): Add a tooltip to the new mode-line item. - 2008-01-24 Glenn Morris * t-mouse.el (gpm-mouse-start): Declare as a function. diff --git a/lisp/vc.el b/lisp/vc.el index 74bfd045b54..1bb5c28d530 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -952,13 +952,15 @@ However, before executing BODY, find FILE, and after BODY, save buffer." "An alternative output filter for async process P. One difference with the default filter is that this inserts S after markers. Another is that undo information is not kept." - (with-current-buffer (process-buffer p) - (save-excursion - (let ((buffer-undo-list t) - (inhibit-read-only t)) - (goto-char (process-mark p)) - (insert s) - (set-marker (process-mark p) (point)))))) + (let ((buffer (process-buffer p))) + (when (buffer-live-p buffer) + (with-current-buffer buffer + (save-excursion + (let ((buffer-undo-list t) + (inhibit-read-only t)) + (goto-char (process-mark p)) + (insert s) + (set-marker (process-mark p) (point)))))))) (defun vc-setup-buffer (&optional buf) "Prepare BUF for executing a VC command and make it current. @@ -981,10 +983,10 @@ BUF defaults to \"*vc*\", can be a string and will be created if necessary." (defun vc-process-sentinel (p s) (let ((previous (process-get p 'vc-previous-sentinel)) (buf (process-buffer p))) - (if previous (funcall previous p s)) ;; Impatient users sometime kill "slow" buffers; check liveness ;; to avoid "error in process sentinel: Selecting deleted buffer". (when (buffer-live-p buf) + (if previous (funcall previous p s)) (with-current-buffer buf (setq mode-line-process (let ((status (process-status p))) @@ -1969,17 +1971,19 @@ the buffer contents as a comment." (defmacro vc-diff-switches-list (backend) `(vc-switches ',backend 'diff)) (make-obsolete 'vc-diff-switches-list 'vc-switches "22.1") -(defun vc-diff-sentinel (verbose rev1-name rev2-name) +(defun vc-diff-finish (buffer-name verbose) ;; The empty sync output case has already been handled, so the only - ;; possibility of an empty output is for an async process, in which case - ;; it's important to insert the "diffs end here" message in the buffer - ;; since the user may miss a message in the echo area. - (and verbose - (zerop (buffer-size)) - (let ((inhibit-read-only t)) - (insert "No differences found.\n"))) - (goto-char (point-min)) - (shrink-window-if-larger-than-buffer)) + ;; possibility of an empty output is for an async process. + (when (buffer-live-p buffer-name) + (with-current-buffer (get-buffer buffer-name) + (and verbose + (zerop (buffer-size)) + (let ((inhibit-read-only t)) + (insert "No differences found.\n"))) + (goto-char (point-min)) + (let ((window (get-buffer-window (current-buffer)))) + (when window + (shrink-window-if-larger-than-buffer window)))))) (defvar vc-diff-added-files nil "If non-nil, diff added files by comparing them to /dev/null.") @@ -2038,7 +2042,7 @@ returns t if the buffer had changes, nil otherwise." ;; bindings are nicer for read only buffers. pcl-cvs does the ;; same thing. (setq buffer-read-only t) - (vc-exec-after `(vc-diff-sentinel ,verbose ,rev1-name ,rev2-name)) + (vc-exec-after `(vc-diff-finish ,(buffer-name) ,verbose)) ;; Display the buffer, but at the end because it can change point. (pop-to-buffer (current-buffer)) ;; In the async case, we return t even if there are no differences From 578877a1fd02f37293b8a5810fab3b81830f3943 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Thu, 24 Jan 2008 09:46:40 +0000 Subject: [PATCH 292/439] (delete-selection-pre-hook): Avoid clearing out pre-command-hook when text is read-only. --- lisp/ChangeLog | 5 +++++ lisp/delsel.el | 18 +++++++++++++++++- 2 files changed, 22 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 370f63021b3..34a8222c13f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-24 Martin Rudalics + + * delsel.el (delete-selection-pre-hook): Avoid clearing out + pre-command-hook when text is read-only. + 2008-01-24 Thien-Thi Nguyen * vc.el (vc-process-filter): Do nothing if buffer not live. diff --git a/lisp/delsel.el b/lisp/delsel.el index 6427c39eecb..990ca91ace2 100644 --- a/lisp/delsel.el +++ b/lisp/delsel.el @@ -113,7 +113,23 @@ any selection." ;; stop safe_run_hooks from clearing out pre-command-hook. (and (eq inhibit-quit 'pre-command-hook) (setq inhibit-quit 'delete-selection-dummy)) - (signal 'file-supersession (cdr data))))))) + (signal 'file-supersession (cdr data))) + (text-read-only + ;; This signal may come either from `delete-active-region' or + ;; `self-insert-command' (when `overwrite-mode' is non-nil). + ;; To avoid clearing out `pre-command-hook' we handle this case + ;; by issuing a simple message. Note, however, that we do not + ;; handle all related problems: When read-only text ends before + ;; the end of the region, the latter is not deleted but any + ;; subsequent insertion will succeed. We could avoid this case + ;; by doing a (setq this-command 'ignore) here. This would, + ;; however, still not handle the case where read-only text ends + ;; precisely where the region starts: In that case the deletion + ;; would succeed but the subsequent insertion would fail with a + ;; text-read-only error. To handle that case we would have to + ;; investigate text properties at both ends of the region and + ;; skip the deletion when inserting text is forbidden there. + (message "Text is read-only") (ding)))))) (put 'self-insert-command 'delete-selection t) (put 'self-insert-iso 'delete-selection t) From b240275b833414e62c75c2873ba2552fd20518a3 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 24 Jan 2008 10:44:22 +0000 Subject: [PATCH 293/439] *** empty log message *** --- lisp/ChangeLog | 98 ++++++++++++++++++++++---------------------------- 1 file changed, 43 insertions(+), 55 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 34a8222c13f..ca1387f62c0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -40,8 +40,7 @@ * replace.el (occur-mode-find-occurrence-hook): New hook that can be used to reveal or highlight the location of a match. - (occur-mode-goto-occurrence) - (occur-mode-goto-occurrence-other-window) + (occur-mode-goto-occurrence, occur-mode-goto-occurrence-other-window) (occur-mode-display-occurrence): Run `occur-mode-find-occurrence-hook'. 2008-01-23 Martin Rudalics @@ -84,13 +83,13 @@ 2008-01-23 Eli Zaretskii - * view.el (view-file-other-window, view-file-other-frame): Don't - kill the buffer if it is modified. Doc fixes. + * view.el (view-file-other-window, view-file-other-frame): + Don't kill the buffer if it is modified. Doc fixes. (kill-buffer-if-not-modified): New function. (view-file): Don't kill the buffer if it is modified. - * progmodes/ebrowse.el (ebrowse-view-file-other-window): Delete - function. + * progmodes/ebrowse.el (ebrowse-view-file-other-window): + Delete function. (ebrowse-view/find-file-and-search-pattern): Call view-file-other-window instead of ebrowse-view-file-other-window. (ebrowse-view-file-other-frame): Don't call @@ -124,7 +123,7 @@ Remove. Move syntax table initialization ... (verilog-mode-syntax-table): ... here. (verilog-mode): Don't initialize the syntax table here. - (verilog-mark-defun): Only do something useful for XEmacs, emacs + (verilog-mark-defun): Only do something useful for XEmacs, Emacs does not need it. 2008-01-23 Wilson Snyder @@ -140,13 +139,12 @@ 2008-01-23 Wilson Snyder * progmodes/verilog-mode.el (top-level): Fix spacing. - (verilog-mode-version, verilog-mode-release-date): Update version - number. + (verilog-mode-version, verilog-mode-release-date): + Update version number. (verilog-mode-release-emacs): New variable. - (compile-command, reporter-prompt-for-summary-p): Define for byte - compiler. - (verilog-startup-message-lines) - (verilog-startup-message-displayed) + (compile-command, reporter-prompt-for-summary-p): + Define for byte compiler. + (verilog-startup-message-lines, verilog-startup-message-displayed) (verilog-display-startup-message): Remove. (verilog-highlight-p1800-keywords): Improve docstring. (sigs-in, sigs-out, got-sig, got-rvalue, uses-delayed) @@ -154,9 +152,8 @@ (verilog-highlight-translate-off, verilog-indent-level) (verilog-indent-level-module, verilog-indent-level-declaration) (verilog-indent-declaration-macros, verilog-indent-lists) - (verilog-indent-level-behavioral) - (verilog-indent-level-directive, verilog-cexp-indent) - (verilog-case-indent, verilog-auto-newline) + (verilog-indent-level-behavioral, verilog-indent-level-directive) + (verilog-cexp-indent, verilog-case-indent, verilog-auto-newline) (verilog-auto-indent-on-newline, verilog-tab-always-indent) (verilog-tab-to-comment, verilog-indent-begin-after-if) (verilog-align-ifelse, verilog-minimum-comment-distance) @@ -168,24 +165,20 @@ (verilog-active-low-regexp, verilog-auto-sense-include-inputs) (verilog-auto-sense-defines-constant, verilog-auto-reset-widths) (verilog-assignment-delay, verilog-auto-inst-vector) - (verilog-auto-inst-template-numbers) - (verilog-auto-input-ignore-regexp) - (verilog-auto-inout-ignore-regexp) - (verilog-auto-output-ignore-regexp) - (verilog-auto-unused-ignore-regexp, verilog-typedef-regexp): Add - safe-local-variable properties. - (verilog-statement-menu, verilog-company) - (verilog-re-search-forward, verilog-re-search-backward) - (verilog-error-regexp-add, verilog-end-block-re) - (verilog-emacs-features, verilog-populate-syntax-table) - (verilog-setup-dual-comments, verilog-type-font-keywords) - (verilog-inside-comment-p, electric-verilog-backward-sexp) - (verilog-backward-sexp, verilog-forward-sexp) - (verilog-font-lock-init, verilog-mode) + (verilog-auto-inst-template-numbers, verilog-auto-input-ignore-regexp) + (verilog-auto-inout-ignore-regexp, verilog-auto-output-ignore-regexp) + (verilog-auto-unused-ignore-regexp, verilog-typedef-regexp): + Add safe-local-variable properties. + (verilog-statement-menu, verilog-company, verilog-re-search-forward) + (verilog-re-search-backward, verilog-error-regexp-add) + (verilog-end-block-re, verilog-emacs-features) + (verilog-populate-syntax-table, verilog-setup-dual-comments) + (verilog-type-font-keywords, verilog-inside-comment-p) + (electric-verilog-backward-sexp, verilog-backward-sexp) + (verilog-forward-sexp, verilog-font-lock-init, verilog-mode) (electric-verilog-terminate-line, electric-verilog-semi) - (electric-verilog-tab, verilog-insert-1, ) - (verilog-insert-indices, verilog-generate-numbers) - (verilog-comment-region, verilog-label-be) + (electric-verilog-tab, verilog-insert-1, verilog-insert-indices) + (verilog-generate-numbers, verilog-comment-region, verilog-label-be) (verilog-beg-of-statement, verilog-in-case-region-p) (verilog-in-struct-region-p, verilog-in-generate-region-p) (verilog-in-fork-region-p, verilog-backward-case-item) @@ -198,28 +191,24 @@ (verilog-forward-syntactic-ws, verilog-backward-ws&directives) (verilog-forward-ws&directives, verilog-at-constraint-p) (verilog-skip-backward-comments, verilog-indent-line-relative) - (verilog-do-indent, verilog-indent-comment) - (verilog-more-comment, verilog-pretty-declarations) - (verilog-pretty-expr, verilog-just-one-space) - (verilog-indent-declaration, verilog-get-completion-decl) - (verilog-goto-defun, verilog-showscopes, verilog-header) - (verilog-signals-combine-bus, verilog-read-decls) + (verilog-do-indent, verilog-indent-comment, verilog-more-comment) + (verilog-pretty-declarations, verilog-pretty-expr) + (verilog-just-one-space, verilog-indent-declaration) + (verilog-get-completion-decl, verilog-goto-defun, verilog-showscopes) + (verilog-header, verilog-signals-combine-bus, verilog-read-decls) (verilog-read-always-signals-recurse, verilog-read-instants) (verilog-read-auto-template, verilog-set-define) (verilog-read-defines, verilog-read-signals, verilog-getopt) - (verilog-is-number, verilog-expand-dirnames) - (verilog-modi-lookup, verilog-modi-cache-results) - (verilog-insert-one-definition, verilog-make-width-expression) - (verilog-delete-autos-lined, verilog-auto-save-check) - (verilog-auto-arg, verilog-auto-inst-port, verilog-auto-inst) - (verilog-auto-inst-param, verilog-auto-reg) - (verilog-auto-reg-input, verilog-auto-wire, ) - (verilog-auto-output, verilog-auto-output-every) - (verilog-auto-input, verilog-auto-inout) - (verilog-auto-inout-module, verilog-auto-sense) - (verilog-auto-reset, verilog-auto-tieoff, verilog-auto-unused) - (verilog-auto-ascii-enum, verilog-auto) - (verilog-sk-define-signal, verilog-mode-mouse-map) + (verilog-is-number, verilog-expand-dirnames, verilog-modi-lookup) + (verilog-modi-cache-results, verilog-insert-one-definition) + (verilog-make-width-expression, verilog-delete-autos-lined) + (verilog-auto-save-check, verilog-auto-arg, verilog-auto-inst-port) + (verilog-auto-inst, verilog-auto-inst-param, verilog-auto-reg) + (verilog-auto-reg-input, verilog-auto-wire, verilog-auto-output) + (verilog-auto-output-every, verilog-auto-input, verilog-auto-inout) + (verilog-auto-inout-module, verilog-auto-sense, verilog-auto-reset) + (verilog-auto-tieoff, verilog-auto-unused, verilog-auto-ascii-enum) + (verilog-auto, verilog-sk-define-signal, verilog-mode-mouse-map) (verilog-load-file-at-mouse, verilog-load-file-at-point) (verilog-library-files): Cleanup spacing of )'s they should not be on unique lines. Fix checkdoc warnings. @@ -227,8 +216,7 @@ 2008-01-22 Glenn Morris * progmodes/hideif.el (hide-ifdef-initially, hide-ifdef-read-only) - (hide-ifdef-lines, hide-ifdef-shadow, hide-ifdef-shadow): - Remove autoload cookies. + (hide-ifdef-lines, hide-ifdef-shadow): Remove autoload cookies. * vc.el (vc-diff-sentinel): Do not write a footer if there were differences. @@ -386,7 +374,7 @@ * vc.el: Make vc-status asynchronous. (vc-update-vc-status-buffer): New function broken out of ... - (vc-status-refresh): ... here. Pass vc-update-vc-status-buffer to + (vc-status-refresh): ... here. Pass vc-update-vc-status-buffer to the dir-status backend function. * vc-hg.el (vc-hg-dir-status): Compute the status asynchronously. From 8c8e195273c8aa03aa2b9d953e1ab28a73d33c53 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 24 Jan 2008 11:13:45 +0000 Subject: [PATCH 294/439] (delsel-unload-function): Don't use `remprop'; it is not autoloaded, and we wouldn't want to load CL just to unload delsel.el anyway. Suggested by Martin Rudalics . --- lisp/ChangeLog | 6 ++++++ lisp/delsel.el | 2 +- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ca1387f62c0..a80f7ef4f41 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-24 Juanma Barranquero + + * delsel.el (delsel-unload-function): Don't use `remprop'; it is + not autoloaded, and we wouldn't want to load CL just to unload + delsel.el anyway. Suggested by Martin Rudalics . + 2008-01-24 Martin Rudalics * delsel.el (delete-selection-pre-hook): Avoid clearing out diff --git a/lisp/delsel.el b/lisp/delsel.el index 990ca91ace2..3f9a0c7b32a 100644 --- a/lisp/delsel.el +++ b/lisp/delsel.el @@ -173,7 +173,7 @@ then it takes a second \\[keyboard-quit] to abort the minibuffer." (dolist (sym '(self-insert-command self-insert-iso yank clipboard-yank insert-register delete-backward-char backward-delete-char-untabify delete-char newline-and-indent newline open-line)) - (remprop sym 'delete-selection)) + (put sym 'delete-selection nil)) ;; continue standard unloading nil) From d36122a23ef6b5d37215c7f892cc9e4f938818db Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Thu, 24 Jan 2008 13:09:13 +0000 Subject: [PATCH 295/439] (vc-next-action): Fix two instances of "free-var file" bug: In both cases, convert single call to one wrapped in dolist. --- lisp/ChangeLog | 3 +++ lisp/vc.el | 25 +++++++++++++++++++------ 2 files changed, 22 insertions(+), 6 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index a80f7ef4f41..18baed67097 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -18,6 +18,9 @@ Don't do window resize if no window displays buffer. (vc-diff-internal): Use vc-diff-finish. + * vc.el (vc-next-action): Fix two instances of "free-var file" bug: + In both cases, convert single call to one wrapped in dolist. + 2008-01-24 Dan Nicolaescu * vc.el: Add a TODO item about missing files. diff --git a/lisp/vc.el b/lisp/vc.el index 1bb5c28d530..9d1c6682c4d 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -1564,15 +1564,28 @@ merge in the changes into your working copy." (setq revision (read-string "New revision or backend: ")) (let ((vsym (intern (upcase revision)))) (if (member vsym vc-handled-backends) - (vc-transfer-file file vsym) + (dolist (file files) (vc-transfer-file file vsym)) (vc-checkin ready-for-commit revision)))))))) ;; locked by somebody else (locking VCSes only) ((stringp state) - (let ((revision - (if verbose - (read-string "Revision to steal: ") - (vc-working-revision file)))) - (dolist (file files) (vc-steal-lock file revision state)))) + ;; In the old days, we computed the revision once and used it on + ;; the single file. Then, for the 2007-2008 fileset rewrite, we + ;; computed the revision once (incorrectly, using a free var) and + ;; used it on all files. To fix the free var bug, we can either + ;; use `(car files)' or do what we do here: distribute the + ;; revision computation among `files'. Although this may be + ;; tedious for those backends where a "revision" is a trans-file + ;; concept, it is nonetheless correct for both those and (more + ;; importantly) for those where "revision" is a per-file concept. + ;; If the intersection of the former group and "locking VCSes" is + ;; non-empty [I vaguely doubt it --ttn], we can reinstate the + ;; pre-computation approach of yore. + (dolist (file files) + (vc-steal-lock + file (if verbose + (read-string (format "%s revision to steal: " file)) + (vc-working-revision file)) + state))) ;; needs-patch ((eq state 'needs-patch) (dolist (file files) From ef5e3601471f4796cd04a0881ae241e79abea730 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Thu, 24 Jan 2008 14:12:10 +0000 Subject: [PATCH 296/439] (vc-version-diff): Make sure we shrink the right window. --- lisp/ChangeLog | 4 ++++ lisp/vc.el | 3 ++- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 28d0cc19003..a4c7feae80d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-24 Stefan Monnier + + * vc.el (vc-version-diff): Make sure we shrink the right window. + 2008-01-23 Jason Rumney * lpr.el (printer-name): Do not set on MS Windows. diff --git a/lisp/vc.el b/lisp/vc.el index bbca76e2b90..e7fc52b5019 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -1853,7 +1853,8 @@ versions of all registered files in or below it." (if (eq (buffer-size) 0) (insert "No differences found.\n")) (goto-char (point-min)) - (shrink-window-if-larger-than-buffer))) + (let ((win (get-buffer-window (current-buffer) t))) + (if win (shrink-window-if-larger-than-buffer win))))) t)) (defun vc-diff-label (file file-rev rev) From 845ec007da2bc3b649ca9ecf113fda697e9314cb Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Thu, 24 Jan 2008 15:09:24 +0000 Subject: [PATCH 297/439] (vc-diff-finish): Search all frames for the buffer's window. --- lisp/vc.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/vc.el b/lisp/vc.el index 9d1c6682c4d..35c371a6038 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -1994,7 +1994,7 @@ the buffer contents as a comment." (let ((inhibit-read-only t)) (insert "No differences found.\n"))) (goto-char (point-min)) - (let ((window (get-buffer-window (current-buffer)))) + (let ((window (get-buffer-window (current-buffer) t))) (when window (shrink-window-if-larger-than-buffer window)))))) From a445370f16f05f2b546894908921a5c345c55f94 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Thu, 24 Jan 2008 15:14:52 +0000 Subject: [PATCH 298/439] * sieve.el (sieve-make-overlay, sieve-overlay-put, sieve-overlays-at): * message.el (message-beginning-of-line): Use featurep instead of bound tests in order to resolve conditionals at compile time. * textmodes/reftex-toc.el (reftex-toc-next, reftex-toc-previous) (reftex-toc-restore-region): * textmodes/reftex-index.el (reftex-index-initialize-phrases-buffer) (reftex-index-phrases-apply-to-region): * textmodes/ispell.el (ispell-word): * progmodes/vhdl-mode.el (vhdl-keep-region-active): * progmodes/pascal.el (pascal-mark-defun): * progmodes/f90.el (f90-mark-subprogram, f90-indent-region) (f90-fill-region): * emulation/tpu-edt.el (tpu-set-mark): * emulation/crisp.el (crisp-region-active): * winner.el (winner-active-region): * ansi-color.el (ansi-color-set-extent-face): Use featurep instead of bound tests in order to resolve conditionals at compile time. --- lisp/ChangeLog | 17 +++++++++++++++++ lisp/ansi-color.el | 2 +- lisp/emulation/crisp.el | 2 +- lisp/emulation/tpu-edt.el | 4 +--- lisp/gnus/ChangeLog | 6 ++++++ lisp/gnus/message.el | 2 +- lisp/gnus/sieve.el | 18 +++++++++--------- lisp/progmodes/f90.el | 6 +++--- lisp/progmodes/pascal.el | 4 ++-- lisp/progmodes/vhdl-mode.el | 2 +- lisp/textmodes/ispell.el | 4 ++-- lisp/textmodes/reftex-index.el | 10 ++++++---- lisp/textmodes/reftex-toc.el | 10 +++++----- lisp/winner.el | 2 +- 14 files changed, 56 insertions(+), 33 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 18baed67097..cb0e6acecdf 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,20 @@ +2008-01-24 Dan Nicolaescu + + * textmodes/reftex-toc.el (reftex-toc-next, reftex-toc-previous) + (reftex-toc-restore-region): + * textmodes/reftex-index.el (reftex-index-initialize-phrases-buffer) + (reftex-index-phrases-apply-to-region): + * textmodes/ispell.el (ispell-word): + * progmodes/vhdl-mode.el (vhdl-keep-region-active): + * progmodes/pascal.el (pascal-mark-defun): + * progmodes/f90.el (f90-mark-subprogram, f90-indent-region) + (f90-fill-region): + * emulation/tpu-edt.el (tpu-set-mark): + * emulation/crisp.el (crisp-region-active): + * winner.el (winner-active-region): + * ansi-color.el (ansi-color-set-extent-face): Use featurep instead + of bound tests in order to resolve conditionals at compile time. + 2008-01-24 Juanma Barranquero * delsel.el (delsel-unload-function): Don't use `remprop'; it is diff --git a/lisp/ansi-color.el b/lisp/ansi-color.el index 530325cd24e..db2818f31ed 100644 --- a/lisp/ansi-color.el +++ b/lisp/ansi-color.el @@ -513,7 +513,7 @@ property." (defun ansi-color-set-extent-face (extent face) "Set the `face' property of EXTENT to FACE. XEmacs uses `set-extent-face', Emacs uses `overlay-put'." - (if (fboundp 'set-extent-face) + (if (featurep 'xemacs) (set-extent-face extent face) (overlay-put extent 'face face))) diff --git a/lisp/emulation/crisp.el b/lisp/emulation/crisp.el index b5fd7ee602c..7c254da869a 100644 --- a/lisp/emulation/crisp.el +++ b/lisp/emulation/crisp.el @@ -148,7 +148,7 @@ does not load the scroll-all package." (defun crisp-region-active () "Compatibility function to test for an active region." - (if (boundp 'zmacs-region-active-p) + (if (featurep 'xemacs) zmacs-region-active-p mark-active)) diff --git a/lisp/emulation/tpu-edt.el b/lisp/emulation/tpu-edt.el index ff0e6ad25eb..e9de0409aa4 100644 --- a/lisp/emulation/tpu-edt.el +++ b/lisp/emulation/tpu-edt.el @@ -751,9 +751,7 @@ version of Emacs." Sets the mark at POS and activates the region according to the current version of Emacs." (set-mark pos) - ;; We use a separate `if' for the fboundp so the byte-compiler notices it - ;; and doesn't complain about the subsequent call. - (if (fboundp 'zmacs-activate-region) (if pos (zmacs-activate-region)))) + (when (featurep 'xemacs) (when pos (zmacs-activate-region)))) (defun tpu-string-prompt (prompt history-symbol) "Read a string with PROMPT." diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index dbba5fd608e..35347c8e71a 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog @@ -1,3 +1,9 @@ +2008-01-24 Dan Nicolaescu + + * sieve.el (sieve-make-overlay, sieve-overlay-put, sieve-overlays-at): + * message.el (message-beginning-of-line): Use featurep instead of bound + tests in order to resolve conditionals at compile time. + 2008-01-23 Katsumi Yamaoka * gnus-art.el (gnus-insert-mime-button): Don't decode description. diff --git a/lisp/gnus/message.el b/lisp/gnus/message.el index 731d9924286..273d1c4ec5b 100644 --- a/lisp/gnus/message.el +++ b/lisp/gnus/message.el @@ -5952,7 +5952,7 @@ beginning of header value. Therefore, repeated calls will toggle point between beginning of field and beginning of line." (interactive "p") (let ((zrs 'zmacs-region-stays)) - (when (and (interactive-p) (boundp zrs)) + (when (and (featurep 'xemacs) (interactive-p) (boundp zrs)) (set zrs t))) (if (and message-beginning-of-line (message-point-in-header-p)) diff --git a/lisp/gnus/sieve.el b/lisp/gnus/sieve.el index c05e9d1a356..c32c44ae505 100644 --- a/lisp/gnus/sieve.el +++ b/lisp/gnus/sieve.el @@ -290,15 +290,15 @@ Server : " server ":" (or port "2000") " (get-char-property (or pos (point)) 'script-name)) (eval-and-compile - (defalias 'sieve-make-overlay (if (fboundp 'make-overlay) - 'make-overlay - 'make-extent)) - (defalias 'sieve-overlay-put (if (fboundp 'overlay-put) - 'overlay-put - 'set-extent-property)) - (defalias 'sieve-overlays-at (if (fboundp 'overlays-at) - 'overlays-at - 'extents-at))) + (defalias 'sieve-make-overlay (if (featurep 'xemacs) + 'make-extent + 'make-overlay)) + (defalias 'sieve-overlay-put (if (featurep 'xemacs) + 'set-extent-property + 'overlay-put)) + (defalias 'sieve-overlays-at (if (featurep 'xemacs) + 'extents-at + 'overlays-at))) (defun sieve-highlight (on) "Turn ON or off highlighting on the current language overlay." diff --git a/lisp/progmodes/f90.el b/lisp/progmodes/f90.el index df10b5ecd30..2c152d91512 100644 --- a/lisp/progmodes/f90.el +++ b/lisp/progmodes/f90.el @@ -1681,7 +1681,7 @@ A block is a subroutine, if-endif, etc." (push-mark) (goto-char pos) (setq program (f90-beginning-of-subprogram)) - (if (fboundp 'zmacs-activate-region) + (if (featurep 'xemacs) (zmacs-activate-region) (setq mark-active t deactivate-mark nil)) @@ -1866,7 +1866,7 @@ If run in the middle of a line, the line is not broken." (goto-char save-point) (set-marker end-region-mark nil) (set-marker save-point nil) - (if (fboundp 'zmacs-deactivate-region) + (if (featurep 'xemacs) (zmacs-deactivate-region) (deactivate-mark)))) @@ -1976,7 +1976,7 @@ Like `join-line', but handles F90 syntax." f90-cache-position (point))) (setq f90-cache-position nil) (set-marker end-region-mark nil) - (if (fboundp 'zmacs-deactivate-region) + (if (featurep 'xemacs) (zmacs-deactivate-region) (deactivate-mark)))) diff --git a/lisp/progmodes/pascal.el b/lisp/progmodes/pascal.el index 6dca919ba25..4c33b6b053c 100644 --- a/lisp/progmodes/pascal.el +++ b/lisp/progmodes/pascal.el @@ -523,8 +523,8 @@ This puts the mark at the end, and point at the beginning." (pascal-end-of-defun) (push-mark (point)) (pascal-beg-of-defun) - (if (fboundp 'zmacs-activate-region) - (zmacs-activate-region))) + (when (featurep 'xemacs) + (zmacs-activate-region))) (defun pascal-comment-area (start end) "Put the region into a Pascal comment. diff --git a/lisp/progmodes/vhdl-mode.el b/lisp/progmodes/vhdl-mode.el index 98818ea8354..72fda808053 100644 --- a/lisp/progmodes/vhdl-mode.el +++ b/lisp/progmodes/vhdl-mode.el @@ -2047,7 +2047,7 @@ your style, only those that are different from the default.") (defun vhdl-keep-region-active () "Do whatever is necessary to keep the region active in XEmacs. Ignore byte-compiler warnings you might see." - (and (boundp 'zmacs-region-stays) + (and (featurep 'xemacs) (setq zmacs-region-stays t))) ;; `wildcard-to-regexp' is included only in XEmacs 21 diff --git a/lisp/textmodes/ispell.el b/lisp/textmodes/ispell.el index 813b26ee6e4..fcb1d2444ec 100644 --- a/lisp/textmodes/ispell.el +++ b/lisp/textmodes/ispell.el @@ -1627,7 +1627,7 @@ quit spell session exited." (or quietly (message "%s is correct" (funcall ispell-format-word-function word))) - (and (fboundp 'extent-at) + (and (featurep 'xemacs) (extent-at start) (and (fboundp 'delete-extent) (delete-extent (extent-at start))))) @@ -1636,7 +1636,7 @@ quit spell session exited." (message "%s is correct because of root %s" (funcall ispell-format-word-function word) (funcall ispell-format-word-function poss))) - (and (fboundp 'extent-at) + (and (featurep 'xemacs) (extent-at start) (and (fboundp 'delete-extent) (delete-extent (extent-at start))))) diff --git a/lisp/textmodes/reftex-index.el b/lisp/textmodes/reftex-index.el index 2d489eb5896..15fba461fd3 100644 --- a/lisp/textmodes/reftex-index.el +++ b/lisp/textmodes/reftex-index.el @@ -1243,8 +1243,9 @@ If the buffer is non-empty, delete the old header first." (beginning-of-line 2)) (while (looking-at "^[ \t]*$") (beginning-of-line 2)) - (cond ((fboundp 'zmacs-activate-region) (zmacs-activate-region)) - ((boundp 'make-active) (setq mark-active t))) + (if (featurep 'xemacs) + (zmacs-activate-region) + (setq mark-active t)) (if (yes-or-no-p "Delete and rebuild header? ") (delete-region (point-min) (point)))) @@ -1495,8 +1496,9 @@ index the new part without having to go over the unchanged parts again." (unwind-protect (progn ;; Hide the region highlighting - (cond ((fboundp 'zmacs-deactivate-region) (zmacs-deactivate-region)) - ((fboundp 'deactivate-mark) (deactivate-mark))) + (if (featurep 'xemacs) + (zmacs-deactivate-region) + (deactivate-mark)) (delete-other-windows) (reftex-index-visit-phrases-buffer) (reftex-index-all-phrases)) diff --git a/lisp/textmodes/reftex-toc.el b/lisp/textmodes/reftex-toc.el index 0e501fdf23e..e57e9a59a73 100644 --- a/lisp/textmodes/reftex-toc.el +++ b/lisp/textmodes/reftex-toc.el @@ -326,7 +326,7 @@ SPC=view TAB=goto RET=goto+hide [q]uit [r]escan [l]abels [f]ollow [x]r [?]Help (defun reftex-toc-next (&optional arg) "Move to next selectable item." (interactive "p") - (if (boundp 'zmacs-region-stays) (setq zmacs-region-stays t)) + (when (featurep 'xemacs) (setq zmacs-region-stays t)) (setq reftex-callback-fwd t) (or (eobp) (forward-char 1)) (goto-char (or (next-single-property-change (point) :data) @@ -334,21 +334,21 @@ SPC=view TAB=goto RET=goto+hide [q]uit [r]escan [l]abels [f]ollow [x]r [?]Help (defun reftex-toc-previous (&optional arg) "Move to previous selectable item." (interactive "p") - (if (boundp 'zmacs-region-stays) (setq zmacs-region-stays t)) + (when (featurep 'xemacs) (setq zmacs-region-stays t)) (setq reftex-callback-fwd nil) (goto-char (or (previous-single-property-change (point) :data) (point)))) (defun reftex-toc-next-heading (&optional arg) "Move to next table of contentes line." (interactive "p") - (if (boundp 'zmacs-region-stays) (setq zmacs-region-stays t)) + (when (featurep 'xemacs) (setq zmacs-region-stays t)) (end-of-line) (re-search-forward "^ " nil t arg) (beginning-of-line)) (defun reftex-toc-previous-heading (&optional arg) "Move to previous table of contentes line." (interactive "p") - (if (boundp 'zmacs-region-stays) (setq zmacs-region-stays t)) + (when (featurep 'xemacs) (setq zmacs-region-stays t)) (re-search-backward "^ " nil t arg)) (defun reftex-toc-toggle-follow () "Toggle follow (other window follows with context)." @@ -637,7 +637,7 @@ point." (if mark-line (progn (set-mark mpos) - (if (fboundp 'zmacs-activate-region) + (if (featurep 'xemacs) (zmacs-activate-region) (setq mark-active t deactivate-mark nil))))) diff --git a/lisp/winner.el b/lisp/winner.el index 27b68106a53..5e9d6a3212e 100644 --- a/lisp/winner.el +++ b/lisp/winner.el @@ -51,7 +51,7 @@ '(region-active-p))) (defsetf winner-active-region () (store) - (if (fboundp 'zmacs-activate-region) + (if (featurep 'xemacs) `(if ,store (zmacs-activate-region) (zmacs-deactivate-region)) `(setq mark-active ,store))) From 1c19d20efe080c1ff95764a79bb8a5486c83d446 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Thu, 24 Jan 2008 16:30:53 +0000 Subject: [PATCH 299/439] *** empty log message *** --- lisp/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index cb0e6acecdf..ca688f4a0f6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -305,7 +305,7 @@ 2008-01-21 Juanma Barranquero - * server.el (server-log-time-function): New function. + * server.el (server-log-time-function): New variable. (server-log): Use it. 2008-01-21 Glenn Morris From 42c3e51c12e3a9fde8de77d34e0bf68f92c51551 Mon Sep 17 00:00:00 2001 From: Ken Manheimer Date: Thu, 24 Jan 2008 17:45:28 +0000 Subject: [PATCH 300/439] (allout-keybindings-list): In initial setting, express meta-prefixed allout keys as vectors instead of strings, since the string form is interpreted in some cases as composed key modifiers, eg, accented keys. (allout-line-boundary-regexp): Clarify description. (set-allout-regexp): Repair the expressions so that the formfeed part is identified as one of the top-level groups, and is included in all the forms, not just the -line-boundary-regexp one. (allout-prefix-data): Incorporate information from the various allout regexp's formfeed alternative group, when present. (allout-write-file-hook-handler): Rectify mangling of the error handling. It was broken in 2007-12-06T19:56:41Z!deego@gnufans.org, where an `error' condition-case handler was apparently reformatted as if it was a call to the error function. An apparent repair attempt in version 1.101 situated the original body of the error handling code as bogus condition-case handlers. I've returned to just about the working code that was originally there, removing an unnecessary - but benign - enclosing 'progn'. \(Automated or cursory code fixes often aren't.) (allout-region-active-p): Fallback to value of mark-active if neither use-region-p nor region-active-p are present, for compatability with current and recent emacs major releases. --- lisp/allout.el | 54 +++++++++++++++++++++++++++++++------------------- 1 file changed, 34 insertions(+), 20 deletions(-) diff --git a/lisp/allout.el b/lisp/allout.el index 48371938242..4cdb8735f8a 100644 --- a/lisp/allout.el +++ b/lisp/allout.el @@ -155,11 +155,11 @@ unless optional third, non-nil element is present.") ("*" allout-rebullet-current-heading) ("#" allout-number-siblings) ("\C-k" allout-kill-line t) - ("\M-k" allout-copy-line-as-kill t) + ([?\M-k] allout-copy-line-as-kill t) ("\C-y" allout-yank t) - ("\M-y" allout-yank-pop t) + ([?\M-y] allout-yank-pop t) ("\C-k" allout-kill-topic) - ("\M-k" allout-copy-topic-as-kill) + ([?\M-k] allout-copy-topic-as-kill) ; Miscellaneous commands: ;([?\C-\ ] allout-mark-topic) ("@" allout-resolve-xref) @@ -886,7 +886,7 @@ topic prefix to be matched.") (make-variable-buffer-local 'allout-depth-one-regexp) ;;;_ = allout-line-boundary-regexp (defvar allout-line-boundary-regexp () - "`allout-regexp' with outline style beginning-of-line anchor. + "`allout-regexp' prepended with a newline for the search target. This is properly set by `set-allout-regexp'.") (make-variable-buffer-local 'allout-line-boundary-regexp) @@ -1058,7 +1058,7 @@ Also refresh various data structures that hinge on the regexp." (setq allout-plain-bullets-string-len (length allout-plain-bullets-string)) (setq allout-header-subtraction (1- (length allout-header-prefix))) - (let (new-part old-part) + (let (new-part old-part formfeed-part) (setq new-part (concat "\\(" (regexp-quote allout-header-prefix) "[ \t]*" @@ -1072,18 +1072,26 @@ Also refresh various data structures that hinge on the regexp." "\\)" "+" " ?[^" allout-primary-bullet "]") + formfeed-part "\\(\^L\\)" + allout-regexp (concat new-part "\\|" old-part - "\\|\^l") + "\\|" + formfeed-part) allout-line-boundary-regexp (concat "\n" new-part "\\|" - "\n" old-part) + "\n" old-part + "\\|" + "\n" formfeed-part) allout-bob-regexp (concat "\\`" new-part "\\|" - "\\`" old-part)) + "\\`" old-part + "\\|" + "\\`" formfeed-part + )) (setq allout-depth-specific-regexp (concat "\\(^\\|\\`\\)" @@ -1501,13 +1509,12 @@ See `allout-encryption-ciphertext-rejection-regexps' for rejection reasons.") (condition-case failure (setq allout-after-save-decrypt (allout-encrypt-decrypted except-mark)) - (message "allout-write-file-hook-handler suppressing error %s" - failure) - (sit-for 2) - (error "allout-write-file-hook-handler suppressing error %s" - failure)))) + (error (message + "allout-write-file-hook-handler suppressing error %s" + failure) + (sit-for 2))))) )) - nil) + nil) ;;;_ > allout-auto-save-hook-handler () (defun allout-auto-save-hook-handler () "Implement `allout-encrypt-unencrypted-on-saves' policy for auto save." @@ -2253,9 +2260,10 @@ function can also be used as an `isearch-mode-end-hook'." "Register allout-prefix state data. For reference by `allout-recent' funcs. Returns BEGINNING." - (setq allout-recent-prefix-end (or (match-end 1) (match-end 2)) + (setq allout-recent-prefix-end (or (match-end 1) (match-end 2) (match-end 3)) allout-recent-prefix-beginning (or (match-beginning 1) - (match-beginning 2)) + (match-beginning 2) + (match-beginning 3)) allout-recent-depth (max 1 (- allout-recent-prefix-end allout-recent-prefix-beginning allout-header-subtraction))) @@ -2384,6 +2392,8 @@ Actually, returns prefix beginning point." (defun allout-depth () "Return depth of topic most immediately containing point. +Does not do doublecheck for aberrant topic header. + Return zero if point is not within any topic. Like `allout-current-depth', but respects hidden as well as visible topics." @@ -2572,10 +2582,14 @@ We skip anomolous low-level topics, a la `allout-aberrant-container-p'." (when (re-search-forward allout-line-boundary-regexp nil 0) (allout-prefix-data) + (goto-char allout-recent-prefix-beginning) + (while (not (bolp)) + (forward-char -1)) (and (allout-do-doublecheck) ;; this will set allout-recent-* on the first non-aberrant topic, ;; whether it's the current one or one that disqualifies it: (allout-aberrant-container-p)) + ;; this may or may not be the same as above depending on doublecheck: (goto-char allout-recent-prefix-beginning)))) ;;;_ > allout-this-or-next-heading (defun allout-this-or-next-heading () @@ -5459,10 +5473,10 @@ header and body. The elements of that list are: (nreverse result)))) ;;;_ > allout-region-active-p () (defmacro allout-region-active-p () - (if (fboundp 'use-region-p) - '(use-region-p) - '(region-active-p))) -;;;_ > allout-process-exposed (&optional func from to frombuf + (cond ((fboundp 'use-region-p) '(use-region-p)) + ((fboundp 'region-active-p) '(region-active-p)) + (t 'mark-active))) +;;_ > allout-process-exposed (&optional func from to frombuf ;;; tobuf format) (defun allout-process-exposed (&optional func from to frombuf tobuf format start-num) From 3bcdc5706015ed8797293008da81438521f48512 Mon Sep 17 00:00:00 2001 From: Ken Manheimer Date: Thu, 24 Jan 2008 17:53:29 +0000 Subject: [PATCH 301/439] * allout.el (allout-keybindings-list): Use vectors instead of strings for keys. (allout-line-boundary-regexp): (set-allout-regexp): (allout-prefix-data): Repair handling of formfeeds as header prefix. (allout-write-file-hook-handler): Repair mangling of error handling. (allout-region-active-p): Fallback to mark-active. --- lisp/ChangeLog | 30 ++++++++++++++++++++++++++++++ 1 file changed, 30 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ca688f4a0f6..4e8c1cabfe6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,33 @@ +2008-01-24 Ken Manheimer + + * allout.el (allout-keybindings-list): In initial setting, express + meta-prefixed allout keys as vectors instead of strings, since the + string form is interpreted in some cases as composed key + modifiers, eg, accented keys. + + (allout-line-boundary-regexp): Clarify description. + + (set-allout-regexp): Repair the expressions so that the formfeed + part is identified as one of the top-level groups, and is + included in all the forms, not just the -line-boundary-regexp one. + + (allout-prefix-data): Incorporate information from the various + allout regexp's formfeed alternative group, when present. + + (allout-write-file-hook-handler): Rectify mangling of the error + handling. It was broken in 2007-12-06T19:56:41Z!deego@gnufans.org, where an `error' + condition-case handler was apparently reformatted as if it was a + call to the error function. An apparent repair attempt in version + 1.101 situated the original body of the error handling code as + bogus condition-case handlers. I've returned to just about the + working code that was originally there, removing an unnecessary - + but benign - enclosing 'progn'. \(Automated or cursory code fixes + often aren't.) + + (allout-region-active-p): Fallback to value of mark-active if + neither use-region-p nor region-active-p are present, for + compatability with current and recent emacs major releases. + 2008-01-24 Dan Nicolaescu * textmodes/reftex-toc.el (reftex-toc-next, reftex-toc-previous) From a8ed19cada1fb67dd87abf39a39d9d1c4d7ebbe6 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Thu, 24 Jan 2008 18:45:04 +0000 Subject: [PATCH 302/439] Rewrite entry to protect it against revisionists. --- lisp/ChangeLog | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4e8c1cabfe6..761a8fa3f81 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -272,7 +272,9 @@ 2008-01-22 Glenn Morris * progmodes/hideif.el (hide-ifdef-initially, hide-ifdef-read-only) - (hide-ifdef-lines, hide-ifdef-shadow): Remove autoload cookies. + (hide-ifdef-lines, hide-ifdef-shadow): Remove autoload cookies + from defcustoms. + (hide-ifdef-shadow): Remove autoload cookie from defface. * vc.el (vc-diff-sentinel): Do not write a footer if there were differences. From 484ea0b6c9e54a6e58bbf240bd723161c4d6d4cf Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Thu, 24 Jan 2008 21:28:56 +0000 Subject: [PATCH 303/439] * net/tramp.el (tramp-do-copy-or-rename-file): Flush the cache of the source file in case of `rename'. Reported by Pete Forman . --- lisp/ChangeLog | 6 ++++++ lisp/net/tramp.el | 5 +++++ 2 files changed, 11 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 761a8fa3f81..2cc13c1c664 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-24 Michael Albinus + + * net/tramp.el (tramp-do-copy-or-rename-file): Flush the cache of + the source file in case of `rename'. Reported by Pete Forman + . + 2008-01-24 Ken Manheimer * allout.el (allout-keybindings-list): In initial setting, express diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 7c3153fc0be..4aa092ad704 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -3034,6 +3034,11 @@ and `rename'. FILENAME and NEWNAME must be absolute file names." ;; One of them must be a Tramp file. (error "Tramp implementation says this cannot happen"))) + ;; In case of `rename', we must flush the cache of the source file. + (when (and t1 (eq op 'rename)) + (with-parsed-tramp-file-name filename nil + (tramp-flush-file-property v localname))) + ;; When newname did exist, we have wrong cached values. (when t2 (with-parsed-tramp-file-name newname nil From 2bc439803ecbf40814ca67c5b496f257c2be239f Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Fri, 25 Jan 2008 00:58:40 +0000 Subject: [PATCH 304/439] consistently mention command keys in section names --- doc/misc/ChangeLog | 6 ++++++ doc/misc/info.texi | 4 ++-- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index 47e521f537c..b8cb040f322 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,9 @@ +2008-01-24 Karl Berry + + * info.texi (Search Index), + (Search Text): mention the command character in the section name, + a la the (Go to node) node. + 2008-01-21 Michael Albinus * dbus.texi (Errors and Events): New macro dbus-ignore-errors. diff --git a/doc/misc/info.texi b/doc/misc/info.texi index cad33e79bcc..89229d61cd7 100644 --- a/doc/misc/info.texi +++ b/doc/misc/info.texi @@ -970,7 +970,7 @@ an actual @samp{?} character, the simplest way is to insert it using @node Search Text, Search Index, , Advanced @comment node-name, next, previous, up -@section How to search Info documents +@section @kbd{s} searches Info documents @cindex searching Info documents @cindex Info document as a reference @@ -1018,7 +1018,7 @@ by setting the variable @code{Info-isearch-search} to @code{nil} @node Search Index, Go to node, Search Text, Advanced @comment node-name, next, previous, up -@section How to search the indices for specific subjects +@section @kbd{i} searches the indices for specific subjects @cindex searching Info indices @kindex i @r{(Info mode)} From 83665af36e1209d25f999121ab9c320a9f0f4295 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Fri, 25 Jan 2008 01:09:01 +0000 Subject: [PATCH 305/439] *** empty log message *** --- lisp/ChangeLog.6 | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/ChangeLog.6 b/lisp/ChangeLog.6 index 781122dcb29..2fff1f9a85f 100644 --- a/lisp/ChangeLog.6 +++ b/lisp/ChangeLog.6 @@ -2769,7 +2769,7 @@ (gnus-request-accept-article): Make sure there's a newline at the end of the buffer. (gnus-adjust-marked-articles): Don't remove illegal ticked - articles (for forwards compatability). + articles (for forwards compatibility). 1996-02-03 Lars Magne Ingebrigtsen From 75bcb912ca11e772c239f1bb9a35f41d2f2725c1 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Fri, 25 Jan 2008 02:18:05 +0000 Subject: [PATCH 306/439] (allout-prefix-data): Doc fix. (allout-show-current-subtree): Reflow docstring. (allout-use-mode-specific-leader, allout-use-hanging-indents, produce-allout-mode-map, allout-overlay-interior-modification-handler, allout-next-heading, allout-previous-heading, allout-rebullet-heading, allout-rebullet-topic, allout-rebullet-topic-grunt, allout-kill-topic, allout-copy-topic-as-kill, allout-listify-exposed, allout-process-exposed, allout-encrypted-key-info, allout-update-passphrase-mnemonic-aids, allout-next-topic-pending-encryption, allout-tests-globally-true): Fix typos in docstrings. --- lisp/ChangeLog | 16 +++++++++++++++- lisp/allout.el | 51 +++++++++++++++++++++++++------------------------- 2 files changed, 41 insertions(+), 26 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index a4c7feae80d..28b1f7dc905 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,17 @@ +2008-01-25 Juanma Barranquero + + * allout.el (allout-prefix-data): Doc fix. + (allout-show-current-subtree): Reflow docstring. + (allout-use-mode-specific-leader, allout-use-hanging-indents) + (produce-allout-mode-map, allout-overlay-interior-modification-handler) + (allout-next-heading, allout-previous-heading, allout-rebullet-heading) + (allout-rebullet-topic, allout-rebullet-topic-grunt, allout-kill-topic) + (allout-copy-topic-as-kill, allout-listify-exposed) + (allout-process-exposed, allout-encrypted-key-info) + (allout-update-passphrase-mnemonic-aids) + (allout-next-topic-pending-encryption) + (allout-tests-globally-true): Fix typos in docstrings. + 2008-01-24 Stefan Monnier * vc.el (vc-version-diff): Make sure we shrink the right window. @@ -29,7 +43,7 @@ * progmodes/python.el: Quote all calls to "auxiliary skeleton"s to prevent infloops. -2008-01-20 Martin Svenson (tiny change) +2008-01-20 Martin Svenson (tiny change) * progmodes/python.el (python-imports): Default to "None". diff --git a/lisp/allout.el b/lisp/allout.el index dbaef725c13..43642e6ee26 100644 --- a/lisp/allout.el +++ b/lisp/allout.el @@ -395,7 +395,7 @@ comment-start strings that do not end in spaces are tripled in the header-prefix, and an `_' underscore is tacked on the end, to distinguish them from regular comment strings. comment-start strings that do end in spaces are not tripled, but an underscore -is substituted for the space. [This presumes that the space is +is substituted for the space. [This presumes that the space is for appearance, not comment syntax. You can use `allout-mode-leaders' to override this behavior, when undesired.]" @@ -747,7 +747,7 @@ else allout's special hanging-indent maintaining auto-fill function, (defcustom allout-use-hanging-indents t "*If non-nil, topic body text auto-indent defaults to indent of the header. Ie, it is indented to be just past the header prefix. This is -relevant mostly for use with indented-text-mode, or other situations +relevant mostly for use with `indented-text-mode', or other situations where auto-fill occurs." :type 'boolean :group 'allout) @@ -1124,10 +1124,10 @@ Also refresh various data structures that hinge on the regexp." (defvar allout-mode-map nil "Keybindings for (allout) outline minor mode.") ;;;_ > produce-allout-mode-map (keymap-alist &optional base-map) (defun produce-allout-mode-map (keymap-list &optional base-map) - "Produce keymap for use as allout-mode-map, from KEYMAP-LIST. + "Produce keymap for use as `allout-mode-map', from KEYMAP-LIST. Built on top of optional BASE-MAP, or empty sparse map if none specified. -See doc string for allout-keybindings-list for format of binding list." +See doc string for `allout-keybindings-list' for format of binding list." (let ((map (or base-map (make-sparse-keymap))) (pref (list allout-command-prefix))) (mapcar (function @@ -2140,10 +2140,10 @@ OPEN: A TOPIC that is not CLOSED, though its OFFSPRING or BODY may be." "Get confirmation before making arbitrary changes to invisible text. We expose the invisible text and ask for confirmation. Refusal or -keyboard-quit abandons the changes, with keyboard-quit additionally +`keyboard-quit' abandons the changes, with keyboard-quit additionally reclosing the opened text. -No confirmation is necessary when inhibit-read-only is set - eg, allout +No confirmation is necessary when `inhibit-read-only' is set - eg, allout internal functions use this feature cohesively bunch changes." (when (and (not inhibit-read-only) (not after)) @@ -2234,7 +2234,8 @@ function can also be used as an `isearch-mode-end-hook'." (defsubst allout-prefix-data () "Register allout-prefix state data. -For reference by `allout-recent' funcs. Returns BEGINNING." +For reference by `allout-recent' funcs. Return +the new value of `allout-recent-prefix-beginning'." (setq allout-recent-prefix-end (or (match-end 1) (match-end 2)) allout-recent-prefix-beginning (or (match-beginning 1) (match-beginning 2)) @@ -2535,7 +2536,7 @@ Outermost is first." Returns the location of the heading, or nil if none found. -We skip anomolous low-level topics, a la `allout-aberrant-container-p'." +We skip anomalous low-level topics, a la `allout-aberrant-container-p'." (if (looking-at allout-regexp) (forward-char 1)) @@ -2558,7 +2559,7 @@ We skip anomolous low-level topics, a la `allout-aberrant-container-p'." Return the location of the beginning of the heading, or nil if not found. -We skip anomolous low-level topics, a la `allout-aberrant-container-p'." +We skip anomalous low-level topics, a la `allout-aberrant-container-p'." (if (bobp) nil @@ -3924,9 +3925,9 @@ Third arg NUMBER-CONTROL can force the prefix to or away from numbered form. It has effect only if `allout-numbered-bullet' is non-nil and soliciting was not explicitly invoked (via first arg). Its effect, numbering or denumbering, then depends on the setting -of the forth arg, INDEX. +of the fourth arg, INDEX. -If NUMBER-CONTROL is non-nil and forth arg INDEX is nil, then the +If NUMBER-CONTROL is non-nil and fourth arg INDEX is nil, then the prefix of the topic is forced to be non-numbered. Null index and non-nil NUMBER-CONTROL forces denumbering. Non-nil INDEX (and non-nil NUMBER-CONTROL) forces a numbered-prefix form. If non-nil @@ -4010,7 +4011,7 @@ this function." Descends into invisible as well as visible topics, however. -When optional sans-offspring is non-nil, subtopics are not +When optional SANS-OFFSPRING is non-nil, subtopics are not shifted. (Shifting a topic outwards without shifting its offspring is disallowed, since this would create a \"containment discontinuity\", where the depth difference between a topic and @@ -4055,7 +4056,7 @@ Finally, if optional SANS-OFFSPRING is non-nil then the offspring are not shifted. (Shifting a topic outwards without shifting its offspring is disallowed, since this would create a \"containment discontinuity\", where the depth difference between -a topic and its immediate offspring is greater than one..)" +a topic and its immediate offspring is greater than one.)" ;; XXX the recursion here is peculiar, and in general the routine may ;; need simplification with refactoring. @@ -4341,7 +4342,7 @@ Trailing whitespace is killed with a topic if that whitespace: previous one. Topic exposure is marked with text-properties, to be used by -allout-yank-processing for exposure recovery." +`allout-yank-processing' for exposure recovery." (interactive) (let* ((inhibit-field-text-motion t) @@ -4372,7 +4373,7 @@ allout-yank-processing for exposure recovery." (run-hook-with-args 'allout-structure-deleted-hook depth (point)))) ;;;_ > allout-copy-topic-as-kill () (defun allout-copy-topic-as-kill () - "Like allout-kill-topic, but save to kill ring instead of deleting." + "Like `allout-kill-topic', but save to kill ring instead of deleting." (interactive) (let ((buffer-read-only t)) (condition-case nil @@ -4874,8 +4875,8 @@ Useful for coherently exposing to a random point in a hidden region." ))) ;;;_ > allout-show-current-subtree (&optional arg) (defun allout-show-current-subtree (&optional arg) - "Show everything within the current topic. With a repeat-count, -expose this topic and its siblings." + "Show everything within the current topic. +With a repeat-count, expose this topic and its siblings." (interactive "P") (save-excursion (if (<= (allout-current-depth) 0) @@ -5288,7 +5289,7 @@ the subject region. Optional START and END indicate bounds of region. -optional arg, FORMAT, designates an alternate presentation form for +Optional arg, FORMAT, designates an alternate presentation form for the prefix: list - Present prefix as numeric section.subsection..., starting with @@ -5418,7 +5419,7 @@ FROMBUF to buffer TOBUF. Sixth optional arg, FORMAT, designates an alternate presentation form: `flat' - Present prefix as numeric section.subsection..., starting with - section indicated by the start-num, innermost nesting first. + section indicated by the START-NUM, innermost nesting first. X`flat-indented' - Prefix is like `flat' for first topic at each X level, but subsequent topics have only leaf topic X number, padded with blanks to line up with first. @@ -6292,8 +6293,8 @@ of the availability of a cached copy." The key type is one of 'symmetric or 'keypair. -if 'keypair, and some of the user's secret keys are among those for which -the message was encoded, return the identity of the first. otherwise, +If 'keypair, and some of the user's secret keys are among those for which +the message was encoded, return the identity of the first. Otherwise, return nil for the second item of the pair. An error is raised if the text is not encrypted." @@ -6338,7 +6339,7 @@ An error is raised if the text is not encrypted." See `allout-passphrase-verifier-string' and `allout-passphrase-hint-string' settings. -PASSPHRASE is the passphrase being mnemonicized +PASSPHRASE is the passphrase being mnemonicized. OUTLINE-BUFFER is the buffer of the outline being adjusted. @@ -6416,7 +6417,7 @@ EXCEPT-MARK identifies a point whose containing topics should be excluded from encryption. This supports 'except-current mode of `allout-encrypt-unencrypted-on-saves'. -Such a topic has the allout-topic-encryption-bullet without an +Such a topic has the `allout-topic-encryption-bullet' without an immediately following '*' that would mark the topic as being encrypted. It must also have content." (let (done got content-beg) @@ -6746,7 +6747,7 @@ If BEG is bigger than END we return 0." (cond ((null list) nil) ((atom (car list)) (cons (car list) (allout-flatten (cdr list)))) (t (append (allout-flatten (car list)) (allout-flatten (cdr list)))))) -;;;_ : Compatability: +;;;_ : Compatibility: ;;;_ > allout-mark-marker to accommodate divergent emacsen: (defun allout-mark-marker (&optional force buffer) "Accommodate the different signature for `mark-marker' across Emacsen. @@ -6938,7 +6939,7 @@ To ignore intangibility, bind `inhibit-point-motion-hooks' to t." (defvar allout-tests-globally-unbound nil "Fodder for allout resumptions tests - defvar just for byte compiler.") (defvar allout-tests-globally-true nil - "Fodder for allout resumptions tests - defvar just just for byte compiler.") + "Fodder for allout resumptions tests - defvar just for byte compiler.") (defvar allout-tests-locally-true nil "Fodder for allout resumptions tests - defvar just for byte compiler.") (defun allout-test-resumptions () From 409dd1209d15594d85ba083f4954bcc541594c9f Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Fri, 25 Jan 2008 02:46:19 +0000 Subject: [PATCH 307/439] Regnerate configure. --- configure | 8 +------- 1 file changed, 1 insertion(+), 7 deletions(-) diff --git a/configure b/configure index 26a5a8ba152..4d17d14802e 100755 --- a/configure +++ b/configure @@ -11543,8 +11543,6 @@ _ACEOF fi HAVE_DBUS=no -{ echo "$as_me:$LINENO: checking maybe dbus" >&5 -echo $ECHO_N "checking maybe dbus... $ECHO_C" >&6; } if test "${with_dbus}" = "yes"; then succeeded=no @@ -11647,11 +11645,6 @@ cat >>confdefs.h <<\_ACEOF _ACEOF fi - { echo "$as_me:$LINENO: result: $HAVE_DBUS" >&5 -echo "${ECHO_T}$HAVE_DBUS" >&6; } -else - { echo "$as_me:$LINENO: result: no bub" >&5 -echo "${ECHO_T}no bub" >&6; } fi ### Link with -lXft if available to work around a bug. @@ -23450,6 +23443,7 @@ echo " Does Emacs use a gif library? ${HAVE_GIF} $ac_ echo " Does Emacs use -lpng? ${HAVE_PNG}" echo " Does Emacs use -lrsvg-2? ${HAVE_RSVG}" echo " Does Emacs use -lgpm? ${HAVE_GPM}" +echo " Does Emacs use -ldbus? ${HAVE_DBUS}" echo " Does Emacs use X toolkit scroll bars? ${USE_TOOLKIT_SCROLL_BARS}" echo From 5e56b3fb5aac96b5a65800da0495cef072388edf Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Fri, 25 Jan 2008 03:28:10 +0000 Subject: [PATCH 308/439] ERC: Sync version 5.3, release candidate 1. --- etc/ChangeLog | 4 + etc/ERC-NEWS | 231 +++++++- lisp/erc/ChangeLog | 1096 +++++++++----------------------------- lisp/erc/ChangeLog.07 | 839 +++++++++++++++++++++++++++++ lisp/erc/erc-backend.el | 31 +- lisp/erc/erc-button.el | 26 +- lisp/erc/erc-compat.el | 47 -- lisp/erc/erc-dcc.el | 133 +++-- lisp/erc/erc-goodies.el | 82 ++- lisp/erc/erc-list.el | 227 ++++++++ lisp/erc/erc-networks.el | 16 +- lisp/erc/erc-page.el | 8 +- lisp/erc/erc-replace.el | 11 +- lisp/erc/erc-services.el | 11 + lisp/erc/erc-track.el | 135 +++-- lisp/erc/erc-xdcc.el | 13 +- lisp/erc/erc.el | 150 ++++-- 17 files changed, 2022 insertions(+), 1038 deletions(-) create mode 100644 lisp/erc/ChangeLog.07 create mode 100644 lisp/erc/erc-list.el diff --git a/etc/ChangeLog b/etc/ChangeLog index 8e783c871fb..655ce0c74fd 100644 --- a/etc/ChangeLog +++ b/etc/ChangeLog @@ -1,3 +1,7 @@ +2008-01-25 Michael Olson + + * ERC-NEWS: Update for ERC 5.3 release candidate. + 2008-01-22 Juanma Barranquero * DEVEL.HUMOR: New entry. diff --git a/etc/ERC-NEWS b/etc/ERC-NEWS index 450b1cdcf83..ec348a450f6 100644 --- a/etc/ERC-NEWS +++ b/etc/ERC-NEWS @@ -15,14 +15,237 @@ of ERC that comes with Emacs. `erc-join-channel' now accepts a prefix-argument to prompt for the key when channels are protected by keywords. +** ERC will now automatically determine which nick prefixes are valid +when joining a server. + +** Figure out which directory contains startup files when looking for +.erc.el. For Emacs this is usually ~/.emacs.d, and for XEmacs this is +usually ~/.xemacs. + +** Fix bug with view-mode when running erc-toggle-debug-irc-protocol. + +** Permit several commands to be run even when the server connection is dead. +This includes /CLEAR, /COUNTRY, /HELP, /LASTLOG, /QUIT, /GQUIT, +/RECONNECT, /SERVER, and /SET. + +** Make /RECONNECT work better when the server connection is dead. +Also, handle case where the server buffer has been killed. + +** Better handle interaction with /RECONNECT and indefinite reconnect +attempts. Display message which tells the user that they can stop the +reconnect attempts by killing the server buffer. + +** New option `erc-reuse-frames' determines whether new frames are always +created. It defaults to not creating a new frame for an ERC buffer if +there is already a window displaying it. This only has an effect when +the `erc-join-buffer' option is set to 'frame. + +** New command /ME'S handles the case where someone types "/me's" in an +ERC buffer. It concatenates the text " 's" to the beginning of the +input and then sends the result like a normal /ME command. + +** Fix bug where some messages were being sent to the server too soon. +In the past, this may have resulted in strange problems like seeing +the connection attempt stall, which may have especially affected +spotty or traffic-shaped connections. + +** Handle 307 (nick has identified) responses from the server. + +** Display a less-confusing message if the connection attempt fails. + +** On a tty, make sure that notices are displayed in blue rather than pink. + +** By default, open query buffers that are initiated by others in a new +unselected window. This may be changed by customizing the +`erc-auto-query' option. This should make ERC more friendly to new +users. + +** New option `erc-query-display' indicates how to display a query buffer +that is made using the /QUERY command. The default is to display the +query in a new selected window. + +** By default, display network name rather than server name in the modeline. +This should ERC use less space in the modeline. To get the old +behavior back, set `erc-mode-line-format' to "%s %a". + +** New option `erc-remove-parsed-property' determines whether to remove +the 'erc-parsed property. This should save some memory in channels +with large amounts of text on screen. It is enabled by default. + +** Modules newly enabled by default + +*** move-to-prompt: Move to the prompt when typing text. +*** networks: Provide data about IRC networks. + +** New formatting variables allowed in `erc-format-network': + +*** `%N': the name of the network. +*** `%S': much like %s, but let the network name trump the server name. + +** Compatibility with old releases + +*** In `erc-server-coding-system' and `erc-coding-system-for-target', pass +the `target' argument as the first and only argument to the function +named by these options. + +*** In `erc-track-faces-priority-list', permit list entries to be lists of +faces. This can be used to differentiate between, for example, +buttons in default text and buttons in notices. + +*** The `erc-assert' function has been removed in favor of using `assert' +from cl-macs.el. + +*** If your application uses the 'erc-parsed text property outside of +the insert hooks, you will need to set `erc-remove-parsed-property' +to nil. + ** Changes and additions to modules +*** BBDB (erc-bbdb.el) + +**** Work around bug in XEmacs 21.4 that causes an error to be thrown when +the first argument to `run-at-time' is nil. + +*** Button (erc-button.el) + +**** Recognize parentheses that are part of URLs. + +**** When in a channel, only buttonize nicks from that channel. + +*** DCC support (erc-dcc.el) + +**** Turn this into the "dcc" module for ERC, so that it can be more +easily enabled. + +**** New option `erc-dcc-listen-host' determines which IP address to listen +on for outside connection attempts. + +**** New option `erc-dcc-public-host' determines which IP address to advertise +when sending a file. This is useful for people who are on a local +subnet. Together, these two options replace the `erc-dcc-host' +option. + +**** New option `erc-dcc-receive-cache' indicates how much of a received +file to store in an Emacs buffer before flushing it to disk. The +default is 0.5 MB. + +**** Save only parts of received files in buffers, writing repeatedly to +disk after we get at least `erc-dcc-receive-cache' bytes. This allows +users to receive very large files without running out of memory. + +**** Rename `erc-verbose-dcc' option to `erc-dcc-verbose' and also +default it to nil. + +**** Fix edge case in erc-dcc-send-sentinel. + +**** If client confirms too much, then display byte count and kill the +file buffer. + +*** Goodies (erc-goodies.el) + +**** New module move-to-prompt causes the point to be moved to the prompt +if a user tries to type elsewhere in the buffer, and then inserts +their keystrokes after the prompt. It is enabled by default. + +**** New module keep-place keeps your place in unvisited ERC buffers +when new messages arrive. + +**** Enable scroll-to-bottom in all ERC buffers when the module is enabled, +rather than having the user do it manually. + +**** Fix bug with buffer ordering and scroll-to-bottom module. + +**** In the unmorse module, handle the morse code style that has "/ " at +the end of every letter. + +*** Identd (erc-identd.el) + +**** Fix bad behavior when closing the identd process. + +*** Channel lists (erc-list.el) + +**** Replace the old module with a rewritten one, so that we can include +it with Emacs. The old version of erc-list.el has been renamed to +erc-list-old.el, and is available as the list-old module. + +The new version does not yet have support for XEmacs. + +**** Don't display lots of output in the server buffer when running /LIST. + +*** Logging (erc-log.el) + +**** Permit the `erc-log-channels-directory' option to be set to a function +name. This makes it easier to write custom functions that determine +where log files should be placed. + +**** New option `erc-log-filter-function' specifies the function to call +for filtering text before writing it to a log file. By default, no +filtering is performed. + +*** Networks (erc-networks.el) + +**** Turn this into the "networks" module for ERC, so that it can be more +easily enabled. Enable it by default. + +**** Add support for Rizon. + +*** Internet services / Nickserv (erc-services.el) + +**** New hook option `erc-nickserv-identified-hook' is run after NickServ +acknowledges a successful identification. + +**** Add support for the GRnet and Rizon networks. + +*** Timestamps (erc-stamp.el) + +**** By default, place timestamps on both the left and the right. +The left timestamps appear once a day, and the right timestamps appear +once a minute when new messages arrive. To change this, customize the +`erc-insert-timestamp-function' and +`erc-insert-away-timestamp-function' options. + *** Channel tracking (erc-track.el) -If erc-track-position-in-mode-line is set to nil, the tracking -information won't be shown in the mode line, which is a change -from the previous behavior of showing it "After all other -information". +**** If `erc-track-position-in-mode-line' is set to nil, the tracking +information won't be shown in the mode line, which is a change from +the previous behavior of showing it "After all other information". + +If this variable is set to t, then the information will be added to +the very end of the mode line. + +**** New option `erc-track-remove-disconnected-buffers' controls whether +buffers associated with a server that is disconnected should be +removed from the modified buffers list. The default is to keep them +in the list. + +**** New hook option `erc-track-list-changed-hook' is run whenever the +contents of the modified channels list changes. It is useful for +people who use a separate mechanism to provide notification of channel +activity. + +**** The `erc-track-switch-direction' option now can be set to the value +'importance. If set to this value, ERC will switch to channels in +order of importance, which is determined by the position of the +channel's face in `erc-track-faces-priority-list'. + +**** Activate erc-track-minor-mode earlier in the connection process. + +**** Don't track buttons in notices. + +**** Get a rough idea for which channels are currently active by +switching between several normal conversation faces in the modeline. +This behavior can be modified by changing the new +`erc-track-faces-normal-list' option. + +**** Ignore display of who set the default channel topic and listing of +users on the current channel. Customize the `erc-track-exclude-types' +option to indicate the types of messages to exclude. These two +message types are "333" and "353", respectively. + +*** Support for acting as an XDCC file-server (erc-xdcc.el) + +**** Turn this into the "xdcc" module for ERC, so that it can be more +easily enabled. * Changes in ERC 5.2 diff --git a/lisp/erc/ChangeLog b/lisp/erc/ChangeLog index 2e8fb250018..cddd0f845b6 100644 --- a/lisp/erc/ChangeLog +++ b/lisp/erc/ChangeLog @@ -1,843 +1,271 @@ +2008-01-25 Michael Olson + + * NEWS: Update. + + * erc-goodies.el (keep-place): New module which keeps your place + in unvisited ERC buffers when new messages arrive. This is mostly + taken from Johan BockgÃ¥rd's init file. + (erc-noncommands-list): Move to correct place. + + * erc-networks.el: Add a module definition. + + * erc-services.el (erc-nickserv-identify-mode): Force-enable the + networks module, because we need it to set erc-network for us. + + * erc-track.el (erc-track-faces-normal-list): Indicate in the + docstring that this variable can be set to nil. + + * erc.el: On second thought, don't load erc-networks. Just enable + the networks module by default. + (erc-modules): Add option for keep-place and networks. Enable + networks by default. + (erc-version-string): Make release candidate 1 available. + +2008-01-24 Michael Olson + + * erc.el: Load erc-networks.el so that functions get access to the + `erc-network-name' function. + + * erc-track.el (erc-track-faces-normal-list): Add + erc-dangerous-host-face. + (erc-track-exclude-types): Add 333 and 353 to the default list of + things to ignore, and explain what they are in the docstring. + +2008-01-23 Michael Olson + + * erc-track.el (erc-track-faces-priority-list): Move + erc-nick-default-face higher, so that it can be used for the + activity indication effect. Add erc-current-nick-face, + erc-pal-face, erc-dangerous-host-face, and erc-fool-face by + themselves. + (erc-track-faces-normal-list): New option that contains a list of + faces to consider "normal". + (erc-track-position-in-mode-line): Minor docfix. + (erc-track-find-face): Use erc-track-faces-normal-list to produce + a sort of blinking activity effect. + +2008-01-22 Michael Olson + + * erc-button.el (erc-button-add-nickname-buttons): When in a + channel buffer, only look at nicks from the current channel. + Thanks to e1f for the report. + +2008-01-21 Michael Olson + + * erc-compat.el (erc-const-expr-p, erc-list*, erc-assert): Remove, + since we can use the default `assert' function without it causing + us any problems, even in Emacs 21. Thanks to bojohan for the + suggestion. + + * erc-goodies.el (move-to-prompt): Use the "XEmacs" method + instead, because the [remap ...] method interferes with + delete-selection-mode. + (erc-move-to-prompt): Rename from erc-move-to-prompt-xemacs. + Deactivate mark and call push-mark before moving point. Thanks to + bojohan for the suggestion. + (erc-move-to-prompt-setup): Rename from + erc-move-to-prompt-init-xemacs. + + * erc-track.el (erc-track-faces-priority-list): Replace erc-button + with '(erc-button erc-default-face) so that we only care about + buttons that are part of normal text. Adjust customization type + to handle this case. Make erc-nick-default-face a list. Handle + pals, fools, current nick, and dangerous hosts. + (erc-track-find-face): Simplify. Adapt for list of faces case. + (erc-faces-in): Don't deflate lists of faces. Add them as-is. + (erc-track-face-priority): Use equal instead of eq. + +2008-01-20 Michael Olson + + * erc-goodies.el (erc-move-to-prompt, erc-move-to-prompt-xemacs): + Fix off-by-one error that caused the point to move when placed at + the beginning of some already-typed text. Thanks to e1f for the + report. + + * erc-dcc.el, erc-xdcc.el: Add simple module definitions. + + * erc.el (erc-modules): Add dcc and xdcc. + +2008-01-19 Michael Olson + + * erc-bbdb.el (erc-bbdb-insinuate-and-show-entry): Work around bug + in XEmacs 21.4 that throws an error when the first argument to + run-at-time is nil. + + * erc-button.el (button): Undo XEmacs-specific change to all ERC + buffers when module is removed. + (erc-button-setup): Rename from erc-button-add-keys, and move + XEmacs-specific stuff here. + + * erc-goodies.el (erc-unmorse): Improve regexp for detecting + morse. Deal with the morse style that has "/ " at the end of + every letter. + (erc-imenu-setup): New function that sets up Imenu support. Add + it instead of a lambda form to erc-mode-hook. + (scrolltobottom): Remove erc-scroll-to-bottom from all ERC buffers + when module is removed. Activate the functionality in all ERC + buffers when the module is activated, rather than leaving it up to + the user. + (move-to-prompt): New module that moves to the ERC prompt if a + user tries to type elsewhere in the buffer, and then inserts their + keystrokes there. This is mostly taken from Johan BockgÃ¥rd's init + file. + (erc-move-to-prompt): New function that implements this. + (erc-move-to-prompt-xemacs): New function that implements this for + XEmacs. + (erc-move-to-prompt-init-xemacs): New function to perform the + extra initialization step needed for XEmacs. + + * erc-page.el, erc-replace.el: Fix header and footer. + + * erc-track.el (erc-track-minor-mode-maybe): Take an optional + buffer arg so that we can put this in erc-connect-pre-hook. If + given this argument, include it in the check to determine whether + to activate erc-track-minor-mode. + (track): Add erc-track-minor-mode-maybe to erc-connect-pre-hook, + so that we can use it as soon as a connection is attempted. + + * erc.el (erc-format-network, erc-format-target-and/or-network): + Use erc-network-name function instead, and check to see whether + that function is bound. This fixes an error in process filter for + people who did not have erc-services or erc-networks loaded. + (erc-modules): Add move-to-prompt module and enable it by + default. Thanks to e1f for the suggestion. + +2008-01-18 Michael Olson + + * Makefile (EXTRAS): Include erc-list-old.el. + + * erc-dcc.el (erc-dcc-verbose): Rename from erc-verbose-dcc. + (erc-pack-int): Rewrite to not depend on a count argument. + (erc-unpack-int): Rewrite to remove 4-character limitation. + (erc-dcc-server): Call set-process-coding-system and + set-process-filter-multibyte so that the contents get sent out + without modification. + (erc-dcc-send-filter): Don't take a substring -- just pass the + whole string to erc-unpack-int. + (erc-dcc-receive-cache): New option that indicates the number of + bytes to let the receive buffer grow before flushing it. + (erc-dcc-file-name): New buffer-local variable to keep track of + the filename of the currently-received file. + (erc-dcc-get-file): Disable undo for a speed increase. Set + erc-dcc-file-name. Truncate the file before writing to it. + (erc-dcc-append-contents): New function to append the contents of + a buffer to a file and then erase the contents of the buffer. + (erc-dcc-get-filter): Flush buffer contents after exceeding + erc-dcc-receive-cache. This allows large files to be downloaded + without storing the whole thing in memory. + (erc-dcc-get-sentinel): Flush any remaining contents before + closing. No need to save buffer. + (erc-dcc-listen-host): New option that determines which IP address + to listen on. + (erc-dcc-public-host): New option that determines which IP address + to advertise when sending a file. This is useful for people who + are on a local subnet. Together, these two options replace + erc-dcc-host. + + * erc.el (erc-mode-line-format): Add %N and %S. %N is the name of + the network, and %S is much like %s but with the network name + trumping the server name. Default to "%S %a". Thanks to e1f for + the suggestion. + (erc-format-network): New function that formats the network name. + (erc-format-target-and/or-network): New function that formats both + the network name and target, falling back on the server name if + the network name is not available. + (erc-update-mode-line-buffer): Add the new format spec items. + +2008-01-17 Michael Olson + + * erc.el (erc-join-buffer): Improve documentation. + (erc-query-display): New option indicating how to display a query + buffer that is made by using the /QUERY command. The default is + to display the query in a new window. + (erc-cmd-QUERY): Use it. Improve docstring. + (erc-auto-query): Default this to 'window-noselect instead, + because I've already seen bug reports about new users thinking + that ERC didn't display their test messages. Improve + customization type. + (erc-notice-face): Make this work with XEmacs. + (erc-join-buffer): Mention 'buffer in docstring. Improve + customization type. + + * erc-dcc.el (erc-dcc-send-sentinel): Better handle case where elt + is nil, in order to avoid an error. Thanks to Brent Goodrick for + the initial patch. + (erc-dcc-display-send): New function split from erc-dcc-send-hook. + (erc-dcc-send-connect-hook): Use it -- we don't like lambda forms + in hooks. + (erc-dcc-send-filter): Display byte count if the client confirmed + too much, and kill the buffer. Otherwise a DoS might be possible + by making Emacs run out of RAM. + + * erc-backend.el (erc-server-connect): Detect early on whether the + connection attempt has failed in order to avoid confusing error + messages. + + * erc-networks.el (erc-server-alist): Add Rizon network. + + * erc-services.el (erc-nickserv-passwords): Add Rizon to options. + (erc-nickserv-alist): Add support for Rizon. + + * erc-track.el (erc-track-find-face): Don't let buttons in notices + trump default text. Use catch/throw. Default to first element of + FACES is nothing is found. + + * erc-xdcc.el: Add local variables for proper indentation setup. + +2008-01-15 Michael Olson + + * erc-backend.el (erc-server-coding-system): Docfix. + (erc-coding-system-for-target): Pass the `target' argument along + as the first and only argument. It's not good to just depend on a + dynamic binding. + +2008-01-10 Michael Olson + + * erc-backend.el (321, 322): Split message-displaying parts into + new functions, which are added to each response's respective + hook. This makes them easier to disable. + + * erc-list.el: New file from Tom Tromey. Use erc-propertize + instead of propertize. Require 'erc. + (list): New module definition. Remove message-displaying + functions for 321 and 322 response handlers when enabling the + module, and restore them when disabling. As a sanity check, + remove the erc-list-handle-322 function when disabling the module. + (erc-list-handle-322): Handle the case where we run the LIST + command, but do not go through the normal steps. + (erc-cmd-LIST): Add docstring. Strip initial space from line if + it is non-nil. Use make-local-variable to silence compiler + warning. Capture current buffer and pass it to + erc-list-install-322-handler. + (erc-list-install-322-handler): Take server-buffer argument, so + that we are certain of being in the right buffer. Use 4th + argument to add-hook, so that erc-server-322-functions is only + modified in one buffer. + + * erc-list-old.el: Renamed from old erc-list.el. + + * erc.el (erc-modules): Add list-old. + (erc-set-topic): Handle case where there are no newlines in the + existing topic, which happens when /LIST is run. + (erc-notice-face): If we have less than 88 colors, make this + blue. Otherwise the text will be pink in a tty, which looks + dreadful. Thanks to e1f for the report. + (erc-remove-parsed-property): New option that determines whether + to remove the erc-parsed property after displaying a message. + This should have the effect of making ERC take up less memory. + (erc-display-line-1): Use it. + 2008-01-04 Stefan Monnier * erc-ibuffer.el (erc-channel-modes): Pass mode-name through format-mode-line -2007-12-16 Diane Murray - * erc-services.el (erc-nickserv-alist): Removed autodetect regexp, - added identified regexp for OFTC. - (erc-nickserv-identification-autodetect): Make sure success-regex - is non-nil. - (erc-nickserv-identify-autodetect): Make sure identify-regex is - non-nil. Doc fix. +See ChangeLog.07 for earlier changes. -2007-12-13 Diane Murray - - * erc-backend.el (PRIVMSG, QUIT, TOPIC, WALLOPS, 376, 004, 221) - (312, 315, 319, 330, 331, 333, 367, 368, 391, 405, 406, 412) - (421, 432, 433, 437, 442, 461, 474, 477, 482, 431): Doc fix. - -2007-12-09 Michael Olson - - * erc-services.el (erc-nickserv-alist): Fix regexps for GRnet. - -2007-12-09 Giorgos Keramidas (tiny change) - - * erc-backend.el, erc.el: - Parse 275 (secure connection) responses. - - * erc-services.el: Add identification hooks for GRnet, the Greek - IRC network . - -2007-12-08 David Kastrup - - * erc-stamp.el (erc-echo-timestamp): - * erc-lang.el (language): - * erc-backend.el (erc-server-connect): Fix buggy call to `message'. - -2007-12-07 Edward O'Connor - - * erc-services.el: Provide a hook that runs when nickserv confirms - that the user has successfully identified. - (services, erc-nickserv-identify-mode): Add and remove - erc-nickserv-identification-autodetect from - erc-server-NOTICE-functions. - (erc-nickserv-alist): Add SUCCESS-REGEXP to each entry. - (erc-nickserv-alist-identified-regexp) - (erc-nickserv-identification-autodetect): New functions. - (erc-nickserv-identified-hook): New hook. - -2007-12-06 D. Goel - - * erc-match.el (erc-add-entry-to-list): Fix buggy call to `error'. - -2007-12-01 Glenn Morris - - * erc-backend.el (erc-server-send-ping): Move after definition of - erc-server-send. - - * erc.el (iswitchb-temp-buflist, iswitchb-read-buffer) - (erc-controls-strip): Declare for compiler. - (erc-iswitchb): Don't require iswitchb when compiling. Test - iswitchb-mode is bound. - -2007-11-30 Dan Nicolaescu - - * erc.el (open-ssl-stream, open-tls-stream, erc-network-name): - Declare as functions. - -2007-11-29 Giorgos Keramidas (tiny change) - - * erc-backend.el, erc.el: - Parse 307 (nick has identified) responses. - -2007-11-15 Juanma Barranquero - - * erc.el (erc-open): - * erc-backend.el (define-erc-response-handler): - * erc-log.el (log): - * erc-match.el (erc-log-matches): Fix typos in docstrings. - -2007-11-11 Michael Olson - - * erc-autoaway.el (erc-autoaway-possibly-set-away): - * erc-netsplit.el (erc-netsplit-timer): - * erc-notify.el (erc-notify-timer): - * erc-track.el (erc-user-is-active): Only run if we have - successfully established a connection to the server and have - logged in. I suspect that sending messages too soon may make some - IRC servers not respond well, particularly when the network - connection is iffy or subject to traffic-shaping. - -2007-11-01 Michael Olson - - * erc-compat.el (erc-set-write-file-functions): New compatibility - function to set the write hooks appropriately. - - * erc-log.el (erc-log-setup-logging): Use - erc-set-write-file-functions. This fixes a byte-compiler warning. - - * erc-stamp.el: Silence byte-compiler warning about - erc-fill-column. - - * erc.el (erc-with-all-buffers-of-server): Bind the result of - mapcar to a variable in order to silence a byte-compiler warning. - -2007-10-29 Michael Olson - - * erc-ibuffer.el (erc-modified-channels-alist): Use - eval-when-compile, and explain why we are doing this. - -2007-10-25 Dan Nicolaescu - - * erc-ibuffer.el (erc-modified-channels-alist): Pacify - byte-compiler. - -2007-10-13 Glenn Morris - - * erc-track.el (erc-modified-channels-update): Use mapc rather - than mapcar. - -2007-10-12 Diane Murray - - * erc.el (erc-join-channel): Prompt for channel key if C-u or - another prefix-arg was typed. - - * NEWS: Noted this change. - -2007-10-07 Michael Olson - - * erc.el (erc-cmd-ME'S): New command that handles the case where - someone types "/me's". It concatenates the text " 's" to the - beginning of the input and then sends the result like a normal - "/me" command. - (erc-command-regexp): Permit single-quote character. - -2007-09-30 Aidan Kehoe (tiny change) - - * erc-log.el (erc-save-buffer-in-logs): Prevent spurious warnings - when looking at a log file and concurrently saving to it. - -2007-09-18 Exal de Jesus Garcia Carrillo (tiny change) - - * erc.texi (Special-Features): Fix small typo. - -2007-09-16 Michael Olson - - * erc-track.el (erc-track-switch-direction): Mention - erc-track-faces-priority-list. Thanks to Leo for the suggestion. - -2007-09-11 Exal de Jesus Garcia Carrillo (tiny change) - - * erc-sound.el: Fix typo in setting up instructions. - -2007-09-10 Michael Olson - - * Makefile (elpa): Copy dir template rather than echoing a few - lines. The reason for this is that the ELPA package for ERC was - getting a corrupt dir entry. - - * dir-template: Template for the ELPA dir file. - -2007-09-08 Michael Olson - - * erc-log.el (erc-log-filter-function): New option that specifies - the function to call for filtering text before writing it to a log - file. Thanks to David O'Toole for the suggestion. - (erc-save-buffer-in-logs): Use erc-log-filter-function. Make sure - we carry along the value of coding-system-for-write, because this - could potentially be shadowed by the temporary buffer. - - * erc.el (erc-version-string): Update to 5.3, development version. - -2007-09-07 Glenn Morris - - * erc.el (erc-toggle-debug-irc-protocol): Fix call to - erc-view-mode-enter. - -2007-08-08 Glenn Morris - - * erc-log.el, erc.el: Replace `iff' in doc-strings and comments. - -2007-09-03 Michael Olson - - * erc.el (erc-default-port): Make this an integer value rather - than a string. Thanks to Luca Capello for the report. - -2007-08-27 Michael Olson - - * erc.el (erc-cmd-GQUIT): If erc-kill-queries-on-quit is non-nil, - kill all query buffers after 4 seconds. - -2007-08-16 Michael Olson - - * NEWS: Add ERC 5.3 changes section, and mention jbms' erc-track - compatibility note. - - * erc-track.el (erc-track-list-changed-hook): Turn this into a - customizable option. - (erc-track-switch-direction): Add 'importance option. - (erc-modified-channels-display): If erc-track-switch-direction is - 'importance, call erc-track-sort-by-importance. - (erc-track-face-priority): New function that returns a number - indicating the position of a face in erc-track-faces-priority-list. - (erc-track-sort-by-importance): New function that sorts - erc-modified-channels-list according to erc-track-face-priority. - (erc-track-get-active-buffer): Make 'oldest a rough opposite of - 'importance. - -2007-08-14 Jeremy Maitin-Shepard - - * erc-track.el (erc-track-remove-disconnected-buffers): New - variable which controls whether buffers associated with a server - that is disconnected should be removed from - `erc-modified-channels-alist'. Existing behavior is to - unconditionally remove such buffers, which is achieved by setting - `erc-track-removed-disconnected-buffers' to t. When set to t, - which is the new default value, such buffers remain in the list, - which I think is often the desired behavior, since the user may - likely wish to find out about activity that occurred in a channel - prior to it being disconnected. - (erc-track-list-changed-hook): New hook that is run whenever the - contents of `erc-modified-channels-alist' changes; it is useful - for users such as myself that don't use the default mode-line - notification but instead use a separate mechanism (which is tied - to my window manager) to provide notification of channel activity. - (erc-track-get-buffer-window): New function that acts as a wrapper - around `get-buffer-window' that handles the `selected-visible' - option of `erc-track-visibility'; previously, the value of - `erc-track-visibility' was passed directly to `get-buffer-window', - which does not support `selected-visible'; consequently, - `selected-visible' was not properly supported. - (erc-track-modified-channels): Fix a bug in the logic for removing - buffers from the list in certain cases. - (erc-track-position-in-mode-line): Add a supported value that - specifies that the tracking information should not be added to the - mode line at all. The value of nil is used to indicate that the - information should not be added at all to the mode line. - (erc-track-add-to-mode-line): Check for position eq to t, rather - than non-nil. - (erc-buffer-visible): Use erc-track-get-buffer-window. - (erc-modified-channels-update): Take - erc-track-remove-disconnected-buffers into account. - (erc-modified-channels-display): Run `erc-track-list-changed-hook'. - - * erc.el (erc-reuse-frames): New option that determines whether - new frames are always created. Defaults to t. This only has an - effect when erc-join-buffer is set to 'frame. - (erc-setup-buffer): Use it. - -2007-08-14 Michael Olson - - * erc-backend.el (erc-server-reconnect): If the server buffer has - been killed, use the current buffer instead. If the current - buffer is not an ERC buffer, give an error. This fixes a bug when - /reconnect is run from a channel buffer whose server buffer has - been deleted. Thanks to jbms for the report. - (erc-process-sentinel-1): Take server buffer as an argument, so - that we can make sure that it is current. - (erc-process-sentinel): Pass buffer to erc-process-sentinel-1. - (erc-process-sentinel-2): New function split from - erc-process-sentinel-1. If server buffer is deleted during a - reconnect attempt, stop trying to reconnect. Fix bug where - reconnect was not happening when erc-server-reconnect-attempts was - t. Call erc-server-reconnect-p only once each time. If we are - instructed to try connecting indefinitely, tell the user that they - can stop this by killing the server buffer. Call the process - sentinel by means of run-at-time, so that there is time to kill - the buffer if need be; this also removes the need for a while - loop. Refuse to reconnect again if erc-server-reconnect-timeout - is not an number. - - * erc.el (erc-command-no-process-p): Fix bug: the return value of - erc-extract-command-from-line is a list rather than a single - symbol. Thanks to jbms for the report. - (erc-cmd-RECONNECT): Use simpler logic, and use buffer-live-p - rather than bufferp. - (erc-send-current-line, erc-display-command, erc-display-msg): - Handle case where erc-server-process is nil, so that /reconnect - works. - -2007-08-12 Michael Olson - - * erc-identd.el (erc-identd-filter): Instead of sending an EOF - character, which now confuses freenode, stop the server process, - so that no new connections are accepted, and kill the current - client process. - -2007-07-30 Michael Olson - - * erc-nicklist.el: Remove from the Emacs source tree. This file - is not release quality, and relies heavily on a module which - cannot be distributed with ERC due to licensing reasons. - -2007-07-29 Michael Olson - - * erc-list.el: Relicense to GPLv3. Since the file was already - licensed under version 2 or later, it turns out that we do not - need the permission of all of the authors in order to proceed. - -2007-07-25 Glenn Morris - - * Relicense all FSF files to GPLv3 or later. - -2007-07-13 Michael Olson - - * erc-goodies.el (erc-get-bg-color-face, erc-get-fg-color-face): - Use erc-error rather than message and beep. - - * erc-sound.el: Indentation fix. - - * erc.el (erc-command-no-process-p): New function that determines - if its argument is an ERC command that can be run when the server - process is not alive. - (erc-cmd-SET, erc-cmd-CLEAR, erc-cmd-COUNTRY, erc-cmd-HELP) - (erc-cmd-LASTLOG, erc-cmd-QUIT, erc-cmd-GQUIT) - (erc-cmd-RECONNECT, erc-cmd-SERVER): Denote that these commands - can be run even when the server process is not alive. - (erc-send-current-line): Call erc-command-no-process-p if the - server process is not alive, to determine if we have a command - that can be run anyway. Thanks to Tom Tromey for the bug report. - (erc-error): New function that either displays a message or throws - an error, depending on whether debug-on-error is non-nil. - (erc-cmd-SERVER, erc-send-current-line): Use it. - -2007-07-10 Michael Olson - - * Relicense all FSF-assigned code to GPLv3. - -2007-06-25 Michael Olson - - * erc.texi (Options): Fix typo. - (Getting Help and Reporting Bugs): Update webpage URL. Make Gmane - part more readable. - -2007-06-20 Michael Olson - - * erc-stamp.el (erc-timestamp-format-left): New option that - specifies the left timestamp to use for - erc-insert-timestamp-left-and-right. - (erc-timestamp-format-right): New option that specifies the right - timestamp to use for erc-insert-timestamp-left-and-right. - (erc-insert-timestamp-function): Change default to - erc-insert-timestamp-left-and-right. - (erc-insert-away-timestamp-function): Ditto. - (erc-timestamp-last-inserted-left) - (erc-timestamp-last-inserted-right): New variables to keep track - of data for erc-insert-timestamp-left-and-right. - (erc-insert-timestamp-left-and-right): New function that places - timestamps on both the left and right sides of the screen, but - only if each timestamp has changed since it was last computed. - Thanks to offby1 for urging me to merge this. - - * erc.el (erc-open-ssl-stream): Display informative error when - ssl.el not found. - (erc-tls): New function to connect using tls.el. - (erc-open-tls-stream): New function to initiate tls connection. - Display informative error when tls.el not found. - -2007-06-19 Michael Olson - - * erc-log.el: Update header with accurate instructions. - -2007-06-17 Michael Olson - - * erc-pkg.el: Update description to match what is currently in ELPA. - -2007-06-14 Juanma Barranquero - - * erc-goodies.el (erc-scroll-to-bottom): Remove redundant check. - -2007-06-13 Michael Olson - - * erc-compat.el (erc-with-selected-window): New compatibility - macro that implements `with-selected-window'. - - * erc-goodies.el (erc-scroll-to-bottom): Use it. This fixes a bug - with buffer ordering where ERC buffers would move to the top. - Thanks to Ivan Kanis for the patch. - -2007-06-10 Michael Olson - - * erc-log.el (erc-logging-enabled): Fix a bug that occurred when - `erc-log-channels-directory' had the name of a function. - -2007-06-06 Juanma Barranquero - - * erc.el (erc-show-channel-key-p, erc-startup-file-list): - Fix typo in docstring. - -2007-06-03 Michael Olson - - * erc-compat.el (erc-view-mode-enter): Make this its own function, - in order to document what we do, and provide sane fallback - behavior. - - * erc.el (erc-toggle-debug-irc-protocol): Don't pass any arguments - to erc-view-mode-enter, since we don't do anything special with - the exit function. This fixes a bug with Emacs 21 and Emacs 22. - Thanks to Leo for noticing. - -2007-05-30 Michael Olson - - * erc-compat.el (erc-user-emacs-directory): New variable that - determines where to find user-specific Emacs settings. For Emacs, - this is usually ~/.emacs.d, and for XEmacs this is usually - ~/.xemacs. - - * erc.el (erc-startup-file-list): Use erc-user-emacs-directory. - -2007-05-28 Michael Olson - - * erc-button.el (erc-button-url-regexp): Recognize parentheses as - part of URLs. Thanks to Lawrence Mitchell for the fix. - -2007-05-26 Michael Olson - - * erc.texi (Modules): Fix references to completion modules. - -2007-05-21 Michael Olson - - * Makefile (SOURCE): Remove erc-pkg.el. - (debclean): New rule to clean old Debian packages of ERC. - (debprepare): Don't modify the released tarball, but copy it as - the .orig.tar.gz file. - (debrelease, debrevision): Remove. - (debinstall): New target that copies the generated Debian file to - a distro-specific location. - (deb): New rule that chains together the stages in building a - Debian package. - (EXTRAS): Add erc-nicklist.el, since it is not release-quality. - (extras): Copy images directory. - - * erc-nicklist.el (erc-nicklist-icons-directory): Use - locate-library to find the "images" directory. This should be - more failsafe. Thanks to Tom Tromey for the idea. - -2007-05-19 Michael Olson - - * Makefile (ELPA): New variable that contains the location of my - local ELPA repository. - (elpa): New rule that makes an ELPA package for ERC. - -2007-04-19 Michael Olson - - * erc.el (erc-parse-prefix): New function that retrieves the - PREFIX server parameter from the current server and returns an - alist of prefix type to prefix character. - (erc-channel-receive-names): Use `erc-parse-prefix' to determine - whether the first character of a nick is a prefix character or - not. This should fix a bug reported by bromine about needing to - type "%" first to complete nicks of people who are "hops" on - Slashnet. This should also support for very exotic IRC server - setups, if any exist. - (erc-update-current-channel-member): Indentation. - -2007-04-15 Michael Olson - - * erc-log.el (erc-generate-log-file-name-function): Docfix. - Mention how to deal with the case for putting log files in - different directories. Change a customization type from `symbol' - to `function'. - (erc-log-channels-directory): Allow this to contain a function - name, which is called with the same args as in - `erc-generate-log-file-name-function'. Thanks to andrewy for the - report and use case. - (erc-current-logfile): Detect if `erc-log-channels-directory' is a - function and call it with arguments if so. - -2007-04-12 Michael Olson - - * erc-backend.el (define-erc-response-handler): Mention that hook - processing stops when the function returns non-nil. This should - help avoid a nasty "gotcha" when making custom functions. Thanks - to John Sullivan for the report. - -2007-04-08 Diane Murray - - * erc-nicklist.el (erc-nicklist-voiced-position): Fixed - customization mismatch. - -2007-04-01 Michael Olson - - * erc.el (erc-version-string): Release ERC 5.2. - - * erc-auto.in, erc-chess.el, erc-list.el, erc-speak.el: - * erc-viper.el: Update copyright notices. - - * erc.texi: Make Emacs Lisp source code in this document - essentially public domain. Update version to 5.2. - (Obtaining ERC): Mention extras tarball. - (Releases): Mention local GNU mirror. - (Sample Configuration): Remove notice. - - * FOR-RELEASE (5.3): Add item for erc-nicklist. - Mark NEWS as done. Mark extras tarball as done. - - * Makefile (VERSION): Increment to 5.2. - (TESTING): Remove. - (EXTRAS): New variable containing the contents of our "Emacs 22 - extras" tarball. - (SOURCE): Remove $(TESTING). - (MISC): Add COPYING and ChangeLog.06. Fix ChangeLog.NNNN -> - ChangeLog.NN. - (release): Use $(SNAPDIR) instead of erc-$(VERSION). - (extras): New rule which implements the building of the extras - tarball. - (upload-extras): New rule to upload the extras tarball. It's - yucky to replicate upload, but oh well. - (DISTRIBUTOR): New variable used to differentiate between building - packages for Ubuntu and Debian. - (debrelease, debrevision): Use it. - (debbuild): Run linda in addition to lintian. - - * NEWS: Mention extras tarball. Note which files have been - renamed. Note that erc-list is enabled by default, except in - Emacs 22. - - * README.extras: New file which serves as a README for the extras - tarball. - -2007-03-31 Michael Olson - - * NEWS: Update for the 5.2 release. - - * FOR-RELEASE: Finish up 5.2 manual item. Add documentation item - for 5.3. - - * erc.texi (Sample Session): Flesh out. Mention #erc. - (Modules): Defer to 5.3 release. - (Advanced Usage): Move Sample Configuration chapter ahead of - unfinished chapters. - (Sample Configuration): Write. - (Options): Mention how to see available ERC options. Defer to 5.3 - release. - (Tips and Tricks): Remove, since it seems better to just include - tips and tricks in the sample configuration, commented out. - - * erc-bbdb.el (erc-bbdb-search-name-and-create): Make prompt more - informative about how to skip merging. - (erc-bbdb-insinuate-and-show-entry-1): Move contents of - erc-bbdb-insinuate-and-show-entry here. - (erc-bbdb-insinuate-and-show-entry): Run - erc-bbdb-insinuate-and-show-entry-1 "outside" of the calling - function, so that we can avoid triggering a process-filter error - if the user hits C-g. - -2007-03-30 Michael Olson - - * FOR-RELEASE: Solve C-c C-SPC keybinding dilemma. - - * erc-autoaway.el (erc-autoaway-idle-method): Use `if' rather than - `cond' and `set' rather than `set-default'. - - * erc-log.el: Avoid compiler warning by requiring erc-network - during compilation. - (erc-generate-log-file-name-function): Add tag to each option. - Add erc-generate-log-file-name-network. - (erc-generate-log-file-name-network): New function which generates - a log file name that uses network name rather than server name, - when possible. - - * erc-track.el (track): Assimilate track-when-inactive module, - since there's no need to have two modules in one file -- an option - will do. Remove track-modified-channels alias. Call - erc-track-minor-mode-maybe, and tear down the minor mode when - disabling. - (erc-track-when-inactive): New option which determines whether to - track visible buffers when inactive. The default is not to do so. - (erc-track-visibility): Mention erc-track-when-inactive. - (erc-buffer-visible): Use erc-track-when-inactive. - (erc-track-enable-keybindings): New option which determines - whether to enable the global-level tracking keybindings. The - default is to do so, unless they would override another binding, - in which case we prompt the user about it. - (erc-track-minor-mode-map): Move global keybindings here. - (erc-track-minor-mode): New minor mode which only enables the - keybindings and does nothing else. - (erc-track-minor-mode-maybe): New function which starts - erc-track-minor-mode, but only if it hasn't already been started, - an ERC buffer exists, and the user OK's it, depending on the value - of `erc-track-enable-keybindings'. - (erc-track-switch-buffer): Display a message if someone calls this - without first enabling erc-track-mode. - -2007-03-17 Michael Olson - - * erc.texi (Development): Mention ErcDevelopment page on - emacswiki. - (Getting Started): Mention ~/.emacs.d/.ercrc.el and the Customize - interface. - (Sample Session): New section that has a very rough draft for a - sample ERC session. - (Special Features): New section that explains some of the special - features of ERC. Taken from ErcFeatures on emacswiki, with - enhancements. - -2007-03-12 Diane Murray - - * erc-autoaway.el (erc-autoaway-idle-method): When setting the new - value, disable and re-enable `erc-autoaway-mode' only if it was - already enabled. This fixes a bug where autoaway was enabled just - by loading the file. - -2007-03-10 Diane Murray - - * erc-capab.el: Added more information to the Usage section. - (erc-capab-identify-prefix): Doc fix. - (erc-capab-identify-unidentified): New face. - (290): Removed. Definition moved to erc-backend.el. - (erc-capab-identify-send-messages): Renamed from - `erc-capab-send-identify-messages'. - (erc-capab-identify-setup): Use it. - (erc-capab-identify-get-unidentified-nickname): Renamed from - `erc-capab-get-unidentified-nickname'. - (erc-capab-identify-add-prefix): Use it. Use - `erc-capab-identify-unidentified' as the face. - - * erc-backend.el (290): Moved here from erc-capab.el. - - * erc.el (erc-select): Added an autoload cookie. - (erc-message-type-member, erc-restore-text-properties): Use - `erc-get-parsed-vector'. - (erc-auto-query): Set the default to 'bury since many new users - expect private messages from others to be in dedicated query - buffers, not the server buffer. - (erc-common-server-suffixes): Use "freenode" for freenode.net, not - "OPN". Added oftc.net. - - * NEWS: Added note about erc-auto-query's new default setting. - -2007-03-03 Michael Olson - - * erc.el (erc-open, erc): Docfixes. - -2007-03-02 Michael Olson - - * FOR-RELEASE: Make section for 5.3 release and move erc-backend - cleanup there. Awaiting discussion before doing other things. - Add tasks for merging filename changes from the 5.2 release - branch, and for making a tarball of modules not in Emacs 22. Add - item to remind me to update NEWS. Mark backtab entry as done. - - * erc-button.el (button): Add call to `erc-button-add-keys'. - (erc-button-keys-added): New variable tracking whether we've added - the keys yet. - (erc-button-add-keys): New function that adds the key to - erc-mode-map. - - * erc.texi: Change version to 5.2 (pre-release). - -2007-02-15 Michael Olson - - * CREDITS: Update. - - * erc-backend.el (erc-server-send-ping-interval): Change to use a - default of 30 seconds. Improve customize interface. - (erc-server-send-ping-timeout): New option that determines when to - consider a connection stalled and restart it. The default is - after 120 seconds. - (erc-server-send-ping): Use erc-server-send-ping-timeout instead - of erc-server-send-ping-interval. If - erc-server-send-ping-timeout is nil, do not ever kill and restart - a hung IRC process. - - * erc.el (erc-modules): Include the name of the module in its - description. This should make it easier for people to find and - enable a particular module. - -2007-02-15 Vivek Dasmohapatra - - * erc.el (erc-cmd-RECONNECT): Kill old process if it is still - alive. - (erc-message-english-PART): Properly escape "%" characters in - reason. - - * erc-backend.el (erc-server-reconnecting): New variable that is - set when the user requests a reconnect, but the old process is - still alive. This forces the reconnect to work even though the - process is killed manually during reconnect. - (erc-server-connect): Initialize it. - (erc-server-reconnect-p): Use it. - (erc-process-sentinel-1): Set it to nil after the first reconnect - attempt. - -2007-02-07 Diane Murray - - * erc-menu.el (erc-menu-definition): Fixed so that the separator - is between "Current channel" and "Pals, fools and other keywords", - not at the bottom of the "Current channel" submenu. - -2007-01-25 Diane Murray - - * erc-networks.el (erc-server-alist): Removed SSL server for now - since `erc-server-select' doesn't know to use `erc-ssl'. - - * erc-networks.el (erc-server-alist, erc-networks-alist): Added - definitions for oftc.net. - - * erc-services.el (erc-nickserv-alist): Fixed OFTC message regexp. - -2007-01-22 Michael Olson - - * erc-backend.el (erc-server-error-occurred): New variable that - indicates when an error has been signaled by the server. This - should fix an infinite reconnect bug when giving some servers a - bogus :full-name. Thanks to Angelina Carlton for the report. - (erc-server-connect): Initialize erc-server-error-occurred. - (erc-server-reconnect-p): Use it. - (ERROR): Set it. - - * erc-services.el (erc-nickserv-alist): Alphabetize and add Ars - and QuakeNet. Standardize look of entries. Fix type mismatch - error in customize interface. - (erc-nickserv-passwords): Alphabetize and add missing entries from - erc-nickserv-alist. - -2007-01-21 Michael Olson - - * erc.el (erc-header-line-format): Document how to disable the - header line, and add a customization type for it. Also, make the - changes take effect immediately. - -2007-01-19 Michael Olson - - * erc.texi (Modules): Document new menu module. Thanks to Leo - for noticing. - -2007-01-16 Diane Murray - - * erc-stamp.el (erc-insert-timestamp-left): Fixed so that the - whitespace string filler is hidden correctly when timestamps are - hidden. - (erc-toggle-timestamps): New function to use instead of - `erc-show-timestamps' and `erc-hide-timestamps'. - - * erc.el (erc-restore-text-properties): Moved here from - erc-fill.el since it could be useful in general. - - * erc-fill.el (erc-restore-text-properties): Removed. - -2007-01-13 Michael Olson - - * erc.el (erc-command-regexp): New variable that is used to match - a command. - (erc-send-input): Use it. This fixes a bug where paths -- - "/usr/bin/foo", for example -- were being displayed as commands, - but still sent correctly. - (erc-extract-command-from-line): Use it. - - * erc.texi (Modules): Document erc-capab-identify. - -2007-01-11 Diane Murray - - * erc.el (erc-find-parsed-property): Moved here from erc-track.el - since it can be useful in general. - - * erc-track.el (erc-find-parsed-property): Removed. - - * erc-capab.el (erc-capab-find-parsed): Removed. - (erc-capab-identify-add-prefix): Use `erc-find-parsed-property'. - - * erc.el (erc-open): Run `erc-before-connect' hook here. This - makes sure the hook always gets called before a connection is - made, as some functions, like `erc-handle-irc-url', use `erc-open' - instead of `erc'. - (erc): Removed `erc-before-connect' hook. - - * erc-menu.el (erc-menu-definition): Put items specific to - channels in a "Current channel" submenu. - - * erc-backend.el (321, 323): Display channel list in server buffer - when not using the channel list module. - - * erc.el: Updated copyright years. - (erc-version-string): Set to 5.2 (devel). - (erc-format-lag-time): Fixed to work when `erc-server-lag' is nil. - (erc-update-mode-line-buffer): Set the header face. - -2007-01-11 Michael Olson - - * erc-bbdb.el (erc-bbdb-popup-type): Fix customization type and - documentation. - - * erc-services.el (erc-nickserv-identify-mode): Improve - documentation for nick-change option and move higher to fix - compiler warning. Avoid a recursive load error. - (erc-nickserv-alist): Add simple entry for BitlBee, to avoid - "NickServ is AWAY: User is offline" error. Oddly enough, bitlbee - was smart enough to recognize that as an authentication request - and log in regardless, which is why I didn't notice this earlier. - (erc-nickserv-alist-sender, erc-nickserv-alist-regexp) - (erc-nickserv-alist-nickserv, erc-nickserv-alist-ident-keyword) - (erc-nickserv-alist-use-nick-p) - (erc-nickserv-alist-ident-command): New accessors for - erc-nickserv-alist. Using nth is unwieldy. - (erc-nickserv-identify-autodetect) - (erc-nickserv-identify-on-connect) - (erc-nickserv-identify-on-nick-change, erc-nickserv-identify): Use - the new accessors. - -2007-01-11 Diane Murray - - * NEWS: Added note for `erc-my-nick-face'. Fixed capab-identify - wording. - -2007-01-10 Diane Murray - - * erc.el (erc-mode-line-format): Added %l to documentation. - (erc-header-line-format): Removed "[IRC]". Use the new %l - replacement character. Doc fix. - (erc-format-channel-modes): Removed lag code. Removed parentheses - from mode string. - (erc-format-lag-time): New function. - (erc-update-mode-line-buffer): Use it. - -2007-01-10 Michael Olson - - * erc.el: Fix typo in url-irc-function instructions. - -2007-01-09 Michael Olson - - * erc.el (erc-system-name): New option that determines the system - name to use when logging in. The default is to figure this out by - calling `system-name'. - (erc-login): Use it. - -2007-01-07 Michael Olson - - * erc.el (erc-modules): Add the menu module. This should fix a - bug with incorrect ERC submenus being displayed. - - * erc-menu.el: Turn this into a module. - (erc-menu-add, erc-menu-remove): New functions that add and remove - the ERC menu. - - -See ChangeLog.06 for earlier changes. - - Copyright (C) 2007, 2008 Free Software Foundation, Inc. + Copyright (C) 2008 Free Software Foundation, Inc. This file is part of GNU Emacs. @@ -860,5 +288,3 @@ See ChangeLog.06 for earlier changes. ;; coding: utf-8 ;; add-log-time-zone-rule: t ;; End: - -;; arch-tag: 3369b6e5-96b1-4b32-96cd-9a905c747496 diff --git a/lisp/erc/ChangeLog.07 b/lisp/erc/ChangeLog.07 new file mode 100644 index 00000000000..c317fe62177 --- /dev/null +++ b/lisp/erc/ChangeLog.07 @@ -0,0 +1,839 @@ +2007-12-16 Diane Murray + + * erc-services.el (erc-nickserv-alist): Removed autodetect regexp, + added identified regexp for OFTC. + (erc-nickserv-identification-autodetect): Make sure success-regex + is non-nil. + (erc-nickserv-identify-autodetect): Make sure identify-regex is + non-nil. Doc fix. + +2007-12-13 Diane Murray + + * erc-backend.el (PRIVMSG, QUIT, TOPIC, WALLOPS, 376, 004, 221) + (312, 315, 319, 330, 331, 333, 367, 368, 391, 405, 406, 412) + (421, 432, 433, 437, 442, 461, 474, 477, 482, 431): Doc fix. + +2007-12-09 Michael Olson + + * erc-services.el (erc-nickserv-alist): Fix regexps for GRnet. + +2007-12-09 Giorgos Keramidas (tiny change) + + * erc-backend.el, erc.el: + Parse 275 (secure connection) responses. + + * erc-services.el: Add identification hooks for GRnet, the Greek + IRC network . + +2007-12-08 David Kastrup + + * erc-stamp.el (erc-echo-timestamp): + * erc-lang.el (language): + * erc-backend.el (erc-server-connect): Fix buggy call to `message'. + +2007-12-07 Edward O'Connor + + * erc-services.el: Provide a hook that runs when nickserv confirms + that the user has successfully identified. + (services, erc-nickserv-identify-mode): Add and remove + erc-nickserv-identification-autodetect from + erc-server-NOTICE-functions. + (erc-nickserv-alist): Add SUCCESS-REGEXP to each entry. + (erc-nickserv-alist-identified-regexp) + (erc-nickserv-identification-autodetect): New functions. + (erc-nickserv-identified-hook): New hook. + +2007-12-06 D. Goel + + * erc-match.el (erc-add-entry-to-list): Fix buggy call to `error'. + +2007-12-01 Glenn Morris + + * erc-backend.el (erc-server-send-ping): Move after definition of + erc-server-send. + +2007-11-29 Giorgos Keramidas (tiny change) + + * erc-backend.el, erc.el: + Parse 307 (nick has identified) responses. + +2007-11-15 Juanma Barranquero + + * erc.el (erc-open): + * erc-backend.el (define-erc-response-handler): + * erc-log.el (log): + * erc-match.el (erc-log-matches): Fix typos in docstrings. + +2007-11-11 Michael Olson + + * erc-autoaway.el (erc-autoaway-possibly-set-away): + * erc-netsplit.el (erc-netsplit-timer): + * erc-notify.el (erc-notify-timer): + * erc-track.el (erc-user-is-active): Only run if we have + successfully established a connection to the server and have + logged in. I suspect that sending messages too soon may make some + IRC servers not respond well, particularly when the network + connection is iffy or subject to traffic-shaping. + +2007-11-01 Michael Olson + + * erc-compat.el (erc-set-write-file-functions): New compatibility + function to set the write hooks appropriately. + + * erc-log.el (erc-log-setup-logging): Use + erc-set-write-file-functions. This fixes a byte-compiler warning. + + * erc-stamp.el: Silence byte-compiler warning about + erc-fill-column. + + * erc.el (erc-with-all-buffers-of-server): Bind the result of + mapcar to a variable in order to silence a byte-compiler warning. + +2007-10-29 Michael Olson + + * erc-ibuffer.el (erc-modified-channels-alist): Use + eval-when-compile, and explain why we are doing this. + +2007-10-25 Dan Nicolaescu + + * erc-ibuffer.el (erc-modified-channels-alist): Pacify + byte-compiler. + +2007-10-13 Glenn Morris + + * erc-track.el (erc-modified-channels-update): Use mapc rather + than mapcar. + +2007-10-12 Diane Murray + + * erc.el (erc-join-channel): Prompt for channel key if C-u or + another prefix-arg was typed. + + * NEWS: Noted this change. + +2007-10-07 Michael Olson + + * erc.el (erc-cmd-ME'S): New command that handles the case where + someone types "/me's". It concatenates the text " 's" to the + beginning of the input and then sends the result like a normal + "/me" command. + (erc-command-regexp): Permit single-quote character. + +2007-09-30 Aidan Kehoe (tiny change) + + * erc-log.el (erc-save-buffer-in-logs): Prevent spurious warnings + when looking at a log file and concurrently saving to it. + +2007-09-18 Exal de Jesus Garcia Carrillo (tiny change) + + * erc.texi (Special-Features): Fix small typo. + +2007-09-16 Michael Olson + + * erc-track.el (erc-track-switch-direction): Mention + erc-track-faces-priority-list. Thanks to Leo for the suggestion. + +2007-09-11 Exal de Jesus Garcia Carrillo (tiny change) + + * erc-sound.el: Fix typo in setting up instructions. + +2007-09-10 Michael Olson + + * Makefile (elpa): Copy dir template rather than echoing a few + lines. The reason for this is that the ELPA package for ERC was + getting a corrupt dir entry. + + * dir-template: Template for the ELPA dir file. + +2007-09-08 Michael Olson + + * erc-log.el (erc-log-filter-function): New option that specifies + the function to call for filtering text before writing it to a log + file. Thanks to David O'Toole for the suggestion. + (erc-save-buffer-in-logs): Use erc-log-filter-function. Make sure + we carry along the value of coding-system-for-write, because this + could potentially be shadowed by the temporary buffer. + + * erc.el (erc-version-string): Update to 5.3, development version. + +2007-09-07 Glenn Morris + + * erc.el (erc-toggle-debug-irc-protocol): Fix call to + erc-view-mode-enter. + +2007-08-08 Glenn Morris + + * erc-log.el, erc.el: Replace `iff' in doc-strings and comments. + +2007-09-03 Michael Olson + + * erc.el (erc-default-port): Make this an integer value rather + than a string. Thanks to Luca Capello for the report. + +2007-08-27 Michael Olson + + * erc.el (erc-cmd-GQUIT): If erc-kill-queries-on-quit is non-nil, + kill all query buffers after 4 seconds. + +2007-08-16 Michael Olson + + * NEWS: Add ERC 5.3 changes section, and mention jbms' erc-track + compatibility note. + + * erc-track.el (erc-track-list-changed-hook): Turn this into a + customizable option. + (erc-track-switch-direction): Add 'importance option. + (erc-modified-channels-display): If erc-track-switch-direction is + 'importance, call erc-track-sort-by-importance. + (erc-track-face-priority): New function that returns a number + indicating the position of a face in erc-track-faces-priority-list. + (erc-track-sort-by-importance): New function that sorts + erc-modified-channels-list according to erc-track-face-priority. + (erc-track-get-active-buffer): Make 'oldest a rough opposite of + 'importance. + +2007-08-14 Jeremy Maitin-Shepard + + * erc-track.el (erc-track-remove-disconnected-buffers): New + variable which controls whether buffers associated with a server + that is disconnected should be removed from + `erc-modified-channels-alist'. Existing behavior is to + unconditionally remove such buffers, which is achieved by setting + `erc-track-removed-disconnected-buffers' to t. When set to t, + which is the new default value, such buffers remain in the list, + which I think is often the desired behavior, since the user may + likely wish to find out about activity that occurred in a channel + prior to it being disconnected. + (erc-track-list-changed-hook): New hook that is run whenever the + contents of `erc-modified-channels-alist' changes; it is useful + for users such as myself that don't use the default mode-line + notification but instead use a separate mechanism (which is tied + to my window manager) to provide notification of channel activity. + (erc-track-get-buffer-window): New function that acts as a wrapper + around `get-buffer-window' that handles the `selected-visible' + option of `erc-track-visibility'; previously, the value of + `erc-track-visibility' was passed directly to `get-buffer-window', + which does not support `selected-visible'; consequently, + `selected-visible' was not properly supported. + (erc-track-modified-channels): Fix a bug in the logic for removing + buffers from the list in certain cases. + (erc-track-position-in-mode-line): Add a supported value that + specifies that the tracking information should not be added to the + mode line at all. The value of nil is used to indicate that the + information should not be added at all to the mode line. + (erc-track-add-to-mode-line): Check for position eq to t, rather + than non-nil. + (erc-buffer-visible): Use erc-track-get-buffer-window. + (erc-modified-channels-update): Take + erc-track-remove-disconnected-buffers into account. + (erc-modified-channels-display): Run `erc-track-list-changed-hook'. + + * erc.el (erc-reuse-frames): New option that determines whether + new frames are always created. Defaults to t. This only has an + effect when erc-join-buffer is set to 'frame. + (erc-setup-buffer): Use it. + +2007-08-14 Michael Olson + + * erc-backend.el (erc-server-reconnect): If the server buffer has + been killed, use the current buffer instead. If the current + buffer is not an ERC buffer, give an error. This fixes a bug when + /reconnect is run from a channel buffer whose server buffer has + been deleted. Thanks to jbms for the report. + (erc-process-sentinel-1): Take server buffer as an argument, so + that we can make sure that it is current. + (erc-process-sentinel): Pass buffer to erc-process-sentinel-1. + (erc-process-sentinel-2): New function split from + erc-process-sentinel-1. If server buffer is deleted during a + reconnect attempt, stop trying to reconnect. Fix bug where + reconnect was not happening when erc-server-reconnect-attempts was + t. Call erc-server-reconnect-p only once each time. If we are + instructed to try connecting indefinitely, tell the user that they + can stop this by killing the server buffer. Call the process + sentinel by means of run-at-time, so that there is time to kill + the buffer if need be; this also removes the need for a while + loop. Refuse to reconnect again if erc-server-reconnect-timeout + is not an number. + + * erc.el (erc-command-no-process-p): Fix bug: the return value of + erc-extract-command-from-line is a list rather than a single + symbol. Thanks to jbms for the report. + (erc-cmd-RECONNECT): Use simpler logic, and use buffer-live-p + rather than bufferp. + (erc-send-current-line, erc-display-command, erc-display-msg): + Handle case where erc-server-process is nil, so that /reconnect + works. + +2007-08-12 Michael Olson + + * erc-identd.el (erc-identd-filter): Instead of sending an EOF + character, which now confuses freenode, stop the server process, + so that no new connections are accepted, and kill the current + client process. + +2007-07-29 Michael Olson + + * erc-list.el: Relicense to GPLv3. Since the file was already + licensed under version 2 or later, it turns out that we do not + need the permission of all of the authors in order to proceed. + +2007-07-13 Michael Olson + + * erc-goodies.el (erc-get-bg-color-face, erc-get-fg-color-face): + Use erc-error rather than message and beep. + + * erc-sound.el: Indentation fix. + + * erc.el (erc-command-no-process-p): New function that determines + if its argument is an ERC command that can be run when the server + process is not alive. + (erc-cmd-SET, erc-cmd-CLEAR, erc-cmd-COUNTRY, erc-cmd-HELP) + (erc-cmd-LASTLOG, erc-cmd-QUIT, erc-cmd-GQUIT) + (erc-cmd-RECONNECT, erc-cmd-SERVER): Denote that these commands + can be run even when the server process is not alive. + (erc-send-current-line): Call erc-command-no-process-p if the + server process is not alive, to determine if we have a command + that can be run anyway. Thanks to Tom Tromey for the bug report. + (erc-error): New function that either displays a message or throws + an error, depending on whether debug-on-error is non-nil. + (erc-cmd-SERVER, erc-send-current-line): Use it. + +2007-07-10 Michael Olson + + * Relicense all FSF-assigned code to GPLv3. + +2007-06-25 Michael Olson + + * erc.texi (Options): Fix typo. + (Getting Help and Reporting Bugs): Update webpage URL. Make Gmane + part more readable. + +2007-06-20 Michael Olson + + * erc-stamp.el (erc-timestamp-format-left): New option that + specifies the left timestamp to use for + erc-insert-timestamp-left-and-right. + (erc-timestamp-format-right): New option that specifies the right + timestamp to use for erc-insert-timestamp-left-and-right. + (erc-insert-timestamp-function): Change default to + erc-insert-timestamp-left-and-right. + (erc-insert-away-timestamp-function): Ditto. + (erc-timestamp-last-inserted-left) + (erc-timestamp-last-inserted-right): New variables to keep track + of data for erc-insert-timestamp-left-and-right. + (erc-insert-timestamp-left-and-right): New function that places + timestamps on both the left and right sides of the screen, but + only if each timestamp has changed since it was last computed. + Thanks to offby1 for urging me to merge this. + + * erc.el (erc-open-ssl-stream): Display informative error when + ssl.el not found. + (erc-tls): New function to connect using tls.el. + (erc-open-tls-stream): New function to initiate tls connection. + Display informative error when tls.el not found. + +2007-06-19 Michael Olson + + * erc-log.el: Update header with accurate instructions. + +2007-06-17 Michael Olson + + * erc-pkg.el: Update description to match what is currently in ELPA. + +2007-06-14 Juanma Barranquero + + * erc-goodies.el (erc-scroll-to-bottom): Remove redundant check. + +2007-06-13 Michael Olson + + * erc-compat.el (erc-with-selected-window): New compatibility + macro that implements `with-selected-window'. + + * erc-goodies.el (erc-scroll-to-bottom): Use it. This fixes a bug + with buffer ordering where ERC buffers would move to the top. + Thanks to Ivan Kanis for the patch. + +2007-06-10 Michael Olson + + * erc-log.el (erc-logging-enabled): Fix a bug that occurred when + `erc-log-channels-directory' had the name of a function. + +2007-06-06 Juanma Barranquero + + * erc.el (erc-show-channel-key-p, erc-startup-file-list): + Fix typo in docstring. + +2007-06-03 Michael Olson + + * erc-compat.el (erc-view-mode-enter): Make this its own function, + in order to document what we do, and provide sane fallback + behavior. + + * erc.el (erc-toggle-debug-irc-protocol): Don't pass any arguments + to erc-view-mode-enter, since we don't do anything special with + the exit function. This fixes a bug with Emacs 21 and Emacs 22. + Thanks to Leo for noticing. + +2007-05-30 Michael Olson + + * erc-compat.el (erc-user-emacs-directory): New variable that + determines where to find user-specific Emacs settings. For Emacs, + this is usually ~/.emacs.d, and for XEmacs this is usually + ~/.xemacs. + + * erc.el (erc-startup-file-list): Use erc-user-emacs-directory. + +2007-05-28 Michael Olson + + * erc-button.el (erc-button-url-regexp): Recognize parentheses as + part of URLs. Thanks to Lawrence Mitchell for the fix. + +2007-05-26 Michael Olson + + * erc.texi (Modules): Fix references to completion modules. + +2007-05-21 Michael Olson + + * Makefile (SOURCE): Remove erc-pkg.el. + (debclean): New rule to clean old Debian packages of ERC. + (debprepare): Don't modify the released tarball, but copy it as + the .orig.tar.gz file. + (debrelease, debrevision): Remove. + (debinstall): New target that copies the generated Debian file to + a distro-specific location. + (deb): New rule that chains together the stages in building a + Debian package. + (EXTRAS): Add erc-nicklist.el, since it is not release-quality. + (extras): Copy images directory. + + * erc-nicklist.el (erc-nicklist-icons-directory): Use + locate-library to find the "images" directory. This should be + more failsafe. Thanks to Tom Tromey for the idea. + +2007-05-19 Michael Olson + + * Makefile (ELPA): New variable that contains the location of my + local ELPA repository. + (elpa): New rule that makes an ELPA package for ERC. + +2007-04-19 Michael Olson + + * erc.el (erc-parse-prefix): New function that retrieves the + PREFIX server parameter from the current server and returns an + alist of prefix type to prefix character. + (erc-channel-receive-names): Use `erc-parse-prefix' to determine + whether the first character of a nick is a prefix character or + not. This should fix a bug reported by bromine about needing to + type "%" first to complete nicks of people who are "hops" on + Slashnet. This should also support for very exotic IRC server + setups, if any exist. + (erc-update-current-channel-member): Indentation. + +2007-04-15 Michael Olson + + * erc-log.el (erc-generate-log-file-name-function): Docfix. + Mention how to deal with the case for putting log files in + different directories. Change a customization type from `symbol' + to `function'. + (erc-log-channels-directory): Allow this to contain a function + name, which is called with the same args as in + `erc-generate-log-file-name-function'. Thanks to andrewy for the + report and use case. + (erc-current-logfile): Detect if `erc-log-channels-directory' is a + function and call it with arguments if so. + +2007-04-12 Michael Olson + + * erc-backend.el (define-erc-response-handler): Mention that hook + processing stops when the function returns non-nil. This should + help avoid a nasty "gotcha" when making custom functions. Thanks + to John Sullivan for the report. + +2007-04-08 Diane Murray + + * erc-nicklist.el (erc-nicklist-voiced-position): Fixed + customization mismatch. + +2007-04-01 Michael Olson + + * erc.el (erc-version-string): Release ERC 5.2. + + * erc-auto.in, erc-chess.el, erc-list.el, erc-speak.el: + * erc-viper.el: Update copyright notices. + + * erc.texi: Make Emacs Lisp source code in this document + essentially public domain. Update version to 5.2. + (Obtaining ERC): Mention extras tarball. + (Releases): Mention local GNU mirror. + (Sample Configuration): Remove notice. + + * FOR-RELEASE (5.3): Add item for erc-nicklist. + Mark NEWS as done. Mark extras tarball as done. + + * Makefile (VERSION): Increment to 5.2. + (TESTING): Remove. + (EXTRAS): New variable containing the contents of our "Emacs 22 + extras" tarball. + (SOURCE): Remove $(TESTING). + (MISC): Add COPYING and ChangeLog.06. Fix ChangeLog.NNNN -> + ChangeLog.NN. + (release): Use $(SNAPDIR) instead of erc-$(VERSION). + (extras): New rule which implements the building of the extras + tarball. + (upload-extras): New rule to upload the extras tarball. It's + yucky to replicate upload, but oh well. + (DISTRIBUTOR): New variable used to differentiate between building + packages for Ubuntu and Debian. + (debrelease, debrevision): Use it. + (debbuild): Run linda in addition to lintian. + + * NEWS: Mention extras tarball. Note which files have been + renamed. Note that erc-list is enabled by default, except in + Emacs 22. + + * README.extras: New file which serves as a README for the extras + tarball. + +2007-03-31 Michael Olson + + * NEWS: Update for the 5.2 release. + + * FOR-RELEASE: Finish up 5.2 manual item. Add documentation item + for 5.3. + + * erc.texi (Sample Session): Flesh out. Mention #erc. + (Modules): Defer to 5.3 release. + (Advanced Usage): Move Sample Configuration chapter ahead of + unfinished chapters. + (Sample Configuration): Write. + (Options): Mention how to see available ERC options. Defer to 5.3 + release. + (Tips and Tricks): Remove, since it seems better to just include + tips and tricks in the sample configuration, commented out. + + * erc-bbdb.el (erc-bbdb-search-name-and-create): Make prompt more + informative about how to skip merging. + (erc-bbdb-insinuate-and-show-entry-1): Move contents of + erc-bbdb-insinuate-and-show-entry here. + (erc-bbdb-insinuate-and-show-entry): Run + erc-bbdb-insinuate-and-show-entry-1 "outside" of the calling + function, so that we can avoid triggering a process-filter error + if the user hits C-g. + +2007-03-30 Michael Olson + + * FOR-RELEASE: Solve C-c C-SPC keybinding dilemma. + + * erc-autoaway.el (erc-autoaway-idle-method): Use `if' rather than + `cond' and `set' rather than `set-default'. + + * erc-log.el: Avoid compiler warning by requiring erc-network + during compilation. + (erc-generate-log-file-name-function): Add tag to each option. + Add erc-generate-log-file-name-network. + (erc-generate-log-file-name-network): New function which generates + a log file name that uses network name rather than server name, + when possible. + + * erc-track.el (track): Assimilate track-when-inactive module, + since there's no need to have two modules in one file -- an option + will do. Remove track-modified-channels alias. Call + erc-track-minor-mode-maybe, and tear down the minor mode when + disabling. + (erc-track-when-inactive): New option which determines whether to + track visible buffers when inactive. The default is not to do so. + (erc-track-visibility): Mention erc-track-when-inactive. + (erc-buffer-visible): Use erc-track-when-inactive. + (erc-track-enable-keybindings): New option which determines + whether to enable the global-level tracking keybindings. The + default is to do so, unless they would override another binding, + in which case we prompt the user about it. + (erc-track-minor-mode-map): Move global keybindings here. + (erc-track-minor-mode): New minor mode which only enables the + keybindings and does nothing else. + (erc-track-minor-mode-maybe): New function which starts + erc-track-minor-mode, but only if it hasn't already been started, + an ERC buffer exists, and the user OK's it, depending on the value + of `erc-track-enable-keybindings'. + (erc-track-switch-buffer): Display a message if someone calls this + without first enabling erc-track-mode. + +2007-03-17 Michael Olson + + * erc.texi (Development): Mention ErcDevelopment page on + emacswiki. + (Getting Started): Mention ~/.emacs.d/.ercrc.el and the Customize + interface. + (Sample Session): New section that has a very rough draft for a + sample ERC session. + (Special Features): New section that explains some of the special + features of ERC. Taken from ErcFeatures on emacswiki, with + enhancements. + +2007-03-12 Diane Murray + + * erc-autoaway.el (erc-autoaway-idle-method): When setting the new + value, disable and re-enable `erc-autoaway-mode' only if it was + already enabled. This fixes a bug where autoaway was enabled just + by loading the file. + +2007-03-10 Diane Murray + + * erc-capab.el: Added more information to the Usage section. + (erc-capab-identify-prefix): Doc fix. + (erc-capab-identify-unidentified): New face. + (290): Removed. Definition moved to erc-backend.el. + (erc-capab-identify-send-messages): Renamed from + `erc-capab-send-identify-messages'. + (erc-capab-identify-setup): Use it. + (erc-capab-identify-get-unidentified-nickname): Renamed from + `erc-capab-get-unidentified-nickname'. + (erc-capab-identify-add-prefix): Use it. Use + `erc-capab-identify-unidentified' as the face. + + * erc-backend.el (290): Moved here from erc-capab.el. + + * erc.el (erc-select): Added an autoload cookie. + (erc-message-type-member, erc-restore-text-properties): Use + `erc-get-parsed-vector'. + (erc-auto-query): Set the default to 'bury since many new users + expect private messages from others to be in dedicated query + buffers, not the server buffer. + (erc-common-server-suffixes): Use "freenode" for freenode.net, not + "OPN". Added oftc.net. + + * NEWS: Added note about erc-auto-query's new default setting. + +2007-03-03 Michael Olson + + * erc.el (erc-open, erc): Docfixes. + +2007-03-02 Michael Olson + + * FOR-RELEASE: Make section for 5.3 release and move erc-backend + cleanup there. Awaiting discussion before doing other things. + Add tasks for merging filename changes from the 5.2 release + branch, and for making a tarball of modules not in Emacs 22. Add + item to remind me to update NEWS. Mark backtab entry as done. + + * erc-button.el (button): Add call to `erc-button-add-keys'. + (erc-button-keys-added): New variable tracking whether we've added + the keys yet. + (erc-button-add-keys): New function that adds the key to + erc-mode-map. + + * erc.texi: Change version to 5.2 (pre-release). + +2007-02-15 Michael Olson + + * CREDITS: Update. + + * erc-backend.el (erc-server-send-ping-interval): Change to use a + default of 30 seconds. Improve customize interface. + (erc-server-send-ping-timeout): New option that determines when to + consider a connection stalled and restart it. The default is + after 120 seconds. + (erc-server-send-ping): Use erc-server-send-ping-timeout instead + of erc-server-send-ping-interval. If + erc-server-send-ping-timeout is nil, do not ever kill and restart + a hung IRC process. + + * erc.el (erc-modules): Include the name of the module in its + description. This should make it easier for people to find and + enable a particular module. + +2007-02-15 Vivek Dasmohapatra + + * erc.el (erc-cmd-RECONNECT): Kill old process if it is still + alive. + (erc-message-english-PART): Properly escape "%" characters in + reason. + + * erc-backend.el (erc-server-reconnecting): New variable that is + set when the user requests a reconnect, but the old process is + still alive. This forces the reconnect to work even though the + process is killed manually during reconnect. + (erc-server-connect): Initialize it. + (erc-server-reconnect-p): Use it. + (erc-process-sentinel-1): Set it to nil after the first reconnect + attempt. + +2007-02-07 Diane Murray + + * erc-menu.el (erc-menu-definition): Fixed so that the separator + is between "Current channel" and "Pals, fools and other keywords", + not at the bottom of the "Current channel" submenu. + +2007-01-25 Diane Murray + + * erc-networks.el (erc-server-alist): Removed SSL server for now + since `erc-server-select' doesn't know to use `erc-ssl'. + + * erc-networks.el (erc-server-alist, erc-networks-alist): Added + definitions for oftc.net. + + * erc-services.el (erc-nickserv-alist): Fixed OFTC message regexp. + +2007-01-22 Michael Olson + + * erc-backend.el (erc-server-error-occurred): New variable that + indicates when an error has been signaled by the server. This + should fix an infinite reconnect bug when giving some servers a + bogus :full-name. Thanks to Angelina Carlton for the report. + (erc-server-connect): Initialize erc-server-error-occurred. + (erc-server-reconnect-p): Use it. + (ERROR): Set it. + + * erc-services.el (erc-nickserv-alist): Alphabetize and add Ars + and QuakeNet. Standardize look of entries. Fix type mismatch + error in customize interface. + (erc-nickserv-passwords): Alphabetize and add missing entries from + erc-nickserv-alist. + +2007-01-21 Michael Olson + + * erc.el (erc-header-line-format): Document how to disable the + header line, and add a customization type for it. Also, make the + changes take effect immediately. + +2007-01-19 Michael Olson + + * erc.texi (Modules): Document new menu module. Thanks to Leo + for noticing. + +2007-01-16 Diane Murray + + * erc-stamp.el (erc-insert-timestamp-left): Fixed so that the + whitespace string filler is hidden correctly when timestamps are + hidden. + (erc-toggle-timestamps): New function to use instead of + `erc-show-timestamps' and `erc-hide-timestamps'. + + * erc.el (erc-restore-text-properties): Moved here from + erc-fill.el since it could be useful in general. + + * erc-fill.el (erc-restore-text-properties): Removed. + +2007-01-13 Michael Olson + + * erc.el (erc-command-regexp): New variable that is used to match + a command. + (erc-send-input): Use it. This fixes a bug where paths -- + "/usr/bin/foo", for example -- were being displayed as commands, + but still sent correctly. + (erc-extract-command-from-line): Use it. + + * erc.texi (Modules): Document erc-capab-identify. + +2007-01-11 Diane Murray + + * erc.el (erc-find-parsed-property): Moved here from erc-track.el + since it can be useful in general. + + * erc-track.el (erc-find-parsed-property): Removed. + + * erc-capab.el (erc-capab-find-parsed): Removed. + (erc-capab-identify-add-prefix): Use `erc-find-parsed-property'. + + * erc.el (erc-open): Run `erc-before-connect' hook here. This + makes sure the hook always gets called before a connection is + made, as some functions, like `erc-handle-irc-url', use `erc-open' + instead of `erc'. + (erc): Removed `erc-before-connect' hook. + + * erc-menu.el (erc-menu-definition): Put items specific to + channels in a "Current channel" submenu. + + * erc-backend.el (321, 323): Display channel list in server buffer + when not using the channel list module. + + * erc.el: Updated copyright years. + (erc-version-string): Set to 5.2 (devel). + (erc-format-lag-time): Fixed to work when `erc-server-lag' is nil. + (erc-update-mode-line-buffer): Set the header face. + +2007-01-11 Michael Olson + + * erc-bbdb.el (erc-bbdb-popup-type): Fix customization type and + documentation. + + * erc-services.el (erc-nickserv-identify-mode): Improve + documentation for nick-change option and move higher to fix + compiler warning. Avoid a recursive load error. + (erc-nickserv-alist): Add simple entry for BitlBee, to avoid + "NickServ is AWAY: User is offline" error. Oddly enough, bitlbee + was smart enough to recognize that as an authentication request + and log in regardless, which is why I didn't notice this earlier. + (erc-nickserv-alist-sender, erc-nickserv-alist-regexp) + (erc-nickserv-alist-nickserv, erc-nickserv-alist-ident-keyword) + (erc-nickserv-alist-use-nick-p) + (erc-nickserv-alist-ident-command): New accessors for + erc-nickserv-alist. Using nth is unwieldy. + (erc-nickserv-identify-autodetect) + (erc-nickserv-identify-on-connect) + (erc-nickserv-identify-on-nick-change, erc-nickserv-identify): Use + the new accessors. + +2007-01-11 Diane Murray + + * NEWS: Added note for `erc-my-nick-face'. Fixed capab-identify + wording. + +2007-01-10 Diane Murray + + * erc.el (erc-mode-line-format): Added %l to documentation. + (erc-header-line-format): Removed "[IRC]". Use the new %l + replacement character. Doc fix. + (erc-format-channel-modes): Removed lag code. Removed parentheses + from mode string. + (erc-format-lag-time): New function. + (erc-update-mode-line-buffer): Use it. + +2007-01-10 Michael Olson + + * erc.el: Fix typo in url-irc-function instructions. + +2007-01-09 Michael Olson + + * erc.el (erc-system-name): New option that determines the system + name to use when logging in. The default is to figure this out by + calling `system-name'. + (erc-login): Use it. + +2007-01-07 Michael Olson + + * erc.el (erc-modules): Add the menu module. This should fix a + bug with incorrect ERC submenus being displayed. + + * erc-menu.el: Turn this into a module. + (erc-menu-add, erc-menu-remove): New functions that add and remove + the ERC menu. + + +See ChangeLog.06 for earlier changes. + + Copyright (C) 2007, 2008 Free Software Foundation, Inc. + + This file is part of GNU Emacs. + + GNU Emacs is free software; you can redistribute it and/or modify + it under the terms of the GNU General Public License as published by + the Free Software Foundation; either version 3, or (at your option) + any later version. + + GNU Emacs is distributed in the hope that it will be useful, + but WITHOUT ANY WARRANTY; without even the implied warranty of + MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + GNU General Public License for more details. + + You should have received a copy of the GNU General Public License + along with GNU Emacs; see the file COPYING. If not, write to the + Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, + Boston, MA 02110-1301, USA. + +;; Local Variables: +;; coding: utf-8 +;; add-log-time-zone-rule: t +;; End: + +;; arch-tag: 3369b6e5-96b1-4b32-96cd-9a905c747496 diff --git a/lisp/erc/erc-backend.el b/lisp/erc/erc-backend.el index 5fe0efd1c94..1bb3e4aada2 100644 --- a/lisp/erc/erc-backend.el +++ b/lisp/erc/erc-backend.el @@ -332,11 +332,10 @@ This is either a coding system, a cons, a function, or nil. If a cons, the encoding system for outgoing text is in the car and the decoding system for incoming text is in the cdr. The most -interesting use for this is to put `undecided' in the cdr. If a -function, it is called with no arguments and should return a -coding system or a cons as described above. Note that you can use -the dynamically bound variable `target' to get the current -target. See `erc-coding-system-for-target'. +interesting use for this is to put `undecided' in the cdr. + +If a function, it is called with the argument `target' and should +return a coding system or a cons as described above. If you need to send non-ASCII text to people not using a client that does decoding on its own, you must tell ERC what encoding to use. @@ -491,6 +490,8 @@ We will store server variables in the buffer given by BUFFER." (let ((process (funcall erc-server-connect-function (format "erc-%s-%s" server port) nil server port))) + (unless (processp process) + (error "Connection attempt failed")) (message "%s...done" msg) ;; Misc server variables (with-current-buffer buffer @@ -686,7 +687,7 @@ This is determined via `erc-encoding-coding-alist' or (when (string-match (car pat) target) (throw 'match (cdr pat))))))) (and (functionp erc-server-coding-system) - (funcall erc-server-coding-system)) + (funcall erc-server-coding-system target)) erc-server-coding-system)) (defun erc-decode-string-from-target (str target) @@ -1649,8 +1650,13 @@ See `erc-display-server-message'." nil (define-erc-response-handler (321) "LIST header." nil - (setq erc-channel-list nil) - (erc-display-message parsed 'notice proc 's321)) + (setq erc-channel-list nil)) + +(defun erc-server-321-message (proc parsed) + "Display a message for the 321 event." + (erc-display-message parsed 'notice proc 's321) + nil) +(add-hook 'erc-server-321-functions 'erc-server-321-message t) (define-erc-response-handler (322) "LIST notice." nil @@ -1658,10 +1664,17 @@ See `erc-display-server-message'." nil (multiple-value-bind (channel num-users) (cdr (erc-response.command-args parsed)) (add-to-list 'erc-channel-list (list channel)) - (erc-update-channel-topic channel topic) + (erc-update-channel-topic channel topic)))) + +(defun erc-server-322-message (proc parsed) + "Display a message for the 322 event." + (let ((topic (erc-response.contents parsed))) + (multiple-value-bind (channel num-users) + (cdr (erc-response.command-args parsed)) (erc-display-message parsed 'notice proc 's322 ?c channel ?u num-users ?t (or topic ""))))) +(add-hook 'erc-server-322-functions 'erc-server-322-message t) (define-erc-response-handler (324) "Channel or nick modes." nil diff --git a/lisp/erc/erc-button.el b/lisp/erc/erc-button.el index a74d56b90bd..7e45c6cd4ea 100644 --- a/lisp/erc/erc-button.el +++ b/lisp/erc/erc-button.el @@ -57,16 +57,15 @@ ((add-hook 'erc-insert-modify-hook 'erc-button-add-buttons 'append) (add-hook 'erc-send-modify-hook 'erc-button-add-buttons 'append) (add-hook 'erc-complete-functions 'erc-button-next) - (add-hook 'erc-mode-hook 'erc-button-add-keys)) + (add-hook 'erc-mode-hook 'erc-button-setup)) ((remove-hook 'erc-insert-modify-hook 'erc-button-add-buttons) (remove-hook 'erc-send-modify-hook 'erc-button-add-buttons) (remove-hook 'erc-complete-functions 'erc-button-next) - (remove-hook 'erc-mode-hook 'erc-button-add-keys))) - -;; Make XEmacs use `erc-button-face'. -(when (featurep 'xemacs) - (add-hook 'erc-mode-hook - (lambda () (set (make-local-variable 'widget-button-face) nil)))) + (remove-hook 'erc-mode-hook 'erc-button-setup) + (when (featurep 'xemacs) + (dolist (buffer (erc-buffer-list)) + (with-current-buffer buffer + (kill-local-variable 'widget-button-face)))))) ;;; Variables @@ -247,8 +246,12 @@ constituents.") "Internal variable used to keep track of whether we've added the global-level ERC button keys yet.") -(defun erc-button-add-keys () +(defun erc-button-setup () "Add ERC mode-level button movement keys. This is only done once." + ;; Make XEmacs use `erc-button-face'. + (when (featurep 'xemacs) + (set (make-local-variable 'widget-button-face) nil)) + ;; Add keys. (unless erc-button-keys-added (define-key erc-mode-map (kbd "") 'erc-button-previous) (setq erc-button-keys-added t))) @@ -299,9 +302,10 @@ specified by `erc-button-alist'." (setq bounds (bounds-of-thing-at-point 'word)) (setq word (buffer-substring-no-properties (car bounds) (cdr bounds))) - (if (erc-get-server-user word) - (erc-button-add-button (car bounds) (cdr bounds) - fun t (list word))))))) + (when (or (and (erc-server-buffer-p) (erc-get-server-user word)) + (and erc-channel-users (erc-get-channel-user word))) + (erc-button-add-button (car bounds) (cdr bounds) + fun t (list word))))))) (defun erc-button-add-buttons-1 (regexp entry) "Search through the buffer for matches to ENTRY and add buttons." diff --git a/lisp/erc/erc-compat.el b/lisp/erc/erc-compat.el index d99d8fca7da..dd01280b3aa 100644 --- a/lisp/erc/erc-compat.el +++ b/lisp/erc/erc-compat.el @@ -88,53 +88,6 @@ See `replace-match' for explanations of FIXEDCASE and LITERAL." (defalias 'erc-make-obsolete 'make-obsolete) (defalias 'erc-make-obsolete-variable 'make-obsolete-variable) -;; Provde an equivalent of `assert', based on the code from cl-macs.el -(defun erc-const-expr-p (x) - (cond ((consp x) - (or (eq (car x) 'quote) - (and (memq (car x) '(function function*)) - (or (symbolp (nth 1 x)) - (and (eq (and (consp (nth 1 x)) - (car (nth 1 x))) 'lambda) 'func))))) - ((symbolp x) (and (memq x '(nil t)) t)) - (t t))) - -(put 'erc-assertion-failed 'error-conditions '(error)) -(put 'erc-assertion-failed 'error-message "Assertion failed") - -(defun erc-list* (arg &rest rest) - "Return a new list with specified args as elements, cons'd to last arg. -Thus, `(list* A B C D)' is equivalent to `(nconc (list A B C) D)', or to -`(cons A (cons B (cons C D)))'." - (cond ((not rest) arg) - ((not (cdr rest)) (cons arg (car rest))) - (t (let* ((n (length rest)) - (copy (copy-sequence rest)) - (last (nthcdr (- n 2) copy))) - (setcdr last (car (cdr last))) - (cons arg copy))))) - -(defmacro erc-assert (form &optional show-args string &rest args) - "Verify that FORM returns non-nil; signal an error if not. -Second arg SHOW-ARGS means to include arguments of FORM in message. -Other args STRING and ARGS... are arguments to be passed to `error'. -They are not evaluated unless the assertion fails. If STRING is -omitted, a default message listing FORM itself is used." - (let ((sargs - (and show-args - (delq nil (mapcar - (function - (lambda (x) - (and (not (erc-const-expr-p x)) x))) - (cdr form)))))) - (list 'progn - (list 'or form - (if string - (erc-list* 'error string (append sargs args)) - (list 'signal '(quote erc-assertion-failed) - (erc-list* 'list (list 'quote form) sargs)))) - nil))) - ;; Provide a simpler replacement for `member-if' (defun erc-member-if (predicate list) "Find the first item satisfying PREDICATE in LIST. diff --git a/lisp/erc/erc-dcc.el b/lisp/erc/erc-dcc.el index 8158c0999d3..2aca06479f6 100644 --- a/lisp/erc/erc-dcc.el +++ b/lisp/erc/erc-dcc.el @@ -60,6 +60,12 @@ (require 'cl) (require 'pcomplete)) +;;;###autoload (autoload 'erc-dcc-mode "erc-dcc") +(define-erc-module dcc nil + "Provide Direct Client-to-Client support for ERC." + ((add-hook 'erc-server-401-functions 'erc-dcc-no-such-nick)) + ((remove-hook 'erc-server-401-functions 'erc-dcc-no-such-nick))) + (defgroup erc-dcc nil "DCC stands for Direct Client Communication, where you and your friend's client programs connect directly to each other, @@ -70,7 +76,7 @@ Using DCC get and send, you can transfer files directly from and to other IRC users." :group 'erc) -(defcustom erc-verbose-dcc t +(defcustom erc-dcc-verbose nil "*If non-nil, be verbose about DCC activity reporting." :group 'erc-dcc :type 'boolean) @@ -195,20 +201,22 @@ compared with `erc-nick-equal-p' which is IRC case-insensitive." (setq list (cdr list))))) result)) -;; msa wrote this nifty little frob to convert an n-byte integer to a packed -;; string. -(defun erc-pack-int (value count) - (if (> count 0) - (concat (erc-pack-int (/ value 256) (1- count)) - (char-to-string (% value 256))) - "")) +(defun erc-pack-int (value) + "Convert an integer into a packed string." + (let* ((len (ceiling (/ value 256.0))) + (str (make-string len ?a)) + (i (1- len))) + (while (>= i 0) + (aset str i (% value 256)) + (setq value (/ value 256)) + (setq i (1- i))) + str)) (defun erc-unpack-int (str) - "Unpack a 1-4 character packed string into an integer." + "Unpack a packed string into an integer." (let ((len (length str)) (num 0) (count 0)) - (erc-assert (<= len 4)) ;; this isn't going to fit in elisp bounds (while (< count len) (setq num (+ num (lsh (aref str (- len count 1)) (* 8 count)))) (setq count (1+ count))) @@ -256,15 +264,24 @@ The result is also a string." ;;; Server code -(defcustom erc-dcc-host nil - "*IP address to use for outgoing DCC offers. -Should be set to a string or nil, if nil, automatic detection of the -host interface to use will be attempted." +(defcustom erc-dcc-listen-host nil + "IP address to listen on when offering files. +Should be set to a string or nil. If nil, automatic detection of +the host interface to use will be attempted." :group 'erc-dcc :type (list 'choice (list 'const :tag "Auto-detect" nil) (list 'string :tag "IP-address" :valid-regexp erc-dcc-ipv4-regexp))) +(defcustom erc-dcc-public-host nil + "IP address to use for outgoing DCC offers. +Should be set to a string or nil. If nil, use the value of +`erc-dcc-listen-host'." + :group 'erc-dcc + :type (list 'choice (list 'const :tag "Same as erc-dcc-listen-host" nil) + (list 'string :tag "IP-address" + :valid-regexp erc-dcc-ipv4-regexp))) + (defcustom erc-dcc-send-request 'ask "*How to treat incoming DCC Send requests. 'ask - Report the Send request, and wait for the user to manually accept it @@ -282,7 +299,7 @@ host interface to use will be attempted." "Determine the IP address we are using. If variable `erc-dcc-host' is non-nil, use it. Otherwise call `erc-dcc-get-host' on the erc-server-process." - (or erc-dcc-host (erc-dcc-get-host erc-server-process) + (or erc-dcc-listen-host (erc-dcc-get-host erc-server-process) (error "Unable to determine local address"))) (defcustom erc-dcc-port-range nil @@ -311,6 +328,7 @@ created subprocess, or nil." process) (while (not process) (condition-case err + (progn (setq process (make-network-process :name name :buffer nil @@ -322,6 +340,11 @@ created subprocess, or nil." :sentinel sentinel :log #'erc-dcc-server-accept :server t)) + (when (processp process) + (when (fboundp 'set-process-coding-system) + (set-process-coding-system process 'binary 'binary)) + (when (fboundp 'set-process-filter-multibyte) + (set-process-filter-multibyte process nil)))) (file-error (unless (and (string= "Cannot bind server socket" (cadr err)) (string= "address already in use" (caddr err))) @@ -698,7 +721,7 @@ bytes sent." (confirmed-marker (plist-get elt :sent)) (sent-marker (plist-get elt :sent))) (with-current-buffer (process-buffer proc) - (when erc-verbose-dcc + (when erc-dcc-verbose (erc-display-message nil 'notice (erc-dcc-get-parent proc) (format "DCC: Confirmed %d, sent %d, sending block now" @@ -713,8 +736,7 @@ bytes sent." (length string))))) (defun erc-dcc-send-filter (proc string) - (erc-assert (= (% (length string) 4) 0)) - (let* ((size (erc-unpack-int (substring string (- (length string) 4)))) + (let* ((size (erc-unpack-int string)) (elt (erc-dcc-member :peer proc)) (parent (plist-get elt :parent)) (sent-marker (plist-get elt :sent)) @@ -742,16 +764,21 @@ bytes sent." ((> confirmed-marker sent-marker) (erc-display-message nil 'notice parent - (format "DCC: Client confirmed too much!")) + (format "DCC: Client confirmed too much (%s vs %s)!" + (marker-position confirmed-marker) + (marker-position sent-marker))) + (set-buffer-modified-p nil) + (kill-buffer (current-buffer)) (delete-process proc)))))) +(defun erc-dcc-display-send (proc) + (erc-display-message + nil 'notice (erc-dcc-get-parent proc) + (format "DCC: SEND connect from %s" + (format-network-address (process-contact proc :remote))))) + (defcustom erc-dcc-send-connect-hook - '((lambda (proc) - (erc-display-message - nil 'notice (erc-dcc-get-parent proc) - (format "DCC: SEND connect from %s" - (format-network-address (process-contact proc :remote))))) - erc-dcc-send-block) + '(erc-dcc-display-send erc-dcc-send-block) "*Hook run whenever the remote end of a DCC SEND offer connected to your listening port." :group 'erc-dcc @@ -762,14 +789,14 @@ listening port." (erc-extract-nick (plist-get plist :nick))) (defun erc-dcc-send-sentinel (proc event) - (let* ((elt (erc-dcc-member :peer proc)) - (buf (marker-buffer (plist-get elt :sent)))) + (let* ((elt (erc-dcc-member :peer proc))) (cond ((string-match "^open from " event) (when elt - (with-current-buffer buf - (set-process-buffer proc buf) - (setq erc-dcc-entry-data elt)) + (let ((buf (marker-buffer (plist-get elt :sent)))) + (with-current-buffer buf + (set-process-buffer proc buf) + (setq erc-dcc-entry-data elt))) (run-hook-with-args 'erc-dcc-send-connect-hook proc)))))) (defun erc-dcc-find-file (file) @@ -807,15 +834,23 @@ other client." (process-send-string pproc (format "PRIVMSG %s :\C-aDCC SEND %s %s %d %d\C-a\n" nick (erc-dcc-file-to-name file) - (erc-ip-to-decimal (nth 0 contact)) + (erc-ip-to-decimal (or erc-dcc-public-host + (nth 0 contact))) (nth 1 contact) size))) (error "`make-network-process' not supported by your Emacs"))) ;;; GET handling +(defcustom erc-dcc-receive-cache (* 1024 512) + "Number of bytes to let the receive buffer grow before flushing it." + :group 'erc-dcc + :type 'integer) + (defvar erc-dcc-byte-count nil) (make-variable-buffer-local 'erc-dcc-byte-count) +(defvar erc-dcc-file-name nil) +(make-variable-buffer-local 'erc-dcc-file-name) (defun erc-dcc-get-file (entry file parent-proc) "This function does the work of setting up a transfer from the remote client @@ -825,6 +860,7 @@ filter and a process sentinel, and making the connection." proc) (with-current-buffer buffer (fundamental-mode) + (buffer-disable-undo (current-buffer)) ;; This is necessary to have the buffer saved as-is in GNU ;; Emacs. ;; XEmacs change: We don't have `set-buffer-multibyte', setting @@ -835,7 +871,10 @@ filter and a process sentinel, and making the connection." (setq mode-line-process '(":%s") buffer-file-type t buffer-read-only t) - (set-visited-file-name file) + (setq erc-dcc-file-name file) + + ;; Truncate the given file to size 0 before appending to it. + (write-region (point) (point) erc-dcc-file-name nil 'nomessage) (setq erc-server-process parent-proc erc-dcc-entry-data entry) @@ -847,7 +886,6 @@ filter and a process sentinel, and making the connection." (string-to-number (plist-get entry :port)) entry)) (set-process-buffer proc buffer) - ;; The following two lines make saving as-is work under Windows (set-process-coding-system proc 'binary 'binary) (set-buffer-file-coding-system 'binary t) @@ -856,6 +894,14 @@ filter and a process sentinel, and making the connection." (setq entry (plist-put entry :start-time (erc-current-time))) (setq entry (plist-put entry :peer proc))))) +(defun erc-dcc-append-contents (buffer file) + "Append the contents of BUFFER to FILE. +The contents of the BUFFER will then be erased." + (with-current-buffer buffer + (let ((coding-system-for-write 'binary)) + (write-region (point-min) (point-max) erc-dcc-file-name t 'nomessage) + (erase-buffer)))) + (defun erc-dcc-get-filter (proc str) "This is the process filter for transfers from other clients to this one. It reads incoming bytes from the network and stores them in the DCC @@ -868,8 +914,10 @@ rather than every 1024 byte block, but nobody seems to care." (insert (string-make-unibyte str)) (setq erc-dcc-byte-count (+ (length str) erc-dcc-byte-count)) - (erc-assert (= erc-dcc-byte-count (1- (point-max)))) - (and erc-verbose-dcc + (when (> (point-max) erc-dcc-receive-cache) + (erc-dcc-append-contents (current-buffer) erc-dcc-file-name)) + + (and erc-dcc-verbose (erc-display-message nil 'notice erc-server-process 'dcc-get-bytes-received @@ -885,7 +933,7 @@ rather than every 1024 byte block, but nobody seems to care." (delete-process proc)) (t (process-send-string - proc (erc-pack-int erc-dcc-byte-count 4))))))) + proc (erc-pack-int erc-dcc-byte-count))))))) (defun erc-dcc-get-sentinel (proc event) @@ -895,17 +943,18 @@ transfer is complete." ;; FIXME, we should look at EVENT, and also check size. (with-current-buffer (process-buffer proc) (delete-process proc) - (setq buffer-read-only nil) (setq erc-dcc-list (delete erc-dcc-entry-data erc-dcc-list)) + (unless (= (point-min) (point-max)) + (setq erc-dcc-byte-count (+ (buffer-size) erc-dcc-byte-count)) + (erc-dcc-append-contents (current-buffer) erc-dcc-file-name)) (erc-display-message nil 'notice erc-server-process 'dcc-get-complete - ?f (file-name-nondirectory buffer-file-name) - ?s (number-to-string (buffer-size)) + ?f erc-dcc-file-name + ?s (number-to-string erc-dcc-byte-count) ?t (format "%.0f" (erc-time-diff (plist-get erc-dcc-entry-data :start-time) - (erc-current-time)))) - (save-buffer)) + (erc-current-time))))) (kill-buffer (process-buffer proc)) (delete-process proc)) @@ -1126,8 +1175,6 @@ other client." (if (processp peer) (delete-process peer))) nil)) -(add-hook 'erc-server-401-functions 'erc-dcc-no-such-nick) - (provide 'erc-dcc) ;;; erc-dcc.el ends here diff --git a/lisp/erc/erc-goodies.el b/lisp/erc/erc-goodies.el index 9612b001156..ff065467f84 100644 --- a/lisp/erc/erc-goodies.el +++ b/lisp/erc/erc-goodies.el @@ -33,10 +33,14 @@ (require 'erc) -;; Imenu Autoload -(add-hook 'erc-mode-hook - (lambda () - (setq imenu-create-index-function 'erc-create-imenu-index))) +;;; Imenu support + +(defun erc-imenu-setup () + "Setup Imenu support in an ERC buffer." + (set (make-local-variable 'imenu-create-index-function) + 'erc-create-imenu-index)) + +(add-hook 'erc-mode-hook 'erc-imenu-setup) (autoload 'erc-create-imenu-index "erc-imenu" "Imenu index creation function") ;;; Automatically scroll to bottom @@ -51,11 +55,15 @@ argument to `recenter'." :type '(choice integer (const nil))) (define-erc-module scrolltobottom nil - "This mode causes the prompt to stay at the end of the window. -You have to activate or deactivate it in already created windows -separately." - ((add-hook 'erc-mode-hook 'erc-add-scroll-to-bottom)) - ((remove-hook 'erc-mode-hook 'erc-add-scroll-to-bottom))) + "This mode causes the prompt to stay at the end of the window." + ((add-hook 'erc-mode-hook 'erc-add-scroll-to-bottom) + (dolist (buffer (erc-buffer-list)) + (with-current-buffer buffer + (erc-add-scroll-to-bottom)))) + ((remove-hook 'erc-mode-hook 'erc-add-scroll-to-bottom) + (dolist (buffer (erc-buffer-list)) + (with-current-buffer buffer + (remove-hook 'window-scroll-functions 'erc-scroll-to-bottom t))))) (defun erc-add-scroll-to-bottom () "A hook function for `erc-mode-hook' to recenter output at bottom of window. @@ -110,7 +118,46 @@ Put this function on `erc-insert-post-hook' and/or `erc-send-post-hook'." (put-text-property (point-min) (point-max) 'front-sticky t) (put-text-property (point-min) (point-max) 'rear-nonsticky t)) -;; Distinguish non-commands +;;; Move to prompt when typing text +(define-erc-module move-to-prompt nil + "This mode causes the point to be moved to the prompt when typing text." + ((add-hook 'erc-mode-hook 'erc-move-to-prompt-setup) + (dolist (buffer (erc-buffer-list)) + (with-current-buffer buffer + (erc-move-to-prompt-setup)))) + ((remove-hook 'erc-mode-hook 'erc-move-to-prompt-setup) + (dolist (buffer (erc-buffer-list)) + (with-current-buffer buffer + (remove-hook 'pre-command-hook 'erc-move-to-prompt t))))) + +(defun erc-move-to-prompt () + "Move the point to the ERC prompt if this is a self-inserting command." + (when (and erc-input-marker (< (point) erc-input-marker) + (eq 'self-insert-command this-command)) + (deactivate-mark) + (push-mark) + (goto-char (point-max)))) + +(defun erc-move-to-prompt-setup () + "Initialize the move-to-prompt module for XEmacs." + (add-hook 'pre-command-hook 'erc-move-to-prompt nil t)) + +;;; Keep place in unvisited channels +(define-erc-module keep-place nil + "Leave point above un-viewed text in other channels." + ((add-hook 'erc-insert-pre-hook 'erc-keep-place)) + ((remove-hook 'erc-insert-pre-hook 'erc-keep-place))) + +(defun erc-keep-place (ignored) + "Move point away from the last line in a non-selected ERC buffer." + (when (and (not (eq (window-buffer (selected-window)) + (current-buffer))) + (>= (point) erc-insert-marker)) + (deactivate-mark) + (goto-char (erc-beg-of-input-line)) + (forward-line -1))) + +;;; Distinguish non-commands (defvar erc-noncommands-list '(erc-cmd-ME erc-cmd-COUNTRY erc-cmd-SV @@ -496,8 +543,19 @@ channel that has weird people talking in morse to each other. See also `unmorse-region'." (goto-char (point-min)) - (when (re-search-forward "[.-]+\\([.-]+[/ ]\\)+[.-]+" nil t) - (unmorse-region (match-beginning 0) (match-end 0)))) + (when (re-search-forward "[.-]+\\([.-]*/? *\\)+[.-]+/?" nil t) + (save-restriction + (narrow-to-region (match-beginning 0) (match-end 0)) + ;; Turn " / " into " " + (goto-char (point-min)) + (while (re-search-forward " / " nil t) + (replace-match " ")) + ;; Turn "/ " into "/" + (goto-char (point-min)) + (while (re-search-forward "/ " nil t) + (replace-match "/")) + ;; Unmorse region + (unmorse-region (point-min) (point-max))))) ;;; erc-occur (defun erc-occur (string &optional proc) diff --git a/lisp/erc/erc-list.el b/lisp/erc/erc-list.el new file mode 100644 index 00000000000..fc8ec9bf10e --- /dev/null +++ b/lisp/erc/erc-list.el @@ -0,0 +1,227 @@ +;;; erc-list.el --- /list support for ERC + +;; Copyright (C) 2008 Free Software Foundation, Inc. + +;; Author: Tom Tromey +;; Version: 0.1 +;; Keywords: comm + +;; This file is part of ERC. + +;; ERC is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3, or (at your option) +;; any later version. + +;; ERC is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with ERC; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. + +;;; Commentary: + +;; This file provides nice support for /list in ERC. + +;;; Code: + +(require 'erc) + +;; This is implicitly the width of the channel name column. Pick +;; something small enough that the topic has a chance of being +;; readable, but long enough that most channel names won't make for +;; strange formatting. +(defconst erc-list-nusers-column 25) + +;; Width of the number-of-users column. +(defconst erc-list-topic-column (+ erc-list-nusers-column 10)) + +;; The list buffer. This is buffer local in the server buffer. +(defvar erc-list-buffer nil) + +;; The argument to the last "/list". This is buffer local in the +;; server buffer. +(defvar erc-list-last-argument nil) + +;; The server buffer corresponding to the list buffer. This is buffer +;; local in the list buffer. +(defvar erc-list-server-buffer nil) + +;; Define module: +;;;###autoload (autoload 'erc-list-mode "erc-list") +(define-erc-module list nil + "List channels nicely in a separate buffer." + ((remove-hook 'erc-server-321-functions 'erc-server-321-message) + (remove-hook 'erc-server-322-functions 'erc-server-322-message)) + ((erc-with-all-buffers-of-server nil + #'erc-open-server-buffer-p + (remove-hook 'erc-server-322-functions 'erc-list-handle-322 t)) + (add-hook 'erc-server-321-functions 'erc-server-321-message t) + (add-hook 'erc-server-322-functions 'erc-server-322-message t))) + +;; Format a record for display. +(defun erc-list-make-string (channel users topic) + (concat + channel + (erc-propertize " " + 'display (list 'space :align-to erc-list-nusers-column) + 'face 'fixed-pitch) + users + (erc-propertize " " + 'display (list 'space :align-to erc-list-topic-column) + 'face 'fixed-pitch) + topic)) + +;; Insert a record into the list buffer. +(defun erc-list-insert-item (channel users topic) + (save-excursion + (let ((buffer-read-only nil)) + (goto-char (point-max)) + (insert (erc-list-make-string channel users topic) "\n")))) + +(defun erc-list-join () + "Join the irc channel named on this line." + (interactive) + (unless (eobp) + (beginning-of-line) + (unless (looking-at "\\([&#+!][^ \n]+\\)") + (error "Not looking at channel name?")) + (let ((chan (match-string 1))) + (with-current-buffer erc-list-server-buffer + (erc-join-channel chan))))) + +(defun erc-list-kill () + "Kill the current ERC list buffer." + (interactive) + (kill-buffer (current-buffer))) + +(defun erc-list-revert () + "Refresh the list of channels." + (interactive) + (with-current-buffer erc-list-server-buffer + (erc-cmd-LIST erc-list-last-argument))) + +(defun erc-list-menu-sort-by-column (&optional e) + "Sort the channel list by the column clicked on." + (interactive (list last-input-event)) + (if e (mouse-select-window e)) + (let* ((pos (event-start e)) + (obj (posn-object pos)) + (col (if obj + (get-text-property (cdr obj) 'column-number (car obj)) + (get-text-property (posn-point pos) 'column-number)))) + (let ((buffer-read-only nil)) + (if (= col 1) + (sort-fields col (point-min) (point-max)) + (sort-numeric-fields col (point-min) (point-max)))))) + +(defvar erc-list-menu-mode-map nil + "Local keymap for `erc-list-mode' buffers.") + +(unless erc-list-menu-mode-map + (setq erc-list-menu-mode-map (make-keymap)) + (suppress-keymap erc-list-menu-mode-map) + (define-key erc-list-menu-mode-map "k" 'erc-list-kill) + (define-key erc-list-menu-mode-map "j" 'erc-list-join) + (define-key erc-list-menu-mode-map "g" 'erc-list-revert) + (define-key erc-list-menu-mode-map "n" 'next-line) + (define-key erc-list-menu-mode-map "p" 'previous-line) + (define-key erc-list-menu-mode-map "q" 'quit-window)) + +(defvar erc-list-menu-sort-button-map nil + "Local keymap for ERC list menu mode sorting buttons.") + +(unless erc-list-menu-sort-button-map + (let ((map (make-sparse-keymap))) + (define-key map [header-line mouse-1] 'erc-list-menu-sort-by-column) + (define-key map [follow-link] 'mouse-face) + (setq erc-list-menu-sort-button-map map))) + +;; Helper function that makes a buttonized column header. +(defun erc-list-button (title column) + (erc-propertize title + 'column-number column + 'help-echo "mouse-1: sort by column" + 'mouse-face 'highlight + 'keymap erc-list-menu-sort-button-map)) + +(define-derived-mode erc-list-menu-mode nil "ERC-List" + "Major mode for editing a list of irc channels." + (setq header-line-format + (concat + (erc-propertize " " + 'display '(space :align-to 0) + 'face 'fixed-pitch) + (erc-list-make-string (erc-list-button "Channel" 1) + (erc-list-button "# Users" 2) + "Topic"))) + (setq truncate-lines t)) + +(put 'erc-list-menu-mode 'mode-class 'special) + +;; Handle a "322" response. This response tells us about a single +;; channel. +(defun erc-list-handle-322 (proc parsed) + (let* ((args (cdr (erc-response.command-args parsed))) + (channel (car args)) + (nusers (car (cdr args))) + (topic (erc-response.contents parsed))) + (when (buffer-live-p erc-list-buffer) + (with-current-buffer erc-list-buffer + (erc-list-insert-item channel nusers topic)))) + ;; Don't let another hook run. + t) + +;; Helper function to install our 322 handler and make our buffer. +(defun erc-list-install-322-handler (server-buffer) + (with-current-buffer server-buffer + ;; Arrange for 322 responses to insert into our buffer. + (add-hook 'erc-server-322-functions 'erc-list-handle-322 t t) + ;; Arrange for 323 (end of list) to end this. + (erc-once-with-server-event + 323 + '(progn + (remove-hook 'erc-server-322-functions 'erc-list-handle-322 t))) + ;; Find the list buffer, empty it, and display it. + (set (make-local-variable 'erc-list-buffer) + (get-buffer-create (concat "*Channels of " + erc-server-announced-name + "*"))) + (with-current-buffer erc-list-buffer + (erc-list-menu-mode) + (setq buffer-read-only nil) + (erase-buffer) + (set (make-local-variable 'erc-list-server-buffer) server-buffer) + (setq buffer-read-only t)) + (pop-to-buffer erc-list-buffer)) + t) + +;; The main entry point. +(defun erc-cmd-LIST (&optional line) + "Show a listing of channels on the current server in a separate window. + +If LINE is specified, include it with the /LIST command. It +should usually be one or more channels, separated by commas. + +Please note that this function only works with IRC servers which conform +to RFC and send the LIST header (#321) at start of list transmission." + (erc-with-server-buffer + (set (make-local-variable 'erc-list-last-argument) line) + (erc-once-with-server-event + 321 + (list 'progn + (list 'erc-list-install-322-handler (current-buffer))))) + (erc-server-send (concat "LIST :" (or (and line (substring line 1)) + "")))) +(put 'erc-cmd-LIST 'do-not-parse-args t) + +;;; erc-list.el ends here +;; +;; Local Variables: +;; indent-tabs-mode: t +;; tab-width: 8 +;; End: diff --git a/lisp/erc/erc-networks.el b/lisp/erc/erc-networks.el index 48efd41791f..b74fdb245a4 100644 --- a/lisp/erc/erc-networks.el +++ b/lisp/erc/erc-networks.el @@ -28,9 +28,7 @@ ;; ;; Usage: ;; -;; Put into your .emacs: -;; -;; (require 'erc-networks) +;; This is the "networks" module. ;; ;; M-x erc-server-select provides an alternative way to connect to servers by ;; choosing networks. @@ -351,6 +349,7 @@ ("Relicnet: Random server" Relicnet "irc.relic.net" 6667) ("Rezosup: Random server" Rezosup "irc.rezosup.org" 6667) ("Risanet: Random server" Risanet "irc.risanet.com" ((6667 6669))) + ("Rizon: Random server" Rizon "irc.rizon.net" (6633 (6660 6669) 6697 7000 8080 9999)) ("Rubiks: Random server" Rubiks "irc.rubiks.net" 6667) ("Rusnet: EU, RU, Tomsk" Rusnet "irc.tsk.ru" ((6667 6669) (7770 7775) )) ("Rusnet: EU, RU, Vladivostok" Rusnet "irc.vladivostok.ru" ((6667 6669) (7770 7775) )) @@ -765,9 +764,14 @@ network as a symbol." (setq erc-network nil) nil) -(add-hook 'erc-server-375-functions 'erc-set-network-name) -(add-hook 'erc-server-422-functions 'erc-set-network-name) -(add-hook 'erc-disconnected-hook 'erc-unset-network-name) +(define-erc-module networks nil + "Provide data about IRC networks." + ((add-hook 'erc-server-375-functions 'erc-set-network-name) + (add-hook 'erc-server-422-functions 'erc-set-network-name) + (add-hook 'erc-disconnected-hook 'erc-unset-network-name)) + ((remove-hook 'erc-server-375-functions 'erc-set-network-name) + (remove-hook 'erc-server-422-functions 'erc-set-network-name) + (remove-hook 'erc-disconnected-hook 'erc-unset-network-name))) (defun erc-ports-list (ports) "Return a list of PORTS. diff --git a/lisp/erc/erc-page.el b/lisp/erc/erc-page.el index 90a2009106f..ff30bcab209 100644 --- a/lisp/erc/erc-page.el +++ b/lisp/erc/erc-page.el @@ -104,5 +104,11 @@ receive pages if `erc-page-mode' is on." (provide 'erc-page) -;; arch-tag: 82fd2e0e-6060-4dd2-9788-8c1411e844de ;;; erc-page.el ends here +;; +;; Local Variables: +;; indent-tabs-mode: t +;; tab-width: 8 +;; End: + +;; arch-tag: 82fd2e0e-6060-4dd2-9788-8c1411e844de diff --git a/lisp/erc/erc-replace.el b/lisp/erc/erc-replace.el index d6713c6a442..45ce20e7fa7 100644 --- a/lisp/erc/erc-replace.el +++ b/lisp/erc/erc-replace.el @@ -1,6 +1,7 @@ ;; erc-replace.el -- wash and massage messages inserted into the buffer -;; Copyright (C) 2001, 2002, 2004, 2006, 2007, 2008 Free Software Foundation, Inc. +;; Copyright (C) 2001, 2002, 2004, 2006, 2007, +;; 2008 Free Software Foundation, Inc. ;; Author: Andreas Fuchs ;; Maintainer: Mario Lang (mlang@delysid.org) @@ -88,5 +89,11 @@ It replaces text according to `erc-replace-alist'." (provide 'erc-replace) -;; arch-tag: dd904a59-d8a6-47f8-ac3a-76b698289a18 ;;; erc-replace.el ends here +;; +;; Local Variables: +;; indent-tabs-mode: t +;; tab-width: 8 +;; End: + +;; arch-tag: dd904a59-d8a6-47f8-ac3a-76b698289a18 diff --git a/lisp/erc/erc-services.el b/lisp/erc/erc-services.el index 028d358ad39..b25a10dc5ca 100644 --- a/lisp/erc/erc-services.el +++ b/lisp/erc/erc-services.el @@ -123,6 +123,10 @@ You can also use M-x erc-nickserv-identify-mode to change modes." '(("autodetect") ("nick-change") ("both")) nil t)))) (add-hook 'erc-server-NOTICE-functions 'erc-nickserv-identification-autodetect) + (unless erc-networks-mode + ;; Force-enable networks module, because we need it to set + ;; erc-network for us. + (erc-networks-enable)) (cond ((eq mode 'autodetect) (setq erc-nickserv-identify-mode 'autodetect) (add-hook 'erc-server-NOTICE-functions @@ -187,6 +191,7 @@ Example of use: (const iip) (const OFTC) (const QuakeNet) + (const Rizon) (const SlashNET) (symbol :tag "Network name")) (repeat :tag "Nickname and password" @@ -256,6 +261,12 @@ Example of use: "NickServ" "IDENTIFY" nil nil "You\\s-are\\s-successfully\\s-identified\\s-as\\s-") + (Rizon + "NickServ!service@rizon.net" + "This\\s-nickname\\s-is\\s-registered\\s-and\\s-protected." + "NickServ" + "IDENTIFY" nil nil + "Password\\s-accepted\\s--\\s-you\\s-are\\s-now\\s-recognized.") (QuakeNet nil nil "Q@CServe.quakenet.org" diff --git a/lisp/erc/erc-track.el b/lisp/erc/erc-track.el index 76a692219ca..360d92c32c5 100644 --- a/lisp/erc/erc-track.el +++ b/lisp/erc/erc-track.el @@ -101,9 +101,13 @@ disconnected from `erc-modified-channels-alist'." :group 'erc-track :type 'boolean) -(defcustom erc-track-exclude-types '("NICK") +(defcustom erc-track-exclude-types '("NICK" "333" "353") "*List of message types to be ignored. -This list could look like '(\"JOIN\" \"PART\")." +This list could look like '(\"JOIN\" \"PART\"). + +By default, exclude changes of nicknames (NICK), display of who +set the channel topic (333), and listing of users on the current +channel (353)." :group 'erc-track :type 'erc-message-type) @@ -175,15 +179,32 @@ The faces used are the same as used for text in the buffers. :type 'boolean) (defcustom erc-track-faces-priority-list - '(erc-error-face erc-current-nick-face erc-keyword-face erc-pal-face - erc-nick-msg-face erc-direct-msg-face erc-button erc-dangerous-host-face - erc-default-face erc-action-face erc-nick-default-face erc-fool-face - erc-notice-face erc-input-face erc-prompt-face) + '(erc-error-face + (erc-nick-default-face erc-current-nick-face) + erc-current-nick-face + erc-keyword-face + (erc-nick-default-face erc-pal-face) + erc-pal-face + erc-nick-msg-face + erc-direct-msg-face + (erc-button erc-default-face) + (erc-nick-default-face erc-dangerous-host-face) + erc-dangerous-host-face + erc-nick-default-face + (erc-nick-default-face erc-default-face) + erc-default-face + erc-action-face + (erc-nick-default-face erc-fool-face) + erc-fool-face + erc-notice-face + erc-input-face + erc-prompt-face) "A list of faces used to highlight active buffer names in the modeline. If a message contains one of the faces in this list, the buffer name will be highlighted using that face. The first matching face is used." :group 'erc-track - :type '(repeat face)) + :type '(repeat (choice face + (repeat :tag "Combination" face)))) (defcustom erc-track-priority-faces-only nil "Only track text highlighted with a priority face. @@ -193,6 +214,7 @@ this variable. You can set a list of channel name strings, so those will be ignored while all other channels will be tracked as normal. Other options are 'all, to apply this to all channels or nil, to disable this feature. + Note: If you have a lot of faces listed in `erc-track-faces-priority-list', setting this variable might not be very useful." :group 'erc-track @@ -200,17 +222,38 @@ setting this variable might not be very useful." (repeat string) (const all))) +(defcustom erc-track-faces-normal-list + '((erc-button erc-default-face) + (erc-nick-default-face erc-dangerous-host-face) + erc-dangerous-host-face + erc-nick-default-face + (erc-nick-default-face erc-default-face) + erc-default-face + erc-action-face) + "A list of faces considered to be part of normal conversations. +This list is used to highlight active buffer names in the modeline. + +If a message contains one of the faces in this list, and the +previous modeline face for this buffer is also in this list, then +the buffer name will be highlighted using the face from the +message. This gives a rough indication that active conversations +are occurring in these channels. + +The effect may be disabled by setting this variable to nil." + :group 'erc-track + :type '(repeat (choice face + (repeat :tag "Combination" face)))) + (defcustom erc-track-position-in-mode-line 'before-modes "Where to show modified channel information in the mode-line. Setting this variable only has effects in GNU Emacs versions above 21.3. Choices are: -'before-modes - add to the beginning of `mode-line-modes' -'after-modes - add to the end of `mode-line-modes' -t - add to the end of `global-mode-string'. -nil - don't add to mode line -" +'before-modes - add to the beginning of `mode-line-modes', +'after-modes - add to the end of `mode-line-modes', +t - add to the end of `global-mode-string', +nil - don't add to mode line." :group 'erc-track :type '(choice (const :tag "Just before mode information" before-modes) (const :tag "Just after mode information" after-modes) @@ -443,7 +486,7 @@ START is the minimum length of the name used." ;;; Test: -(erc-assert +(assert (and ;; verify examples from the doc strings (equal (let ((erc-track-shorten-aggressively nil)) @@ -560,13 +603,15 @@ module, otherwise the keybindings will not do anything useful." :global t :group 'erc-track) -(defun erc-track-minor-mode-maybe () +(defun erc-track-minor-mode-maybe (&optional buffer) "Enable `erc-track-minor-mode', depending on `erc-track-enable-keybindings'." - (unless (or erc-track-minor-mode - ;; don't start the minor mode until we have an ERC - ;; process running, because we don't want to prompt the - ;; user while starting Emacs - (null (erc-buffer-list))) + (when (and (not erc-track-minor-mode) + ;; don't start the minor mode until we have an ERC + ;; process running, because we don't want to prompt the + ;; user while starting Emacs + (or (and (buffer-live-p buffer) + (with-current-buffer buffer (eq major-mode 'erc-mode))) + (erc-buffer-list))) (cond ((eq erc-track-enable-keybindings 'ask) (let ((key (or (and (key-binding (kbd "C-c C-SPC")) "C-SPC") (and (key-binding (kbd "C-c C-@")) "C-@")))) @@ -616,6 +661,7 @@ module, otherwise the keybindings will not do anything useful." (add-hook 'erc-insert-post-hook 'erc-track-modified-channels) (add-hook 'erc-disconnected-hook 'erc-modified-channels-update)) ;; enable the tracking keybindings + (add-hook 'erc-connect-pre-hook 'erc-track-minor-mode-maybe) (erc-track-minor-mode-maybe))) ;; Disable: ((when (boundp 'erc-track-when-inactive) @@ -637,6 +683,7 @@ module, otherwise the keybindings will not do anything useful." (remove-hook 'erc-disconnected-hook 'erc-modified-channels-update) (remove-hook 'erc-insert-post-hook 'erc-track-modified-channels)) ;; disable the tracking keybindings + (remove-hook 'erc-connect-pre-hook 'erc-track-minor-mode-maybe) (when erc-track-minor-mode (erc-track-minor-mode -1))))) @@ -821,15 +868,36 @@ Use `erc-make-mode-line-buffer-name' to create buttons." (defun erc-track-find-face (faces) "Return the face to use in the modeline from the faces in FACES. If `erc-track-faces-priority-list' is set, the one from FACES who is -first in that list will be used." - (let ((candidates erc-track-faces-priority-list) - candidate face) - (while (and candidates (not face)) - (setq candidate (car candidates) - candidates (cdr candidates)) - (when (memq candidate faces) - (setq face candidate))) - face)) +first in that list will be used. + +If `erc-track-faces-normal-list' is non-nil, use it to produce a +blinking effect that indicates channel activity when the first +element in FACES and the highest-ranking face among the rest of +FACES are both members of `erc-track-faces-normal-list'. + +If `erc-track-faces-priority-list' is not set, the first element +in FACES will be used. + +If one of the faces is a list, then it will be ranked according +to its highest-tanking face member. A list of faces including +that member will take priority over just the single member +element." + (let ((choice (catch 'face + (dolist (candidate erc-track-faces-priority-list) + (when (member candidate faces) + (throw 'face candidate))))) + (no-first (and erc-track-faces-normal-list + (catch 'face + (dolist (candidate erc-track-faces-priority-list) + (when (member candidate (cdr faces)) + (throw 'face candidate))))))) + (cond ((null choice) + (car faces)) + ((and (member choice erc-track-faces-normal-list) + (member no-first erc-track-faces-normal-list)) + no-first) + (t + choice)))) (defun erc-track-modified-channels () "Hook function for `erc-insert-post-hook' to check if the current @@ -898,14 +966,15 @@ is in `erc-mode'." "Return a list of all faces used in STR." (let ((i 0) (m (length str)) - (faces (erc-list (get-text-property 0 'face str)))) + (faces (erc-list (get-text-property 0 'face str))) + cur) (while (and (setq i (next-single-property-change i 'face str m)) (not (= i m))) - (dolist (face (erc-list (get-text-property i 'face str))) - (add-to-list 'faces face))) + (when (setq cur (get-text-property i 'face str)) + (add-to-list 'faces cur))) faces)) -(erc-assert +(assert (let ((str "is bold")) (put-text-property 3 (length str) 'face '(bold erc-current-nick-face) @@ -935,7 +1004,7 @@ higher number than any other face in that list." (let ((count 0)) (catch 'done (dolist (item erc-track-faces-priority-list) - (if (eq item face) + (if (equal item face) (throw 'done t) (setq count (1+ count))))) count)) diff --git a/lisp/erc/erc-xdcc.el b/lisp/erc/erc-xdcc.el index ed1d0c948b6..b58a7b61713 100644 --- a/lisp/erc/erc-xdcc.el +++ b/lisp/erc/erc-xdcc.el @@ -62,6 +62,11 @@ being evaluated and should return stings." :group 'erc-dcc :type '(repeat (repeat :tag "Message" (choice string sexp)))) +;;;###autoload (autoload 'erc-xdcc-mode "erc-xdcc") +(define-erc-module xdcc nil + "Act as an XDCC file-server." + nil nil) + ;;;###autoload (defun erc-xdcc-add-file (file) "Add a file to `erc-xdcc-files'." @@ -126,5 +131,11 @@ being evaluated and should return stings." (provide 'erc-xdcc) -;; arch-tag: a13b62fe-2399-4562-af4e-f18a8dd4b9c8 ;;; erc-xdcc.el ends here +;; +;; Local Variables: +;; indent-tabs-mode: t +;; tab-width: 8 +;; End: + +;; arch-tag: a13b62fe-2399-4562-af4e-f18a8dd4b9c8 diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index c197f618442..aa03e67461f 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el @@ -66,7 +66,7 @@ ;;; Code: -(defconst erc-version-string "Version 5.3 (devel)" +(defconst erc-version-string "Version 5.3 (RC 1)" "ERC version. This is used by function `erc-version'.") (eval-when-compile (require 'cl)) @@ -1167,7 +1167,12 @@ This will only be used if `erc-header-line-face-method' is non-nil." See the variable `erc-command-indicator'." :group 'erc-faces) -(defface erc-notice-face '((t (:bold t :foreground "SlateBlue"))) +(defface erc-notice-face + (if (featurep 'xemacs) + '((t (:bold t :foreground "blue"))) + '((((class color) (min-colors 88)) + (:bold t :foreground "SlateBlue")) + (t (:bold t :foreground "blue")))) "ERC face for notices." :group 'erc-faces) @@ -1465,18 +1470,23 @@ Turning on `erc-mode' runs the hook `erc-mode-hook'." "IRC port to use if it cannot be detected otherwise.") (defcustom erc-join-buffer 'buffer - "Determines how to display the newly created IRC buffer. -'window - in another window, -'window-noselect - in another window, but don't select that one, -'frame - in another frame, -'bury - bury it in a new buffer, -any other value - in place of the current buffer." + "Determines how to display a newly created IRC buffer. + +The available choices are: + + 'window - in another window, + 'window-noselect - in another window, but don't select that one, + 'frame - in another frame, + 'bury - bury it in a new buffer, + 'buffer - in place of the current buffer, + any other value - in place of the current buffer." :group 'erc-buffers - :type '(choice (const window) - (const window-noselect) - (const frame) - (const bury) - (const buffer))) + :type '(choice (const :tag "Split window and select" window) + (const :tag "Split window, don't select" window-noselect) + (const :tag "New frame" frame) + (const :tag "Bury in new buffer" bury) + (const :tag "Use current buffer" buffer) + (const :tag "Use current buffer" t))) (defcustom erc-frame-alist nil "*Alist of frame parameters for creating erc frames. @@ -1804,8 +1814,8 @@ buffer rather than a server buffer.") mods)))) (defcustom erc-modules '(netsplit fill button match track completion readonly - ring autojoin noncommands irccontrols - stamp menu) + networks ring autojoin noncommands irccontrols + move-to-prompt stamp menu list) "A list of modules which ERC should enable. If you set the value of this without using `customize' remember to call \(erc-update-modules) after you change it. When using `customize', modules @@ -1837,14 +1847,20 @@ removed from the list will be disabled." (const :tag "completion: Complete nicknames and commands (programmable)" completion) (const :tag "hecomplete: Complete nicknames and commands (old)" hecomplete) + (const :tag "dcc: Provide Direct Client-to-Client support" dcc) (const :tag "fill: Wrap long lines" fill) (const :tag "identd: Launch an identd server on port 8113" identd) (const :tag "irccontrols: Highlight or remove IRC control characters" irccontrols) + (const :tag "keep-place: Leave point above un-viewed text" keep-place) + (const :tag "list: List channels in a separate buffer" list) (const :tag "log: Save buffers in logs" log) (const :tag "match: Highlight pals, fools, and other keywords" match) (const :tag "menu: Display a menu in ERC buffers" menu) + (const :tag "move-to-prompt: Move to the prompt when typing text" + move-to-prompt) (const :tag "netsplit: Detect netsplits" netsplit) + (const :tag "networks: Provide data about IRC networks" networks) (const :tag "noncommands: Don't display non-IRC commands after evaluation" noncommands) (const :tag @@ -1866,6 +1882,7 @@ removed from the list will be disabled." (const :tag "track: Track channel activity in the mode-line" track) (const :tag "truncate: Truncate buffers to a certain size" truncate) (const :tag "unmorse: Translate morse code in messages" unmorse) + (const :tag "xdcc: Act as an XDCC file-server" xdcc) (repeat :tag "Others" :inline t symbol)) :group 'erc) @@ -2324,6 +2341,15 @@ If ARG is non-nil, show the *erc-protocol* buffer." I.e. any char in it has the `invisible' property set." (text-property-any 0 (length string) 'invisible t string)) +(defcustom erc-remove-parsed-property t + "Whether to remove the erc-parsed text property after displaying a message. + +The default is to remove it, since it causes ERC to take up extra +memory. If you have code that relies on this property, then set +this option to nil." + :type 'boolean + :group 'erc) + (defun erc-display-line-1 (string buffer) "Display STRING in `erc-mode' BUFFER. Auxiliary function used in `erc-display-line'. The line gets filtered to @@ -2364,7 +2390,10 @@ If STRING is nil, the function does nothing." (save-restriction (narrow-to-region insert-position (point)) (run-hooks 'erc-insert-modify-hook) - (run-hooks 'erc-insert-post-hook)))))) + (run-hooks 'erc-insert-post-hook) + (when erc-remove-parsed-property + (remove-text-properties (point-min) (point-max) + '(erc-parsed nil)))))))) (erc-update-undo-list (- (or (marker-position erc-insert-marker) (point-max)) insert-position)))))) @@ -3161,14 +3190,35 @@ just as you provided it. Use this command with care!" (t nil))) (put 'erc-cmd-QUOTE 'do-not-parse-args t) +(defcustom erc-query-display 'window + "Indicates how to display query buffers when using the /QUERY +command to talk to someone. + +The default behavior is to display the message in a new window +and bring it to the front. See the documentation for +`erc-join-buffer' for a description of the available choices. + +See also `erc-auto-query' to decide how private messages from +other people should be displayed." + :group 'erc-query + :type '(choice (const :tag "Split window and select" window) + (const :tag "Split window, don't select" window-noselect) + (const :tag "New frame" frame) + (const :tag "Bury in new buffer" bury) + (const :tag "Use current buffer" buffer) + (const :tag "Use current buffer" t))) + (defun erc-cmd-QUERY (&optional user) "Open a query with USER. The type of query window/frame/etc will depend on the value of -`erc-join-buffer'. If USER is omitted, close the current query buffer if one -exists - except this is broken now ;-)" +`erc-query-display'. + +If USER is omitted, close the current query buffer if one exists +- except this is broken now ;-)" (interactive (list (read-from-minibuffer "Start a query with: " nil))) - (let ((session-buffer (erc-server-buffer))) + (let ((session-buffer (erc-server-buffer)) + (erc-join-buffer erc-query-display)) (if user (erc-query user session-buffer) ;; currently broken, evil hack to display help anyway @@ -3707,8 +3757,9 @@ If `point' is at the beginning of a channel name, use that as default." (read-from-minibuffer (concat "Set topic of " (erc-default-target) ": ") (when erc-channel-topic - (cons (apply 'concat (butlast (split-string erc-channel-topic "\C-o"))) - 0))))) + (let ((ss (split-string erc-channel-topic "\C-o"))) + (cons (apply 'concat (if (cdr ss) (butlast ss) ss)) + 0)))))) (let ((topic-list (split-string topic "\C-o"))) ; strip off the topic setter (erc-cmd-TOPIC (concat (erc-default-target) " " (car topic-list))))) @@ -3841,20 +3892,22 @@ To change how this query window is displayed, use `let' to bind (erc-update-mode-line) buf)) -(defcustom erc-auto-query 'bury +(defcustom erc-auto-query 'window-noselect "If non-nil, create a query buffer each time you receive a private message. +If the buffer doesn't already exist, it is created. -If the buffer doesn't already exist it is created. This can be -set to a symbol, to control how the new query window should -appear. See the documentation for `erc-join-buffer' for -available choices." +This can be set to a symbol, to control how the new query window +should appear. The default behavior is to display the buffer in +a new window, but not to select it. See the documentation for +`erc-join-buffer' for a description of the available choices." :group 'erc-query - :type '(choice (const nil) - (const buffer) - (const window) - (const window-noselect) - (const bury) - (const frame))) + :type '(choice (const :tag "Don't create query window" nil) + (const :tag "Split window and select" window) + (const :tag "Split window, don't select" window-noselect) + (const :tag "New frame" frame) + (const :tag "Bury in new buffer" bury) + (const :tag "Use current buffer" buffer) + (const :tag "Use current buffer" t))) (defcustom erc-query-on-unjoined-chan-privmsg t "If non-nil create query buffer on receiving any PRIVMSG at all. @@ -5822,7 +5875,7 @@ See `current-time' for details on the time format." ;; Mode line handling -(defcustom erc-mode-line-format "%s %a" +(defcustom erc-mode-line-format "%S %a" "A string to be formatted and shown in the mode-line in `erc-mode'. The string is formatted using `format-spec' and the result is set as the value @@ -5833,12 +5886,16 @@ The following characters are replaced: %l: The estimated lag time to the server %m: The modes of the channel %n: The current nick name +%N: The name of the network %o: The topic of the channel %p: The session port %t: The name of the target (channel, nickname, or servername:port) %s: In the server-buffer, this gets filled with the value of `erc-server-announced-name', in a channel, the value of - (erc-default-target) also get concatenated." + (erc-default-target) also get concatenated. +%S: In the server-buffer, this gets filled with the value of + `erc-network', in a channel, the value of (erc-default-target) + also get concatenated." :group 'erc-mode-line-and-header :type 'string) @@ -5932,6 +5989,29 @@ This should be a string with substitution variables recognized by (server-name server-name) (t (buffer-name (current-buffer)))))) +(defun erc-format-network () + "Return the name of the network we are currently on." + (let ((network (and (fboundp 'erc-network-name) (erc-network-name)))) + (if (and network (symbolp network)) + (symbol-name network) + ""))) + +(defun erc-format-target-and/or-network () + "Return the network or the current target and network combined. +If the name of the network is not available, then use the +shortened server name instead." + (let ((network-name (or (and (fboundp 'erc-network-name) (erc-network-name)) + (erc-shorten-server-name + (or erc-server-announced-name + erc-session-server))))) + (when (and network-name (symbolp network-name)) + (setq network-name (symbol-name network-name))) + (cond ((erc-default-target) + (concat (erc-string-no-properties (erc-default-target)) + "@" network-name)) + (network-name network-name) + (t (buffer-name (current-buffer)))))) + (defun erc-format-away-status () "Return a formatted `erc-mode-line-away-status-format' if `erc-away' is non-nil." @@ -5975,9 +6055,11 @@ if `erc-away' is non-nil." ?l (erc-format-lag-time) ?m (erc-format-channel-modes) ?n (or (erc-current-nick) "") + ?N (erc-format-network) ?o (erc-controls-strip erc-channel-topic) ?p (erc-port-to-string erc-session-port) ?s (erc-format-target-and/or-server) + ?S (erc-format-target-and/or-network) ?t (erc-format-target))) (process-status (cond ((and (erc-server-process-alive) (not erc-server-connected)) From e0df1b73db61b652198ab72a7ab0d9791f29a0a8 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 25 Jan 2008 04:31:22 +0000 Subject: [PATCH 309/439] Fix typo and tense. --- src/ChangeLog | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 09fbe99a8f2..24b69f1a8d1 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -25,11 +25,11 @@ 2008-01-21 Michael Albinus - * dbusbind.el (Fdbus_method_return_internal): Renamed from + * dbusbind.c (Fdbus_method_return_internal): Rename from Fdbus_method_return. - (Fdbus_unregister_object): Moved to dbus.el. + (Fdbus_unregister_object): Move to dbus.el. (Fdbus_call_method, Fdbus_method_return_internal) - (Fdbus_send_signal): Debug messages improved. + (Fdbus_send_signal): Improve debug messages. 2008-01-20 Martin Rudalics From 5b940d5a6974b2ec2a0090f8a77958c6d97b2df0 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 25 Jan 2008 04:32:52 +0000 Subject: [PATCH 310/439] Correct usage of OPTION_DEFAULT_ON, OPTION_DEFAULT_OFF so that the defaults are as they used to be. Default `Carbon' to off (it's unsupported). --- ChangeLog | 6 ++++++ configure.in | 26 ++++++++++++++++---------- 2 files changed, 22 insertions(+), 10 deletions(-) diff --git a/ChangeLog b/ChangeLog index de0e388afb1..a90e0ce9718 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2008-01-25 Glenn Morris + + * configure.in: Correct usage of OPTION_DEFAULT_ON, + OPTION_DEFAULT_OFF so that the defaults are as they used to be. + Default `Carbon' to off (it's unsupported). + 2008-01-24 Glenn Morris * configure.in: Standardize dbus-related messages. diff --git a/configure.in b/configure.in index a13c1f31378..950e86d8a04 100644 --- a/configure.in +++ b/configure.in @@ -101,6 +101,7 @@ fi OPTION_DEFAULT_ON([sound],[don't compile with sound support]) +dnl FIXME currently it is not the last. dnl This should be the last --with option, because --with-x is dnl added later on when we find the path of X, and it's best to dnl keep them together visually. @@ -122,19 +123,24 @@ this option's value should be `yes', `no', `lucid', `athena', `motif' or `gtk'. with_x_toolkit=$val ]) -OPTION_DEFAULT_OFF([xpm],[use -lXpm for displaying XPM images]) -OPTION_DEFAULT_OFF([jpeg],[use -ljpeg for displaying JPEG images]) -OPTION_DEFAULT_OFF([tiff],[use -ltiff for displaying TIFF images]) -OPTION_DEFAULT_OFF([gif],[use -lgif (or -lungif) for displaying GIF images]) -OPTION_DEFAULT_OFF([png],[use -lpng for displaying PNG images]) -OPTION_DEFAULT_OFF([gpm],[use -lgpm for mouse support on a GNU/Linux console]) -OPTION_DEFAULT_OFF([rsvg],[use -lrsvg-2 for displaying SVG images]) -OPTION_DEFAULT_OFF([gtk],[use GTK (same as --with-x-toolkit=gtk)]) +dnl _ON results in a '--without' option in the --help output, so +dnl the help text should refer to "don't compile", etc. +OPTION_DEFAULT_ON([xpm],[don't compile with XPM image support]) +OPTION_DEFAULT_ON([jpeg],[don't compile with JPEG image support]) +OPTION_DEFAULT_ON([tiff],[don't compile with TIFF image support]) +OPTION_DEFAULT_ON([gif],[don't compile with GIF image support]) +OPTION_DEFAULT_ON([png],[don't compile with PNG image support]) +OPTION_DEFAULT_ON([rsvg],[don't compile with SVG image support]) + +OPTION_DEFAULT_OFF([gtk],[use GTK toolkit]) OPTION_DEFAULT_ON([toolkit-scroll-bars],[don't use Motif or Xaw3d scroll bars]) OPTION_DEFAULT_ON([xaw3d],[don't use Xaw3d]) OPTION_DEFAULT_ON([xim],[don't use X11 XIM]) -OPTION_DEFAULT_ON([carbon],[don't use Carbon GUI on Mac OS X]) -OPTION_DEFAULT_ON([dbus],[use D-Bus]) +OPTION_DEFAULT_OFF([carbon],[use Carbon GUI on Mac OS X. **UNSUPPORTED!**]) + +OPTION_DEFAULT_ON([gpm],[don't use -lgpm for mouse support on a GNU/Linux console]) +OPTION_DEFAULT_OFF([dbus],[compile with D-Bus support]) + AC_ARG_WITH([pkg-config-prog],dnl [AS_HELP_STRING([--with-pkg-config-prog=PATH], From c8467c40b35566ca0515f3abe349642dcd26e017 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 25 Jan 2008 04:35:17 +0000 Subject: [PATCH 311/439] Regenerate, with shell functions millstone. --- configure | 76 +++++++++++++++++++++++++++---------------------------- 1 file changed, 38 insertions(+), 38 deletions(-) diff --git a/configure b/configure index 4d17d14802e..b2ebd636419 100755 --- a/configure +++ b/configure @@ -412,10 +412,10 @@ else fi test \$exitcode = 0") || { - echo No shell found that supports shell functions. - echo Please tell autoconf@gnu.org about your system, - echo including any error possibly output before this - echo message + echo Please tell bug-autoconf@gnu.org about your system, + echo including any error possibly output before this message. + echo This can help us improve future autoconf versions. + echo Configuration will now proceed without shell functions. } @@ -1344,20 +1344,21 @@ Optional Packages: --without-sound don't compile with sound support --with-x-toolkit=KIT use an X toolkit (KIT one of: yes, lucid, athena, motif, gtk, no) - --with-xpm use -lXpm for displaying XPM images - --with-jpeg use -ljpeg for displaying JPEG images - --with-tiff use -ltiff for displaying TIFF images - --with-gif use -lgif (or -lungif) for displaying GIF images - --with-png use -lpng for displaying PNG images - --with-gpm use -lgpm for mouse support on a GNU/Linux console - --with-rsvg use -lrsvg-2 for displaying SVG images - --with-gtk use GTK (same as --with-x-toolkit=gtk) + --without-xpm don't compile with XPM image support + --without-jpeg don't compile with JPEG image support + --without-tiff don't compile with TIFF image support + --without-gif don't compile with GIF image support + --without-png don't compile with PNG image support + --without-rsvg don't compile with SVG image support + --with-gtk use GTK toolkit --without-toolkit-scroll-bars don't use Motif or Xaw3d scroll bars --without-xaw3d don't use Xaw3d --without-xim don't use X11 XIM - --without-carbon don't use Carbon GUI on Mac OS X - --without-dbus use D-Bus + --with-carbon use Carbon GUI on Mac OS X. **UNSUPPORTED!** + --without-gpm don't use -lgpm for mouse support on a GNU/Linux + console + --with-dbus compile with D-Bus support --with-pkg-config-prog=PATH Path to pkg-config for finding GTK and librsvg --with-x use the X Window System @@ -1956,7 +1957,7 @@ fi if test "${with_xpm+set}" = set; then withval=$with_xpm; else - with_xpm=no + with_xpm=yes fi @@ -1964,7 +1965,7 @@ fi if test "${with_jpeg+set}" = set; then withval=$with_jpeg; else - with_jpeg=no + with_jpeg=yes fi @@ -1972,7 +1973,7 @@ fi if test "${with_tiff+set}" = set; then withval=$with_tiff; else - with_tiff=no + with_tiff=yes fi @@ -1980,7 +1981,7 @@ fi if test "${with_gif+set}" = set; then withval=$with_gif; else - with_gif=no + with_gif=yes fi @@ -1988,15 +1989,7 @@ fi if test "${with_png+set}" = set; then withval=$with_png; else - with_png=no -fi - - -# Check whether --with-gpm was given. -if test "${with_gpm+set}" = set; then - withval=$with_gpm; -else - with_gpm=no + with_png=yes fi @@ -2004,10 +1997,11 @@ fi if test "${with_rsvg+set}" = set; then withval=$with_rsvg; else - with_rsvg=no + with_rsvg=yes fi + # Check whether --with-gtk was given. if test "${with_gtk+set}" = set; then withval=$with_gtk; @@ -2044,7 +2038,16 @@ fi if test "${with_carbon+set}" = set; then withval=$with_carbon; else - with_carbon=yes + with_carbon=no +fi + + + +# Check whether --with-gpm was given. +if test "${with_gpm+set}" = set; then + withval=$with_gpm; +else + with_gpm=yes fi @@ -2052,11 +2055,12 @@ fi if test "${with_dbus+set}" = set; then withval=$with_dbus; else - with_dbus=yes + with_dbus=no fi + # Check whether --with-pkg-config-prog was given. if test "${with_pkg_config_prog+set}" = set; then withval=$with_pkg_config_prog; @@ -18119,13 +18123,11 @@ _ACEOF cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ -#include /* for off_t */ - #include +#include int main () { -int (*fp) (FILE *, off_t, int) = fseeko; - return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); +return fseeko (stdin, 0, 0) && (fseeko) (stdin, 0, 0); ; return 0; } @@ -18165,13 +18167,11 @@ cat confdefs.h >>conftest.$ac_ext cat >>conftest.$ac_ext <<_ACEOF /* end confdefs.h. */ #define _LARGEFILE_SOURCE 1 -#include /* for off_t */ - #include +#include int main () { -int (*fp) (FILE *, off_t, int) = fseeko; - return fseeko (stdin, 0, 0) && fp (stdin, 0, 0); +return fseeko (stdin, 0, 0) && (fseeko) (stdin, 0, 0); ; return 0; } From ce173b302f23074f3e8a086ba1ccfa7ad01ec8af Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 25 Jan 2008 04:41:09 +0000 Subject: [PATCH 312/439] Sven Joachim (kill-buffer-if-not-modified): Don't pass t to buffer-modified-p. --- lisp/ChangeLog | 5 +++++ lisp/view.el | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2cc13c1c664..b93a5f3a37b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-25 Sven Joachim + + * view.el (kill-buffer-if-not-modified): Don't pass t to + buffer-modified-p. + 2008-01-24 Michael Albinus * net/tramp.el (tramp-do-copy-or-rename-file): Flush the cache of diff --git a/lisp/view.el b/lisp/view.el index c663b2a2431..410b8ecc6a6 100644 --- a/lisp/view.el +++ b/lisp/view.el @@ -249,7 +249,7 @@ This is local in each buffer, once it is used.") ;; types C-x C-q again to return to view mode. (defun kill-buffer-if-not-modified (buf) "Like `kill-buffer', but does nothing if the buffer is modified." - (let ((buf (or (bufferp buf) (get-buffer buf)))) + (let ((buf (get-buffer buf))) (and buf (not (buffer-modified-p buf)) (kill-buffer buf)))) From a981bee972f9c0382aaeff9f6c7c0a55433bda88 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Fri, 25 Jan 2008 04:42:30 +0000 Subject: [PATCH 313/439] Sven Joachim (kill-buffer-if-not-modified): Don't pass t to buffer-modified-p. --- lisp/ChangeLog | 5 +++++ lisp/view.el | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 28b1f7dc905..b620ff1e667 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-25 Sven Joachim + + * view.el (kill-buffer-if-not-modified): Don't pass t to + buffer-modified-p. + 2008-01-25 Juanma Barranquero * allout.el (allout-prefix-data): Doc fix. diff --git a/lisp/view.el b/lisp/view.el index c89fd692152..7a56f983218 100644 --- a/lisp/view.el +++ b/lisp/view.el @@ -244,7 +244,7 @@ This is local in each buffer, once it is used.") ;; types C-x C-q again to return to view mode. (defun kill-buffer-if-not-modified (buf) "Like `kill-buffer', but does nothing if the buffer is modified." - (let ((buf (or (bufferp buf) (get-buffer buf)))) + (let ((buf (get-buffer buf))) (and buf (not (buffer-modified-p buf)) (kill-buffer buf)))) From f187f57d5474a33de6bd566ef7bdcb4de931c47c Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Fri, 25 Jan 2008 05:03:52 +0000 Subject: [PATCH 314/439] Add arch tagline --- lisp/erc/ChangeLog | 2 ++ lisp/erc/erc-list.el | 2 ++ 2 files changed, 4 insertions(+) diff --git a/lisp/erc/ChangeLog b/lisp/erc/ChangeLog index cddd0f845b6..3fb174c97d1 100644 --- a/lisp/erc/ChangeLog +++ b/lisp/erc/ChangeLog @@ -288,3 +288,5 @@ See ChangeLog.07 for earlier changes. ;; coding: utf-8 ;; add-log-time-zone-rule: t ;; End: + +;; arch-tag: 15787dfd-e091-4c8c-8b88-747b474e1ac7 diff --git a/lisp/erc/erc-list.el b/lisp/erc/erc-list.el index fc8ec9bf10e..586c720dd19 100644 --- a/lisp/erc/erc-list.el +++ b/lisp/erc/erc-list.el @@ -225,3 +225,5 @@ to RFC and send the LIST header (#321) at start of list transmission." ;; indent-tabs-mode: t ;; tab-width: 8 ;; End: + +;; arch-tag: 99c5f9cb-6bac-4224-86bf-e394768cd1d0 From d57941800355c2a967705089d9bc790a58d18a3a Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Fri, 25 Jan 2008 05:38:31 +0000 Subject: [PATCH 315/439] * ibuffer.el (ibuffer-default-sorting-mode): Add option to sort by file name. (ibuffer-mode-map): Add binding to sort by file name. (ibuffer-filename/process-header-map): New variable. (filename-and-process): Add a header that sorts by file name. (ibuffer-mode): Mention sorting by file name. * ibuf-ext.el (filename/process): New sorter. --- lisp/ChangeLog | 11 +++++++++++ lisp/ibuf-ext.el | 14 ++++++++++++++ lisp/ibuffer.el | 9 +++++++++ 3 files changed, 34 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b93a5f3a37b..68cac6e786e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,14 @@ +2008-01-25 Dan Nicolaescu + + * ibuffer.el (ibuffer-default-sorting-mode): Add option to sort by + file name. + (ibuffer-mode-map): Add binding to sort by file name. + (ibuffer-filename/process-header-map): New variable. + (filename-and-process): Add a header that sorts by file name. + (ibuffer-mode): Mention sorting by file name. + + * ibuf-ext.el (filename/process): New sorter. + 2008-01-25 Sven Joachim * view.el (kill-buffer-if-not-modified): Don't pass t to diff --git a/lisp/ibuf-ext.el b/lisp/ibuf-ext.el index 0499fab51aa..82face5eccb 100644 --- a/lisp/ibuf-ext.el +++ b/lisp/ibuf-ext.el @@ -1155,6 +1155,20 @@ Ordering is lexicographic." (with-current-buffer (car b) (buffer-size)))) +;;;###autoload (autoload 'ibuffer-do-sort-by-filename/process "ibuf-ext") +(define-ibuffer-sorter filename/process + "Sort the buffers by their file name/process name." + (:description "file name") + (string-lessp + ;; FIXME: For now just compare the file name and the process name + ;; (if it exists). Is there a better way to do this? + (or (buffer-file-name (car a)) + (let ((pr-a (get-buffer-process (car a)))) + (and (processp pr-a) (process-name pr-a)))) + (or (buffer-file-name (car b)) + (let ((pr-b (get-buffer-process (car b)))) + (and (processp pr-b) (process-name pr-b)))))) + ;;; Functions to emulate bs.el ;;;###autoload diff --git a/lisp/ibuffer.el b/lisp/ibuffer.el index dcf840fc584..7c6da00cf0f 100644 --- a/lisp/ibuffer.el +++ b/lisp/ibuffer.el @@ -209,6 +209,7 @@ view of the buffers." :type '(choice (const :tag "Last view time" :value recency) (const :tag "Lexicographic" :value alphabetic) (const :tag "Buffer size" :value size) + (const :tag "File name" :value filename/process) (const :tag "Major mode" :value major-mode)) :group 'ibuffer) (defvar ibuffer-sorting-mode nil) @@ -447,6 +448,7 @@ directory, like `default-directory'." (define-key map (kbd "s a") 'ibuffer-do-sort-by-alphabetic) (define-key map (kbd "s v") 'ibuffer-do-sort-by-recency) (define-key map (kbd "s s") 'ibuffer-do-sort-by-size) + (define-key map (kbd "s f") 'ibuffer-do-sort-by-filename/process) (define-key map (kbd "s m") 'ibuffer-do-sort-by-major-mode) (define-key map (kbd "/ m") 'ibuffer-filter-by-mode) @@ -828,6 +830,11 @@ directory, like `default-directory'." (define-key map [down-mouse-3] 'ibuffer-mouse-popup-menu) map)) +(defvar ibuffer-filename/process-header-map + (let ((map (make-sparse-keymap))) + (define-key map [(mouse-1)] 'ibuffer-do-sort-by-filename/process) + map)) + (defvar ibuffer-mode-name-map (let ((map (make-sparse-keymap))) (define-key map [(mouse-2)] 'ibuffer-mouse-filter-by-mode) @@ -1753,6 +1760,7 @@ If point is on a group name, this function operates on that group." (define-ibuffer-column filename-and-process (:name "Filename/Process" + :header-mouse-map ibuffer-filename/process-header-map :summarizer (lambda (strings) (setq strings (delete "" strings)) @@ -2433,6 +2441,7 @@ Sorting commands: '\\[ibuffer-toggle-sorting-mode]' - Rotate between the various sorting modes. '\\[ibuffer-invert-sorting]' - Reverse the current sorting order. '\\[ibuffer-do-sort-by-alphabetic]' - Sort the buffers lexicographically. + '\\[ibuffer-do-sort-by-filename/process]' - Sort the buffers by the file name. '\\[ibuffer-do-sort-by-recency]' - Sort the buffers by last viewing time. '\\[ibuffer-do-sort-by-size]' - Sort the buffers by size. '\\[ibuffer-do-sort-by-major-mode]' - Sort the buffers by major mode. From ccd8f7fe141f55e9ba381633b02a6467df0270e1 Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Fri, 25 Jan 2008 10:01:15 +0000 Subject: [PATCH 316/439] (Fclrhash): Return TABLE. --- src/ChangeLog | 4 ++++ src/fns.c | 5 +++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 24b69f1a8d1..a6d8cc928d6 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-25 Thien-Thi Nguyen + + * fns.c (Fclrhash): Return TABLE. + 2008-01-23 YAMAMOTO Mitsuharu * macterm.c (x_scroll_bar_create): Initialize bar->redraw_needed_p. diff --git a/src/fns.c b/src/fns.c index 01c7e583661..a6872e7d5ec 100644 --- a/src/fns.c +++ b/src/fns.c @@ -5407,12 +5407,13 @@ DEFUN ("hash-table-p", Fhash_table_p, Shash_table_p, 1, 1, 0, DEFUN ("clrhash", Fclrhash, Sclrhash, 1, 1, 0, - doc: /* Clear hash table TABLE. */) + doc: /* Clear hash table TABLE and return it. */) (table) Lisp_Object table; { hash_clear (check_hash_table (table)); - return Qnil; + /* Be compatible with XEmacs. */ + return table; } From 97a739d5394d0b14a8dbafe624e2e6759154aa39 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Fri, 25 Jan 2008 14:09:57 +0000 Subject: [PATCH 317/439] New commands for cleaning up some blank problems like trailing blanks. --- lisp/ChangeLog | 15 ++ lisp/blank-mode.el | 395 ++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 403 insertions(+), 7 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 68cac6e786e..49b2015b321 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,18 @@ +2008-01-25 Vinicius Jose Latorre + + * blank-mode.el: New version 9.0. New commands to clean up some blank + problems like trailing blanks. New faces and regexp for visualizing + the blank problems. Doc fix. + (blank-chars, blank-global-modes, blank-chars-value-list) + (blank-toggle-option-alist, blank-help-text): Initialization fix. + (blank-indentation, blank-empty, blank-space-after-tab): New faces. + (blank-indentation, blank-empty, blank-space-after-tab) + (blank-indentation-regexp, blank-empty-at-bob-regexp) + (blank-empty-at-eob-regexp, blank-space-after-tab-regexp): New + options. + (blank-cleanup, blank-cleanup-region): New commands. + (blank-color-on): Code fix. + 2008-01-25 Dan Nicolaescu * ibuffer.el (ibuffer-default-sorting-mode): Add option to sort by diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el index 9d36ebde6ae..315ac99ea7b 100644 --- a/lisp/blank-mode.el +++ b/lisp/blank-mode.el @@ -6,7 +6,7 @@ ;; Author: Vinicius Jose Latorre ;; Maintainer: Vinicius Jose Latorre ;; Keywords: data, wp -;; Version: 8.1 +;; Version: 9.0 ;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre ;; This file is part of GNU Emacs. @@ -100,6 +100,10 @@ ;; ;; blank-mode was inspired by: ;; +;; whitespace.el Rajesh Vaidheeswarran +;; Warn about and clean bogus whitespaces in the file +;; (inspired the idea to warn and clean some blanks) +;; ;; show-whitespace-mode.el Aurelien Tisne ;; Simple mode to highlight whitespaces ;; (inspired the idea to use font-lock) @@ -153,6 +157,37 @@ ;; ;; M-x global-blank-mode RET ;; +;; There are also the following useful commands: +;; +;; `blank-cleanup' +;; Cleanup some blank problems in all buffer or at region. +;; +;; `blank-cleanup-region' +;; Cleanup some blank problems at region. +;; +;; The problems, which are cleaned up, are: +;; +;; 1. empty lines at beginning of buffer. +;; 2. empty lines at end of buffer. +;; If `blank-chars' has `empty' as an element, remove all empty +;; lines at beginning and/or end of buffer. +;; +;; 3. 8 or more SPACEs at beginning of line. +;; If `blank-chars' has `indentation' as an element, replace 8 or +;; more SPACEs at beginning of line by TABs. +;; +;; 4. SPACEs before TAB. +;; If `blank-chars' has `space-before-tab' as an element, replace +;; SPACEs by TABs. +;; +;; 5. SPACEs or TABs at end of line. +;; If `blank-chars' has `trailing' as an element, remove all +;; SPACEs or TABs at end of line." +;; +;; 6. 8 or more SPACEs after TAB. +;; If `blank-chars' has `space-after-tab' as an element, replace +;; SPACEs by TABs. +;; ;; ;; Hooks ;; ----- @@ -197,6 +232,15 @@ ;; `blank-space-before-tab' Face used to visualize SPACEs before ;; TAB. ;; +;; `blank-indentation' Face used to visualize 8 or more +;; SPACEs at beginning of line. +;; +;; `blank-empty' Face used to visualize empty lines at +;; beginning and/or end of buffer. +;; +;; `blank-space-after-tab' Face used to visualize 8 or more +;; SPACEs after TAB. +;; ;; `blank-space-regexp' Specify SPACE characters regexp. ;; ;; `blank-hspace-regexp' Specify HARD SPACE characters regexp. @@ -208,6 +252,18 @@ ;; `blank-space-before-tab-regexp' Specify SPACEs before TAB ;; regexp. ;; +;; `blank-indentation-regexp' Specify regexp for 8 or more SPACEs at +;; beginning of line. +;; +;; `blank-empty-at-bob-regexp' Specify regexp for empty lines at +;; beginning of buffer. +;; +;; `blank-empty-at-eob-regexp' Specify regexp for empty lines at end +;; of buffer. +;; +;; `blank-space-after-tab-regexp' Specify regexp for 8 or more +;; SPACEs after TAB. +;; ;; `blank-line-length' Specify length beyond which the line ;; is highlighted. ;; @@ -249,6 +305,7 @@ ;; visws.el (his code was modified, but the main idea was kept). ;; ;; Thanks to: +;; Rajesh Vaidheeswarran whitespace.el ;; Aurelien Tisne show-whitespace-mode.el ;; Lawrence Mitchell whitespace-mode.el ;; Miles Bader visws.el @@ -297,7 +354,8 @@ See also `blank-display-mappings' for documentation." (defcustom blank-chars - '(tabs spaces trailing lines space-before-tab newline) + '(tabs spaces trailing lines space-before-tab newline + indentation empty space-after-tab) "*Specify which kind of blank is visualized. It's a list which element value can be: @@ -315,6 +373,14 @@ It's a list which element value can be: newline NEWLINEs are visualized. + indentation 8 or more SPACEs at beginning of line are + visualized. + + empty empty lines at beginning and/or end of buffer + are visualized. + + space-after-tab 8 or more SPACEs after a TAB are visualized. + Any other value is ignored. If nil, don't visualize TABs, (HARD) SPACEs and NEWLINEs. @@ -331,7 +397,12 @@ has `mark' as an element." (const :tag "Lines" lines) (const :tag "SPACEs before TAB" space-before-tab) - (const :tag "NEWLINEs" newline))) + (const :tag "NEWLINEs" newline) + (const :tag "Indentation SPACEs" indentation) + (const :tag "Empty Lines At BOB And/Or EOB" + empty) + (const :tag "SPACEs after TAB" + space-after-tab))) :group 'blank) @@ -461,6 +532,51 @@ Used when `blank-style' has `color' as an element." :group 'blank) +(defcustom blank-indentation 'blank-indentation + "*Symbol face used to visualize 8 or more SPACEs at beginning of line. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-indentation + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "yellow" :foreground "firebrick"))) + "Face used to visualize 8 or more SPACEs at beginning of line." + :group 'blank) + + +(defcustom blank-empty 'blank-empty + "*Symbol face used to visualize empty lines at beginning and/or end of buffer. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-empty + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "yellow" :foreground "firebrick"))) + "Face used to visualize empty lines at beginning and/or end of buffer." + :group 'blank) + + +(defcustom blank-space-after-tab 'blank-space-after-tab + "*Symbol face used to visualize 8 or more SPACEs after TAB. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-space-after-tab + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "yellow" :foreground "firebrick"))) + "Face used to visualize 8 or more SPACEs after TAB." + :group 'blank) + + (defcustom blank-hspace-regexp "\\(\\(\xA0\\|\x8A0\\|\x920\\|\xE20\\|\xF20\\)+\\)" "*Specify HARD SPACE characters regexp. @@ -574,6 +690,70 @@ Used when `blank-style' has `color' as an element, and :group 'blank) +(defcustom blank-indentation-regexp "^\t*\\(\\( \\{8\\}\\)+\\)[^\n\t]" + "*Specify regexp for 8 or more SPACEs at beginning of line. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that should be considered blank. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `indentation' as an element." + :type '(regexp :tag "Indentation SPACEs") + :group 'blank) + + +(defcustom blank-empty-at-bob-regexp "\\`\\(\\([ \t]*\n\\)+\\)" + "*Specify regexp for empty lines at beginning of buffer. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that should be considered blank. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `empty' as an element." + :type '(regexp :tag "Empty Lines At Beginning Of Buffer") + :group 'blank) + + +(defcustom blank-empty-at-eob-regexp "^\\([ \t\n]+\\)\\'" + "*Specify regexp for empty lines at end of buffer. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that should be considered blank. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `empty' as an element." + :type '(regexp :tag "Empty Lines At End Of Buffer") + :group 'blank) + + +(defcustom blank-space-after-tab-regexp "\t\\(\\( \\{8\\}\\)+\\)" + "*Specify regexp for 8 or more SPACEs after TAB. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that should be considered blank. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `space-after-tab' as an element." + :type '(regexp :tag "SPACEs After TAB") + :group 'blank) + + (defcustom blank-line-length 80 "*Specify length beyond which the line is highlighted. @@ -658,13 +838,13 @@ of the list is negated if it begins with `not'. For example: means that `blank-mode' is turned on for buffers in C and C++ modes only." - :type '(choice (const :tag "none" nil) - (const :tag "all" t) - (set :menu-tag "mode specific" :tag "modes" + :type '(choice (const :tag "None" nil) + (const :tag "All" t) + (set :menu-tag "Mode Specific" :tag "Modes" :value (not) (const :tag "Except" not) (repeat :inline t - (symbol :tag "mode")))) + (symbol :tag "Mode")))) :group 'blank) @@ -765,6 +945,9 @@ Only useful with a windowing system." space-before-tab lines newline + indentation + empty + space-after-tab ) "List of valid `blank-chars' values.") @@ -783,6 +966,9 @@ Only useful with a windowing system." (?b . space-before-tab) (?l . lines) (?n . newline) + (?i . indentation) + (?e . empty) + (?a . space-after-tab) (?c . color) (?m . mark) (?x . blank-chars) @@ -830,6 +1016,9 @@ Interactively, it reads one of the following chars: b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization n toggle NEWLINE visualization + i toggle indentation SPACEs visualization + e toggle empty line at bob and/or eob visualization + a toggle SPACEs after TAB visualization c toggle color faces m toggle visual mark x restore `blank-chars' value @@ -845,6 +1034,9 @@ The valid symbols are: space-before-tab toggle SPACEs before TAB visualization lines toggle \"long lines\" visualization newline toggle NEWLINE visualization + indentation toggle indentation SPACEs visualization + empty toggle empty line at bob and/or eob visualization + space-after-tab toggle SPACEs after TAB visualization color toggle color faces mark toggle visual mark blank-chars restore `blank-chars' value @@ -887,6 +1079,9 @@ Interactively, it reads one of the following chars: b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization n toggle NEWLINE visualization + i toggle indentation SPACEs visualization + e toggle empty line at bob and/or eob visualization + a toggle SPACEs after TAB visualization c toggle color faces m toggle visual mark x restore `blank-chars' value @@ -902,6 +1097,9 @@ The valid symbols are: space-before-tab toggle SPACEs before TAB visualization lines toggle \"long lines\" visualization newline toggle NEWLINE visualization + indentation toggle indentation SPACEs visualization + empty toggle empty line at bob and/or eob visualization + space-after-tab toggle SPACEs after TAB visualization color toggle color faces mark toggle visual mark blank-chars restore `blank-chars' value @@ -920,6 +1118,152 @@ Only useful with a windowing system." (global-blank-mode 0) (global-blank-mode 1))) + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; User commands - Cleanup + + +;;;###autoload +(defun blank-cleanup () + "Cleanup some blank problems in all buffer or at region. + +It usually applies to the whole buffer, but in transient mark +mode when the mark is active, it applies to the region. It also +applies to the region when it is not in transiente mark mode, the +mark is active and it was pressed `C-u' just before calling +`blank-cleanup' interactively. + +See also `blank-cleanup-region'. + +The problems, which are cleaned up, are: + +1. empty lines at beginning of buffer. +2. empty lines at end of buffer. + If `blank-chars' has `empty' as an element, remove all empty + lines at beginning and/or end of buffer. + +3. 8 or more SPACEs at beginning of line. + If `blank-chars' has `indentation' as an element, replace 8 or + more SPACEs at beginning of line by TABs. + +4. SPACEs before TAB. + If `blank-chars' has `space-before-tab' as an element, replace + SPACEs by TABs. + +5. SPACEs or TABs at end of line. + If `blank-chars' has `trailing' as an element, remove all + SPACEs or TABs at end of line. + +6. 8 or more SPACEs after TAB. + If `blank-chars' has `space-after-tab' as an element, replace + SPACEs by TABs." + (interactive "@*") + (if (and (or transient-mark-mode + current-prefix-arg) + mark-active) + ;; region active + ;; problems 1 and 2 are not handled in region + ;; problem 3: 8 or more SPACEs at bol + ;; problem 4: SPACEs before TAB + ;; problem 5: SPACEs or TABs at eol + ;; problem 6: 8 or more SPACEs after TAB + (blank-cleanup-region (region-beginning) (region-end)) + ;; whole buffer + (save-excursion + ;; problem 1: empty lines at bob + ;; problem 2: empty lines at eob + ;; action: remove all empty lines at bob and/or eob + (when (memq 'empty blank-chars) + (let (overwrite-mode) ; enforce no overwrite + (goto-char (point-min)) + (when (re-search-forward blank-empty-at-bob-regexp nil t) + (delete-region (match-beginning 1) (match-end 1))) + (when (re-search-forward blank-empty-at-eob-regexp nil t) + (delete-region (match-beginning 1) (match-end 1))))) + ;; problem 3: 8 or more SPACEs at bol + ;; problem 4: SPACEs before TAB + ;; problem 5: SPACEs or TABs at eol + ;; problem 6: 8 or more SPACEs after TAB + (blank-cleanup-region (point-min) (point-max))))) + + +;;;###autoload +(defun blank-cleanup-region (start end) + "Cleanup some blank problems at region. + +The problems, which are cleaned up, are: + +1. 8 or more SPACEs at beginning of line. + If `blank-chars' has `indentation' as an element, replace 8 or + more SPACEs at beginning of line by TABs. + +2. SPACEs before TAB. + If `blank-chars' has `space-before-tab' as an element, replace + SPACEs by TABs. + +3. SPACEs or TABs at end of line. + If `blank-chars' has `trailing' as an element, remove all + SPACEs or TABs at end of line. + +4. 8 or more SPACEs after TAB. + If `blank-chars' has `space-after-tab' as an element, replace + SPACEs by TABs." + (interactive "@*r") + (let ((rstart (min start end)) + (rend (copy-marker (max start end))) + (tab-width 8) ; assure TAB width + (indent-tabs-mode t) ; always insert TABs + overwrite-mode ; enforce no overwrite + tmp) + (save-excursion + ;; problem 1: 8 or more SPACEs at bol + ;; action: replace 8 or more SPACEs at bol by TABs + (when (memq 'indentation blank-chars) + (goto-char rstart) + (while (re-search-forward blank-indentation-regexp rend t) + (setq tmp (current-indentation)) + (delete-horizontal-space) + (unless (eolp) + (indent-to tmp)))) + ;; problem 3: SPACEs or TABs at eol + ;; action: remove all SPACEs or TABs at eol + (when (memq 'trailing blank-chars) + (let ((regexp + (concat "\\(\\(" blank-trailing-regexp "\\)+\\)$"))) + (goto-char rstart) + (while (re-search-forward regexp rend t) + (delete-region (match-beginning 1) (match-end 1))))) + ;; problem 4: 8 or more SPACEs after TAB + ;; action: replace 8 or more SPACEs by TABs + (when (memq 'space-after-tab blank-chars) + (goto-char rstart) + (while (re-search-forward blank-space-after-tab-regexp rend t) + (goto-char (match-beginning 1)) + (let ((scol (current-column)) + (ecol (save-excursion + (goto-char (match-end 1)) + (current-column)))) + (delete-region (match-beginning 1) (match-end 1)) + (insert-char ?\t (/ (- ecol scol) 8))))) + ;; problem 2: SPACEs before TAB + ;; action: replace SPACEs before TAB by TABs + (when (memq 'space-before-tab blank-chars) + (goto-char rstart) + (while (re-search-forward blank-space-before-tab-regexp rend t) + (goto-char (match-beginning 1)) + (let* ((scol (current-column)) + (ecol (save-excursion + (goto-char (match-end 1)) + (current-column))) + (next-tab-col (* (/ (+ scol 8) 8) 8))) + (delete-region (match-beginning 1) (match-end 1)) + (when (<= next-tab-col ecol) + (insert-char ?\t + (/ (- (- ecol (% ecol 8)) ; prev end col + (- scol (% scol 8))) ; prev start col + 8))))))) + (set-marker rend nil))) ; point marker to nowhere + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;; Internal functions @@ -948,6 +1292,9 @@ Only useful with a windowing system." [] b - toggle SPACEs before TAB visualization [] l - toggle \"long lines\" visualization [] n - toggle NEWLINE visualization + [] i - toggle indentation SPACEs visualization + [] e - toggle empty line at bob and/or eob visualization + [] a - toggle SPACEs after TAB visualization [] c - toggle color faces [] m - toggle visual mark @@ -1019,6 +1366,9 @@ It reads one of the following chars: b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization n toggle NEWLINE visualization + i toggle indentation SPACEs visualization + e toggle empty line at bob and/or eob visualization + a toggle SPACEs after TAB visualization c toggle color faces m toggle visual mark x restore `blank-chars' value @@ -1171,6 +1521,37 @@ options are valid." (list blank-space-before-tab-regexp 1 blank-space-before-tab t)) t)) + (when (memq 'indentation blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show indentation SPACEs + (list blank-indentation-regexp + 1 blank-indentation t)) + t)) + (when (memq 'empty blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show empty lines at beginning of buffer + (list blank-empty-at-bob-regexp + 1 blank-empty t)) + t) + (font-lock-add-keywords + nil + (list + ;; Show empty lines at end of buffer + (list blank-empty-at-eob-regexp + 1 blank-empty t)) + t)) + (when (memq 'space-after-tab blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show SPACEs after TAB + (list blank-space-after-tab-regexp + 1 blank-space-after-tab t)) + t)) ;; now turn on font lock and highlight blanks (font-lock-mode 1))) From 0feb2f35d3748400f297f6c608809018bb2b9da1 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Fri, 25 Jan 2008 14:10:35 +0000 Subject: [PATCH 318/439] New commands for cleaning up some blank problems like trailing blanks. --- lisp/ChangeLog | 15 ++ lisp/blank-mode.el | 395 ++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 403 insertions(+), 7 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b620ff1e667..47e983862b7 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,18 @@ +2008-01-25 Vinicius Jose Latorre + + * blank-mode.el: New version 9.0. New commands to clean up some blank + problems like trailing blanks. New faces and regexp for visualizing + the blank problems. Doc fix. + (blank-chars, blank-global-modes, blank-chars-value-list) + (blank-toggle-option-alist, blank-help-text): Initialization fix. + (blank-indentation, blank-empty, blank-space-after-tab): New faces. + (blank-indentation, blank-empty, blank-space-after-tab) + (blank-indentation-regexp, blank-empty-at-bob-regexp) + (blank-empty-at-eob-regexp, blank-space-after-tab-regexp): New + options. + (blank-cleanup, blank-cleanup-region): New commands. + (blank-color-on): Code fix. + 2008-01-25 Sven Joachim * view.el (kill-buffer-if-not-modified): Don't pass t to diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el index 9d36ebde6ae..315ac99ea7b 100644 --- a/lisp/blank-mode.el +++ b/lisp/blank-mode.el @@ -6,7 +6,7 @@ ;; Author: Vinicius Jose Latorre ;; Maintainer: Vinicius Jose Latorre ;; Keywords: data, wp -;; Version: 8.1 +;; Version: 9.0 ;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre ;; This file is part of GNU Emacs. @@ -100,6 +100,10 @@ ;; ;; blank-mode was inspired by: ;; +;; whitespace.el Rajesh Vaidheeswarran +;; Warn about and clean bogus whitespaces in the file +;; (inspired the idea to warn and clean some blanks) +;; ;; show-whitespace-mode.el Aurelien Tisne ;; Simple mode to highlight whitespaces ;; (inspired the idea to use font-lock) @@ -153,6 +157,37 @@ ;; ;; M-x global-blank-mode RET ;; +;; There are also the following useful commands: +;; +;; `blank-cleanup' +;; Cleanup some blank problems in all buffer or at region. +;; +;; `blank-cleanup-region' +;; Cleanup some blank problems at region. +;; +;; The problems, which are cleaned up, are: +;; +;; 1. empty lines at beginning of buffer. +;; 2. empty lines at end of buffer. +;; If `blank-chars' has `empty' as an element, remove all empty +;; lines at beginning and/or end of buffer. +;; +;; 3. 8 or more SPACEs at beginning of line. +;; If `blank-chars' has `indentation' as an element, replace 8 or +;; more SPACEs at beginning of line by TABs. +;; +;; 4. SPACEs before TAB. +;; If `blank-chars' has `space-before-tab' as an element, replace +;; SPACEs by TABs. +;; +;; 5. SPACEs or TABs at end of line. +;; If `blank-chars' has `trailing' as an element, remove all +;; SPACEs or TABs at end of line." +;; +;; 6. 8 or more SPACEs after TAB. +;; If `blank-chars' has `space-after-tab' as an element, replace +;; SPACEs by TABs. +;; ;; ;; Hooks ;; ----- @@ -197,6 +232,15 @@ ;; `blank-space-before-tab' Face used to visualize SPACEs before ;; TAB. ;; +;; `blank-indentation' Face used to visualize 8 or more +;; SPACEs at beginning of line. +;; +;; `blank-empty' Face used to visualize empty lines at +;; beginning and/or end of buffer. +;; +;; `blank-space-after-tab' Face used to visualize 8 or more +;; SPACEs after TAB. +;; ;; `blank-space-regexp' Specify SPACE characters regexp. ;; ;; `blank-hspace-regexp' Specify HARD SPACE characters regexp. @@ -208,6 +252,18 @@ ;; `blank-space-before-tab-regexp' Specify SPACEs before TAB ;; regexp. ;; +;; `blank-indentation-regexp' Specify regexp for 8 or more SPACEs at +;; beginning of line. +;; +;; `blank-empty-at-bob-regexp' Specify regexp for empty lines at +;; beginning of buffer. +;; +;; `blank-empty-at-eob-regexp' Specify regexp for empty lines at end +;; of buffer. +;; +;; `blank-space-after-tab-regexp' Specify regexp for 8 or more +;; SPACEs after TAB. +;; ;; `blank-line-length' Specify length beyond which the line ;; is highlighted. ;; @@ -249,6 +305,7 @@ ;; visws.el (his code was modified, but the main idea was kept). ;; ;; Thanks to: +;; Rajesh Vaidheeswarran whitespace.el ;; Aurelien Tisne show-whitespace-mode.el ;; Lawrence Mitchell whitespace-mode.el ;; Miles Bader visws.el @@ -297,7 +354,8 @@ See also `blank-display-mappings' for documentation." (defcustom blank-chars - '(tabs spaces trailing lines space-before-tab newline) + '(tabs spaces trailing lines space-before-tab newline + indentation empty space-after-tab) "*Specify which kind of blank is visualized. It's a list which element value can be: @@ -315,6 +373,14 @@ It's a list which element value can be: newline NEWLINEs are visualized. + indentation 8 or more SPACEs at beginning of line are + visualized. + + empty empty lines at beginning and/or end of buffer + are visualized. + + space-after-tab 8 or more SPACEs after a TAB are visualized. + Any other value is ignored. If nil, don't visualize TABs, (HARD) SPACEs and NEWLINEs. @@ -331,7 +397,12 @@ has `mark' as an element." (const :tag "Lines" lines) (const :tag "SPACEs before TAB" space-before-tab) - (const :tag "NEWLINEs" newline))) + (const :tag "NEWLINEs" newline) + (const :tag "Indentation SPACEs" indentation) + (const :tag "Empty Lines At BOB And/Or EOB" + empty) + (const :tag "SPACEs after TAB" + space-after-tab))) :group 'blank) @@ -461,6 +532,51 @@ Used when `blank-style' has `color' as an element." :group 'blank) +(defcustom blank-indentation 'blank-indentation + "*Symbol face used to visualize 8 or more SPACEs at beginning of line. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-indentation + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "yellow" :foreground "firebrick"))) + "Face used to visualize 8 or more SPACEs at beginning of line." + :group 'blank) + + +(defcustom blank-empty 'blank-empty + "*Symbol face used to visualize empty lines at beginning and/or end of buffer. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-empty + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "yellow" :foreground "firebrick"))) + "Face used to visualize empty lines at beginning and/or end of buffer." + :group 'blank) + + +(defcustom blank-space-after-tab 'blank-space-after-tab + "*Symbol face used to visualize 8 or more SPACEs after TAB. + +Used when `blank-style' has `color' as an element." + :type 'face + :group 'blank) + + +(defface blank-space-after-tab + '((((class mono)) (:inverse-video t :bold t :underline t)) + (t (:background "yellow" :foreground "firebrick"))) + "Face used to visualize 8 or more SPACEs after TAB." + :group 'blank) + + (defcustom blank-hspace-regexp "\\(\\(\xA0\\|\x8A0\\|\x920\\|\xE20\\|\xF20\\)+\\)" "*Specify HARD SPACE characters regexp. @@ -574,6 +690,70 @@ Used when `blank-style' has `color' as an element, and :group 'blank) +(defcustom blank-indentation-regexp "^\t*\\(\\( \\{8\\}\\)+\\)[^\n\t]" + "*Specify regexp for 8 or more SPACEs at beginning of line. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that should be considered blank. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `indentation' as an element." + :type '(regexp :tag "Indentation SPACEs") + :group 'blank) + + +(defcustom blank-empty-at-bob-regexp "\\`\\(\\([ \t]*\n\\)+\\)" + "*Specify regexp for empty lines at beginning of buffer. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that should be considered blank. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `empty' as an element." + :type '(regexp :tag "Empty Lines At Beginning Of Buffer") + :group 'blank) + + +(defcustom blank-empty-at-eob-regexp "^\\([ \t\n]+\\)\\'" + "*Specify regexp for empty lines at end of buffer. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that should be considered blank. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `empty' as an element." + :type '(regexp :tag "Empty Lines At End Of Buffer") + :group 'blank) + + +(defcustom blank-space-after-tab-regexp "\t\\(\\( \\{8\\}\\)+\\)" + "*Specify regexp for 8 or more SPACEs after TAB. + +If you're using `mule' package, it may exist other characters besides: + + \" \" \"\\t\" \"\\xA0\" \"\\x8A0\" \"\\x920\" \"\\xE20\" \ +\"\\xF20\" + +that should be considered blank. + +Used when `blank-style' has `color' as an element, and +`blank-chars' has `space-after-tab' as an element." + :type '(regexp :tag "SPACEs After TAB") + :group 'blank) + + (defcustom blank-line-length 80 "*Specify length beyond which the line is highlighted. @@ -658,13 +838,13 @@ of the list is negated if it begins with `not'. For example: means that `blank-mode' is turned on for buffers in C and C++ modes only." - :type '(choice (const :tag "none" nil) - (const :tag "all" t) - (set :menu-tag "mode specific" :tag "modes" + :type '(choice (const :tag "None" nil) + (const :tag "All" t) + (set :menu-tag "Mode Specific" :tag "Modes" :value (not) (const :tag "Except" not) (repeat :inline t - (symbol :tag "mode")))) + (symbol :tag "Mode")))) :group 'blank) @@ -765,6 +945,9 @@ Only useful with a windowing system." space-before-tab lines newline + indentation + empty + space-after-tab ) "List of valid `blank-chars' values.") @@ -783,6 +966,9 @@ Only useful with a windowing system." (?b . space-before-tab) (?l . lines) (?n . newline) + (?i . indentation) + (?e . empty) + (?a . space-after-tab) (?c . color) (?m . mark) (?x . blank-chars) @@ -830,6 +1016,9 @@ Interactively, it reads one of the following chars: b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization n toggle NEWLINE visualization + i toggle indentation SPACEs visualization + e toggle empty line at bob and/or eob visualization + a toggle SPACEs after TAB visualization c toggle color faces m toggle visual mark x restore `blank-chars' value @@ -845,6 +1034,9 @@ The valid symbols are: space-before-tab toggle SPACEs before TAB visualization lines toggle \"long lines\" visualization newline toggle NEWLINE visualization + indentation toggle indentation SPACEs visualization + empty toggle empty line at bob and/or eob visualization + space-after-tab toggle SPACEs after TAB visualization color toggle color faces mark toggle visual mark blank-chars restore `blank-chars' value @@ -887,6 +1079,9 @@ Interactively, it reads one of the following chars: b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization n toggle NEWLINE visualization + i toggle indentation SPACEs visualization + e toggle empty line at bob and/or eob visualization + a toggle SPACEs after TAB visualization c toggle color faces m toggle visual mark x restore `blank-chars' value @@ -902,6 +1097,9 @@ The valid symbols are: space-before-tab toggle SPACEs before TAB visualization lines toggle \"long lines\" visualization newline toggle NEWLINE visualization + indentation toggle indentation SPACEs visualization + empty toggle empty line at bob and/or eob visualization + space-after-tab toggle SPACEs after TAB visualization color toggle color faces mark toggle visual mark blank-chars restore `blank-chars' value @@ -920,6 +1118,152 @@ Only useful with a windowing system." (global-blank-mode 0) (global-blank-mode 1))) + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; User commands - Cleanup + + +;;;###autoload +(defun blank-cleanup () + "Cleanup some blank problems in all buffer or at region. + +It usually applies to the whole buffer, but in transient mark +mode when the mark is active, it applies to the region. It also +applies to the region when it is not in transiente mark mode, the +mark is active and it was pressed `C-u' just before calling +`blank-cleanup' interactively. + +See also `blank-cleanup-region'. + +The problems, which are cleaned up, are: + +1. empty lines at beginning of buffer. +2. empty lines at end of buffer. + If `blank-chars' has `empty' as an element, remove all empty + lines at beginning and/or end of buffer. + +3. 8 or more SPACEs at beginning of line. + If `blank-chars' has `indentation' as an element, replace 8 or + more SPACEs at beginning of line by TABs. + +4. SPACEs before TAB. + If `blank-chars' has `space-before-tab' as an element, replace + SPACEs by TABs. + +5. SPACEs or TABs at end of line. + If `blank-chars' has `trailing' as an element, remove all + SPACEs or TABs at end of line. + +6. 8 or more SPACEs after TAB. + If `blank-chars' has `space-after-tab' as an element, replace + SPACEs by TABs." + (interactive "@*") + (if (and (or transient-mark-mode + current-prefix-arg) + mark-active) + ;; region active + ;; problems 1 and 2 are not handled in region + ;; problem 3: 8 or more SPACEs at bol + ;; problem 4: SPACEs before TAB + ;; problem 5: SPACEs or TABs at eol + ;; problem 6: 8 or more SPACEs after TAB + (blank-cleanup-region (region-beginning) (region-end)) + ;; whole buffer + (save-excursion + ;; problem 1: empty lines at bob + ;; problem 2: empty lines at eob + ;; action: remove all empty lines at bob and/or eob + (when (memq 'empty blank-chars) + (let (overwrite-mode) ; enforce no overwrite + (goto-char (point-min)) + (when (re-search-forward blank-empty-at-bob-regexp nil t) + (delete-region (match-beginning 1) (match-end 1))) + (when (re-search-forward blank-empty-at-eob-regexp nil t) + (delete-region (match-beginning 1) (match-end 1))))) + ;; problem 3: 8 or more SPACEs at bol + ;; problem 4: SPACEs before TAB + ;; problem 5: SPACEs or TABs at eol + ;; problem 6: 8 or more SPACEs after TAB + (blank-cleanup-region (point-min) (point-max))))) + + +;;;###autoload +(defun blank-cleanup-region (start end) + "Cleanup some blank problems at region. + +The problems, which are cleaned up, are: + +1. 8 or more SPACEs at beginning of line. + If `blank-chars' has `indentation' as an element, replace 8 or + more SPACEs at beginning of line by TABs. + +2. SPACEs before TAB. + If `blank-chars' has `space-before-tab' as an element, replace + SPACEs by TABs. + +3. SPACEs or TABs at end of line. + If `blank-chars' has `trailing' as an element, remove all + SPACEs or TABs at end of line. + +4. 8 or more SPACEs after TAB. + If `blank-chars' has `space-after-tab' as an element, replace + SPACEs by TABs." + (interactive "@*r") + (let ((rstart (min start end)) + (rend (copy-marker (max start end))) + (tab-width 8) ; assure TAB width + (indent-tabs-mode t) ; always insert TABs + overwrite-mode ; enforce no overwrite + tmp) + (save-excursion + ;; problem 1: 8 or more SPACEs at bol + ;; action: replace 8 or more SPACEs at bol by TABs + (when (memq 'indentation blank-chars) + (goto-char rstart) + (while (re-search-forward blank-indentation-regexp rend t) + (setq tmp (current-indentation)) + (delete-horizontal-space) + (unless (eolp) + (indent-to tmp)))) + ;; problem 3: SPACEs or TABs at eol + ;; action: remove all SPACEs or TABs at eol + (when (memq 'trailing blank-chars) + (let ((regexp + (concat "\\(\\(" blank-trailing-regexp "\\)+\\)$"))) + (goto-char rstart) + (while (re-search-forward regexp rend t) + (delete-region (match-beginning 1) (match-end 1))))) + ;; problem 4: 8 or more SPACEs after TAB + ;; action: replace 8 or more SPACEs by TABs + (when (memq 'space-after-tab blank-chars) + (goto-char rstart) + (while (re-search-forward blank-space-after-tab-regexp rend t) + (goto-char (match-beginning 1)) + (let ((scol (current-column)) + (ecol (save-excursion + (goto-char (match-end 1)) + (current-column)))) + (delete-region (match-beginning 1) (match-end 1)) + (insert-char ?\t (/ (- ecol scol) 8))))) + ;; problem 2: SPACEs before TAB + ;; action: replace SPACEs before TAB by TABs + (when (memq 'space-before-tab blank-chars) + (goto-char rstart) + (while (re-search-forward blank-space-before-tab-regexp rend t) + (goto-char (match-beginning 1)) + (let* ((scol (current-column)) + (ecol (save-excursion + (goto-char (match-end 1)) + (current-column))) + (next-tab-col (* (/ (+ scol 8) 8) 8))) + (delete-region (match-beginning 1) (match-end 1)) + (when (<= next-tab-col ecol) + (insert-char ?\t + (/ (- (- ecol (% ecol 8)) ; prev end col + (- scol (% scol 8))) ; prev start col + 8))))))) + (set-marker rend nil))) ; point marker to nowhere + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;; Internal functions @@ -948,6 +1292,9 @@ Only useful with a windowing system." [] b - toggle SPACEs before TAB visualization [] l - toggle \"long lines\" visualization [] n - toggle NEWLINE visualization + [] i - toggle indentation SPACEs visualization + [] e - toggle empty line at bob and/or eob visualization + [] a - toggle SPACEs after TAB visualization [] c - toggle color faces [] m - toggle visual mark @@ -1019,6 +1366,9 @@ It reads one of the following chars: b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization n toggle NEWLINE visualization + i toggle indentation SPACEs visualization + e toggle empty line at bob and/or eob visualization + a toggle SPACEs after TAB visualization c toggle color faces m toggle visual mark x restore `blank-chars' value @@ -1171,6 +1521,37 @@ options are valid." (list blank-space-before-tab-regexp 1 blank-space-before-tab t)) t)) + (when (memq 'indentation blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show indentation SPACEs + (list blank-indentation-regexp + 1 blank-indentation t)) + t)) + (when (memq 'empty blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show empty lines at beginning of buffer + (list blank-empty-at-bob-regexp + 1 blank-empty t)) + t) + (font-lock-add-keywords + nil + (list + ;; Show empty lines at end of buffer + (list blank-empty-at-eob-regexp + 1 blank-empty t)) + t)) + (when (memq 'space-after-tab blank-active-chars) + (font-lock-add-keywords + nil + (list + ;; Show SPACEs after TAB + (list blank-space-after-tab-regexp + 1 blank-space-after-tab t)) + t)) ;; now turn on font lock and highlight blanks (font-lock-mode 1))) From 41ff6d0a23c2002affb8f5235a84a49a8245d9f7 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Fri, 25 Jan 2008 15:11:18 +0000 Subject: [PATCH 319/439] (allout-unload-function): New function. --- lisp/allout.el | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/lisp/allout.el b/lisp/allout.el index 43642e6ee26..7782170e834 100644 --- a/lisp/allout.el +++ b/lisp/allout.el @@ -2120,6 +2120,16 @@ OPEN: A TOPIC that is not CLOSED, though its OFFSPRING or BODY may be." ;;;_ > allout-minor-mode (defalias 'allout-minor-mode 'allout-mode) +;;;_ > allout-unload-function +(defun allout-unload-function () + "Unload the allout outline library." + (save-current-buffer + (dolist (buffer (buffer-list)) + (set-buffer buffer) + (when allout-mode (allout-mode -1)))) + ;; continue standard unloading + nil) + ;;;_ - Position Assessment ;;;_ > allout-hidden-p (&optional pos) (defsubst allout-hidden-p (&optional pos) From b939b83f27e761ca5451bf0bbe5b74a011747068 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Fri, 25 Jan 2008 15:25:23 +0000 Subject: [PATCH 320/439] *** empty log message *** --- lisp/ChangeLog | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 47e983862b7..2d3543022d0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-25 Juanma Barranquero + + * allout.el (allout-unload-function): New function. + 2008-01-25 Vinicius Jose Latorre * blank-mode.el: New version 9.0. New commands to clean up some blank @@ -8,8 +12,7 @@ (blank-indentation, blank-empty, blank-space-after-tab): New faces. (blank-indentation, blank-empty, blank-space-after-tab) (blank-indentation-regexp, blank-empty-at-bob-regexp) - (blank-empty-at-eob-regexp, blank-space-after-tab-regexp): New - options. + (blank-empty-at-eob-regexp, blank-space-after-tab-regexp): New options. (blank-cleanup, blank-cleanup-region): New commands. (blank-color-on): Code fix. From 38b9f0f370787df00241e25cdb83aa4373801d60 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Fri, 25 Jan 2008 15:43:05 +0000 Subject: [PATCH 321/439] (server-process-filter): Don't force the authentication string to be followed by "\n". --- lisp/server.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/server.el b/lisp/server.el index 2087af26b10..23f8eb36947 100644 --- a/lisp/server.el +++ b/lisp/server.el @@ -767,7 +767,7 @@ The following commands are accepted by the client: (server-log (concat "Received " string) proc) ;; First things first: let's check the authentication (unless (process-get proc :authenticated) - (if (and (string-match "-auth \\(.*?\\)\n" string) + (if (and (string-match "-auth \\([!-~]+\\)\n?" string) (equal (match-string 1 string) (process-get proc :auth-key))) (progn (setq string (substring string (match-end 0))) From 5ab73228619adb09dea84e4abf01a11cf5a6f024 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Fri, 25 Jan 2008 15:46:07 +0000 Subject: [PATCH 322/439] (set_tcp_socket): Don't send a "\n" after the authentication string; there's no need to haste. --- lib-src/ChangeLog | 5 +++++ lib-src/emacsclient.c | 6 +++--- lisp/ChangeLog | 8 ++++++-- 3 files changed, 14 insertions(+), 5 deletions(-) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index 05d8af126bb..c1fb7e9293f 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,8 @@ +2008-01-25 Juanma Barranquero + + * emacsclient.c (set_tcp_socket): Don't send "\n" after + the authentication string; there's no need to haste. + 2008-01-22 Chong Yidong * pop.c (pop_stat, pop_last): Fix last fix. diff --git a/lib-src/emacsclient.c b/lib-src/emacsclient.c index 568b6c18119..b8ab19721ff 100644 --- a/lib-src/emacsclient.c +++ b/lib-src/emacsclient.c @@ -229,7 +229,7 @@ xstrdup (const char *s) /* Return the current working directory. Returns NULL on errors. - Any other returned value must be freed with free. This is used + Any other returned value must be freed with free. This is used only when get_current_dir_name is not defined on the system. */ char* get_current_dir_name () @@ -1010,7 +1010,7 @@ set_tcp_socket () send_to_emacs (s, "-auth "); send_to_emacs (s, auth_string); - send_to_emacs (s, "\n"); + send_to_emacs (s, " "); return s; } @@ -1100,7 +1100,7 @@ handle_sigtstp (int signalnum) if (emacs_socket) send_to_emacs (emacs_socket, "-suspend \n"); - /* Unblock this signal and call the default handler by temprarily + /* Unblock this signal and call the default handler by temporarily changing the handler and resignalling. */ sigprocmask (SIG_BLOCK, NULL, &set); sigdelset (&set, signalnum); diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 49b2015b321..2058d25ecef 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-25 Juanma Barranquero + + * server.el (server-process-filter): Don't force + the authentication string to be followed by "\n". + 2008-01-25 Vinicius Jose Latorre * blank-mode.el: New version 9.0. New commands to clean up some blank @@ -8,8 +13,7 @@ (blank-indentation, blank-empty, blank-space-after-tab): New faces. (blank-indentation, blank-empty, blank-space-after-tab) (blank-indentation-regexp, blank-empty-at-bob-regexp) - (blank-empty-at-eob-regexp, blank-space-after-tab-regexp): New - options. + (blank-empty-at-eob-regexp, blank-space-after-tab-regexp): New options. (blank-cleanup, blank-cleanup-region): New commands. (blank-color-on): Code fix. From 34a14ec974bca41fbc7a19d7365cfce000b79302 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Fri, 25 Jan 2008 15:52:08 +0000 Subject: [PATCH 323/439] *** empty log message *** --- lib-src/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index c1fb7e9293f..7409d136527 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -33,7 +33,7 @@ * emacsclient.c: Add missing final newlines to message calls. -2008-01-09 Daniel Hackney (tiny change) +2008-01-09 Daniel Hackney (tiny change) * emacsclient.c (set_socket): Add final newline to socket error message. From d454552ce373195c83a6a97081342053394585c0 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Fri, 25 Jan 2008 17:48:59 +0000 Subject: [PATCH 324/439] (find-library): Wrap search for library name in condition-case to avoid reporting a scan-error. --- lisp/ChangeLog | 5 +++++ lisp/emacs-lisp/find-func.el | 16 +++++++++++----- 2 files changed, 16 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2058d25ecef..b3b48c704cc 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-25 Martin Rudalics + + * emacs-lisp/find-func.el (find-library): Wrap search for + library name in condition-case to avoid reporting a scan-error. + 2008-01-25 Juanma Barranquero * server.el (server-process-filter): Don't force diff --git a/lisp/emacs-lisp/find-func.el b/lisp/emacs-lisp/find-func.el index 7c4c01a6e32..58695e95347 100644 --- a/lisp/emacs-lisp/find-func.el +++ b/lisp/emacs-lisp/find-func.el @@ -200,11 +200,17 @@ TYPE should be nil to find a function, or `defvar' to find a variable." (let* ((path (cons (or find-function-source-path load-path) (find-library-suffixes))) (def (if (eq (function-called-at-point) 'require) - (save-excursion - (backward-up-list) - (forward-char) - (backward-sexp -2) - (thing-at-point 'symbol)) + ;; `function-called-at-point' may return 'require + ;; with `point' anywhere on this line. So wrap the + ;; `save-excursion' below in a `condition-case' to + ;; avoid reporting a scan-error here. + (condition-case nil + (save-excursion + (backward-up-list) + (forward-char) + (forward-sexp 2) + (thing-at-point 'symbol)) + (error nil)) (thing-at-point 'symbol)))) (when def (setq def (and (locate-file-completion def path 'test) def))) From 79235cbe2d1942c461226a889458449b209ce154 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Fri, 25 Jan 2008 18:56:19 +0000 Subject: [PATCH 325/439] *** empty log message *** --- src/ChangeLog | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index a6d8cc928d6..73d2e1d05c7 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-25 Michael Albinus + + * dbusbind.c (xd_retrieve_arg): Pacify GCC on x86_64 GNU/Linux. + 2008-01-25 Thien-Thi Nguyen * fns.c (Fclrhash): Return TABLE. From b35c64e48f4d1d71e7bb3b1bfc0b1de2d2eb3f9a Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Fri, 25 Jan 2008 18:56:46 +0000 Subject: [PATCH 326/439] * dbusbind.c (xd_retrieve_arg): Pacify GCC on x86_64 GNU/Linux. --- src/dbusbind.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/dbusbind.c b/src/dbusbind.c index badcf1f14d7..4bc48f3b6e9 100644 --- a/src/dbusbind.c +++ b/src/dbusbind.c @@ -594,10 +594,14 @@ xd_retrieve_arg (dtype, iter) case DBUS_TYPE_INT32: case DBUS_TYPE_UINT32: { + /* Assignment to EMACS_INT stops GCC whining about limited + range of data type. */ dbus_uint32_t val; + EMACS_INT val1; dbus_message_iter_get_basic (iter, &val); XD_DEBUG_MESSAGE ("%c %d", dtype, val); - return make_fixnum_or_float (val); + val1 = val; + return make_fixnum_or_float (val1); } case DBUS_TYPE_INT64: From 8f696e65587ebacf9a0bb812938ab1fc94e921bb Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 25 Jan 2008 22:50:33 +0000 Subject: [PATCH 327/439] (file-provides, file-requires): Push the filename right. --- lisp/loadhist.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/loadhist.el b/lisp/loadhist.el index 5aaa06b0a11..71e81ae4221 100644 --- a/lisp/loadhist.el +++ b/lisp/loadhist.el @@ -74,7 +74,7 @@ A library name is equivalent to the file name that `load-library' would load." (let (provides) (dolist (x (file-loadhist-lookup file) provides) (when (eq (car-safe x) 'provide) - (push x provides))))) + (push (cdr x) provides))))) (defun file-requires (file) "Return the list of features required by FILE as it was loaded. @@ -83,7 +83,7 @@ A library name is equivalent to the file name that `load-library' would load." (let (requires) (dolist (x (file-loadhist-lookup file) requires) (when (eq (car-safe x) 'require) - (push x requires))))) + (push (cdr x) requires))))) (defsubst file-set-intersect (p q) "Return the set intersection of two lists." From 3531046188b20307bb5097cd5d41012ba87bb3af Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 25 Jan 2008 22:51:18 +0000 Subject: [PATCH 328/439] (add-hook): Implement `permanent-local-hook' property. --- lisp/subr.el | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/lisp/subr.el b/lisp/subr.el index ca479de2687..5a7f88f76dd 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -1103,7 +1103,17 @@ function, it is changed to a list of functions." (append hook-value (list function)) (cons function hook-value)))) ;; Set the actual variable - (if local (set hook hook-value) (set-default hook hook-value)))) + (if local + (progn + ;; If HOOK isn't a permanent local, + ;; but FUNCTION wants to survive a change of modes, + ;; mark HOOK as partially permanent. + (and (symbolp function) + (get function 'permanent-local-hook) + (not (get hook 'permanent-local)) + (put hook 'permanent-local 'permanent-local-hook)) + (set hook hook-value)) + (set-default hook hook-value)))) (defun remove-hook (hook function &optional local) "Remove from the value of HOOK the function FUNCTION. From 2b88d62a493196add69d764cf971e4f10ab1e42d Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 25 Jan 2008 22:52:50 +0000 Subject: [PATCH 329/439] Trivial change. --- lisp/ChangeLog | 6 ++++++ lisp/emacs-lisp/cl-macs.el | 11 ++++++----- 2 files changed, 12 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b3b48c704cc..84c8c78e700 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-25 Richard Stallman + + * subr.el (add-hook): Implement `permanent-local-hook' property. + + * loadhist.el (file-provides, file-requires): Push the filename right. + 2008-01-25 Martin Rudalics * emacs-lisp/find-func.el (find-library): Wrap search for diff --git a/lisp/emacs-lisp/cl-macs.el b/lisp/emacs-lisp/cl-macs.el index 9e078d04be3..17da9cc5154 100644 --- a/lisp/emacs-lisp/cl-macs.el +++ b/lisp/emacs-lisp/cl-macs.el @@ -2508,11 +2508,12 @@ They are not evaluated unless the assertion fails. If STRING is omitted, a default message listing FORM itself is used." (and (or (not (cl-compiling-file)) (< cl-optimize-speed 3) (= cl-optimize-safety 3)) - (let ((sargs (and show-args (delq nil (mapcar - (function - (lambda (x) - (and (not (cl-const-expr-p x)) - x))) (cdr form)))))) + (let ((sargs (and show-args + (delq nil (mapcar + (lambda (x) + (unless (cl-const-expr-p x) + x)) + (cdr form)))))) (list 'progn (list 'or form (if string From 2f7a359dddf8eff1830548918d2fdc43211b84a9 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 25 Jan 2008 22:56:30 +0000 Subject: [PATCH 330/439] (reset_buffer_local_variables): Implement `permanent-local-hook'. (Qpermanent_local_hook): New variable. (syms_of_buffer): init and staticpro it. --- src/buffer.c | 37 +++++++++++++++++++++++++++++++++---- 1 file changed, 33 insertions(+), 4 deletions(-) diff --git a/src/buffer.c b/src/buffer.c index 6cbaabf85ec..cf125559f76 100644 --- a/src/buffer.c +++ b/src/buffer.c @@ -153,6 +153,7 @@ Lisp_Object Qucs_set_table_for_input; int inhibit_modification_hooks; Lisp_Object Qfundamental_mode, Qmode_class, Qpermanent_local; +Lisp_Object Qpermanent_local_hook; Lisp_Object Qprotected_field; @@ -761,13 +762,38 @@ reset_buffer_local_variables (b, permanent_too) b->local_var_alist = Qnil; else { - Lisp_Object tmp, last = Qnil; + Lisp_Object tmp, prop, last = Qnil; for (tmp = b->local_var_alist; CONSP (tmp); tmp = XCDR (tmp)) if (CONSP (XCAR (tmp)) && SYMBOLP (XCAR (XCAR (tmp))) - && !NILP (Fget (XCAR (XCAR (tmp)), Qpermanent_local))) - /* If permanent-local, keep it. */ - last = tmp; + && !NILP (prop = Fget (XCAR (XCAR (tmp)), Qpermanent_local))) + { + /* If permanent-local, keep it. */ + last = tmp; + if (EQ (prop, Qpermanent_local_hook)) + { + /* This is a partially permanent hook variable. + Preserve only the elements that want to be preserved. */ + Lisp_Object list, newlist; + list = XCDR (XCAR (tmp)); + if (!CONSP (list)) + newlist = list; + else + for (newlist = Qnil; CONSP (list); list = XCDR (list)) + { + Lisp_Object elt = XCAR (list); + /* Preserve element ELT if it's t, + if it is a function with a `permanent-local-hook' property, + or if it's not a symbol. */ + if (! SYMBOLP (elt) + || EQ (elt, Qt) + || !NILP (Fget (elt, Qpermanent_local_hook))) + newlist = Fcons (elt, newlist); + } + XSETCDR (XCAR (tmp), Fnreverse (newlist)); + } + } + /* Delete this local variable. */ else if (NILP (last)) b->local_var_alist = XCDR (tmp); else @@ -5292,6 +5318,8 @@ syms_of_buffer () staticpro (&Vbuffer_alist); staticpro (&Qprotected_field); staticpro (&Qpermanent_local); + Qpermanent_local_hook = intern ("permanent-local-hook"); + staticpro (&Qpermanent_local_hook); staticpro (&Qkill_buffer_hook); Qoverlayp = intern ("overlayp"); staticpro (&Qoverlayp); @@ -5319,6 +5347,7 @@ syms_of_buffer () staticpro (&Qbefore_change_functions); Qafter_change_functions = intern ("after-change-functions"); staticpro (&Qafter_change_functions); + /* The next one is initialized in init_buffer_once. */ staticpro (&Qucs_set_table_for_input); Qkill_buffer_query_functions = intern ("kill-buffer-query-functions"); From 94f9b406a79c27dff71194a30995efac3a9510fd Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 25 Jan 2008 22:57:41 +0000 Subject: [PATCH 331/439] (read_char): Restore echo_message_buffer after redisplay. --- src/keyboard.c | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/keyboard.c b/src/keyboard.c index 4d31c9e01b8..2187c22bdb7 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -2704,6 +2704,8 @@ read_char (commandflag, nmaps, maps, prev_event, used_mouse_menu, end_time) /* if redisplay was requested */ if (commandflag >= 0) { + int echo_current = echo_message_buffer == echo_area_buffer[0]; + /* If there is pending input, process any events which are not user-visible, such as X selection_request events. */ if (input_pending @@ -2727,6 +2729,12 @@ read_char (commandflag, nmaps, maps, prev_event, used_mouse_menu, end_time) swallow_events (0); /* If that cleared input_pending, try again to redisplay. */ } + + /* Prevent the redisplay we just did + from messing up echoing of the input after the prompt. */ + if (commandflag == 0 && echo_current) + echo_message_buffer = echo_area_buffer[0]; + } /* Message turns off echoing unless more keystrokes turn it on again. From bbb9fc1f654a0eb81a5dc186e16880a0354ddd71 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 25 Jan 2008 23:02:36 +0000 Subject: [PATCH 332/439] (redisplay_window): Run Qwindow_text_change_functions and jump back to beginning. Move some other initializations after that. (Qwindow_text_change_functions, (Vwindow_text_change_functions): New variables. (syms_of_xdisp): Init them. --- src/ChangeLog | 15 +++++++++++++++ src/xdisp.c | 33 +++++++++++++++++++++++++++------ 2 files changed, 42 insertions(+), 6 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 73d2e1d05c7..9a70449ac78 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,18 @@ +2008-01-25 Richard Stallman + + * xdisp.c (redisplay_window): Run Qwindow_text_change_functions and + jump back to beginning. Move some other initializations after that. + (Qwindow_text_change_functions, Vwindow_text_change_functions): + New variables. + (syms_of_xdisp): Init them. + + * keyboard.c (read_char): Restore echo_message_buffer after redisplay. + + * buffer.c (reset_buffer_local_variables): Implement + `permanent-local-hook'. + (Qpermanent_local_hook): New variable. + (syms_of_buffer): init and staticpro it. + 2008-01-25 Michael Albinus * dbusbind.c (xd_retrieve_arg): Pacify GCC on x86_64 GNU/Linux. diff --git a/src/xdisp.c b/src/xdisp.c index dfa18bfacb7..8c1b2b945fe 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -232,6 +232,7 @@ extern Lisp_Object Qhelp_echo; Lisp_Object Qoverriding_local_map, Qoverriding_terminal_local_map; Lisp_Object Qwindow_scroll_functions, Vwindow_scroll_functions; +Lisp_Object Qwindow_text_change_functions, Vwindow_text_change_functions; Lisp_Object Qredisplay_end_trigger_functions, Vredisplay_end_trigger_functions; Lisp_Object Qinhibit_point_motion_hooks; Lisp_Object QCeval, QCfile, QCdata, QCpropertize; @@ -12884,8 +12885,7 @@ redisplay_window (window, just_this_one_p) *w->desired_matrix->method = 0; #endif - specbind (Qinhibit_point_motion_hooks, Qt); - + restart: reconsider_clip_changes (w, buffer); /* Has the mode line to be updated? */ @@ -12936,10 +12936,6 @@ redisplay_window (window, just_this_one_p) /* Really select the buffer, for the sake of buffer-local variables. */ set_buffer_internal_1 (XBUFFER (w->buffer)); - SET_TEXT_POS (opoint, PT, PT_BYTE); - - beg_unchanged = BEG_UNCHANGED; - end_unchanged = END_UNCHANGED; current_matrix_up_to_date_p = (!NILP (w->window_end_valid) @@ -12948,6 +12944,23 @@ redisplay_window (window, just_this_one_p) && XFASTINT (w->last_modified) >= MODIFF && XFASTINT (w->last_overlay_modified) >= OVERLAY_MODIFF); + /* Run the window-bottom-change-functions + if it is possible that the text on the screen has changed + (either due to modification of the text, or any other reason). */ + if (!current_matrix_up_to_date_p + && !NILP (Vwindow_text_change_functions)) + { + safe_run_hooks (Qwindow_text_change_functions); + goto restart; + } + + beg_unchanged = BEG_UNCHANGED; + end_unchanged = END_UNCHANGED; + + SET_TEXT_POS (opoint, PT, PT_BYTE); + + specbind (Qinhibit_point_motion_hooks, Qt); + buffer_unchanged_p = (!NILP (w->window_end_valid) && !current_buffer->clip_changed @@ -23962,6 +23975,9 @@ syms_of_xdisp () staticpro (&Qwindow_scroll_functions); Qwindow_scroll_functions = intern ("window-scroll-functions"); + staticpro (&Qwindow_text_change_functions); + Qwindow_text_change_functions = intern ("window-text-change-functions"); + staticpro (&Qredisplay_end_trigger_functions); Qredisplay_end_trigger_functions = intern ("redisplay-end-trigger-functions"); @@ -24273,6 +24289,11 @@ and its new display-start position. Note that the value of `window-end' is not valid when these functions are called. */); Vwindow_scroll_functions = Qnil; + DEFVAR_LISP ("window-text-change-functions", + &Vwindow_text_change_functions, + doc: /* Functions to call in redisplay when text in the window might change. */); + Vwindow_text_change_functions = Qnil; + DEFVAR_LISP ("redisplay-end-trigger-functions", &Vredisplay_end_trigger_functions, doc: /* Functions called when redisplay of a window reaches the end trigger. Each function is called with two arguments, the window and the end trigger value. From fd9a7a58319598fc714e01e1366b2032f3944172 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 25 Jan 2008 23:04:06 +0000 Subject: [PATCH 333/439] (Running Hooks, Setting Hooks): New nodes. (Hooks): Add menu. (Setting Hooks): For `add-hook', document `permanent-local-hook'. --- doc/lispref/modes.texi | 30 +++++++++++++++++++++++------- 1 file changed, 23 insertions(+), 7 deletions(-) diff --git a/doc/lispref/modes.texi b/doc/lispref/modes.texi index 38e93b2033e..3004ca3a934 100644 --- a/doc/lispref/modes.texi +++ b/doc/lispref/modes.texi @@ -77,15 +77,16 @@ convention. @samp{-hooks}. If the variable's name ends in @samp{-function}, then its value is just a single function, not a list of functions. - Here's an example that uses a mode hook to turn on Auto Fill mode when -in Lisp Interaction mode: +@menu +* Running Hooks:: How to run a hook. +* Setting Hooks:: How to put functions on a hook, or remove them. +@end menu -@example -(add-hook 'lisp-interaction-mode-hook 'turn-on-auto-fill) -@end example +@node Running Hooks +@subsection Running Hooks - At the appropriate time, Emacs uses the @code{run-hooks} function to -run particular hooks. + At the appropriate times, Emacs uses the @code{run-hooks} function +and the other functions below to run particular hooks. @defun run-hooks &rest hookvars This function takes one or more normal hook variable names as @@ -125,6 +126,16 @@ the last hook function that was called. If all hook functions return @code{nil}, it returns @code{nil} as well. @end defun +@node Setting Hooks +@subsection Setting Hooks + + Here's an example that uses a mode hook to turn on Auto Fill mode when +in Lisp Interaction mode: + +@example +(add-hook 'lisp-interaction-mode-hook 'turn-on-auto-fill) +@end example + @defun add-hook hook function &optional append local This function is the handy way to add function @var{function} to hook variable @var{hook}. You can use it for abnormal hooks as well as for @@ -141,6 +152,11 @@ adds @code{my-text-hook-function} to the hook called @code{text-mode-hook}. If @var{function} is already present in @var{hook} (comparing using @code{equal}), then @code{add-hook} does not add it a second time. +If @var{function} has a non-@code{nil} property +@code{permanent-local-hook}, then @code{kill-all-local-variables} (or +changing major modes) won't delete it from the hook variable's local +value. + It is best to design your hook functions so that the order in which they are executed does not matter. Any dependence on the order is ``asking for trouble.'' However, the order is predictable: normally, From 2d105adf8b708a1ba7ebd56f74f18c751818e8dc Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Fri, 25 Jan 2008 23:04:39 +0000 Subject: [PATCH 334/439] Add `permanent-local-hook'. --- etc/NEWS | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/etc/NEWS b/etc/NEWS index 87822ef0d85..22e896db16c 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -440,6 +440,11 @@ search and match primitives from changing the match data. ** New function `match-substitute-replacement' returns the result of `replace-match' without actually using it in the buffer. +** If a local hook function has a non-nil `permanent-local-hook' +property, then `kill-all-local-variables' does not remove it from +the local value of the hook variable. This means it remains +even if you change major modes. + +++ ** A list of default values can be specified for the DEFAULT argument of functions `read-from-minibuffer', `read-string', `read-command', From 3ac7a21e51347773559ffd8d133845aaf73eb9fd Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sat, 26 Jan 2008 01:00:30 +0000 Subject: [PATCH 335/439] * xdisp.c (pos_visible_p): Handle the case where charpos falls on invisible text covered with an ellipsis. --- src/ChangeLog | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index 9a70449ac78..dddf5447469 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-01-26 Chong Yidong + + * xdisp.c (pos_visible_p): Handle the case where charpos falls on + invisible text covered with an ellipsis. + 2008-01-25 Richard Stallman * xdisp.c (redisplay_window): Run Qwindow_text_change_functions and From a5bafa401fc141892429a27ae18d46e8dde84446 Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sat, 26 Jan 2008 01:00:44 +0000 Subject: [PATCH 336/439] (pos_visible_p): Handle the case where charpos falls on invisible text covered with an ellipsis. --- src/xdisp.c | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) diff --git a/src/xdisp.c b/src/xdisp.c index 8c1b2b945fe..d8619cdfa9e 100644 --- a/src/xdisp.c +++ b/src/xdisp.c @@ -1321,6 +1321,28 @@ pos_visible_p (w, charpos, x, y, rtop, rbot, rowh, vpos) visible_p = 1; if (visible_p) { + Lisp_Object window, prop; + + XSETWINDOW (window, w); + prop = Fget_char_property (make_number (it.position.charpos), + Qinvisible, window); + + /* If charpos coincides with invisible text covered with an + ellipsis, use the first glyph of the ellipsis to compute + the pixel positions. */ + if (TEXT_PROP_MEANS_INVISIBLE (prop) == 2) + { + struct glyph_row *row = it.glyph_row; + struct glyph *glyph = row->glyphs[TEXT_AREA]; + struct glyph *end = glyph + row->used[TEXT_AREA]; + int x = row->x; + + for (; glyph < end && glyph->charpos < charpos; glyph++) + x += glyph->pixel_width; + + top_x = x; + } + *x = top_x; *y = max (top_y + max (0, it.max_ascent - it.ascent), window_top_y); *rtop = max (0, window_top_y - top_y); From 003484a9d409a0fc14e05ce23efd611e9f8ca50e Mon Sep 17 00:00:00 2001 From: Chong Yidong Date: Sat, 26 Jan 2008 01:02:55 +0000 Subject: [PATCH 337/439] ** david.reitter@gmail.com, 27 dec: pos-visible-in-window-p at ellipsis Fixed in trunk. RMS agreed to delay backport till after 22.2 release. --- admin/FOR-RELEASE | 3 --- 1 file changed, 3 deletions(-) diff --git a/admin/FOR-RELEASE b/admin/FOR-RELEASE index feb509aece5..8541570cc6b 100644 --- a/admin/FOR-RELEASE +++ b/admin/FOR-RELEASE @@ -50,9 +50,6 @@ http://lists.gnu.org/archive/html/bug-gnu-emacs/2007-09/msg00055.html * BUGS -** david.reitter@gmail.com, 27 dec: pos-visible-in-window-p at ellipsis -http://lists.gnu.org/archive/html/emacs-devel/2008-01/msg00945.html - ** diff mode change for missing spaces in -u format. Installed 2008-01-08 fix does not work right. http://lists.gnu.org/archive/html/emacs-devel/2007-11/msg01990.html From 302d7d5465573c17de07f3addbdc6a63180c0b57 Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Sat, 26 Jan 2008 01:08:53 +0000 Subject: [PATCH 338/439] (logon_network_drive): New function. (stat): Use it. --- src/ChangeLog | 5 +++++ src/w32.c | 33 +++++++++++++++++++++++++++++++++ 2 files changed, 38 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index dddf5447469..469bc632182 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,8 @@ +2008-01-26 Jason Rumney + + * w32.c (logon_network_drive): New function. + (stat): Use it. + 2008-01-26 Chong Yidong * xdisp.c (pos_visible_p): Handle the case where charpos falls on diff --git a/src/w32.c b/src/w32.c index 5a8289789da..f1be902707e 100644 --- a/src/w32.c +++ b/src/w32.c @@ -1938,6 +1938,36 @@ unc_volume_file_attributes (const char *path) return attrs; } +/* Ensure a network connection is authenticated. */ +static void +logon_network_drive (const char *path) +{ + NETRESOURCE resource; + char share[MAX_PATH]; + int i, n_slashes; + + /* Only logon to networked drives. */ + if (!IS_DIRECTORY_SEP (path[0]) || !IS_DIRECTORY_SEP (path[1])) + return; + n_slashes = 2; + strncpy (share, path, MAX_PATH); + /* Truncate to just server and share name. */ + for (i = 2; i < MAX_PATH; i++) + { + if (IS_DIRECTORY_SEP (share[i]) && ++n_slashes > 3) + { + share[i] = '\0'; + break; + } + } + + resource.dwType = RESOURCETYPE_DISK; + resource.lpLocalName = NULL; + resource.lpRemoteName = share; + resource.lpProvider = NULL; + + WNetAddConnection2 (&resource, NULL, NULL, CONNECT_INTERACTIVE); +} /* Shadow some MSVC runtime functions to map requests for long filenames to reasonable short names if necessary. This was originally added to @@ -2495,6 +2525,9 @@ stat (const char * path, struct stat * buf) } else { + if (IS_DIRECTORY_SEP (name[0]) && IS_DIRECTORY_SEP (name[1])) + logon_network_drive (name); + fh = FindFirstFile (name, &wfd); if (fh == INVALID_HANDLE_VALUE) { From 9f3b76d5b8f707aab54c25431b6d81866e4039cc Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Sat, 26 Jan 2008 01:47:21 +0000 Subject: [PATCH 339/439] Handle *long* lines tail visualization. --- lisp/ChangeLog | 10 +++ lisp/blank-mode.el | 179 ++++++++++++++++++++++++++------------------- 2 files changed, 115 insertions(+), 74 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 84c8c78e700..53c252cf725 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,13 @@ +2008-01-26 Vinicius Jose Latorre + + * blank-mode.el: New version 9.1. Handle "long" line tail + visualization. Doc fix. + (blank-line-length): Renamed to blank-line-column. + (blank-chars-value-list, blank-toggle-option-alist, blank-help-text): + Initialization fix. + (blank-replace-spaces-by-tabs): New fun. + (blank-cleanup, blank-cleanup-region, blank-color-on): Code fix. + 2008-01-25 Richard Stallman * subr.el (add-hook): Implement `permanent-local-hook' property. diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el index 315ac99ea7b..5f1270c49a7 100644 --- a/lisp/blank-mode.el +++ b/lisp/blank-mode.el @@ -6,7 +6,7 @@ ;; Author: Vinicius Jose Latorre ;; Maintainer: Vinicius Jose Latorre ;; Keywords: data, wp -;; Version: 9.0 +;; Version: 9.1 ;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre ;; This file is part of GNU Emacs. @@ -264,7 +264,7 @@ ;; `blank-space-after-tab-regexp' Specify regexp for 8 or more ;; SPACEs after TAB. ;; -;; `blank-line-length' Specify length beyond which the line +;; `blank-line-column' Specify column beyond which the line ;; is highlighted. ;; ;; `blank-display-mappings' Specify an alist of mappings for @@ -277,6 +277,9 @@ ;; Acknowledgements ;; ---------------- ;; +;; Thanks to nschum (EmacsWiki) for the idea about highlight "long" +;; lines tail. See EightyColumnRule (EmacsWiki). +;; ;; Thanks to Juri Linkov for suggesting: ;; * `define-minor-mode'. ;; * `global-blank-*' name for global commands. @@ -293,7 +296,7 @@ ;; indicating defface byte-compilation warnings. ;; ;; Thanks to TimOCallaghan (EmacsWiki) for the idea about highlight -;; "long" lines. See EightyColumnRule (EmacsWiki). +;; "long" lines. See EightyColumnRule (EmacsWiki). ;; ;; Thanks to Yanghui Bian for indicating a new ;; newline character mapping. @@ -366,8 +369,18 @@ It's a list which element value can be: spaces SPACEs and HARD SPACEs are visualized. - lines lines whose length is greater than - `blank-line-length' are highlighted. + lines lines whose have columns beyond + `blank-line-column' are highlighted. + Whole line is highlighted. + It has precedence over + `lines-tail' (see below). + + lines-tail lines whose have columns beyond + `blank-line-column' are highlighted. + But only the part of line which goes + beyond `blank-line-column' column. + It has effect only if `lines' (see above) + is not present in `blank-chars'. space-before-tab SPACEs before TAB are visualized. @@ -501,7 +514,7 @@ Used when `blank-style' has `color' as an element." (defcustom blank-line 'blank-line "*Symbol face used to visualize \"long\" lines. -See `blank-line-length'. +See `blank-line-column'. Used when `blank-style' has `color' as an element." :type 'face @@ -513,7 +526,7 @@ Used when `blank-style' has `color' as an element." (t (:background "gray20" :foreground "violet"))) "Face used to visualize \"long\" lines. -See `blank-line-length'." +See `blank-line-column'." :group 'blank) @@ -754,11 +767,11 @@ Used when `blank-style' has `color' as an element, and :group 'blank) -(defcustom blank-line-length 80 - "*Specify length beyond which the line is highlighted. +(defcustom blank-line-column 80 + "*Specify column beyond which the line is highlighted. Used when `blank-style' has `color' as an element, and -`blank-chars' has `lines' as an element." +`blank-chars' has `lines' or `lines-tail' as an element." :type '(integer :tag "Line Length") :group 'blank) @@ -944,6 +957,7 @@ Only useful with a windowing system." trailing space-before-tab lines + lines-tail newline indentation empty @@ -965,6 +979,7 @@ Only useful with a windowing system." (?r . trailing) (?b . space-before-tab) (?l . lines) + (?L . lines-tail) (?n . newline) (?i . indentation) (?e . empty) @@ -1015,6 +1030,7 @@ Interactively, it reads one of the following chars: r toggle trailing blanks visualization b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization + L toggle \"long lines\" tail visualization n toggle NEWLINE visualization i toggle indentation SPACEs visualization e toggle empty line at bob and/or eob visualization @@ -1033,6 +1049,7 @@ The valid symbols are: trailing toggle trailing blanks visualization space-before-tab toggle SPACEs before TAB visualization lines toggle \"long lines\" visualization + lines-tail toggle \"long lines\" tail visualization newline toggle NEWLINE visualization indentation toggle indentation SPACEs visualization empty toggle empty line at bob and/or eob visualization @@ -1078,6 +1095,7 @@ Interactively, it reads one of the following chars: r toggle trailing blanks visualization b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization + L toggle \"long lines\" tail visualization n toggle NEWLINE visualization i toggle indentation SPACEs visualization e toggle empty line at bob and/or eob visualization @@ -1096,6 +1114,7 @@ The valid symbols are: trailing toggle trailing blanks visualization space-before-tab toggle SPACEs before TAB visualization lines toggle \"long lines\" visualization + lines-tail toggle \"long lines\" tail visualization newline toggle NEWLINE visualization indentation toggle indentation SPACEs visualization empty toggle empty line at bob and/or eob visualization @@ -1170,21 +1189,22 @@ The problems, which are cleaned up, are: (blank-cleanup-region (region-beginning) (region-end)) ;; whole buffer (save-excursion - ;; problem 1: empty lines at bob - ;; problem 2: empty lines at eob - ;; action: remove all empty lines at bob and/or eob - (when (memq 'empty blank-chars) - (let (overwrite-mode) ; enforce no overwrite - (goto-char (point-min)) - (when (re-search-forward blank-empty-at-bob-regexp nil t) - (delete-region (match-beginning 1) (match-end 1))) - (when (re-search-forward blank-empty-at-eob-regexp nil t) - (delete-region (match-beginning 1) (match-end 1))))) - ;; problem 3: 8 or more SPACEs at bol - ;; problem 4: SPACEs before TAB - ;; problem 5: SPACEs or TABs at eol - ;; problem 6: 8 or more SPACEs after TAB - (blank-cleanup-region (point-min) (point-max))))) + (save-match-data + ;; problem 1: empty lines at bob + ;; problem 2: empty lines at eob + ;; action: remove all empty lines at bob and/or eob + (when (memq 'empty blank-chars) + (let (overwrite-mode) ; enforce no overwrite + (goto-char (point-min)) + (when (re-search-forward blank-empty-at-bob-regexp nil t) + (delete-region (match-beginning 1) (match-end 1))) + (when (re-search-forward blank-empty-at-eob-regexp nil t) + (delete-region (match-beginning 1) (match-end 1))))))) + ;; problem 3: 8 or more SPACEs at bol + ;; problem 4: SPACEs before TAB + ;; problem 5: SPACEs or TABs at eol + ;; problem 6: 8 or more SPACEs after TAB + (blank-cleanup-region (point-min) (point-max)))) ;;;###autoload @@ -1216,54 +1236,52 @@ The problems, which are cleaned up, are: overwrite-mode ; enforce no overwrite tmp) (save-excursion - ;; problem 1: 8 or more SPACEs at bol - ;; action: replace 8 or more SPACEs at bol by TABs - (when (memq 'indentation blank-chars) - (goto-char rstart) - (while (re-search-forward blank-indentation-regexp rend t) - (setq tmp (current-indentation)) - (delete-horizontal-space) - (unless (eolp) - (indent-to tmp)))) - ;; problem 3: SPACEs or TABs at eol - ;; action: remove all SPACEs or TABs at eol - (when (memq 'trailing blank-chars) - (let ((regexp - (concat "\\(\\(" blank-trailing-regexp "\\)+\\)$"))) + (save-match-data + ;; problem 1: 8 or more SPACEs at bol + ;; action: replace 8 or more SPACEs at bol by TABs + (when (memq 'indentation blank-chars) (goto-char rstart) - (while (re-search-forward regexp rend t) - (delete-region (match-beginning 1) (match-end 1))))) - ;; problem 4: 8 or more SPACEs after TAB - ;; action: replace 8 or more SPACEs by TABs - (when (memq 'space-after-tab blank-chars) - (goto-char rstart) - (while (re-search-forward blank-space-after-tab-regexp rend t) - (goto-char (match-beginning 1)) - (let ((scol (current-column)) - (ecol (save-excursion - (goto-char (match-end 1)) - (current-column)))) - (delete-region (match-beginning 1) (match-end 1)) - (insert-char ?\t (/ (- ecol scol) 8))))) - ;; problem 2: SPACEs before TAB - ;; action: replace SPACEs before TAB by TABs - (when (memq 'space-before-tab blank-chars) - (goto-char rstart) - (while (re-search-forward blank-space-before-tab-regexp rend t) - (goto-char (match-beginning 1)) - (let* ((scol (current-column)) - (ecol (save-excursion - (goto-char (match-end 1)) - (current-column))) - (next-tab-col (* (/ (+ scol 8) 8) 8))) - (delete-region (match-beginning 1) (match-end 1)) - (when (<= next-tab-col ecol) - (insert-char ?\t - (/ (- (- ecol (% ecol 8)) ; prev end col - (- scol (% scol 8))) ; prev start col - 8))))))) + (while (re-search-forward blank-indentation-regexp rend t) + (setq tmp (current-indentation)) + (delete-horizontal-space) + (unless (eolp) + (indent-to tmp)))) + ;; problem 3: SPACEs or TABs at eol + ;; action: remove all SPACEs or TABs at eol + (when (memq 'trailing blank-chars) + (let ((regexp (concat "\\(\\(" blank-trailing-regexp + "\\)+\\)$"))) + (goto-char rstart) + (while (re-search-forward regexp rend t) + (delete-region (match-beginning 1) (match-end 1))))) + ;; problem 4: 8 or more SPACEs after TAB + ;; action: replace 8 or more SPACEs by TABs + (when (memq 'space-after-tab blank-chars) + (blank-replace-spaces-by-tabs + rstart rend blank-space-after-tab-regexp)) + ;; problem 2: SPACEs before TAB + ;; action: replace SPACEs before TAB by TABs + (when (memq 'space-before-tab blank-chars) + (blank-replace-spaces-by-tabs + rstart rend blank-space-before-tab-regexp)))) (set-marker rend nil))) ; point marker to nowhere + +(defun blank-replace-spaces-by-tabs (rstart rend regexp) + "Replace all SPACEs by TABs matched by REGEXP between RSTART and REND." + (goto-char rstart) + (while (re-search-forward regexp rend t) + (goto-char (match-beginning 1)) + (let* ((scol (current-column)) + (ecol (save-excursion + (goto-char (match-end 1)) + (current-column)))) + (delete-region (match-beginning 1) (match-end 1)) + (insert-char ?\t + (/ (- (- ecol (% ecol 8)) ; prev end col + (- scol (% scol 8))) ; prev start col + 8))))) + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;; Internal functions @@ -1291,6 +1309,7 @@ The problems, which are cleaned up, are: [] r - toggle trailing blanks visualization [] b - toggle SPACEs before TAB visualization [] l - toggle \"long lines\" visualization + [] L - toggle \"long lines\" tail visualization [] n - toggle NEWLINE visualization [] i - toggle indentation SPACEs visualization [] e - toggle empty line at bob and/or eob visualization @@ -1365,6 +1384,7 @@ It reads one of the following chars: r toggle trailing blanks visualization b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization + L toggle \"long lines\" tail visualization n toggle NEWLINE visualization i toggle indentation SPACEs visualization e toggle empty line at bob and/or eob visualization @@ -1504,14 +1524,25 @@ options are valid." (list (concat "\\(\\(" blank-trailing-regexp "\\)+\\)$") 1 blank-trailing t)) t)) - (when (memq 'lines blank-active-chars) + (when (or (memq 'lines blank-active-chars) + (memq 'lines-tail blank-active-chars)) (font-lock-add-keywords nil (list ;; Show "long" lines - (list (concat "^\\(.\\{" (int-to-string blank-line-length) - ",\\}\\)$") - 1 blank-line t)) + (list + (format + "^\\([^\t\n]\\{%s\\}\\|[^\t\n]\\{0,%s\\}\t\\)\\{%d\\}%s\\(.+\\)$" + tab-width (1- tab-width) + (/ blank-line-column tab-width) + (let ((rem (% blank-line-column tab-width))) + (if (zerop rem) + "" + (format ".\\{%d\\}" rem)))) + (if (memq 'lines blank-active-chars) + 0 ; whole line + 2) ; line tail + blank-line t)) t)) (when (memq 'space-before-tab blank-active-chars) (font-lock-add-keywords From 908c0b1e4f1c0257e10cad71948ca0053e442335 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Sat, 26 Jan 2008 01:49:18 +0000 Subject: [PATCH 340/439] Handle *long* lines tail visualization. --- lisp/ChangeLog | 10 +++ lisp/blank-mode.el | 179 ++++++++++++++++++++++++++------------------- 2 files changed, 115 insertions(+), 74 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2d3543022d0..b4dd992d03b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,13 @@ +2008-01-26 Vinicius Jose Latorre + + * blank-mode.el: New version 9.1. Handle "long" line tail + visualization. Doc fix. + (blank-line-length): Renamed to blank-line-column. + (blank-chars-value-list, blank-toggle-option-alist, blank-help-text): + Initialization fix. + (blank-replace-spaces-by-tabs): New fun. + (blank-cleanup, blank-cleanup-region, blank-color-on): Code fix. + 2008-01-25 Juanma Barranquero * allout.el (allout-unload-function): New function. diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el index 315ac99ea7b..5f1270c49a7 100644 --- a/lisp/blank-mode.el +++ b/lisp/blank-mode.el @@ -6,7 +6,7 @@ ;; Author: Vinicius Jose Latorre ;; Maintainer: Vinicius Jose Latorre ;; Keywords: data, wp -;; Version: 9.0 +;; Version: 9.1 ;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre ;; This file is part of GNU Emacs. @@ -264,7 +264,7 @@ ;; `blank-space-after-tab-regexp' Specify regexp for 8 or more ;; SPACEs after TAB. ;; -;; `blank-line-length' Specify length beyond which the line +;; `blank-line-column' Specify column beyond which the line ;; is highlighted. ;; ;; `blank-display-mappings' Specify an alist of mappings for @@ -277,6 +277,9 @@ ;; Acknowledgements ;; ---------------- ;; +;; Thanks to nschum (EmacsWiki) for the idea about highlight "long" +;; lines tail. See EightyColumnRule (EmacsWiki). +;; ;; Thanks to Juri Linkov for suggesting: ;; * `define-minor-mode'. ;; * `global-blank-*' name for global commands. @@ -293,7 +296,7 @@ ;; indicating defface byte-compilation warnings. ;; ;; Thanks to TimOCallaghan (EmacsWiki) for the idea about highlight -;; "long" lines. See EightyColumnRule (EmacsWiki). +;; "long" lines. See EightyColumnRule (EmacsWiki). ;; ;; Thanks to Yanghui Bian for indicating a new ;; newline character mapping. @@ -366,8 +369,18 @@ It's a list which element value can be: spaces SPACEs and HARD SPACEs are visualized. - lines lines whose length is greater than - `blank-line-length' are highlighted. + lines lines whose have columns beyond + `blank-line-column' are highlighted. + Whole line is highlighted. + It has precedence over + `lines-tail' (see below). + + lines-tail lines whose have columns beyond + `blank-line-column' are highlighted. + But only the part of line which goes + beyond `blank-line-column' column. + It has effect only if `lines' (see above) + is not present in `blank-chars'. space-before-tab SPACEs before TAB are visualized. @@ -501,7 +514,7 @@ Used when `blank-style' has `color' as an element." (defcustom blank-line 'blank-line "*Symbol face used to visualize \"long\" lines. -See `blank-line-length'. +See `blank-line-column'. Used when `blank-style' has `color' as an element." :type 'face @@ -513,7 +526,7 @@ Used when `blank-style' has `color' as an element." (t (:background "gray20" :foreground "violet"))) "Face used to visualize \"long\" lines. -See `blank-line-length'." +See `blank-line-column'." :group 'blank) @@ -754,11 +767,11 @@ Used when `blank-style' has `color' as an element, and :group 'blank) -(defcustom blank-line-length 80 - "*Specify length beyond which the line is highlighted. +(defcustom blank-line-column 80 + "*Specify column beyond which the line is highlighted. Used when `blank-style' has `color' as an element, and -`blank-chars' has `lines' as an element." +`blank-chars' has `lines' or `lines-tail' as an element." :type '(integer :tag "Line Length") :group 'blank) @@ -944,6 +957,7 @@ Only useful with a windowing system." trailing space-before-tab lines + lines-tail newline indentation empty @@ -965,6 +979,7 @@ Only useful with a windowing system." (?r . trailing) (?b . space-before-tab) (?l . lines) + (?L . lines-tail) (?n . newline) (?i . indentation) (?e . empty) @@ -1015,6 +1030,7 @@ Interactively, it reads one of the following chars: r toggle trailing blanks visualization b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization + L toggle \"long lines\" tail visualization n toggle NEWLINE visualization i toggle indentation SPACEs visualization e toggle empty line at bob and/or eob visualization @@ -1033,6 +1049,7 @@ The valid symbols are: trailing toggle trailing blanks visualization space-before-tab toggle SPACEs before TAB visualization lines toggle \"long lines\" visualization + lines-tail toggle \"long lines\" tail visualization newline toggle NEWLINE visualization indentation toggle indentation SPACEs visualization empty toggle empty line at bob and/or eob visualization @@ -1078,6 +1095,7 @@ Interactively, it reads one of the following chars: r toggle trailing blanks visualization b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization + L toggle \"long lines\" tail visualization n toggle NEWLINE visualization i toggle indentation SPACEs visualization e toggle empty line at bob and/or eob visualization @@ -1096,6 +1114,7 @@ The valid symbols are: trailing toggle trailing blanks visualization space-before-tab toggle SPACEs before TAB visualization lines toggle \"long lines\" visualization + lines-tail toggle \"long lines\" tail visualization newline toggle NEWLINE visualization indentation toggle indentation SPACEs visualization empty toggle empty line at bob and/or eob visualization @@ -1170,21 +1189,22 @@ The problems, which are cleaned up, are: (blank-cleanup-region (region-beginning) (region-end)) ;; whole buffer (save-excursion - ;; problem 1: empty lines at bob - ;; problem 2: empty lines at eob - ;; action: remove all empty lines at bob and/or eob - (when (memq 'empty blank-chars) - (let (overwrite-mode) ; enforce no overwrite - (goto-char (point-min)) - (when (re-search-forward blank-empty-at-bob-regexp nil t) - (delete-region (match-beginning 1) (match-end 1))) - (when (re-search-forward blank-empty-at-eob-regexp nil t) - (delete-region (match-beginning 1) (match-end 1))))) - ;; problem 3: 8 or more SPACEs at bol - ;; problem 4: SPACEs before TAB - ;; problem 5: SPACEs or TABs at eol - ;; problem 6: 8 or more SPACEs after TAB - (blank-cleanup-region (point-min) (point-max))))) + (save-match-data + ;; problem 1: empty lines at bob + ;; problem 2: empty lines at eob + ;; action: remove all empty lines at bob and/or eob + (when (memq 'empty blank-chars) + (let (overwrite-mode) ; enforce no overwrite + (goto-char (point-min)) + (when (re-search-forward blank-empty-at-bob-regexp nil t) + (delete-region (match-beginning 1) (match-end 1))) + (when (re-search-forward blank-empty-at-eob-regexp nil t) + (delete-region (match-beginning 1) (match-end 1))))))) + ;; problem 3: 8 or more SPACEs at bol + ;; problem 4: SPACEs before TAB + ;; problem 5: SPACEs or TABs at eol + ;; problem 6: 8 or more SPACEs after TAB + (blank-cleanup-region (point-min) (point-max)))) ;;;###autoload @@ -1216,54 +1236,52 @@ The problems, which are cleaned up, are: overwrite-mode ; enforce no overwrite tmp) (save-excursion - ;; problem 1: 8 or more SPACEs at bol - ;; action: replace 8 or more SPACEs at bol by TABs - (when (memq 'indentation blank-chars) - (goto-char rstart) - (while (re-search-forward blank-indentation-regexp rend t) - (setq tmp (current-indentation)) - (delete-horizontal-space) - (unless (eolp) - (indent-to tmp)))) - ;; problem 3: SPACEs or TABs at eol - ;; action: remove all SPACEs or TABs at eol - (when (memq 'trailing blank-chars) - (let ((regexp - (concat "\\(\\(" blank-trailing-regexp "\\)+\\)$"))) + (save-match-data + ;; problem 1: 8 or more SPACEs at bol + ;; action: replace 8 or more SPACEs at bol by TABs + (when (memq 'indentation blank-chars) (goto-char rstart) - (while (re-search-forward regexp rend t) - (delete-region (match-beginning 1) (match-end 1))))) - ;; problem 4: 8 or more SPACEs after TAB - ;; action: replace 8 or more SPACEs by TABs - (when (memq 'space-after-tab blank-chars) - (goto-char rstart) - (while (re-search-forward blank-space-after-tab-regexp rend t) - (goto-char (match-beginning 1)) - (let ((scol (current-column)) - (ecol (save-excursion - (goto-char (match-end 1)) - (current-column)))) - (delete-region (match-beginning 1) (match-end 1)) - (insert-char ?\t (/ (- ecol scol) 8))))) - ;; problem 2: SPACEs before TAB - ;; action: replace SPACEs before TAB by TABs - (when (memq 'space-before-tab blank-chars) - (goto-char rstart) - (while (re-search-forward blank-space-before-tab-regexp rend t) - (goto-char (match-beginning 1)) - (let* ((scol (current-column)) - (ecol (save-excursion - (goto-char (match-end 1)) - (current-column))) - (next-tab-col (* (/ (+ scol 8) 8) 8))) - (delete-region (match-beginning 1) (match-end 1)) - (when (<= next-tab-col ecol) - (insert-char ?\t - (/ (- (- ecol (% ecol 8)) ; prev end col - (- scol (% scol 8))) ; prev start col - 8))))))) + (while (re-search-forward blank-indentation-regexp rend t) + (setq tmp (current-indentation)) + (delete-horizontal-space) + (unless (eolp) + (indent-to tmp)))) + ;; problem 3: SPACEs or TABs at eol + ;; action: remove all SPACEs or TABs at eol + (when (memq 'trailing blank-chars) + (let ((regexp (concat "\\(\\(" blank-trailing-regexp + "\\)+\\)$"))) + (goto-char rstart) + (while (re-search-forward regexp rend t) + (delete-region (match-beginning 1) (match-end 1))))) + ;; problem 4: 8 or more SPACEs after TAB + ;; action: replace 8 or more SPACEs by TABs + (when (memq 'space-after-tab blank-chars) + (blank-replace-spaces-by-tabs + rstart rend blank-space-after-tab-regexp)) + ;; problem 2: SPACEs before TAB + ;; action: replace SPACEs before TAB by TABs + (when (memq 'space-before-tab blank-chars) + (blank-replace-spaces-by-tabs + rstart rend blank-space-before-tab-regexp)))) (set-marker rend nil))) ; point marker to nowhere + +(defun blank-replace-spaces-by-tabs (rstart rend regexp) + "Replace all SPACEs by TABs matched by REGEXP between RSTART and REND." + (goto-char rstart) + (while (re-search-forward regexp rend t) + (goto-char (match-beginning 1)) + (let* ((scol (current-column)) + (ecol (save-excursion + (goto-char (match-end 1)) + (current-column)))) + (delete-region (match-beginning 1) (match-end 1)) + (insert-char ?\t + (/ (- (- ecol (% ecol 8)) ; prev end col + (- scol (% scol 8))) ; prev start col + 8))))) + ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; ;;;; Internal functions @@ -1291,6 +1309,7 @@ The problems, which are cleaned up, are: [] r - toggle trailing blanks visualization [] b - toggle SPACEs before TAB visualization [] l - toggle \"long lines\" visualization + [] L - toggle \"long lines\" tail visualization [] n - toggle NEWLINE visualization [] i - toggle indentation SPACEs visualization [] e - toggle empty line at bob and/or eob visualization @@ -1365,6 +1384,7 @@ It reads one of the following chars: r toggle trailing blanks visualization b toggle SPACEs before TAB visualization l toggle \"long lines\" visualization + L toggle \"long lines\" tail visualization n toggle NEWLINE visualization i toggle indentation SPACEs visualization e toggle empty line at bob and/or eob visualization @@ -1504,14 +1524,25 @@ options are valid." (list (concat "\\(\\(" blank-trailing-regexp "\\)+\\)$") 1 blank-trailing t)) t)) - (when (memq 'lines blank-active-chars) + (when (or (memq 'lines blank-active-chars) + (memq 'lines-tail blank-active-chars)) (font-lock-add-keywords nil (list ;; Show "long" lines - (list (concat "^\\(.\\{" (int-to-string blank-line-length) - ",\\}\\)$") - 1 blank-line t)) + (list + (format + "^\\([^\t\n]\\{%s\\}\\|[^\t\n]\\{0,%s\\}\t\\)\\{%d\\}%s\\(.+\\)$" + tab-width (1- tab-width) + (/ blank-line-column tab-width) + (let ((rem (% blank-line-column tab-width))) + (if (zerop rem) + "" + (format ".\\{%d\\}" rem)))) + (if (memq 'lines blank-active-chars) + 0 ; whole line + 2) ; line tail + blank-line t)) t)) (when (memq 'space-before-tab blank-active-chars) (font-lock-add-keywords From 304484e4a0ba830c56a040cf8e137120573215a5 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sat, 26 Jan 2008 04:28:04 +0000 Subject: [PATCH 341/439] (--without-gcc): By default, neither off nor on. --- ChangeLog | 4 ++++ configure.in | 5 ++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index a90e0ce9718..557f5c27d9e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-01-26 Glenn Morris + + * configure.in (--without-gcc): By default, neither off nor on. + 2008-01-25 Glenn Morris * configure.in: Correct usage of OPTION_DEFAULT_ON, diff --git a/configure.in b/configure.in index 950e86d8a04..a1db65b9f7a 100644 --- a/configure.in +++ b/configure.in @@ -70,7 +70,10 @@ AC_DEFUN([OPTION_DEFAULT_ON], [dnl m4_bpatsubst([with_$1], [[^0-9a-z]], [_])=yes])dnl ])dnl -OPTION_DEFAULT_ON([gcc],[don't use GCC to compile Emacs if GCC is found]) +dnl By default, neither off nor on. +AC_ARG_WITH([gcc], +[AS_HELP_STRING([--without-gcc], + [don't use GCC to compile Emacs even if GCC is found])]) OPTION_DEFAULT_ON([pop],[don't support POP mail retrieval with movemail]) if test "$with_pop" = yes; then From 985fd38180c9ac8bcddc737b70e857b763fd708c Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 26 Jan 2008 10:39:11 +0000 Subject: [PATCH 342/439] (Imenu): Remove "@cindex tags". --- man/programs.texi | 1 - 1 file changed, 1 deletion(-) diff --git a/man/programs.texi b/man/programs.texi index b1c196ba077..9c12199b00c 100644 --- a/man/programs.texi +++ b/man/programs.texi @@ -279,7 +279,6 @@ bindings for that purpose. @subsection Imenu @cindex index of buffer definitions @cindex buffer definitions index -@cindex tags The Imenu facility offers a way to find the major definitions in a file by name. It is also useful in text formatter major modes, From a56d9a08d2c0ded6389afd4b252f0f9d6cc4bb73 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 26 Jan 2008 10:40:15 +0000 Subject: [PATCH 343/439] (Tags): Add "@cindex tags". --- man/ChangeLog | 5 +++++ man/maintaining.texi | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/man/ChangeLog b/man/ChangeLog index 470ec73c4fe..31465ffbca3 100644 --- a/man/ChangeLog +++ b/man/ChangeLog @@ -1,3 +1,8 @@ +2008-01-26 Eli Zaretskii + + * programs.texi (Imenu): Move "@cindex tags" from here... + * maintaining.texi (Tags): ...to here. + 2008-01-23 Kevin Ryde * custom.texi (Mouse Buttons): Update elisp xref to "Click Events" on diff --git a/man/maintaining.texi b/man/maintaining.texi index 90e5131cfc0..385431f28ba 100644 --- a/man/maintaining.texi +++ b/man/maintaining.texi @@ -130,7 +130,8 @@ Of course, you should substitute the proper years and copyright holder. @node Tags @section Tags Tables -@cindex tags table +@cindex tags +@cindex tag tables A @dfn{tags table} is a description of how a multi-file program is broken up into files. It lists the names of the component files and the From c617afcea160aeeaa8b00d4181fe784069a888d4 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 26 Jan 2008 13:04:14 +0000 Subject: [PATCH 344/439] (g_b_init_get_sid_sub_authority, g_b_init_get_sid_sub_authority_count): New static variables. (GetSidSubAuthority_Proc, GetSidSubAuthorityCount_Proc): New typedefs. (get_sid_sub_authority, get_sid_sub_authority_count): New functions. (init_user_info): Use the above two new functions to retrieve uid and gid. Use 500/513, the Windows defaults, as Administrator's uid/gid. --- src/ChangeLog | 10 +++++ src/w32.c | 107 ++++++++++++++++++++++++++++++++++++++++---------- 2 files changed, 96 insertions(+), 21 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 469bc632182..9f620aae33e 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,13 @@ +2008-01-26 Eli Zaretskii + + * w32.c (g_b_init_get_sid_sub_authority) + (g_b_init_get_sid_sub_authority_count): New static variables. + (GetSidSubAuthority_Proc, GetSidSubAuthorityCount_Proc): New typedefs. + (get_sid_sub_authority, get_sid_sub_authority_count): New functions. + (init_user_info): Use the above two new functions to retrieve uid + and gid. Use 500/513, the Windows defaults, as Administrator's + uid/gid. + 2008-01-26 Jason Rumney * w32.c (logon_network_drive): New function. diff --git a/src/w32.c b/src/w32.c index f1be902707e..88c9c78316d 100644 --- a/src/w32.c +++ b/src/w32.c @@ -120,6 +120,8 @@ static BOOL g_b_init_open_process_token; static BOOL g_b_init_get_token_information; static BOOL g_b_init_lookup_account_sid; static BOOL g_b_init_get_sid_identifier_authority; +static BOOL g_b_init_get_sid_sub_authority; +static BOOL g_b_init_get_sid_sub_authority_count; /* BEGIN: Wrapper functions around OpenProcessToken @@ -161,6 +163,12 @@ typedef BOOL (WINAPI * LookupAccountSid_Proc) ( PSID_NAME_USE peUse); typedef PSID_IDENTIFIER_AUTHORITY (WINAPI * GetSidIdentifierAuthority_Proc) ( PSID pSid); +typedef PDWORD (WINAPI * GetSidSubAuthority_Proc) ( + PSID pSid, + DWORD n); +typedef PUCHAR (WINAPI * GetSidSubAuthorityCount_Proc) ( + PSID pSid); + /* ** A utility function ** */ static BOOL @@ -349,6 +357,55 @@ PSID_IDENTIFIER_AUTHORITY WINAPI get_sid_identifier_authority ( return (s_pfn_Get_Sid_Identifier_Authority (pSid)); } +PDWORD WINAPI get_sid_sub_authority ( + PSID pSid, + DWORD n) +{ + static GetSidSubAuthority_Proc s_pfn_Get_Sid_Sub_Authority = NULL; + HMODULE hm_advapi32 = NULL; + if (is_windows_9x () == TRUE) + { + return NULL; + } + if (g_b_init_get_sid_sub_authority == 0) + { + g_b_init_get_sid_sub_authority = 1; + hm_advapi32 = LoadLibrary ("Advapi32.dll"); + s_pfn_Get_Sid_Sub_Authority = + (GetSidSubAuthority_Proc) GetProcAddress ( + hm_advapi32, "GetSidSubAuthority"); + } + if (s_pfn_Get_Sid_Sub_Authority == NULL) + { + return NULL; + } + return (s_pfn_Get_Sid_Sub_Authority (pSid, n)); +} + +PUCHAR WINAPI get_sid_sub_authority_count ( + PSID pSid) +{ + static GetSidSubAuthorityCount_Proc s_pfn_Get_Sid_Sub_Authority_Count = NULL; + HMODULE hm_advapi32 = NULL; + if (is_windows_9x () == TRUE) + { + return NULL; + } + if (g_b_init_get_sid_sub_authority_count == 0) + { + g_b_init_get_sid_sub_authority_count = 1; + hm_advapi32 = LoadLibrary ("Advapi32.dll"); + s_pfn_Get_Sid_Sub_Authority_Count = + (GetSidSubAuthorityCount_Proc) GetProcAddress ( + hm_advapi32, "GetSidSubAuthorityCount"); + } + if (s_pfn_Get_Sid_Sub_Authority_Count == NULL) + { + return NULL; + } + return (s_pfn_Get_Sid_Sub_Authority_Count (pSid)); +} + /* END: Wrapper functions around OpenProcessToken and other functions in advapi32.dll that are only @@ -547,39 +604,47 @@ init_user_info () domain, &dlength, &user_type)) { strcpy (the_passwd.pw_name, name); - /* Determine a reasonable uid value. */ + /* Determine a reasonable uid value. */ if (stricmp ("administrator", name) == 0) { - the_passwd.pw_uid = 0; - the_passwd.pw_gid = 0; + the_passwd.pw_uid = 500; /* well-known Administrator uid */ + the_passwd.pw_gid = 513; /* well-known None gid */ } else { - SID_IDENTIFIER_AUTHORITY * pSIA; + /* Use RID, the relative portion of the SID, that is the last + sub-authority value of the SID. */ + DWORD n_subauthorities = + *get_sid_sub_authority_count (*((PSID *) user_sid)); - pSIA = get_sid_identifier_authority (*((PSID *) user_sid)); - /* I believe the relative portion is the last 4 bytes (of 6) - with msb first. */ - the_passwd.pw_uid = ((pSIA->Value[2] << 24) + - (pSIA->Value[3] << 16) + - (pSIA->Value[4] << 8) + - (pSIA->Value[5] << 0)); - /* restrict to conventional uid range for normal users */ - the_passwd.pw_uid = the_passwd.pw_uid % 60001; + if (n_subauthorities < 1) + the_passwd.pw_uid = 0; /* the "World" RID */ + else + { + the_passwd.pw_uid = + *get_sid_sub_authority (*((PSID *) user_sid), + n_subauthorities - 1); + /* Restrict to conventional uid range for normal users. */ + the_passwd.pw_uid %= 60001; + } /* Get group id */ if (get_token_information (token, TokenPrimaryGroup, (PVOID) user_sid, sizeof (user_sid), &trash)) { - SID_IDENTIFIER_AUTHORITY * pSIA; + n_subauthorities = + *get_sid_sub_authority_count (*((PSID *) user_sid)); - pSIA = get_sid_identifier_authority (*((PSID *) user_sid)); - the_passwd.pw_gid = ((pSIA->Value[2] << 24) + - (pSIA->Value[3] << 16) + - (pSIA->Value[4] << 8) + - (pSIA->Value[5] << 0)); - /* I don't know if this is necessary, but for safety... */ - the_passwd.pw_gid = the_passwd.pw_gid % 60001; + if (n_subauthorities < 1) + the_passwd.pw_gid = 0; /* the "World" RID */ + else + { + the_passwd.pw_gid = + *get_sid_sub_authority (*((PSID *) user_sid), + n_subauthorities - 1); + /* I don't know if this is necessary, but for safety... */ + the_passwd.pw_gid %= 60001; + } } else the_passwd.pw_gid = the_passwd.pw_uid; From de4db6f103a1e99e675d7f02731be130e3b9d102 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 26 Jan 2008 13:15:27 +0000 Subject: [PATCH 345/439] (ls-lisp-insert-directory): If -n switch is used, invoke directory-files-and-attributes with last argument `integer' instead of `string'. (insert-directory): Add -n to the list of supported switches mentioned in the doc string. --- lisp/ChangeLog | 8 ++++++++ lisp/ls-lisp.el | 7 +++++-- 2 files changed, 13 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 53c252cf725..8a9c9f3f2c6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2008-01-26 Eli Zaretskii + + * ls-lisp.el (ls-lisp-insert-directory): If -n switch is used, + invoke directory-files-and-attributes with last argument `integer' + instead of `string'. + (insert-directory): Add -n to the list of supported switches + mentioned in the doc string. + 2008-01-26 Vinicius Jose Latorre * blank-mode.el: New version 9.1. Handle "long" line tail diff --git a/lisp/ls-lisp.el b/lisp/ls-lisp.el index 302329b9bba..2963168a899 100644 --- a/lisp/ls-lisp.el +++ b/lisp/ls-lisp.el @@ -209,7 +209,7 @@ The Lisp emulation does not run any external programs or shells. It supports ordinary shell wildcards if `ls-lisp-support-shell-wildcards' is non-nil; otherwise, it interprets wildcards as regular expressions to match file names. It does not support all `ls' switches -- those -that work are: A a c i r S s t u U X g G B C R and F partly." +that work are: A a c i r S s t u U X g G B C R n and F partly." (if ls-lisp-use-insert-directory-program (funcall original-insert-directory file switches wildcard full-directory-p) @@ -286,7 +286,10 @@ not contain `d', so that a full listing is expected." (let* ((dir (file-name-as-directory file)) (default-directory dir) ; so that file-attributes works (file-alist - (directory-files-and-attributes dir nil wildcard-regexp t 'string)) + (directory-files-and-attributes dir nil wildcard-regexp t + (if (memq ?n switches) + 'integer + 'string))) (now (current-time)) (sum 0) ;; do all bindings here for speed From 19eab3c797a7986fdccadbad488d69248538c6ed Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Sat, 26 Jan 2008 14:51:58 +0000 Subject: [PATCH 346/439] *** empty log message *** --- lisp/ChangeLog | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 8a9c9f3f2c6..0673f5cb357 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,13 @@ +2008-01-26 Michael Albinus + + * vc.el (vc-directory, vc-update-change-log): Remove check for + Tramp. Both functions work for it, though pretty slow + (`vc-directory'). Maybe the implementation can be optimized. + + * net/tramp.el (tramp-dissect-file-name): Raise an error when + Tramp 2.0 syntax is used. Suggested by Trent W. Buck + . + 2008-01-26 Eli Zaretskii * ls-lisp.el (ls-lisp-insert-directory): If -n switch is used, From ce0ee994e482b5808ee7a285fd72765a79746f4b Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 26 Jan 2008 14:52:01 +0000 Subject: [PATCH 347/439] (init_user_info): Fix commentary for RID usage. --- src/w32.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/w32.c b/src/w32.c index 88c9c78316d..1febcf2c4f4 100644 --- a/src/w32.c +++ b/src/w32.c @@ -612,8 +612,8 @@ init_user_info () } else { - /* Use RID, the relative portion of the SID, that is the last - sub-authority value of the SID. */ + /* Use the last sub-authority value of the RID, the relative + portion of the SID, as user/group ID. */ DWORD n_subauthorities = *get_sid_sub_authority_count (*((PSID *) user_sid)); From 65b014077a58eb191c45f5e73c1be775a491f7c0 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Sat, 26 Jan 2008 14:53:55 +0000 Subject: [PATCH 348/439] * vc.el (vc-directory, vc-update-change-log): Remove check for Tramp. Both functions work for it, though pretty slow (`vc-directory'). Maybe the implementation can be optimized. --- lisp/vc.el | 5 ----- 1 file changed, 5 deletions(-) diff --git a/lisp/vc.el b/lisp/vc.el index 35c371a6038..0069c124866 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -2571,8 +2571,6 @@ With prefix arg READ-SWITCHES, specify a value to override (interactive "DDired under VC (directory): \nP") (let ((vc-dired-switches (concat vc-dired-listing-switches (if vc-dired-recurse "R" "")))) - (if (eq (string-match tramp-file-name-regexp dir) 0) - (error "Sorry, vc-directory does not work over Tramp")) (if read-switches (setq vc-dired-switches (read-string "Dired listing switches: " @@ -3229,9 +3227,6 @@ log entries should be gathered." ;; it should find all relevant files relative to ;; the default-directory. nil))) - (dolist (file (or args (list default-directory))) - (if (eq (string-match tramp-file-name-regexp file) 0) - (error "Sorry, vc-update-change-log does not work over Tramp"))) (vc-call-backend (vc-responsible-backend default-directory) 'update-changelog args)) From 5d449a36ccff14cfa371f61cf57501e073e5d2f9 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Sat, 26 Jan 2008 14:54:55 +0000 Subject: [PATCH 349/439] * net/tramp.el (tramp-dissect-file-name): Raise an error when Tramp 2.0 syntax is used. Suggested by Trent W. Buck . --- lisp/net/tramp.el | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 4aa092ad704..9fba537f006 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -6663,6 +6663,10 @@ values." (user (match-string (nth 2 tramp-file-name-structure) name)) (host (match-string (nth 3 tramp-file-name-structure) name)) (localname (match-string (nth 4 tramp-file-name-structure) name))) + (when (member method '("multi" "multiu")) + (error + "`%s' method is no longer supported, see (info \"(tramp)Multi-hops\")" + method)) (if nodefault (vector method user host localname) (vector From 6811b9f4e614162634a783e74e0ab976bdfa9440 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 26 Jan 2008 15:04:33 +0000 Subject: [PATCH 350/439] (get_sid_sub_authority, get_sid_sub_authority_count): Fix return values on Windows 9x or when the corresponding advapi32.dll functions are not available. --- src/w32.c | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/src/w32.c b/src/w32.c index 1febcf2c4f4..adfac347549 100644 --- a/src/w32.c +++ b/src/w32.c @@ -362,10 +362,11 @@ PDWORD WINAPI get_sid_sub_authority ( DWORD n) { static GetSidSubAuthority_Proc s_pfn_Get_Sid_Sub_Authority = NULL; + static DWORD zero = 0U; HMODULE hm_advapi32 = NULL; if (is_windows_9x () == TRUE) { - return NULL; + return &zero; } if (g_b_init_get_sid_sub_authority == 0) { @@ -377,7 +378,7 @@ PDWORD WINAPI get_sid_sub_authority ( } if (s_pfn_Get_Sid_Sub_Authority == NULL) { - return NULL; + return &zero; } return (s_pfn_Get_Sid_Sub_Authority (pSid, n)); } @@ -386,10 +387,11 @@ PUCHAR WINAPI get_sid_sub_authority_count ( PSID pSid) { static GetSidSubAuthorityCount_Proc s_pfn_Get_Sid_Sub_Authority_Count = NULL; + static UCHAR zero = 0U; HMODULE hm_advapi32 = NULL; if (is_windows_9x () == TRUE) { - return NULL; + return &zero; } if (g_b_init_get_sid_sub_authority_count == 0) { @@ -401,7 +403,7 @@ PUCHAR WINAPI get_sid_sub_authority_count ( } if (s_pfn_Get_Sid_Sub_Authority_Count == NULL) { - return NULL; + return &zero; } return (s_pfn_Get_Sid_Sub_Authority_Count (pSid)); } From 248c21c5f20f60961cb18de1f90b995dd6ce8b18 Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 26 Jan 2008 15:25:12 +0000 Subject: [PATCH 351/439] (fstat): Use pw_uid and pw_gid from the_passwd structure for st_uid and st_gid of the file. --- src/ChangeLog | 2 ++ src/w32.c | 4 ++-- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 9f620aae33e..b3ab1ad9904 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -7,6 +7,8 @@ (init_user_info): Use the above two new functions to retrieve uid and gid. Use 500/513, the Windows defaults, as Administrator's uid/gid. + (fstat): Use pw_uid and pw_gid from the_passwd structure for + st_uid and st_gid of the file. 2008-01-26 Jason Rumney diff --git a/src/w32.c b/src/w32.c index adfac347549..dfec1dc8f8a 100644 --- a/src/w32.c +++ b/src/w32.c @@ -2768,8 +2768,8 @@ fstat (int desc, struct stat * buf) buf->st_ino = fake_inode; /* consider files to belong to current user */ - buf->st_uid = 0; - buf->st_gid = 0; + buf->st_uid = the_passwd.pw_uid; + buf->st_gid = the_passwd.pw_gid; buf->st_dev = info.dwVolumeSerialNumber; buf->st_rdev = info.dwVolumeSerialNumber; From 4ada4a87b460fad6237978b6f8dbb067e1a9908a Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Sat, 26 Jan 2008 17:00:52 +0000 Subject: [PATCH 352/439] (Fclrhash): Return TABLE. --- src/ChangeLog | 4 ++++ src/fns.c | 5 +++-- 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 1c4b08d24d7..eac48d83fbb 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-26 Thien-Thi Nguyen + + * fns.c (Fclrhash): Return TABLE. + 2008-01-21 YAMAMOTO Mitsuharu * macterm.c (x_scroll_bar_create): Initialize bar->redraw_needed_p. diff --git a/src/fns.c b/src/fns.c index 3f3cdccc36d..5df8be238df 100644 --- a/src/fns.c +++ b/src/fns.c @@ -5406,12 +5406,13 @@ DEFUN ("hash-table-p", Fhash_table_p, Shash_table_p, 1, 1, 0, DEFUN ("clrhash", Fclrhash, Sclrhash, 1, 1, 0, - doc: /* Clear hash table TABLE. */) + doc: /* Clear hash table TABLE and return it. */) (table) Lisp_Object table; { hash_clear (check_hash_table (table)); - return Qnil; + /* Be compatible with XEmacs. */ + return table; } From 9db3bfaeaf0fb657f5caffd1d5e1977e432f5555 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sat, 26 Jan 2008 17:07:59 +0000 Subject: [PATCH 353/439] (find-tag-default): Simplify using exclusively skip-syntax-backward/-forward. --- lisp/ChangeLog | 5 +++++ lisp/subr.el | 43 +++++++++++++++++++++++-------------------- 2 files changed, 28 insertions(+), 20 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 0673f5cb357..0b0a7dca4de 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-26 Martin Rudalics + + * subr.el (find-tag-default): Simplify using exclusively + skip-syntax-backward/-forward. + 2008-01-26 Michael Albinus * vc.el (vc-directory, vc-update-change-log): Remove check for diff --git a/lisp/subr.el b/lisp/subr.el index 5a7f88f76dd..f3579cc1fa6 100644 --- a/lisp/subr.el +++ b/lisp/subr.el @@ -2127,26 +2127,29 @@ Note that this should end with a directory separator.") (defun find-tag-default () "Determine default tag to search for, based on text at point. If there is no plausible default, return nil." - (save-excursion - (while (looking-at "\\sw\\|\\s_") - (forward-char 1)) - (if (or (re-search-backward "\\sw\\|\\s_" - (save-excursion (beginning-of-line) (point)) - t) - (re-search-forward "\\(\\sw\\|\\s_\\)+" - (save-excursion (end-of-line) (point)) - t)) - (progn - (goto-char (match-end 0)) - (condition-case nil - (buffer-substring-no-properties - (point) - (progn (forward-sexp -1) - (while (looking-at "\\s'") - (forward-char 1)) - (point))) - (error nil))) - nil))) + (let (from to bound) + (when (or (progn + ;; Look at text around `point'. + (save-excursion + (skip-syntax-backward "w_") (setq from (point))) + (save-excursion + (skip-syntax-forward "w_") (setq to (point))) + (> to from)) + ;; Look between `line-beginning-position' and `point'. + (save-excursion + (and (setq bound (line-beginning-position)) + (skip-syntax-backward "^w_" bound) + (> (setq to (point)) bound) + (skip-syntax-backward "w_") + (setq from (point)))) + ;; Look between `point' and `line-end-position'. + (save-excursion + (and (setq bound (line-end-position)) + (skip-syntax-forward "^w_" bound) + (< (setq from (point)) bound) + (skip-syntax-forward "w_") + (setq to (point))))) + (buffer-substring-no-properties from to)))) (defun play-sound (sound) "SOUND is a list of the form `(sound KEYWORD VALUE...)'. From add20191343608c74f9b389b7dcffe0c22ca7580 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sat, 26 Jan 2008 17:18:50 +0000 Subject: [PATCH 354/439] (wdired-get-filename): Change `(1+ beg)' to `beg' so that the filename end is found even when the filename is empty. Fixes error and spurious newlines when marking files for deletion. --- lisp/ChangeLog | 6 ++++++ lisp/wdired.el | 6 +++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b4dd992d03b..cbdb8f93256 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-26 Phil Sung (tiny change) + + * wdired.el (wdired-get-filename): Change `(1+ beg)' to `beg' so + that the filename end is found even when the filename is empty. + Fixes error and spurious newlines when marking files for deletion. + 2008-01-26 Vinicius Jose Latorre * blank-mode.el: New version 9.1. Handle "long" line tail diff --git a/lisp/wdired.el b/lisp/wdired.el index dff4c008d1b..013e14ec7f7 100644 --- a/lisp/wdired.el +++ b/lisp/wdired.el @@ -323,7 +323,11 @@ non-nil means return old filename." (unless (eq beg end) (if old (setq file (get-text-property beg 'old-name)) - (setq end (next-single-property-change (1+ beg) 'end-name)) + ;; In the following form changed `(1+ beg)' to `beg' so that + ;; the filename end is found even when the filename is empty. + ;; Fixes error and spurious newlines when marking files for + ;; deletion. + (setq end (next-single-property-change beg 'end-name)) (setq file (buffer-substring-no-properties (1+ beg) end))) (and file (setq file (wdired-normalize-filename file)))) (if (or no-dir old) From e31720013490deeb31fb429e5beb18ce63147a1f Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sat, 26 Jan 2008 17:23:56 +0000 Subject: [PATCH 355/439] (wdired-get-filename): Change `(1+ beg)' to `beg' so that the filename end is found even when the filename is empty. Fixes error and spurious newlines when marking files for deletion. --- lisp/ChangeLog | 6 ++++++ lisp/wdired.el | 6 +++++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 0b0a7dca4de..1e67505cb70 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-26 Phil Sung (tiny change) + + * wdired.el (wdired-get-filename): Change `(1+ beg)' to `beg' so + that the filename end is found even when the filename is empty. + Fixes error and spurious newlines when marking files for deletion. + 2008-01-26 Martin Rudalics * subr.el (find-tag-default): Simplify using exclusively diff --git a/lisp/wdired.el b/lisp/wdired.el index 287e2119c8d..36725db5db5 100644 --- a/lisp/wdired.el +++ b/lisp/wdired.el @@ -323,7 +323,11 @@ non-nil means return old filename." (unless (eq beg end) (if old (setq file (get-text-property beg 'old-name)) - (setq end (next-single-property-change (1+ beg) 'end-name)) + ;; In the following form changed `(1+ beg)' to `beg' so that + ;; the filename end is found even when the filename is empty. + ;; Fixes error and spurious newlines when marking files for + ;; deletion. + (setq end (next-single-property-change beg 'end-name)) (setq file (buffer-substring-no-properties (1+ beg) end))) (and file (setq file (wdired-normalize-filename file)))) (if (or no-dir old) From 405b8be3fc7ad1232d744142cc7fa7429621dfdb Mon Sep 17 00:00:00 2001 From: Eli Zaretskii Date: Sat, 26 Jan 2008 17:55:24 +0000 Subject: [PATCH 356/439] (tags-query-replace): Doc fix. --- lisp/ChangeLog | 4 ++++ lisp/progmodes/etags.el | 5 ++++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index cbdb8f93256..3399fcea80e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-26 Eli Zaretskii + + * progmodes/etags.el (tags-query-replace): Doc fix. + 2008-01-26 Phil Sung (tiny change) * wdired.el (wdired-get-filename): Change `(1+ beg)' to `beg' so diff --git a/lisp/progmodes/etags.el b/lisp/progmodes/etags.el index edff63acb3f..a22853fb404 100644 --- a/lisp/progmodes/etags.el +++ b/lisp/progmodes/etags.el @@ -1820,8 +1820,11 @@ See documentation of variable `tags-file-name'." Third arg DELIMITED (prefix arg) means replace only word-delimited matches. If you exit (\\[keyboard-quit], RET or q), you can resume the query replace with the command \\[tags-loop-continue]. +Fourth arg FILE-LIST-FORM non-nil means initialize the replacement loop. +Fifth and sixth arguments START and END are accepted, for compatibility +with `query-replace-regexp', and ignored. -See documentation of variable `tags-file-name'." +See also documentation of the variable `tags-file-name'." (interactive (query-replace-read-args "Tags query replace (regexp)" t t)) (setq tags-loop-scan `(let ,(unless (equal from (downcase from)) '((case-fold-search nil))) From 66991ff0a0e2b703dcd3779398ef22141bc56ecf Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Sat, 26 Jan 2008 19:46:17 +0000 Subject: [PATCH 357/439] (url-generic-parse-url): Fix docstring. --- lisp/url/url-parse.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/url/url-parse.el b/lisp/url/url-parse.el index f47ff9a37c3..7d09150d52c 100644 --- a/lisp/url/url-parse.el +++ b/lisp/url/url-parse.el @@ -77,9 +77,9 @@ ;;;###autoload (defun url-generic-parse-url (url) - "Return a vector of the parts of URL. -Format is: -\[TYPE USER PASSWORD HOST PORT FILE TARGET ATTRIBUTES FULL\]" + "Return an URL-struct of the parts of URL. +The CL-style struct contains the following fields: +TYPE USER PASSWORD HOST PORTSPEC FILENAME TARGET ATTRIBUTES FULLNESS." ;; See RFC 3986. (cond ((null url) From 30719e6c95c570674e2736ece52677e7161143a7 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sat, 26 Jan 2008 19:58:09 +0000 Subject: [PATCH 358/439] *** empty log message *** --- lisp/ChangeLog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 3399fcea80e..442f7669b28 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-26 Alan Mackenzie + + * progmodes/cc-defs.el (c-save-buffer-state): Bind + buffer-file-name and buffer-file-truename to nil, to prevent + primitives generating "buffer is read only" messages. + 2008-01-26 Eli Zaretskii * progmodes/etags.el (tags-query-replace): Doc fix. From c7ad89a66816230bb37fa6d16cc114e24ead28ea Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sat, 26 Jan 2008 19:59:10 +0000 Subject: [PATCH 359/439] (c-save-buffer-state): Bind buffer-file-name and buffer-file-truename to nil, to prevent primitives generating "buffer is read only" messages. --- lisp/progmodes/cc-defs.el | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lisp/progmodes/cc-defs.el b/lisp/progmodes/cc-defs.el index 9dbd5161a84..1632d756ffc 100644 --- a/lisp/progmodes/cc-defs.el +++ b/lisp/progmodes/cc-defs.el @@ -425,6 +425,8 @@ The return value is the value of the last form in BODY." (inhibit-read-only t) (inhibit-point-motion-hooks t) before-change-functions after-change-functions deactivate-mark + buffer-file-name buffer-file-truename ; Prevent primitives checking + ; for file modification ,@varlist) (unwind-protect (progn ,@body) From 832ffa7c8ef161baba18792b6e26065c19d5b15c Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Sat, 26 Jan 2008 20:04:49 +0000 Subject: [PATCH 360/439] (vc-exec-after): For mode-line-process highlighting, if feature `compile' is not available, fall back to font-lock-warning-face. --- lisp/ChangeLog | 7 ++++++- lisp/vc.el | 6 +++++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1e67505cb70..9d87c313f3a 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,4 +1,9 @@ -2008-01-26 Phil Sung (tiny change) +2008-01-26 Thien-Thi Nguyen + + * vc.el (vc-exec-after): For mode-line-process highlighting, if + `compile' is not available, fall back to font-lock-warning-face. + +2008-01-26 Phil Sung (tiny change) * wdired.el (wdired-get-filename): Change `(1+ beg)' to `beg' so that the filename end is found even when the filename is empty. diff --git a/lisp/vc.el b/lisp/vc.el index 0069c124866..ce212314491 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -1036,7 +1036,11 @@ Else, add CODE to the process' sentinel." ;; Deliberate overstatement, but power law respected. ;; (The message is ephemeral, so we make it loud.) --ttn (propertize " (incomplete/in progress)" - 'face 'compilation-warning + 'face (if (featurep 'compile) + ;; ttn's preferred loudness + 'compilation-warning + ;; suitably available fallback + font-lock-warning-face) 'help-echo "A VC command is in progress in this buffer")) (let ((previous (process-sentinel proc))) From b3360383c8de7fc50ee5107f8863c873cacc8f4a Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sat, 26 Jan 2008 20:20:20 +0000 Subject: [PATCH 361/439] Ulf Jasper (icalendar-version): Increase to "0.17". (icalendar-import-format): Doc fix. Allow function type. (icalendar--read-element): Doc fix. (icalendar--parse-summary-and-rest): Doc fix. Handle function type icalendar-import-format. Make regexps non-greedy. (icalendar--format-ical-event): Handle function type icalendar-import-format. (icalendar-import-format-sample): New function. --- lisp/ChangeLog | 11 ++ lisp/calendar/icalendar.el | 213 +++++++++++++++++++++---------------- 2 files changed, 133 insertions(+), 91 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9d87c313f3a..d7f34bd3f46 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,14 @@ +2008-01-20 Ulf Jasper + + * icalendar.el (icalendar-version): Increase to "0.17". + (icalendar-import-format): Doc fix. Allow function type. + (icalendar--read-element): Doc fix. + (icalendar--parse-summary-and-rest): Doc fix. Handle function + type icalendar-import-format. Make regexps non-greedy. + (icalendar--format-ical-event): Handle function type + icalendar-import-format. + (icalendar-import-format-sample): New function. + 2008-01-26 Thien-Thi Nguyen * vc.el (vc-exec-after): For mode-line-process highlighting, if diff --git a/lisp/calendar/icalendar.el b/lisp/calendar/icalendar.el index b05598b6a27..62cc247e8de 100644 --- a/lisp/calendar/icalendar.el +++ b/lisp/calendar/icalendar.el @@ -105,7 +105,7 @@ ;;; Code: -(defconst icalendar-version "0.16" +(defconst icalendar-version "0.17" "Version number of icalendar.el.") ;; ====================================================================== @@ -118,17 +118,25 @@ (defcustom icalendar-import-format "%s%d%l%o" - "Format string for importing events from iCalendar into Emacs diary. -This string defines how iCalendar events are inserted into diary -file. Meaning of the specifiers: + "Format for importing events from iCalendar into Emacs diary. +It defines how iCalendar events are inserted into diary file. +This may either be a string or a function. + +In case of a formatting STRING the following specifiers can be used: %c Class, see `icalendar-import-format-class' %d Description, see `icalendar-import-format-description' %l Location, see `icalendar-import-format-location' %o Organizer, see `icalendar-import-format-organizer' %s Summary, see `icalendar-import-format-summary' %t Status, see `icalendar-import-format-status' -%u URL, see `icalendar-import-format-url'" - :type 'string +%u URL, see `icalendar-import-format-url' + +A formatting FUNCTION will be called with a VEVENT as its only +argument. It must return a string. See +`icalendar-import-format-sample' for an example." + :type '(choice + (string :tag "String") + (function :tag "Function")) :group 'icalendar) (defcustom icalendar-import-format-summary @@ -247,7 +255,7 @@ Pass arguments REGEXP REP STRING FIXEDCASE LITERAL to INVALUE gives the current iCalendar element we are reading. INPARAMS gives the current parameters..... This function calls itself recursively for each nested calendar element -it finds" +it finds." (let (element children line name params param param-name param-value value (continue t)) @@ -923,89 +931,95 @@ entries. ENTRY-MAIN is the first line of the diary entry." (error "Could not parse entry"))) (defun icalendar--parse-summary-and-rest (summary-and-rest) - "Parse SUMMARY-AND-REST from a diary to fill iCalendar properties." + "Parse SUMMARY-AND-REST from a diary to fill iCalendar properties. +Returns an alist." (save-match-data - (let* ((s icalendar-import-format) - (p-cla (or (string-match "%c" icalendar-import-format) -1)) - (p-des (or (string-match "%d" icalendar-import-format) -1)) - (p-loc (or (string-match "%l" icalendar-import-format) -1)) - (p-org (or (string-match "%o" icalendar-import-format) -1)) - (p-sum (or (string-match "%s" icalendar-import-format) -1)) - (p-sta (or (string-match "%t" icalendar-import-format) -1)) - (p-url (or (string-match "%u" icalendar-import-format) -1)) - (p-list (sort (list p-cla p-des p-loc p-org p-sta p-sum p-url) '<)) - pos-cla pos-des pos-loc pos-org pos-sta pos-sum pos-url) - (dotimes (i (length p-list)) - (cond ((and (>= p-cla 0) (= (nth i p-list) p-cla)) - (setq pos-cla (+ 2 (* 2 i)))) - ((and (>= p-des 0) (= (nth i p-list) p-des)) - (setq pos-des (+ 2 (* 2 i)))) - ((and (>= p-loc 0) (= (nth i p-list) p-loc)) - (setq pos-loc (+ 2 (* 2 i)))) - ((and (>= p-org 0) (= (nth i p-list) p-org)) - (setq pos-org (+ 2 (* 2 i)))) - ((and (>= p-sta 0) (= (nth i p-list) p-sta)) - (setq pos-sta (+ 2 (* 2 i)))) - ((and (>= p-sum 0) (= (nth i p-list) p-sum)) - (setq pos-sum (+ 2 (* 2 i)))) - ((and (>= p-url 0) (= (nth i p-list) p-url)) - (setq pos-url (+ 2 (* 2 i)))))) - (mapc (lambda (ij) - (setq s (icalendar--rris (car ij) (cadr ij) s t t))) - (list - ;; summary must be first! because of %s - (list "%s" - (concat "\\(" icalendar-import-format-summary "\\)?")) - (list "%c" - (concat "\\(" icalendar-import-format-class "\\)?")) - (list "%d" - (concat "\\(" icalendar-import-format-description "\\)?")) - (list "%l" - (concat "\\(" icalendar-import-format-location "\\)?")) - (list "%o" - (concat "\\(" icalendar-import-format-organizer "\\)?")) - (list "%t" - (concat "\\(" icalendar-import-format-status "\\)?")) - (list "%u" - (concat "\\(" icalendar-import-format-url "\\)?")))) - (setq s (concat (icalendar--rris "%s" "\\(.*\\)" s nil t) " ")) - (if (string-match s summary-and-rest) - (let (cla des loc org sta sum url) - (if (and pos-sum (match-beginning pos-sum)) - (setq sum (substring summary-and-rest - (match-beginning pos-sum) - (match-end pos-sum)))) - (if (and pos-cla (match-beginning pos-cla)) - (setq cla (substring summary-and-rest - (match-beginning pos-cla) - (match-end pos-cla)))) - (if (and pos-des (match-beginning pos-des)) - (setq des (substring summary-and-rest - (match-beginning pos-des) - (match-end pos-des)))) - (if (and pos-loc (match-beginning pos-loc)) - (setq loc (substring summary-and-rest - (match-beginning pos-loc) - (match-end pos-loc)))) - (if (and pos-org (match-beginning pos-org)) - (setq org (substring summary-and-rest - (match-beginning pos-org) - (match-end pos-org)))) - (if (and pos-sta (match-beginning pos-sta)) - (setq sta (substring summary-and-rest - (match-beginning pos-sta) - (match-end pos-sta)))) - (if (and pos-url (match-beginning pos-url)) - (setq url (substring summary-and-rest - (match-beginning pos-url) - (match-end pos-url)))) - (list (if cla (cons 'cla cla) nil) - (if des (cons 'des des) nil) - (if loc (cons 'loc loc) nil) - (if org (cons 'org org) nil) - (if sta (cons 'sta sta) nil) - ;;(if sum (cons 'sum sum) nil) - (if url (cons 'url url) nil))))))) + (if (functionp icalendar-import-format) + ;; can't do anything + nil + ;; split summary-and-rest + (let* ((s icalendar-import-format) + (p-cla (or (string-match "%c" icalendar-import-format) -1)) + (p-des (or (string-match "%d" icalendar-import-format) -1)) + (p-loc (or (string-match "%l" icalendar-import-format) -1)) + (p-org (or (string-match "%o" icalendar-import-format) -1)) + (p-sum (or (string-match "%s" icalendar-import-format) -1)) + (p-sta (or (string-match "%t" icalendar-import-format) -1)) + (p-url (or (string-match "%u" icalendar-import-format) -1)) + (p-list (sort (list p-cla p-des p-loc p-org p-sta p-sum p-url) '<)) + pos-cla pos-des pos-loc pos-org pos-sta pos-sum pos-url) + (dotimes (i (length p-list)) + (cond ((and (>= p-cla 0) (= (nth i p-list) p-cla)) + (setq pos-cla (+ 2 (* 2 i)))) + ((and (>= p-des 0) (= (nth i p-list) p-des)) + (setq pos-des (+ 2 (* 2 i)))) + ((and (>= p-loc 0) (= (nth i p-list) p-loc)) + (setq pos-loc (+ 2 (* 2 i)))) + ((and (>= p-org 0) (= (nth i p-list) p-org)) + (setq pos-org (+ 2 (* 2 i)))) + ((and (>= p-sta 0) (= (nth i p-list) p-sta)) + (setq pos-sta (+ 2 (* 2 i)))) + ((and (>= p-sum 0) (= (nth i p-list) p-sum)) + (setq pos-sum (+ 2 (* 2 i)))) + ((and (>= p-url 0) (= (nth i p-list) p-url)) + (setq pos-url (+ 2 (* 2 i)))))) + (mapc (lambda (ij) + (setq s (icalendar--rris (car ij) (cadr ij) s t t))) + (list + ;; summary must be first! because of %s + (list "%s" + (concat "\\(" icalendar-import-format-summary "\\)??")) + (list "%c" + (concat "\\(" icalendar-import-format-class "\\)??")) + (list "%d" + (concat "\\(" icalendar-import-format-description "\\)??")) + (list "%l" + (concat "\\(" icalendar-import-format-location "\\)??")) + (list "%o" + (concat "\\(" icalendar-import-format-organizer "\\)??")) + (list "%t" + (concat "\\(" icalendar-import-format-status "\\)??")) + (list "%u" + (concat "\\(" icalendar-import-format-url "\\)??")))) + (setq s (concat "^" (icalendar--rris "%s" "\\(.*?\\)" s nil t) + " $")) + (if (string-match s summary-and-rest) + (let (cla des loc org sta sum url) + (if (and pos-sum (match-beginning pos-sum)) + (setq sum (substring summary-and-rest + (match-beginning pos-sum) + (match-end pos-sum)))) + (if (and pos-cla (match-beginning pos-cla)) + (setq cla (substring summary-and-rest + (match-beginning pos-cla) + (match-end pos-cla)))) + (if (and pos-des (match-beginning pos-des)) + (setq des (substring summary-and-rest + (match-beginning pos-des) + (match-end pos-des)))) + (if (and pos-loc (match-beginning pos-loc)) + (setq loc (substring summary-and-rest + (match-beginning pos-loc) + (match-end pos-loc)))) + (if (and pos-org (match-beginning pos-org)) + (setq org (substring summary-and-rest + (match-beginning pos-org) + (match-end pos-org)))) + (if (and pos-sta (match-beginning pos-sta)) + (setq sta (substring summary-and-rest + (match-beginning pos-sta) + (match-end pos-sta)))) + (if (and pos-url (match-beginning pos-url)) + (setq url (substring summary-and-rest + (match-beginning pos-url) + (match-end pos-url)))) + (list (if cla (cons 'cla cla) nil) + (if des (cons 'des des) nil) + (if loc (cons 'loc loc) nil) + (if org (cons 'org org) nil) + (if sta (cons 'sta sta) nil) + ;;(if sum (cons 'sum sum) nil) + (if url (cons 'url url) nil)))))))) ;; subroutines for icalendar-export-region (defun icalendar--convert-ordinary-to-ical (nonmarker entry-main) @@ -1600,7 +1614,9 @@ buffer `*icalendar-errors*'." (defun icalendar--format-ical-event (event) "Create a string representation of an iCalendar EVENT." - (let ((string icalendar-import-format) + (if (functionp icalendar-import-format) + (funcall icalendar-import-format event) + (let ((string icalendar-import-format) (conversion-list '(("%c" CLASS icalendar-import-format-class) ("%d" DESCRIPTION icalendar-import-format-description) @@ -1628,7 +1644,7 @@ buffer `*icalendar-errors*'." string t t)))) conversion-list) - string)) + string))) (defun icalendar--convert-ical-to-diary (ical-list diary-file &optional do-not-ask @@ -2044,6 +2060,21 @@ the entry." ;; return diary-file in case it has been changed interactively diary-file) +;; ====================================================================== +;; Examples +;; ====================================================================== +(defun icalendar-import-format-sample (event) + "Example function for formatting an icalendar EVENT." + (format (concat "SUMMARY=`%s' DESCRIPTION=`%s' LOCATION=`%s' ORGANIZER=`%s' " + "STATUS=`%s' URL=`%s' CLASS=`%s'") + (or (icalendar--get-event-property event 'SUMMARY) "") + (or (icalendar--get-event-property event 'DESCRIPTION) "") + (or (icalendar--get-event-property event 'LOCATION) "") + (or (icalendar--get-event-property event 'ORGANIZER) "") + (or (icalendar--get-event-property event 'STATUS) "") + (or (icalendar--get-event-property event 'URL) "") + (or (icalendar--get-event-property event 'CLASS) ""))) + (provide 'icalendar) ;; arch-tag: 74fdbe8e-0451-4e38-bb61-4416e822f4fc From b680ecd673fa57b6c53702fc80ae4120c45ee7f4 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sat, 26 Jan 2008 20:25:17 +0000 Subject: [PATCH 362/439] *** empty log message *** --- lisp/ChangeLog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index d7f34bd3f46..2bb50cd13a4 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-26 Alan Mackenzie + + * progmodes/cc-defs.el (c-save-buffer-state): Bind + buffer-file-name and buffer-file-truename to nil, to prevent + primitives generating "buffer is read only" messages. + 2008-01-20 Ulf Jasper * icalendar.el (icalendar-version): Increase to "0.17". From 44f714fda507effc32817d3e3f52260a3abeeb7a Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sat, 26 Jan 2008 20:28:46 +0000 Subject: [PATCH 363/439] (c-save-buffer-state): Bind buffer-file-name and buffer-file-truename to nil, to prevent primitives generating "buffer is read only" messages. --- lisp/progmodes/cc-defs.el | 2 ++ 1 file changed, 2 insertions(+) diff --git a/lisp/progmodes/cc-defs.el b/lisp/progmodes/cc-defs.el index 288aca687aa..9ef8db7548f 100644 --- a/lisp/progmodes/cc-defs.el +++ b/lisp/progmodes/cc-defs.el @@ -425,6 +425,8 @@ The return value is the value of the last form in BODY." (inhibit-read-only t) (inhibit-point-motion-hooks t) before-change-functions after-change-functions deactivate-mark + buffer-file-name buffer-file-truename ; Prevent primitives checking + ; for file modification ,@varlist) (unwind-protect (progn ,@body) From f7317f6c66b56413263ab8d1efd14d85e7bf6561 Mon Sep 17 00:00:00 2001 From: Glenn Morris Date: Sat, 26 Jan 2008 21:05:58 +0000 Subject: [PATCH 364/439] (--with-carbon): Tone down rhetoric in help text. --- ChangeLog | 1 + configure.in | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/ChangeLog b/ChangeLog index 557f5c27d9e..1f9820d386a 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,6 +1,7 @@ 2008-01-26 Glenn Morris * configure.in (--without-gcc): By default, neither off nor on. + (--with-carbon): Tone down rhetoric in help text. 2008-01-25 Glenn Morris diff --git a/configure.in b/configure.in index a1db65b9f7a..abf67196b74 100644 --- a/configure.in +++ b/configure.in @@ -139,7 +139,7 @@ OPTION_DEFAULT_OFF([gtk],[use GTK toolkit]) OPTION_DEFAULT_ON([toolkit-scroll-bars],[don't use Motif or Xaw3d scroll bars]) OPTION_DEFAULT_ON([xaw3d],[don't use Xaw3d]) OPTION_DEFAULT_ON([xim],[don't use X11 XIM]) -OPTION_DEFAULT_OFF([carbon],[use Carbon GUI on Mac OS X. **UNSUPPORTED!**]) +OPTION_DEFAULT_OFF([carbon],[use Carbon GUI on Mac OS X. This is unsupported!]) OPTION_DEFAULT_ON([gpm],[don't use -lgpm for mouse support on a GNU/Linux console]) OPTION_DEFAULT_OFF([dbus],[compile with D-Bus support]) From 0ea5797a183e5aaeb3be19ff8a95de0d28acd1c9 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Sat, 26 Jan 2008 21:27:38 +0000 Subject: [PATCH 365/439] (decode_options): Default to a NULL display, as Emacs-22. Allow the -d option under w32 again, for those rare cases where it actually does make sense. --- lib-src/ChangeLog | 6 ++++++ lib-src/emacsclient.c | 19 +++++++++++++++---- 2 files changed, 21 insertions(+), 4 deletions(-) diff --git a/lib-src/ChangeLog b/lib-src/ChangeLog index 7409d136527..9ebfbc29ecd 100644 --- a/lib-src/ChangeLog +++ b/lib-src/ChangeLog @@ -1,3 +1,9 @@ +2008-01-26 Stefan Monnier + + * emacsclient.c (decode_options): Default to a NULL display, as Emacs-22. + Allow the -d option under w32 again, for those rare cases where it + actually does make sense. + 2008-01-25 Juanma Barranquero * emacsclient.c (set_tcp_socket): Don't send "\n" after diff --git a/lib-src/emacsclient.c b/lib-src/emacsclient.c index b8ab19721ff..707be43b5f7 100644 --- a/lib-src/emacsclient.c +++ b/lib-src/emacsclient.c @@ -479,10 +479,14 @@ decode_options (argc, argv) char **argv; { alternate_editor = egetenv ("ALTERNATE_EDITOR"); -#ifndef WINDOWSNT + + /* We used to set `display' to $DISPLAY by default, but this changed the + default behavior and is sometimes inconvenient. So instead of forcing + users to say "--display ''" when they want to use Emacs's existing tty + or display connection, we force them to use "--display $DISPLAY" if + they want Emacs to connect to their current display. */ +#if 0 display = egetenv ("DISPLAY"); - if (display && strlen (display) == 0) - display = NULL; #endif while (1) @@ -519,7 +523,11 @@ decode_options (argc, argv) server_file = optarg; break; -#ifndef WINDOWSNT + /* We used to disallow this argument in w32, but it seems better + to allow it, for the occasional case where the user is + connecting with a w32 client to a server compiled with X11 + support. */ +#if 1 /* !defined WINDOWS */ case 'd': display = optarg; break; @@ -558,6 +566,9 @@ decode_options (argc, argv) } } + if (display && strlen (display) == 0) + display = NULL; + if (!tty && display) window_system = 1; #if !defined (WINDOWSNT) && !defined (HAVE_CARBON) From 15db4a13e5ae62e10bda61ed78dd5024353e6499 Mon Sep 17 00:00:00 2001 From: Michael Olson Date: Sat, 26 Jan 2008 21:49:41 +0000 Subject: [PATCH 366/439] Sync ERC 5.3 release. --- doc/misc/ChangeLog | 7 +++ doc/misc/erc.texi | 109 ++++++++++++++++++++++++++++++--------------- lisp/erc/ChangeLog | 17 +++++++ lisp/erc/erc.el | 2 +- 4 files changed, 98 insertions(+), 37 deletions(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index b8cb040f322..73d1459f8ff 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,10 @@ +2008-01-26 Michael Olson + + * erc.texi: Update version for ERC 5.3 release. + (Obtaining ERC): Update extras URLs for 5.3. + (Development): Write instructions for git, and remove those for Arch. + (History): Mention the switch to git. + 2008-01-24 Karl Berry * info.texi (Search Index), diff --git a/doc/misc/erc.texi b/doc/misc/erc.texi index ef4d105b712..95f9e4a20fe 100644 --- a/doc/misc/erc.texi +++ b/doc/misc/erc.texi @@ -12,7 +12,7 @@ @syncodeindex fn cp @copying -This manual is for ERC version 5.2. +This manual is for ERC version 5.3. Copyright @copyright{} 2005, 2006, 2007, 2008 Free Software Foundation, Inc. @@ -72,7 +72,7 @@ and modified without restriction. permission to redistribute ERC on certain terms; it also explains that there is no warranty. -* GNU Free Documentation License:: The license for this documentation. +* GNU Free Documentation License:: The license for this documentation. * Concept Index:: Search for terms. @detailmenu @@ -135,8 +135,8 @@ dependency issues. If desired, they may be found at the following locations, or from your local GNU mirror. @itemize @bullet -@item @uref{http://ftp.gnu.org/gnu/erc/erc-5.2-extras.tar.gz} -@item @uref{http://ftp.gnu.org/gnu/erc/erc-5.2-extras.zip} +@item @uref{http://ftp.gnu.org/gnu/erc/erc-5.3-extras.tar.gz} +@item @uref{http://ftp.gnu.org/gnu/erc/erc-5.3-extras.zip} @end itemize The rest of this chapter may be skipped if you are using the version of @@ -169,68 +169,101 @@ Alternatively, you can download the latest release from Choose the development version if you want to live on the bleeding edge of ERC development or try out new features before release. -@subheading GNU Arch +@cindex git version control system, using +The git version control system allows you to keep up-to-date with the +latest changes to the development version of ERC. It also allows you +to contribute changes (via commits, if you are have developer access to +the repository, or via patches, otherwise). If you would like to +contribute to ERC development, it is highly recommended that you use +git. -ERC is developed using GNU Arch. Downloading ERC with Arch and staying -up-to-date involves the following steps. +If you are new to git, you might find this tutorial helpful: +@uref{http://www.kernel.org/pub/software/scm/git/docs/tutorial.html}. + +Downloading ERC with git and staying up-to-date involves the following +steps. @enumerate -@cindex GNU Arch, installing -@item Install arch +@item Install git. @itemize @bullet -@item Debian: @kbd{apt-get install tla}. -@item Other distributions: see @uref{ftp://ftp.gnu.org/gnu/gnu-arch/}. +@item Debian and Ubuntu: @kbd{apt-get install git-core}. +@item Windows: @uref{http://git.or.cz/gitwiki/WindowsInstall}. +@item Other operating systems: download, compile, and install the source +from @uref{http://www.kernel.org/pub/software/scm/git/}, or find a git +package for your operating system. @end itemize -@cindex GNU Arch, downloading ERC -@item Register the archive. +@item Download the ERC development branch. + +If you have developer access to ERC, do: + @example -tla register-archive -f http://arch.sv.gnu.org/archives/erc/erc +git clone ssh://loginname@@git.sv.gnu.org/srv/git/erc.git @end example -@item Download the ERC source code. +otherwise, do: + @example -# Download ERC into the @file{erc} directory. -tla get erc@@sv.gnu.org/erc--main--0 erc +git clone git://git.sv.gnu.org/erc.git +@end example + +If you are behind a restrictive firewall, and do not have developer +access, then do the following instead: + +@example +git clone http://git.sv.gnu.org/r/erc.git @end example @item List upstream changes that are missing from your local copy. Do this whenever you want to see whether new changes have been committed -to ERC. +to ERC. If you wish, you may skip this step and proceed directly to +the ``update'' step. @example # Change to the source directory you are interested in. -cd erc/ +cd erc -# Display the summary of changes -tla missing --summary +# Fetch new changes from the repository, but don't apply them yet +git fetch origin + +# Display log messages for the new changes +git log HEAD..origin @end example -@cindex GNU Arch, updating ERC -@item Update to the latest version by replaying missing changes. +``origin'' is git's name for the location where you originally got ERC +from. You can change this location at any time by editing the +@file{.git/config} file in the directory where the ERC source was +placed. + +@cindex updating ERC with git +@item Update to the latest version by pulling in any missing changes. + @example cd erc -tla update +git pull origin @end example +git will show how many files changed, and will provide a visual display +for how many lines were changed in each file. + @end enumerate -If you are new to Arch and want to learn more about developing ERC with -it, visit @uref{http://emacswiki.org/cgi-bin/wiki/ErcDevelopment} for -full instructions. +There are other ways to interact with the ERC repository. -@subheading Development snapshots - -@cindex development snapshot -Alternatively, the latest development snapshot may be downloaded in both -``.tar.gz'' and ``.zip'' forms. - -@itemize @bullet -@item @uref{http://www.mwolson.org/static/dist/erc-latest.tar.gz} -@item @uref{http://www.mwolson.org/static/dist/erc-latest.zip} +@itemize +@item Browse git repo: @uref{http://git.sv.gnu.org/gitweb/?p=erc.git} +@item Latest development snapshot: @uref{http://mwolson.org/static/dist/erc-latest.tar.gz} +@item Latest development snapshot (zip file): @uref{http://mwolson.org/static/dist/erc-latest.zip} @end itemize +The latest development snapshot can lag behind the git repo by as much +as 20 minutes, but never more than that. + +For further information on committing changes to ERC and performing +development, please consult +@uref{http://emacswiki.org/cgi-bin/wiki/ErcDevelopment}. + @node Installation, Getting Started, Obtaining ERC, Top @comment node-name, next, previous, up @@ -1009,6 +1042,10 @@ ERC became an official GNU project, and development moved to @uref{http://sv.gnu.org/projects/erc}. We switched to using GNU Arch as our revision control system. Our mailing list address changed as well. +@item 2007 + +We switched to using git for our version control system. + @end itemize @node Copying, GNU Free Documentation License, History, Top diff --git a/lisp/erc/ChangeLog b/lisp/erc/ChangeLog index 3fb174c97d1..23057faa0b6 100644 --- a/lisp/erc/ChangeLog +++ b/lisp/erc/ChangeLog @@ -1,3 +1,20 @@ +2008-01-26 Michael Olson + + * erc.el (erc-version-string): Release ERC 5.3. + + * Makefile (VERSION): Update. + (EXTRAS): Remove erc-list.el after all, because this is mainly for + users of the version that comes with Emacs, and they will have + erc-list.el by Emacs 23. + (MISC): Add ChangeLog.07. + + * README.extras: Mention Emacs 23. + + * erc.texi (Obtaining ERC): Update extras URLs for 5.3. + (Development): Write instructions for git, and remove those for + Arch. + (History): Mention the switch to git. + 2008-01-25 Michael Olson * NEWS: Update. diff --git a/lisp/erc/erc.el b/lisp/erc/erc.el index aa03e67461f..e98c9d29baa 100644 --- a/lisp/erc/erc.el +++ b/lisp/erc/erc.el @@ -66,7 +66,7 @@ ;;; Code: -(defconst erc-version-string "Version 5.3 (RC 1)" +(defconst erc-version-string "Version 5.3" "ERC version. This is used by function `erc-version'.") (eval-when-compile (require 'cl)) From 28cbade4188cfa3037c23bcadfbbbaaf3960bc58 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Sat, 26 Jan 2008 21:54:44 +0000 Subject: [PATCH 367/439] (server-buffer): New const. (server-log): New var. (server-log): Use them. (server-process-filter): (Try to) run the continuation in the same cwd as the client's. --- lisp/ChangeLog | 36 +++++++++++++++++++++--------------- lisp/server.el | 46 +++++++++++++++++++++++++++++++--------------- 2 files changed, 52 insertions(+), 30 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2bb50cd13a4..d6db38e535c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,7 +1,15 @@ +2008-01-26 Stefan Monnier + + * server.el (server-buffer): New const. + (server-log): New var. + (server-log): Use them. + (server-process-filter): (Try to) run the continuation in the same cwd + as the client's. + 2008-01-26 Alan Mackenzie - * progmodes/cc-defs.el (c-save-buffer-state): Bind - buffer-file-name and buffer-file-truename to nil, to prevent + * progmodes/cc-defs.el (c-save-buffer-state): + Bind buffer-file-name and buffer-file-truename to nil, to prevent primitives generating "buffer is read only" messages. 2008-01-20 Ulf Jasper @@ -38,8 +46,8 @@ (`vc-directory'). Maybe the implementation can be optimized. * net/tramp.el (tramp-dissect-file-name): Raise an error when - Tramp 2.0 syntax is used. Suggested by Trent W. Buck - . + Tramp 2.0 syntax is used. + Suggested by Trent W. Buck . 2008-01-26 Eli Zaretskii @@ -53,7 +61,7 @@ * blank-mode.el: New version 9.1. Handle "long" line tail visualization. Doc fix. - (blank-line-length): Renamed to blank-line-column. + (blank-line-length): Rename to blank-line-column. (blank-chars-value-list, blank-toggle-option-alist, blank-help-text): Initialization fix. (blank-replace-spaces-by-tabs): New fun. @@ -108,8 +116,8 @@ 2008-01-24 Michael Albinus * net/tramp.el (tramp-do-copy-or-rename-file): Flush the cache of - the source file in case of `rename'. Reported by Pete Forman - . + the source file in case of `rename'. + Reported by Pete Forman . 2008-01-24 Ken Manheimer @@ -257,10 +265,9 @@ (kill-buffer-if-not-modified): New function. (view-file): Don't kill the buffer if it is modified. - * progmodes/ebrowse.el (ebrowse-view-file-other-window): - Delete function. - (ebrowse-view/find-file-and-search-pattern): Call - view-file-other-window instead of ebrowse-view-file-other-window. + * progmodes/ebrowse.el (ebrowse-view-file-other-window): Delete. + (ebrowse-view/find-file-and-search-pattern): + Call view-file-other-window instead of ebrowse-view-file-other-window. (ebrowse-view-file-other-frame): Don't call current-window-configuration. Fix second argument in the call to view-mode-enter. Doc fix. @@ -271,8 +278,8 @@ 2008-01-23 Dan Nicolaescu - * files.el (safe-local-eval-forms): Mark - (add-hook 'write-file-hooks 'time-stamp) as safe. + * files.el (safe-local-eval-forms): + Mark (add-hook 'write-file-hooks 'time-stamp) as safe. 2008-01-23 Nick Roberts @@ -488,8 +495,7 @@ * repeat.el (repeat-undo-count): New variable. (repeat): For self-insertions make undo boundary only after 20 - repetitions. Inhibit point recording when repeat-repeat-char is - non-nil. + repetitions. Inhibit point recording unless repeat-repeat-char is nil. 2008-01-19 Reiner Steib diff --git a/lisp/server.el b/lisp/server.el index 23f8eb36947..d3606f5c860 100644 --- a/lisp/server.el +++ b/lisp/server.el @@ -294,11 +294,20 @@ If NOFRAME is non-nil, let the frames live. (To be used from (defvar server-log-time-function 'current-time-string "Function to generate timestamps for the *server* buffer.") +(defconst server-buffer " *server*" + "Buffer used internally by Emacs's server. +One use is to log the I/O for debugging purposes (see `server-log'), +the other is to provide a current buffer in which the process filter can +safely let-bind buffer-local variables like default-directory.") + +(defvar server-log nil + "If non-nil, log the server's inputs and outputs in the `server-buffer'.") + (defun server-log (string &optional client) - "If a *server* buffer exists, write STRING to it for logging purposes. + "If `server-log' is non-nil, log STRING to `server-buffer'. If CLIENT is non-nil, add a description of it to the logged message." - (when (get-buffer "*server*") - (with-current-buffer "*server*" + (when server-log + (with-current-buffer (get-buffer-create server-buffer) (goto-char (point-max)) (insert (funcall server-log-time-function) (cond @@ -497,7 +506,7 @@ kill any existing server communications subprocess." ;; Those are decoded by server-process-filter according ;; to file-name-coding-system. :coding 'raw-text - ;; The rest of the args depends on the kind of socket used. + ;; The other args depend on the kind of socket used. (if server-use-tcp (list :family nil :service t @@ -928,17 +937,24 @@ The following commands are accepted by the client: (server-create-window-system-frame display nowait proc)) (t (server-create-tty-frame tty-name tty-type proc)))) - (process-put proc 'continuation - (lexical-let ((proc proc) - (files files) - (nowait nowait) - (commands commands) - (dontkill dontkill) - (frame frame) - (tty-name tty-name)) - (lambda () - (server-execute proc files nowait commands - dontkill frame tty-name)))) + (process-put + proc 'continuation + (lexical-let ((proc proc) + (files files) + (nowait nowait) + (commands commands) + (dontkill dontkill) + (frame frame) + (dir dir) + (tty-name tty-name)) + (lambda () + (with-current-buffer (get-buffer-create server-buffer) + ;; Use the same cwd as the emacsclient, if possible, so + ;; relative file names work correctly, even in `eval'. + (let ((default-directory + (if (file-directory-p dir) dir default-directory))) + (server-execute proc files nowait commands + dontkill frame tty-name)))))) (when (or frame files) (server-goto-toplevel proc)) From 00a72a6cb97e26f29157da7ae568c49c394a684d Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sat, 26 Jan 2008 22:14:34 +0000 Subject: [PATCH 368/439] *** empty log message *** --- lisp/ChangeLog | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 442f7669b28..e55184caea3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,15 @@ +2008-01-26 Alan Mackenzie + + * progmodes/cc-vars.el (c-hanging-braces-alist): new element for + arglist-cont-nonempty. + + * progmodes/cc-cmds.el (c-brace-newlines): Determine the newlines + for a brace with syntax arglist-cont-nonempty. + + * progmodes/cc-styles.el (c-style-alist): Add elements for + arglist-cont-nonempty into 5 styles (gnu, ellemtel, linux, python, + awk). + 2008-01-26 Alan Mackenzie * progmodes/cc-defs.el (c-save-buffer-state): Bind From 9bb1a1d66cfef977eab4129895ca7290be40ecfa Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sat, 26 Jan 2008 22:26:18 +0000 Subject: [PATCH 369/439] Introduce elements for the syntactic symbol arglist-cont-nonempty into c-hanging-braces-alist. Amend pertinent functions and 5 styles. --- lisp/progmodes/cc-cmds.el | 6 +++++- lisp/progmodes/cc-styles.el | 15 ++++++++++----- lisp/progmodes/cc-vars.el | 6 ++++-- 3 files changed, 19 insertions(+), 8 deletions(-) diff --git a/lisp/progmodes/cc-cmds.el b/lisp/progmodes/cc-cmds.el index e2bc7d55dc9..7afe6e6c243 100644 --- a/lisp/progmodes/cc-cmds.el +++ b/lisp/progmodes/cc-cmds.el @@ -524,7 +524,11 @@ inside a literal or a macro, nothing special happens." ;; This is the list of brace syntactic symbols that can hang. ;; If any new ones are added to c-offsets-alist, they should be ;; added here as well. - '(class-open class-close defun-open defun-close + ;; + ;; The order of this list is important; if SYNTAX has several + ;; elements, the element that "wins" is the earliest in SYMS. + '(arglist-cont-nonempty ; e.g. an array literal. + class-open class-close defun-open defun-close inline-open inline-close brace-list-open brace-list-close brace-list-intro brace-entry-open diff --git a/lisp/progmodes/cc-styles.el b/lisp/progmodes/cc-styles.el index 7c80f66e277..02240400b1e 100644 --- a/lisp/progmodes/cc-styles.el +++ b/lisp/progmodes/cc-styles.el @@ -58,7 +58,8 @@ '(("gnu" (c-basic-offset . 2) (c-comment-only-line-offset . (0 . 0)) - (c-hanging-braces-alist . ((substatement-open before after))) + (c-hanging-braces-alist . ((substatement-open before after) + (arglist-cont-nonempty))) (c-offsets-alist . ((statement-block-intro . +) (knr-argdecl-intro . 5) (substatement-open . +) @@ -170,7 +171,8 @@ (case-label . +) (access-label . -) (inclass . ++) - (inline-open . 0)))) + (inline-open . 0) + (arglist-cont-nonempty)))) ("linux" (c-basic-offset . 8) @@ -178,7 +180,8 @@ (c-hanging-braces-alist . ((brace-list-open) (brace-entry-open) (substatement-open after) - (block-close . c-snug-do-while))) + (block-close . c-snug-do-while) + (arglist-cont-nonempty))) (c-cleanup-list . (brace-else-brace)) (c-offsets-alist . ((statement-block-intro . +) (knr-argdecl-intro . 0) @@ -200,7 +203,8 @@ (brace-list-close) (brace-entry-open) (substatement-open after) - (block-close . c-snug-do-while))) + (block-close . c-snug-do-while) + (arglist-cont-nonempty))) (c-block-comment-prefix . "")) ("java" @@ -230,7 +234,8 @@ (c-hanging-braces-alist . ((defun-open after) (defun-close . c-snug-1line-defun-close) (substatement-open after) - (block-close . c-snug-do-while))) + (block-close . c-snug-do-while) + (arglist-cont-nonempty))) (c-hanging-semi&comma-criteria . nil) (c-cleanup-list . nil) ; You might want one-liner-defun here. (c-offsets-alist . ((statement-block-intro . +) diff --git a/lisp/progmodes/cc-vars.el b/lisp/progmodes/cc-vars.el index 425dddf16a0..f9c891de6c8 100644 --- a/lisp/progmodes/cc-vars.el +++ b/lisp/progmodes/cc-vars.el @@ -718,7 +718,8 @@ involve auto-newline inserted newlines: (module-open after) (composition-open after) (inexpr-class-open after) - (inexpr-class-close before)) + (inexpr-class-close before) + (arglist-cont-nonempty)) "*Controls the insertion of newlines before and after braces when the auto-newline feature is active. This variable contains an association list with elements of the following form: @@ -772,7 +773,8 @@ syntactic context for the brace line." namespace-open namespace-close module-open module-close composition-open composition-close - inexpr-class-open inexpr-class-close))) + inexpr-class-open inexpr-class-close + arglist-cont-nonempty))) :group 'c) (defcustom c-max-one-liner-length 80 From ae068fdff1f6ef59035b1db42572ea09731a8285 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sat, 26 Jan 2008 23:57:17 +0000 Subject: [PATCH 370/439] (Tags): Delete redundant index entry. --- man/ChangeLog | 4 ++++ man/maintaining.texi | 8 ++++---- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/man/ChangeLog b/man/ChangeLog index 31465ffbca3..65963d30088 100644 --- a/man/ChangeLog +++ b/man/ChangeLog @@ -1,3 +1,7 @@ +2008-01-26 Richard Stallman + + * maintaining.texi (Tags): Delete redundant index entry. + 2008-01-26 Eli Zaretskii * programs.texi (Imenu): Move "@cindex tags" from here... diff --git a/man/maintaining.texi b/man/maintaining.texi index 385431f28ba..1a4877c422b 100644 --- a/man/maintaining.texi +++ b/man/maintaining.texi @@ -130,7 +130,6 @@ Of course, you should substitute the proper years and copyright holder. @node Tags @section Tags Tables -@cindex tags @cindex tag tables A @dfn{tags table} is a description of how a multi-file program is @@ -793,9 +792,10 @@ default is to use the same setting as the value of It is possible to get through all the files in the tags table with a single invocation of @kbd{M-x tags-query-replace}. But often it is useful to exit temporarily, which you can do with any input event that -has no special query replace meaning. You can resume the query replace -subsequently by typing @kbd{M-,}; this command resumes the last tags -search or replace command that you did. +has no special query replace meaning. You can resume the query +replace subsequently by typing @kbd{M-,}; this command resumes the +last tags search or replace command that you did. For instance, to +skip the rest of the current file, you can type @kbd{M-> M-,}. The commands in this section carry out much broader searches than the @code{find-tag} family. The @code{find-tag} commands search only for From 60c7bbd2ad7f57a88dd0001e6a39e44fb6a4e7c4 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sun, 27 Jan 2008 01:04:56 +0000 Subject: [PATCH 371/439] Many doc fixes. (allout-encrypt-string): Fix error message. --- lisp/allout.el | 319 +++++++++++++++++++++++++------------------------ 1 file changed, 160 insertions(+), 159 deletions(-) diff --git a/lisp/allout.el b/lisp/allout.el index 7782170e834..08c0c4a391f 100644 --- a/lisp/allout.el +++ b/lisp/allout.el @@ -5,7 +5,7 @@ ;; Author: Ken Manheimer ;; Maintainer: Ken Manheimer -;; Created: Dec 1991 - first release to usenet +;; Created: Dec 1991 -- first release to usenet ;; Version: 2.2.1 ;; Keywords: outlines wp languages ;; Website: http://myriadicity.net/Sundry/EmacsAllout @@ -36,11 +36,11 @@ ;; - Topic-oriented editing including coherent topic and subtopic ;; creation, promotion, demotion, cut/paste across depths, etc. ;; - Incremental search with dynamic exposure and reconcealment of text -;; - Customizable bullet format - enables programming-language specific +;; - Customizable bullet format -- enables programming-language specific ;; outlining, for code-folding editing. (Allout code itself is to try it; -;; formatted as an outline - do ESC-x eval-buffer in allout.el; but +;; formatted as an outline -- do ESC-x eval-buffer in allout.el; but ;; emacs local file variables need to be enabled when the -;; file was visited - see `enable-local-variables'.) +;; file was visited -- see `enable-local-variables'.) ;; - Configurable per-file initial exposure settings ;; - Symmetric-key and key-pair topic encryption, plus symmetric passphrase ;; mnemonic support, with verification against an established passphrase @@ -53,7 +53,7 @@ ;; exposure control (see the allout-mode docstring) ;; - Easy rendering of exposed portions into numbered, latex, indented, etc ;; outline styles -;; - Careful attention to whitespace - enabling blank lines between items +;; - Careful attention to whitespace -- enabling blank lines between items ;; and maintenance of hanging indentation (in paragraph auto-fill and ;; across topic promotion and demotion) of topic bodies consistent with ;; indentation of their topic header. @@ -76,7 +76,7 @@ ;; `allout-mode' as a minor mode. (It has changed since allout ;; 3.x, for those of you that depend on the old method.) ;; -;; Note - the lines beginning with `;;;_' are outline topic headers. +;; Note -- the lines beginning with `;;;_' are outline topic headers. ;; Just `ESC-x eval-buffer' to give it a whirl. ;; ken manheimer (ken dot manheimer at gmail dot com) @@ -111,7 +111,7 @@ ;;;_ = allout-auto-activation (defcustom allout-auto-activation nil - "*Regulates auto-activation modality of allout outlines - see `allout-init'. + "*Regulates auto-activation modality of allout outlines -- see `allout-init'. Setq-default by `allout-init' to regulate whether or not allout outline mode is automatically activated when the buffer-specific @@ -153,35 +153,35 @@ value will automatically trigger `allout-mode', provided The types of elements in the layout specification are: - integer - dictate the relative depth to open the corresponding topic(s), - where: - - negative numbers force the topic to be closed before opening - to the absolute value of the number, so all siblings are open - only to that level. - - positive numbers open to the relative depth indicated by the - number, but do not force already opened subtopics to be closed. - - 0 means to close topic - hide all subitems. - : - repeat spec - apply the preceeding element to all siblings at - current level, *up to* those siblings that would be covered by specs - following the `:' on the list. Ie, apply to all topics at level but - trailing ones accounted for by trailing specs. (Only the first of - multiple colons at the same level is honored - later ones are ignored.) - * - completely exposes the topic, including bodies - + - exposes all subtopics, but not the bodies - - - exposes the body of the corresponding topic, but not subtopics - list - a nested layout spec, to be applied intricately to its + INTEGER -- dictate the relative depth to open the corresponding topic(s), + where: + -- negative numbers force the topic to be closed before opening + to the absolute value of the number, so all siblings are open + only to that level. + -- positive numbers open to the relative depth indicated by the + number, but do not force already opened subtopics to be closed. + -- 0 means to close topic -- hide all subitems. + : -- repeat spec -- apply the preceeding element to all siblings at + current level, *up to* those siblings that would be covered by specs + following the `:' on the list. Ie, apply to all topics at level but + trailing ones accounted for by trailing specs. (Only the first of + multiple colons at the same level is honored -- later ones are ignored.) + * -- completely exposes the topic, including bodies + + -- exposes all subtopics, but not the bodies + - -- exposes the body of the corresponding topic, but not subtopics + LIST -- a nested layout spec, to be applied intricately to its corresponding item(s) Examples: - '(-2 : 0) + (-2 : 0) Collapse the top-level topics to show their children and grandchildren, but completely collapse the final top-level topic. - '(-1 () : 1 0) + (-1 () : 1 0) Close the first topic so only the immediate subtopics are shown, leave the subsequent topics exposed as they are until the second second to last topic, which is exposed at least one level, and completely close the last topic. - '(-2 : -1 *) + (-2 : -1 *) Expose children and grandchildren of all topics at current level except the last two; expose children of the second to last and completely expose the last one, including its subtopics. @@ -253,7 +253,7 @@ repeated calls." Cycling only happens on when the command is repeated, not when it follows a different command. -Smart-placement means that repeated calls to this function will +Smart placement means that repeated calls to this function will advance as follows: - if the cursor is not on the end-of-line, @@ -335,25 +335,25 @@ persistent until deliberately changed. Their significance is purely by convention, however. Some conventions suggest themselves: - `(' - open paren - an aside or incidental point - `?' - question mark - uncertain or outright question - `!' - exclamation point/bang - emphatic - `[' - open square bracket - meta-note, about item instead of item's subject - `\"' - double quote - a quotation or other citation - `=' - equal sign - an assignement, equating a name with some connotation - `^' - carat - relates to something above + `(' - open paren -- an aside or incidental point + `?' - question mark -- uncertain or outright question + `!' - exclamation point/bang -- emphatic + `[' - open square bracket -- meta-note, about item instead of item's subject + `\"' - double quote -- a quotation or other citation + `=' - equal sign -- an assignement, equating a name with some connotation + `^' - carat -- relates to something above Some are more elusive, but their rationale may be recognizable: - `+' - plus - pending consideration, completion - `_' - underscore - done, completed - `&' - ampersand - addendum, furthermore + `+' - plus -- pending consideration, completion + `_' - underscore -- done, completed + `&' - ampersand -- addendum, furthermore \(Some other non-plain bullets have special meaning to the software. By default: - `~' marks encryptable topics - see `allout-topic-encryption-bullet' - `#' marks auto-numbered bullets - see `allout-numbered-bullet'.) + `~' marks encryptable topics -- see `allout-topic-encryption-bullet' + `#' marks auto-numbered bullets -- see `allout-numbered-bullet'.) See `allout-plain-bullets-string' for the standard, alternating bullets. @@ -436,7 +436,7 @@ are always respected by the topic maneuvering functions." ;;;###autoload (put 'allout-old-style-prefixes 'safe-local-variable (if (fboundp 'booleanp) 'booleanp '(lambda (x) (member x '(t nil))))) -;;;_ = allout-stylish-prefixes - alternating bullets +;;;_ = allout-stylish-prefixes -- alternating bullets (defcustom allout-stylish-prefixes t "*Do fancy stuff with topic prefix bullets according to level, etc. @@ -600,9 +600,9 @@ variable for details about allout ajustment of file variables." (defcustom allout-passphrase-hint-handling 'always "*Dictate outline encryption passphrase reminder handling: - always - always show reminder when prompting - needed - show reminder on passphrase entry failure - disabled - never present or adjust reminder + always -- always show reminder when prompting + needed -- show reminder on passphrase entry failure + disabled -- never present or adjust reminder See the docstring for the `allout-enable-file-variable-adjustment' variable for details about allout ajustment of file variables." @@ -625,7 +625,7 @@ mostly covers both deliberate file writes and auto-saves. can continue editing but the copy on the file system will be encrypted.) Auto-saves will use the \"All except current topic\" mode if this - one is selected, to avoid practical difficulties - see below. + one is selected, to avoid practical difficulties -- see below. - All except current topic: skip the topic currently being edited, even if it's pending encryption. This may expose the current topic on the file sytem, but avoids the nuisance of prompts for the encryption @@ -677,7 +677,7 @@ willing to let allout use a bunch of \C-c keybindings." :group 'allout) ;;;_ = allout-keybindings-list -;;; You have to reactivate allout-mode - `(allout-mode t)' - to +;;; You have to reactivate allout-mode -- `(allout-mode t)' -- to ;;; institute changes to this var. (defvar allout-keybindings-list () "*List of `allout-mode' key / function bindings, for `allout-mode-map'. @@ -792,7 +792,7 @@ For details, see `allout-toggle-current-subtree-encryption's docstring." :group 'allout) (make-variable-buffer-local 'allout-enable-file-variable-adjustment) -;;;_* CODE - no user customizations below. +;;;_* CODE -- no user customizations below. ;;;_ #1 Internal Outline Formatting and Configuration ;;;_ : Version @@ -812,7 +812,7 @@ For details, see `allout-toggle-current-subtree-encryption's docstring." (defvar allout-mode nil "Allout outline mode minor-mode flag.") (make-variable-buffer-local 'allout-mode) ;;;_ = allout-layout nil -(defvar allout-layout nil ; LEAVE GLOBAL VALUE NIL - see docstring. +(defvar allout-layout nil ; LEAVE GLOBAL VALUE NIL -- see docstring. "Buffer-specific setting for allout layout. In buffers where this is non-nil (and if `allout-init' has been run, to @@ -856,7 +856,7 @@ by `set-allout-regexp'.") (defvar allout-bullets-string "" "A string dictating the valid set of outline topic bullets. -This var should *not* be set by the user - it is set by `set-allout-regexp', +This var should *not* be set by the user -- it is set by `set-allout-regexp', and is produced from the elements of `allout-plain-bullets-string' and `allout-distinctive-bullets-string'.") (make-variable-buffer-local 'allout-bullets-string) @@ -954,7 +954,7 @@ invoking it directly." comment-start t))) allout-use-mode-specific-leader - ;; Oops - garbled value, equate with effect of 't: + ;; Oops -- garbled value, equate with effect of t: t))) (leader (cond @@ -983,7 +983,7 @@ invoking it directly." (setq allout-header-prefix leader) (if (not allout-old-style-prefixes) ;; setting allout-primary-bullet makes the top level topics use - - ;; actually, be - the special prefix: + ;; actually, be -- the special prefix: (setq allout-primary-bullet leader)) allout-header-prefix))) (defalias 'allout-infer-header-lead @@ -1239,7 +1239,7 @@ extended from the existing one by `append'ing a list containing the second element of the pair onto the end of the existing value. Extension, and resumptions in general, should not be used for hook -functions - use the 'local mode of `add-hook' for that, instead. +functions -- use the 'local mode of `add-hook' for that, instead. The settings are stored on `allout-mode-prior-settings'." (while pairs @@ -1258,7 +1258,7 @@ The settings are stored on `allout-mode-prior-settings'." (when (not (assoc name allout-mode-prior-settings)) ;; Not already added as a resumption, create the prior setting entry. (if (local-variable-p name) - ;; is already local variable - preserve the prior value: + ;; is already local variable -- preserve the prior value: (push (list name prior-value) allout-mode-prior-settings) ;; wasn't local variable, indicate so for resumption by killing ;; local value, and make it local: @@ -1324,9 +1324,9 @@ It is run at the conclusion of `allout-flag-region'. Functions on the hook must take three arguments: - - from - integer indicating the point at the start of the change. - - to - integer indicating the point of the end of the change. - - flag - change mode: nil for exposure, otherwise concealment. + - FROM -- integer indicating the point at the start of the change. + - TO -- integer indicating the point of the end of the change. + - FLAG -- change mode: nil for exposure, otherwise concealment. This hook might be invoked multiple times by a single command. @@ -1338,10 +1338,10 @@ and eventually will not be invoked.") Functions on the hook should take two arguments: - - new-start - integer indicating the point at the start of the first new item. - - new-end - integer indicating the point of the end of the last new item. + - NEW-START -- integer indicating position of start of the first new item. + - NEW-END -- integer indicating position of end of the last new item. -Some edits that introduce new items may missed by this hook - +Some edits that introduce new items may missed by this hook: specifically edits that native allout routines do not control. This hook might be invoked multiple times by a single command.") @@ -1351,10 +1351,10 @@ This hook might be invoked multiple times by a single command.") Functions on the hook must take two arguments: - - depth - integer indicating the depth of the subtree that was deleted. - - removed-from - integer indicating the point where the subtree was removed. + - DEPTH -- integer indicating the depth of the subtree that was deleted. + - REMOVED-FROM -- integer indicating the point where the subtree was removed. -Some edits that remove or invalidate items may missed by this hook - +Some edits that remove or invalidate items may missed by this hook: specifically edits that native allout routines do not control. This hook might be invoked multiple times by a single command.") @@ -1364,10 +1364,10 @@ This hook might be invoked multiple times by a single command.") Functions on the hook should take two arguments: - - depth-change - integer indicating depth increase, negative for decrease - - start - integer indicating the start point of the shifted parent item. + - DEPTH-CHANGE -- integer indicating depth increase, negative for decrease + - START -- integer indicating the start point of the shifted parent item. -Some edits that shift items can be missed by this hook - specifically edits +Some edits that shift items can be missed by this hook: specifically edits that native allout routines do not control. This hook might be invoked multiple times by a single command.") @@ -1462,7 +1462,7 @@ See `allout-encryption-ciphertext-rejection-regexps' for rejection reasons.") (make-variable-buffer-local 'allout-encryption-ciphertext-rejection-ceiling) ;;;_ > allout-mode-p () ;; Must define this macro above any uses, or byte compilation will lack -;; proper def, if file isn't loaded - eg, during emacs build! +;; proper def, if file isn't loaded -- eg, during emacs build! (defmacro allout-mode-p () "Return t if `allout-mode' is active in current buffer." 'allout-mode) @@ -1638,8 +1638,8 @@ the following two lines in your Emacs init file: (put 'allout-exposure-category 'evaporate t) ;; XXX We use isearch-open-invisible *and* isearch-mode-end-hook. The ;; latter would be sufficient, but it seems that a separate behavior - - ;; the _transient_ opening of invisible text during isearch - is keyed to - ;; presence of the isearch-open-invisible property - even though this + ;; the _transient_ opening of invisible text during isearch -- is keyed to + ;; presence of the isearch-open-invisible property -- even though this ;; property controls the isearch _arrival_ behavior. This is the case at ;; least in emacs 21, 22.0, and xemacs 21.4. (put 'allout-exposure-category 'isearch-open-invisible @@ -1693,7 +1693,7 @@ variable. We recommend customizing `allout-command-prefix' to use just `\\C-c' as the command prefix, if the allout bindings don't conflict with any personal bindings you have on \\C-c. In any case, outline structure navigation and authoring is simplified by positioning the cursor on an -item's bullet character, the \"hot-spot\" - then you can invoke allout +item's bullet character, the \"hot-spot\" -- then you can invoke allout commands with just the un-prefixed, un-control-shifted command letters. This is described further in the HOT-SPOT Operation section. @@ -1714,7 +1714,7 @@ This is described further in the HOT-SPOT Operation section. \\[allout-backward-current-level] `allout-backward-current-level' \\[allout-end-of-entry] `allout-end-of-entry' \\[allout-beginning-of-current-entry] `allout-beginning-of-current-entry' (alternately, goes to hot-spot) -\\[allout-beginning-of-line] `allout-beginning-of-line' - like regular beginning-of-line, but +\\[allout-beginning-of-line] `allout-beginning-of-line' -- like regular beginning-of-line, but if immediately repeated cycles to the beginning of the current item and then to the hot-spot (if `allout-beginning-of-line-cycles' is set). @@ -1732,7 +1732,7 @@ This is described further in the HOT-SPOT Operation section. \\[allout-rebullet-current-heading] `allout-rebullet-current-heading' Prompt for alternate bullet for current topic \\[allout-rebullet-topic] `allout-rebullet-topic' Reconcile bullets of topic and - its' offspring - distinctive bullets are not changed, others + its' offspring -- distinctive bullets are not changed, others are alternated according to nesting depth. \\[allout-number-siblings] `allout-number-siblings' Number bullets of topic and siblings - the offspring are not affected. @@ -1763,7 +1763,7 @@ M-x outlineify-sticky Activate outline mode for current buffer, \\[allout-copy-exposed-to-buffer] `allout-copy-exposed-to-buffer' Duplicate outline, sans concealed text, to buffer with name derived from derived from that - of current buffer - \"*BUFFERNAME exposed*\". + of current buffer -- \"*BUFFERNAME exposed*\". \\[allout-flatten-exposed-to-buffer] `allout-flatten-exposed-to-buffer' Like above 'copy-exposed', but convert topic prefixes to section.subsection... numeric @@ -1832,7 +1832,7 @@ without changes to the allout core. Here are key ones: Terminology -Topic hierarchy constituents - TOPICS and SUBTOPICS: +Topic hierarchy constituents -- TOPICS and SUBTOPICS: ITEM: A unitary outline element, including the HEADER and ENTRY text. TOPIC: An ITEM and any ITEMs contained within it, ie having greater DEPTH @@ -2085,7 +2085,7 @@ OPEN: A TOPIC that is not CLOSED, though its OFFSPRING or BODY may be." (progn (apply 'allout-expose-topic (list use-layout)) (message "Adjusting '%s' exposure... done." (buffer-name))) - ;; Problem applying exposure - notify user, but don't + ;; Problem applying exposure -- notify user, but don't ;; interrupt, eg, file visit: (error (message "%s" (car (cdr err))) (sit-for 1)))))) @@ -2153,7 +2153,7 @@ We expose the invisible text and ask for confirmation. Refusal or `keyboard-quit' abandons the changes, with keyboard-quit additionally reclosing the opened text. -No confirmation is necessary when `inhibit-read-only' is set - eg, allout +No confirmation is necessary when `inhibit-read-only' is set -- eg, allout internal functions use this feature cohesively bunch changes." (when (and (not inhibit-read-only) (not after)) @@ -2191,7 +2191,7 @@ internal functions use this feature cohesively bunch changes." (defun allout-before-change-handler (beg end) "Protect against changes to invisible text. -See allout-overlay-interior-modification-handler for details." +See `allout-overlay-interior-modification-handler' for details." (if (and (allout-mode-p) undo-in-progress (allout-hidden-p)) (allout-show-to-offshoot)) @@ -2216,7 +2216,7 @@ function can also be used as an `isearch-mode-end-hook'." (if (and (allout-mode-p) (allout-hidden-p)) (allout-show-to-offshoot))) -;;;_ #3 Internal Position State-Tracking - "allout-recent-*" funcs +;;;_ #3 Internal Position State-Tracking -- "allout-recent-*" funcs ;;; All the basic outline functions that directly do string matches to ;;; evaluate heading prefix location set the variables ;;; `allout-recent-prefix-beginning' and `allout-recent-prefix-end' @@ -2299,7 +2299,7 @@ to return the current depth of the most recently matched topic." (defsubst allout-do-doublecheck () "True if current item conditions qualify for checking on topic aberrance." (and - ;; presume integrity of outline and yanked content during yank - necessary, + ;; presume integrity of outline and yanked content during yank -- necessary ;; to allow for level disparity of yank location and yanked text: (not allout-inhibit-aberrance-doublecheck) ;; allout-doublecheck-at-and-shallower is ceiling for doublecheck: @@ -2336,12 +2336,12 @@ exceeds the topic by more than one." (allout-prefix-data) (goto-char allout-recent-prefix-beginning) (cond - ;; sibling - continue: + ;; sibling -- continue: ((eq allout-recent-depth depth)) - ;; first offspring is excessive - aberrant: + ;; first offspring is excessive -- aberrant: ((> allout-recent-depth (1+ depth)) (setq done t aberrant t)) - ;; next non-sibling is lower-depth - not aberrant: + ;; next non-sibling is lower-depth -- not aberrant: (t (setq done t))))) (if aberrant aberrant @@ -2666,9 +2666,9 @@ starting point, and PREV-DEPTH is depth of prior topic." ;; Register this one and move on: (setq chart (cons allout-recent-prefix-beginning chart)) (if (and levels (<= levels 1)) - ;; At depth limit - skip sublevels: + ;; At depth limit -- skip sublevels: (or (allout-next-sibling curr-depth) - ;; or no more siblings - proceed to + ;; or no more siblings -- proceed to ;; next heading at lesser depth: (while (and (<= curr-depth allout-recent-depth) @@ -2741,7 +2741,7 @@ start point." (let ((further (allout-chart-to-reveal here (if (null depth) depth (1- depth))))) - ;; We're on the start of a subtree - recurse with it, if there's + ;; We're on the start of a subtree -- recurse with it, if there's ;; more depth to go: (if further (setq result (append further result))) (setq chart (cdr chart))) @@ -3126,7 +3126,7 @@ situation." (progn (goto-char start-point) nil) ;; rationale: if any intervening items were at a lower depth, we - ;; would now be on the first offspring at the target depth - ie, + ;; would now be on the first offspring at the target depth -- ie, ;; the preceeding item (per the search direction) must be at a ;; lesser depth. that's all we need to check. (if backward (allout-next-heading) (allout-previous-heading)) @@ -3203,7 +3203,7 @@ Move to buffer limit in indicated direction if headings are exhausted." (allout-aberrant-container-p)) ;; skip this aberrant prospective header line: t - ;; this prospective headerline qualifies - register: + ;; this prospective headerline qualifies -- register: (setq got allout-recent-prefix-beginning) ;; and break the loop: nil)))) @@ -3371,7 +3371,7 @@ Returns the qualifying command, if any, else nil." (>= 122 key-num)) ; "z" (- key-num 96) key-num))) t)))) - ;; Qualified as an allout command - do hot-spot operation. + ;; Qualified as an allout command -- do hot-spot operation. (setq allout-post-goto-bullet t) ;; accept-defaults nil, or else we'll get allout-item-icon-key-handler. (setq mapped-binding (key-binding (char-to-string key-num)))) @@ -3473,7 +3473,7 @@ Second arg NEW indicates that a new topic is being opened after the topic at point, if non-nil. Default bullet for new topics, eg, may be set (contingent to other args) to numbered bullets if previous sibling is one. The implication otherwise is that the current topic -is being adjusted - shifted or rebulleted - and we don't consider +is being adjusted -- shifted or rebulleted -- and we don't consider bullet or previous sibling. Third arg DEPTH forces the topic prefix to that depth, regardless of @@ -3519,11 +3519,11 @@ index for each successive sibling)." ;; Getting value for bullet char is practically the whole job: (cond - ; Simplest situation - level 1: + ; Simplest situation -- level 1: ((<= depth 1) (setq header-lead "") allout-primary-bullet) ; Simple, too: all asterisks: (allout-old-style-prefixes - ;; Cheat - make body the whole thing, null out header-lead and + ;; Cheat -- make body the whole thing, null out header-lead and ;; bullet-char: (setq body (make-string depth (string-to-char allout-primary-bullet))) @@ -3601,8 +3601,8 @@ index for each successive sibling)." "Open a new topic at depth DEPTH. New topic is situated after current one, unless optional flag BEFORE -is non-nil, or unless current line is completely empty - lacking even -whitespace - in which case open is done on the current line. +is non-nil, or unless current line is completely empty -- lacking even +whitespace -- in which case open is done on the current line. When adding an offspring, it will be added immediately after the parent if the other offspring are exposed, or after the last child if the offspring @@ -3666,7 +3666,7 @@ Nuances: (if (not opening-on-blank) ; Positioning and vertical - ; padding - only if not + ; padding -- only if not ; opening-on-blank: (progn (goto-char ref-topic) @@ -3717,7 +3717,7 @@ Nuances: (open-line 1))) (allout-end-of-current-subtree) (if (looking-at "\n\n") (forward-char 1)))) - ;; Going inwards - double-space if first offspring is + ;; Going inwards -- double-space if first offspring is ;; double-spaced, otherwise snug up. (allout-end-of-entry) (if (eobp) @@ -3727,7 +3727,7 @@ Nuances: (backward-char 1) (if (bolp) ;; Blank lines between current header body and next - ;; header - get to last substantive (non-white-space) + ;; header -- get to last substantive (non-white-space) ;; line in body: (progn (setq dbl-space t) (re-search-backward "[^ \t\n]" nil t))) @@ -3872,7 +3872,7 @@ Note that refill of indented paragraphs is not done." (not (looking-at allout-regexp))) (if (> 0 (setq excess (- (- old-indent-end old-indent-begin) old-margin))) - ;; Text starts left of old margin - don't adjust: + ;; Text starts left of old margin -- don't adjust: nil ;; Text was hanging at or right of old left margin - ;; reindent it, preserving its existing indentation @@ -4131,7 +4131,7 @@ a topic and its immediate offspring is greater than one.)" nil)))) ;;; do-successors ((< starting-depth new-depth) - ;; Rare case - subtopic more than one level deeper than parent. + ;; Rare case -- subtopic more than one level deeper than parent. ;; Treat this one at an even deeper level: (allout-rebullet-topic-grunt relative-depth new-depth @@ -4193,7 +4193,7 @@ Returns final depth." (defun allout-number-siblings (&optional denumber) "Assign numbered topic prefix to this topic and its siblings. -With universal argument, denumber - assign default bullet to this +With universal argument, denumber -- assign default bullet to this topic and its siblings. With repeated universal argument (`^U^U'), solicit bullet for each @@ -4408,7 +4408,7 @@ Topic exposure is marked with text-properties, to be used by 'invisible nil end)))) (if (or (not next) (eq prev next)) - ;; still not at start of hidden area - must not be any left. + ;; still not at start of hidden area -- must not be any left. (setq done t) (goto-char next) (setq prev next) @@ -4449,7 +4449,7 @@ Topic exposure is marked with text-properties, to be used by 'allout-was-hidden nil end))) (if (or (not next) (eq prev next)) - ;; no more or not advancing - must not be any left. + ;; no more or not advancing -- must not be any left. (setq done t) (goto-char next) (setq prev next) @@ -4505,7 +4505,7 @@ however, are left exactly like normal, non-allout-specific yanks." (rectify-numbering (or resituate (and into-bol (looking-at allout-regexp))))) (if resituate - ;; Yanking a topic into the start of a topic - reconcile to fit: + ;; Yanking a topic into the start of a topic -- reconcile to fit: (let* ((inhibit-field-text-motion t) (prefix-len (if (not (match-end 1)) 1 @@ -4644,7 +4644,7 @@ works with normal `yank' in non-outline buffers." Adapts level of popped topics to level of fresh prefix. -Note - prefix changes to distinctive bullets will stick, if followed +Note -- prefix changes to distinctive bullets will stick, if followed by pops to non-distinctive yanks. Bug..." (interactive "*p") @@ -4663,7 +4663,7 @@ by pops to non-distinctive yanks. Bug..." (interactive) (if (not allout-file-xref-bullet) (error - "Outline cross references disabled - no `allout-file-xref-bullet'") + "Outline cross references disabled -- no `allout-file-xref-bullet'") (if (not (string= (allout-current-bullet) allout-file-xref-bullet)) (error "Current heading lacks cross-reference bullet `%s'" allout-file-xref-bullet) @@ -4890,11 +4890,11 @@ With a repeat-count, expose this topic and its siblings." (interactive "P") (save-excursion (if (<= (allout-current-depth) 0) - ;; Outside any topics - try to get to the first: + ;; Outside any topics -- try to get to the first: (if (not (allout-next-heading)) (error "No topics") - ;; got to first, outermost topic - set to expose it and siblings: - (message "Above outermost topic - exposing all.") + ;; got to first, outermost topic -- set to expose it and siblings: + (message "Above outermost topic -- exposing all.") (allout-flag-region (point-min)(point-max) nil)) (allout-beginning-of-current-line) (if (not arg) @@ -4931,7 +4931,7 @@ siblings, even if the target topic is already closed." (interactive) (let* ((from (point)) - (sibs-msg "Top-level topic already closed - closing siblings...") + (sibs-msg "Top-level topic already closed -- closing siblings...") (current-exposed (not (allout-current-topic-collapsed-p t)))) (cond (current-exposed (allout-flag-current-subtree t)) (just-close nil) @@ -5019,13 +5019,13 @@ Simple (numeric and null-list) specs are interpreted as follows: that level. - positive numbers open to the relative depth indicated by the number, but do not force already opened subtopics to be closed. - - 0 means to close topic - hide all offspring. + - 0 means to close topic -- hide all offspring. : - `repeat' apply prior element to all siblings at current level, *up to* those siblings that would be covered by specs following the `:' on the list. Ie, apply to all topics at level but the last ones. (Only first of multiple colons at same level is - respected - subsequent ones are discarded.) + respected -- subsequent ones are discarded.) * - completely opens the topic, including bodies. + - shows all the sub headers, but not the bodies - - exposes the body of the corresponding topic. @@ -5073,11 +5073,11 @@ Examples: ;; Expand the `repeat' spec to an explicit version, ;; w.r.t. remaining siblings: (let ((residue ; = # of sibs not covered by remaining spec - ;; Dang - could be nice to make use of the chart, sigh: + ;; Dang, could be nice to make use of the chart, sigh: (- (length (allout-chart-siblings)) (length spec)))) (if (< 0 residue) - ;; Some residue - cover it with prev-elem: + ;; Some residue -- cover it with prev-elem: (setq spec (append (make-list residue prev-elem) spec))))))) ((numberp curr-elem) @@ -5211,7 +5211,7 @@ Examples: (error "allout-new-exposure: Can't find any outline topics")) (list 'allout-expose-topic (list 'quote spec)))) -;;;_ #7 Systematic outline presentation - copying, printing, flattening +;;;_ #7 Systematic outline presentation -- copying, printing, flattening ;;;_ - Mapping and processing of topics ;;;_ ( See also Subtree Charting, in Navigation code.) @@ -5302,9 +5302,9 @@ Optional START and END indicate bounds of region. Optional arg, FORMAT, designates an alternate presentation form for the prefix: - list - Present prefix as numeric section.subsection..., starting with + list -- Present prefix as numeric section.subsection..., starting with section indicated by the list, innermost nesting first. - `indent' (symbol) - Convert header prefixes to all white space, + `indent' (symbol) -- Convert header prefixes to all white space, except for distinctive bullets. The elements of the list produced are lists that represents a topic @@ -5329,7 +5329,7 @@ header and body. The elements of that list are: (beginning-of-line) ;; Goto initial topic, and register preceeding stuff, if any: (if (> (allout-goto-prefix-doublechecked) start) - ;; First topic follows beginning point - register preliminary stuff: + ;; First topic follows beginning point -- register preliminary stuff: (setq result (list (list 0 "" nil (buffer-substring start (1- (point))))))) (while (and (not done) @@ -5397,7 +5397,7 @@ header and body. The elements of that list are: (cond ((= new-depth depth) (setq format (cons (1+ (car format)) (cdr format)))) - ((> new-depth depth) ; descending - assume by 1: + ((> new-depth depth) ; descending -- assume by 1: (setq format (cons 1 format))) (t ; Pop the residue: @@ -5428,12 +5428,12 @@ Apply FUNCTION to exposed portions FROM position TO position in buffer FROMBUF to buffer TOBUF. Sixth optional arg, FORMAT, designates an alternate presentation form: - `flat' - Present prefix as numeric section.subsection..., starting with + `flat' -- Present prefix as numeric section.subsection..., starting with section indicated by the START-NUM, innermost nesting first. - X`flat-indented' - Prefix is like `flat' for first topic at each + X`flat-indented' -- Prefix is like `flat' for first topic at each X level, but subsequent topics have only leaf topic X number, padded with blanks to line up with first. - `indent' (symbol) - Convert header prefixes to all white space, + `indent' (symbol) -- Convert header prefixes to all white space, except for distinctive bullets. Defaults: @@ -5453,19 +5453,19 @@ Defaults: (setq from (point-min) to (point-max)))) (if frombuf (if (not (bufferp frombuf)) - ;; Specified but not a buffer - get it: + ;; Specified but not a buffer -- get it: (let ((got (get-buffer frombuf))) (if (not got) (error (concat "allout-process-exposed: source buffer " frombuf " not found.")) (setq frombuf got)))) - ;; not specified - default it: + ;; not specified -- default it: (setq frombuf (current-buffer))) (if tobuf (if (not (bufferp tobuf)) (setq tobuf (get-buffer-create tobuf))) - ;; not specified - default it: + ;; not specified -- default it: (setq tobuf (concat "*" (buffer-name frombuf) " exposed*"))) (if (listp format) (nreverse format)) @@ -5552,7 +5552,7 @@ alternate presentation format for the outline: (defun allout-flatten-exposed-to-buffer (&optional arg tobuf) "Present numeric outline of outline's exposed portions in another buffer. -The resulting outline is not compatible with outline mode - use +The resulting outline is not compatible with outline mode -- use `allout-copy-exposed-to-buffer' if you want that. Use `allout-indented-exposed-to-buffer' for indented presentation. @@ -5568,7 +5568,7 @@ used verbatim." (defun allout-indented-exposed-to-buffer (&optional arg tobuf) "Present indented outline of outline's exposed portions in another buffer. -The resulting outline is not compatible with outline mode - use +The resulting outline is not compatible with outline mode -- use `allout-copy-exposed-to-buffer' if you want that. Use `allout-flatten-exposed-to-buffer' for numeric sectional presentation. @@ -5796,7 +5796,7 @@ encryption are encrypted. See allout-encrypt-unencrypted-on-saves for auto-encryption specifics. \*NOTE WELL* that automatic encryption that happens during saves will -default to symmetric encryption - you must deliberately (re)encrypt key-pair +default to symmetric encryption -- you must deliberately (re)encrypt key-pair encrypted topics if you want them to continue to use the key-pair cipher. Level-one topics, with prefix consisting solely of an `*' asterisk, cannot be @@ -5883,7 +5883,7 @@ See `allout-toggle-current-subtree-encryption' for more details." subtree-end)) (subtree-end-char (char-after (1- subtree-end))) (subtree-trailing-char (char-after subtree-end)) - ;; kluge - result-text needs to be nil, but we also want to + ;; kluge -- result-text needs to be nil, but we also want to ;; check for the error condition (result-text (if (or (string= "" subject-text) (string= "\n" subject-text)) @@ -5970,18 +5970,19 @@ If DECRYPT is true (default false), then decrypt instead of encrypt. FETCH-PASS (default false) forces fresh prompting for the passphrase. -KEY-TYPE indicates whether to use a 'symmetric or 'keypair cipher. +KEY-TYPE, either `symmetric' or `keypair', specifies which type +of cypher to use. FOR-KEY is human readable identification of the first of the user's eligible secret keys a keypair decryption targets, or else nil. -Optional RETRIED is for internal use - conveys the number of failed keys +Optional RETRIED is for internal use -- conveys the number of failed keys that have been solicited in sequence leading to this current call. Optional PASSPHRASE enables explicit delivery of the decryption passphrase, for verification purposes. -Optional REJECTED is for internal use - conveys the number of +Optional REJECTED is for internal use -- conveys the number of rejections due to matches against `allout-encryption-ciphertext-rejection-regexps', as limited by `allout-encryption-ciphertext-rejection-ceiling'. @@ -6078,13 +6079,13 @@ Returns the resulting string, or nil if the transformation fails." (if status (pgg-situate-output (point-min) (point-max)) - ;; failed - handle passphrase caching + ;; failed -- handle passphrase caching (if verifying (throw 'encryption-failed nil) (pgg-remove-passphrase-from-cache target-cache-id t) - (error "Symmetric-cipher %scryption failed - %s" + (error "Symmetric-cipher %scryption failed -- %s" (if decrypt "de" "en") - "try again with different passphrase.")))) + "try again with different passphrase")))) ;; encrypt 'keypair: ((not decrypt) @@ -6115,7 +6116,7 @@ Returns the resulting string, or nil if the transformation fails." 1 (- (point-max) (if decrypt 0 1)))) ) - ;; validate result - non-empty + ;; validate result -- non-empty (cond ((not result-text) (if verifying nil @@ -6151,7 +6152,7 @@ Returns the resulting string, or nil if the transformation fails." (string-match "[\C-a\C-k\C-o-\C-z\C-@]" result-text)) (error (concat "Encryption produced non-armored text, which" - "conflicts with allout mode - reconfigure!"))) + "conflicts with allout mode -- reconfigure!"))) ;; valid result and just verifying or non-symmetric: ((or verifying (not (equal key-type 'symmetric))) @@ -6160,7 +6161,7 @@ Returns the resulting string, or nil if the transformation fails." passphrase t)) result-text) - ;; valid result and regular symmetric - "register" + ;; valid result and regular symmetric -- "register" ;; passphrase with mnemonic aids/cache. (t (set-buffer allout-buffer) @@ -6191,7 +6192,7 @@ CACHE-ID is the cache id of the key for the passphrase. PROMPT-ID is the id for use when prompting the user. -KEY-TYPE is either 'symmetric or 'keypair. +KEY-TYPE is either `symmetric' or `keypair'. ALLOUT-BUFFER is the buffer containing the entry being en/decrypted. @@ -6254,7 +6255,7 @@ of the availability of a cached copy." (if (and (not confirmation) (if (yes-or-no-p (concat "Passphrase differs from established" - " - use new one instead? ")) + " -- use new one instead? ")) ;; deactivate password for subsequent ;; confirmation: (progn @@ -6264,11 +6265,11 @@ of the availability of a cached copy." t)) (progn (pgg-remove-passphrase-from-cache cache-id t) (error "Wrong passphrase.")))) - ;; No verifier string - force confirmation by repetition of + ;; No verifier string -- force confirmation by repetition of ;; (new) passphrase: ((or fetch-pass (not cached)) (pgg-remove-passphrase-from-cache cache-id t)))) - ;; confirmation vs new input - doing pgg-read-passphrase will do the + ;; confirmation vs new input -- doing pgg-read-passphrase will do the ;; right thing, in either case: (if (not confirmation) (setq confirmation @@ -6279,7 +6280,7 @@ of the availability of a cached copy." (if (equal got-pass confirmation) confirmation (if (yes-or-no-p (concat "spelling of original and" - " confirmation differ - retry? ")) + " confirmation differ -- retry? ")) (progn (setq retried (if retried (1+ retried) 1)) (pgg-remove-passphrase-from-cache cache-id t) ;; recurse to this routine: @@ -6301,9 +6302,9 @@ of the availability of a cached copy." (defun allout-encrypted-key-info (text) "Return a pair of the key type and identity of a recipient's secret key. -The key type is one of 'symmetric or 'keypair. +The key type is one of `symmetric' or `keypair'. -If 'keypair, and some of the user's secret keys are among those for which +If `keypair', and some of the user's secret keys are among those for which the message was encoded, return the identity of the first. Otherwise, return nil for the second item of the pair. @@ -6479,7 +6480,7 @@ must also have content." "Encrypt topics pending encryption except those containing exemption point. EXCEPT-MARK identifies a point whose containing topics should be excluded -from encryption. This supports 'except-current mode of +from encryption. This supports the `except-current' mode of `allout-encrypt-unencrypted-on-saves'. If a topic that is currently being edited was encrypted, we return a list @@ -6545,7 +6546,7 @@ setup for auto-startup." (if (allout-goto-prefix) t (allout-open-topic 2) - (insert (concat "Dummy outline topic header - see" + (insert (concat "Dummy outline topic header -- see" "`allout-mode' docstring: `^Hm'.")) (allout-adjust-file-variable "allout-layout" (or allout-layout '(-1 : 0)))))) @@ -6553,7 +6554,7 @@ setup for auto-startup." (defun allout-file-vars-section-data () "Return data identifying the file-vars section, or nil if none. -Returns list `(beginning-point prefix-string suffix-string)'." +Returns a list of the form (BEGINNING-POINT PREFIX-STRING SUFFIX-STRING)." ;; minimally gleaned from emacs 21.4 files.el hack-local-variables function. (let (beg prefix suffix) (save-excursion @@ -6655,7 +6656,7 @@ not its value." got) (dolist (sym configvar-value) (if (not (boundp sym)) - (if (yes-or-no-p (format "%s entry `%s' is unbound - remove it? " + (if (yes-or-no-p (format "%s entry `%s' is unbound -- remove it? " configvar-name sym)) (delq sym (symbol-value configvar-name))) (push (symbol-value sym) got))) @@ -6702,7 +6703,7 @@ Optional arg DO-DEFAULTING indicates to accept empty input (CR)." string "")) nil)))) - ;; got something out of loop - return it: + ;; got something out of loop -- return it: got) ) ;;;_ : Strings: @@ -6710,7 +6711,7 @@ Optional arg DO-DEFAULTING indicates to accept empty input (CR)." (defun regexp-sans-escapes (regexp &optional successive-backslashes) "Return a copy of REGEXP with all character escapes stripped out. -Representations of actual backslashes - '\\\\\\\\' - are left as a +Representations of actual backslashes -- '\\\\\\\\' -- are left as a single backslash. Optional arg SUCCESSIVE-BACKSLASHES is used internally for recursion." @@ -6809,7 +6810,7 @@ BEG and END default respectively to the beginning and end of buffer." (move-overlay o end (overlay-end o)) (delete-overlay o))))))) ) -;;;_ > copy-overlay if necessary - xemacs ~ 21.4 +;;;_ > copy-overlay if necessary -- xemacs ~ 21.4 (if (not (fboundp 'copy-overlay)) (defun copy-overlay (o) "Return a copy of overlay O." @@ -6821,7 +6822,7 @@ BEG and END default respectively to the beginning and end of buffer." (while props (overlay-put o1 (pop props) (pop props))) o1))) -;;;_ > add-to-invisibility-spec if necessary - xemacs ~ 21.4 +;;;_ > add-to-invisibility-spec if necessary -- xemacs ~ 21.4 (if (not (fboundp 'add-to-invisibility-spec)) (defun add-to-invisibility-spec (element) "Add ELEMENT to `buffer-invisibility-spec'. @@ -6831,14 +6832,14 @@ that can be added." (setq buffer-invisibility-spec (list t))) (setq buffer-invisibility-spec (cons element buffer-invisibility-spec)))) -;;;_ > remove-from-invisibility-spec if necessary - xemacs ~ 21.4 +;;;_ > remove-from-invisibility-spec if necessary -- xemacs ~ 21.4 (if (not (fboundp 'remove-from-invisibility-spec)) (defun remove-from-invisibility-spec (element) "Remove ELEMENT from `buffer-invisibility-spec'." (if (consp buffer-invisibility-spec) (setq buffer-invisibility-spec (delete element buffer-invisibility-spec))))) -;;;_ > move-beginning-of-line if necessary - older emacs, xemacs +;;;_ > move-beginning-of-line if necessary -- older emacs, xemacs (if (not (fboundp 'move-beginning-of-line)) (defun move-beginning-of-line (arg) "Move point to beginning of current line as displayed. @@ -6862,7 +6863,7 @@ To ignore intangibility, bind `inhibit-point-motion-hooks' to t." (skip-chars-backward "^\n")) (vertical-motion 0)) ) -;;;_ > move-end-of-line if necessary - older emacs, xemacs +;;;_ > move-end-of-line if necessary -- older emacs, xemacs (if (not (fboundp 'move-end-of-line)) (defun move-end-of-line (arg) "Move point to end of current line as displayed. @@ -6931,7 +6932,7 @@ To ignore intangibility, bind `inhibit-point-motion-hooks' to t." (isearch-repeat 'forward) (isearch-mode t))) -;;;_ #11 Unit tests - this should be last item before "Provide" +;;;_ #11 Unit tests -- this should be last item before "Provide" ;;;_ > allout-run-unit-tests () (defun allout-run-unit-tests () "Run the various allout unit tests." @@ -6947,11 +6948,11 @@ To ignore intangibility, bind `inhibit-point-motion-hooks' to t." (while (boundp name) (makunbound name))) ;;;_ > allout-test-resumptions () (defvar allout-tests-globally-unbound nil - "Fodder for allout resumptions tests - defvar just for byte compiler.") + "Fodder for allout resumptions tests -- defvar just for byte compiler.") (defvar allout-tests-globally-true nil - "Fodder for allout resumptions tests - defvar just for byte compiler.") + "Fodder for allout resumptions tests -- defvar just for byte compiler.") (defvar allout-tests-locally-true nil - "Fodder for allout resumptions tests - defvar just for byte compiler.") + "Fodder for allout resumptions tests -- defvar just for byte compiler.") (defun allout-test-resumptions () "Exercise allout resumptions." ;; for each resumption case, we also test that the right local/global @@ -6987,10 +6988,10 @@ To ignore intangibility, bind `inhibit-point-motion-hooks' to t." (allout-tests-obliterate-variable 'allout-tests-locally-true) (set (make-local-variable 'allout-tests-locally-true) t) (assert (not (default-boundp 'allout-tests-locally-true)) - nil (concat "Test setup mistake - variable supposed to" + nil (concat "Test setup mistake -- variable supposed to" " not have global binding, but it does.")) (assert (local-variable-p 'allout-tests-locally-true) - nil (concat "Test setup mistake - variable supposed to have" + nil (concat "Test setup mistake -- variable supposed to have" " local binding, but it lacks one.")) (allout-add-resumptions '(allout-tests-locally-true nil)) (assert (not (default-boundp 'allout-tests-locally-true))) From ea18b2b19e76217cc97565b4e50a98b4dd8aa196 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sun, 27 Jan 2008 01:07:20 +0000 Subject: [PATCH 372/439] More trivial doc fixes. Comment change. --- lisp/ChangeLog | 5 +++++ lisp/allout.el | 18 +++++++++--------- 2 files changed, 14 insertions(+), 9 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index e55184caea3..ab60c3e144b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-27 Richard Stallman + + * allout.el: Many doc fixes. + (allout-encrypt-string): Fix error message. + 2008-01-26 Alan Mackenzie * progmodes/cc-vars.el (c-hanging-braces-alist): new element for diff --git a/lisp/allout.el b/lisp/allout.el index 08c0c4a391f..075a41bdba1 100644 --- a/lisp/allout.el +++ b/lisp/allout.el @@ -982,7 +982,7 @@ invoking it directly." nil (setq allout-header-prefix leader) (if (not allout-old-style-prefixes) - ;; setting allout-primary-bullet makes the top level topics use - + ;; setting allout-primary-bullet makes the top level topics use -- ;; actually, be -- the special prefix: (setq allout-primary-bullet leader)) allout-header-prefix))) @@ -1444,7 +1444,7 @@ substition is used against the regexp matches, a la `replace-match'.") "Variable for regexps matching plaintext to remove before encryption. This is for the sake of redoing encryption in cases where the ciphertext -incidentally contains strings that would disrupt mode operation - +incidentally contains strings that would disrupt mode operation -- for example, a line that happens to look like an allout-mode topic prefix. Entries must be symbols that are bound to the desired regexp values. @@ -1637,7 +1637,7 @@ the following two lines in your Emacs init file: (put 'allout-exposure-category 'invisible 'allout) (put 'allout-exposure-category 'evaporate t) ;; XXX We use isearch-open-invisible *and* isearch-mode-end-hook. The - ;; latter would be sufficient, but it seems that a separate behavior - + ;; latter would be sufficient, but it seems that a separate behavior -- ;; the _transient_ opening of invisible text during isearch -- is keyed to ;; presence of the isearch-open-invisible property -- even though this ;; property controls the isearch _arrival_ behavior. This is the case at @@ -1734,7 +1734,7 @@ This is described further in the HOT-SPOT Operation section. \\[allout-rebullet-topic] `allout-rebullet-topic' Reconcile bullets of topic and its' offspring -- distinctive bullets are not changed, others are alternated according to nesting depth. -\\[allout-number-siblings] `allout-number-siblings' Number bullets of topic and siblings - +\\[allout-number-siblings] `allout-number-siblings' Number bullets of topic and siblings -- the offspring are not affected. With repeat count, revoke numbering. @@ -1940,7 +1940,7 @@ OPEN: A TOPIC that is not CLOSED, though its OFFSPRING or BODY may be." (cond - ;; Provision for v19.18, 19.19 bug - + ;; Provision for v19.18, 19.19 bug -- ;; Emacs v 19.18, 19.19 file-var code invokes prop-line-designated ;; modes twice when file is visited. We have to avoid toggling mode ;; off on second invocation, so we detect it as best we can, and @@ -2480,7 +2480,7 @@ Outermost is first." ;;;_ > allout-end-of-current-line () (defun allout-end-of-current-line () "Move to the end of line, past concealed text if any." - ;; XXX This is for symmetry with `allout-beginning-of-current-line' - + ;; XXX This is for symmetry with `allout-beginning-of-current-line' -- ;; `move-end-of-line' doesn't suffer the same problem as ;; `move-beginning-of-line'. (let ((inhibit-field-text-motion t)) @@ -3874,7 +3874,7 @@ Note that refill of indented paragraphs is not done." old-margin))) ;; Text starts left of old margin -- don't adjust: nil - ;; Text was hanging at or right of old left margin - + ;; Text was hanging at or right of old left margin -- ;; reindent it, preserving its existing indentation ;; beyond the old margin: (delete-region old-indent-begin old-indent-end) @@ -6087,7 +6087,7 @@ Returns the resulting string, or nil if the transformation fails." (if decrypt "de" "en") "try again with different passphrase")))) - ;; encrypt 'keypair: + ;; encrypt `keypair': ((not decrypt) (setq status @@ -6100,7 +6100,7 @@ Returns the resulting string, or nil if the transformation fails." (error (pgg-remove-passphrase-from-cache target-cache-id t) (error "encryption failed")))) - ;; decrypt 'keypair: + ;; decrypt `keypair': (t (setq status From b9712b1c0d45bc75408516e3f49457c84c60ccc1 Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Sun, 27 Jan 2008 11:06:45 +0000 Subject: [PATCH 373/439] (define-button-type): Clarify type of NAME in docstring. --- lisp/ChangeLog | 4 ++++ lisp/button.el | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index d6db38e535c..5ce427498ab 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-27 Thien-Thi Nguyen + + * button.el (define-button-type): Clarify type of NAME in docstring. + 2008-01-26 Stefan Monnier * server.el (server-buffer): New const. diff --git a/lisp/button.el b/lisp/button.el index 5129df9b44f..0b45f2cec41 100644 --- a/lisp/button.el +++ b/lisp/button.el @@ -116,7 +116,7 @@ Buttons inherit them by setting their `category' property to that symbol." ;;;###autoload (defun define-button-type (name &rest properties) - "Define a `button type' called NAME. + "Define a `button type' called NAME (a symbol). The remaining arguments form a sequence of PROPERTY VALUE pairs, specifying properties to use as defaults for buttons with this type \(a button's type may be set by giving it a `type' property when From 1a256502c72ce928f29f532a4df3cfb96b8161ac Mon Sep 17 00:00:00 2001 From: Thien-Thi Nguyen Date: Sun, 27 Jan 2008 11:08:21 +0000 Subject: [PATCH 374/439] (Button Types): For define-button-type, clarify type of NAME. --- doc/lispref/ChangeLog | 5 +++++ doc/lispref/display.texi | 3 ++- 2 files changed, 7 insertions(+), 1 deletion(-) diff --git a/doc/lispref/ChangeLog b/doc/lispref/ChangeLog index 21038e6e0e1..12539758018 100644 --- a/doc/lispref/ChangeLog +++ b/doc/lispref/ChangeLog @@ -1,3 +1,8 @@ +2008-01-27 Thien-Thi Nguyen + + * display.texi (Button Types): + For define-button-type, clarify type of NAME. + 2008-01-19 Martin Rudalics * buffers.texi (Buffer Modification): Fix typo. diff --git a/doc/lispref/display.texi b/doc/lispref/display.texi index b56d24da64e..ee3c828857a 100644 --- a/doc/lispref/display.texi +++ b/doc/lispref/display.texi @@ -4499,7 +4499,8 @@ so that it's easy to define special-purpose types of buttons for specific tasks. @defun define-button-type name &rest properties -Define a `button type' called @var{name}. The remaining arguments +Define a `button type' called @var{name} (a symbol). +The remaining arguments form a sequence of @var{property value} pairs, specifying default property values for buttons with this type (a button's type may be set by giving it a @code{type} property when creating the button, using From 3e5558010a804bfda1b176b93b81af4eceeb2cb7 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sun, 27 Jan 2008 13:57:49 +0000 Subject: [PATCH 375/439] *** empty log message *** --- lisp/ChangeLog | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5ce427498ab..2f734eacf03 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,15 @@ +2008-01-27 Alan Mackenzie + + * progmodes/cc-vars.el (c-hanging-braces-alist): new element for + arglist-cont-nonempty. + + * progmodes/cc-cmds.el (c-brace-newlines): Determine the newlines + for a brace with syntax arglist-cont-nonempty. + + * progmodes/cc-styles.el (c-style-alist): Add elements for + arglist-cont-nonempty into 5 styles (gnu, ellemtel, linux, python, + awk). + 2008-01-27 Thien-Thi Nguyen * button.el (define-button-type): Clarify type of NAME in docstring. From 4fae8922bea01886f04e534c26b12f2876fefb80 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sun, 27 Jan 2008 13:59:47 +0000 Subject: [PATCH 376/439] Introduce elements for the syntactic symbol arglist-cont-nonempty into c-hanging-braces-alist. Amend pertinent functions and 5 styles. --- lisp/progmodes/cc-cmds.el | 6 +++++- lisp/progmodes/cc-styles.el | 15 ++++++++++----- lisp/progmodes/cc-vars.el | 6 ++++-- 3 files changed, 19 insertions(+), 8 deletions(-) diff --git a/lisp/progmodes/cc-cmds.el b/lisp/progmodes/cc-cmds.el index 8d3facb08b6..1a2ee3f0ce5 100644 --- a/lisp/progmodes/cc-cmds.el +++ b/lisp/progmodes/cc-cmds.el @@ -524,7 +524,11 @@ inside a literal or a macro, nothing special happens." ;; This is the list of brace syntactic symbols that can hang. ;; If any new ones are added to c-offsets-alist, they should be ;; added here as well. - '(class-open class-close defun-open defun-close + ;; + ;; The order of this list is important; if SYNTAX has several + ;; elements, the element that "wins" is the earliest in SYMS. + '(arglist-cont-nonempty ; e.g. an array literal. + class-open class-close defun-open defun-close inline-open inline-close brace-list-open brace-list-close brace-list-intro brace-entry-open diff --git a/lisp/progmodes/cc-styles.el b/lisp/progmodes/cc-styles.el index 41f1836c0a4..26596e42ae8 100644 --- a/lisp/progmodes/cc-styles.el +++ b/lisp/progmodes/cc-styles.el @@ -58,7 +58,8 @@ '(("gnu" (c-basic-offset . 2) (c-comment-only-line-offset . (0 . 0)) - (c-hanging-braces-alist . ((substatement-open before after))) + (c-hanging-braces-alist . ((substatement-open before after) + (arglist-cont-nonempty))) (c-offsets-alist . ((statement-block-intro . +) (knr-argdecl-intro . 5) (substatement-open . +) @@ -170,7 +171,8 @@ (case-label . +) (access-label . -) (inclass . ++) - (inline-open . 0)))) + (inline-open . 0) + (arglist-cont-nonempty)))) ("linux" (c-basic-offset . 8) @@ -178,7 +180,8 @@ (c-hanging-braces-alist . ((brace-list-open) (brace-entry-open) (substatement-open after) - (block-close . c-snug-do-while))) + (block-close . c-snug-do-while) + (arglist-cont-nonempty))) (c-cleanup-list . (brace-else-brace)) (c-offsets-alist . ((statement-block-intro . +) (knr-argdecl-intro . 0) @@ -200,7 +203,8 @@ (brace-list-close) (brace-entry-open) (substatement-open after) - (block-close . c-snug-do-while))) + (block-close . c-snug-do-while) + (arglist-cont-nonempty))) (c-block-comment-prefix . "")) ("java" @@ -230,7 +234,8 @@ (c-hanging-braces-alist . ((defun-open after) (defun-close . c-snug-1line-defun-close) (substatement-open after) - (block-close . c-snug-do-while))) + (block-close . c-snug-do-while) + (arglist-cont-nonempty))) (c-hanging-semi&comma-criteria . nil) (c-cleanup-list . nil) ; You might want one-liner-defun here. (c-offsets-alist . ((statement-block-intro . +) diff --git a/lisp/progmodes/cc-vars.el b/lisp/progmodes/cc-vars.el index c217e6e6871..8b7b9cd24ee 100644 --- a/lisp/progmodes/cc-vars.el +++ b/lisp/progmodes/cc-vars.el @@ -729,7 +729,8 @@ involve auto-newline inserted newlines: (module-open after) (composition-open after) (inexpr-class-open after) - (inexpr-class-close before)) + (inexpr-class-close before) + (arglist-cont-nonempty)) "*Controls the insertion of newlines before and after braces when the auto-newline feature is active. This variable contains an association list with elements of the following form: @@ -783,7 +784,8 @@ syntactic context for the brace line." namespace-open namespace-close module-open module-close composition-open composition-close - inexpr-class-open inexpr-class-close))) + inexpr-class-open inexpr-class-close + arglist-cont-nonempty))) :group 'c) (defcustom c-max-one-liner-length 80 From 475b5907736f25b9b67641c1698937cc0ca76b83 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 27 Jan 2008 15:37:26 +0000 Subject: [PATCH 377/439] * server.el (server-process-filter): Check for non-nil before calling file-directory-p. --- lisp/ChangeLog | 7 ++++++- lisp/server.el | 3 ++- 2 files changed, 8 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 2f734eacf03..679784fbcd0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-27 Dan Nicolaescu + + * server.el (server-process-filter): Check for non-nil before + calling file-directory-p. + 2008-01-27 Alan Mackenzie * progmodes/cc-vars.el (c-hanging-braces-alist): new element for @@ -5,7 +10,7 @@ * progmodes/cc-cmds.el (c-brace-newlines): Determine the newlines for a brace with syntax arglist-cont-nonempty. - + * progmodes/cc-styles.el (c-style-alist): Add elements for arglist-cont-nonempty into 5 styles (gnu, ellemtel, linux, python, awk). diff --git a/lisp/server.el b/lisp/server.el index d3606f5c860..ad4608f2fd2 100644 --- a/lisp/server.el +++ b/lisp/server.el @@ -952,7 +952,8 @@ The following commands are accepted by the client: ;; Use the same cwd as the emacsclient, if possible, so ;; relative file names work correctly, even in `eval'. (let ((default-directory - (if (file-directory-p dir) dir default-directory))) + (if (and dir (file-directory-p dir)) + dir default-directory))) (server-execute proc files nowait commands dontkill frame tty-name)))))) From 59e3a79d2bf012db203905ea01846ba951a286d2 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 27 Jan 2008 15:59:30 +0000 Subject: [PATCH 378/439] Remove some unused macros. --- admin/CPP-DEFINES | 4 ---- 1 file changed, 4 deletions(-) diff --git a/admin/CPP-DEFINES b/admin/CPP-DEFINES index 4d1d647f03e..7550db0ebd0 100644 --- a/admin/CPP-DEFINES +++ b/admin/CPP-DEFINES @@ -176,7 +176,6 @@ LONG_ALIGN L_SET MAIL_PROGRAM_NAME MAIL_USE_FLOCK -MAKE_PARALLEL MAXNAMLEN MEMMOVE_MISSING MEMORY_IN_STRING_H @@ -209,9 +208,6 @@ NO_UNION_TYPE NSIG NSIG_MINIMUM OBJECTS_MACHINE -OLDXMENU_OPTIONS -OLD_PROGRAM_H -OLD_SECTION_H ORDINARY_LINK OSF1 O_NDELAY From 9c28b587abe1ebf89059753b6983d597402042d8 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 27 Jan 2008 16:06:02 +0000 Subject: [PATCH 379/439] * configure.in: Update comment. * Makefile.in: Remove references to unused macros. --- ChangeLog | 4 ++++ configure.in | 3 +-- src/ChangeLog | 4 ++++ src/Makefile.in | 14 ++------------ 4 files changed, 11 insertions(+), 14 deletions(-) diff --git a/ChangeLog b/ChangeLog index 1f9820d386a..6932c0f904d 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,7 @@ +2008-01-27 Dan Nicolaescu + + * configure.in: Update comment. + 2008-01-26 Glenn Morris * configure.in (--without-gcc): By default, neither off nor on. diff --git a/configure.in b/configure.in index abf67196b74..6b9de40756a 100644 --- a/configure.in +++ b/configure.in @@ -2676,8 +2676,7 @@ AH_BOTTOM([ #endif /* Multi-tty support relies on MULTI_KBOARD. It seems safe to turn it - on unconditionally. Note that src/s/darwin.h disables this at - present. */ + on unconditionally. */ #ifndef MULTI_KBOARD #define MULTI_KBOARD #endif diff --git a/src/ChangeLog b/src/ChangeLog index b3ab1ad9904..114bbc5b0e7 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-27 Dan Nicolaescu + + * Makefile.in: Remove references to unused macros. + 2008-01-26 Eli Zaretskii * w32.c (g_b_init_get_sid_sub_authority) diff --git a/src/Makefile.in b/src/Makefile.in index 88acbbf802f..b8f62055f07 100644 --- a/src/Makefile.in +++ b/src/Makefile.in @@ -993,12 +993,7 @@ ${etc}DOC: ${libsrc}make-docfile${EXEEXT} ${obj} ${shortlisp} ${SOME_MACHINE_LIS ${libsrc}make-docfile${EXEEXT}: cd ${libsrc}; ${MAKE} ${MFLAGS} make-docfile${EXEEXT} -/* Some systems define this to cause parallel Make-ing. */ -#ifndef MAKE_PARALLEL -#define MAKE_PARALLEL -#endif - -temacs${EXEEXT}: MAKE_PARALLEL $(LOCALCPP) $(STARTFILES) stamp-oldxmenu ${obj} ${otherobj} OBJECTS_MACHINE prefix-args${EXEEXT} +temacs${EXEEXT}: $(LOCALCPP) $(STARTFILES) stamp-oldxmenu ${obj} ${otherobj} OBJECTS_MACHINE prefix-args${EXEEXT} echo "${obj} ${otherobj} " OBJECTS_MACHINE > buildobj.lst $(LD) YMF_PASS_LDFLAGS (${STARTFLAGS} ${TEMACS_LDFLAGS}) $(LDFLAGS) \ -o temacs ${STARTFILES} ${obj} ${otherobj} \ @@ -1010,11 +1005,6 @@ temacs${EXEEXT}: MAKE_PARALLEL $(LOCALCPP) $(STARTFILES) stamp-oldxmenu ${obj} $ prefix-args${EXEEXT}: prefix-args.c $(config_h) $(CC) $(ALL_CFLAGS) $(LDFLAGS) ${srcdir}/prefix-args.c -o prefix-args -/* Do not lose if this was not defined. */ -#ifndef OLDXMENU_OPTIONS -#define OLDXMENU_OPTIONS -#endif - #if defined (HAVE_X_WINDOWS) && defined (HAVE_X11) && defined (HAVE_MENUS) && ! defined (HAVE_GTK) /* We use stamp-xmenu with these two deps @@ -1060,7 +1050,7 @@ C_SWITCH_X_SITE_1 = C_SWITCH_X_SITE C_SWITCH_X_MACHINE_1 = C_SWITCH_X_MACHINE C_SWITCH_X_SYSTEM_1 = C_SWITCH_X_SYSTEM really-oldXMenu: - cd ${oldXMenudir}; ${MAKE} ${MFLAGS} OLDXMENU_OPTIONS \ + cd ${oldXMenudir}; ${MAKE} ${MFLAGS} \ CC='${CC}' CFLAGS='${CFLAGS}' MAKE='${MAKE}' \ "C_SWITCH_X_SITE=$(C_SWITCH_X_SITE_1)" \ "C_SWITCH_X_MACHINE=$(C_SWITCH_X_MACHINE_1)" \ From c9d8f7462c9e216429c91aa29c48e2b675a62732 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Sun, 27 Jan 2008 16:15:43 +0000 Subject: [PATCH 380/439] *** empty log message *** --- doc/misc/ChangeLog | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index 73d1459f8ff..3c179467fa2 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,8 @@ +2008-01-27 Michael Albinus + + * tramp.texi (Inline methods): The hostname of the su(do)? methods + must be a local host. + 2008-01-26 Michael Olson * erc.texi: Update version for ERC 5.3 release. @@ -8,7 +13,7 @@ 2008-01-24 Karl Berry * info.texi (Search Index), - (Search Text): mention the command character in the section name, + (Search Text): mention the command character in the section name, a la the (Go to node) node. 2008-01-21 Michael Albinus From 4605b7cdc1418949633408e60907e2ef41b4da33 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Sun, 27 Jan 2008 16:17:08 +0000 Subject: [PATCH 381/439] * tramp.texi (Inline methods): The hostname of the su(do)? methods must be a local host. --- doc/misc/tramp.texi | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/doc/misc/tramp.texi b/doc/misc/tramp.texi index 87164bfce31..331ec594bf0 100644 --- a/doc/misc/tramp.texi +++ b/doc/misc/tramp.texi @@ -672,8 +672,10 @@ as the @option{rsh} method. This method does not connect to a remote host at all, rather it uses the @command{su} program to allow you to edit files as another user. -With other words, a specified host name in the file name is silently -ignored. +That means, the specified host name in the file name must be either +@samp{localhost} or the host name as returned by the function +@command{(system-name)}. For an exception of this rule see +@ref{Multi-hops}. @item @option{sudo} From 2991e49f20dc4a7af55cc94802f3c69c47679c76 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Sun, 27 Jan 2008 16:20:57 +0000 Subject: [PATCH 382/439] * net/tramp.el (tramp-compute-multi-hops): In case of su(do)? methods, the host name must be a local host. --- lisp/ChangeLog | 5 +++++ lisp/net/tramp.el | 21 +++++++++++++++++++++ 2 files changed, 26 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 679784fbcd0..20478b7511c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-27 Michael Albinus + + * net/tramp.el (tramp-compute-multi-hops): In case of su(do)? + methods, the host name must be a local host. + 2008-01-27 Dan Nicolaescu * server.el (server-process-filter): Check for non-nil before diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index 9fba537f006..b9e6a279644 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -6052,6 +6052,27 @@ Gateway hops are already opened." "Method `%s' is not supported for multi-hops." (tramp-file-name-method item))))) + ;; In case the host name is not used for the remote shell + ;; command, the user could be misguided by applying a random + ;; hostname. + (let* ((v (car target-alist)) + (method (tramp-file-name-method v)) + (host (tramp-file-name-host v))) + (unless + (or + ;; There are multi-hops. + (cdr target-alist) + ;; The host name is used for the remote shell command. + (member + '("%h") (tramp-get-method-parameter method 'tramp-login-args)) + ;; The host is local. We cannot use `tramp-local-host-p' + ;; here, because it opens a connection as well. + (string-match + (concat "^" (regexp-opt (list "localhost" (system-name)) t) "$") + host)) + (tramp-error + v 'file-error "Wrong hostname `%s' for method `%s'" host method))) + ;; Result. target-alist)) From 3f08440f1d8ff99145b1eb2868e06c129817e578 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 27 Jan 2008 16:31:09 +0000 Subject: [PATCH 383/439] Add TODO item about not defaulting to RCS. --- lisp/ChangeLog | 2 ++ lisp/vc.el | 3 +++ 2 files changed, 5 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 20478b7511c..c0eae49b68c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -5,6 +5,8 @@ 2008-01-27 Dan Nicolaescu + * vc.el: Add TODO item about not defaulting to RCS. + * server.el (server-process-filter): Check for non-nil before calling file-directory-p. diff --git a/lisp/vc.el b/lisp/vc.el index ce212314491..102eeef0fbf 100644 --- a/lisp/vc.el +++ b/lisp/vc.el @@ -566,6 +566,9 @@ ;; ;; - "snapshots" should be renamed to "branches", and thoroughly reworked. ;; +;; - do not default to RCS anymore when the current directory is not +;; controlled by any VCS and the user does C-x v v +;; ;;; Code: From a0573493acf669b92b7b7c8d504131bf3e4aff34 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 27 Jan 2008 16:31:44 +0000 Subject: [PATCH 384/439] Remove more unused macros. --- admin/CPP-DEFINES | 9 --------- 1 file changed, 9 deletions(-) diff --git a/admin/CPP-DEFINES b/admin/CPP-DEFINES index 7550db0ebd0..b2c11459c85 100644 --- a/admin/CPP-DEFINES +++ b/admin/CPP-DEFINES @@ -60,7 +60,6 @@ BAUD_CONVERT BROKEN_FIONREAD BROKEN_SELECT_NON_X BROKEN_SIGIO -BROKEN_START BROKEN_TIOCGETC BROKEN_TIOCGWINSZ BSD4_2 @@ -93,9 +92,6 @@ DOT_GLOBAL_START DUMMIES EEOF ELF -ERROR0 -ERROR1 -ERROR2 EXEC_HDR_TYPE EXEC_MAGIC EXEC_PAGESIZE @@ -172,7 +168,6 @@ LIB_X11_LIB LINKER LOAD_AVE_CVT LOAD_AVE_TYPE -LONG_ALIGN L_SET MAIL_PROGRAM_NAME MAIL_USE_FLOCK @@ -181,7 +176,6 @@ MEMMOVE_MISSING MEMORY_IN_STRING_H MKDIR_PROTOTYPE MOTIF -M_TERMINFO NARROWPROTO NEED_ERRNO NEED_NET_ERRNO_H @@ -218,8 +212,6 @@ PNTR_COMPARISON_TYPE POSIX_SIGNALS PREFER_VSUSP PTY_ITERATION -PTY_MAJOR -PTY_MINOR PTY_NAME_SPRINTF PTY_OPEN PTY_TTY_NAME_SPRINTF @@ -287,7 +279,6 @@ XSET XUINT X_DEFAULT_FONT _ABIN32 -_CX_UX _MIPS_SZLONG _POSIX_SOURCE __main From f6558e2d480575a5398a9df904c7dae69064f79f Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sun, 27 Jan 2008 16:56:04 +0000 Subject: [PATCH 385/439] Correct typos, enhance comments. --- lisp/progmodes/cc-awk.el | 2 +- lisp/progmodes/cc-engine.el | 13 +++++++------ 2 files changed, 8 insertions(+), 7 deletions(-) diff --git a/lisp/progmodes/cc-awk.el b/lisp/progmodes/cc-awk.el index d9a70558697..b361585422a 100644 --- a/lisp/progmodes/cc-awk.el +++ b/lisp/progmodes/cc-awk.el @@ -478,7 +478,7 @@ (defun c-awk-get-NL-prop-prev-line (&optional do-lim) ;; Get the c-awk-NL-prop text-property from the previous line, calculating - ;; it if necessary. Return nil if we're at BOB. + ;; it if necessary. Return nil if we're already at BOB. ;; See c-awk-after-if-for-while-condition-p for a description of DO-LIM. ;; ;; This function might do hidden buffer changes. diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 8596aaad4c2..2a224d956d1 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el @@ -5091,7 +5091,8 @@ comment at the start of cc-engine.el for more info." ;; ;; The point is left at the first token after the first complete ;; declarator, if there is one. The return value is a cons where - ;; the car is the position of the first token in the declarator. + ;; the car is the position of the first token in the declarator. (See + ;; below for the cdr.) ;; Some examples: ;; ;; void foo (int a, char *b) stuff ... @@ -5115,9 +5116,9 @@ comment at the start of cc-engine.el for more info." ;; Foo::Foo (int b) : Base (b) {} ;; car ^ ^ point ;; - ;; The cdr of the return value is non-nil if a - ;; `c-typedef-decl-kwds' specifier is found in the declaration, - ;; i.e. the declared identifier(s) are types. + ;; The cdr of the return value is non-nil iff a `c-typedef-decl-kwds' + ;; specifier (e.g. class, struct, enum, typedef) is found in the + ;; declaration, i.e. the declared identifier(s) are types. ;; ;; If a cast is parsed: ;; @@ -5132,7 +5133,7 @@ comment at the start of cc-engine.el for more info." ;; the first token in (the visible part of) the buffer. ;; ;; CONTEXT is a symbol that describes the context at the point: - ;; 'decl In a comma-separatded declaration context (typically + ;; 'decl In a comma-separated declaration context (typically ;; inside a function declaration arglist). ;; '<> In an angle bracket arglist. ;; 'arglist Some other type of arglist. @@ -5873,7 +5874,7 @@ comment at the start of cc-engine.el for more info." (setq c-record-type-identifiers save-rec-type-ids c-record-ref-identifiers save-rec-ref-ids) nil)))) - + (defun c-forward-label (&optional assume-markup preceding-token-end limit) ;; Assuming that point is at the beginning of a token, check if it starts a ;; label and if so move over it and return non-nil (t in default situations, From b931ca952558b2deb06ce2a390acc329491d9b33 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sun, 27 Jan 2008 17:01:10 +0000 Subject: [PATCH 386/439] *** empty log message *** --- lisp/ChangeLog | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c0eae49b68c..48c5455ea3b 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-27 Alan Mackenzie + + * progmodes/cc-awk.el, progmodes/cc-engine.el: Correct typos, + enhance comments. + 2008-01-27 Michael Albinus * net/tramp.el (tramp-compute-multi-hops): In case of su(do)? From 5da46258169a4eaf77fc2eb51a826223257f8c30 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sun, 27 Jan 2008 17:02:06 +0000 Subject: [PATCH 387/439] Correct typos, enhance comments. --- lisp/progmodes/cc-engine.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 2a224d956d1..929b000b83f 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el @@ -5874,7 +5874,7 @@ comment at the start of cc-engine.el for more info." (setq c-record-type-identifiers save-rec-type-ids c-record-ref-identifiers save-rec-ref-ids) nil)))) - + (defun c-forward-label (&optional assume-markup preceding-token-end limit) ;; Assuming that point is at the beginning of a token, check if it starts a ;; label and if so move over it and return non-nil (t in default situations, From 022d0cf4cd59ab9f19269b14c9b9e25480b8cd70 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Sun, 27 Jan 2008 17:03:43 +0000 Subject: [PATCH 388/439] Correct typos, enhance comments. --- lisp/progmodes/cc-awk.el | 2 +- lisp/progmodes/cc-engine.el | 11 ++++++----- 2 files changed, 7 insertions(+), 6 deletions(-) diff --git a/lisp/progmodes/cc-awk.el b/lisp/progmodes/cc-awk.el index d9a70558697..b361585422a 100644 --- a/lisp/progmodes/cc-awk.el +++ b/lisp/progmodes/cc-awk.el @@ -478,7 +478,7 @@ (defun c-awk-get-NL-prop-prev-line (&optional do-lim) ;; Get the c-awk-NL-prop text-property from the previous line, calculating - ;; it if necessary. Return nil if we're at BOB. + ;; it if necessary. Return nil if we're already at BOB. ;; See c-awk-after-if-for-while-condition-p for a description of DO-LIM. ;; ;; This function might do hidden buffer changes. diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 9718bd0ddc9..322771f0dab 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el @@ -5094,7 +5094,8 @@ comment at the start of cc-engine.el for more info." ;; ;; The point is left at the first token after the first complete ;; declarator, if there is one. The return value is a cons where - ;; the car is the position of the first token in the declarator. + ;; the car is the position of the first token in the declarator. (See + ;; below for the cdr.) ;; Some examples: ;; ;; void foo (int a, char *b) stuff ... @@ -5118,9 +5119,9 @@ comment at the start of cc-engine.el for more info." ;; Foo::Foo (int b) : Base (b) {} ;; car ^ ^ point ;; - ;; The cdr of the return value is non-nil if a - ;; `c-typedef-decl-kwds' specifier is found in the declaration, - ;; i.e. the declared identifier(s) are types. + ;; The cdr of the return value is non-nil iff a `c-typedef-decl-kwds' + ;; specifier (e.g. class, struct, enum, typedef) is found in the + ;; declaration, i.e. the declared identifier(s) are types. ;; ;; If a cast is parsed: ;; @@ -5135,7 +5136,7 @@ comment at the start of cc-engine.el for more info." ;; the first token in (the visible part of) the buffer. ;; ;; CONTEXT is a symbol that describes the context at the point: - ;; 'decl In a comma-separatded declaration context (typically + ;; 'decl In a comma-separated declaration context (typically ;; inside a function declaration arglist). ;; '<> In an angle bracket arglist. ;; 'arglist Some other type of arglist. From 2aea825c389aada237f810582edbaa337435ea82 Mon Sep 17 00:00:00 2001 From: Andreas Schwab Date: Sun, 27 Jan 2008 18:42:21 +0000 Subject: [PATCH 389/439] Regenerate. --- configure | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/configure b/configure index b2ebd636419..1a4d5b9c165 100755 --- a/configure +++ b/configure @@ -412,10 +412,10 @@ else fi test \$exitcode = 0") || { - echo Please tell bug-autoconf@gnu.org about your system, - echo including any error possibly output before this message. - echo This can help us improve future autoconf versions. - echo Configuration will now proceed without shell functions. + echo No shell found that supports shell functions. + echo Please tell autoconf@gnu.org about your system, + echo including any error possibly output before this + echo message } @@ -1336,7 +1336,7 @@ Optional Features: Optional Packages: --with-PACKAGE[=ARG] use PACKAGE [ARG=yes] --without-PACKAGE do not use PACKAGE (same as --with-PACKAGE=no) - --without-gcc don't use GCC to compile Emacs if GCC is found + --without-gcc don't use GCC to compile Emacs even if GCC is found --without-pop don't support POP mail retrieval with movemail --with-kerberos support Kerberos-authenticated POP --with-kerberos5 support Kerberos version 5 authenticated POP @@ -1355,7 +1355,7 @@ Optional Packages: don't use Motif or Xaw3d scroll bars --without-xaw3d don't use Xaw3d --without-xim don't use X11 XIM - --with-carbon use Carbon GUI on Mac OS X. **UNSUPPORTED!** + --with-carbon use Carbon GUI on Mac OS X. This is unsupported! --without-gpm don't use -lgpm for mouse support on a GNU/Linux console --with-dbus compile with D-Bus support @@ -1842,8 +1842,6 @@ gameuser=games # Check whether --with-gcc was given. if test "${with_gcc+set}" = set; then withval=$with_gcc; -else - with_gcc=yes fi From a28ed9e54738bf5a52d2c03f887e74ebf2c1c7c2 Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 27 Jan 2008 19:48:44 +0000 Subject: [PATCH 390/439] * add-log.el (change-log-search-file-name, change-log-find-file): New function. (change-log-font-lock-keywords): Move file name matching ... (change-log-file-names-re): ... here. New defconst. (change-log-mode-map): New binding C-c C-f to change-log-find-file. --- lisp/ChangeLog | 8 ++++++++ lisp/add-log.el | 23 +++++++++++++++++++++-- 2 files changed, 29 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 48c5455ea3b..c2aeff86f93 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,11 @@ +2007-01-27 Jan Nieuwenhuizen + + * add-log.el (change-log-search-file-name, change-log-find-file): + New function. + (change-log-font-lock-keywords): Move file name matching ... + (change-log-file-names-re): ... here. New defconst. + (change-log-mode-map): New binding C-c C-f to change-log-find-file. + 2008-01-27 Alan Mackenzie * progmodes/cc-awk.el, progmodes/cc-engine.el: Correct typos, diff --git a/lisp/add-log.el b/lisp/add-log.el index a52aa519819..534dbd0746d 100644 --- a/lisp/add-log.el +++ b/lisp/add-log.el @@ -240,8 +240,10 @@ Note: The search is conducted only within 10%, at the beginning of the file." ;; backward-compatibility alias (put 'change-log-acknowledgement-face 'face-alias 'change-log-acknowledgement) +(defconst change-log-file-names-re "^\\( +\\|\t\\)\\* \\([^ ,:([\n]+\\)") + (defvar change-log-font-lock-keywords - '(;; + `(;; ;; Date lines, new (2000-01-01) and old (Sat Jan 1 00:00:00 2000) styles. ;; Fixme: this regepx is just an approximate one and may match ;; wrongly with a non-date line existing as a random note. In @@ -255,7 +257,7 @@ Note: The search is conducted only within 10%, at the beginning of the file." (2 'change-log-email))) ;; ;; File names. - ("^\\( +\\|\t\\)\\* \\([^ ,:([\n]+\\)" + (,change-log-file-names-re (2 'change-log-file) ;; Possibly further names in a list: ("\\=, \\([^ ,:([\n]+\\)" nil nil (1 'change-log-file)) @@ -287,10 +289,27 @@ Note: The search is conducted only within 10%, at the beginning of the file." 3 'change-log-acknowledgement)) "Additional expressions to highlight in Change Log mode.") +(defun change-log-search-file-name (where) + "Return the file-name for the change under point." + (save-excursion + (goto-char where) + (beginning-of-line 1) + (re-search-forward change-log-file-names-re) + (match-string 2))) + +(defun change-log-find-file () + "Visit the file for the change under point." + (interactive) + (let ((file (change-log-search-file-name (point)))) + (if (and file (file-exists-p file)) + (find-file file) + (message "No such file or directory: ~s" file)))) + (defvar change-log-mode-map (let ((map (make-sparse-keymap))) (define-key map [?\C-c ?\C-p] 'add-log-edit-prev-comment) (define-key map [?\C-c ?\C-n] 'add-log-edit-next-comment) + (define-key map [?\C-c ?\C-f] 'change-log-find-file) map) "Keymap for Change Log major mode.") From 000605b34b4d18d73bbde8021124ca164d10fa1f Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 27 Jan 2008 19:52:46 +0000 Subject: [PATCH 391/439] (change-log-search-file-name): Work harder to find the correct file name. (change-log-find-file): Fix typo. (change-log-start-entry-re): Move definition earlier. --- lisp/ChangeLog | 7 +++++++ lisp/add-log.el | 31 ++++++++++++++++++++++++++----- 2 files changed, 33 insertions(+), 5 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c2aeff86f93..c84ffb934b3 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2008-01-27 Dan Nicolaescu + + * add-log.el (change-log-search-file-name): Work harder to find + the correct file name. + (change-log-find-file): Fix typo. + (change-log-start-entry-re): Move definition earlier. + 2007-01-27 Jan Nieuwenhuizen * add-log.el (change-log-search-file-name, change-log-find-file): diff --git a/lisp/add-log.el b/lisp/add-log.el index 534dbd0746d..c9fdb34bc9a 100644 --- a/lisp/add-log.el +++ b/lisp/add-log.el @@ -241,6 +241,7 @@ Note: The search is conducted only within 10%, at the beginning of the file." (put 'change-log-acknowledgement-face 'face-alias 'change-log-acknowledgement) (defconst change-log-file-names-re "^\\( +\\|\t\\)\\* \\([^ ,:([\n]+\\)") +(defconst change-log-start-entry-re "^\\sw.........[0-9:+ ]*") (defvar change-log-font-lock-keywords `(;; @@ -294,8 +295,30 @@ Note: The search is conducted only within 10%, at the beginning of the file." (save-excursion (goto-char where) (beginning-of-line 1) - (re-search-forward change-log-file-names-re) - (match-string 2))) + (if (looking-at change-log-start-entry-re) + ;; We are at the start of an entry, search forward for a file + ;; name. + (progn + (re-search-forward change-log-file-names-re nil t) + (match-string 2)) + (if (looking-at change-log-file-names-re) + ;; We found a file name. + (match-string 2) + ;; Look backwards for either a file name or the log entry start. + (if (re-search-backward + (concat "\\(" change-log-start-entry-re + "\\)\\|\\(" + change-log-file-names-re "\\)") nil t) + (if (match-beginning 1) + ;; We got the start of the entry, look forward for a + ;; file name. + (progn + (re-search-forward change-log-file-names-re nil t) + (match-string 2)) + (match-string 4)) + ;; We must be before any file name, look forward. + (re-search-forward change-log-file-names-re nil t) + (match-string 2)))))) (defun change-log-find-file () "Visit the file for the change under point." @@ -303,7 +326,7 @@ Note: The search is conducted only within 10%, at the beginning of the file." (let ((file (change-log-search-file-name (point)))) (if (and file (file-exists-p file)) (find-file file) - (message "No such file or directory: ~s" file)))) + (message "No such file or directory: %s" file)))) (defvar change-log-mode-map (let ((map (make-sparse-keymap))) @@ -1120,8 +1143,6 @@ Has a preference of looking backwards." (change-log-get-method-definition-1 "")) (concat change-log-get-method-definition-md "]")))))) -(defconst change-log-start-entry-re "^\\sw.........[0-9:+ ]*") - (defun change-log-sortable-date-at () "Return date of log entry in a consistent form for sorting. Point is assumed to be at the start of the entry." From e8cbfb8dc7235ddbec9a43155fa604b2f349e31e Mon Sep 17 00:00:00 2001 From: Dan Nicolaescu Date: Sun, 27 Jan 2008 19:58:42 +0000 Subject: [PATCH 392/439] Add info about C-c C-f in change-log-mode. --- etc/NEWS | 3 +++ 1 file changed, 3 insertions(+) diff --git a/etc/NEWS b/etc/NEWS index 22e896db16c..e9e281e9bca 100644 --- a/etc/NEWS +++ b/etc/NEWS @@ -223,6 +223,9 @@ same host, based on messages. See the manual for further details. * Changes in Specialized Modes and Packages in Emacs 23.1 +** ChangeLog now has function bound to C-c C-f that finds the file in +the current log entry. + ** abbrev was rewritten in Elisp and extended with more flexibility. *** New functions: abbrev-get, abbrev-put, abbrev-table-get, abbrev-table-put, abbrev-table-p. From 3621231b47a11a501e3aa75c7562071d2f0199c5 Mon Sep 17 00:00:00 2001 From: Nick Roberts Date: Sun, 27 Jan 2008 20:51:19 +0000 Subject: [PATCH 393/439] *** empty log message *** --- lisp/ChangeLog | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ab60c3e144b..02b3cef22bf 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-27 Nick Roberts + + * progmodes/gdb-ui.el (gdb-create-define-alist): Don't call + gdb-cpp-define-alist-program if file is nil (currently only + " *partial-output-..."). + 2008-01-27 Richard Stallman * allout.el: Many doc fixes. From f43ad7374fe3caf1e89cd6ede0f83769ef30998b Mon Sep 17 00:00:00 2001 From: Nick Roberts Date: Sun, 27 Jan 2008 20:53:02 +0000 Subject: [PATCH 394/439] (gdb-create-define-alist): Don't call gdb-cpp-define-alist-program if file is nil (currently only " *partial-output-..."). --- lisp/progmodes/gdb-ui.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/progmodes/gdb-ui.el b/lisp/progmodes/gdb-ui.el index d85bf23c7c5..4e6727cdbad 100644 --- a/lisp/progmodes/gdb-ui.el +++ b/lisp/progmodes/gdb-ui.el @@ -435,11 +435,11 @@ otherwise do not." (output (with-output-to-string (with-current-buffer standard-output - (call-process shell-file-name - (if (file-exists-p file) file nil) + (and file (file-exists-p file) + (call-process shell-file-name file (list t nil) nil "-c" (concat gdb-cpp-define-alist-program " " - gdb-cpp-define-alist-flags))))) + gdb-cpp-define-alist-flags)))))) (define-list (split-string output "\n" t)) (name)) (setq gdb-define-alist nil) (dolist (define define-list) From 5e613c0246a7b7e83a37982265309ed3ffb5ce0d Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sun, 27 Jan 2008 22:19:43 +0000 Subject: [PATCH 395/439] (view-buffer): Explain in doc-string why exit-action should not be set to kill-buffer. --- lisp/view.el | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/lisp/view.el b/lisp/view.el index 410b8ecc6a6..c7a8d3d54c9 100644 --- a/lisp/view.el +++ b/lisp/view.el @@ -332,7 +332,12 @@ This command runs the normal hook `view-mode-hook'. Optional argument EXIT-ACTION is either nil or a function with buffer as argument. This function is called when finished viewing buffer. Use -this argument instead of explicitly setting `view-exit-action'." +this argument instead of explicitly setting `view-exit-action'. + +Do not set EXIT-ACTION to `kill-buffer' when BUFFER visits a +file: Users may suspend viewing in order to modify the buffer. +Exiting View mode will then discard the user's edits. Setting +EXIT-ACTION to `kill-buffer-if-not-modified' avoids this." (interactive "bView buffer: ") (let ((undo-window (list (window-buffer) (window-start) (window-point)))) (switch-to-buffer buffer) From 687422dffaffc4d763733b6e4f05df3b209b1d57 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sun, 27 Jan 2008 22:20:43 +0000 Subject: [PATCH 396/439] (archive-extract): Use kill-buffer-if-not-modified as exit-action when viewing the buffer. --- lisp/arc-mode.el | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/lisp/arc-mode.el b/lisp/arc-mode.el index 504cbce962f..8a01ed3cda6 100644 --- a/lisp/arc-mode.el +++ b/lisp/arc-mode.el @@ -995,7 +995,8 @@ using `make-temp-file', and the generated name is returned." (archive-maybe-update t)) (or (not (buffer-name buffer)) (cond - (view-p (view-buffer buffer (and just-created 'kill-buffer))) + (view-p (view-buffer + buffer (and just-created 'kill-buffer-if-not-modified))) ((eq other-window-p 'display) (display-buffer buffer)) (other-window-p (switch-to-buffer-other-window buffer)) (t (switch-to-buffer buffer)))))) @@ -1952,7 +1953,7 @@ This doesn't recover lost files, it just undoes changes in the buffer itself." (archive-rar-extract tmpfile name)) (if tmpbuf (kill-buffer tmpbuf)) (delete-file tmpfile)))) - + ;; ------------------------------------------------------------------------- ;; This line was a mistake; it is kept now for compatibility. From a51b80e7a7dd10a97761ff750deb95310412ff89 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Sun, 27 Jan 2008 22:21:45 +0000 Subject: [PATCH 397/439] (tar-extract): Use kill-buffer-if-not-modified as exit-action when viewing the buffer. --- lisp/ChangeLog | 9 +++++++++ lisp/tar-mode.el | 3 ++- 2 files changed, 11 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c84ffb934b3..f54b105032d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,12 @@ +2008-01-27 Martin Rudalics + + * view.el (view-buffer): Explain in doc-string why exit-action + should not be set to kill-buffer. + + * arc-mode.el (archive-extract): + * tar-mode.el (tar-extract): Use kill-buffer-if-not-modified as + exit-action when viewing the buffer. + 2008-01-27 Dan Nicolaescu * add-log.el (change-log-search-file-name): Work harder to find diff --git a/lisp/tar-mode.el b/lisp/tar-mode.el index d03458a1641..39f2371c686 100644 --- a/lisp/tar-mode.el +++ b/lisp/tar-mode.el @@ -796,7 +796,8 @@ appear on disk when you save the tar-file's buffer." (narrow-to-region (point-min) tar-header-offset) (set-buffer-multibyte tar-buffer-multibyte))) (if view-p - (view-buffer buffer (and just-created 'kill-buffer)) + (view-buffer + buffer (and just-created 'kill-buffer-if-not-modified)) (if (eq other-window-p 'display) (display-buffer buffer) (if other-window-p From f03ea9d918bf696a78ce34b69914f4457a002816 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Sun, 27 Jan 2008 22:47:58 +0000 Subject: [PATCH 398/439] (server-log-time-function): Doc fix. (server-buffer): Fix typo in docstring. --- lisp/ChangeLog | 13 +++++++++---- lisp/server.el | 8 ++++---- 2 files changed, 13 insertions(+), 8 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index f54b105032d..9dbabec7bf9 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-27 Juanma Barranquero + + * server.el (server-log-time-function): Doc fix. + (server-buffer): Fix typo in docstring. + 2008-01-27 Martin Rudalics * view.el (view-buffer): Explain in doc-string why exit-action @@ -16,11 +21,11 @@ 2007-01-27 Jan Nieuwenhuizen - * add-log.el (change-log-search-file-name, change-log-find-file): - New function. + * add-log.el (change-log-search-file-name, change-log-find-file): + New function. (change-log-font-lock-keywords): Move file name matching ... (change-log-file-names-re): ... here. New defconst. - (change-log-mode-map): New binding C-c C-f to change-log-find-file. + (change-log-mode-map): New binding C-c C-f to change-log-find-file. 2008-01-27 Alan Mackenzie @@ -41,7 +46,7 @@ 2008-01-27 Alan Mackenzie - * progmodes/cc-vars.el (c-hanging-braces-alist): new element for + * progmodes/cc-vars.el (c-hanging-braces-alist): New element for arglist-cont-nonempty. * progmodes/cc-cmds.el (c-brace-newlines): Determine the newlines diff --git a/lisp/server.el b/lisp/server.el index ad4608f2fd2..024df504779 100644 --- a/lisp/server.el +++ b/lisp/server.el @@ -292,13 +292,13 @@ If NOFRAME is non-nil, let the frames live. (To be used from (server-log "Deleted" proc)))) (defvar server-log-time-function 'current-time-string - "Function to generate timestamps for the *server* buffer.") + "Function to generate timestamps for `server-buffer'.") (defconst server-buffer " *server*" "Buffer used internally by Emacs's server. One use is to log the I/O for debugging purposes (see `server-log'), the other is to provide a current buffer in which the process filter can -safely let-bind buffer-local variables like default-directory.") +safely let-bind buffer-local variables like `default-directory'.") (defvar server-log nil "If non-nil, log the server's inputs and outputs in the `server-buffer'.") @@ -952,8 +952,8 @@ The following commands are accepted by the client: ;; Use the same cwd as the emacsclient, if possible, so ;; relative file names work correctly, even in `eval'. (let ((default-directory - (if (and dir (file-directory-p dir)) - dir default-directory))) + (if (and dir (file-directory-p dir)) + dir default-directory))) (server-execute proc files nowait commands dontkill frame tty-name)))))) From 0975aa2475b2691bcb646d56cb3be39f01843ef2 Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Mon, 28 Jan 2008 03:48:45 +0000 Subject: [PATCH 399/439] (read_char): Yet another int/Lisp_Object mixup (YAILOM). --- src/ChangeLog | 15 +++++++++------ src/keyboard.c | 2 +- 2 files changed, 10 insertions(+), 7 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 114bbc5b0e7..3986b4f9284 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-28 Stefan Monnier + + * keyboard.c (read_char): Yet another int/Lisp_Object mixup (YAILOM). + 2008-01-27 Dan Nicolaescu * Makefile.in: Remove references to unused macros. @@ -8,9 +12,8 @@ (g_b_init_get_sid_sub_authority_count): New static variables. (GetSidSubAuthority_Proc, GetSidSubAuthorityCount_Proc): New typedefs. (get_sid_sub_authority, get_sid_sub_authority_count): New functions. - (init_user_info): Use the above two new functions to retrieve uid - and gid. Use 500/513, the Windows defaults, as Administrator's - uid/gid. + (init_user_info): Use them to retrieve uid and gid. + Use 500/513, the Windows defaults, as Administrator's uid/gid. (fstat): Use pw_uid and pw_gid from the_passwd structure for st_uid and st_gid of the file. @@ -34,10 +37,10 @@ * keyboard.c (read_char): Restore echo_message_buffer after redisplay. - * buffer.c (reset_buffer_local_variables): Implement - `permanent-local-hook'. + * buffer.c (reset_buffer_local_variables): + Implement `permanent-local-hook'. (Qpermanent_local_hook): New variable. - (syms_of_buffer): init and staticpro it. + (syms_of_buffer): Init and staticpro it. 2008-01-25 Michael Albinus diff --git a/src/keyboard.c b/src/keyboard.c index 2187c22bdb7..fb6bec2cad8 100644 --- a/src/keyboard.c +++ b/src/keyboard.c @@ -2704,7 +2704,7 @@ read_char (commandflag, nmaps, maps, prev_event, used_mouse_menu, end_time) /* if redisplay was requested */ if (commandflag >= 0) { - int echo_current = echo_message_buffer == echo_area_buffer[0]; + int echo_current = EQ (echo_message_buffer, echo_area_buffer[0]); /* If there is pending input, process any events which are not user-visible, such as X selection_request events. */ From a1da1e372a7a671153a226d08e9b7ae4b2225196 Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Mon, 28 Jan 2008 03:51:31 +0000 Subject: [PATCH 400/439] Merge from gnus--devo--0 Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1016 --- doc/misc/ChangeLog | 5 +++++ doc/misc/gnus.texi | 26 ++++++++++++++++++++++++++ lisp/gnus/ChangeLog | 8 ++++++++ lisp/gnus/mail-source.el | 2 ++ lisp/gnus/nnmail.el | 27 ++++++++++++++++++++++----- 5 files changed, 63 insertions(+), 5 deletions(-) diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index 3c179467fa2..d4710db0675 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog @@ -1,3 +1,8 @@ +2008-01-28 Michael Sperber + + * gnus.texi (Mail Source Specifiers): Document `group' specifier. + (Group Parameters): Document `mail-source' parameter. + 2008-01-27 Michael Albinus * tramp.texi (Inline methods): The hostname of the su(do)? methods diff --git a/doc/misc/gnus.texi b/doc/misc/gnus.texi index ba61fd72247..f90b0f96847 100644 --- a/doc/misc/gnus.texi +++ b/doc/misc/gnus.texi @@ -3035,6 +3035,12 @@ to. If it is set, the value is used as the method for posting message instead of @code{gnus-post-method}. +@item mail-source +@cindex mail-source +If it is set, and the setting of @code{mail-sources} includes a +@code{group} mail source (@pxref{Mail Sources}), the value is a +mail source for this group. + @item banner @cindex banner An item like @code{(banner . @var{regexp})} causes any part of an article @@ -14145,6 +14151,21 @@ element is a @dfn{mail source type}, followed by an arbitrary number of @dfn{keywords}. Keywords that are not explicitly specified are given default values. +The @code{mail-sources} is global for all mail groups. You can specify +an additional mail source for a particular group by including the +@code{group} mail specifier in @code{mail-sources}, and setting a +@code{mail-source} group parameter (@pxref{Group Parameters}) specifying +a single mail source. When this is used, @code{mail-sources} is +typically just @code{(group)}; the @code{mail-source} parameter for a +group might look like this: + +@lisp +(mail-source . (file :path "home/user/spools/foo.spool")) +@end lisp + +This means that the group's (and only this group's) messages will be +fetched from the spool file @samp{/user/spools/foo.spool}. + The following mail source types are available: @table @code @@ -14535,6 +14556,11 @@ An example webmail source: :user "user-name" :password "secret") @end lisp + +@item group +Get the actual mail source from the @code{mail-source} group parameter, +@xref{Group Parameters}. + @end table @table @dfn diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 35347c8e71a..94a976c8e65 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog @@ -1,3 +1,11 @@ +2008-01-24 Michael Sperber + + * mail-source.el (mail-sources): Add `group' choice. + + * nnmail.el (nnmail-get-new-mail-1): Abstract this out to add another + parameter `in-group' to control into which group the articles go. + Add treatment of `group' mail-source. + 2008-01-24 Dan Nicolaescu * sieve.el (sieve-make-overlay, sieve-overlay-put, sieve-overlays-at): diff --git a/lisp/gnus/mail-source.el b/lisp/gnus/mail-source.el index 9f9f9733110..01463c55628 100644 --- a/lisp/gnus/mail-source.el +++ b/lisp/gnus/mail-source.el @@ -74,6 +74,8 @@ See Info node `(gnus)Mail Source Specifiers'." (repeat :tag "List" (choice :format "%[Value Menu%] %v" :value (file) + (cons :tag "Group parameter `mail-source'" + (const :format "" group)) (cons :tag "Spool file" (const :format "" file) (checklist :tag "Options" :greedy t diff --git a/lisp/gnus/nnmail.el b/lisp/gnus/nnmail.el index f0f90218aab..a6ed7190351 100644 --- a/lisp/gnus/nnmail.el +++ b/lisp/gnus/nnmail.el @@ -1766,11 +1766,15 @@ See the Info node `(gnus)Fancy Mail Splitting' for more details." (symbol-value sym)))) (defun nnmail-get-new-mail (method exit-func temp - &optional group spool-func) + &optional group spool-func) "Read new incoming mail." + (nnmail-get-new-mail-1 method exit-func temp group nil spool-func)) + +(defun nnmail-get-new-mail-1 (method exit-func temp + group in-group spool-func) + (let* ((sources mail-sources) fetching-sources - (group-in group) (i 0) (new 0) (total 0) @@ -1778,6 +1782,18 @@ See the Info node `(gnus)Fancy Mail Splitting' for more details." (when (and (nnmail-get-value "%s-get-new-mail" method) sources) (while (setq source (pop sources)) + + ;; Use group's parameter + (when (eq (car source) 'group) + (let ((mail-sources + (list + (gnus-group-find-parameter + (concat (symbol-name method) ":" group) + 'mail-source t)))) + (nnmail-get-new-mail-1 method exit-func temp + group group spool-func)) + (setq source nil)) + ;; Hack to only fetch the contents of a single group's spool file. (when (and (eq (car source) 'directory) (null nnmail-scan-directory-mail-source-once) @@ -1816,9 +1832,10 @@ See the Info node `(gnus)Fancy Mail Splitting' for more details." (nnmail-split-incoming file ',(intern (format "%s-save-mail" method)) ',spool-func - (if (equal file orig-file) - nil - (nnmail-get-split-group orig-file ',source)) + (or in-group + (if (equal file orig-file) + nil + (nnmail-get-split-group orig-file ',source))) ',(intern (format "%s-active-number" method))))))) (incf total new) (incf i))) From a591ee5891d8eb03e20b250beea2d420e5194594 Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Mon, 28 Jan 2008 13:57:22 +0000 Subject: [PATCH 401/439] Move whitespace.el to obsolete dir.: --- lisp/obsolete/whitespace.el | 814 ++++++++++++++++++++++++++++++++++++ 1 file changed, 814 insertions(+) create mode 100644 lisp/obsolete/whitespace.el diff --git a/lisp/obsolete/whitespace.el b/lisp/obsolete/whitespace.el new file mode 100644 index 00000000000..b2ef06c9584 --- /dev/null +++ b/lisp/obsolete/whitespace.el @@ -0,0 +1,814 @@ +;;; whitespace.el --- warn about and clean bogus whitespaces in the file + +;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, +;; 2005, 2006, 2007, 2008 Free Software Foundation, Inc. + +;; Author: Rajesh Vaidheeswarran +;; Keywords: convenience + +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3, or (at your option) +;; any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. + +;;; Commentary: +;; +;; URL: http://www.dsmit.com/lisp/ +;; +;; The whitespace library is intended to find and help fix five different types +;; of whitespace problems that commonly exist in source code. +;; +;; 1. Leading space (empty lines at the top of a file). +;; 2. Trailing space (empty lines at the end of a file). +;; 3. Indentation space (8 or more spaces at beginning of line, that should be +;; replaced with TABS). +;; 4. Spaces followed by a TAB. (Almost always, we never want that). +;; 5. Spaces or TABS at the end of a line. +;; +;; Whitespace errors are reported in a buffer, and on the modeline. +;; +;; Modeline will show a W:! to denote a particular type of whitespace, +;; where `x' and `y' can be one (or more) of: +;; +;; e - End-of-Line whitespace. +;; i - Indentation whitespace. +;; l - Leading whitespace. +;; s - Space followed by Tab. +;; t - Trailing whitespace. +;; +;; If any of the whitespace checks is turned off, the modeline will display a +;; !. +;; +;; (since (3) is the most controversial one, here is the rationale: Most +;; terminal drivers and printer drivers have TAB configured or even +;; hardcoded to be 8 spaces. (Some of them allow configuration, but almost +;; always they default to 8.) +;; +;; Changing `tab-width' to other than 8 and editing will cause your code to +;; look different from within Emacs, and say, if you cat it or more it, or +;; even print it. +;; +;; Almost all the popular programming modes let you define an offset (like +;; c-basic-offset or perl-indent-level) to configure the offset, so you +;; should never have to set your `tab-width' to be other than 8 in all +;; these modes. In fact, with an indent level of say, 4, 2 TABS will cause +;; Emacs to replace your 8 spaces with one \t (try it). If vi users in +;; your office complain, tell them to use vim, which distinguishes between +;; tabstop and shiftwidth (vi equivalent of our offsets), and also ask them +;; to set smarttab.) +;; +;; All the above have caused (and will cause) unwanted codeline integration and +;; merge problems. +;; +;; whitespace.el will complain if it detects whitespaces on opening a file, and +;; warn you on closing a file also (in case you had inserted any +;; whitespaces during the process of your editing). +;; +;; Exported functions: +;; +;; `whitespace-buffer' - To check the current buffer for whitespace problems. +;; `whitespace-cleanup' - To cleanup all whitespaces in the current buffer. +;; `whitespace-region' - To check between point and mark for whitespace +;; problems. +;; `whitespace-cleanup-region' - To cleanup all whitespaces between point +;; and mark in the current buffer. + +;;; Code: + +(defvar whitespace-version "3.5" "Version of the whitespace library.") + +(defvar whitespace-all-buffer-files nil + "An associated list of buffers and files checked for whitespace cleanliness. + +This is to enable periodic checking of whitespace cleanliness in the files +visited by the buffers.") + +(defvar whitespace-rescan-timer nil + "Timer object used to rescan the files in buffers that have been modified.") + +;; Tell Emacs about this new kind of minor mode +(defvar whitespace-mode nil + "Non-nil when Whitespace mode (a minor mode) is enabled.") +(make-variable-buffer-local 'whitespace-mode) + +(defvar whitespace-mode-line nil + "String to display in the mode line for Whitespace mode.") +(make-variable-buffer-local 'whitespace-mode-line) + +(defvar whitespace-check-buffer-leading nil + "Test leading whitespace for file in current buffer if t.") +(make-variable-buffer-local 'whitespace-check-buffer-leading) +;;;###autoload(put 'whitespace-check-buffer-leading 'safe-local-variable 'booleanp) + +(defvar whitespace-check-buffer-trailing nil + "Test trailing whitespace for file in current buffer if t.") +(make-variable-buffer-local 'whitespace-check-buffer-trailing) +;;;###autoload(put 'whitespace-check-buffer-trailing 'safe-local-variable 'booleanp) + +(defvar whitespace-check-buffer-indent nil + "Test indentation whitespace for file in current buffer if t.") +(make-variable-buffer-local 'whitespace-check-buffer-indent) +;;;###autoload(put 'whitespace-check-buffer-indent 'safe-local-variable 'booleanp) + +(defvar whitespace-check-buffer-spacetab nil + "Test Space-followed-by-TABS whitespace for file in current buffer if t.") +(make-variable-buffer-local 'whitespace-check-buffer-spacetab) +;;;###autoload(put 'whitespace-check-buffer-spacetab 'safe-local-variable 'booleanp) + +(defvar whitespace-check-buffer-ateol nil + "Test end-of-line whitespace for file in current buffer if t.") +(make-variable-buffer-local 'whitespace-check-buffer-ateol) +;;;###autoload(put 'whitespace-check-buffer-ateol 'safe-local-variable 'booleanp) + +(defvar whitespace-highlighted-space nil + "The variable to store the extent to highlight.") +(make-variable-buffer-local 'whitespace-highlighted-space) + +(defalias 'whitespace-make-overlay + (if (featurep 'xemacs) 'make-extent 'make-overlay)) +(defalias 'whitespace-overlay-put + (if (featurep 'xemacs) 'set-extent-property 'overlay-put)) +(defalias 'whitespace-delete-overlay + (if (featurep 'xemacs) 'delete-extent 'delete-overlay)) +(defalias 'whitespace-overlay-start + (if (featurep 'xemacs) 'extent-start 'overlay-start)) +(defalias 'whitespace-overlay-end + (if (featurep 'xemacs) 'extent-end 'overlay-end)) +(defalias 'whitespace-mode-line-update + (if (featurep 'xemacs) 'redraw-modeline 'force-mode-line-update)) + +(defgroup whitespace nil + "Check for and fix five different types of whitespaces in source code." + :version "21.1" + :link '(emacs-commentary-link "whitespace.el") + ;; Since XEmacs doesn't have a 'convenience group, use the next best group + ;; which is 'editing? + :group (if (featurep 'xemacs) 'editing 'convenience)) + +(defcustom whitespace-check-leading-whitespace t + "Flag to check leading whitespace. This is the global for the system. +It can be overridden by setting a buffer local variable +`whitespace-check-buffer-leading'." + :type 'boolean + :group 'whitespace) + +(defcustom whitespace-check-trailing-whitespace t + "Flag to check trailing whitespace. This is the global for the system. +It can be overridden by setting a buffer local variable +`whitespace-check-buffer-trailing'." + :type 'boolean + :group 'whitespace) + +(defcustom whitespace-check-spacetab-whitespace t + "Flag to check space followed by a TAB. This is the global for the system. +It can be overridden by setting a buffer local variable +`whitespace-check-buffer-spacetab'." + :type 'boolean + :group 'whitespace) + +(defcustom whitespace-spacetab-regexp "[ ]+\t" + "Regexp to match one or more spaces followed by a TAB." + :type 'regexp + :group 'whitespace) + +(defcustom whitespace-check-indent-whitespace indent-tabs-mode + "Flag to check indentation whitespace. This is the global for the system. +It can be overridden by setting a buffer local variable +`whitespace-check-buffer-indent'." + :type 'boolean + :group 'whitespace) + +(defcustom whitespace-indent-regexp "^\t*\\( \\)+" + "Regexp to match multiples of eight spaces near line beginnings. +The default value ignores leading TABs." + :type 'regexp + :group 'whitespace) + +(defcustom whitespace-check-ateol-whitespace t + "Flag to check end-of-line whitespace. This is the global for the system. +It can be overridden by setting a buffer local variable +`whitespace-check-buffer-ateol'." + :type 'boolean + :group 'whitespace) + +(defcustom whitespace-ateol-regexp "[ \t]+$" + "Regexp to match one or more TABs or spaces at line ends." + :type 'regexp + :group 'whitespace) + +(defcustom whitespace-errbuf "*Whitespace Errors*" + "The name of the buffer where whitespace related messages will be logged." + :type 'string + :group 'whitespace) + +(defcustom whitespace-clean-msg "clean." + "If non-nil, this message will be displayed after a whitespace check +determines a file to be clean." + :type 'string + :group 'whitespace) + +(defcustom whitespace-abort-on-error nil + "While writing a file, abort if the file is unclean. +If `whitespace-auto-cleanup' is set, that takes precedence over +this variable." + :type 'boolean + :group 'whitespace) + +(defcustom whitespace-auto-cleanup nil + "Cleanup a buffer automatically on finding it whitespace unclean." + :type 'boolean + :group 'whitespace) + +(defcustom whitespace-silent nil + "All whitespace errors will be shown only in the modeline when t. + +Note that setting this may cause all whitespaces introduced in a file to go +unnoticed when the buffer is killed, unless the user visits the `*Whitespace +Errors*' buffer before opening (or closing) another file." + :type 'boolean + :group 'whitespace) + +(defcustom whitespace-modes '(ada-mode asm-mode autoconf-mode awk-mode + c-mode c++-mode cc-mode + change-log-mode cperl-mode + electric-nroff-mode emacs-lisp-mode + f90-mode fortran-mode html-mode + html3-mode java-mode jde-mode + ksh-mode latex-mode LaTeX-mode + lisp-mode m4-mode makefile-mode + modula-2-mode nroff-mode objc-mode + pascal-mode perl-mode prolog-mode + python-mode scheme-mode sgml-mode + sh-mode shell-script-mode simula-mode + tcl-mode tex-mode texinfo-mode + vrml-mode xml-mode) + + "Major modes in which we turn on whitespace checking. + +These are mostly programming and documentation modes. But you may add other +modes that you want whitespaces checked in by adding something like the +following to your `.emacs': + +\(setq whitespace-modes (cons 'my-mode (cons 'my-other-mode + whitespace-modes))\) + +Or, alternately, you can use the Emacs `customize' command to set this." + :type '(repeat symbol) + :group 'whitespace) + +(defcustom whitespace-rescan-timer-time 600 + "Period in seconds to rescan modified buffers for whitespace creep. + +This is the period after which the timer will fire causing +`whitespace-rescan-files-in-buffers' to check for whitespace creep in +modified buffers. + +To disable timer scans, set this to zero." + :type 'integer + :group 'whitespace) + +(defcustom whitespace-display-in-modeline t + "Display whitespace errors on the modeline." + :type 'boolean + :group 'whitespace) + +(defcustom whitespace-display-spaces-in-color t + "Display the bogus whitespaces by coloring them with the face +`whitespace-highlight'." + :type 'boolean + :group 'whitespace) + +(defgroup whitespace-faces nil + "Faces used in whitespace." + :prefix "whitespace-" + :group 'whitespace + :group 'faces) + +(defface whitespace-highlight '((((class color) (background light)) + (:background "green1")) + (((class color) (background dark)) + (:background "sea green")) + (((class grayscale mono) + (background light)) + (:background "black")) + (((class grayscale mono) + (background dark)) + (:background "white"))) + "Face used for highlighting the bogus whitespaces that exist in the buffer." + :group 'whitespace-faces) +;; backward-compatibility alias +(put 'whitespace-highlight-face 'face-alias 'whitespace-highlight) + +(if (not (assoc 'whitespace-mode minor-mode-alist)) + (setq minor-mode-alist (cons '(whitespace-mode whitespace-mode-line) + minor-mode-alist))) + +(set-default 'whitespace-check-buffer-leading + whitespace-check-leading-whitespace) +(set-default 'whitespace-check-buffer-trailing + whitespace-check-trailing-whitespace) +(set-default 'whitespace-check-buffer-indent + whitespace-check-indent-whitespace) +(set-default 'whitespace-check-buffer-spacetab + whitespace-check-spacetab-whitespace) +(set-default 'whitespace-check-buffer-ateol + whitespace-check-ateol-whitespace) + +(defun whitespace-check-whitespace-mode (&optional arg) + "Test and set the whitespace-mode in qualifying buffers." + (if (null whitespace-mode) + (setq whitespace-mode + (if (or arg (member major-mode whitespace-modes)) + t + nil)))) + +;;;###autoload +(defun whitespace-toggle-leading-check () + "Toggle the check for leading space in the local buffer." + (interactive) + (let ((current-val whitespace-check-buffer-leading)) + (setq whitespace-check-buffer-leading (not current-val)) + (message "Will%s check for leading space in buffer." + (if whitespace-check-buffer-leading "" " not")) + (if whitespace-check-buffer-leading (whitespace-buffer-leading)))) + +;;;###autoload +(defun whitespace-toggle-trailing-check () + "Toggle the check for trailing space in the local buffer." + (interactive) + (let ((current-val whitespace-check-buffer-trailing)) + (setq whitespace-check-buffer-trailing (not current-val)) + (message "Will%s check for trailing space in buffer." + (if whitespace-check-buffer-trailing "" " not")) + (if whitespace-check-buffer-trailing (whitespace-buffer-trailing)))) + +;;;###autoload +(defun whitespace-toggle-indent-check () + "Toggle the check for indentation space in the local buffer." + (interactive) + (let ((current-val whitespace-check-buffer-indent)) + (setq whitespace-check-buffer-indent (not current-val)) + (message "Will%s check for indentation space in buffer." + (if whitespace-check-buffer-indent "" " not")) + (if whitespace-check-buffer-indent + (whitespace-buffer-search whitespace-indent-regexp)))) + +;;;###autoload +(defun whitespace-toggle-spacetab-check () + "Toggle the check for space-followed-by-TABs in the local buffer." + (interactive) + (let ((current-val whitespace-check-buffer-spacetab)) + (setq whitespace-check-buffer-spacetab (not current-val)) + (message "Will%s check for space-followed-by-TABs in buffer." + (if whitespace-check-buffer-spacetab "" " not")) + (if whitespace-check-buffer-spacetab + (whitespace-buffer-search whitespace-spacetab-regexp)))) + + +;;;###autoload +(defun whitespace-toggle-ateol-check () + "Toggle the check for end-of-line space in the local buffer." + (interactive) + (let ((current-val whitespace-check-buffer-ateol)) + (setq whitespace-check-buffer-ateol (not current-val)) + (message "Will%s check for end-of-line space in buffer." + (if whitespace-check-buffer-ateol "" " not")) + (if whitespace-check-buffer-ateol + (whitespace-buffer-search whitespace-ateol-regexp)))) + + +;;;###autoload +(defun whitespace-buffer (&optional quiet) + "Find five different types of white spaces in buffer. +These are: +1. Leading space \(empty lines at the top of a file\). +2. Trailing space \(empty lines at the end of a file\). +3. Indentation space \(8 or more spaces, that should be replaced with TABS\). +4. Spaces followed by a TAB. \(Almost always, we never want that\). +5. Spaces or TABS at the end of a line. + +Check for whitespace only if this buffer really contains a non-empty file +and: +1. the major mode is one of the whitespace-modes, or +2. `whitespace-buffer' was explicitly called with a prefix argument." + (interactive) + (let ((whitespace-error nil)) + (whitespace-check-whitespace-mode current-prefix-arg) + (if (and buffer-file-name (> (buffer-size) 0) whitespace-mode) + (progn + (whitespace-check-buffer-list (buffer-name) buffer-file-name) + (whitespace-tickle-timer) + (overlay-recenter (point-max)) + (remove-overlays nil nil 'face 'whitespace-highlight) + (if whitespace-auto-cleanup + (if buffer-read-only + (if (not quiet) + (message "Can't cleanup: %s is read-only" (buffer-name))) + (whitespace-cleanup-internal)) + (let ((whitespace-leading (if whitespace-check-buffer-leading + (whitespace-buffer-leading) + nil)) + (whitespace-trailing (if whitespace-check-buffer-trailing + (whitespace-buffer-trailing) + nil)) + (whitespace-indent (if whitespace-check-buffer-indent + (whitespace-buffer-search + whitespace-indent-regexp) + nil)) + (whitespace-spacetab (if whitespace-check-buffer-spacetab + (whitespace-buffer-search + whitespace-spacetab-regexp) + nil)) + (whitespace-ateol (if whitespace-check-buffer-ateol + (whitespace-buffer-search + whitespace-ateol-regexp) + nil)) + (whitespace-errmsg nil) + (whitespace-filename buffer-file-name) + (whitespace-this-modeline "")) + + ;; Now let's complain if we found any of the above. + (setq whitespace-error (or whitespace-leading whitespace-indent + whitespace-spacetab whitespace-ateol + whitespace-trailing)) + + (if whitespace-error + (progn + (setq whitespace-errmsg + (concat whitespace-filename " contains:\n" + (if whitespace-leading + "Leading whitespace\n") + (if whitespace-indent + (concat "Indentation whitespace" + whitespace-indent "\n")) + (if whitespace-spacetab + (concat "Space followed by Tab" + whitespace-spacetab "\n")) + (if whitespace-ateol + (concat "End-of-line whitespace" + whitespace-ateol "\n")) + (if whitespace-trailing + "Trailing whitespace\n") + "\ntype `M-x whitespace-cleanup' to " + "cleanup the file.")) + (setq whitespace-this-modeline + (concat (if whitespace-ateol "e") + (if whitespace-indent "i") + (if whitespace-leading "l") + (if whitespace-spacetab "s") + (if whitespace-trailing "t"))))) + (whitespace-update-modeline whitespace-this-modeline) + (if (get-buffer whitespace-errbuf) + (kill-buffer whitespace-errbuf)) + (with-current-buffer (get-buffer-create whitespace-errbuf) + (if whitespace-errmsg + (progn + (insert whitespace-errmsg) + (if (not (or quiet whitespace-silent)) + (display-buffer (current-buffer) t)) + (if (not quiet) + (message "Whitespaces: [%s%s] in %s" + whitespace-this-modeline + (let ((whitespace-unchecked + (whitespace-unchecked-whitespaces))) + (if whitespace-unchecked + (concat "!" whitespace-unchecked) + "")) + whitespace-filename))) + (if (and (not quiet) (not (equal whitespace-clean-msg ""))) + (message "%s %s" whitespace-filename + whitespace-clean-msg)))))))) + whitespace-error)) + +;;;###autoload +(defun whitespace-region (s e) + "Check the region for whitespace errors." + (interactive "r") + (save-excursion + (save-restriction + (narrow-to-region s e) + (whitespace-buffer)))) + +;;;###autoload +(defun whitespace-cleanup () + "Cleanup the five different kinds of whitespace problems. +It normally applies to the whole buffer, but in Transient Mark mode +when the mark is active it applies to the region. +See `whitespace-buffer' docstring for a summary of the problems." + (interactive) + (if (and transient-mark-mode mark-active) + (whitespace-cleanup-region (region-beginning) (region-end)) + (whitespace-cleanup-internal))) + +(defun whitespace-cleanup-internal (&optional region-only) + ;; If this buffer really contains a file, then run, else quit. + (whitespace-check-whitespace-mode current-prefix-arg) + (if (and buffer-file-name whitespace-mode) + (let ((whitespace-any nil) + (whitespace-tabwith 8) + (whitespace-tabwith-saved tab-width)) + + ;; since all printable TABS should be 8, irrespective of how + ;; they are displayed. + (setq tab-width whitespace-tabwith) + + (if (and whitespace-check-buffer-leading + (whitespace-buffer-leading)) + (progn + (whitespace-buffer-leading-cleanup) + (setq whitespace-any t))) + + (if (and whitespace-check-buffer-trailing + (whitespace-buffer-trailing)) + (progn + (whitespace-buffer-trailing-cleanup) + (setq whitespace-any t))) + + (if (and whitespace-check-buffer-indent + (whitespace-buffer-search whitespace-indent-regexp)) + (progn + (whitespace-indent-cleanup) + (setq whitespace-any t))) + + (if (and whitespace-check-buffer-spacetab + (whitespace-buffer-search whitespace-spacetab-regexp)) + (progn + (whitespace-buffer-cleanup whitespace-spacetab-regexp "\t") + (setq whitespace-any t))) + + (if (and whitespace-check-buffer-ateol + (whitespace-buffer-search whitespace-ateol-regexp)) + (progn + (whitespace-buffer-cleanup whitespace-ateol-regexp "") + (setq whitespace-any t))) + + ;; Call this recursively till everything is taken care of + (if whitespace-any + (whitespace-cleanup-internal region-only) + ;; if we are done, talk to the user + (progn + (unless whitespace-silent + (if region-only + (message "The region is now clean") + (message "%s is now clean" buffer-file-name))) + (whitespace-update-modeline))) + (setq tab-width whitespace-tabwith-saved)))) + +;;;###autoload +(defun whitespace-cleanup-region (s e) + "Whitespace cleanup on the region." + (interactive "r") + (save-excursion + (save-restriction + (narrow-to-region s e) + (whitespace-cleanup-internal t)) + (whitespace-buffer t))) + +(defun whitespace-buffer-leading () + "Return t if the current buffer has leading newline characters. +If highlighting is enabled, highlight these characters." + (save-excursion + (goto-char (point-min)) + (skip-chars-forward "\n") + (unless (bobp) + (whitespace-highlight-the-space (point-min) (point)) + t))) + +(defun whitespace-buffer-leading-cleanup () + "Remove any leading newline characters from current buffer." + (save-excursion + (goto-char (point-min)) + (skip-chars-forward "\n") + (delete-region (point-min) (point)))) + +(defun whitespace-buffer-trailing () + "Return t if the current buffer has extra trailing newline characters. +If highlighting is enabled, highlight these characters." + (save-excursion + (goto-char (point-max)) + (skip-chars-backward "\n") + (forward-line) + (unless (eobp) + (whitespace-highlight-the-space (point) (point-max)) + t))) + +(defun whitespace-buffer-trailing-cleanup () + "Remove extra trailing newline characters from current buffer." + (save-excursion + (goto-char (point-max)) + (skip-chars-backward "\n") + (unless (eobp) + (forward-line) + (delete-region (point) (point-max))))) + +(defun whitespace-buffer-search (regexp) + "Search for any given whitespace REGEXP." + (with-local-quit + (let (whitespace-retval) + (save-excursion + (goto-char (point-min)) + (while (re-search-forward regexp nil t) + (whitespace-highlight-the-space (match-beginning 0) (match-end 0)) + (push (match-beginning 0) whitespace-retval))) + (when whitespace-retval + (format " %s" (nreverse whitespace-retval)))))) + +(defun whitespace-buffer-cleanup (regexp newregexp) + "Search for any given whitespace REGEXP and replace it with the NEWREGEXP." + (save-excursion + (goto-char (point-min)) + (while (re-search-forward regexp nil t) + (replace-match newregexp)))) + +(defun whitespace-indent-cleanup () + "Search for 8/more spaces at the start of a line and replace it with tabs." + (save-excursion + (goto-char (point-min)) + (while (re-search-forward whitespace-indent-regexp nil t) + (let ((column (current-column)) + (indent-tabs-mode t)) + (delete-region (match-beginning 0) (point)) + (indent-to column))))) + +(defun whitespace-unchecked-whitespaces () + "Return the list of whitespaces whose testing has been suppressed." + (let ((unchecked-spaces + (concat (if (not whitespace-check-buffer-ateol) "e") + (if (not whitespace-check-buffer-indent) "i") + (if (not whitespace-check-buffer-leading) "l") + (if (not whitespace-check-buffer-spacetab) "s") + (if (not whitespace-check-buffer-trailing) "t")))) + (if (not (equal unchecked-spaces "")) + unchecked-spaces + nil))) + +(defun whitespace-update-modeline (&optional whitespace-err) + "Update modeline with whitespace errors. +Also with whitespaces whose testing has been turned off." + (if whitespace-display-in-modeline + (progn + (setq whitespace-mode-line nil) + ;; Whitespace errors + (if (and whitespace-err (not (equal whitespace-err ""))) + (setq whitespace-mode-line whitespace-err)) + ;; Whitespace suppressed errors + (let ((whitespace-unchecked (whitespace-unchecked-whitespaces))) + (if whitespace-unchecked + (setq whitespace-mode-line + (concat whitespace-mode-line "!" whitespace-unchecked)))) + ;; Add the whitespace modeline prefix + (setq whitespace-mode-line (if whitespace-mode-line + (concat " W:" whitespace-mode-line) + nil)) + (whitespace-mode-line-update)))) + +(defun whitespace-highlight-the-space (b e) + "Highlight the current line, unhighlighting a previously jumped to line." + (if whitespace-display-spaces-in-color + (let ((ol (whitespace-make-overlay b e))) + (whitespace-overlay-put ol 'face 'whitespace-highlight)))) + +(defun whitespace-unhighlight-the-space() + "Unhighlight the currently highlight line." + (if (and whitespace-display-spaces-in-color whitespace-highlighted-space) + (progn + (mapc 'whitespace-delete-overlay whitespace-highlighted-space) + (setq whitespace-highlighted-space nil)))) + +(defun whitespace-check-buffer-list (buf-name buf-file) + "Add a buffer and its file to the whitespace monitor list. + +The buffer named BUF-NAME and its associated file BUF-FILE are now monitored +periodically for whitespace." + (if (and whitespace-mode (not (member (list buf-file buf-name) + whitespace-all-buffer-files))) + (add-to-list 'whitespace-all-buffer-files (list buf-file buf-name)))) + +(defun whitespace-tickle-timer () + "Tickle timer to periodically to scan qualifying files for whitespace creep. + +If timer is not set, then set it to scan the files in +`whitespace-all-buffer-files' periodically (defined by +`whitespace-rescan-timer-time') for whitespace creep." + (if (and whitespace-rescan-timer-time + (/= whitespace-rescan-timer-time 0) + (not whitespace-rescan-timer)) + (setq whitespace-rescan-timer + (add-timeout whitespace-rescan-timer-time + 'whitespace-rescan-files-in-buffers nil + whitespace-rescan-timer-time)))) + +(defun whitespace-rescan-files-in-buffers (&optional arg) + "Check monitored files for whitespace creep since last scan." + (let ((whitespace-all-my-files whitespace-all-buffer-files) + buffile bufname thiselt buf) + (if (not whitespace-all-my-files) + (progn + (disable-timeout whitespace-rescan-timer) + (setq whitespace-rescan-timer nil)) + (while whitespace-all-my-files + (setq thiselt (car whitespace-all-my-files)) + (setq whitespace-all-my-files (cdr whitespace-all-my-files)) + (setq buffile (car thiselt)) + (setq bufname (cadr thiselt)) + (setq buf (get-buffer bufname)) + (if (buffer-live-p buf) + (save-excursion + ;;(message "buffer %s live" bufname) + (set-buffer bufname) + (if whitespace-mode + (progn + ;;(message "checking for whitespace in %s" bufname) + (if whitespace-auto-cleanup + (progn + ;;(message "cleaning up whitespace in %s" bufname) + (whitespace-cleanup-internal)) + (progn + ;;(message "whitespace-buffer %s." (buffer-name)) + (whitespace-buffer t)))) + ;;(message "Removing %s from refresh list" bufname) + (whitespace-refresh-rescan-list buffile bufname))) + ;;(message "Removing %s from refresh list" bufname) + (whitespace-refresh-rescan-list buffile bufname)))))) + +(defun whitespace-refresh-rescan-list (buffile bufname) + "Refresh the list of files to be rescanned for whitespace creep." + (if whitespace-all-buffer-files + (setq whitespace-all-buffer-files + (delete (list buffile bufname) whitespace-all-buffer-files)) + (when whitespace-rescan-timer + (disable-timeout whitespace-rescan-timer) + (setq whitespace-rescan-timer nil)))) + +;;;###autoload +(defalias 'global-whitespace-mode 'whitespace-global-mode) + +;;;###autoload +(define-minor-mode whitespace-global-mode + "Toggle using Whitespace mode in new buffers. +With ARG, turn the mode on if ARG is positive, otherwise turn it off. + +When this mode is active, `whitespace-buffer' is added to +`find-file-hook' and `kill-buffer-hook'." + :global t + :group 'whitespace + (if whitespace-global-mode + (progn + (add-hook 'find-file-hook 'whitespace-buffer) + (add-hook 'write-file-functions 'whitespace-write-file-hook nil t) + (add-hook 'kill-buffer-hook 'whitespace-buffer)) + (remove-hook 'find-file-hook 'whitespace-buffer) + (remove-hook 'write-file-functions 'whitespace-write-file-hook t) + (remove-hook 'kill-buffer-hook 'whitespace-buffer))) + +;;;###autoload +(defun whitespace-write-file-hook () + "Hook function to be called on the buffer when whitespace check is enabled. +This is meant to be added buffer-locally to `write-file-functions'." + (let ((werr nil)) + (if whitespace-auto-cleanup + (whitespace-cleanup-internal) + (setq werr (whitespace-buffer))) + (if (and whitespace-abort-on-error werr) + (error "Abort write due to whitespaces in %s" + buffer-file-name))) + nil) + +(defun whitespace-unload-function () + "Unload the whitespace library." + (if (unintern "whitespace-unload-hook") + ;; if whitespace-unload-hook is defined, let's get rid of it + ;; and recursively call `unload-feature' + (progn (unload-feature 'whitespace) t) + ;; this only happens in the recursive call + (whitespace-global-mode -1) + (save-current-buffer + (dolist (buf (buffer-list)) + (set-buffer buf) + (remove-hook 'write-file-functions 'whitespace-write-file-hook t))) + ;; continue standard unloading + nil)) + +(defun whitespace-unload-hook () + (remove-hook 'find-file-hook 'whitespace-buffer) + (remove-hook 'write-file-functions 'whitespace-write-file-hook t) + (remove-hook 'kill-buffer-hook 'whitespace-buffer)) + +(add-hook 'whitespace-unload-hook 'whitespace-unload-hook) + +(provide 'whitespace) + +;; arch-tag: 4ff44e87-b63c-402d-95a6-15e51e58bd0c +;;; whitespace.el ends here From 596c0ee145b24d10c347ed4444e2e7260509ba4b Mon Sep 17 00:00:00 2001 From: Vinicius Jose Latorre Date: Mon, 28 Jan 2008 13:58:19 +0000 Subject: [PATCH 402/439] Move whitespace.el to obsolete dir. --- lisp/ChangeLog | 12 + lisp/blank-mode.el | 34 +- lisp/whitespace.el | 814 --------------------------------------------- 3 files changed, 45 insertions(+), 815 deletions(-) delete mode 100644 lisp/whitespace.el diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 9dbabec7bf9..1e2dcf1e558 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,15 @@ +2008-01-28 Vinicius Jose Latorre + + * whitespace.el: Moved to obsolete dir. + + * blank-mode.el: New version 9.2. Replace whitespace funs by aliases + in blank-mode. + (whitespace-buffer): New fun. + (whitespace-region): Alias for whitespace-buffer, because there is no + blank-region fun. + (whitespace-cleanup): Alias for blank-cleanup. + (whitespace-cleanup-region): Alias for blank-cleanup-region. + 2008-01-27 Juanma Barranquero * server.el (server-log-time-function): Doc fix. diff --git a/lisp/blank-mode.el b/lisp/blank-mode.el index 5f1270c49a7..8956e95ac1e 100644 --- a/lisp/blank-mode.el +++ b/lisp/blank-mode.el @@ -6,7 +6,7 @@ ;; Author: Vinicius Jose Latorre ;; Maintainer: Vinicius Jose Latorre ;; Keywords: data, wp -;; Version: 9.1 +;; Version: 9.2 ;; X-URL: http://www.emacswiki.org/cgi-bin/wiki/ViniciusJoseLatorre ;; This file is part of GNU Emacs. @@ -1682,6 +1682,38 @@ options are valid." ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; +;;;; Aliases for whitespace compatibility + + +;;;###autoload +(defun whitespace-buffer () + (interactive) + (blank-mode 0) ; assure is off + ;; keep original values + (let ((blank-style (copy-sequence blank-style)) + (blank-chars (copy-sequence blank-chars))) + ;; adjust options for whitespace bogus blanks + (add-to-list 'blank-style 'color) + (mapc #'(lambda (option) + (add-to-list 'blank-chars option)) + '(trailing + indentation + space-before-tab + empty + space-after-tab)) + (blank-mode 1))) + +;;;###autoload +(defalias 'whitespace-region 'whitespace-buffer) ; there is no `blank-region' + +;;;###autoload +(defalias 'whitespace-cleanup 'blank-cleanup) + +;;;###autoload +(defalias 'whitespace-cleanup-region 'blank-cleanup-region) + + +;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; (provide 'blank-mode) diff --git a/lisp/whitespace.el b/lisp/whitespace.el deleted file mode 100644 index b2ef06c9584..00000000000 --- a/lisp/whitespace.el +++ /dev/null @@ -1,814 +0,0 @@ -;;; whitespace.el --- warn about and clean bogus whitespaces in the file - -;; Copyright (C) 1999, 2000, 2001, 2002, 2003, 2004, -;; 2005, 2006, 2007, 2008 Free Software Foundation, Inc. - -;; Author: Rajesh Vaidheeswarran -;; Keywords: convenience - -;; This file is part of GNU Emacs. - -;; GNU Emacs is free software; you can redistribute it and/or modify -;; it under the terms of the GNU General Public License as published by -;; the Free Software Foundation; either version 3, or (at your option) -;; any later version. - -;; GNU Emacs is distributed in the hope that it will be useful, -;; but WITHOUT ANY WARRANTY; without even the implied warranty of -;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -;; GNU General Public License for more details. - -;; You should have received a copy of the GNU General Public License -;; along with GNU Emacs; see the file COPYING. If not, write to the -;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, -;; Boston, MA 02110-1301, USA. - -;;; Commentary: -;; -;; URL: http://www.dsmit.com/lisp/ -;; -;; The whitespace library is intended to find and help fix five different types -;; of whitespace problems that commonly exist in source code. -;; -;; 1. Leading space (empty lines at the top of a file). -;; 2. Trailing space (empty lines at the end of a file). -;; 3. Indentation space (8 or more spaces at beginning of line, that should be -;; replaced with TABS). -;; 4. Spaces followed by a TAB. (Almost always, we never want that). -;; 5. Spaces or TABS at the end of a line. -;; -;; Whitespace errors are reported in a buffer, and on the modeline. -;; -;; Modeline will show a W:! to denote a particular type of whitespace, -;; where `x' and `y' can be one (or more) of: -;; -;; e - End-of-Line whitespace. -;; i - Indentation whitespace. -;; l - Leading whitespace. -;; s - Space followed by Tab. -;; t - Trailing whitespace. -;; -;; If any of the whitespace checks is turned off, the modeline will display a -;; !. -;; -;; (since (3) is the most controversial one, here is the rationale: Most -;; terminal drivers and printer drivers have TAB configured or even -;; hardcoded to be 8 spaces. (Some of them allow configuration, but almost -;; always they default to 8.) -;; -;; Changing `tab-width' to other than 8 and editing will cause your code to -;; look different from within Emacs, and say, if you cat it or more it, or -;; even print it. -;; -;; Almost all the popular programming modes let you define an offset (like -;; c-basic-offset or perl-indent-level) to configure the offset, so you -;; should never have to set your `tab-width' to be other than 8 in all -;; these modes. In fact, with an indent level of say, 4, 2 TABS will cause -;; Emacs to replace your 8 spaces with one \t (try it). If vi users in -;; your office complain, tell them to use vim, which distinguishes between -;; tabstop and shiftwidth (vi equivalent of our offsets), and also ask them -;; to set smarttab.) -;; -;; All the above have caused (and will cause) unwanted codeline integration and -;; merge problems. -;; -;; whitespace.el will complain if it detects whitespaces on opening a file, and -;; warn you on closing a file also (in case you had inserted any -;; whitespaces during the process of your editing). -;; -;; Exported functions: -;; -;; `whitespace-buffer' - To check the current buffer for whitespace problems. -;; `whitespace-cleanup' - To cleanup all whitespaces in the current buffer. -;; `whitespace-region' - To check between point and mark for whitespace -;; problems. -;; `whitespace-cleanup-region' - To cleanup all whitespaces between point -;; and mark in the current buffer. - -;;; Code: - -(defvar whitespace-version "3.5" "Version of the whitespace library.") - -(defvar whitespace-all-buffer-files nil - "An associated list of buffers and files checked for whitespace cleanliness. - -This is to enable periodic checking of whitespace cleanliness in the files -visited by the buffers.") - -(defvar whitespace-rescan-timer nil - "Timer object used to rescan the files in buffers that have been modified.") - -;; Tell Emacs about this new kind of minor mode -(defvar whitespace-mode nil - "Non-nil when Whitespace mode (a minor mode) is enabled.") -(make-variable-buffer-local 'whitespace-mode) - -(defvar whitespace-mode-line nil - "String to display in the mode line for Whitespace mode.") -(make-variable-buffer-local 'whitespace-mode-line) - -(defvar whitespace-check-buffer-leading nil - "Test leading whitespace for file in current buffer if t.") -(make-variable-buffer-local 'whitespace-check-buffer-leading) -;;;###autoload(put 'whitespace-check-buffer-leading 'safe-local-variable 'booleanp) - -(defvar whitespace-check-buffer-trailing nil - "Test trailing whitespace for file in current buffer if t.") -(make-variable-buffer-local 'whitespace-check-buffer-trailing) -;;;###autoload(put 'whitespace-check-buffer-trailing 'safe-local-variable 'booleanp) - -(defvar whitespace-check-buffer-indent nil - "Test indentation whitespace for file in current buffer if t.") -(make-variable-buffer-local 'whitespace-check-buffer-indent) -;;;###autoload(put 'whitespace-check-buffer-indent 'safe-local-variable 'booleanp) - -(defvar whitespace-check-buffer-spacetab nil - "Test Space-followed-by-TABS whitespace for file in current buffer if t.") -(make-variable-buffer-local 'whitespace-check-buffer-spacetab) -;;;###autoload(put 'whitespace-check-buffer-spacetab 'safe-local-variable 'booleanp) - -(defvar whitespace-check-buffer-ateol nil - "Test end-of-line whitespace for file in current buffer if t.") -(make-variable-buffer-local 'whitespace-check-buffer-ateol) -;;;###autoload(put 'whitespace-check-buffer-ateol 'safe-local-variable 'booleanp) - -(defvar whitespace-highlighted-space nil - "The variable to store the extent to highlight.") -(make-variable-buffer-local 'whitespace-highlighted-space) - -(defalias 'whitespace-make-overlay - (if (featurep 'xemacs) 'make-extent 'make-overlay)) -(defalias 'whitespace-overlay-put - (if (featurep 'xemacs) 'set-extent-property 'overlay-put)) -(defalias 'whitespace-delete-overlay - (if (featurep 'xemacs) 'delete-extent 'delete-overlay)) -(defalias 'whitespace-overlay-start - (if (featurep 'xemacs) 'extent-start 'overlay-start)) -(defalias 'whitespace-overlay-end - (if (featurep 'xemacs) 'extent-end 'overlay-end)) -(defalias 'whitespace-mode-line-update - (if (featurep 'xemacs) 'redraw-modeline 'force-mode-line-update)) - -(defgroup whitespace nil - "Check for and fix five different types of whitespaces in source code." - :version "21.1" - :link '(emacs-commentary-link "whitespace.el") - ;; Since XEmacs doesn't have a 'convenience group, use the next best group - ;; which is 'editing? - :group (if (featurep 'xemacs) 'editing 'convenience)) - -(defcustom whitespace-check-leading-whitespace t - "Flag to check leading whitespace. This is the global for the system. -It can be overridden by setting a buffer local variable -`whitespace-check-buffer-leading'." - :type 'boolean - :group 'whitespace) - -(defcustom whitespace-check-trailing-whitespace t - "Flag to check trailing whitespace. This is the global for the system. -It can be overridden by setting a buffer local variable -`whitespace-check-buffer-trailing'." - :type 'boolean - :group 'whitespace) - -(defcustom whitespace-check-spacetab-whitespace t - "Flag to check space followed by a TAB. This is the global for the system. -It can be overridden by setting a buffer local variable -`whitespace-check-buffer-spacetab'." - :type 'boolean - :group 'whitespace) - -(defcustom whitespace-spacetab-regexp "[ ]+\t" - "Regexp to match one or more spaces followed by a TAB." - :type 'regexp - :group 'whitespace) - -(defcustom whitespace-check-indent-whitespace indent-tabs-mode - "Flag to check indentation whitespace. This is the global for the system. -It can be overridden by setting a buffer local variable -`whitespace-check-buffer-indent'." - :type 'boolean - :group 'whitespace) - -(defcustom whitespace-indent-regexp "^\t*\\( \\)+" - "Regexp to match multiples of eight spaces near line beginnings. -The default value ignores leading TABs." - :type 'regexp - :group 'whitespace) - -(defcustom whitespace-check-ateol-whitespace t - "Flag to check end-of-line whitespace. This is the global for the system. -It can be overridden by setting a buffer local variable -`whitespace-check-buffer-ateol'." - :type 'boolean - :group 'whitespace) - -(defcustom whitespace-ateol-regexp "[ \t]+$" - "Regexp to match one or more TABs or spaces at line ends." - :type 'regexp - :group 'whitespace) - -(defcustom whitespace-errbuf "*Whitespace Errors*" - "The name of the buffer where whitespace related messages will be logged." - :type 'string - :group 'whitespace) - -(defcustom whitespace-clean-msg "clean." - "If non-nil, this message will be displayed after a whitespace check -determines a file to be clean." - :type 'string - :group 'whitespace) - -(defcustom whitespace-abort-on-error nil - "While writing a file, abort if the file is unclean. -If `whitespace-auto-cleanup' is set, that takes precedence over -this variable." - :type 'boolean - :group 'whitespace) - -(defcustom whitespace-auto-cleanup nil - "Cleanup a buffer automatically on finding it whitespace unclean." - :type 'boolean - :group 'whitespace) - -(defcustom whitespace-silent nil - "All whitespace errors will be shown only in the modeline when t. - -Note that setting this may cause all whitespaces introduced in a file to go -unnoticed when the buffer is killed, unless the user visits the `*Whitespace -Errors*' buffer before opening (or closing) another file." - :type 'boolean - :group 'whitespace) - -(defcustom whitespace-modes '(ada-mode asm-mode autoconf-mode awk-mode - c-mode c++-mode cc-mode - change-log-mode cperl-mode - electric-nroff-mode emacs-lisp-mode - f90-mode fortran-mode html-mode - html3-mode java-mode jde-mode - ksh-mode latex-mode LaTeX-mode - lisp-mode m4-mode makefile-mode - modula-2-mode nroff-mode objc-mode - pascal-mode perl-mode prolog-mode - python-mode scheme-mode sgml-mode - sh-mode shell-script-mode simula-mode - tcl-mode tex-mode texinfo-mode - vrml-mode xml-mode) - - "Major modes in which we turn on whitespace checking. - -These are mostly programming and documentation modes. But you may add other -modes that you want whitespaces checked in by adding something like the -following to your `.emacs': - -\(setq whitespace-modes (cons 'my-mode (cons 'my-other-mode - whitespace-modes))\) - -Or, alternately, you can use the Emacs `customize' command to set this." - :type '(repeat symbol) - :group 'whitespace) - -(defcustom whitespace-rescan-timer-time 600 - "Period in seconds to rescan modified buffers for whitespace creep. - -This is the period after which the timer will fire causing -`whitespace-rescan-files-in-buffers' to check for whitespace creep in -modified buffers. - -To disable timer scans, set this to zero." - :type 'integer - :group 'whitespace) - -(defcustom whitespace-display-in-modeline t - "Display whitespace errors on the modeline." - :type 'boolean - :group 'whitespace) - -(defcustom whitespace-display-spaces-in-color t - "Display the bogus whitespaces by coloring them with the face -`whitespace-highlight'." - :type 'boolean - :group 'whitespace) - -(defgroup whitespace-faces nil - "Faces used in whitespace." - :prefix "whitespace-" - :group 'whitespace - :group 'faces) - -(defface whitespace-highlight '((((class color) (background light)) - (:background "green1")) - (((class color) (background dark)) - (:background "sea green")) - (((class grayscale mono) - (background light)) - (:background "black")) - (((class grayscale mono) - (background dark)) - (:background "white"))) - "Face used for highlighting the bogus whitespaces that exist in the buffer." - :group 'whitespace-faces) -;; backward-compatibility alias -(put 'whitespace-highlight-face 'face-alias 'whitespace-highlight) - -(if (not (assoc 'whitespace-mode minor-mode-alist)) - (setq minor-mode-alist (cons '(whitespace-mode whitespace-mode-line) - minor-mode-alist))) - -(set-default 'whitespace-check-buffer-leading - whitespace-check-leading-whitespace) -(set-default 'whitespace-check-buffer-trailing - whitespace-check-trailing-whitespace) -(set-default 'whitespace-check-buffer-indent - whitespace-check-indent-whitespace) -(set-default 'whitespace-check-buffer-spacetab - whitespace-check-spacetab-whitespace) -(set-default 'whitespace-check-buffer-ateol - whitespace-check-ateol-whitespace) - -(defun whitespace-check-whitespace-mode (&optional arg) - "Test and set the whitespace-mode in qualifying buffers." - (if (null whitespace-mode) - (setq whitespace-mode - (if (or arg (member major-mode whitespace-modes)) - t - nil)))) - -;;;###autoload -(defun whitespace-toggle-leading-check () - "Toggle the check for leading space in the local buffer." - (interactive) - (let ((current-val whitespace-check-buffer-leading)) - (setq whitespace-check-buffer-leading (not current-val)) - (message "Will%s check for leading space in buffer." - (if whitespace-check-buffer-leading "" " not")) - (if whitespace-check-buffer-leading (whitespace-buffer-leading)))) - -;;;###autoload -(defun whitespace-toggle-trailing-check () - "Toggle the check for trailing space in the local buffer." - (interactive) - (let ((current-val whitespace-check-buffer-trailing)) - (setq whitespace-check-buffer-trailing (not current-val)) - (message "Will%s check for trailing space in buffer." - (if whitespace-check-buffer-trailing "" " not")) - (if whitespace-check-buffer-trailing (whitespace-buffer-trailing)))) - -;;;###autoload -(defun whitespace-toggle-indent-check () - "Toggle the check for indentation space in the local buffer." - (interactive) - (let ((current-val whitespace-check-buffer-indent)) - (setq whitespace-check-buffer-indent (not current-val)) - (message "Will%s check for indentation space in buffer." - (if whitespace-check-buffer-indent "" " not")) - (if whitespace-check-buffer-indent - (whitespace-buffer-search whitespace-indent-regexp)))) - -;;;###autoload -(defun whitespace-toggle-spacetab-check () - "Toggle the check for space-followed-by-TABs in the local buffer." - (interactive) - (let ((current-val whitespace-check-buffer-spacetab)) - (setq whitespace-check-buffer-spacetab (not current-val)) - (message "Will%s check for space-followed-by-TABs in buffer." - (if whitespace-check-buffer-spacetab "" " not")) - (if whitespace-check-buffer-spacetab - (whitespace-buffer-search whitespace-spacetab-regexp)))) - - -;;;###autoload -(defun whitespace-toggle-ateol-check () - "Toggle the check for end-of-line space in the local buffer." - (interactive) - (let ((current-val whitespace-check-buffer-ateol)) - (setq whitespace-check-buffer-ateol (not current-val)) - (message "Will%s check for end-of-line space in buffer." - (if whitespace-check-buffer-ateol "" " not")) - (if whitespace-check-buffer-ateol - (whitespace-buffer-search whitespace-ateol-regexp)))) - - -;;;###autoload -(defun whitespace-buffer (&optional quiet) - "Find five different types of white spaces in buffer. -These are: -1. Leading space \(empty lines at the top of a file\). -2. Trailing space \(empty lines at the end of a file\). -3. Indentation space \(8 or more spaces, that should be replaced with TABS\). -4. Spaces followed by a TAB. \(Almost always, we never want that\). -5. Spaces or TABS at the end of a line. - -Check for whitespace only if this buffer really contains a non-empty file -and: -1. the major mode is one of the whitespace-modes, or -2. `whitespace-buffer' was explicitly called with a prefix argument." - (interactive) - (let ((whitespace-error nil)) - (whitespace-check-whitespace-mode current-prefix-arg) - (if (and buffer-file-name (> (buffer-size) 0) whitespace-mode) - (progn - (whitespace-check-buffer-list (buffer-name) buffer-file-name) - (whitespace-tickle-timer) - (overlay-recenter (point-max)) - (remove-overlays nil nil 'face 'whitespace-highlight) - (if whitespace-auto-cleanup - (if buffer-read-only - (if (not quiet) - (message "Can't cleanup: %s is read-only" (buffer-name))) - (whitespace-cleanup-internal)) - (let ((whitespace-leading (if whitespace-check-buffer-leading - (whitespace-buffer-leading) - nil)) - (whitespace-trailing (if whitespace-check-buffer-trailing - (whitespace-buffer-trailing) - nil)) - (whitespace-indent (if whitespace-check-buffer-indent - (whitespace-buffer-search - whitespace-indent-regexp) - nil)) - (whitespace-spacetab (if whitespace-check-buffer-spacetab - (whitespace-buffer-search - whitespace-spacetab-regexp) - nil)) - (whitespace-ateol (if whitespace-check-buffer-ateol - (whitespace-buffer-search - whitespace-ateol-regexp) - nil)) - (whitespace-errmsg nil) - (whitespace-filename buffer-file-name) - (whitespace-this-modeline "")) - - ;; Now let's complain if we found any of the above. - (setq whitespace-error (or whitespace-leading whitespace-indent - whitespace-spacetab whitespace-ateol - whitespace-trailing)) - - (if whitespace-error - (progn - (setq whitespace-errmsg - (concat whitespace-filename " contains:\n" - (if whitespace-leading - "Leading whitespace\n") - (if whitespace-indent - (concat "Indentation whitespace" - whitespace-indent "\n")) - (if whitespace-spacetab - (concat "Space followed by Tab" - whitespace-spacetab "\n")) - (if whitespace-ateol - (concat "End-of-line whitespace" - whitespace-ateol "\n")) - (if whitespace-trailing - "Trailing whitespace\n") - "\ntype `M-x whitespace-cleanup' to " - "cleanup the file.")) - (setq whitespace-this-modeline - (concat (if whitespace-ateol "e") - (if whitespace-indent "i") - (if whitespace-leading "l") - (if whitespace-spacetab "s") - (if whitespace-trailing "t"))))) - (whitespace-update-modeline whitespace-this-modeline) - (if (get-buffer whitespace-errbuf) - (kill-buffer whitespace-errbuf)) - (with-current-buffer (get-buffer-create whitespace-errbuf) - (if whitespace-errmsg - (progn - (insert whitespace-errmsg) - (if (not (or quiet whitespace-silent)) - (display-buffer (current-buffer) t)) - (if (not quiet) - (message "Whitespaces: [%s%s] in %s" - whitespace-this-modeline - (let ((whitespace-unchecked - (whitespace-unchecked-whitespaces))) - (if whitespace-unchecked - (concat "!" whitespace-unchecked) - "")) - whitespace-filename))) - (if (and (not quiet) (not (equal whitespace-clean-msg ""))) - (message "%s %s" whitespace-filename - whitespace-clean-msg)))))))) - whitespace-error)) - -;;;###autoload -(defun whitespace-region (s e) - "Check the region for whitespace errors." - (interactive "r") - (save-excursion - (save-restriction - (narrow-to-region s e) - (whitespace-buffer)))) - -;;;###autoload -(defun whitespace-cleanup () - "Cleanup the five different kinds of whitespace problems. -It normally applies to the whole buffer, but in Transient Mark mode -when the mark is active it applies to the region. -See `whitespace-buffer' docstring for a summary of the problems." - (interactive) - (if (and transient-mark-mode mark-active) - (whitespace-cleanup-region (region-beginning) (region-end)) - (whitespace-cleanup-internal))) - -(defun whitespace-cleanup-internal (&optional region-only) - ;; If this buffer really contains a file, then run, else quit. - (whitespace-check-whitespace-mode current-prefix-arg) - (if (and buffer-file-name whitespace-mode) - (let ((whitespace-any nil) - (whitespace-tabwith 8) - (whitespace-tabwith-saved tab-width)) - - ;; since all printable TABS should be 8, irrespective of how - ;; they are displayed. - (setq tab-width whitespace-tabwith) - - (if (and whitespace-check-buffer-leading - (whitespace-buffer-leading)) - (progn - (whitespace-buffer-leading-cleanup) - (setq whitespace-any t))) - - (if (and whitespace-check-buffer-trailing - (whitespace-buffer-trailing)) - (progn - (whitespace-buffer-trailing-cleanup) - (setq whitespace-any t))) - - (if (and whitespace-check-buffer-indent - (whitespace-buffer-search whitespace-indent-regexp)) - (progn - (whitespace-indent-cleanup) - (setq whitespace-any t))) - - (if (and whitespace-check-buffer-spacetab - (whitespace-buffer-search whitespace-spacetab-regexp)) - (progn - (whitespace-buffer-cleanup whitespace-spacetab-regexp "\t") - (setq whitespace-any t))) - - (if (and whitespace-check-buffer-ateol - (whitespace-buffer-search whitespace-ateol-regexp)) - (progn - (whitespace-buffer-cleanup whitespace-ateol-regexp "") - (setq whitespace-any t))) - - ;; Call this recursively till everything is taken care of - (if whitespace-any - (whitespace-cleanup-internal region-only) - ;; if we are done, talk to the user - (progn - (unless whitespace-silent - (if region-only - (message "The region is now clean") - (message "%s is now clean" buffer-file-name))) - (whitespace-update-modeline))) - (setq tab-width whitespace-tabwith-saved)))) - -;;;###autoload -(defun whitespace-cleanup-region (s e) - "Whitespace cleanup on the region." - (interactive "r") - (save-excursion - (save-restriction - (narrow-to-region s e) - (whitespace-cleanup-internal t)) - (whitespace-buffer t))) - -(defun whitespace-buffer-leading () - "Return t if the current buffer has leading newline characters. -If highlighting is enabled, highlight these characters." - (save-excursion - (goto-char (point-min)) - (skip-chars-forward "\n") - (unless (bobp) - (whitespace-highlight-the-space (point-min) (point)) - t))) - -(defun whitespace-buffer-leading-cleanup () - "Remove any leading newline characters from current buffer." - (save-excursion - (goto-char (point-min)) - (skip-chars-forward "\n") - (delete-region (point-min) (point)))) - -(defun whitespace-buffer-trailing () - "Return t if the current buffer has extra trailing newline characters. -If highlighting is enabled, highlight these characters." - (save-excursion - (goto-char (point-max)) - (skip-chars-backward "\n") - (forward-line) - (unless (eobp) - (whitespace-highlight-the-space (point) (point-max)) - t))) - -(defun whitespace-buffer-trailing-cleanup () - "Remove extra trailing newline characters from current buffer." - (save-excursion - (goto-char (point-max)) - (skip-chars-backward "\n") - (unless (eobp) - (forward-line) - (delete-region (point) (point-max))))) - -(defun whitespace-buffer-search (regexp) - "Search for any given whitespace REGEXP." - (with-local-quit - (let (whitespace-retval) - (save-excursion - (goto-char (point-min)) - (while (re-search-forward regexp nil t) - (whitespace-highlight-the-space (match-beginning 0) (match-end 0)) - (push (match-beginning 0) whitespace-retval))) - (when whitespace-retval - (format " %s" (nreverse whitespace-retval)))))) - -(defun whitespace-buffer-cleanup (regexp newregexp) - "Search for any given whitespace REGEXP and replace it with the NEWREGEXP." - (save-excursion - (goto-char (point-min)) - (while (re-search-forward regexp nil t) - (replace-match newregexp)))) - -(defun whitespace-indent-cleanup () - "Search for 8/more spaces at the start of a line and replace it with tabs." - (save-excursion - (goto-char (point-min)) - (while (re-search-forward whitespace-indent-regexp nil t) - (let ((column (current-column)) - (indent-tabs-mode t)) - (delete-region (match-beginning 0) (point)) - (indent-to column))))) - -(defun whitespace-unchecked-whitespaces () - "Return the list of whitespaces whose testing has been suppressed." - (let ((unchecked-spaces - (concat (if (not whitespace-check-buffer-ateol) "e") - (if (not whitespace-check-buffer-indent) "i") - (if (not whitespace-check-buffer-leading) "l") - (if (not whitespace-check-buffer-spacetab) "s") - (if (not whitespace-check-buffer-trailing) "t")))) - (if (not (equal unchecked-spaces "")) - unchecked-spaces - nil))) - -(defun whitespace-update-modeline (&optional whitespace-err) - "Update modeline with whitespace errors. -Also with whitespaces whose testing has been turned off." - (if whitespace-display-in-modeline - (progn - (setq whitespace-mode-line nil) - ;; Whitespace errors - (if (and whitespace-err (not (equal whitespace-err ""))) - (setq whitespace-mode-line whitespace-err)) - ;; Whitespace suppressed errors - (let ((whitespace-unchecked (whitespace-unchecked-whitespaces))) - (if whitespace-unchecked - (setq whitespace-mode-line - (concat whitespace-mode-line "!" whitespace-unchecked)))) - ;; Add the whitespace modeline prefix - (setq whitespace-mode-line (if whitespace-mode-line - (concat " W:" whitespace-mode-line) - nil)) - (whitespace-mode-line-update)))) - -(defun whitespace-highlight-the-space (b e) - "Highlight the current line, unhighlighting a previously jumped to line." - (if whitespace-display-spaces-in-color - (let ((ol (whitespace-make-overlay b e))) - (whitespace-overlay-put ol 'face 'whitespace-highlight)))) - -(defun whitespace-unhighlight-the-space() - "Unhighlight the currently highlight line." - (if (and whitespace-display-spaces-in-color whitespace-highlighted-space) - (progn - (mapc 'whitespace-delete-overlay whitespace-highlighted-space) - (setq whitespace-highlighted-space nil)))) - -(defun whitespace-check-buffer-list (buf-name buf-file) - "Add a buffer and its file to the whitespace monitor list. - -The buffer named BUF-NAME and its associated file BUF-FILE are now monitored -periodically for whitespace." - (if (and whitespace-mode (not (member (list buf-file buf-name) - whitespace-all-buffer-files))) - (add-to-list 'whitespace-all-buffer-files (list buf-file buf-name)))) - -(defun whitespace-tickle-timer () - "Tickle timer to periodically to scan qualifying files for whitespace creep. - -If timer is not set, then set it to scan the files in -`whitespace-all-buffer-files' periodically (defined by -`whitespace-rescan-timer-time') for whitespace creep." - (if (and whitespace-rescan-timer-time - (/= whitespace-rescan-timer-time 0) - (not whitespace-rescan-timer)) - (setq whitespace-rescan-timer - (add-timeout whitespace-rescan-timer-time - 'whitespace-rescan-files-in-buffers nil - whitespace-rescan-timer-time)))) - -(defun whitespace-rescan-files-in-buffers (&optional arg) - "Check monitored files for whitespace creep since last scan." - (let ((whitespace-all-my-files whitespace-all-buffer-files) - buffile bufname thiselt buf) - (if (not whitespace-all-my-files) - (progn - (disable-timeout whitespace-rescan-timer) - (setq whitespace-rescan-timer nil)) - (while whitespace-all-my-files - (setq thiselt (car whitespace-all-my-files)) - (setq whitespace-all-my-files (cdr whitespace-all-my-files)) - (setq buffile (car thiselt)) - (setq bufname (cadr thiselt)) - (setq buf (get-buffer bufname)) - (if (buffer-live-p buf) - (save-excursion - ;;(message "buffer %s live" bufname) - (set-buffer bufname) - (if whitespace-mode - (progn - ;;(message "checking for whitespace in %s" bufname) - (if whitespace-auto-cleanup - (progn - ;;(message "cleaning up whitespace in %s" bufname) - (whitespace-cleanup-internal)) - (progn - ;;(message "whitespace-buffer %s." (buffer-name)) - (whitespace-buffer t)))) - ;;(message "Removing %s from refresh list" bufname) - (whitespace-refresh-rescan-list buffile bufname))) - ;;(message "Removing %s from refresh list" bufname) - (whitespace-refresh-rescan-list buffile bufname)))))) - -(defun whitespace-refresh-rescan-list (buffile bufname) - "Refresh the list of files to be rescanned for whitespace creep." - (if whitespace-all-buffer-files - (setq whitespace-all-buffer-files - (delete (list buffile bufname) whitespace-all-buffer-files)) - (when whitespace-rescan-timer - (disable-timeout whitespace-rescan-timer) - (setq whitespace-rescan-timer nil)))) - -;;;###autoload -(defalias 'global-whitespace-mode 'whitespace-global-mode) - -;;;###autoload -(define-minor-mode whitespace-global-mode - "Toggle using Whitespace mode in new buffers. -With ARG, turn the mode on if ARG is positive, otherwise turn it off. - -When this mode is active, `whitespace-buffer' is added to -`find-file-hook' and `kill-buffer-hook'." - :global t - :group 'whitespace - (if whitespace-global-mode - (progn - (add-hook 'find-file-hook 'whitespace-buffer) - (add-hook 'write-file-functions 'whitespace-write-file-hook nil t) - (add-hook 'kill-buffer-hook 'whitespace-buffer)) - (remove-hook 'find-file-hook 'whitespace-buffer) - (remove-hook 'write-file-functions 'whitespace-write-file-hook t) - (remove-hook 'kill-buffer-hook 'whitespace-buffer))) - -;;;###autoload -(defun whitespace-write-file-hook () - "Hook function to be called on the buffer when whitespace check is enabled. -This is meant to be added buffer-locally to `write-file-functions'." - (let ((werr nil)) - (if whitespace-auto-cleanup - (whitespace-cleanup-internal) - (setq werr (whitespace-buffer))) - (if (and whitespace-abort-on-error werr) - (error "Abort write due to whitespaces in %s" - buffer-file-name))) - nil) - -(defun whitespace-unload-function () - "Unload the whitespace library." - (if (unintern "whitespace-unload-hook") - ;; if whitespace-unload-hook is defined, let's get rid of it - ;; and recursively call `unload-feature' - (progn (unload-feature 'whitespace) t) - ;; this only happens in the recursive call - (whitespace-global-mode -1) - (save-current-buffer - (dolist (buf (buffer-list)) - (set-buffer buf) - (remove-hook 'write-file-functions 'whitespace-write-file-hook t))) - ;; continue standard unloading - nil)) - -(defun whitespace-unload-hook () - (remove-hook 'find-file-hook 'whitespace-buffer) - (remove-hook 'write-file-functions 'whitespace-write-file-hook t) - (remove-hook 'kill-buffer-hook 'whitespace-buffer)) - -(add-hook 'whitespace-unload-hook 'whitespace-unload-hook) - -(provide 'whitespace) - -;; arch-tag: 4ff44e87-b63c-402d-95a6-15e51e58bd0c -;;; whitespace.el ends here From 513feaa5ad09fe4ef1332bfc1e5eb7bca57fa1ba Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Mon, 28 Jan 2008 17:44:11 +0000 Subject: [PATCH 403/439] (stat): Don't do a double check for networked drive. --- src/w32.c | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/src/w32.c b/src/w32.c index dfec1dc8f8a..2395c236769 100644 --- a/src/w32.c +++ b/src/w32.c @@ -2592,8 +2592,7 @@ stat (const char * path, struct stat * buf) } else { - if (IS_DIRECTORY_SEP (name[0]) && IS_DIRECTORY_SEP (name[1])) - logon_network_drive (name); + logon_network_drive (name); fh = FindFirstFile (name, &wfd); if (fh == INVALID_HANDLE_VALUE) From 10ef2ef78a0f1a25c7bf4176771fda524619446e Mon Sep 17 00:00:00 2001 From: Reiner Steib Date: Mon, 28 Jan 2008 18:49:55 +0000 Subject: [PATCH 404/439] Remove bogus spaces. --- lisp/gnus/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/gnus/ChangeLog b/lisp/gnus/ChangeLog index 94a976c8e65..f3b41740f3e 100644 --- a/lisp/gnus/ChangeLog +++ b/lisp/gnus/ChangeLog @@ -1,4 +1,4 @@ -2008-01-24 Michael Sperber +2008-01-24 Michael Sperber * mail-source.el (mail-sources): Add `group' choice. From ef264c42097f5317044f6a85f895588184c2dbdd Mon Sep 17 00:00:00 2001 From: Stefan Monnier Date: Mon, 28 Jan 2008 19:05:13 +0000 Subject: [PATCH 405/439] * window.c (run_window_configuration_change_hook): New function. Code extracted from set_window_buffer. Set the selected frame. (set_window_buffer): Use it. * window.h (run_window_configuration_change_hook): Declare. * dispnew.c (change_frame_size_1): Use it instead of set-window-buffer. --- src/ChangeLog | 6 ++++++ src/dispnew.c | 4 +--- src/window.c | 24 ++++++++++++++++++++---- src/window.h | 1 + 4 files changed, 28 insertions(+), 7 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 3986b4f9284..0d1a18ef2ca 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,5 +1,11 @@ 2008-01-28 Stefan Monnier + * window.c (run_window_configuration_change_hook): New function. + Code extracted from set_window_buffer. Set the selected frame. + (set_window_buffer): Use it. + * window.h (run_window_configuration_change_hook): Declare. + * dispnew.c (change_frame_size_1): Use it instead of set-window-buffer. + * keyboard.c (read_char): Yet another int/Lisp_Object mixup (YAILOM). 2008-01-27 Dan Nicolaescu diff --git a/src/dispnew.c b/src/dispnew.c index ab0f581b53d..284e1fde4bd 100644 --- a/src/dispnew.c +++ b/src/dispnew.c @@ -6386,9 +6386,7 @@ change_frame_size_1 (f, newheight, newwidth, pretend, delay, safe) record_unwind_protect (Fset_buffer, Fcurrent_buffer ()); - /* This isn't quite a no-op: it runs window-configuration-change-hook. */ - Fset_window_buffer (FRAME_SELECTED_WINDOW (f), - XWINDOW (FRAME_SELECTED_WINDOW (f))->buffer, Qt); + run_window_configuration_change_hook (f); unbind_to (count, Qnil); } diff --git a/src/window.c b/src/window.c index bf36cbc032f..5b0d8f4375a 100644 --- a/src/window.c +++ b/src/window.c @@ -3307,6 +3307,25 @@ Fset_window_buffer_unwind (obuf) EXFUN (Fset_window_fringes, 4); EXFUN (Fset_window_scroll_bars, 4); +void +run_window_configuration_change_hook (struct frame *f) +{ + if (! NILP (Vwindow_configuration_change_hook) + && ! NILP (Vrun_hooks)) + { + int count = SPECPDL_INDEX (); + if (SELECTED_FRAME () != f) + { + Lisp_Object frame; + XSETFRAME (frame, f); + record_unwind_protect (Fselect_frame, Fselected_frame ()); + Fselect_frame (frame); + } + call1 (Vrun_hooks, Qwindow_configuration_change_hook); + unbind_to (count, Qnil); + } +} + /* Make WINDOW display BUFFER as its contents. RUN_HOOKS_P non-zero means it's allowed to run hooks. See make_frame for a case where it's not allowed. KEEP_MARGINS_P non-zero means that the current @@ -3408,10 +3427,7 @@ set_window_buffer (window, buffer, run_hooks_p, keep_margins_p) if (! NILP (Vwindow_scroll_functions)) run_hook_with_args_2 (Qwindow_scroll_functions, window, Fmarker_position (w->start)); - - if (! NILP (Vwindow_configuration_change_hook) - && ! NILP (Vrun_hooks)) - call1 (Vrun_hooks, Qwindow_configuration_change_hook); + run_window_configuration_change_hook (XFRAME (WINDOW_FRAME (w))); } unbind_to (count, Qnil); diff --git a/src/window.h b/src/window.h index fb56be8bfb7..b2c62fde01f 100644 --- a/src/window.h +++ b/src/window.h @@ -790,6 +790,7 @@ extern void foreach_window P_ ((struct frame *, extern void grow_mini_window P_ ((struct window *, int)); extern void shrink_mini_window P_ ((struct window *)); +void run_window_configuration_change_hook (struct frame *f); /* Make WINDOW display BUFFER as its contents. RUN_HOOKS_P non-zero means it's allowed to run hooks. See make_frame for a case where From b8bfcf96e8e78484cccade13fdb6a8a8697a66b9 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Mon, 28 Jan 2008 21:25:26 +0000 Subject: [PATCH 406/439] * net/tramp.el (tramp-handle-shell-command): Use "/bin/sh -c" for the command. --- lisp/ChangeLog | 5 +++++ lisp/net/tramp.el | 4 +++- 2 files changed, 8 insertions(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 1e2dcf1e558..d467535a186 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,8 @@ +2008-01-28 Michael Albinus + + * net/tramp.el (tramp-handle-shell-command): Use "/bin/sh -c" for + the command. + 2008-01-28 Vinicius Jose Latorre * whitespace.el: Moved to obsolete dir. diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index b9e6a279644..eb68c8302aa 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -3781,7 +3781,9 @@ Lisp error raised when PROGRAM is nil is trapped also, returning 1." (command &optional output-buffer error-buffer) "Like `shell-command' for Tramp files." (let* ((asynchronous (string-match "[ \t]*&[ \t]*\\'" command)) - (args (split-string (substring command 0 asynchronous) " ")) + ;; We cannot use `shell-file-name' and `shell-command-switch', + ;; they are variables of the local host. + (args (list "/bin/sh" "-c" (substring command 0 asynchronous))) (output-buffer (cond ((bufferp output-buffer) output-buffer) From 548667aad86a5e07e5ac96b832dcd10c5e6eb4c6 Mon Sep 17 00:00:00 2001 From: Jason Rumney Date: Mon, 28 Jan 2008 23:23:48 +0000 Subject: [PATCH 407/439] *** empty log message *** --- src/ChangeLog | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/src/ChangeLog b/src/ChangeLog index 0d1a18ef2ca..92cd97146f7 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-28 Jason Rumney + + * w32.c (stat): Don't double check for networked drive. + 2008-01-28 Stefan Monnier * window.c (run_window_configuration_change_hook): New function. From e652840bf703a633979983552556434f6753397b Mon Sep 17 00:00:00 2001 From: John Wiegley Date: Tue, 29 Jan 2008 03:52:05 +0000 Subject: [PATCH 408/439] 2008-01-29 John Wiegley * url-auth.el (url-digest-auth): If the 'opaque' argument is not being used, don't add it to the response text. Also, changed an if so that the interaction between the PROMPT and OVERWRITE arguments can no longer result in the user being queried twice for the same login and password information. --- lisp/url/ChangeLog | 8 +++++++ lisp/url/url-auth.el | 51 ++++++++++++++++++++++++++------------------ 2 files changed, 38 insertions(+), 21 deletions(-) diff --git a/lisp/url/ChangeLog b/lisp/url/ChangeLog index 124f3fc9974..3a70b5343a0 100644 --- a/lisp/url/ChangeLog +++ b/lisp/url/ChangeLog @@ -1,3 +1,11 @@ +2008-01-29 John Wiegley + + * url-auth.el (url-digest-auth): If the 'opaque' argument is not + being used, don't add it to the response text. Also, changed an + if so that the interaction between the PROMPT and OVERWRITE + arguments can no longer result in the user being queried twice for + the same login and password information. + 2008-01-21 Stefan Monnier * url-handlers.el (unhandled-file-name-directory): Add handler. diff --git a/lisp/url/url-auth.el b/lisp/url/url-auth.el index ea96bb08129..ed1a79260ee 100644 --- a/lisp/url/url-auth.el +++ b/lisp/url/url-auth.el @@ -188,31 +188,40 @@ instead of hostname:portnum." (string= data (substring file 0 (length data))))) (setq retval (cdr (car byserv)))) (setq byserv (cdr byserv)))) - (if (or (and (not retval) prompt) overwrite) - (progn - (setq user (read-string (url-auth-user-prompt url realm) - (user-real-login-name)) - pass (read-passwd "Password: ") - retval (setq retval - (cons user - (url-digest-auth-create-key - user pass realm - (or url-request-method "GET") - url))) - byserv (assoc server url-digest-auth-storage)) + (if overwrite + (if (and (not retval) prompt) + (setq user (read-string (url-auth-user-prompt url realm) + (user-real-login-name)) + pass (read-passwd "Password: ") + retval (setq retval + (cons user + (url-digest-auth-create-key + user pass realm + (or url-request-method "GET") + url))) + byserv (assoc server url-digest-auth-storage)) (setcdr byserv (cons (cons file retval) (cdr byserv)))))) (t (setq retval nil))) (if retval - (let ((nonce (or (cdr-safe (assoc "nonce" args)) "nonegiven")) - (opaque (or (cdr-safe (assoc "opaque" args)) "nonegiven"))) - (format - (concat "Digest username=\"%s\", realm=\"%s\"," - "nonce=\"%s\", uri=\"%s\"," - "response=\"%s\", opaque=\"%s\"") - (nth 0 retval) realm nonce (url-filename href) - (md5 (concat (nth 1 retval) ":" nonce ":" - (nth 2 retval))) opaque)))))) + (if (cdr-safe (assoc "opaque" args)) + (let ((nonce (or (cdr-safe (assoc "nonce" args)) "nonegiven")) + (opaque (cdr-safe (assoc "opaque" args)))) + (format + (concat "Digest username=\"%s\", realm=\"%s\"," + "nonce=\"%s\", uri=\"%s\"," + "response=\"%s\", opaque=\"%s\"") + (nth 0 retval) realm nonce (url-filename href) + (md5 (concat (nth 1 retval) ":" nonce ":" + (nth 2 retval))) opaque)) + (let ((nonce (or (cdr-safe (assoc "nonce" args)) "nonegiven"))) + (format + (concat "Digest username=\"%s\", realm=\"%s\"," + "nonce=\"%s\", uri=\"%s\"," + "response=\"%s\"") + (nth 0 retval) realm nonce (url-filename href) + (md5 (concat (nth 1 retval) ":" nonce ":" + (nth 2 retval)))))))))) (defvar url-registered-auth-schemes nil "A list of the registered authorization schemes and various and sundry From 8b329dbaa78f6bea288ad4326914629197f757a1 Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Tue, 29 Jan 2008 05:12:00 +0000 Subject: [PATCH 409/439] src/macterm.c (XTset_vertical_scroll_bar): Fix merge mistake Revision: emacs@sv.gnu.org/emacs--devo--0--patch-1020 --- src/ChangeLog | 4 ++++ src/macterm.c | 2 +- 2 files changed, 5 insertions(+), 1 deletion(-) diff --git a/src/ChangeLog b/src/ChangeLog index 92cd97146f7..0645765cdde 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,7 @@ +2008-01-29 Miles Bader + + * macterm.c (XTset_vertical_scroll_bar): Fix merge mistake. + 2008-01-28 Jason Rumney * w32.c (stat): Don't double check for networked drive. diff --git a/src/macterm.c b/src/macterm.c index 58de15cace0..7ffcbf55e9a 100644 --- a/src/macterm.c +++ b/src/macterm.c @@ -5300,7 +5300,7 @@ XTset_vertical_scroll_bar (w, portion, whole, position) #if USE_CG_DRAWING mac_prepare_for_quickdraw (f); #endif - Draw1Control (SCROLL_BAR_CONTROL_HANDLE (bar)); + Draw1Control (SCROLL_BAR_CONTROL_REF (bar)); } } else From 17cb69a5ae5be8e51528480a3fc12ff996097de3 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Tue, 29 Jan 2008 10:41:42 +0000 Subject: [PATCH 410/439] *** empty log message *** --- lisp/ChangeLog | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 02b3cef22bf..4e454acfc8e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -11,12 +11,12 @@ 2008-01-26 Alan Mackenzie - * progmodes/cc-vars.el (c-hanging-braces-alist): new element for + * progmodes/cc-vars.el (c-hanging-braces-alist): New element for arglist-cont-nonempty. * progmodes/cc-cmds.el (c-brace-newlines): Determine the newlines for a brace with syntax arglist-cont-nonempty. - + * progmodes/cc-styles.el (c-style-alist): Add elements for arglist-cont-nonempty into 5 styles (gnu, ellemtel, linux, python, awk). @@ -31,7 +31,7 @@ * progmodes/etags.el (tags-query-replace): Doc fix. -2008-01-26 Phil Sung (tiny change) +2008-01-26 Phil Sung (tiny change) * wdired.el (wdired-get-filename): Change `(1+ beg)' to `beg' so that the filename end is found even when the filename is empty. From 36e1c289c7d381817583d5b06e013550f56b0b8b Mon Sep 17 00:00:00 2001 From: Tassilo Horn Date: Tue, 29 Jan 2008 13:49:05 +0000 Subject: [PATCH 411/439] 2008-01-29 Tassilo Horn * image-mode.el (image-mode-current-vscroll) (image-mode-current-hscroll): New variables. (image-set-window-hscroll, image-set-window-vscroll): New functions. (image-forward-hscroll, image-next-line, image-bol, image-eol) (image-bob, image-eob): Use them. (image-reset-current-vhscroll): New function. (image-mode): Make new variables buffer-local and reset [vh]scroll on window configuration changes. --- lisp/image-mode.el | 70 +++++++++++++++++++++++++++++++--------------- 1 file changed, 47 insertions(+), 23 deletions(-) diff --git a/lisp/image-mode.el b/lisp/image-mode.el index 6b02db50134..7af8d0f82da 100644 --- a/lisp/image-mode.el +++ b/lisp/image-mode.el @@ -50,22 +50,37 @@ ;;; Image scrolling functions +(defvar image-mode-current-vscroll nil) +(defvar image-mode-current-hscroll nil) + +(defun image-set-window-vscroll (window vscroll &optional pixels-p) + (setq image-mode-current-vscroll vscroll) + (set-window-vscroll window vscroll pixels-p)) + +(defun image-set-window-hscroll (window ncol) + (setq image-mode-current-hscroll ncol) + (set-window-hscroll window ncol)) + +(defun image-reset-current-vhscroll () + (set-window-hscroll (selected-window) image-mode-current-hscroll) + (set-window-vscroll (selected-window) image-mode-current-vscroll)) + (defun image-forward-hscroll (&optional n) "Scroll image in current window to the left by N character widths. Stop if the right edge of the image is reached." (interactive "p") (cond ((= n 0) nil) ((< n 0) - (set-window-hscroll (selected-window) - (max 0 (+ (window-hscroll) n)))) + (image-set-window-hscroll (selected-window) + (max 0 (+ (window-hscroll) n)))) (t (let* ((image (get-char-property (point-min) 'display)) (edges (window-inside-edges)) (win-width (- (nth 2 edges) (nth 0 edges))) (img-width (ceiling (car (image-size image))))) - (set-window-hscroll (selected-window) - (min (max 0 (- img-width win-width)) - (+ n (window-hscroll)))))))) + (image-set-window-hscroll (selected-window) + (min (max 0 (- img-width win-width)) + (+ n (window-hscroll)))))))) (defun image-backward-hscroll (&optional n) "Scroll image in current window to the right by N character widths. @@ -79,16 +94,16 @@ Stop if the bottom edge of the image is reached." (interactive "p") (cond ((= n 0) nil) ((< n 0) - (set-window-vscroll (selected-window) - (max 0 (+ (window-vscroll) n)))) + (image-set-window-vscroll (selected-window) + (max 0 (+ (window-vscroll) n)))) (t (let* ((image (get-char-property (point-min) 'display)) (edges (window-inside-edges)) (win-height (- (nth 3 edges) (nth 1 edges))) (img-height (ceiling (cdr (image-size image))))) - (set-window-vscroll (selected-window) - (min (max 0 (- img-height win-height)) - (+ n (window-vscroll)))))))) + (image-set-window-vscroll (selected-window) + (min (max 0 (- img-height win-height)) + (+ n (window-vscroll)))))))) (defun image-previous-line (&optional n) "Scroll image in current window downward by N lines. @@ -146,7 +161,7 @@ stopping if the top or bottom edge of the image is reached." (and arg (/= (setq arg (prefix-numeric-value arg)) 1) (image-next-line (- arg 1))) - (set-window-hscroll (selected-window) 0)) + (image-set-window-hscroll (selected-window) 0)) (defun image-eol (arg) "Scroll horizontally to the right edge of the image in the current window. @@ -160,14 +175,14 @@ stopping if the top or bottom edge of the image is reached." (edges (window-inside-edges)) (win-width (- (nth 2 edges) (nth 0 edges))) (img-width (ceiling (car (image-size image))))) - (set-window-hscroll (selected-window) - (max 0 (- img-width win-width))))) + (image-set-window-hscroll (selected-window) + (max 0 (- img-width win-width))))) (defun image-bob () "Scroll to the top-left corner of the image in the current window." (interactive) - (set-window-hscroll (selected-window) 0) - (set-window-vscroll (selected-window) 0)) + (image-set-window-hscroll (selected-window) 0) + (image-set-window-vscroll (selected-window) 0)) (defun image-eob () "Scroll to the bottom-right corner of the image in the current window." @@ -178,8 +193,8 @@ stopping if the top or bottom edge of the image is reached." (img-width (ceiling (car (image-size image)))) (win-height (- (nth 3 edges) (nth 1 edges))) (img-height (ceiling (cdr (image-size image))))) - (set-window-hscroll (selected-window) (max 0 (- img-width win-width))) - (set-window-vscroll (selected-window) (max 0 (- img-height win-height))))) + (image-set-window-hscroll (selected-window) (max 0 (- img-width win-width))) + (image-set-window-vscroll (selected-window) (max 0 (- img-height win-height))))) ;;; Image Mode setup @@ -224,6 +239,15 @@ to toggle between display as an image and display as text." ;; Use our own bookmarking function for images. (set (make-local-variable 'bookmark-make-cell-function) 'image-bookmark-make-cell) + + ;; Keep track of [vh]scroll when switching buffers + (set (make-local-variable 'image-mode-current-hscroll) + (window-hscroll (selected-window))) + (set (make-local-variable 'image-mode-current-vscroll) + (window-vscroll (selected-window))) + (add-hook 'window-configuration-change-hook + 'image-reset-current-vhscroll nil t) + (add-hook 'change-major-mode-hook 'image-toggle-display-text nil t) (if (and (display-images-p) (not (get-char-property (point-min) 'display))) @@ -255,9 +279,9 @@ See the command `image-mode' for more information on this mode." (setq image-type "text")) (add-hook 'change-major-mode-hook (lambda () (image-minor-mode -1)) nil t) (message "%s" (concat (substitute-command-keys - "Type \\[image-toggle-display] to view the image as ") - (if (get-char-property (point-min) 'display) - "text" "an image") ".")))) + "Type \\[image-toggle-display] to view the image as ") + (if (get-char-property (point-min) 'display) + "text" "an image") ".")))) ;;;###autoload (defun image-mode-maybe () @@ -333,9 +357,9 @@ and showing the image as an image." (image (create-image file-or-data type data-p)) (props `(display ,image - intangible ,image - rear-nonsticky (display intangible) - read-only t front-sticky (read-only))) + intangible ,image + rear-nonsticky (display intangible) + read-only t front-sticky (read-only))) (inhibit-read-only t) (buffer-undo-list t) (modified (buffer-modified-p))) From 6f70aa334f6f388d2ea86e8e14747f6bb11e6795 Mon Sep 17 00:00:00 2001 From: Tassilo Horn Date: Tue, 29 Jan 2008 13:50:35 +0000 Subject: [PATCH 412/439] 2008-01-29 Tassilo Horn * doc-view.el (doc-view-mode): Use facilities of image-mode to restore [vh]scroll when switching buffers. --- lisp/ChangeLog | 15 +++++++++++++++ lisp/doc-view.el | 9 +++++++++ 2 files changed, 24 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 51a033602ff..5c68efb5298 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,18 @@ +2008-01-29 Tassilo Horn + + * doc-view.el (doc-view-mode): Use facilities below to + restore [vh]scroll when switching buffers. + + * image-mode.el (image-mode-current-vscroll) + (image-mode-current-hscroll): New variables. + (image-set-window-hscroll, image-set-window-vscroll): New + functions. + (image-forward-hscroll, image-next-line, image-bol, image-eol) + (image-bob, image-eob): Use them. + (image-reset-current-vhscroll): New function. + (image-mode): Make new variables buffer-local and reset [vh]scroll + on window configuration changes. + 2008-01-27 Nick Roberts * progmodes/gdb-ui.el (gdb-create-define-alist): Don't call diff --git a/lisp/doc-view.el b/lisp/doc-view.el index 034eace3dfb..047785e844c 100644 --- a/lisp/doc-view.el +++ b/lisp/doc-view.el @@ -987,6 +987,15 @@ toggle between displaying the document or editing it as text." (add-hook 'change-major-mode-hook (lambda () (delete-overlay doc-view-current-overlay)) nil t) + + ;; Keep track of [vh]scroll when switching buffers + (set (make-local-variable 'image-mode-current-hscroll) + (window-hscroll (selected-window))) + (set (make-local-variable 'image-mode-current-vscroll) + (window-vscroll (selected-window))) + (add-hook 'window-configuration-change-hook + 'image-reset-current-vhscroll nil t) + (set (make-local-variable 'mode-line-position) '(" P" (:eval (number-to-string doc-view-current-page)) "/" (:eval (number-to-string (length doc-view-current-files))))) From 66381027737a926f4309a86b0b1bab24d0dad381 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Tue, 29 Jan 2008 14:45:13 +0000 Subject: [PATCH 413/439] (hack-local-variables): Don't query about fake variables. --- lisp/files.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lisp/files.el b/lisp/files.el index ea327f48f2c..7c0557cd5ad 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -2767,7 +2767,8 @@ is specified, returning t if it is specified." (dolist (elt result) (let ((var (car elt)) (val (cdr elt))) - (or (eq var 'mode) + ;; Don't query about the fake variables. + (or (memq var '(mode unibyte coding)) (and (eq var 'eval) (or (eq enable-local-eval t) (hack-one-local-variable-eval-safep From c575e6587e4bea7e181bc8a2b09e57ee0e4a11a1 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Tue, 29 Jan 2008 14:49:10 +0000 Subject: [PATCH 414/439] (tags-query-replace): Delete unused optional args. Doc fix. --- lisp/ChangeLog | 7 +++++++ lisp/progmodes/etags.el | 7 +++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 4e454acfc8e..591a159d4d6 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,10 @@ +2008-01-29 Richard Stallman + + * progmodes/etags.el (tags-query-replace): Delete unused optional args. + Doc fix. + + * files.el (hack-local-variables): Don't query about fake variables. + 2008-01-27 Nick Roberts * progmodes/gdb-ui.el (gdb-create-define-alist): Don't call diff --git a/lisp/progmodes/etags.el b/lisp/progmodes/etags.el index a22853fb404..0a66560f827 100644 --- a/lisp/progmodes/etags.el +++ b/lisp/progmodes/etags.el @@ -1815,7 +1815,7 @@ See documentation of variable `tags-file-name'." (tags-loop-continue (or file-list-form t)))) ;;;###autoload -(defun tags-query-replace (from to &optional delimited file-list-form start end) +(defun tags-query-replace (from to &optional delimited file-list-form) "Do `query-replace-regexp' of FROM with TO on all files listed in tags table. Third arg DELIMITED (prefix arg) means replace only word-delimited matches. If you exit (\\[keyboard-quit], RET or q), you can resume the query replace @@ -1824,7 +1824,10 @@ Fourth arg FILE-LIST-FORM non-nil means initialize the replacement loop. Fifth and sixth arguments START and END are accepted, for compatibility with `query-replace-regexp', and ignored. -See also documentation of the variable `tags-file-name'." +If FILE-LIST-FORM is non-nil, it is a form to evaluate to +produce the list of files to search. + +See also the documentation of the variable `tags-file-name'." (interactive (query-replace-read-args "Tags query replace (regexp)" t t)) (setq tags-loop-scan `(let ,(unless (equal from (downcase from)) '((case-fold-search nil))) From 5c8a04f1a93e11538bf895b1755465aa45e244c9 Mon Sep 17 00:00:00 2001 From: Martin Rudalics Date: Tue, 29 Jan 2008 17:40:19 +0000 Subject: [PATCH 415/439] (find-function-search-for-symbol): Strip extension from .emacs.el to make sure symbol is searched in .emacs too. --- lisp/ChangeLog | 6 ++++++ lisp/emacs-lisp/find-func.el | 8 ++++++-- 2 files changed, 12 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 5c68efb5298..d3525398265 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,9 @@ +2008-01-29 Martin Rudalics + + * emacs-lisp/find-func.el (find-function-search-for-symbol): + Strip extension from .emacs.el to make sure symbol is searched + in .emacs too. + 2008-01-29 Tassilo Horn * doc-view.el (doc-view-mode): Use facilities below to diff --git a/lisp/emacs-lisp/find-func.el b/lisp/emacs-lisp/find-func.el index 58695e95347..85f3fe941b7 100644 --- a/lisp/emacs-lisp/find-func.el +++ b/lisp/emacs-lisp/find-func.el @@ -239,8 +239,12 @@ The search is done in the source for library LIBRARY." (setq symbol (get symbol 'definition-name))) (if (string-match "\\`src/\\(.*\\.c\\)\\'" library) (find-function-C-source symbol (match-string 1 library) type) - (if (string-match "\\.el\\(c\\)\\'" library) - (setq library (substring library 0 (match-beginning 1)))) + (when (string-match "\\.el\\(c\\)\\'" library) + (setq library (substring library 0 (match-beginning 1)))) + ;; Strip extension from .emacs.el to make sure symbol is searched in + ;; .emacs too. + (when (string-match "\\.emacs\\(.el\\)" library) + (setq library (substring library 0 (match-beginning 1)))) (let* ((filename (find-library-name library)) (regexp-symbol (cdr (assq type find-function-regexp-alist)))) (with-current-buffer (find-file-noselect filename) From 54089c0eea82caf34ce360cac85c39bd74a3df8a Mon Sep 17 00:00:00 2001 From: Tassilo Horn Date: Tue, 29 Jan 2008 18:00:40 +0000 Subject: [PATCH 416/439] * image-mode.el (image-mode-current-vscroll) (image-mode-current-hscroll): Add doc strings. (image-set-window-vscroll, image-set-window-hscroll) (image-reset-current-vhscroll, image-mode): Adapt to i-m-current-[vh]scroll being an alist now. --- lisp/image-mode.el | 32 ++++++++++++++++++++++---------- 1 file changed, 22 insertions(+), 10 deletions(-) diff --git a/lisp/image-mode.el b/lisp/image-mode.el index 7af8d0f82da..55caae9a91d 100644 --- a/lisp/image-mode.el +++ b/lisp/image-mode.el @@ -50,20 +50,32 @@ ;;; Image scrolling functions -(defvar image-mode-current-vscroll nil) -(defvar image-mode-current-hscroll nil) +(defvar image-mode-current-vscroll nil + "An alist with elements (WINDOW . VSCROLL).") + +(defvar image-mode-current-hscroll nil + "An alist with elements (WINDOW . HSCROLL).") (defun image-set-window-vscroll (window vscroll &optional pixels-p) - (setq image-mode-current-vscroll vscroll) + (setq image-mode-current-vscroll + (append (list (cons window vscroll)) + (delete (assoc window image-mode-current-vscroll) + image-mode-current-vscroll))) (set-window-vscroll window vscroll pixels-p)) (defun image-set-window-hscroll (window ncol) - (setq image-mode-current-hscroll ncol) + (setq image-mode-current-hscroll + (append (list (cons window ncol)) + (delete (assoc window image-mode-current-hscroll) + image-mode-current-hscroll))) (set-window-hscroll window ncol)) (defun image-reset-current-vhscroll () - (set-window-hscroll (selected-window) image-mode-current-hscroll) - (set-window-vscroll (selected-window) image-mode-current-vscroll)) + (let ((win (selected-window))) + (when (assoc win image-mode-current-hscroll) + (set-window-hscroll win (cdr (assoc win image-mode-current-hscroll)))) + (when (assoc win image-mode-current-vscroll) + (set-window-vscroll win (cdr (assoc win image-mode-current-vscroll)))))) (defun image-forward-hscroll (&optional n) "Scroll image in current window to the left by N character widths. @@ -241,10 +253,10 @@ to toggle between display as an image and display as text." 'image-bookmark-make-cell) ;; Keep track of [vh]scroll when switching buffers - (set (make-local-variable 'image-mode-current-hscroll) - (window-hscroll (selected-window))) - (set (make-local-variable 'image-mode-current-vscroll) - (window-vscroll (selected-window))) + (make-local-variable 'image-mode-current-hscroll) + (make-local-variable 'image-mode-current-vscroll) + (image-set-window-hscroll (selected-window) (window-hscroll)) + (image-set-window-vscroll (selected-window) (window-vscroll)) (add-hook 'window-configuration-change-hook 'image-reset-current-vhscroll nil t) From 865ba895262a7ef207489763281883cdb0ef8800 Mon Sep 17 00:00:00 2001 From: Tassilo Horn Date: Tue, 29 Jan 2008 18:01:32 +0000 Subject: [PATCH 417/439] * doc-view.el (doc-view-mode): Adapt to i-m-current-[vh]scroll being an alist now. --- lisp/ChangeLog | 11 +++++++++++ lisp/doc-view.el | 8 ++++---- 2 files changed, 15 insertions(+), 4 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index d3525398265..00e102729c0 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,14 @@ +2008-01-29 Tassilo Horn + + * doc-view.el (doc-view-mode): Adapt to i-m-current-[vh]scroll + being an alist now. + + * image-mode.el (image-mode-current-vscroll) + (image-mode-current-hscroll): Add doc strings. + (image-set-window-vscroll, image-set-window-hscroll) + (image-reset-current-vhscroll, image-mode): Adapt to + i-m-current-[vh]scroll being an alist now. + 2008-01-29 Martin Rudalics * emacs-lisp/find-func.el (find-function-search-for-symbol): diff --git a/lisp/doc-view.el b/lisp/doc-view.el index 047785e844c..aaa68bf6387 100644 --- a/lisp/doc-view.el +++ b/lisp/doc-view.el @@ -989,10 +989,10 @@ toggle between displaying the document or editing it as text." nil t) ;; Keep track of [vh]scroll when switching buffers - (set (make-local-variable 'image-mode-current-hscroll) - (window-hscroll (selected-window))) - (set (make-local-variable 'image-mode-current-vscroll) - (window-vscroll (selected-window))) + (make-local-variable 'image-mode-current-hscroll) + (make-local-variable 'image-mode-current-vscroll) + (image-set-window-hscroll (selected-window) (window-hscroll)) + (image-set-window-vscroll (selected-window) (window-vscroll)) (add-hook 'window-configuration-change-hook 'image-reset-current-vhscroll nil t) From bf624ae476f3fbd51f7c90f831032a99db260ea1 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:04:32 +0000 Subject: [PATCH 418/439] *** empty log message *** --- lisp/ChangeLog | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 591a159d4d6..b47bb601af2 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-29 Alan Mackenzie + + * progmodes/cc-defs.el (c-version): increase to 5.31.5. + 2008-01-29 Richard Stallman * progmodes/etags.el (tags-query-replace): Delete unused optional args. @@ -11,6 +15,11 @@ gdb-cpp-define-alist-program if file is nil (currently only " *partial-output-..."). +2008-01-27 Alan Mackenzie + + * progmodes/cc-awk.el, progmodes/cc-engine.el: Correct typos, + enhance comments. + 2008-01-27 Richard Stallman * allout.el: Many doc fixes. From 4994db5843f5a319ee79da3055cefe7e088225c1 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:05:22 +0000 Subject: [PATCH 419/439] (c-version): increase to 5.31.5. --- lisp/progmodes/cc-defs.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/progmodes/cc-defs.el b/lisp/progmodes/cc-defs.el index 1632d756ffc..d7be903d357 100644 --- a/lisp/progmodes/cc-defs.el +++ b/lisp/progmodes/cc-defs.el @@ -96,7 +96,7 @@ ;;; Variables also used at compile time. -(defconst c-version "5.31.4" +(defconst c-version "5.31.5" "CC Mode version number.") (defconst c-version-sym (intern c-version)) From 0f138d5d925cac1790cf7b17e4148052e577fa96 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:06:42 +0000 Subject: [PATCH 420/439] *** empty log message *** --- lisp/ChangeLog | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 00e102729c0..6562e57ee7c 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-29 Alan Mackenzie + + * progmodes/cc-defs.el (c-version): increase to 5.31.5. + 2008-01-29 Tassilo Horn * doc-view.el (doc-view-mode): Adapt to i-m-current-[vh]scroll From 3e63bf0e9ce71d206d0e8793f848156f16be7a07 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:07:20 +0000 Subject: [PATCH 421/439] (c-version): increase to 5.31.5. --- lisp/progmodes/cc-defs.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/progmodes/cc-defs.el b/lisp/progmodes/cc-defs.el index 9ef8db7548f..2d4cc982714 100644 --- a/lisp/progmodes/cc-defs.el +++ b/lisp/progmodes/cc-defs.el @@ -96,7 +96,7 @@ ;;; Variables also used at compile time. -(defconst c-version "5.31.4" +(defconst c-version "5.31.5" "CC Mode version number.") (defconst c-version-sym (intern c-version)) From d29cf86d3074248c077e4deaf49c1f4100e0fd25 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:16:18 +0000 Subject: [PATCH 422/439] *** empty log message *** --- lisp/ChangeLog | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b47bb601af2..bf24be08751 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,9 @@ 2008-01-29 Alan Mackenzie + * progmodes/cc-engine.el (c-guess-basic-syntax, CASE 5A.5): Anchor + the "{" of a template function correctly on "template", not the + following "<". + * progmodes/cc-defs.el (c-version): increase to 5.31.5. 2008-01-29 Richard Stallman From 820d062bde06707f66828166ebf97bbb123851b8 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:17:44 +0000 Subject: [PATCH 423/439] (c-guess-basic-syntax, CASE 5A.5): Anchor the "{" of a template function correctly on "template", not the following "<". --- lisp/progmodes/cc-engine.el | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 929b000b83f..77b43657050 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el @@ -8030,12 +8030,15 @@ comment at the start of cc-engine.el for more info." ;; CASE 5A.5: ordinary defun open (t - (goto-char placeholder) - (if (or containing-decl-open macro-start) - (c-add-syntax 'defun-open (c-point 'boi)) - ;; Bogus to use bol here, but it's the legacy. - (c-add-syntax 'defun-open (c-point 'bol))) - ))) + (save-excursion + (c-beginning-of-decl-1 lim) + (while (looking-at c-specifier-key) + (goto-char (match-end 1)) + (c-forward-syntactic-ws indent-point)) + (c-add-syntax 'defun-open (c-point 'boi)) + ;; Bogus to use bol here, but it's the legacy. (Resolved, + ;; 2007-11-09) + )))) ;; CASE 5B: After a function header but before the body (or ;; the ending semicolon if there's no body). From 89710739871b6d907a3239de43abbb5073aa598c Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:20:27 +0000 Subject: [PATCH 424/439] *** empty log message *** --- lisp/ChangeLog | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6562e57ee7c..b6916f18d09 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,9 @@ 2008-01-29 Alan Mackenzie + * progmodes/cc-engine.el (c-guess-basic-syntax, CASE 5A.5): Anchor + the "{" of a template function correctly on "template", not the + following "<". + * progmodes/cc-defs.el (c-version): increase to 5.31.5. 2008-01-29 Tassilo Horn From 86f4a763d44cb450fa2f32bd8443680ae412a70f Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:21:42 +0000 Subject: [PATCH 425/439] (c-guess-basic-syntax, CASE 5A.5): Anchor the "{" of a template function correctly on "template", not the following "<". --- lisp/progmodes/cc-engine.el | 15 +++++++++------ 1 file changed, 9 insertions(+), 6 deletions(-) diff --git a/lisp/progmodes/cc-engine.el b/lisp/progmodes/cc-engine.el index 322771f0dab..48bbcaf18cf 100644 --- a/lisp/progmodes/cc-engine.el +++ b/lisp/progmodes/cc-engine.el @@ -8033,12 +8033,15 @@ comment at the start of cc-engine.el for more info." ;; CASE 5A.5: ordinary defun open (t - (goto-char placeholder) - (if (or containing-decl-open macro-start) - (c-add-syntax 'defun-open (c-point 'boi)) - ;; Bogus to use bol here, but it's the legacy. - (c-add-syntax 'defun-open (c-point 'bol))) - ))) + (save-excursion + (c-beginning-of-decl-1 lim) + (while (looking-at c-specifier-key) + (goto-char (match-end 1)) + (c-forward-syntactic-ws indent-point)) + (c-add-syntax 'defun-open (c-point 'boi)) + ;; Bogus to use bol here, but it's the legacy. (Resolved, + ;; 2007-11-09) + )))) ;; CASE 5B: After a function header but before the body (or ;; the ending semicolon if there's no body). From d7e889f65513307919255f3f55551c6a71a26b68 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:30:04 +0000 Subject: [PATCH 426/439] *** empty log message *** --- lisp/ChangeLog | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index bf24be08751..ee1a6ee0adc 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2008-01-29 Alan Mackenzie + * progmodes/cc-engine.el (c-specifier-key): Exclude "template" + from this regexp; part of same fix as next change to cc-engine.el. + * progmodes/cc-engine.el (c-guess-basic-syntax, CASE 5A.5): Anchor the "{" of a template function correctly on "template", not the following "<". From cc1cce145e9f0bd619dd1af3c50f3c862b6779c6 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:30:54 +0000 Subject: [PATCH 427/439] (c-specifier-key): Exclude "template" from this regexp; to allow the "{" of a template function to be correctly anchored on "template", not the following "<". --- lisp/progmodes/cc-langs.el | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/lisp/progmodes/cc-langs.el b/lisp/progmodes/cc-langs.el index 9e8dd282e11..4c82fb522c0 100644 --- a/lisp/progmodes/cc-langs.el +++ b/lisp/progmodes/cc-langs.el @@ -1771,11 +1771,13 @@ one of `c-type-list-kwds', `c-ref-list-kwds', (c-lang-defvar c-prefix-spec-kwds-re (c-lang-const c-prefix-spec-kwds-re)) (c-lang-defconst c-specifier-key - ;; Adorned regexp of the keywords in `c-prefix-spec-kwds' that - ;; aren't ambiguous with types or type prefixes. + ;; Adorned regexp of the keywords in `c-prefix-spec-kwds' that aren't + ;; ambiguous with types or type prefixes. These are the keywords (like + ;; extern, namespace, but NOT template) that can modify a declaration. t (c-make-keywords-re t (set-difference (c-lang-const c-prefix-spec-kwds) - (c-lang-const c-type-start-kwds) + (append (c-lang-const c-type-start-kwds) + (c-lang-const c-<>-arglist-kwds)) :test 'string-equal))) (c-lang-defvar c-specifier-key (c-lang-const c-specifier-key)) From 88b4a959ac74ff2518b44a4586b369eb01b9d2c5 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:33:38 +0000 Subject: [PATCH 428/439] (c-specifier-key): Exclude "template" from this regexp; to allow the "{" of a template function to be correctly anchored on "template", not the following "<". --- lisp/ChangeLog | 3 +++ lisp/progmodes/cc-langs.el | 8 +++++--- 2 files changed, 8 insertions(+), 3 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b6916f18d09..c089bb61f5e 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,8 @@ 2008-01-29 Alan Mackenzie + * progmodes/cc-langs.el (c-specifier-key): Exclude "template" + from this regexp; part of same fix as next change to cc-engine.el. + * progmodes/cc-engine.el (c-guess-basic-syntax, CASE 5A.5): Anchor the "{" of a template function correctly on "template", not the following "<". diff --git a/lisp/progmodes/cc-langs.el b/lisp/progmodes/cc-langs.el index ea527730620..54725c0fd88 100644 --- a/lisp/progmodes/cc-langs.el +++ b/lisp/progmodes/cc-langs.el @@ -1771,11 +1771,13 @@ one of `c-type-list-kwds', `c-ref-list-kwds', (c-lang-defvar c-prefix-spec-kwds-re (c-lang-const c-prefix-spec-kwds-re)) (c-lang-defconst c-specifier-key - ;; Adorned regexp of the keywords in `c-prefix-spec-kwds' that - ;; aren't ambiguous with types or type prefixes. + ;; Adorned regexp of the keywords in `c-prefix-spec-kwds' that aren't + ;; ambiguous with types or type prefixes. These are the keywords (like + ;; extern, namespace, but NOT template) that can modify a declaration. t (c-make-keywords-re t (set-difference (c-lang-const c-prefix-spec-kwds) - (c-lang-const c-type-start-kwds) + (append (c-lang-const c-type-start-kwds) + (c-lang-const c-<>-arglist-kwds)) :test 'string-equal))) (c-lang-defvar c-specifier-key (c-lang-const c-specifier-key)) From f4e9b84033c490981e22911ce045c42d7721c300 Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:35:05 +0000 Subject: [PATCH 429/439] Correct file name in previous commission. --- lisp/ChangeLog | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index ee1a6ee0adc..14067364e54 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,6 +1,6 @@ 2008-01-29 Alan Mackenzie - * progmodes/cc-engine.el (c-specifier-key): Exclude "template" + * progmodes/cc-langs.el (c-specifier-key): Exclude "template" from this regexp; part of same fix as next change to cc-engine.el. * progmodes/cc-engine.el (c-guess-basic-syntax, CASE 5A.5): Anchor From 6c7480fc75820b56a92e729eea60813ab1a5e25d Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:45:51 +0000 Subject: [PATCH 430/439] *** empty log message *** --- lisp/ChangeLog | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 14067364e54..f0565096f3d 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,5 +1,9 @@ 2008-01-29 Alan Mackenzie + * progmodes/cc-langs.el (c-block-stmt-1-kwds, c-block-stmt-2-kwds) + (c-simple-stmt-kwds): New Objective C keywords: @finally, @try, + @catch, @synchronized, @throw. + * progmodes/cc-langs.el (c-specifier-key): Exclude "template" from this regexp; part of same fix as next change to cc-engine.el. From 9555a4cfeb2e5ebf3c0283d7b79586ef22e62c9d Mon Sep 17 00:00:00 2001 From: Alan Mackenzie Date: Tue, 29 Jan 2008 20:47:03 +0000 Subject: [PATCH 431/439] (c-block-stmt-1-kwds, c-block-stmt-2-kwds, c-simple-stmt-kwds): New Objective C keywords: @finally, @try, @catch, @synchronized, @throw. --- lisp/progmodes/cc-langs.el | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lisp/progmodes/cc-langs.el b/lisp/progmodes/cc-langs.el index 4c82fb522c0..54725c0fd88 100644 --- a/lisp/progmodes/cc-langs.el +++ b/lisp/progmodes/cc-langs.el @@ -1972,6 +1972,7 @@ identifiers that follows the type in a normal declaration." "Statement keywords followed directly by a substatement." t '("do" "else") c++ '("do" "else" "try") + objc '("do" "else" "@finally" "@try") java '("do" "else" "finally" "try") idl nil) @@ -1985,6 +1986,7 @@ identifiers that follows the type in a normal declaration." "Statement keywords followed by a paren sexp and then by a substatement." t '("for" "if" "switch" "while") c++ '("for" "if" "switch" "while" "catch") + objc '("for" "if" "switch" "while" "@catch" "@synchronized") java '("for" "if" "switch" "while" "catch" "synchronized") idl nil pike '("for" "if" "switch" "while" "foreach") @@ -2016,6 +2018,7 @@ identifiers that follows the type in a normal declaration." (c-lang-defconst c-simple-stmt-kwds "Statement keywords followed by an expression or nothing." t '("break" "continue" "goto" "return") + objc '("break" "continue" "goto" "return" "@throw") ;; Note: `goto' is not valid in Java, but the keyword is still reserved. java '("break" "continue" "goto" "return" "throw") idl nil From 8d1f2fd0ce2f4e5031dbb1aff1993c0e2ffe06a6 Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Tue, 29 Jan 2008 21:13:00 +0000 Subject: [PATCH 432/439] *** empty log message *** --- lisp/ChangeLog | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index c089bb61f5e..6e12882ba61 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,14 @@ +2008-01-29 Michael Albinus + + * net/tramp.el (tramp-methods): Use "-H" option for "sudo". Suggested + by Trent W. Buck . Make ("%h") a single + element in "plinkx". + (tramp-handle-shell-command): Reuse "*Async Shell Command*" or + "*Shell Command Output*" buffers. Check, whether there is already + an asynchronous process running. Display always the buffer of the + asynchronous process. + (tramp-compute-multi-hops): Adapt error message. + 2008-01-29 Alan Mackenzie * progmodes/cc-langs.el (c-specifier-key): Exclude "template" From 42bc9b6d9ddc5c15c16d3f0258db961393eb1d4a Mon Sep 17 00:00:00 2001 From: Michael Albinus Date: Tue, 29 Jan 2008 21:14:04 +0000 Subject: [PATCH 433/439] * net/tramp.el (tramp-methods): Use "-H" option for "sudo". Suggested by Trent W. Buck . Make ("%h") a single element in "plinkx". (tramp-handle-shell-command): Reuse "*Async Shell Command*" or "*Shell Command Output*" buffers. Check, whether there is already an asynchronous process running. Display always the buffer of the asynchronous process. (tramp-compute-multi-hops): Adapt error message. --- lisp/net/tramp.el | 60 +++++++++++++++++++++++++++++++++-------------- 1 file changed, 42 insertions(+), 18 deletions(-) diff --git a/lisp/net/tramp.el b/lisp/net/tramp.el index eb68c8302aa..5829635d035 100644 --- a/lisp/net/tramp.el +++ b/lisp/net/tramp.el @@ -441,7 +441,7 @@ files conditionalize this setup based on the TERM environment variable." (tramp-password-end-of-line nil)) ("sudo" (tramp-login-program "sudo") (tramp-login-args (("-u" "%u") - ("-s" "-p" "Password:"))) + ("-s") ("-H") ("-p" "Password:"))) (tramp-remote-sh "/bin/sh") (tramp-copy-program nil) (tramp-copy-args nil) @@ -519,7 +519,9 @@ files conditionalize this setup based on the TERM environment variable." (tramp-default-port 22)) ("plinkx" (tramp-login-program "plink") - (tramp-login-args (("-load" "%h") ("-t") + ;; ("%h") must be a single element, see + ;; `tramp-compute-multi-hops'. + (tramp-login-args (("-load") ("%h") ("-t") (,(format "env 'TERM=%s' 'PROMPT_COMMAND=' 'PS1=$ '" tramp-terminal-type)) @@ -3789,7 +3791,7 @@ Lisp error raised when PROGRAM is nil is trapped also, returning 1." ((bufferp output-buffer) output-buffer) ((stringp output-buffer) (get-buffer-create output-buffer)) (output-buffer (current-buffer)) - (t (generate-new-buffer + (t (get-buffer-create (if asynchronous "*Async Shell Command*" "*Shell Command Output*"))))) @@ -3801,22 +3803,42 @@ Lisp error raised when PROGRAM is nil is trapped also, returning 1." (if (and (not asynchronous) error-buffer) (with-parsed-tramp-file-name default-directory nil (list output-buffer (tramp-make-tramp-temp-file v))) - output-buffer))) + output-buffer)) + (proc (get-buffer-process output-buffer))) - (prog1 - ;; Run the process. - (if (integerp asynchronous) + ;; Check whether there is another process running. Tramp does not + ;; support 2 (asynchronous) processes in parallel. + (when proc + (if (yes-or-no-p "A command is running. Kill it? ") + (ignore-errors (kill-process proc)) + (error "Shell command in progress"))) + + (with-current-buffer output-buffer + (setq buffer-read-only nil + buffer-undo-list t) + (erase-buffer)) + + (if (integerp asynchronous) + (prog1 + ;; Run the process. (apply 'start-file-process "*Async Shell*" buffer args) - (apply 'process-file (car args) nil buffer nil (cdr args))) - ;; Insert error messages if they were separated. - (when (listp buffer) - (with-current-buffer error-buffer (insert-file-contents (cadr buffer))) - (delete-file (cadr buffer))) - ;; There's some output, display it. - (when (with-current-buffer output-buffer (> (point-max) (point-min))) - (if (functionp 'display-message-or-buffer) - (funcall (symbol-function 'display-message-or-buffer) output-buffer) - (pop-to-buffer output-buffer)))))) + ;; Display output. + (pop-to-buffer output-buffer)) + + (prog1 + ;; Run the process. + (apply 'process-file (car args) nil buffer nil (cdr args)) + ;; Insert error messages if they were separated. + (when (listp buffer) + (with-current-buffer error-buffer + (insert-file-contents (cadr buffer))) + (delete-file (cadr buffer))) + ;; There's some output, display it. + (when (with-current-buffer output-buffer (> (point-max) (point-min))) + (if (functionp 'display-message-or-buffer) + (funcall (symbol-function 'display-message-or-buffer) + output-buffer) + (pop-to-buffer output-buffer))))))) ;; File Editing. @@ -6073,7 +6095,9 @@ Gateway hops are already opened." (concat "^" (regexp-opt (list "localhost" (system-name)) t) "$") host)) (tramp-error - v 'file-error "Wrong hostname `%s' for method `%s'" host method))) + v 'file-error + "Host `%s' looks like a remote host, `%s' can only use the local host" + host method))) ;; Result. target-alist)) From 0fcb495e257302a082a638ec0895b645de0671ac Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 30 Jan 2008 00:18:44 +0000 Subject: [PATCH 434/439] New file. --- lisp/ChangeLog | 8 +- lisp/linum.el | 199 +++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 205 insertions(+), 2 deletions(-) create mode 100644 lisp/linum.el diff --git a/lisp/ChangeLog b/lisp/ChangeLog index 6e12882ba61..b2f810910a1 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -1,3 +1,7 @@ +2008-01-30 Markus Triska + + * linum.el: New file. + 2008-01-29 Michael Albinus * net/tramp.el (tramp-methods): Use "-H" option for "sudo". Suggested @@ -18,7 +22,7 @@ the "{" of a template function correctly on "template", not the following "<". - * progmodes/cc-defs.el (c-version): increase to 5.31.5. + * progmodes/cc-defs.el (c-version): Increase to 5.31.5. 2008-01-29 Tassilo Horn @@ -6055,7 +6059,7 @@ Require tramp-cmds.el. (tramp-make-tramp-temp-file): We can get rid of DONT-CREATE. (tramp-handle-file-name-all-completions): Expand DIRECTORY. - (tramp-do-copy-or-rename-file-directly): Make more rigid checks. + (tramp-do-copy-or-rename-file-directly): Make more rigid checks. (tramp-do-copy-or-rename-file-out-of-band) (tramp-maybe-open-connection): Use `make-temp-name'. This is possible, because we don't need to create the temporary file, but diff --git a/lisp/linum.el b/lisp/linum.el new file mode 100644 index 00000000000..887f4bcc705 --- /dev/null +++ b/lisp/linum.el @@ -0,0 +1,199 @@ +;;; linum.el --- display line numbers in the left margin + +;; Copyright (C) 2008 Free Software Foundation, Inc. + +;; Author: Markus Triska +;; Maintainer: FSF +;; Keywords: convenience + +;; This file is part of GNU Emacs. + +;; GNU Emacs is free software; you can redistribute it and/or modify +;; it under the terms of the GNU General Public License as published by +;; the Free Software Foundation; either version 3, or (at your option) +;; any later version. + +;; GNU Emacs is distributed in the hope that it will be useful, +;; but WITHOUT ANY WARRANTY; without even the implied warranty of +;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +;; GNU General Public License for more details. + +;; You should have received a copy of the GNU General Public License +;; along with GNU Emacs; see the file COPYING. If not, write to the +;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, +;; Boston, MA 02110-1301, USA. + +;;; Commentary: + +;; Display line numbers for the current buffer. +;; +;; Add the following to your .emacs file: + +;; (require 'linum) + +;; Then toggle display of line numbers with M-x linum-mode. To enable +;; line numbering in all buffers, use M-x global-linum-mode. + +;;; Code: + +(defconst linum-version "0.9wx") + +(defvar linum-overlays nil "Overlays used in this buffer.") +(defvar linum-available nil "Overlays available for reuse.") +(defvar linum-before-numbering-hook nil + "Functions run in each buffer before line numbering starts.") + +(mapc #'make-variable-buffer-local '(linum-overlays linum-available)) + +(defgroup linum nil + "Show line numbers in the left margin." + :group 'convenience) + +;;;###autoload +(defcustom linum-format 'dynamic + "Format used to display line numbers. +Either a format string like \"%7d\", `dynamic' to adapt the width +as needed, or a function that is called with a line number as its +argument and should evaluate to a string to be shown on that line. +See also `linum-before-numbering-hook'." + :group 'linum + :type 'sexp) + +(defface linum + '((t :inherit shadow)) + "Face for displaying line numbers in the display margin." + :group 'linum) + +(defcustom linum-eager t + "Whether line numbers should be updated after each command. +The conservative setting `nil' might miss some buffer changes, +and you have to scroll or press \\[recenter-top-bottom] to update the numbers." + :group 'linum + :type 'boolean) + +(defcustom linum-delay t + "Delay updates to give Emacs a chance for other changes." + :group 'linum + :type 'boolean) + +;;;###autoload +(define-minor-mode linum-mode + "Toggle display of line numbers in the left margin." + :lighter "" ; for desktop.el + (if linum-mode + (progn + (if linum-eager + (add-hook 'post-command-hook (if linum-delay + 'linum-schedule + 'linum-update-current) nil t) + (add-hook 'after-change-functions 'linum-after-change nil t)) + (add-hook 'window-scroll-functions 'linum-after-scroll nil t) + ;; mistake in Emacs: window-size-change-functions cannot be local + (add-hook 'window-size-change-functions 'linum-after-size) + (add-hook 'change-major-mode-hook 'linum-delete-overlays nil t) + (add-hook 'window-configuration-change-hook + 'linum-after-config nil t) + (linum-update-current)) + (remove-hook 'post-command-hook 'linum-update-current t) + (remove-hook 'post-command-hook 'linum-schedule t) + (remove-hook 'window-size-change-functions 'linum-after-size) + (remove-hook 'window-scroll-functions 'linum-after-scroll t) + (remove-hook 'after-change-functions 'linum-after-change t) + (remove-hook 'window-configuration-change-hook 'linum-after-config t) + (remove-hook 'change-major-mode-hook 'linum-delete-overlays t) + (linum-delete-overlays))) + +;;;###autoload +(define-globalized-minor-mode global-linum-mode linum-mode linum-on) + +(defun linum-on () + (unless (minibufferp) + (linum-mode 1))) + +(defun linum-delete-overlays () + "Delete all overlays displaying line numbers for this buffer." + (mapc #'delete-overlay linum-overlays) + (setq linum-overlays nil) + (dolist (w (get-buffer-window-list (current-buffer) nil t)) + (set-window-margins w 0))) + +(defun linum-update-current () + "Update line numbers for the current buffer." + (linum-update (current-buffer))) + +(defun linum-update (buffer) + "Update line numbers for all windows displaying BUFFER." + (with-current-buffer buffer + (when linum-mode + (setq linum-available linum-overlays) + (setq linum-overlays nil) + (save-excursion + (mapc #'linum-update-window + (get-buffer-window-list buffer nil 'visible))) + (mapc #'delete-overlay linum-available) + (setq linum-available nil)))) + +(defun linum-update-window (win) + "Update line numbers for the portion visible in window WIN." + (goto-char (window-start win)) + (let ((line (line-number-at-pos)) + (limit (1+ (window-end win t))) + (fmt (cond ((stringp linum-format) linum-format) + ((eq linum-format 'dynamic) + (let ((w (length (number-to-string + (count-lines (point-min) (point-max)))))) + (concat "%" (number-to-string w) "d"))))) + (width 0) + visited + ov) + (run-hooks 'linum-before-numbering-hook) + ;; Create an overlay (or reuse an existing one) for each + ;; line visible in this window, if necessary. + (while (and (not (eobp)) (< (point) limit)) + (setq visited nil) + (dolist (o (overlays-in (point) (point))) + (when (eq (overlay-get o 'linum-line) line) + (unless (memq o linum-overlays) + (push o linum-overlays)) + (setq linum-available (delete o linum-available)) + (setq visited t))) + (let ((str (if fmt + (propertize (format fmt line) 'face 'linum) + (funcall linum-format line)))) + (setq width (max width (length str))) + (unless visited + (if (null linum-available) + (setq ov (make-overlay (point) (point))) + (setq ov (pop linum-available)) + (move-overlay ov (point) (point))) + (push ov linum-overlays) + (setq str (propertize " " 'display `((margin left-margin) ,str))) + (overlay-put ov 'before-string str) + (overlay-put ov 'linum-line line))) + (forward-line) + (setq line (1+ line))) + (set-window-margins win width))) + +(defun linum-after-change (beg end len) + ;; update overlays on deletions, and after newlines are inserted + (when (or (= beg end) + (= end (point-max)) + (string-match-p "\n" (buffer-substring-no-properties beg end))) + (linum-update-current))) + +(defun linum-after-scroll (win start) + (linum-update (window-buffer win))) + +(defun linum-after-size (frame) + (linum-after-config)) + +(defun linum-schedule () + ;; schedule an update; the delay gives Emacs a chance for display changes + (run-with-idle-timer 0 nil #'linum-update-current)) + +(defun linum-after-config () + (walk-windows (lambda (w) (linum-update (window-buffer))) nil 'visible)) + +(provide 'linum) + +;;; linum.el ends here From ced5b5cbc8eda16ba9c075869462fa9ee28cd193 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 30 Jan 2008 02:08:38 +0000 Subject: [PATCH 435/439] Update comment. --- lisp/linum.el | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/lisp/linum.el b/lisp/linum.el index 887f4bcc705..c7db8d4a19c 100644 --- a/lisp/linum.el +++ b/lisp/linum.el @@ -27,11 +27,7 @@ ;; Display line numbers for the current buffer. ;; -;; Add the following to your .emacs file: - -;; (require 'linum) - -;; Then toggle display of line numbers with M-x linum-mode. To enable +;; Toggle display of line numbers with M-x linum-mode. To enable ;; line numbering in all buffers, use M-x global-linum-mode. ;;; Code: From 4bd81fde833444fe510c465706aec4134e1ae403 Mon Sep 17 00:00:00 2001 From: Juanma Barranquero Date: Wed, 30 Jan 2008 03:42:50 +0000 Subject: [PATCH 436/439] *** empty log message *** --- lisp/ChangeLog | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/ChangeLog b/lisp/ChangeLog index f0565096f3d..aa5b50b2208 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog @@ -3,7 +3,7 @@ * progmodes/cc-langs.el (c-block-stmt-1-kwds, c-block-stmt-2-kwds) (c-simple-stmt-kwds): New Objective C keywords: @finally, @try, @catch, @synchronized, @throw. - + * progmodes/cc-langs.el (c-specifier-key): Exclude "template" from this regexp; part of same fix as next change to cc-engine.el. @@ -11,7 +11,7 @@ the "{" of a template function correctly on "template", not the following "<". - * progmodes/cc-defs.el (c-version): increase to 5.31.5. + * progmodes/cc-defs.el (c-version): Increase to 5.31.5. 2008-01-29 Richard Stallman From ad38e1fcf455aff2ce60a792c4e8e01976766d71 Mon Sep 17 00:00:00 2001 From: Miles Bader Date: Wed, 30 Jan 2008 06:39:38 +0000 Subject: [PATCH 437/439] Add arch tagline --- lisp/linum.el | 1 + 1 file changed, 1 insertion(+) diff --git a/lisp/linum.el b/lisp/linum.el index c7db8d4a19c..078645c4120 100644 --- a/lisp/linum.el +++ b/lisp/linum.el @@ -192,4 +192,5 @@ and you have to scroll or press \\[recenter-top-bottom] to update the numbers." (provide 'linum) +;; arch-tag: dea45631-ed3c-4867-8b49-1c41c80aec6a ;;; linum.el ends here From 444a15799df6e31972773563beaee2cc19addbc3 Mon Sep 17 00:00:00 2001 From: Bill Wohler Date: Wed, 30 Jan 2008 07:06:39 +0000 Subject: [PATCH 438/439] *** empty log message *** --- lisp/mh-e/ChangeLog | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/lisp/mh-e/ChangeLog b/lisp/mh-e/ChangeLog index 0eba20a9899..96c612da42a 100644 --- a/lisp/mh-e/ChangeLog +++ b/lisp/mh-e/ChangeLog @@ -1,3 +1,8 @@ +2008-01-30 Bill Wohler + + * mh-mime.el (mh-mml-to-mime): Don't look up sender if From + absent. Fixes "Wrong type argument: stringp, nil" error. + 2007-12-02 Glenn Morris * mh-mime.el (mail-strip-quoted-names): Autoload it. From 6dcf341ad3ba1208b3401169e50c024040d95a96 Mon Sep 17 00:00:00 2001 From: Bill Wohler Date: Wed, 30 Jan 2008 07:07:10 +0000 Subject: [PATCH 439/439] (mh-mml-to-mime): Don't look up sender if From absent. Fixes "Wrong type argument: stringp, nil" error. --- lisp/mh-e/mh-mime.el | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) diff --git a/lisp/mh-e/mh-mime.el b/lisp/mh-e/mh-mime.el index ec0940a5d5e..5713ec8dba4 100644 --- a/lisp/mh-e/mh-mime.el +++ b/lisp/mh-e/mh-mime.el @@ -1621,13 +1621,14 @@ This action can be undone by running \\[undo]." (require 'message) (when mh-pgp-support-flag ;; PGP requires actual e-mail addresses, not aliases. - ;; Parse the recipients and sender from the message + ;; Parse the recipients and sender from the message. (message-options-set-recipient) - ;; Do an alias lookup on sender - (message-options-set 'message-sender - (mail-strip-quoted-names - (mh-alias-expand - (message-options-get 'message-sender)))) + ;; Do an alias lookup on sender (if From field is present). + (when (message-options-get 'message-sender) + (message-options-set 'message-sender + (mail-strip-quoted-names + (mh-alias-expand + (message-options-get 'message-sender))))) ;; Do an alias lookup on recipients (message-options-set 'message-recipients (mapconcat