Author Topic: Problem with Find Tags dialog with tags that start with underscore  (Read 2647 times)

WadeHatler

  • Community Member
  • Posts: 19
  • Hero Points: 0
  • Been using VSlick since the dawn of time
In V18 in the Find Tags dialog, if you have labels that start with underscore, the type-to-select feature doesn't work work unless you manually move the cursor below the first entry that starts with underscore.  For example, I have a class with methods __New, Activate, etc.  When I open the dialog, the selector is on __New, and it ignores any typing.  If I manually move it down a couple lines, then the typing works.

Anyone have a solution for that?

Thanks,
Wade Hatler

Graeme

  • Senior Community Member
  • Posts: 2208
  • Hero Points: 272
Re: Problem with Find Tags dialog with tags that start with underscore
« Reply #1 on: October 17, 2013, 10:59:47 am »
I can't really understand your question.  What is the "find tag" dialog - how do you invoke it?  If you mean the find symbol dialog, when I invoke that, the list is empty to start with.

BTW - if this is C or C++, names starting with two underscores or an underscore followed by an uppercase letter are reserved for use by the compiler and its header files and are best avoided.

WadeHatler

  • Community Member
  • Posts: 19
  • Hero Points: 0
  • Been using VSlick since the dawn of time
Re: Problem with Find Tags dialog with tags that start with underscore
« Reply #2 on: October 17, 2013, 09:50:37 pm »
Sorry, I said the wrong name.  It's the dialog you get with list_tags, which lists the tags in the current file.  I think it's bound to Alt-, in the default VSlick install, but you can get it with list-tags from the command line.

To demonstrate the problem, start with something like this C# file, although any class works:
Code: [Select]
class testClass1 {
   void _MethodWithUnderscore() {
   }

   void NoUnderscore() {
   }
}

Execute the list-tags command, and the cursor will be frozen on the _Method... line as you type.  If you move it down below the last method that starts with an underscore and start typing, then it finds the appropriate method easily.

Now remove the underscore from the first method, and you'll see that it navigates correctly as soon as you open it.

I never noticed it before, but I just got class support in a language where I couldn't get it to work before, and started seeing it.  This language has magic methods that start with __ (e.g. __New is the ctor), so I have them at the top of every list.  It's pretty annoying because that dialog is my main method for navigating around in my file, and all of a sudden it doesn't work right.  I could figure out the problem if I need to... I was just hoping it was a known problem with a solution.