在 Netbeans 上激活文本编辑宏

发布于 2024-09-16 18:06:23 字数 194 浏览 3 评论 0原文

这个问题是在超级用户上提出的,但我没有得到任何答复,所以我将其移到这里......我相信它是相关且重要的...... 我在 Mac OS X 上使用 Netbeans 一段时间了,它有一些非常好的功能,但它不支持大多数宏,这很糟糕。我不仅谈论复杂的 emacs 宏,而且甚至不支持最基本的宏,例如用于行尾的 Ce 或用于行首的 Ca。

有人可以帮忙激活宏吗?

This question was asked on Super User but I didn't get any response so I moved it here...I believe it is relevant and important...
I've been using Netbeans on Mac OS X for sometime it has some really good features but it doesn't support most of the macros and that sucks. I'm not only talking about complicated emacs macros but even the most basic are not supported like C-e for the end of the line or C-a for the beginning of the line.

Can somebody help to activate macros ?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。

评论(1

热血少△年 2024-09-23 18:06:23

我不确定你是否真的指的是宏。当我想到宏时,我会想到发出的一系列命令和击键。无论如何,Netbeans 默认情况下肯定支持使用 home 和 end 键的单个命令(快捷方式),例如您提到的命令(行尾和行首)。您可以将它们替换为您选择的组合键或将它们添加为备用组合键。

事实上,Netbeans 允许您创建完整的快捷方式配置文件,并为 Emacs 用户提供了一个配置文件,其中包含您提到的确切快捷方式。可从“工具”>“工具”访问此功能。选项菜单,键盘映射选项卡。

如果您正在寻找实际的宏功能,Netbeans 也支持该功能。您可能需要深入挖掘文档,而 Netbeans 仅附带 3 个内置宏。您可以直接定义它们,也可以让 Netbeans 将您的活动记录到宏中。可以从“工具”>“工具”访问宏。选项菜单,编辑器>宏选项卡。

Netbeans 还支持模板,这些模板是预定义的代码或文本片段,可以通过在编辑器中输入缩写然后按 Tab 键来生成。

I'm not sure if you really mean macros. When I think of macros, I think of a series of commands and keystrokes being issued. In any case, single commands (shortcuts) like the ones you mention (end of a line and beginning of a line) are certainly supported by Netbeans by default with the home and end keys. You can replace those with the key combinations of your choice or add them as alternates.

In fact, Netbeans allows you to create entire profiles of shortcuts and ships with one for Emacs users and contains the exact shortcuts you mention. This functionality is accessed from the Tools > Options menu, Keymap tab.

If you are looking for actual macro capability, that is supported in Netbeans as well. You might have to do some digging for documentation and Netbeans only comes with 3 build in macros. You can define them directly or have Netbeans record your activities to a macro. Macros can be accessed from Tools > Options menu, Editor > macros tab.

Netbeans supports templates as well, which are pieces of predefined code or text that can be generated by entering an abbreviation in the editor and then hitting tab.

~没有更多了~
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文