Saveliy Belkin
Saveliy Belkin

Reputation: 63

graph-tool Make text fit to the vertex

I am ploting the graph with big labels. Is there a way to wrap the labels so they would fit in the vertex of the size.

this is what I have so far

p1 = gt.graph_draw(gr1,
                   output_size=(2000, 6000),
                   pos=pos1,
                   vertex_shape="square",
                   bg_color=(256, 256, 256, 1),
                   vertex_size=20,
                   output='test1.png',
                   vertex_text=gr1.vp['label'],
                   vertex_fill_color=gr1.vp['color'])

example Thank you in advance

Upvotes: 5

Views: 261

Answers (0)

Related Questions