aboutsummaryrefslogtreecommitdiffstats
path: root/color_filters.h
diff options
context:
space:
mode:
authorSake Blok <sake@euronet.nl>2007-11-24 11:38:16 +0000
committerSake Blok <sake@euronet.nl>2007-11-24 11:38:16 +0000
commit9b6f806089352b60a724767a47391d6854f99c6a (patch)
tree0944b3a1a037c65b5da06485b6aeb5312073d56e /color_filters.h
parent5018f190e547853a684fb6a2bbcf4d00fb3e9264 (diff)
This patch adds (ten) temporary coloring rules which will only live until Wireshark is
quit. Temporary coloring filters can be set by: - pressing <ctrl>-<digit> will create a conversation coloring filter based on the addresses of the currently selected packet (order TCP/UDP/IP/Ethernet) This can also be achieved from the "View|Colorize Conversation" menu. - Rightclicking on a packet in the packet-list will give the option to "Colorize Conversation" just as "Conversation Filter" does. - Rightclicking on an item in the packet-detail-list will give the option to "Colorize with filter" which works similar to "Apply as filter" Temporary filters can be cleared from the same menus or by pressing <ctrl>-<space>. This patch also adds an item to the above mentioned menu's to add a permanent color filter in the same way. The colors for the temporary coloring rules are now hardcoded as I do not know how to change the color of menu-items and therefore I chose to use icons to show the actual color of each of the ten temporary coloring rules. Is it at all possible to have different menu items in different colors? One other way of solving this is to recreate the icons on the fly after changing the colors. I will have a look into that once it is clear whether I can use different colors within the menu structure. svn path=/trunk/; revision=23560
Diffstat (limited to 'color_filters.h')
-rw-r--r--color_filters.h9
1 files changed, 8 insertions, 1 deletions
diff --git a/color_filters.h b/color_filters.h
index 056115df17..e0851ac531 100644
--- a/color_filters.h
+++ b/color_filters.h
@@ -24,6 +24,7 @@
#ifndef __COLOR_FILTERS_H__
#define __COLOR_FILTERS_H__
+#define TEMP_COLOR_PREFIX "___tmp_color_filter___"
/** @file
* Color filters.
*/
@@ -65,7 +66,13 @@ gboolean color_filters_used(void);
void
color_filters_enable(gboolean enable);
-
+/** Set the filter string of a temporary color filter
+ *
+ * @param filt_nr a number 1-10 pointing to a temporary color
+ * @param filter the new filter-string
+ */
+void
+color_filters_set_tmp(guint8 filt_nr, gchar *filter);
/* Prime the epan_dissect_t with all the compiler
* color filters of the current filter list.