I had mentioned this before. The behaviour of the double-click is not consistent with the Java editor.
In the Java editor, double-clicking on a variable will highlight the variable, and only the variable. This includes all charaacters which are valid variable characters, but no characters which are not valid.
In a JSP, double clicking works fine within <% and %>, but does not work consistently within quotes or other JSP elements. In some cases it chooses all the text between quote characters (be they a single quote or a double quote). At other times it picks out text where on one side there is a slash and the other side a period. Then it might pick out alpha characters leaving out underscores. And so on.
It is consistent in each case (Java vs HTML vs JavaScript vs CSS vs JSp directives) but is in-consistent between cases.
It would be really good if at all times it followed the standard Java editor, that is variable name characters only.
Except in special cases that iimuhin mentions, where the mouse cursor is not over a variable name, but over block elements.