Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
User name:
Password:
Save Password
Forgot your password?

 All Forums
 Visual Assist
 Feature Requests
 Smart . to -> replacement
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

Mordachai
Tomato Guru

USA
224 Posts

Posted - Apr 01 2014 :  2:59:37 PM  Show Profile  Reply with Quote
I like the . becomes -> some of the time. But it would be so much more powerful if it looked at what I was typing next to decide which it should use, and then make the correction (or uncorrection).

e.g., if I type:

myptr.get()

It should leave it as .

myptr.invoke()

This would be converted to:

myptr->invoke(), because myptr doesn't have an invoke member, but it's underlying pointed-to-type does.

accord
Whole Tomato Software

United Kingdom
3287 Posts

Posted - Apr 01 2014 :  5:39:47 PM  Show Profile  Reply with Quote
Interesting idea, thank you for sharing this with us. However, I feel that users don't usually continue typing after a correction has happened, I imagine they correcting it first. Especially since they won't have any the right type of suggestions: . suggests the template class members, while -> suggests the class "behind" operator ->, so you would need to type in the member's name "blind". Are you aware that hitting backspace corrects the conversion and replaces the listbox with the correct members?

Edited by - accord on Apr 01 2014 5:41:09 PM
Go to Top of Page

Mordachai
Tomato Guru

USA
224 Posts

Posted - Apr 03 2014 :  12:44:53 PM  Show Profile  Reply with Quote
For whatever reason, lately (I use the current beta of VA + VS2013 update 1) when I hit bs, it often fails to correct the -> replacement. Probably because I had already started to type the first character or two of the member. So I end up having to "fight" with the system, erasing, typing again, erasing again, until I can get it to switch to the correct operator.

I think it would be very easy to learn to keep typing, and for VA to offer symbols both from the . space and the -> space (just combine them in the suggestion list, depending on which I finished typing or selected from the suggestion drop-down, the correct operator . or -> would be retroactively applied).

I've turned this feature off for now. It's just too frustrating with the current interaction between how I type and how VA handles it. It really does feel like I'm fighting VA due to the fact that it "forgets" that a backspace should first undo the ./-> replacement. Again, not sure why it's forgotten - seems like if I type a little more, or even if a suggestion box comes up, either case it's lost the context that tells it that BS == undo correction.
Go to Top of Page

accord
Whole Tomato Software

United Kingdom
3287 Posts

Posted - Apr 03 2014 :  5:09:00 PM  Show Profile  Reply with Quote
Interesting idea, I have put in a feature request for this:

case=81399

Correction "loses context" after typing but should not after a listbox. At any rate, undo will always work - Visual Assist puts the correction itself to the undo buffer separately.
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000