diff --git a/ChangeLog b/ChangeLog
index 9ee7d42ea..6b5b6c34b 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
2004-02-02 Alexandre Duret-Lutz
'
+
+def render_automaton(basename, automata):
+ outfile = spot.ofstream(basename + '.dot')
+ spot.dotty_reachable(outfile, automata)
+ del outfile
+ render_dot(basename)
+
+def render_bdd(basename, dictionary, bdd):
+ outfile = spot.ofstream(basename + '.dot')
+ spot.bdd_print_dot(outfile, dictionary, bdd)
+ del outfile
+ render_dot(basename)
+
print "Content-Type: text/html"
print
@@ -214,15 +233,7 @@ if show_automaton_dot:
print ''; sys.stdout.flush()
if show_automaton_gif:
- outfile = spot.ofstream(imgprefix + '-a.dot')
- spot.dotty_reachable(outfile, automaton)
- del outfile
- os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-Gsize=14,14', '-o',
- imgprefix + '-a.gif', imgprefix + '-a.dot')
- os.spawnlp(os.P_WAIT, 'convert', 'convert',
- imgprefix + '-a.gif', imgprefix + '-a.png')
- print '
'
-
+ render_automaton(imgprefix + '-a', automaton)
if show_degen_dot or show_degen_gif:
print '
'
+ render_automaton(imgprefix + '-d', degen)
else:
degen = 0
@@ -264,35 +268,21 @@ if (type(automaton) == spot.tgba_bdd_concretePtr
escaped_print_set(automaton.get_dict(),
automaton.get_core_data().relation)
if show_relation_gif:
- outfile = spot.ofstream(imgprefix + '-b.dot')
- spot.bdd_print_dot(outfile, automaton.get_dict(),
- automaton.get_core_data().relation)
- del outfile
- os.spawnlp(os.P_WAIT, 'dot', 'dot', '-Tgif', '-Gsize=14,14', '-o',
- imgprefix + '-b.gif', imgprefix + '-b.dot')
- os.spawnlp(os.P_WAIT, 'convert', 'convert',
- imgprefix + '-b.gif', imgprefix + '-b.png')
- print '
'
+ render_bdd(imgprefix + '-b', automaton.get_dict(),
+ automaton.get_core_data().relation)
if (type(automaton) == spot.tgba_bdd_concretePtr
and (show_acceptance_dot or show_acceptance_set or show_acceptance_gif)):
print '
'
+ render_bdd(imgprefix + '-c', automaton.get_dict(),
+ automaton.get_core_data().acceptance_conditions)
if show_lbtt:
print '