Emacs: Open a specific Info section

前端 未结 1 1015
迷失自我
迷失自我 2021-01-15 05:33

When i do describe-function info, documentation says: Called from a program, FILE-OR-NODE may specify an Info node of the form \"(FILENAME)NODENAME\".

相关标签:
1条回答
  • 2021-01-15 05:53
    • How to find out filename of a certain info file? (example: "elisp" for Emacs Lisp Intro)

    C-hm from the *info* buffer will tell you that the c key will Put name of current Info node in the kill ring (as well as displaying it in the echo area). From there you can yank it with C-y as usual.

    The part of the node name in parenthesis is the name of the file (minus its suffix, and directory path).

    To obtain the filename including its directory path (but still minus any suffix), you can call (Info-find-file "file") for the file in question ("emacs" in your example).

    Note that the suffix for the file (if any) can be anything in the Info-suffix-list variable.

    You can in fact pass a full file path as the argument to the info function as well. That's generally less useful, but may be handy if you managed to end up with conflicting info files. Interactively, C-uC-hi will prompt you for a full filename.

    (To enter a node name interactively, you can use C-hig.)

    • How to find out the section name? (example: "mark" for "11 The Mark and the Region")

    That's essentially the same as the first question, except it's the part of the node name after the parentheses that you want. Again, just use c to find out.

    • Is it possible to list info files and their sections before calling one with eval-expression?

    I'm not entirely sure what you mean by this, but maybe these help?

    • d will jump to the main directory (as C-hi takes you to initially). This is generated from all the dir files found in the directories in the Info-directory-list variable. Each dir file contains the paths for each file, but you're unlikely to need to see those.

    • < or t takes you to the top node of the file, which generally presents the top-level contents for the file.

    • T opens an all-on-one-page table of contents for the current file.

    • I presents you with index entries matching a pattern, for the current file.

    • C-s can search through all nodes of the current file (simply type it again each time you hit the end of the current node to start searching in the next).

    • M-x info-apropos can be used to search all info files.

    And obviously once you've arrived at a particular node via any method, you can use c to find out its name.

    Also as previously mentioned, once you're in the *info* buffer, you can type g to go to any node in any info file, using the same (file) node syntax. You can omit (file) if you are already in that file, or omit node to get to the top node of the specified file. You may or may not prefer that to using
    M-: (info "(file) node") RET

    As a special case, g*RET renders the entire current info file in a single buffer.

    Other useful Q&As on the general subject:

    • Reading multiple Emacs info files simultaneously
    • how to open *.info file in emacs in info mode?
    • info indexing (within and without emacs)

    Also:

    • http://www.emacswiki.org/emacs/InfoMode

    And of course:

    • M-: (info "(info) Top") RET
    • C-hih
    • C-hi?
    0 讨论(0)
提交回复
热议问题