Back to index

texmacs  1.0.7.15
Defines | Typedefs | Functions
otl_opt.h File Reference
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Defines

#define OTL_OPTSTR_SEP   '+'

Typedefs

typedef struct otl_opt

Functions

otl_optotl_new_opt (void)
void otl_release_opt (otl_opt *opt)
int otl_parse_optstring (otl_opt *opt, const char *optstr)
int otl_match_optrule (otl_opt *opt, const char *tag)

Define Documentation

#define OTL_OPTSTR_SEP   '+'

Definition at line 29 of file otl_opt.h.


Typedef Documentation

typedef struct otl_opt

Definition at line 27 of file otl_opt.h.


Function Documentation

int otl_match_optrule ( otl_opt opt,
const char *  tag 
)

Definition at line 335 of file otl_opt.c.

{
  ASSERT(tag);

  if (!opt || !opt->rule)
    return 1;

  return match_expr(opt->rule, tag);
}

Here is the call graph for this function:

Here is the caller graph for this function:

otl_opt* otl_new_opt ( void  )

Definition at line 219 of file otl_opt.c.

{
  struct otl_opt *opt;

  opt = NEW(1, struct otl_opt);
  opt->rule = NULL;

  return (otl_opt *) opt;
}

Here is the caller graph for this function:

int otl_parse_optstring ( otl_opt opt,
const char *  optstr 
)

Definition at line 319 of file otl_opt.c.

{
  char  *p, *endptr;

  ASSERT(opt);

  if (optstr) {
    p      = (char *) optstr;
    endptr = p + strlen(optstr);
    opt->rule = parse_expr(&p, endptr);
  }

  return 0;
}

Here is the call graph for this function:

Here is the caller graph for this function:

void otl_release_opt ( otl_opt opt)

Definition at line 231 of file otl_opt.c.

{
  if (opt->rule) {
    bt_release_tree(opt->rule);
  }
  opt->rule = NULL;
  RELEASE(opt);
}

Here is the call graph for this function:

Here is the caller graph for this function: