#include "config.h"
+#ifndef _ISOC99_SOURCE
+# define _ISOC99_SOURCE
+#endif
+#ifndef _POSIX_C_SOURCE
+# define _POSIX_C_SOURCE 200112L
+#endif
+
#include <stdlib.h>
#include <stdio.h>
#include <unistd.h>
return (0);
} /* }}} int read_options */
-static double determine_stage_width (sn_stage_t *s)
+static double determine_stage_width (sn_stage_t *s) /* {{{ */
{
int lines[s->comparators_num];
int right[s->comparators_num];
assert (lines_used >= 1);
return (((double) (lines_used - 1)) * INNER_SPACING);
-}
+} /* }}} double determine_stage_width */
static double determine_network_width (sn_network_t *n) /* {{{ */
{
printf ("<?xml version=\"1.0\" standalone=\"no\"?>\n"
"<!DOCTYPE svg PUBLIC \"-//W3C//DTD SVG 1.1//EN\" "
"\"http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd\">\n"
- "<svg xmlns=\"http://www.w3.org/2000/svg\" version=\"1.1\" "
- "width=\"%gpt\" height=\"%gpt\" viewBox=\"0 0 %g %g\">\n",
+ "<svg:svg xmlns:svg=\"http://www.w3.org/2000/svg\" version=\"1.1\" "
+ "width=\"%g\" height=\"%g\" viewBox=\"0 0 %g %g\">\n",
svg_width, svg_height, svg_width, svg_height);
printf ("<!-- Output generated with sn-svg from %s -->\n", PACKAGE_STRING);