gpt4 book ai didi

vim - Intellij VIM 模式,跳转列表 (CTRL-O) 不记录导航

转载 作者:行者123 更新时间:2023-12-04 21:21:42 25 4
gpt4 key购买 nike

我可以使用Ctrl+]跳转到光标下单词的定义,我可以使用Ctrl+O跳转回我来自的地方。但是如果我做一些类似控制点击某事的事情,那个跳转列表似乎并没有记录我来自哪里。然后 Ctrl+O 将不会跳回到我在控制单击时所在的位置。

有没有办法确保跳转列表不会错过这个?

最佳答案

标签导航

tag stack存储用于跳转到/从的所有标签。

  • ctrl] 用于跟随光标下的标签。
  • ctrlt 用于跳转到标签栈中的上一个条目。
  • :tag用于跳转到标签栈中的下一个条目。

  • 跳转导航

    jump list存储光标跳转到/从的所有位置。根据 Vim 的文档,在以下情况下,运动被认为是“跳跃”:
    A "jump" is one of the following commands: "'"', "`", "G", "/", "?", "n",
    "N", "%", "(", ")", "[[", "]]", "{", "}", ":s", ":tag", "L", "M", "H" and
    the commands that start editing a new file.
  • ctrlo 用于在跳转列表中移动光标做旧条目。
  • ctrli 用于将光标移动到跳转列表中较新的条目。

  • 引用

    :help tag-commands :
    g<LeftMouse>                        *g<LeftMouse>*
    <C-LeftMouse> *<C-LeftMouse>* *CTRL-]*
    CTRL-] Jump to the definition of the keyword under the
    cursor. Same as ":tag {ident}", where {ident} is the
    keyword under or after cursor.
    When there are several matching tags for {ident}, jump
    to the [count] one. When no [count] is given the
    first one is jumped to. See |tag-matchlist| for
    jumping to other matching tags.
    {Vi: identifier after the cursor}

    :help tag-stack :
    g<RightMouse>                       *g<RightMouse>*
    <C-RightMouse> *<C-RightMouse>* *CTRL-T*
    CTRL-T Jump to [count] older entry in the tag stack
    (default 1). {not in Vi}

    *:po* *:pop* *E555* *E556*
    :[count]po[p][!] Jump to [count] older entry in tag stack (default 1).
    See |tag-!| for [!]. {not in Vi}

    :[count]ta[g][!] Jump to [count] newer entry in tag stack (default 1).
    See |tag-!| for [!]. {not in Vi}

    :help jump-motions :
                                *CTRL-O*
    CTRL-O Go to [count] Older cursor position in jump list
    (not a motion command). {not in Vi}
    {not available without the |+jumplist| feature}


    <Tab> or *CTRL-I* *<Tab>*
    CTRL-I Go to [count] newer cursor position in jump list
    (not a motion command).
    In a |quickfix-window| it takes you to the position of
    the error under the cursor.
    {not in Vi}
    {not available without the |+jumplist| feature}

    关于vim - Intellij VIM 模式,跳转列表 (CTRL-O) 不记录导航,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/29373765/

    25 4 0
    Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
    广告合作:1813099741@qq.com 6ren.com