【问题标题】:Connecting arcs between lines in Dot (GraphViz)在 Dot (GraphViz) 中的线之间连接弧线
【发布时间】:2011-01-16 10:05:28
【问题描述】:

我必须为我的 AI 课程制作一个状态空间图,我希望使用 GraphViz 来制作它(比 Dia 快得多)。我似乎不知道该怎么做的一件事是如何进行“与”连接,这基本上是连接到同一节点的两条线之间的弧线。这可能吗?

【问题讨论】:

    标签: graph graphviz dot


    【解决方案1】:

    是的。虽然没有明确的点语法,但它几乎总是这样做的:

    # just graph set-up
    digraph new_graph {
    ratio = "auto"
    mincross = 2.0
    
    # draw some nodes
    "001" [shape=box, regular=1, style=filled, fillcolor="#FCD975"] ;
    "017" [shape=circle  , regular=1,style=filled,fillcolor="#9ACEEB"   ] ;
    "007" [shape=diamond  , regular=1,style=filled,fillcolor="#FCD975"   ] ;
    # the key line--creating tiny node w/ no label, no color
    # i use this style because it mimics the 'midpoint' style used in Omnigraffle et al.
    "LN01" [shape=diamond,style=filled,label="",height=.1,width=.1] ;
    
    # draw the edges
    "001" -> "LN01" [dir=none,weight=1] ;
    "007" -> "LN01" [dir=none,weight=1] ;
    "LN01" -> "017" [dir=none, weight=2] ;
    }
    

    alt text http://img121.imageshack.us/img121/2547/dotgvziv.png

    【讨论】:

      猜你喜欢
      • 2016-12-16
      • 1970-01-01
      • 1970-01-01
      • 2019-08-15
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 1970-01-01
      • 2017-12-16
      相关资源
      最近更新 更多