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
 Technical Support
 Create Implementation usually wrong spot
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

swinefeaster
Tomato Guru

296 Posts

Posted - Apr 23 2020 :  8:55:47 PM  Show Profile  Reply with Quote
I would except that if I add a new function in the header, and then I use VAX | Create Implementation, it should put it in the cpp right below the function it's below in the header. Sometimes it does this. But most of the time it throws it at the bottom...

Is there any change you guys could fix this?

Thanks
swine

feline
Whole Tomato Software

United Kingdom
16732 Posts

Posted - Apr 24 2020 :  07:25:48 AM  Show Profile  Reply with Quote
When this goes wrong, if you undo the refactoring, and then run Create Implementation again, do you get the same wrong placement in the cpp file? I am wondering if this is random or always happening.

Assuming this is reliable, can you please try turning Off:

VA Options -> Code Generation -> Maintain order in header and source files for generated C/C++ implementations

and accepting this change, then see where the implementation is placed. Then try turning this setting on again and again see where the implementation is placed.

I just want to make sure that VA is obeying this setting, at least some of the time. If it is, it suggests there is something in the layout of the header / cpp file pair that is confusing us.

zen is the art of being at one with the two'ness
Go to Top of Page

swinefeaster
Tomato Guru

296 Posts

Posted - Apr 24 2020 :  2:40:54 PM  Show Profile  Reply with Quote
ah i found it. the "final" keywords breaks this vax feature.

MyClass.h:

class MyClass final
{
    void foo();
    void middle();
    void moo();
};


MyClass.cpp:

#include "MyClass.h"


void MyClass::foo()
{

}


void MyClass::moo()
{

}


void MyClass::middle()
{

}


(if i remove the final keyword, middle() is generated in the correct spot)
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
16732 Posts

Posted - Apr 25 2020 :  08:29:43 AM  Show Profile  Reply with Quote
Ah, thank you for this, I am seeing the same result here. That was really rather easy to reproduce, once you know what the trigger is. I have put in a bug report for this:

case=142183

for now, if you don't already know, you can use drag and drop, or cut and paste, in VA Outline to help you quickly and easily re-order functions in your files:

https://docs.wholetomato.com/default.asp?W187

zen is the art of being at one with the two'ness
Go to Top of Page

swinefeaster
Tomato Guru

296 Posts

Posted - Apr 27 2020 :  1:20:53 PM  Show Profile  Reply with Quote
oh i didn't know that. can i do that with the keyboard? i try to avoid the mouse when i can, since it's slow. would be great to be able to bind a hotkey to MoveImplementaionUpInCppFile or something like that.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
16732 Posts

Posted - Apr 28 2020 :  07:03:41 AM  Show Profile  Reply with Quote
In the IDE options dialog:

IDE tools menu -> Options -> Environment -> Keyboard

you can map a keyboard shortcut to the command:

VAssistX.VAOutline

which will show VA Outline and place keyboard focus into the outline. You can now move to the function / item you want to move, use CTRL-X to cut it, and then CTRL-V to paste it into the new position you want for it in the file. Since VA Outline allows you to select and move more than one item at a time, this is actually more powerful and flexible, just not quite so direct.

If you are interested the full list of available keyboard shortcuts is given here:

https://docs.wholetomato.com/default.asp?W375

zen is the art of being at one with the two'ness
Go to Top of Page

swinefeaster
Tomato Guru

296 Posts

Posted - Apr 28 2020 :  2:21:04 PM  Show Profile  Reply with Quote
thanks! however, i was hoping for a shortcut to move the implementation without having to open other windows... the window input focus behavior in VS has been really bad for the past decade or so.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
16732 Posts

Posted - Apr 29 2020 :  05:46:34 AM  Show Profile  Reply with Quote
Are you seeing specific problems with window focus? When I bounce around through a lot of different windows I can sometimes just have to hit Escape once or twice to get focus back to where I want it. So I am wondering if you are seeing any problem specific to VA's windows and focus.

Outside of that though, the only problem I am really aware of running into is that autohide tool windows stay open if they opened "under" the mouse cursor. Makes sense for a mouse focused user, but less sense for a keyboard focused user.

zen is the art of being at one with the two'ness
Go to Top of Page

swinefeaster
Tomato Guru

296 Posts

Posted - Apr 29 2020 :  1:42:25 PM  Show Profile  Reply with Quote
i'm talking about "hit Escape once or twice to get focus back to where I want it". i don't see how that's a good experience to be honest.

also, many times when i ctrl+tab to another source file and press ctrl+f and start typing into the find window, a second later, visual studio puts the focus onto the source window and half my input gets thrown into the source code. it's like they implemented it on a timer. though maybe it's visual assist's fault? not really sure
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
16732 Posts

Posted - Apr 30 2020 :  12:26:45 PM  Show Profile  Reply with Quote
I end up pressing Escape a lot simply because I am always in and out of tool windows, dialogs, solutions, etc, so I am not a typical user at all.

So far I cannot reproduce this focus on Ctrl-Tab followed by Ctrl-F in VS2019 with or without VA installed. Have you tried disabling VA to see if this makes any obvious difference? At a first test the menu item:

VAssistX -> Enable/Disable Visual Assist X

should help.

Do you get this problem in all files, or only some files? Perhaps large, or complex, or language dependent?

zen is the art of being at one with the two'ness
Go to Top of Page

swinefeaster
Tomato Guru

296 Posts

Posted - May 26 2020 :  2:16:46 PM  Show Profile  Reply with Quote
for the original bug listed above (142183), when will the fix show up in a build? thanks
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
16732 Posts

Posted - May 27 2020 :  09:21:36 AM  Show Profile  Reply with Quote
I don't have a current estimate, but we are aiming to get this bug fixed in the next few builds, so hopefully not to long now.

zen is the art of being at one with the two'ness
Go to Top of Page

swinefeaster
Tomato Guru

296 Posts

Posted - Jun 30 2020 :  2:04:11 PM  Show Profile  Reply with Quote
still on the radar?

i guess not in the new build yet
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
16732 Posts

Posted - Jul 01 2020 :  04:52:15 AM  Show Profile  Reply with Quote
Unfortunately no progress on this yet, but yes, still very much on the radar. We are hoping to get this addressed in the next few builds, but it is not always easy to decide where to focus limited resources for each build.

zen is the art of being at one with the two'ness
Go to Top of Page
  Previous Topic Topic Next Topic  
 New Topic  Reply to Topic
 Printer Friendly
Jump To:
© 2019 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000