DGML:如何为自定义图表启用“转到定义”? [英] DGML: how to enable the 'Go To Definition' for custom diagrams?

查看:147
本文介绍了DGML:如何为自定义图表启用“转到定义”?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我通过DGML API生成一个自定义工作流程图,其中每个节点都对应一个C#类。我希望能够使用内置的Go To Definition功能,但缺少文档。 不能修改goto定义,但可以使用goto reference代替。如果您在文本编辑器中手动编辑DGML文件,则可以将引用属性添加到节点,如下所示:

  < Node Id =BoomerangReference =Boomerang.dgml/> 

然后,当您在VS中右键单击此节点时,您会看到一个名为Go To Reference 如果你点击这个子菜单,它将打开引用的DGML文件。



请参阅 https://msdn.microsoft.com/en-us/library/ee842619.aspx#AddReferences 以获取更多详细信息。 / p>

I am generating a custom workflow diagram via DGML API where each node corresponds to a C# class. I would like to be able to use the built-in 'Go To Definition' feature but the documentation is lacking.

解决方案

You cannot modify goto definition, but you can use "goto reference" instead. If you manually edit the DGML file in a text editor you can add a "Reference" property to a node, like this:

<Node Id="Boomerang" Reference="Boomerang.dgml"/>

Then when you right click this node in VS you will see a new menu appear named "Go To Reference" with a submenu containing "Reference", if you click this it will open the referenced DGML file.

See https://msdn.microsoft.com/en-us/library/ee842619.aspx#AddReferences for more detail.

这篇关于DGML:如何为自定义图表启用“转到定义”?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆