4 * $Id: ethereal.h,v 1.6 1998/10/12 01:40:48 gerald Exp $
6 * Ethereal - Network traffic analyzer
7 * By Gerald Combs <gerald@zing.org>
8 * Copyright 1998 Gerald Combs
11 * This program is free software; you can redistribute it and/or
12 * modify it under the terms of the GNU General Public License
13 * as published by the Free Software Foundation; either version 2
14 * of the License, or (at your option) any later version.
16 * This program is distributed in the hope that it will be useful,
17 * but WITHOUT ANY WARRANTY; without even the implied warranty of
18 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
19 * GNU General Public License for more details.
21 * You should have received a copy of the GNU General Public License
22 * along with this program; if not, write to the Free Software
23 * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
26 #ifndef __ETHEREAL_H__
27 #define __ETHEREAL_H__
31 #define RC_FILE ".etherealrc"
32 #define MONO_MEDIUM_FONT "-*-lucidatypewriter-medium-r-normal-*-*-120-*-*-*-*-iso8859-1"
33 #define MONO_BOLD_FONT "-*-lucidatypewriter-bold-r-normal-*-*-120-*-*-*-*-iso8859-1"
35 #define DEF_HEIGHT 550
36 #define DEF_READY_MESSAGE " Ready to load or capture"
37 #define EXTERNAL_FILTER "/usr/local/bin/ethereal_tcp_filter -f"
39 /* Byte swapping routines */
41 ( (((x) & 0x00ff) << 8) | \
42 (((x) & 0xff00) >> 8) )
44 ( (((x) & 0x000000ff) << 24) | \
45 (((x) & 0x0000ff00) << 8) | \
46 (((x) & 0x00ff0000) >> 8) | \
47 (((x) & 0xff000000) >> 24) )
51 #define LITTLE_ENDIAN 4321
52 #define BIG_ENDIAN 1234
53 #ifdef WORDS_BIGENDIAN
54 #define BYTE_ORDER BIG_ENDIAN
56 #define BYTE_ORDER LITTLE_ENDIAN
60 /* From the K&R book, p. 89 */
62 #define MAX(x, y) ((x) > (y) ? (x) : (y))
66 #define MIN(x, y) ((x) < (y) ? (x) : (y))
69 typedef struct _selection_info {
75 * Columns in summary listing.
80 #define COL_DESTINATION 3
81 #define COL_PROTOCOL 4
87 * Type of time-stamp shown in the summary display.
95 extern ts_type timestamp_type;
97 void file_sel_ok_cb(GtkWidget *, GtkFileSelection *);
98 void blank_packetinfo();
99 gint file_progress_cb(gpointer);
100 void follow_stream_cb( GtkWidget *, gpointer);
101 void file_open_cmd_cb(GtkWidget *, gpointer);
102 void file_close_cmd_cb(GtkWidget *, gpointer);
103 void file_quit_cmd_cb(GtkWidget *, gpointer);
104 void file_reload_cmd_cb(GtkWidget *, gpointer);
105 void file_print_cmd_cb(GtkWidget *, gpointer);
106 void main_realize_cb(GtkWidget *, gpointer);
108 #endif /* ethereal.h */