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
 Process Snippets in a external custom DLL
 New Topic  Reply to Topic
 Printer Friendly
Author Previous Topic Topic Next Topic  

jtwillia
New Member

USA
8 Posts

Posted - Apr 06 2009 :  11:36:39 AM  Show Profile  Reply with Quote
It would be nice to allow further user customization of snippets by end users via a user created DLL.

The user creates a .NET assembly DLL that contains a class derived from IUserSnippetModifier. VAssistX will create an instance of that class from the user DLL at startup and will use it when snippets are invoked.

The DLL would be called after VAssist has populated the values of the snippet parameters but before it substituted the parameters into the snippet text.

IUserSnippetModifier looks like this:
public interface IUserSnippetModifier
{
  void ModifySnippet(ref string snippetText, Dictionary<string, string> params);
}



Then after calling that hook function, vassist would just substitute the params into the snippet text as it normal does. Point being that the user could modify that text or params in anyway they like. User could pop up a custom GUI , embedd script commands into the snippet text to be processed by the user dll etc.

feline
Whole Tomato Software

United Kingdom
19021 Posts

Posted - Apr 07 2009 :  1:30:04 PM  Show Profile  Reply with Quote
From a support point of view this is worrying, since if the DLL does anything wrong then VA is likely to get the blame.

What are you trying to achieve? Do you have a specific thing you want to do, or is this just an interesting idea?

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

jtwillia
New Member

USA
8 Posts

Posted - Apr 08 2009 :  10:12:11 AM  Show Profile  Reply with Quote
Well mostly I want to do be able to have more ability to make good snippets. Such a change seems to be the best way to empower me to do what I want.
What started my thinking on this was "It'd be really cool if the snippets had an embedded macro language in them". That way you could do stuff like %SubStr($ClassName$, 0, 3)% or %LowerCase($UserArg$)% and such things.

Also, I could use such a plugin to display a custom gui for soliciting snippet args.

As for support, I figure it would go exact opposite of how you describe. Problem with VA? then VA support is likely to blame your user created DLL. Heh but anyways, such a feature would be useful for me that much is sure.
Go to Top of Page

feline
Whole Tomato Software

United Kingdom
19021 Posts

Posted - Apr 08 2009 :  11:31:59 AM  Show Profile  Reply with Quote
There is already a macro programming language built into the IDE. I have seen quite a few requests for Macro's in VA Snippets, but people never seem interested in the IDE macro's. I understand why, given how hard I found it to get started with IDE macro's.

You might find this forum section interesting:

http://www.wholetomato.com/forum/forum.asp?FORUM_ID=35

Problems with these dll's, speaking as support, problems caused by Anti-virus software, network shares, other IDE plugin's, etc, already get "blamed" on VA, since VA is where people notice the problem. I know, I am often the one they come to

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:
© 2023 Whole Tomato Software, LLC Go To Top Of Page
Snitz Forums 2000