Skip to content

Commit

Permalink
From Richard Urwin a great enhancement to the color filter dialogue to
Browse files Browse the repository at this point in the history
make it possible to import/export color filters

svn path=/trunk/; revision=8188
  • Loading branch information
Ronnie Sahlberg committed Aug 18, 2003
1 parent 7e212dd commit 710f08b
Show file tree
Hide file tree
Showing 9 changed files with 865 additions and 203 deletions.
5 changes: 3 additions & 2 deletions AUTHORS
Original file line number Diff line number Diff line change
Expand Up @@ -1422,9 +1422,10 @@ Liviu Daia <Liviu.Daia[AT]imar.ro> {
from the command line
}

Richard Urwin <rurwin[AT]schenck.co.uk> {
Richard Urwin <richard[AT]soronlin.org.uk> {
Developer documentation fixes and updates
Support for a system-wide color filter file
Support for a system-wide color filter file and color filter
import and export
}

Prabhakar Krishnan <Prabhakar.Krishnan[AT]netapp.com> {
Expand Down
3 changes: 2 additions & 1 deletion color.h
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/* color.h
* Definitions for "toolkit-independent" colors
*
* $Id: color.h,v 1.3 2002/09/23 19:09:47 oabad Exp $
* $Id: color.h,v 1.4 2003/08/18 21:27:07 sahlberg Exp $
*
* Ethereal - Network traffic analyzer
* By Gerald Combs <gerald@zing.org>
Expand Down Expand Up @@ -53,6 +53,7 @@ typedef struct _color_filter {
dfilter_t *c_colorfilter; /* compiled filter expression */
void *edit_dialog; /* if filter is being edited, dialog
* box for it */
gboolean marked; /* set if the filter is marked in the color dialog box */
} color_filter_t;

/* List of all color filters. */
Expand Down
83 changes: 83 additions & 0 deletions doc/ethereal.pod.template
Original file line number Diff line number Diff line change
Expand Up @@ -551,6 +551,89 @@ ignored. Therefore, if you are filtering on the existence of protocols,
you should list the higher-level protocols first, and the lower-level
protocols last.

How Colorization Works
----------------------
Packets are colored according to a list of color filters. Each filter
consists of a name, a filter expression and a coloration. A packet is
colored according to the first filter that it matches, Color filter
expressions use exactly the same syntax as display filter expressions.

When Ethereal starts the color filters are loaded from:
1. The user's personal colorfilters file or, if that does not exist,
2. The global colorfilters file.
If neither of these exist then the packets will not be colored.

The Color Filters Dialog
------------------------
This dialog displays a list of color filters and allows it to be
modified.

THE FILTER LIST
Single rows may be selected by clicking. Multiple rows may be selected
by using the ctrl and shift keys in combination with the mouse button.

UP
Moves the selected filter(s) up the list, making it more likely that
they will be used to color packets.

DOWN
Moves the selected filter(s) down the list, making it less likely that
they will be used to color packets.

NEW
Adds a new filter at the bottom of the list and opens the Edit Color
Filter dialog box. You will have to alter the filter expression at
least before the filter will be accepted. The format of color filter
expressions is identical to that of display filters. The new filter is
selected, so it may immediately be moved up and down, deleted or edited.
To avoid confusion all filters are unselected before the new filter is
created.

EDIT
Opens the Edit Color Filter dialog box for the selected filter. (If this
button is disabled you may have more than one filter selected, making it
ambiguous which is to be edited.)

DELETE
Deletes the selected color filter(s).

OK
Closes the dialog and uses the color filters as they stand.

APPLY
Colors the packets according to the current list of color filters, but
does not close the dialog.

SAVE
Saves the current list of color filters in your personal colorfilters
file. Unless you do this they will not be used the next time you start
Ethereal.

REVERT
Deletes your personal colorfilters file, reloads the global
colorfilters file, if any, and closes the dialog.

EXPORT (Save As if using GTK2+)
Allows you to choose a file in which to save the current list of color
filters. You may also choose to save only the selected filters. A
button is provided to save the filters in the global colorfilter file,
(you must have sufficient permissions to write this file, of course.)

IMPORT (Open if using GTK2+)
Allows you to choose a file containing color filters which are then
added to the bottom of the current list. All the added filters are
selected, so they may be moved to the correct position in the list as a
group. To avoid confusion all filters are unselected before the new
filters are imported. A button is provided to load the filters from the
global colorfilter file.

CANCEL
Closes the dialog without changing the coloration of the packets. Note
that changes you have made to the current list of color filters is not
undone.



=item Display:Collapse All

Collapse the protocol tree branches.
Expand Down
Loading

0 comments on commit 710f08b

Please sign in to comment.