summaryrefslogtreecommitdiff
path: root/lisp/info-xref.el
diff options
context:
space:
mode:
authorGlenn Morris <rgm@gnu.org>2013-07-02 20:09:38 -0700
committerGlenn Morris <rgm@gnu.org>2013-07-02 20:09:38 -0700
commit9b057d613a30b83adcb26600118075dc81777510 (patch)
treeb42154e03df1db733a72c02232072f3ea427e636 /lisp/info-xref.el
parente01aa29cd90dc51ecb9b8c4ec6164fb748a6b892 (diff)
downloademacs-9b057d613a30b83adcb26600118075dc81777510.tar.gz
emacs-9b057d613a30b83adcb26600118075dc81777510.tar.bz2
emacs-9b057d613a30b83adcb26600118075dc81777510.zip
Make info-xref checks case-sensitive by default
* lisp/info.el (Info-find-node, Info-find-in-tag-table) (Info-find-node-in-buffer, Info-find-node-2, Info-goto-node): Add option for exact case matching of nodes. * lisp/info-xref.el (info-xref): New custom group. (info-xref-case-fold): New option. (info-xref-goto-node-p): Pass info-xref-case-fold to Info-goto-node.
Diffstat (limited to 'lisp/info-xref.el')
-rw-r--r--lisp/info-xref.el23
1 files changed, 21 insertions, 2 deletions
diff --git a/lisp/info-xref.el b/lisp/info-xref.el
index c38e23bab8a..21fb592ff19 100644
--- a/lisp/info-xref.el
+++ b/lisp/info-xref.el
@@ -45,7 +45,25 @@
;;; Code:
(require 'info)
-(eval-when-compile (require 'cl-lib)) ;; for `incf'
+(eval-when-compile (require 'cl-lib)) ; for `cl-incf'
+
+(defgroup info-xref nil
+ "Check external cross-references in Info documents."
+ :group 'docs) ; FIXME right parent?
+
+;; Should this even be an option?
+(defcustom info-xref-case-fold nil
+ "Non-nil means node checks should ignore case.
+When following cross-references, the Emacs Info reader first tries a
+case-sensitive match, then if that fails a case-insensitive one.
+The standalone Info reader does not do this, nor does this work
+for links in the html versions of Texinfo manuals. Therefore
+to ensure your cross-references work on the widest range of platforms,
+you should set this variable to nil."
+ :group 'info-xref
+ :type 'boolean
+ :version "24.4")
+
;;-----------------------------------------------------------------------------
;; vaguely generic
@@ -204,7 +222,8 @@ buffer's line and column of point."
(Info-goto-node node
(when (get-buffer "*info*")
(set-buffer "*info*")
- "xref - temporary"))
+ "xref - temporary")
+ (not info-xref-case-fold))
t)
(error nil))
(unless (equal (current-buffer) oldbuf)