summaryrefslogtreecommitdiff
path: root/gfx/gfx.h
diff options
context:
space:
mode:
authorWerner Almesberger <werner@almesberger.net>2016-08-24 18:08:15 -0300
committerWerner Almesberger <werner@almesberger.net>2016-08-24 18:08:15 -0300
commit71d2312487fed19d2500357cb644c3801179f600 (patch)
tree70510dcfbc9abb3376306492b89845333fc2865b /gfx/gfx.h
parent279ddbdb4fb11dbffb487db05b74787b5275b4d9 (diff)
downloadeeshow-71d2312487fed19d2500357cb644c3801179f600.tar.gz
eeshow-71d2312487fed19d2500357cb644c3801179f600.tar.bz2
eeshow-71d2312487fed19d2500357cb644c3801179f600.zip
separate argument list from gfx_init; related API changes
Diffstat (limited to 'gfx/gfx.h')
-rw-r--r--gfx/gfx.h7
1 files changed, 4 insertions, 3 deletions
diff --git a/gfx/gfx.h b/gfx/gfx.h
index c31495b..330a2fb 100644
--- a/gfx/gfx.h
+++ b/gfx/gfx.h
@@ -39,7 +39,8 @@ struct gfx_ops {
void (*tag)(void *ctx, const char *s,
int points, const int x[points], const int y[points]);
unsigned (*text_width)(void *ctx, const char *s, unsigned size);
- void *(*init)(int argc, char *const *argv);
+ void *(*init)(void);
+ bool (*args)(void *ctx, int argc, char *const *argv);
void (*sheet_name)(void *ctx, const char *name);
void (*new_sheet)(void *ctx);
void (*end)(void *ctx);
@@ -67,8 +68,8 @@ unsigned gfx_text_width(struct gfx *gfx, const char *s, unsigned size);
/* inititalization and termination */
-struct gfx *gfx_init(const struct gfx_ops *ops,
- int argc, char *const *argv);
+struct gfx *gfx_init(const struct gfx_ops *ops);
+bool gfx_args(struct gfx *gfx, int argc, char *const *argv);
void gfx_sheet_name(struct gfx *gfx, const char *name);
void gfx_new_sheet(struct gfx *gfx);
bool gfx_multi_sheet(struct gfx *gfx);