Skip to content

Commit 518f23f

Browse files
committed
Format options tweaks
1 parent d2dded1 commit 518f23f

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

mathicsscript/format.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -353,11 +353,11 @@ def format_graph(G):
353353

354354
vertex_labels = G.vertex_labels if hasattr(G, "vertex_labels") else False
355355
if vertex_labels:
356-
draw_options["with_labels"] = vertex_labels.to_python() or False
356+
draw_options["with_labels"] = bool(vertex_labels)
357357

358-
if hasattr(G, "title") and G.title.get_string_value():
358+
if hasattr(G, "title") and G.title:
359359
fig, ax = plt.subplots() # Create a figure and an axes
360-
ax.set_title(G.title.get_string_value())
360+
ax.set_title(G.title)
361361

362362
if graph_layout:
363363
if not isinstance(graph_layout, str):

0 commit comments

Comments
 (0)