#include "macros.h"
#include "const.h"
-#include "gvio.h"
#include "gvplugin_render.h"
#include "gvplugin_device.h"
+#include "gvio.h"
#include "agxbuf.h"
#include "utils.h"
#include "color.h"
gvputs(job, "#FIG 3.2\n");
gvprintf(job, "# Generated by %s version %s (%s)\n",
job->common->info[0], job->common->info[1], job->common->info[2]);
- gvprintf(job, "# Title: %s\n", obj->u.g->name);
+ gvprintf(job, "# Title: %s\n", agnameof(obj->u.g));
gvprintf(job, "# Pages: %d\n", job->pagesArraySize.x * job->pagesArraySize.y);
gvputs(job, "Portrait\n"); /* orientation */
gvputs(job, "Center\n"); /* justification */
Depth = 2;
}
-static void mp_textpara(GVJ_t * job, pointf p, textpara_t * para)
+static void mp_textspan(GVJ_t * job, pointf p, textspan_t * span)
{
obj_state_t *obj = job->obj;
int depth = Depth;
int pen_style = 0; /* not used */
int font = -1; /* init to xfig's default font */
- double font_size = para->fontsize * job->zoom;
+ double font_size = span->font->size * job->zoom;
double angle = job->rotation ? (M_PI / 2.0) : 0.0;
int font_flags = 4; /* PostScript font */
double height = 0.0;
double length = 0.0;
- if (para->postscript_alias) /* if it is a standard postscript font */
- font = para->postscript_alias->xfig_code;
+ if (span->font->postscript_alias) /* if it is a standard postscript font */
+ font = span->font->postscript_alias->xfig_code;
- switch (para->just) {
+ switch (span->just) {
case 'l':
sub_type = 0;
break;
"%d %d %d %d %d %d %.1f %.4f %d %.1f %.1f %d %d %s\\001\n",
object_code, sub_type, color, depth, pen_style, font,
font_size, angle, font_flags, height, length, ROUND(p.x), ROUND(p.y),
- mp_string(para->str));
+ mp_string(span->str));
}
static void mp_ellipse(GVJ_t * job, pointf * A, int filled)
0, /* mp_end_anchor */
0, /* mp_begin_label */
0, /* mp_end_label */
- mp_textpara,
+ mp_textspan,
mp_resolve_color,
mp_ellipse,
mp_polygon,