Mercurial > emacs
comparison lisp/info.el @ 90054:f2ebccfa87d4
Revision: miles@gnu.org--gnu-2004/emacs--unicode--0--patch-74
Merge from emacs--cvs-trunk--0
Patches applied:
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-709
Update from CVS: src/indent.c (Fvertical_motion): Fix last change.
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-710
- miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-715
Update from CVS
* miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-716
Merge from gnus--rel--5.10
* miles@gnu.org--gnu-2004/gnus--rel--5.10--patch-74
Update from CVS
author | Miles Bader <miles@gnu.org> |
---|---|
date | Wed, 08 Dec 2004 05:02:30 +0000 |
parents | cb7f41387eb3 a227196e4498 |
children | fb79180b618d |
comparison
equal
deleted
inserted
replaced
90053:fff5f1a61d92 | 90054:f2ebccfa87d4 |
---|---|
186 file, so be prepared for a few surprises if you enable this feature." | 186 file, so be prepared for a few surprises if you enable this feature." |
187 :version "21.4" | 187 :version "21.4" |
188 :type 'boolean | 188 :type 'boolean |
189 :group 'info) | 189 :group 'info) |
190 | 190 |
191 (defcustom Info-search-whitespace-regexp "\\(?:\\s-+\\)" | 191 (defcustom Info-search-whitespace-regexp "\\s-+" |
192 "*If non-nil, regular expression to match a sequence of whitespace chars. | 192 "*If non-nil, regular expression to match a sequence of whitespace chars. |
193 This applies to Info search for regular expressions. | 193 This applies to Info search for regular expressions. |
194 You might want to use something like \"[ \\t\\r\\n]+\" instead. | 194 You might want to use something like \"[ \\t\\r\\n]+\" instead. |
195 In the Customization buffer, that is `[' followed by a space, | 195 In the Customization buffer, that is `[' followed by a space, |
196 a tab, a carriage return (control-M), a newline, and `]+'." | 196 a tab, a carriage return (control-M), a newline, and `]+'." |
1466 (opoint (point)) | 1466 (opoint (point)) |
1467 (opoint-min (point-min)) | 1467 (opoint-min (point-min)) |
1468 (opoint-max (point-max)) | 1468 (opoint-max (point-max)) |
1469 (ostart (window-start)) | 1469 (ostart (window-start)) |
1470 (osubfile Info-current-subfile)) | 1470 (osubfile Info-current-subfile)) |
1471 (when Info-search-whitespace-regexp | |
1472 (setq regexp | |
1473 (mapconcat 'identity (split-string regexp "[ \t\n]+") | |
1474 Info-search-whitespace-regexp))) | |
1475 (setq Info-search-case-fold case-fold-search) | 1471 (setq Info-search-case-fold case-fold-search) |
1476 (save-excursion | 1472 (save-excursion |
1477 (save-restriction | 1473 (save-restriction |
1478 (widen) | 1474 (widen) |
1479 (when backward | 1475 (when backward |
1488 (or (null found) | 1484 (or (null found) |
1489 (if backward | 1485 (if backward |
1490 (isearch-range-invisible found beg-found) | 1486 (isearch-range-invisible found beg-found) |
1491 (isearch-range-invisible beg-found found)) | 1487 (isearch-range-invisible beg-found found)) |
1492 ;; Skip node header line | 1488 ;; Skip node header line |
1493 (save-excursion (forward-line -1) | 1489 (and (save-excursion (forward-line -1) |
1494 (looking-at "\^_")) | 1490 (looking-at "\^_")) |
1491 (forward-line 1)) | |
1495 ;; Skip Tag Table node | 1492 ;; Skip Tag Table node |
1496 (save-excursion | 1493 (save-excursion |
1497 (and (search-backward "\^_" nil t) | 1494 (and (search-backward "\^_" nil t) |
1498 (looking-at "\^_\nTag Table")))))) | 1495 (looking-at "\^_\nTag Table")))))) |
1499 (if (if backward | 1496 (let ((search-spaces-regexp Info-search-whitespace-regexp)) |
1500 (re-search-backward regexp bound t) | 1497 (if (if backward |
1501 (re-search-forward regexp bound t)) | 1498 (re-search-backward regexp bound t) |
1502 (setq found (point) beg-found (if backward (match-end 0) | 1499 (re-search-forward regexp bound t)) |
1503 (match-beginning 0))) | 1500 (setq found (point) beg-found (if backward (match-end 0) |
1504 (setq give-up t))))) | 1501 (match-beginning 0))) |
1502 (setq give-up t)))))) | |
1505 ;; If no subfiles, give error now. | 1503 ;; If no subfiles, give error now. |
1506 (if give-up | 1504 (if give-up |
1507 (if (null Info-current-subfile) | 1505 (if (null Info-current-subfile) |
1508 (if backward | 1506 (let ((search-spaces-regexp Info-search-whitespace-regexp)) |
1509 (re-search-backward regexp) | 1507 (if backward |
1510 (re-search-forward regexp)) | 1508 (re-search-backward regexp) |
1509 (re-search-forward regexp))) | |
1511 (setq found nil))) | 1510 (setq found nil))) |
1512 | 1511 |
1513 (unless (or found bound) | 1512 (unless (or found bound) |
1514 (unwind-protect | 1513 (unwind-protect |
1515 ;; Try other subfiles. | 1514 ;; Try other subfiles. |
1561 (or (null found) | 1560 (or (null found) |
1562 (if backward | 1561 (if backward |
1563 (isearch-range-invisible found beg-found) | 1562 (isearch-range-invisible found beg-found) |
1564 (isearch-range-invisible beg-found found)) | 1563 (isearch-range-invisible beg-found found)) |
1565 ;; Skip node header line | 1564 ;; Skip node header line |
1566 (save-excursion (forward-line -1) | 1565 (and (save-excursion (forward-line -1) |
1567 (looking-at "\^_")) | 1566 (looking-at "\^_")) |
1567 (forward-line 1)) | |
1568 ;; Skip Tag Table node | 1568 ;; Skip Tag Table node |
1569 (save-excursion | 1569 (save-excursion |
1570 (and (search-backward "\^_" nil t) | 1570 (and (search-backward "\^_" nil t) |
1571 (looking-at "\^_\nTag Table")))))) | 1571 (looking-at "\^_\nTag Table")))))) |
1572 (if (if backward | 1572 (let ((search-spaces-regexp Info-search-whitespace-regexp)) |
1573 (re-search-backward regexp nil t) | 1573 (if (if backward |
1574 (re-search-forward regexp nil t)) | 1574 (re-search-backward regexp nil t) |
1575 (setq found (point) beg-found (if backward (match-end 0) | 1575 (re-search-forward regexp nil t)) |
1576 (match-beginning 0))) | 1576 (setq found (point) beg-found (if backward (match-end 0) |
1577 (setq give-up t))) | 1577 (match-beginning 0))) |
1578 (setq give-up t)))) | |
1578 (if give-up | 1579 (if give-up |
1579 (setq found nil)) | 1580 (setq found nil)) |
1580 (if found | 1581 (if found |
1581 (setq list nil))) | 1582 (setq list nil))) |
1582 (if found | 1583 (if found |