NeoMutt  2024-04-16-36-g75b6fb
Teaching an old dog new tricks
DOXYGEN
Loading...
Searching...
No Matches
render.h
Go to the documentation of this file.
1
24#ifndef MUTT_EXPANDO_RENDER_H
25#define MUTT_EXPANDO_RENDER_H
26
27#include <stdint.h>
28
29struct Buffer;
30struct ExpandoNode;
31
32typedef uint8_t MuttFormatFlags;
33#define MUTT_FORMAT_NO_FLAGS 0
34#define MUTT_FORMAT_FORCESUBJ (1 << 0)
35#define MUTT_FORMAT_TREE (1 << 1)
36#define MUTT_FORMAT_STAT_FILE (1 << 2)
37#define MUTT_FORMAT_ARROWCURSOR (1 << 3)
38#define MUTT_FORMAT_INDEX (1 << 4)
39#define MUTT_FORMAT_PLAIN (1 << 5)
40
48{
49 int did;
50 int uid;
51
65 void (*get_string)(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, int max_cols, struct Buffer *buf);
66
79 long (*get_number)(const struct ExpandoNode *node, void *data, MuttFormatFlags flags);
80};
81
82int node_tree_render(const struct ExpandoNode *node,
83 const struct ExpandoRenderData *rdata, struct Buffer *buf,
84 int max_cols, void *data, MuttFormatFlags flags);
85
86#endif /* MUTT_EXPANDO_RENDER_H */
int node_tree_render(const struct ExpandoNode *node, const struct ExpandoRenderData *rdata, struct Buffer *buf, int max_cols, void *data, MuttFormatFlags flags)
Render a tree of ExpandoNodes into a string.
Definition: render.c:45
uint8_t MuttFormatFlags
Flags for expando_render(), e.g. MUTT_FORMAT_FORCESUBJ.
Definition: render.h:32
String manipulation buffer.
Definition: buffer.h:36
Basic Expando Node.
Definition: node.h:67
void(* get_string)(const struct ExpandoNode *node, void *data, MuttFormatFlags flags, int max_cols, struct Buffer *buf)
Definition: render.h:65
long(* get_number)(const struct ExpandoNode *node, void *data, MuttFormatFlags flags)
Definition: render.h:79
int did
Domain ID.
Definition: render.h:49
int uid
Unique ID.
Definition: render.h:50