Sublime Forum

Closing tag not found

#1

Hello,

I test sublime text 2 .

But I have a problem with closing tags .

Sometimes it does not detect the closure , especially when there is a lot of content between html tags for example.

On notepad + + I do not have this problem. The closure is perfectly detected.

BTW the sublime behavior is strange because sometimes if I select the closing tag , it can not find my opening tag . But if I select the opening tag , it is me that closure …

Here are two pictures to illustrate my point :

http://img11.hostingpics.net/pics/579803str1.jpg

http://img11.hostingpics.net/pics/130709str2.jpg

I do not understand why I have this point of interogation .

Here it is not disturbing that the tags are close, but when the tags have a lot of content between them. It is difficult to find the closing tag or opening …

Do you have an explanation and a solution ?

0 Likes

#2
  1. What you are seeing is based on BracketHighlighter plugin which I am the author of (not native Sublime)
  2. BracketHighlighter has a maximum distance threshold for bracket matching to ensure good performance for instant highlighting

By default, BracketHighlighter uses a very conservative threshold (5000). You can increase the threshold in the settings file. I personally use 10000, but you can push it even further. Keep in mind you may have to play with the limit if starts causing lag in typing and such.

The settings can be seen below:
[pre=#232628] // Character threshold to search
“search_threshold”: 10000,[/pre]

0 Likes