]> git.eshelyaron.com Git - emacs.git/commitdiff
Improve the Info mode line further
authorLars Ingebrigtsen <larsi@gnus.org>
Tue, 7 Sep 2021 14:59:52 +0000 (16:59 +0200)
committerLars Ingebrigtsen <larsi@gnus.org>
Tue, 7 Sep 2021 15:46:55 +0000 (17:46 +0200)
* lisp/info.el (Info-set-mode-line): Improve the Info mode line
further (bug#13776).

lisp/info.el

index 55893218562129e987f730064369dafc69c376a2..62202d342c5b3792557bd27a2c875f609079f21d 100644 (file)
@@ -1735,10 +1735,12 @@ escaped (\\\",\\\\)."
                  (if (stringp Info-current-file)
                       (string-replace
                       "%" "%%"
-                      (file-name-sans-extension
-                       (file-name-nondirectory Info-current-file)))
+                       ;; Remove trailing ".info" and ".info.gz", etc.
+                      (replace-regexp-in-string
+                        "\\..*\\'" ""
+                        (file-name-nondirectory Info-current-file)))
                    (format "*%S*" Info-current-file))
-                  'help-echo "Info file name")
+                  'help-echo "Manual name")
                 ") ")
                (if Info-current-node
                    (propertize (string-replace