When Intellij generates code for UI forms you can collapse the code block and it is named: "UI Designer generated code". It is possible to collapse a code selection but its collapsed representation is displayed as "...". Is it possible to give it a custom name? It would look similar to a collapsed #region code block in C#.
In the editor, press Ctrl+Alt+Insert to add a class, file, or package. If the focus is inside the Project tool window and you want to add a new element, press Alt+Insert . To create a new Scratch file, press Ctrl+Alt+Shift+Insert . IntelliJ IDEA creates a temporary file that you can run and debug.
They have implemented region-support now!
From http://youtrack.jetbrains.com/issue/IDEA-80636
Currently Intellij IDEA supports two basic types of custom folding comments:
NetBeans-like:
//<editor-fold desc="..."> ... code ... //</editor-fold>
And VisualStudio-like:
//region <...> ... code ... //endregion
Note that line commenting symbols for "region...endregion" can be changed from "//" to "#" if the '#' character is supported by a language. But by default custom folding comments use the same comment characters as normally used for language line comments. Instead of typing the comments manually, in many cases you can use Ctrl+Alt+T (surround with). Please submit separate issues if you find that something doesn't work as expected.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With