-
Notifications
You must be signed in to change notification settings - Fork 29
/
lglopts.h
39 lines (26 loc) · 884 Bytes
/
lglopts.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
#ifndef lglopts_h_INCLUDED
#define lglopts_h_INCLUDED
#include "lglconst.h"
/*------------------------------------------------------------------------*/
typedef struct Opt {
const char * lng, * descrp;
int val, min, max, dflt;
} Opt;
/*------------------------------------------------------------------------*/
#ifdef OPT
#undef OPT
#endif
#define OPT(LNG,VAL,MIN,MAX,DESCRP) Opt LNG
typedef struct Opts {
Opt beforefirst;
#include "lgloptl.h"
Opt afterlast;
} Opts;
struct LGL;
/*------------------------------------------------------------------------*/
#define FIRSTOPT(lgl) (&(lgl)->opts->beforefirst + 1)
#define LASTOPT(lgl) (&(lgl)->opts->afterlast - 1)
/*------------------------------------------------------------------------*/
void lglinitopts (struct LGL *, Opts *);
/*------------------------------------------------------------------------*/
#endif