This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.
Summary: | Allow marking of parts of file that are not formatted after format (Ctrl+Shift+F) command | ||
---|---|---|---|
Product: | editor | Reporter: | _ sandipchitale <sandipchitale> |
Component: | Formatting & Indentation | Assignee: | Dusan Balek <dbalek> |
Status: | RESOLVED WONTFIX | ||
Severity: | blocker | ||
Priority: | P3 | ||
Version: | 5.x | ||
Hardware: | All | ||
OS: | All | ||
Issue Type: | ENHANCEMENT | Exception Reporter: |
Description
_ sandipchitale
2005-05-08 02:02:34 UTC
I'm afraid I don't understand it very well, can you provide some examples. Here is an example: Sometimes I have long lines of code (array initilization) which need to stay on same line for tabular view i.e. not wrap. To make maximum use of the visible part editor I do not want to indent those lines and I want to start them in the left margin like so: public class Census { public long calculateAveragePopulation() { //<--- left margin. code intentionally at the left margin String[] states = { "Alabama", "Arizona", "Alaska", ... 50 state names }; long[] populations = { 237456293, 13762782, 4567820, ... 50 populations }; } } Now if I invoke the reformat command the two lines will get indented like this public class Census { public long calculateAveragePopulation() { String[] states = { "Alabama", "Arizona", "Alaska", ... 50 state names }; long[] populations = { 237456293, 13762782, 4567820, ... 50 populations }; } } Granted this is a contrieved example. The point is that some times there is some intrinsic meaning that is conveyed by the layout of the code and I want to preserve it even if I reformat rest of code using "Format Code" action. Makes sense? This old bug may not be relevant anymore. If you can still reproduce it in 8.2 development builds please reopen this issue. Thanks for your cooperation, NetBeans IDE 8.2 Release Boss |