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.
I've installed NetBeans 7.1 RC1; at install time it imported my 7.0 settings. One of my settings in Fonts & Colors > Syntax is to set whitespace to Strike Through, Light Gray. In the preview the example looks as I expect (and as it appeared in 7.0), with leading spaces having a light gray strike through. However, 7.1 RC1 has the gray strike through extending to the right side of the editor window on every line, even though there are no trailing spaces. I like visible whitespace, but not to this extent. Is this a deliberate change? If so, am I missing an option to not add the trailing highlighting? (I tried restoring the standard settings and changing the highlighting again, but the same thing happened.) Product Version = NetBeans IDE 7.1 RC1 (Build 201111242103) Operating System = Windows 7 version 6.1 running on amd64 Java; VM; Vendor = 1.6.0_24 Runtime = Java HotSpot(TM) 64-Bit Server VM 19.1-b02
This bug still exists in RC2.
I guess not only the leading whitespace but also whitespace anywhere on the line would appear with strike-through, right? Since '\n' is a whitespace it should in fact highlight the newline char too. Since the newline view renders end of newline view then it's expected. I may force the newline view to have default attributes which seems to me as a best solution.
(In reply to comment #2) > I guess not only the leading whitespace but also whitespace anywhere on the > line would appear with strike-through, right? The preview text area in Fonts & Colors -> Syntax for Language: Java shows the correct rendition of the whitespace elements. There is no need for visible \n (which looks ugly anyway) because trailing spaces render with strikethrough, as shown in the preview in the line after "public class". I don't know what you mean by "newline view".
I can confirm the same behavior on my upgraded (7.0.1 -> 7.1) environment. I use a light gray wave-underline instead of strike-through and it is present the entire width of the editor pane, even after the last character on the line (whitespace or not). Windows 7 Enterprise, x86_64 NetBeans 7.1 release P.S. I really wish there was a "trailing whitespace" option (which is what I really care about) instead of simply all whitespace... but that's a feature request.
Created attachment 115284 [details] Screenshot Screenshot attached.
Filed RFE under bug 207793 for treating trailing whitespace (actually present in the file) different from other whitespace on the line.
This bug still exists in NetBeans IDE Dev (Build 201204030400) for whitespaces in Batch File, C, C++, C/C++ Header, Cascading Style Sheet, Fortran, Makefile, SQL and Shell Script, but not for JavaScript and Properties. This is the regression since 7.0 or 7.1.
Newline chars no longer colored by syntax highlighting. http://hg.netbeans.org/jet-main/rev/8274a4e6a571
Integrated into 'main-golden', will be available in build *201205150400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/8274a4e6a571 User: Miloslav Metelka <mmetelka@netbeans.org> Log: #205829 - Whitespace highlighting fills window.
*** Bug 209295 has been marked as a duplicate of this bug. ***
I can verify that the whitespace formatting issue is now resolved for me. Thanks! Product Version: NetBeans IDE Dev (Build 201205180400) Java: 1.7.0_04; Java HotSpot(TM) 64-Bit Server VM 23.0-b21 System: Windows 7 version 6.1 running on amd64; Cp1252; en_US (nb)