in reply to Re: $_ is null in Tk:Scrolled search?
in thread $_ is null in Tk:Scrolled search?
I understand that $from returns an integer value representing the line number and character number of the first character in the latched word. However I need a way to search each string the "search" function in the while loop is searching so I can check for a comment character. Maybe I can just add this check to the while loop statement.
Basically I need to check if a commented string is on the same line as the found matched $word. If it is I am sure you can see from my code what I want to do. If not I simply want to test if the coordinates of the comment character is after the $from of the matched word. If it is after then I know it is safe to color the matched word it's corresponding color. If the matched word is after a comment character (meaning it is part of a commented string) then I do not want to color it.