Author Topic: Cannot match brace in a long line of text  (Read 527 times)

Offline Arthur

  • Hero Member
  • *****
  • Posts: 624
  • Karma: +1/-0
  • He who is ashamed of asking is afraid of learning.
    • View Profile
    • My Blog
Cannot match brace in a long line of text
« on: April 28, 2010, 03:45:46 pm »
I was working on a long line of text in VB. I needed to match a brace. However, HE does not highlight matching braces in long lines (like in the image) and if I do right-click -> Navigate -> Go To Matching Brace nothing happens. I understand I can simply start refactoring the code, but that takes too much time, and Format command does nothing either, which would be a nice thing though to have indeed.
I really would like this functionality be always working for me.

Offline alex

  • Developer
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1712
  • Karma: +29/-2
    • View Profile
    • HippoEDIT
Re: Cannot match brace in a long line of text
« Reply #1 on: April 28, 2010, 04:06:56 pm »
Hi Arthur,

is brace was inside of the string? Can you provide here text representation of code, that I can check it or it is critical?
HE has limitation for distance between braces, but have doubts that your line is longer then 8192 characters. This is done for performance reasons, otherwise navigation through code will be slow. But maybe there will be some changes in 1.50, I have changed a logic with brace search there.

About Format, format only correct indent, but do not split lines. But I think with scripting it will be possible to extend this functionality for every language.

Best regards,
Alex.

Offline Arthur

  • Hero Member
  • *****
  • Posts: 624
  • Karma: +1/-0
  • He who is ashamed of asking is afraid of learning.
    • View Profile
    • My Blog
Re: Cannot match brace in a long line of text
« Reply #2 on: April 28, 2010, 04:31:17 pm »
It was inside "". But it should work even inside a string I think, because this is so typical for say SQL code to be in double-quotes.
Some privacy issue is preventing me from publishing it, but I will send you a fragment (and if needed the whole file) privately if you still need it.
PS: The line is only 395 chars long.

Offline alex

  • Developer
  • Global Moderator
  • Hero Member
  • *****
  • Posts: 1712
  • Karma: +29/-2
    • View Profile
    • HippoEDIT
Re: Cannot match brace in a long line of text
« Reply #3 on: April 28, 2010, 05:12:51 pm »
Hi Arthur,

"text" styles (strings, comments, documentation ) are skipped when searching for matching braces. I do non need the code.
Because you often can have invalid code inside or something like this ":)". So it will be more problems then benefits.

Best regards,
Alex.

 

Related Topics

  Subject / Started by Replies Last post
3 Replies
479 Views
Last post February 19, 2009, 10:02:59 pm
by alex
2 Replies
748 Views
Last post May 23, 2009, 07:59:54 pm
by Stefan
3 Replies
465 Views
Last post June 29, 2009, 08:34:29 am
by alex
2 Replies
322 Views
Last post November 19, 2010, 03:53:45 pm
by scunliffe
3 Replies
325 Views
Last post August 03, 2011, 03:54:57 am
by alex