Syntax coloring quits working when declaring large string - by David Beechum

Status : 

  Duplicate<br /><br />
		This item appears to be a duplicate of another existing Connect or internal item.<br /><br />
		A more detailed explanation for the resolution of this particular item may have been provided in the comments section.

Sign in
to vote
ID 800982 Comments
Status Closed Workarounds
Type Bug Repros 0
Opened 9/16/2013 11:16:58 AM
Access Restriction Public


I have a unit test class with a test method somewhere around halfway in the file. Syntax coloring does not work for the second half of the file. After trying to figure out what the issue is, I have determined that the string listed in the steps to reproduce is causing the syntax coloring to quit working. It should be noted that the class file compiles and all the test methods in the file run without issue.
Sign in to post a comment.
Posted by Murali [MSFT] on 11/10/2013 at 1:39 PM

Thank you for reporting this issue. The Editor stops syntax coloring after encountering long lines for performance reasons and by default the threshold is 32k. We will certainly improve the experience in future versions depending on the customer feedback.

As a workaround, you can change this threshold by creating a registry key:

HKCU\Software\Microsoft\VisualStudio\11.0\Text Editor\Global Options

and in that key creating a DWORD value with name "LongBufferLineThreshold" and set it to whatever value you like as the new limit.

Murali Krishna
Program Manager,
Visual Studio Language Experience
Posted by Microsoft on 9/17/2013 at 12:09 AM
Thank you for submitting feedback on Visual Studio and .NET Framework. Your issue has been routed to the appropriate VS development team for investigation. We will contact you if we require any additional information.
Posted by Macy [MSFT] on 9/16/2013 at 11:51 AM
Thank you for your feedback, we are currently reviewing the issue you have submitted. If this issue is urgent, please contact support directly(