Windows 8.1.
svn 11313
----------
Selecting 2 contiguous lines, the first one being marked as a comment and the second not, the Edit-> Toggle comment command does not reverse the first line as it should, but only comments the two lines.
Ex:
// yant = yfrc;
xant = intersection.first;
After selecting the two lines and apply Toggle comment:
//// yant = yfrc;
// xant = intersection.first;
Is it a bug?
This looks like the sane behaviour in this case.
Sorry, but I have to disagree.
Toggle means to reverse the situation of the lines.
That is, a line that is a comment, becomes a normal line and the line that is normal, becomes comment.
See Notepad ++, for example.
aaaaaaaaaaaaaaa
// xxxxxxxxxxxxxx
Select both line and press Ctrl+Q:
aaaaaaaaaaaaaaa
// xxxxxxxxxxxxxx
So notepad++ does nothing in this case?
Sorry, mistyped.
After pressing Ctrl+Q (on Notepad++):
// aaaaaaaaaaaaaaa
xxxxxxxxxxxxxx
I agree that toggle should work the way rogeriodec suggests, unless it's specifically intended not to toggle per-line. Otherwise the function is of limited usefulness, such as if you had a long block of code that toggles between two different test configurations of code by swapping which part is commented.
Patches welcome...
please open a ticket on sf, so this won't get lost....
I created ticket #650 describing some issues with the various comment functions.
Thank you!