Lines Matching refs:opt

124   { "short-opt-col",  0, offsetof (struct uparams, short_opt_col) },
125 { "long-opt-col", 0, offsetof (struct uparams, long_opt_col) },
126 { "doc-opt-col", 0, offsetof (struct uparams, doc_opt_col) },
127 { "opt-doc-col", 0, offsetof (struct uparams, opt_doc_col) },
259 #define ovisible(opt) (! ((opt)->flags & OPTION_HIDDEN))
262 #define oalias(opt) ((opt)->flags & OPTION_ALIAS)
265 #define odoc(opt) ((opt)->flags & OPTION_DOC)
268 #define onotrans(opt) ((opt)->flags & OPTION_NO_TRANS)
271 #define oend(opt) __option_is_end (opt)
274 #define oshort(opt) __option_is_short (opt)
360 const struct argp_option *opt;
479 entry->opt = o;
558 int (*func)(const struct argp_option *opt,
565 const struct argp_option *opt, *real = entry->opt;
568 for (opt = real, nopts = entry->num; nopts > 0 && !val; opt++, nopts--)
569 if (oshort (opt) && *so == opt->key)
571 if (!oalias (opt))
572 real = opt;
573 if (ovisible (opt))
574 val = (*func)(opt, real, domain, cookie);
584 int (*func)(const struct argp_option *opt,
591 const struct argp_option *opt, *real = entry->opt;
593 for (opt = real, nopts = entry->num; nopts > 0 && !val; opt++, nopts--)
594 if (opt->name)
596 if (!oalias (opt))
597 real = opt;
598 if (ovisible (opt))
599 val = (*func)(opt, real, domain, cookie);
608 until_short (const struct argp_option *opt, const struct argp_option *real,
611 return oshort (opt) ? opt->key : 0;
626 const struct argp_option *opt;
628 for (opt = entry->opt, num = entry->num; num > 0; opt++, num--)
629 if (opt->name && ovisible (opt))
630 return opt->name;
644 const struct argp_option *opt = entry->opt;
648 if (opt->name && ovisible (opt) && strcmp (opt->name, name) == 0)
651 opt++;
788 int doc1 = odoc (entry1->opt);
789 int doc2 = odoc (entry2->opt);
915 const struct argp_option *opt;
919 for (opts_left = e->num, opt = e->opt; opts_left; opt++, opts_left--)
922 if (oshort (opt) && ch == opt->key)
1117 const struct argp_option *real = entry->opt, *opt;
1134 for (opt = real, num = entry->num; num > 0; opt++, num--)
1135 if (opt->name && ovisible (opt))
1143 for (opt = real, num = entry->num; num > 0; opt++, num--)
1144 if (oshort (opt) && opt->key == *so)
1147 if (ovisible (opt))
1165 for (opt = real, num = entry->num; num > 0; opt++, num--)
1166 if (opt->name && *opt->name && ovisible (opt))
1173 onotrans (opt) ?
1174 opt->name :
1176 opt->name));
1185 for (opt = real, num = entry->num; num > 0; opt++, num--)
1186 if (opt->name && ovisible (opt))
1189 __argp_fmtstream_printf (stream, "--%s", opt->name);
1284 add_argless_short_opt (const struct argp_option *opt,
1289 if (!(opt->arg || real->arg)
1290 && !((opt->flags | real->flags) & OPTION_NO_USAGE))
1291 *(*snao_end)++ = opt->key;
1298 usage_argful_short_opt (const struct argp_option *opt,
1303 const char *arg = opt->arg;
1304 int flags = opt->flags | real->flags;
1314 __argp_fmtstream_printf (stream, " [-%c[%s]]", opt->key, arg);
1320 __argp_fmtstream_printf (stream, "[-%c %s]", opt->key, arg);
1327 /* Output a usage entry for the long option opt to the stream pointed at by
1330 usage_long_opt (const struct argp_option *opt,
1335 const char *arg = opt->arg;
1336 int flags = opt->flags | real->flags;
1341 if (! (flags & OPTION_NO_USAGE) && !odoc (opt))
1347 __argp_fmtstream_printf (stream, " [--%s[=%s]]", opt->name, arg);
1349 __argp_fmtstream_printf (stream, " [--%s=%s]", opt->name, arg);
1352 __argp_fmtstream_printf (stream, " [--%s]", opt->name);