【问题标题】:How can I make my Graphviz graphs have large text?如何使我的 Graphviz 图表具有大文本?
【发布时间】:2013-05-30 14:22:56
【问题描述】:

我根据对旧 VB6 代码执行的一些静态代码分析生成图表。

问题是字体太小,无法打印,即使在我们的 A3 打印机上也是如此。

我已将字体大小设置为大,但似乎没有任何区别。

这是原来的 DOT:

http://pastebin.com/hVD8xKDZ

这是通过 unflatten -l 20 运行的 DOT:

http://pastebin.com/gchwENKE

生成的命令就是:

dot -Tpng -o"输出" -Kdot"输入"

但字体总是太小,无法在 A3 上阅读。

这是图表设置:

This makes the arrows merge
concentrate=true,

Laser printer resolution
dpi=600,

It's the dot language
layout=dot,

Doesn't seem to do much
overlap=true,

The ratio of A3 paper
ratio=1.4142,

The size of A3 paper in inches
size="11.69,16.53"

如果我去掉比例,线条更短,文字看起来更大,但图表不是 A3 形状。

没有 DPI 或大小,dot.exe 就会崩溃。

为什么不让字体变大?

为什么 unflatten 不按应有的方式错开节点?

为什么即使我已经说明了dpi和尺寸,它也会创建一个没有比率的daft ratio?

【问题讨论】:

    标签: graphviz


    【解决方案1】:

    我无法打开您的点文件的链接。

    但是,点语言的字体大小很容易调整

    digraph foo {
            fontsize = 10
            ...
    }
    

    【讨论】:

    • 真的吗?它们为我工作,我已将它们公开。不过,我在点中有node [fontsize=48];。但这是一个非常宽的图,我无法让它平方并扩大节点。
    • 听起来您需要更改布局算法?
    • 布局是点。那里还有什么?文档似乎根本没有列出它们:graphviz.org/content/attrs#dlayout
    • dot 有几种布局算法:dot,neato,twopi,circo,fdp...试试circo 和neato。
    • 到目前为止 fdp 已经产生了一些有用的东西。
    猜你喜欢
    • 2019-10-25
    • 2011-04-17
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2011-11-24
    • 1970-01-01
    • 2012-10-31
    • 1970-01-01
    相关资源
    最近更新 更多