emacs向下钻取快捷方式
emacs drill down shortcut
我是emacs
的新手。在Netbeans中,您可以右键单击任何对象,它会将您直接发送到头文件或实现文件。emacs
中有快捷键吗?
您必须首先创建一个TAGS文件。
如果你在linux上:
$ ctags -e -R *.h *.cpp
// this will create tags for all .h and .cpp files,
// starting from the current directory, and recursing into subdirectories.
// -e : emacs tags (as oposed to vi tags, the default)
// -R : recursive
也可以使用--append
标志将添加到现有标记文件中。例如:
$ ctags --append -e -R *.h *.cpp /home/user/jdoe/thirdparty
// This will add to the TAGS file in the current directory
当您想跳转到符号定义时,在emacs中使用M-x find-tag
或M-.
。它会询问TAGS文件在哪里,然后您就设置好了。要弹出,请使用默认映射到M-*
的M-x pop-tag-mark
。
注意:ctags是可以的,但由于它不是编译器,有时它会把你带错地方。
您可以使用etags
来提供类似的功能。创建TAGS文件后,可以使用M-调用CCD_ 9的快捷方式。
与一切一样:Emacs为您提供了几种方法来做某事,在这种情况下,其中一些方法无法开箱即用。您可以使用etags
,或者如果您需要一个非常大的hammer语义,这是cedet项目的一部分。这将为您提供比简单地跳转到头文件更多的功能,但也许这正是您所需要的。
相关文章:
- 如何在c++中为模板函数实例创建快捷方式
- C++ ->运算符 [] 的快捷方式
- C++结构模板变量快捷方式定义不起作用
- 用于基于成员字段或函数创建比较器的快捷方式
- c++ Visual Studio 2015 快捷方式,用于从选择代码中生成功能
- 是否有用于"go to variable type definition" C++中"auto"变量的 Visual Studio 键盘快捷方式?
- Qt全局快捷方式扩展劫持快捷方式
- 在Qt Creator中应用代码更改的快捷方式是什么?
- 是否有快捷方式重叠运算符?
- 使用 C++ 显示 (.lnk) 快捷方式文件的真实路径
- 一个按钮有两个或多个快捷方式
- 通过TranslateAccelerator检测快捷方式时,忽略Shift键的状态
- 无论如何,是否可以确定MFC应用程序是通过PC重新启动或用户单击应用程序快捷方式开始的
- QDIR入口列表可以使用文件夹快捷方式透明地工作
- 快捷方式在C 中编写自定义编译命令时
- 自动热键:重新映射 MS Visio 的快捷方式,以将手动选择的对象对齐到顶部(好像按:"AlignTop")
- 如何为 QT Windows 应用程序设置不同的桌面快捷方式图标和任务栏图标不同
- 为什么 cppreference 将type_traits xxx_v快捷方式定义为内联 constexpr,而不仅仅是
- 具有OFN_ALLOWMULTISELECT不正确的快捷方式结果的 CFileDialog
- emacs向下钻取快捷方式