I'm just getting started with SyntaxEditor.
I've created a new language that is "in the spirit" of VB.NET and have been able to modify the supplied samples for VB.NET to get syntax coloring and outlining for my language.
Now, I'm trying to hook up some "meatier" functionality and I haven't been able to figure out how best to proceed. Specifically, I want to do something similar to the “Implement Interface” functionality in Visual Studio 2005: when you right click on an interface name that is part of a class definition, you get a context menu with “Implement Interface” on it. Right now, I’m only concerned with displaying & handling the context menu. Using the SyntaxEditor’s “Smart Tags” instead of context menu would also be acceptable.
In reading through the documentation, it looks like there may be several options available, but right now I can’t really figure out even where to start. For example, just like with the VS2005 “Implement Interface” functionality, I only want the context menu (or smart tag) in a very particular situation. For me, the code looks like
CHILD childName AS ParentName
'other stuff here
END CHILD
I want the “Implement Interface”-like functionality on “ParentName”, but only when it is part of a CHILD definition shown above.
It looks like maybe one place to start is by adding a child state to my dynamic language definition; am I going to be able to (easily) do what I want by using a dynamic language? Or am I going to have to create a SyntaxLanguage directly?
And once I get past that, I need to know how to actually hook up the UI. There didn't seem to be much sample code using "Smart Tags", I didn't find any custom context menu sample.
Thanks for the help & guidance.
Dan
I've created a new language that is "in the spirit" of VB.NET and have been able to modify the supplied samples for VB.NET to get syntax coloring and outlining for my language.
Now, I'm trying to hook up some "meatier" functionality and I haven't been able to figure out how best to proceed. Specifically, I want to do something similar to the “Implement Interface” functionality in Visual Studio 2005: when you right click on an interface name that is part of a class definition, you get a context menu with “Implement Interface” on it. Right now, I’m only concerned with displaying & handling the context menu. Using the SyntaxEditor’s “Smart Tags” instead of context menu would also be acceptable.
In reading through the documentation, it looks like there may be several options available, but right now I can’t really figure out even where to start. For example, just like with the VS2005 “Implement Interface” functionality, I only want the context menu (or smart tag) in a very particular situation. For me, the code looks like
CHILD childName AS ParentName
'other stuff here
END CHILD
I want the “Implement Interface”-like functionality on “ParentName”, but only when it is part of a CHILD definition shown above.
It looks like maybe one place to start is by adding a child state to my dynamic language definition; am I going to be able to (easily) do what I want by using a dynamic language? Or am I going to have to create a SyntaxLanguage directly?
And once I get past that, I need to know how to actually hook up the UI. There didn't seem to be much sample code using "Smart Tags", I didn't find any custom context menu sample.
Thanks for the help & guidance.
Dan