Back to index

courier  0.68.2
Functions
html.h File Reference
#include "unicode/unicode.h"
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Functions

struct htmlfilter_infohtmlfilter_alloc (void(*)(const unicode_char *, size_t, void *), void *)
void htmlfilter_free (struct htmlfilter_info *)
void htmlfilter (struct htmlfilter_info *, const unicode_char *, size_t)
void htmlfilter_set_contentbase (struct htmlfilter_info *, const char *)
void htmlfilter_set_http_prefix (struct htmlfilter_info *, const char *)
void htmlfilter_set_mailto_prefix (struct htmlfilter_info *, const char *)
void htmlfilter_set_convertcid (struct htmlfilter_info *, char *(*)(const char *, void *), void *)

Function Documentation

void htmlfilter ( struct htmlfilter_info ,
const unicode_char ,
size_t   
)

Definition at line 358 of file html.c.

{
       while (cnt)
       {
              size_t n=(*p->handler_func)(p, str, cnt);

              str += n;
              cnt -= n;
       }
}

Here is the caller graph for this function:

struct htmlfilter_info* htmlfilter_alloc ( void(*)(const unicode_char *, size_t, void *)  ,
void *   
) [read]

Definition at line 277 of file html.c.

{
       struct htmlfilter_info *p;

       p=calloc(1, sizeof(*p));
       if (!p)
              return p;

       p->output_func=output_func;
       p->output_func_arg=output_func_arg;

       unicode_buf_init(&p->atom, 2048);
       unicode_buf_init(&p->atom2, 2048);
       unicode_buf_init(&p->value, 8192);

       p->handler_func=handle_chars;
       return p;
}

Here is the call graph for this function:

Here is the caller graph for this function:

void htmlfilter_free ( struct htmlfilter_info )

Definition at line 300 of file html.c.

{
       close_elements_until(p, 0);

       free_attrs(p);

       unicode_buf_deinit(&p->atom);
       unicode_buf_deinit(&p->atom2);
       unicode_buf_deinit(&p->value);

       if (p->contentbase)
              free(p->contentbase);

       if (p->http_prefix)
              free(p->http_prefix);

       if (p->mailto_prefix)
              free(p->mailto_prefix);

       free(p);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void htmlfilter_set_contentbase ( struct htmlfilter_info ,
const char *   
)

Definition at line 322 of file html.c.

{
       if (p->contentbase)
              free(p->contentbase);

       p->contentbase=strdup(contentbase);
}

Here is the call graph for this function:

Here is the caller graph for this function:

void htmlfilter_set_convertcid ( struct htmlfilter_info ,
char *  *)(const char *, void *,
void *   
)
void htmlfilter_set_http_prefix ( struct htmlfilter_info ,
const char *   
)

Definition at line 332 of file html.c.

{
       if (p->http_prefix)
              free(p->http_prefix);

       p->http_prefix=http_prefix ? strdup(http_prefix):NULL;
}

Here is the call graph for this function:

Here is the caller graph for this function:

void htmlfilter_set_mailto_prefix ( struct htmlfilter_info ,
const char *   
)

Definition at line 341 of file html.c.

{
       if (p->mailto_prefix)
              free(p->mailto_prefix);

       p->mailto_prefix=mailto_prefix ? strdup(mailto_prefix):NULL;
}

Here is the call graph for this function:

Here is the caller graph for this function: