Netbeans IDE:如何在Netbeans中折叠大块的Javascript代码? [英] Netbeans IDE : How do I fold large chunks of Javascript code in Netbeans?
问题描述
我已经从我舒适的Dreamweaver IDE跳到了Netbeans并且错过了我的代码折叠选项:(
我看到Netbeans你可以折叠正常的功能,但我似乎无法弄清楚如何折叠大块(整个模块)。我在Netbeans中找到了其他语言的修复程序,但它们似乎不适用于Javascript。这在工作时非常令人沮丧在我的4000多行文件中...
I see with Netbeans you can fold normal functions but I can't seem to work out how to fold large chunks (entire modules). I have found fixes for other languages in Netbeans but they don't seem to work in Javascript. This is very frustrating when working on my large 4000+ line files...
肯定有办法吗?!如果没有,任何人都可以推荐一款适用于JS,CSS,HTML和PHP的IDE ?
Surely there is a way?! If not can anyone recommend an IDE that is good for JS, CSS, HTML and PHP?
推荐答案
折叠任何文件类型中所有数据的快捷键是 Ctrl
+ Shift
+ -
(减号)。
展开完全是那个文件,你需要做相反的事情,即 Ctrl
+ Shift
+ +
(加号)。
The shortcut key for folding all of the data in any file type is "Ctrl
+ Shift
+ -
(minus sign)".
To expand fully that file, you need to do the opposite, which is "Ctrl
+ Shift
+ +
(plus sign)".
要查看和编辑NetBeans IDE的整个键盘快捷键,请转到 T ools
菜单> 选项
> Keymap
标签。
To see & edit the whole Keyboard Shortcuts of NetBeans IDE, please go to the "Tools
Menu > Options
> Keymap
Tab".
希望它有所帮助。
折叠代码结构的更新除了函数本身: -
请按照下列步骤操作: -
Update for Folding Code Structures other than the Functions itself:-
Follow these steps:-
- 转到此部分
工具
菜单>选项
>编辑
标签>常规
子标签。 - 您会在其中找到2个部分 - 代码折叠& 骆驼案例行为。
- 在代码折叠部分中,有两个子部分 - 使用代码折叠& 默认折叠。
- 选中使用代码折叠子部分的复选框,以激活其他选项其他子部分。
- 在默认折叠的其他子部分中,您将找到6个选项。其中,您需要的选项是标记和其他代码块。选中此选项的复选框,以激活所有代码结构的代码折叠(例如
if
&for
逻辑,...),然后重新启动应用程序(否则它可能无法正常工作)。
- Go to this section "
Tools
Menu >Options
>Editor
Tab >General
Sub-Tab". - You will find 2 sections in there - "Code Folding" & "Camel Case Behavior".
- In the section of "Code Folding", there are two sub-sections - "Use Code Folding" & "Collapse by Default".
- Check the checkbox for the sub-section "Use Code Folding", to activate the other options of the other sub-section.
- In the other sub-section "Collapse by Default", you will find 6 options. Among them, your required option is the "Tags and Other Code Blocks". Check the checkbox of this option, to activate code folding for all code structures (like "
if
" & "for
" logic, ...), and then restart the application (otherwise it MAY NOT work).
这篇关于Netbeans IDE:如何在Netbeans中折叠大块的Javascript代码?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!