Back to index

plt-scheme  4.2.1
Defines | Functions
generatedoc.c File Reference
#include <config.h>
#include <stdio.h>
#include <libit/unistd.h>
#include <libit/string.h>
#include <libit/ctype.h>
#include <wbuild.h>
#include <wsym.h>
#include <libintl.h>
#include <libit/malloc.h>

Go to the source code of this file.

Defines

#define fputS(s, f)   = fputs(get(s), f)
#define _(String)   gettext(String)
#define topen(tg)   (tag[tg][0])
#define tclose(tg)   (tag[tg][1])

Functions

static void putcode (STRING text, FILE *f, tagpair *tag)
static void print_text_par (FILE *f, tagpair *tag, STRING text, STRING file, int lineno)
static void import_file (FILE *f, tagpair *tag, Section s)
static void function (FILE *f, tagpair *tag, Section s, Section s2)
static void variable (FILE *f, tagpair *tag, Section s)
static void type (FILE *f, tagpair *tag, Section s)
static void macro (FILE *f, tagpair *tag, Section s)
static void chapter_title_intro (FILE *f, tagpair *tag, Class c)
static void public_variables_table (FILE *f, tagpair *tag, Class c)
static void public_variables (FILE *f, tagpair *tag, Class c, int shortdoc)
static void constraint_resources_table (FILE *f, tagpair *tag, Class c)
static void constraint_resources (FILE *f, tagpair *tag, Class c, int shortdoc)
static void export_declaration (FILE *f, tagpair *tag, Section s, int shortdoc)
static void exports (FILE *f, tagpair *tag, Class c, int shortdoc)
static void tabulate_inherited_resources (FILE *f, tagpair *tag, Class self, Class part)
static void summary_inherited_resources (FILE *f, tagpair *tag, Class c)
static void actions (FILE *f, tagpair *tag, Class c, int shortdoc)
static void default_translations (FILE *f, tagpair *tag, Class c)
static void imports (FILE *f, tagpair *tag, Class c)
static void private_variables (FILE *f, tagpair *tag, Class c)
static void private_constraint_variables (FILE *f, tagpair *tag, Class c)
static void private_class_variables (FILE *f, tagpair *tag, Class c)
static void utilities (FILE *f, tagpair *tag, Class c)
static void private_methods (FILE *f, tagpair *tag, Class c)
void generate_doc (FILE *f, tagpair *tag, Class c, int shortdoc)

Define Documentation

#define _ (   String)    gettext(String)

Definition at line 31 of file generatedoc.c.

#define fputS (   s,
 
)    = fputs(get(s), f)

Definition at line 20 of file generatedoc.c.

#define tclose (   tg)    (tag[tg][1])

Definition at line 49 of file generatedoc.c.

#define topen (   tg)    (tag[tg][0])

Definition at line 48 of file generatedoc.c.


Function Documentation

static void actions ( FILE *  f,
tagpair tag,
Class  c,
int  shortdoc 
) [inline, static]

Definition at line 599 of file generatedoc.c.

{
       Section s;

       if (c->actions) {
              fputs(topen(t_actions), f);
              for (s = c->actions; s; s = s->next) {
                     fputs(topen(t_section), f);
                     if (s->decl && s->decl->tp == Proc) {
                            fputs(topen(t_action), f);
                            putcode(s->decl->name, f, tag);
                            fputs(tclose(t_action), f);
                     }
                     print_text_par(f, tag, s->text, c->filename,
                            s->decl ? s->decl->lineno : -1);
                     if (!shortdoc && s->decl) {
                            switch (s->decl->tp) {
                                   case Proc:
                                          function(f, tag, s,
                                                 &action_proto);
                                          break;
                                   case Def:
                                          macro(f, tag, s);
                                          break;
                                   default: break;
                            }
                     }
              fputs(tclose(t_section), f);
              }
       fputs(tclose(t_actions), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void chapter_title_intro ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 250 of file generatedoc.c.

{
       fputs(topen(t_class), f);
       fputs(topen(t_name), f);
       putcode(c->name, f, tag);
       fputs(tclose(t_name), f);
       if (topen(t_name2)) {
              fputs(topen(t_name2), f);
              putcode(c->name, f, tag);
              fputs(tclose(t_name2), f);
       }
       print_text_par(f, tag, c->text, c->filename, c->lineno);
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void constraint_resources ( FILE *  f,
tagpair tag,
Class  c,
int  shortdoc 
) [inline, static]

Definition at line 421 of file generatedoc.c.

{
       Section s;

       if (c->constraints != NULL) {
              fputs(topen(t_constraints), f);
              constraint_resources_table(f, tag, c);
              for (s = c->constraints; s; s = s->next) {
                     fputs(topen(t_section), f);
                     if (s->decl) {
                            fputs(topen(t_constraint), f);
                            if (s->decl->namesym) {
                                   putcode(s->decl->namesym, f, tag);
                            } else {
                                   fputs("XtN", f);
                                   putcode(s->decl->name, f, tag);
                            }
                            fputs(tclose(t_constraint), f);
                     }
                     print_text_par(f, tag, s->text, c->filename, c->lineno);
                     if (!shortdoc && s->decl) {
                            /* (void) fputs(topen(t_code), f); */
                            if (s->decl->typesym) {
                                   fputs(topen(t_less), f);
                                   putcode(s->decl->typesym, f, tag);
                                   fputs(topen(t_greater), f);
                                   putc(' ', f);
                            }
                            putcode(s->decl->type, f, tag);
                            putc(' ', f);
                            putcode(s->decl->name, f, tag);
                            if (s->decl->suffix)
                                   putcode(s->decl->suffix, f, tag);
                            if (s->decl->namesym) {
                                   fputs(topen(t_less), f);
                                   putcode(s->decl->namesym, f, tag);
                                   fputs(topen(t_greater), f);
                                   putc(' ', f);
                            }
                            fputs(" = ", f);
                            if (s->decl->valuesym) {
                                   fputs(topen(t_less), f);
                                   putcode(s->decl->valuesym, f, tag);
                                   fputs(topen(t_greater), f);
                            }
                            putcode(s->decl->value, f, tag);
                            /* (void) fputs(tclose(t_code), f); */
                     }
                     fputs(tclose(t_section), f);
              }
              fputs(tclose(t_constraints), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void constraint_resources_table ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 377 of file generatedoc.c.

{
       Section s;

       fputs(topen(t_table), f);
       fputs(topen(t_tablehead), f);
       putcode(c->name, f, tag);
       fputs(tclose(t_tablehead), f);
       for (s = c->constraints; s; s = s->next) {
              if (s->decl && find_constr_class(c, s->decl->name) == c) {
                     fputs(topen(t_row), f);
                     fputs(topen(t_resname), f);
                     if (s->decl->namesym) {
                            putcode(s->decl->namesym, f, tag);
                     } else {
                            fputs("XtN", f);
                            putcode(s->decl->name, f, tag);
                     }
                     fputs(tclose(t_resname), f);
                     fputs(topen(t_resclass), f);
                     fputs("XtC", f);
                     if (s->decl->namesym)
                            putcode(get_classname(s->decl->namesym),
                                   f, tag);
                     else
                            putcode(get_classname(s->decl->name), f, tag);
                     fputs(tclose(t_resclass), f);
                     fputs(topen(t_restype), f);
                     /* (void) fputs("XtR", f); */
                     if (s->decl->typesym)
                            putcode(s->decl->typesym, f, tag);
                     else
                            putcode(s->decl->type, f, tag);
                     fputs(tclose(t_restype), f);
                     fputs(topen(t_resdefault), f);
                     putcode(s->decl->value, f, tag);
                     fputs(tclose(t_resdefault), f);
                     fputs(tclose(t_row), f);
              }
       }
       fputs(tclose(t_table), f);
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void default_translations ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 632 of file generatedoc.c.

{
       Section s;

       if (c->translations) {
              fputs(topen(t_translations), f);
              for (s = c->translations; s; s = s->next) {
                     fputs(topen(t_section), f);
                     print_text_par(f, tag, s->text, c->filename,
                            s->decl ? s->decl->lineno : -1);
                     if (s->decl) {
                            fputs(topen(t_code), f);
                            putcode(s->decl->type, f, tag);
                            fputs(": ", f);
                            putcode(s->decl->value, f, tag);
                            fputs(tclose(t_code), f);
                     }
                     fputs(tclose(t_section), f);
              }
              fputs(tclose(t_translations), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void export_declaration ( FILE *  f,
tagpair tag,
Section  s,
int  shortdoc 
) [inline, static]

Definition at line 478 of file generatedoc.c.

{
       Decl d1;

       switch (s->decl->tp) {
              case Proc:
                     fputs(topen(t_code), f);
                     putcode(s->decl->type, f, tag);
                     if (s->decl->type)
                            putc(' ', f);
                     putcode(s->decl->name, f, tag);
                     if (s->decl->suffix)
                            putcode(s->decl->suffix, f, tag);
                     if (s->decl->params) {
                            putc('(', f);
                            for (d1 = s->decl->params; d1; d1 = d1->next) {
                                   putcode(d1->type, f, tag);
                                   putc(' ', f);
                                   putcode(d1->name, f, tag);
                                   if (d1->suffix)
                                          putcode(d1->suffix, f, tag);
                                   if (d1->next)
                                          fputs(", ", f);
                            }
                            putc(')', f);
                     }
                     fputs(tclose(t_code), f);
                     if (!shortdoc)
                            putcode(s->decl->body, f, tag);
                     break;
              case Var: variable(f, tag, s); break;
              case Type: type(f, tag, s); break;
              case Def: macro(f, tag, s); break;
              case Incl: import_file(f, tag, s); break;
              default: ; /* Cannot happen! */
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void exports ( FILE *  f,
tagpair tag,
Class  c,
int  shortdoc 
) [inline, static]

Definition at line 517 of file generatedoc.c.

{
       Section s;

       if (c->exports != NULL) {
              fputs(topen(t_exports), f);
              for (s = c->exports; s; s = s->next) {
                     fputs(topen(t_section), f);
                     print_text_par(f, tag, s->text, c->filename,
                            s->decl ? s->decl->lineno : -1);
                     if (s->decl) {
                            export_declaration(f, tag, s, shortdoc);
                     }
                     fputs(tclose(t_section), f);
              }
              fputs(tclose(t_exports), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void function ( FILE *  f,
tagpair tag,
Section  s,
Section  s2 
) [inline, static]

Definition at line 172 of file generatedoc.c.

{
       Decl d1;

       fputs(topen(t_code), f);
       if (s2->decl->type) {
              putcode(s2->decl->type, f, tag);
              putc(' ', f);
       }
       putcode(s->decl->name, f, tag);
       putc('(', f);
       if (s2->decl->params) {
              for (d1 = s2->decl->params; d1; d1 = d1->next) {
                     if (d1->type) {
                            putcode(d1->type, f, tag);
                            putc(' ', f);
                     }
                     putcode(d1->name, f, tag);
                     if (d1->suffix)
                            putcode(d1->suffix, f, tag);
                     if (d1->next)
                            fputs(", ", f);
              }
       }
       putc(')', f);
       putc('\n', f);
       if (s->decl->body)
              putcode(s->decl->body, f, tag);
       fputs(tclose(t_code), f);
}

Here is the call graph for this function:

void generate_doc ( FILE *  f,
tagpair tag,
Class  c,
int  shortdoc 
)

Definition at line 810 of file generatedoc.c.

{
       fputs(topen(t_start), f);
       chapter_title_intro(f, tag, c);
       public_variables(f, tag, c, shortdoc);
       summary_inherited_resources(f, tag, c);
       constraint_resources(f, tag, c, shortdoc);
       exports(f, tag, c, shortdoc);
       default_translations(f, tag, c);
       actions(f, tag, c, shortdoc);
       if (!shortdoc) {
              imports(f, tag, c);
              private_variables(f, tag, c);
              private_constraint_variables(f, tag, c);
              private_class_variables(f, tag, c);
              private_methods(f, tag, c);
              utilities(f, tag, c);
       }
       fputs(tclose(t_start), f);
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void import_file ( FILE *  f,
tagpair tag,
Section  s 
) [inline, static]

Definition at line 157 of file generatedoc.c.

{
       fputs(topen(t_code), f);
       fputs(topen(t_incl), f);
       putc(' ', f);
       putcode(s->decl->name, f, tag);
       fputs(tclose(t_code), f);
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void imports ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 655 of file generatedoc.c.

{
       Section s;
       if (c->imports) {
              fputs(topen(t_imports), f);
              for (s = c->imports; s; s = s->next) {
                     fputs(topen(t_section), f);
                     print_text_par(f, tag, s->text, c->filename,
                            s->decl ? s->decl->lineno : -1);
                     if (s->decl) {
                            switch (s->decl->tp) {
                                   case Proc:
                                          function(f, tag, s, s);
                                          break;
                                   case Var:
                                          variable(f, tag, s);
                                          break;
                                   case Incl:
                                          import_file(f, tag, s);
                                          break;
                                   default: ; /* Cannot happen! */
                            }
                     }
                     fputs(tclose(t_section), f);
              }
              fputs(tclose(t_imports), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void macro ( FILE *  f,
tagpair tag,
Section  s 
) [inline, static]

Definition at line 230 of file generatedoc.c.

{
       Decl d1;

       fputs(topen(t_macro), f);
       putcode(s->decl->name, f, tag);
       if (s->decl->params) {
              putc('(', f);
              for (d1 = s->decl->params; d1; d1 = d1->next) {
                     putcode(d1->name, f, tag);
                     if (d1->next)
                            fputs(", ", f);
              }
              fputs(") =\n", f);
       } else {
              fputs(" = ", f);
       }
       putcode(s->decl->body, f, tag);
       fputs(tclose(t_macro), f);
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void print_text_par ( FILE *  f,
tagpair tag,
STRING  text,
STRING  file,
int  lineno 
) [static]

Definition at line 112 of file generatedoc.c.

{
       char *p;
       int between_bars;

       if (!text)
              return;
       between_bars = 0;
       for (p = get(text); *p; p++) {
              if (between_bars) {
                     switch (*p) {
                            case '_': fputs(topen(t_underline), f); break;
                            case '\\': fputs(topen(t_backslash), f); break;
                            case '~': fputs(topen(t_tilde), f); break;
                            case '#': fputs(topen(t_hashmark), f); break;
                            case '$': fputs(topen(t_dollar), f); break;
                            case '%': fputs(topen(t_percent), f); break;
                            case '^': fputs(topen(t_caret), f); break;
                            case '&': fputs(topen(t_ampersand), f); break;
                            case '{': fputs(topen(t_lbrace), f); break;
                            case '}': fputs(topen(t_rbrace), f); break;
                            case '@': fputs(topen(t_at), f); break;
                            case '|':
                                   fputs(tclose(t_inline), f);
                                   between_bars = 0;
                                   break;
                            default: putc(*p, f);
                     }
              } else if (*p == '|') {
                     between_bars = 1;
                     fputs(topen(t_inline), f);
              } else {
                     putc(*p, f);
              }
       }
       if (between_bars) {
              fprintf(stderr, _("%s:%d: unmatched \"|\" in text\n"),
                     get(file), lineno);
              nerrors++;
              fputs(tclose(t_inline), f); /* make TeX happy */
       }
       putc('\n', f); (void) putc('\n', f);
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void private_class_variables ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 735 of file generatedoc.c.

{
       Section s;

       if (c->classvars != NULL) {
              fputs(topen(t_classvars), f);
              for (s = c->classvars; s; s = s->next) {
                     fputs(topen(t_section), f);
                     print_text_par(f, tag, s->text, c->filename,
                            s->decl ? s->decl->lineno : -1);
                     if (s->decl)
                            variable(f, tag, s);
                     fputs(tclose(t_section), f);
              }
              fputs(tclose(t_classvars), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void private_constraint_variables ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 710 of file generatedoc.c.

{
       Section s;

       if (c->privconstr) {
              fputs(topen(t_privconstraints), f);
              for (s = c->privconstr; s; s = s->next) {
                     fputs(topen(t_section), f);
                     print_text_par(f, tag, s->text, c->filename,
                            s->decl ? s->decl->lineno : -1);
                     if (s->decl) {
                            fputs(topen(t_code), f);
                            putcode(s->decl->type, f, tag);
                            putc(' ', f);
                            putcode(s->decl->name, f, tag);
                            if (s->decl->suffix)
                                   putcode(s->decl->suffix, f, tag);
                            fputs(tclose(t_code), f);
                     }
                     fputs(tclose(t_section), f);
              }
              fputs(tclose(t_privconstraints), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void private_methods ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 780 of file generatedoc.c.

{
       Section s, s2;

       if (c->methods) {
              fputs(topen(t_methods), f);
              for (s = c->methods; s; s = s->next) {
                     fputs(topen(t_section), f);
                     print_text_par(f, tag, s->text, c->filename,
                            s->decl ? s->decl->lineno : -1);
                     if (s->decl) {
                            switch (s->decl->tp) {
                                   case Proc:
                                          s2 = find_method(c,
                                                 s->decl->name);
                                          function(f, tag, s, s2);
                                          break;
                                   case Def:
                                          macro(f, tag, s);
                                          break;
                                   default:
                                     break;
                            }
                     }
                     fputs(tclose(t_section), f);
              }
              fputs(tclose(t_methods), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void private_variables ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 685 of file generatedoc.c.

{
       Section s;

       if (c->privatevars) {
              fputs(topen(t_privatevars), f);
              for (s = c->privatevars; s; s = s->next) {
                     fputs(topen(t_section), f);
                     print_text_par(f, tag, s->text, c->filename,
                            s->decl ? s->decl->lineno : -1);
                     if (s->decl) {
                            fputs(topen(t_code), f);
                            putcode(s->decl->type, f, tag);
                            putc(' ', f);
                            putcode(s->decl->name, f, tag);
                            if (s->decl->suffix)
                                   putcode(s->decl->suffix, f, tag);
                            fputs(tclose(t_code), f);
                     }
                     fputs(tclose(t_section), f);
              }
              fputs(tclose(t_privatevars), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void public_variables ( FILE *  f,
tagpair tag,
Class  c,
int  shortdoc 
) [inline, static]

Definition at line 322 of file generatedoc.c.

{
       Section s;

       if (c->publicvars != NULL) {
              fputs(topen(t_publicvars), f);
              public_variables_table(f, tag, c);
              for (s = c->publicvars; s; s = s->next) {
                     fputs(topen(t_section), f);
                     if (s->decl) {
                            fputs(topen(t_publicvar), f);
                            if (s->decl->namesym) {
                                   putcode(s->decl->namesym, f, tag);
                            } else {
                                   fputs("XtN", f);
                                   putcode(s->decl->name, f, tag);
                            }
                            fputs(tclose(t_publicvar), f);
                     }
                     print_text_par(f, tag, s->text, c->filename, c->lineno);
                     if (!shortdoc && s->decl) {
                            /* (void) fputs(topen(t_code), f); */
                            if (s->decl->typesym) {
                                   fputs(topen(t_less), f);
                                   putcode(s->decl->typesym, f, tag);
                                   fputs(topen(t_greater), f);
                                   putc(' ', f);
                            }
                            putcode(s->decl->type, f, tag);
                            putc(' ', f);
                            putcode(s->decl->name, f, tag);
                            if (s->decl->suffix)
                                   putcode(s->decl->suffix, f, tag);
                            if (s->decl->namesym) {
                                   fputs(topen(t_less), f);
                                   putcode(s->decl->namesym, f, tag);
                                   fputs(topen(t_greater), f);
                                   putc(' ', f);
                            }
                            fputs(" = ", f);
                            if (s->decl->valuesym) {
                                   fputs(topen(t_less), f);
                                   putcode(s->decl->valuesym, f, tag);
                                   fputs(topen(t_greater), f);
                            }
                            putcode(s->decl->value, f, tag);
                            /* (void) fputs(tclose(t_code), f); */
                     }
                     fputs(tclose(t_section), f);
              }
              fputs(tclose(t_publicvars), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void public_variables_table ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 271 of file generatedoc.c.

{
       Section s;

       fputs(topen(t_table), f);
       fputs(topen(t_tablehead), f);
       putcode(c->name, f, tag);
       fputs(tclose(t_tablehead), f);
       for (s = c->publicvars; s; s = s->next) {
              if (s->decl && find_instvar_class(c, s->decl->name) == c) {
                     fputs(topen(t_row), f);
                     fputs(topen(t_resname), f);
                     if (s->decl->namesym) {
                            putcode(s->decl->namesym, f, tag);
                     } else {
                            fputs("XtN", f);
                            putcode(s->decl->name, f, tag);
                     }
                     fputs(tclose(t_resname), f);
                     fputs(topen(t_resclass), f);
                     fputs("XtC", f);
                     if (s->decl->namesym)
                            putcode(get_classname(s->decl->namesym),
                                   f, tag);
                     else
                            putcode(get_classname(s->decl->name), f, tag);
                     fputs(tclose(t_resclass), f);
                     fputs(topen(t_restype), f);
                     /* (void) fputs("XtR", f); */
                     if (s->decl->typesym)
                            putcode(s->decl->typesym, f, tag);
                     else
                            putcode(s->decl->type, f, tag);
                     fputs(tclose(t_restype), f);
                     fputs(topen(t_resdefault), f);
                     putcode(s->decl->value, f, tag);
                     fputs(tclose(t_resdefault), f);
                     fputs(tclose(t_row), f);
              }
       }
       fputs(tclose(t_table), f);
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void putcode ( STRING  text,
FILE *  f,
tagpair tag 
) [static]

Definition at line 55 of file generatedoc.c.

{
       char *p;
       int col = 0;
       if (text) {
              for (p = get(text); *p; p++) {
                     switch (*p) {
                            case '_': fputs(topen(t_underline), f);
                                   col++; break;
                            case '\\': fputs(topen(t_backslash), f);
                                   col++; break;
                            case '~': fputs(topen(t_tilde), f);
                                   col++; break;
                            case '#': fputs(topen(t_hashmark), f);
                                   col++; break;
                            case '$': fputs(topen(t_dollar), f);
                                   col++; break;
                            case '%': fputs(topen(t_percent), f);
                                   col++; break;
                            case '^': fputs(topen(t_caret), f);
                                   col++; break;
                            case '<': fputs(topen(t_less), f);
                                   col++; break;
                            case '>': fputs(topen(t_greater), f);
                                   col++; break;
                            case '&': fputs(topen(t_ampersand), f);
                                   col++; break;
                            case '{': fputs(topen(t_lbrace), f);
                                   col++; break;
                            case '}': fputs(topen(t_rbrace), f);
                                   col++; break;
                            case '|': fputs(topen(t_bar), f);
                                   col++; break;
                            case '@': fputs(topen(t_at), f);
                                   col++; break;
                            case '\n': putc('\n', f);
                                   col = 0; break;
                            case '\t':
                                   do {
                                          putc(' ', f);
                                   } while (++col % 8 != 0);
                                   break;
                            default: putc(*p, f); col++;
                     }
              }
       }
}

Here is the caller graph for this function:

static void summary_inherited_resources ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 592 of file generatedoc.c.

{
       if (c->superclass)
              tabulate_inherited_resources(f, tag, c, c->super);
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void tabulate_inherited_resources ( FILE *  f,
tagpair tag,
Class  self,
Class  part 
) [static]

Definition at line 541 of file generatedoc.c.

{
       Section s;
       if (!part)
              return;
       if (part->publicvars) {
              fputs(topen(t_table), f);
              fputs(topen(t_tablehead), f);
              putcode(part->name, f, tag);
              fputs(tclose(t_tablehead), f);
              for (s = part->publicvars; s; s = s->next) {
                     if (s->decl && (find_instvar_class(part, s->decl->name)
                                   == part)) {
                            fputs(topen(t_row), f);
                            fputs(topen(t_resname), f);
                            if (s->decl->namesym) {
                                   putcode(s->decl->namesym, f, tag);
                            } else {
                                   fputs("XtN", f);
                                   putcode(s->decl->name, f, tag);
                            }
                            fputs(tclose(t_resname), f);
                            fputs(topen(t_resclass), f);
                            fputs("XtC", f);
                            if (s->decl->namesym)
                                   putcode(get_classname(s->decl->namesym),
                                          f, tag);
                            else
                                   putcode(get_classname(s->decl->name),
                                          f, tag);
                            fputs(tclose(t_resclass), f);
                            fputs(topen(t_restype), f);
                            /* (void) fputs("XtR", f); */
                            if (s->decl->typesym)
                                   putcode(s->decl->typesym, f, tag);
                            else
                                   putcode(get_classname(s->decl->type),
                                          f, tag);
                            fputs(tclose(t_restype), f);
                            fputs(topen(t_resdefault), f);
                            putcode(s->decl->value, f, tag);
                            fputs(tclose(t_resdefault), f);
                            fputs(tclose(t_row), f);
                     }
              }
              fputs(tclose(t_table), f);
       }
       tabulate_inherited_resources(f, tag, self, part->super);
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void type ( FILE *  f,
tagpair tag,
Section  s 
) [inline, static]

Definition at line 219 of file generatedoc.c.

{
       fputs(topen(t_code), f);
       fputs(topen(t_type), f);
       putc(' ', f);
       putcode(s->decl->name, f, tag);
       fputs(" = ", f);
       putcode(s->decl->type, f, tag);
       fputs(tclose(t_code), f);
}

Here is the call graph for this function:

static void utilities ( FILE *  f,
tagpair tag,
Class  c 
) [inline, static]

Definition at line 753 of file generatedoc.c.

{
       Section s;

       if (c->utilities) {
              fputs(topen(t_utilities), f);
              for (s = c->utilities; s; s = s->next) {
                     fputs(topen(t_section), f);
                     print_text_par(f, tag, s->text, c->filename,
                            s->decl ? s->decl->lineno : -1);
                     if (s->decl) {
                            switch (s->decl->tp) {
                                   case Proc: function(f, tag, s, s);
                                          break;
                                   case Var: variable(f, tag, s); break;
                                   case Type: type(f, tag, s); break;
                                   case Def: macro(f, tag, s); break;
                                   default: ; /* Cannot happen! */
                            }
                     }
                     fputs(tclose(t_section), f);
              }
              fputs(tclose(t_utilities), f);
       }
}

Here is the call graph for this function:

Here is the caller graph for this function:

static void variable ( FILE *  f,
tagpair tag,
Section  s 
) [inline, static]

Definition at line 203 of file generatedoc.c.

{
       fputs(topen(t_code), f);
       putcode(s->decl->type, f, tag);
       if (s->decl->type)
              putc(' ', f);
       putcode(s->decl->name, f, tag);
       if (s->decl->suffix)
              putcode(s->decl->suffix, f, tag);
       if (s->decl->value) {
              fputs(" = ", f);
              putcode(s->decl->value, f, tag);
       }
       fputs(tclose(t_code), f);
}

Here is the call graph for this function:

Here is the caller graph for this function: