14#include "ws_symbol_export.h"
23#define TAGRULES_FILE_NAME "tagrules.jsonc"
102 const char *tag_content,
104 const char *comment);
Display preferences for the tagging subsystem.
Definition tag_rules.h:44
tag_link_click_mode_t link_click
Definition tag_rules.h:47
char separator
Definition tag_rules.h:45
int emoji_size
Definition tag_rules.h:46
Data for a single tagging rule.
Definition tag_rules.h:53
The compiled display filter object passed back to the user.
Definition dfilter-int.h:46
Holds all state for the dissection of a single byte array, including session, buffer,...
Definition epan_dissect.h:28
WS_DLL_PUBLIC bool tag_rules_write_path(GSList *list, const char *path, const tag_prefs_t *prefs, char **err_msg)
Write a rule list to an arbitrary file path.
Definition tag_rules.c:443
WS_DLL_PUBLIC tag_rule_t * tag_rule_new(const char *name, const char *filter, const char *tag_content, const char *tag_url, const char *comment)
Create a new tag rule (g_new0-allocated).
Definition tag_rules.c:85
tag_link_click_mode_t
Controls how a tag link is activated in the packet list.
Definition tag_rules.h:32
@ TAG_LINK_CLICK_NONE
Definition tag_rules.h:35
@ TAG_LINK_CLICK_SINGLE
Definition tag_rules.h:33
@ TAG_LINK_CLICK_CTRL
Definition tag_rules.h:34
WS_DLL_PUBLIC tag_prefs_t tag_rules_get_prefs(void)
Get the current display preferences.
Definition tag_rules.c:62
WS_DLL_PUBLIC void tag_rule_delete(tag_rule_t *rule)
Delete a single tag rule and free all its memory.
Definition tag_rules.c:103
WS_DLL_PUBLIC GSList * tag_rules_read_path(const char *path, char **err_msg)
Read tag rules from a file into a new GSList without touching the active list.
Definition tag_rules.c:419
struct _tag_rule tag_rule_t
Data for a single tagging rule.
WS_DLL_PUBLIC const GSList * tag_rules_get_list(void)
Return the currently active tag rule list.
Definition tag_rules.c:530
WS_DLL_PUBLIC bool tag_rules_export_list(GSList *list, const char *path, char **err_msg)
Write an arbitrary tag rule GSList to a file without touching the active list.
Definition tag_rules.c:537
WS_DLL_PUBLIC void tag_rules_set_prefs(const tag_prefs_t *prefs)
Set the display preferences (does not write to disk).
Definition tag_rules.c:74
WS_DLL_PUBLIC void tag_rules_prime_edt(struct epan_dissect *edt)
Prime an epan_dissect_t with all compiled tag rule filters.
Definition tag_rules.c:558
WS_DLL_PUBLIC void tag_rule_list_free(GSList *list)
Free a GSList of tag_rule_t* (e.g. one built by the model for export).
Definition tag_rules.c:552
struct _tag_prefs tag_prefs_t
Display preferences for the tagging subsystem.
WS_DLL_PUBLIC void tag_rules_clone(tag_rule_add_cb_func cb, void *user_data)
Clone the currently active tag rule list.
Definition tag_rules.c:487
WS_DLL_PUBLIC void tag_rules_apply(GSList *new_list)
Apply a new tag rule list (called when the dialog OK is pressed).
Definition tag_rules.c:503
void(* tag_rule_add_cb_func)(tag_rule_t *rule, void *user_data)
A tag rule was added (while importing or cloning). (tag_rules.c calls this for every rule coming in).
Definition tag_rules.h:69
WS_DLL_PUBLIC bool tag_rules_write(void)
Write tag rules to the active profile's tagrules.jsonc file.
Definition tag_rules.c:459
WS_DLL_PUBLIC void tag_rules_init(void)
Initialize the tag rules subsystem (read from file).
Definition tag_rules.c:400
WS_DLL_PUBLIC bool tag_rules_used(void)
Definition tag_rules.c:68
WS_DLL_PUBLIC void tag_rules_reload(void)
Reload the tag rules from disk.
Definition tag_rules.c:413