GFXprim
2D bitmap graphics library with emphasis on speed and correctness
|
A markup parsers. More...
#include <utils/gp_markup.h>
Go to the source code of this file.
Enumerations | |
enum | gp_markup_fmt { GP_MARKUP_PLAINTEXT , GP_MARKUP_GFXPRIM , GP_MARKUP_HTML } |
Markup format to parse. More... | |
enum | gp_markup_html_flags { GP_MARKUP_HTML_KEEP_WS = 0x01 } |
Functions | |
gp_markup * | gp_markup_parse (enum gp_markup_fmt fmt, const char *markup, enum gp_markup_flags flags) |
Parsers a markup string. | |
gp_markup * | gp_markup_plaintext_parse (const char *markup, enum gp_markup_flags flags) |
Parses a plaintext markup. | |
gp_markup * | gp_markup_gfxprim_parse (const char *markup, enum gp_markup_flags flags) |
Parses a gfxprim markup. | |
gp_markup * | gp_markup_html_parse (const char *markup, enum gp_markup_flags flags) |
Parses a HTML markup. | |
void | gp_markup_free (gp_markup *self) |
Frees a markup. | |
A markup parsers.
Definition in file gp_markup_parser.h.
enum gp_markup_fmt |
Markup format to parse.
Enumerator | |
---|---|
GP_MARKUP_PLAINTEXT | An UTF-8 text without any formatting |
GP_MARKUP_GFXPRIM | A GFXprim markup |
GP_MARKUP_HTML | A small subset of HTML |
Definition at line 19 of file gp_markup_parser.h.
enum gp_markup_html_flags |
HTML parser markup flags.
Enumerator | |
---|---|
GP_MARKUP_HTML_KEEP_WS | Keep whitespaces Some HTML like markup languages only use tags for text size/color and expect whitespaces to be kept, such as Pango markup or XDXF. |
Definition at line 65 of file gp_markup_parser.h.
void gp_markup_free | ( | gp_markup * | self | ) |
Frees a markup.
markup | A parsed markup. |
gp_markup * gp_markup_gfxprim_parse | ( | const char * | markup, |
enum gp_markup_flags | flags | ||
) |
Parses a gfxprim markup.
markup | A string with a markup. |
flags | Flags passed to markup parser. |
gp_markup * gp_markup_html_parse | ( | const char * | markup, |
enum gp_markup_flags | flags | ||
) |
Parses a HTML markup.
markup | A string with a markup. |
flags | A flags passed to markup parser. |
gp_markup * gp_markup_parse | ( | enum gp_markup_fmt | fmt, |
const char * | markup, | ||
enum gp_markup_flags | flags | ||
) |
Parsers a markup string.
fmt | A markup format. |
markup | A string with a markup. |
flags | A flags passed to markup parser. |
gp_markup * gp_markup_plaintext_parse | ( | const char * | markup, |
enum gp_markup_flags | flags | ||
) |
Parses a plaintext markup.
markup | A string with a markup. |
flags | Flags passed to markup parser. |