Sha256: 0f113c23a942421842d130f90d2fab835ca0f98b3e4b0d85b31e4535fc22e3ac

Contents?: true

Size: 1.83 KB

Versions: 3

Compression:

Stored size: 1.83 KB

Contents

#ifndef MTEX2MML_H
#define MTEX2MML_H

#define MTEX2MML_VERSION "1.0.0"

#ifdef __cplusplus
extern "C" {
#endif

/* Step 1. Parse a buffer with mtex source; return value is mathml, or 0 on failure (e.g., parse error).
 */
extern char * mtex2MML_parse (const char * buffer, unsigned long length);

/* Step 2. Free the string from Step 1.
 */
extern void   mtex2MML_free_string (char * str);


/* Alternatively, to filter generic source and converting embedded equations, use:
 */
extern int    mtex2MML_filter (const char * buffer, unsigned long length);

extern int    mtex2MML_html_filter (const char * buffer, unsigned long length);
extern int    mtex2MML_strict_html_filter (const char * buffer, unsigned long length);


/* To change output methods:
 *
 * Note: If length is 0, then buffer is treated like a string; otherwise only length bytes are written.
 */
extern void (*mtex2MML_write) (const char * buffer, unsigned long length); /* default writes to stdout */
extern void (*mtex2MML_write_mathml) (const char * mathml);                /* default calls mtex2MML_write(mathml,0) */
extern void (*mtex2MML_error) (const char * msg);                          /* default writes to stderr */


/* Other stuff:
 */
extern void   mtex2MML_setup (const char * buffer, unsigned long length);

extern void   mtex2MML_restart ();

extern char * mtex2MML_copy_string (const char * str);
extern char * mtex2MML_copy_string_extra (const char * str, unsigned extra);
extern char * mtex2MML_copy2 (const char * first, const char * second);
extern char * mtex2MML_copy3 (const char * first, const char * second, const char * third);
extern char * mtex2MML_copy_escaped (const char * str);

extern char * mtex2MML_empty_string;

extern int    mtex2MML_lineno;

extern int    mtex2MML_rowposn;
extern int    mtex2MML_displaymode;

#ifdef __cplusplus
}
#endif

#endif /* ! MTEX2MML_H */

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
mathematical-0.6.2 ext/mathematical/mtex2MML/src/mtex2MML.h
mathematical-0.6.1 ext/mathematical/mtex2MML/src/mtex2MML.h
mathematical-0.6.0 ext/mathematical/mtex2MML/src/mtex2MML.h