如何在 WPF 中轻松绘制图形? [英] How to easily draw graphs in WPF?

查看:29
本文介绍了如何在 WPF 中轻松绘制图形?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我需要绘制表示有限状态机的图形.我尝试使用

目前建议的所有工具都不适合这种情况,或者我可能不知道如何在这种情况下应用它们.

解决方案

Graphviz + GraphViz C# Wrapper 正是我想要的.

I need to draw graphs representing finite state machines. I tried to use Graph#. It's cool, but it lacks some things. There is no documentation, which makes it very difficult to use, I cannot draw loops (edges from a vertex to itself) using its custom WPF control and labeling edges is also not implemented. Is there any other library o adviced way of drawing graphs in WPF?

Functionality I need:

  • edge labeling
  • loop (cyclic) edges
  • vertex labeling
  • drawing single/double circles around vertices - vertices should be represented either as circle (or double circle) with a label inside

Any ideas?


EDIT:

I got some propositions, for which I am grateful. However, I think I have not made my thought clear. I need this kind of graph:

All tools suggested as far are not suitable for this or maybe I don't know how to apply them in this situation.

解决方案

Graphviz + GraphViz C# Wrapper are exactly what I was looking for.

这篇关于如何在 WPF 中轻松绘制图形?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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