diff options
author | Martin Poirier <theeth@yahoo.com> | 2010-05-24 22:53:45 +0400 |
---|---|---|
committer | Martin Poirier <theeth@yahoo.com> | 2010-05-24 22:53:45 +0400 |
commit | bd15f5122dabec7cdfebb8564f3e3529f4991bba (patch) | |
tree | e6e5e482bb0eb8f1d7e40163eb2b0ac46bf65286 /source/blender/blenlib/BLI_args.h | |
parent | be44a3b7c4bf11d450172fe07c8d3484f8ae02f2 (diff) |
BLI_args cleanup
Adding documentation strings in argument data.
--help is auto generated (options not manually categorized end up in the "others" section at the bottom)
Diffstat (limited to 'source/blender/blenlib/BLI_args.h')
-rw-r--r-- | source/blender/blenlib/BLI_args.h | 14 |
1 files changed, 9 insertions, 5 deletions
diff --git a/source/blender/blenlib/BLI_args.h b/source/blender/blenlib/BLI_args.h index 5b0aa31e712..cc4d65980c9 100644 --- a/source/blender/blenlib/BLI_args.h +++ b/source/blender/blenlib/BLI_args.h @@ -41,14 +41,18 @@ typedef int (*BA_ArgCallback)(int argc, char **argv, void *data); struct bArgs *BLI_argsInit(int argc, char **argv); void BLI_argsFree(struct bArgs *ba); -/* pass starts at 1, -1 means valid all the time */ -void BLI_argsAdd(struct bArgs *ba, char *arg, int pass, BA_ArgCallback cb, void *data); -void BLI_argsAddPair(struct bArgs *ba, char *arg_short, char *arg_long, int pass, BA_ArgCallback cb, void *data); - -void BLI_argsAddCase(struct bArgs *ba, char *arg, int pass, BA_ArgCallback cb, void *data); /* not case specific */ +/* pass starts at 1, -1 means valid all the time + * short_arg or long_arg can be null to specify no short or long versions + * */ +void BLI_argsAdd(struct bArgs *ba, int pass, char *short_arg, char *long_arg, char *doc, BA_ArgCallback cb, void *data); +/* short_case and long_case specify if those arguments are case specific */ +void BLI_argsAddCase(struct bArgs *ba, int pass, char *short_arg, int short_case, char *long_arg, int long_case, char *doc, BA_ArgCallback cb, void *data); void BLI_argsParse(struct bArgs *ba, int pass, BA_ArgCallback default_cb, void *data); +void BLI_argsPrintArgDoc(struct bArgs *ba, char *arg); +void BLI_argsPrintOtherDoc(struct bArgs *ba); + void BLI_argsPrint(struct bArgs *ba); char **BLI_argsArgv(struct bArgs *ba); |