diff --git a/eeshow/sch-parse.c b/eeshow/sch-parse.c index 289d75a..ca48609 100644 --- a/eeshow/sch-parse.c +++ b/eeshow/sch-parse.c @@ -211,8 +211,8 @@ static bool parse_hsheet_field(struct sch_ctx *ctx, const char *line) if (sscanf(line, "F%d \"%m[^\"]\" %u", &n, &s, &dim) == 3) { switch (n) { case 0: - sheet->sheet = s; - sheet->sheet_dim = dim; + sheet->name = s; + sheet->name_dim = dim; return 1; case 1: sheet->file = s; @@ -335,7 +335,7 @@ static bool parse_line(const struct file *file, void *user, const char *line) } if (sscanf(line, "$Sheet%n", &n) == 0 && n) { ctx->state = sch_sheet; - obj->u.sheet.sheet = NULL; + obj->u.sheet.name = NULL; obj->u.sheet.file = NULL; obj->u.sheet.rotated = 0; obj->u.sheet.fields = NULL; diff --git a/eeshow/sch-render.c b/eeshow/sch-render.c index b1b9311..cfc777c 100644 --- a/eeshow/sch-render.c +++ b/eeshow/sch-render.c @@ -69,17 +69,17 @@ static void do_hsheet_text(const struct sch_obj *obj, { char *s; - assert(sheet->sheet && sheet->file); + assert(sheet->name && sheet->file); struct text sheet_txt = { - .size = sheet->sheet_dim, + .size = sheet->name_dim, .x = obj->x, .y = obj->y, .rot = 0, .hor = text_min, .vert = text_min, }; - if (asprintf(&s, "Sheet: %s", sheet->sheet)) {} + if (asprintf(&s, "Sheet: %s", sheet->name)) {} sheet_txt.s = s; /* work around "const" mismatch */ struct text file_txt = { diff --git a/eeshow/sch.h b/eeshow/sch.h index 385b146..efe45be 100644 --- a/eeshow/sch.h +++ b/eeshow/sch.h @@ -67,8 +67,8 @@ struct sch_obj { } comp; struct sch_sheet { unsigned h, w; - const char *sheet; - unsigned sheet_dim; + const char *name; + unsigned name_dim; const char *file; unsigned file_dim; bool rotated;