Whole Tomato Software Forums
Whole Tomato Software Forums
Main Site | Profile | Register | Active Topics | Members | Search | FAQ
 All Forums
 Visual Assist
 Feature Requests
 Constrain Ctrl+Alt+F to current function

You must be registered to post a reply.
Click here to register.

Screensize:
UserName:
Password:
Format: BoldItalicizeUnderlineStrikethrough Align leftCenterAlign right Insert horizontal ruleUpload and insert imageInsert hyperlinkInsert email addressInsert codeInsert quoted textInsert listInsert Emoji
   
Message:

Forum code is on.
Html is off.

 
Check to subscribe to this topic.
   

T O P I C    R E V I E W
foxmuldr Posted - Jun 08 2016 : 09:43:55 AM
Is there a way to constrain the Ctrl+Alt+F find feature to the current function? Or the current source file? If not, could it be added?

Best regards,
Rick C. Hodgin
12   L A T E S T    R E P L I E S    (Newest First)
foxmuldr Posted - Jun 15 2016 : 8:30:27 PM
quote:
Originally posted by feline

Firstly an API would have to be designed and written, then maintained. We already have different available features in different IDE's, and a steady stream of new IDE's to support.

I agree that this would be helpful in some cases, but currently we don't have any plans to do this. We have to prioritise our available resources somehow, and currently this just does not seem to be the best place to focus them.



As before, I'd agree to sign a non-disclosure agreement, a non-compete agreement, etc., get a copy of the source code, and add in the API and code myself, giving it to you in a complete (or mostly complete) form.

I'd be happy to design, implement, and even maintain it under NDA and non-compete.

Best regards,
Rick C. Hodgin
feline Posted - Jun 15 2016 : 8:00:47 PM
Firstly an API would have to be designed and written, then maintained. We already have different available features in different IDE's, and a steady stream of new IDE's to support.

I agree that this would be helpful in some cases, but currently we don't have any plans to do this. We have to prioritise our available resources somehow, and currently this just does not seem to be the best place to focus them.
foxmuldr Posted - Jun 14 2016 : 2:14:23 PM
quote:
Originally posted by feline
As for add-on code, we are already an add-on for an existing tool. There is nothing stopping anyone writing their own add-on to run in parallel if they so desire.



We've had this discussion before. You already have an engine that's been constructed, debugged, and well developed. You would only need to expose access points through an exposed API to deliver the ability for external apps to use your engine. You could expose them in such a way that they are higher level things, and not at a level where we could call something incorrectly. Simple features like:

identify_symbol_by_file_line_and_position()
set_post_process_find_results_hook()
set_repaint_hook()
...and so on.

These would allow our VAX add-in plugins to call and be called to utilize, augment, and decorate VAX content in a way which is simple, flexible, powerful, and has the ability to add these features where required. It would also spawn more sales because it's an augment to VAX, which means people would need VAX to use our add-ons.

It would greatly simplify the process of creating an add-on, as it would just be a series of function calls to your engine, with your engine handling all of the mechanics, and ours doing some highest-end manipulation of those raw results.

I honestly don't know why you won't add this. It wouldn't take long, and would resolve nearly all of these requests for features many of us would like. We could just create an add-on for it and put it in a public repository for people to pick-and-choose from.

Best regards,
Rick C. Hodgin
feline Posted - Jun 13 2016 : 7:35:08 PM
We have limited resources, like every company and project, so somehow we have to prioritise and balance new features with bug reports. It would not help if I simply put in a feature request for every feature suggested here, by you and others, knowing that most of them would not be acted on any time soon, if ever, due to the combined work required. So I try to find alternate solutions with existing functionality where possible.

We do try to listen to what is popular as well, I certainly don't have all of the answers, or always know what features should or should not be considered. So looking to see if there is a good case to be made for a feature seems a sensible step to take.

I am sorry if this is not the answer you are looking for, but it is the truth.

As for add-on code, we are already an add-on for an existing tool. There is nothing stopping anyone writing their own add-on to run in parallel if they so desire.
foxmuldr Posted - Jun 10 2016 : 11:06:39 PM
quote:
Originally posted by feline

Can you please try the following very simple test code:
with
VA Options -> Highlighting -> Highlight write and read references to symbol under cursor
turned on, only the correct references are being highlighted. Do you see the same thing?


Yes. It works.

quote:
Limiting Find References to the current function seems a rather narrow feature, if there are existing options that will help.



I run into this a lot with people. They come across an idea that doesn't conform with their way of thinking about how development should be done, so it is not important to them, or is labeled something like "narrow feature".

I am a developer working on creating toolsets to give to people. I'm not prepared to determine categorically for other developers what features are desirable or undesirable. I desire to expose and give everyone those capabilities which exist, and then credit them with enough intelligence to determine for themselves which solutions are best for their use case. I also intend to provide add-on code which will allow them to write their own extensions, which may be useful to them.

In this case, when I position my caret over the word it highlights the other references correctly. I can see the other ones nearby. It doesn't enumerate them. There isn't a list I can go through, as with a find result, one-by-one to examine the context. I can't look only into the find results window and see a compact and concise list of source code lines which have those results. What you propose is a different operation. Is it usable? Possibly. But it's not the same.

I continue to be disappointed coming here with feature request after feature request which are rejected. I will evaluate the effort.

Best regards,
Rick C. Hodgin
feline Posted - Jun 10 2016 : 5:27:41 PM
Can you please try the following very simple test code:

struct FelineDatum
{
	int buffer;
	int data_s8;
};

struct FelineBuilder
{
	int buffer;
	int data_s8;
};

void testHighlightSpecific()
{
	FelineDatum datumVar;
	FelineBuilder builderVar;
	// place the caret into "buffer" or "data_s8"
	// and only the correct instances are highlighted
	datumVar.buffer = 0;
	datumVar.data_s8 = 0;
	builderVar.buffer = 1;
	builderVar.data_s8 = 1;
	datumVar.buffer++;
	datumVar.buffer += 3;
}

with

VA Options -> Highlighting -> Highlight write and read references to symbol under cursor

turned on, only the correct references are being highlighted. Do you see the same thing?

Limiting Find References to the current function seems a rather narrow feature, if there are existing options that will help.
foxmuldr Posted - Jun 09 2016 : 2:21:08 PM
quote:
Originally posted by feline

Have you considered using Highlight Find Results, to quickly highlight all instances of a symbol:


Yes. :-)

quote:
you can even map a keyboard shortcut to the command VAssistX.FindSelected to highlight instances of the word under the caret, without opening the Find dialog.

You can also tell VA to highlight references to the symbol under the cursorL


I have that feature enabled. It highlights the word, but not the context. It has some use, but not in all cases. For example, I'm looking at two structures I use nearly everywhere:

SDatum
SBuilder

Both have these members, which are used very often:
typedef char s8;
s8* buffer;
s8* data_s8;

So if I'm on a structure that has an SDatum or SBuilder field called "fred", and I am then referencing fred->data_s8, and I want to find where all fred->data_s8 is used in the current scope, then I can only do it with find references. If I search just for data_s8 it will also highlight the other structure's data_s8 members, which I don't want.

Searching by name can be useful, and I do use it, but it's not always the correct solution.

-----
You seem reticent to consider this request of limiting the find scope to just the current function, so I will withdraw my request. I'll make due with the find current file ability, and then manually whittle down the fewer results compared to the way I do it now.

Thank you for VAX. It is a good tool and it increases my productivity.

Best regards,
Rick C. Hodgin
feline Posted - Jun 09 2016 : 1:33:33 PM
Have you considered using Highlight Find Results, to quickly highlight all instances of a symbol:

http://docs.wholetomato.com/default.asp?W185

you can even map a keyboard shortcut to the command VAssistX.FindSelected to highlight instances of the word under the caret, without opening the Find dialog.

You can also tell VA to highlight references to the symbol under the cursorL

http://docs.wholetomato.com/default.asp?W186

the idea being to highlight, and thus easily find, the symbol or symbols you want, without much delay.
foxmuldr Posted - Jun 09 2016 : 09:35:22 AM
quote:
Originally posted by feline
How long are the functions you are working with? Are the extra references really an issue?



They vary. Typically 25 to 100 lines, about what will fit on my 1920 x 1200 monitor. However, I don't always work on that monitor. And, when I'm in the debugger, the code window is notably smaller. Since VS and MSVC allow edit-and-continue, I often continueto write my code while it's running.

quote:
If this is something you only need now and then, are you aware you can delete results from the Find References Results list? You can highlight all of the results who's scope (the first part of the result) is in the wrong function, then press Del to remove them from the results list, just leaving you with the results you are interested in.



That's a workaround. :-) However, many of the things I would search for are part of oft-used global structure members, so the result set may be very large (hundreds of entries). If there were a way to hone down to the one function, it would be desirable. But the workaround is also workable. What I typically do today is do the global search (which also takes several seconds longer than would a function or file search), and then locate the function within the list. The entries are all grouped together so I just leave them.

But, it's extra work for me, and it's something I do regularly, hence the request.

Best regards,
Rick C. Hodgin
feline Posted - Jun 08 2016 : 11:34:32 PM
Typos are very easy to make, we all do it, I just needed to know which command you were looking at :)

How long are the functions you are working with? Are the extra references really an issue?

If this is something you only need now and then, are you aware you can delete results from the Find References Results list? You can highlight all of the results who's scope (the first part of the result) is in the wrong function, then press Del to remove them from the results list, just leaving you with the results you are interested in.
foxmuldr Posted - Jun 08 2016 : 12:40:16 PM
quote:
Originally posted by feline

What do you have Ctrl+Alt+F mapped to? I have Find References mapped to Shift+Alt+F, which is the default keyboard mapping, if available.


I meant Shift+Alt+F. A typo.

quote:
If you do mean Find References, then you can use the Find References in File command instead if you want results limited to just the current file. This is in the VAssistX menu, or in the IDE options you can map a keyboard shortcut to the command VAssistX.FindReferencesinFile.


I'll map that to a keystroke. Thank you.

quote:
Unfortunately no, you cannot constrain Find References to just the current function. But you could use Smart Select:

http://docs.wholetomato.com/default.asp?W560

to quickly select the current function, and then do an IDE find with the scope set to the current selection.



Can this feature be added with a VAssist.XFindReferencesinFunction ?

Best regards,
Rick C. Hodgin
feline Posted - Jun 08 2016 : 11:19:50 AM
What do you have Ctrl+Alt+F mapped to? I have Find References mapped to Shift+Alt+F, which is the default keyboard mapping, if available.

If you do mean Find References, then you can use the Find References in File command instead if you want results limited to just the current file. This is in the VAssistX menu, or in the IDE options you can map a keyboard shortcut to the command VAssistX.FindReferencesinFile.

Unfortunately no, you cannot constrain Find References to just the current function. But you could use Smart Select:

http://docs.wholetomato.com/default.asp?W560

to quickly select the current function, and then do an IDE find with the scope set to the current selection.

© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000