diff options
Diffstat (limited to 'epan/column.c')
-rw-r--r-- | epan/column.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/epan/column.c b/epan/column.c index 789f3ecc54..85fe8212a5 100644 --- a/epan/column.c +++ b/epan/column.c @@ -415,6 +415,18 @@ get_timestamp_column_longest_string(gint type, gint precision) return ""; } +/* Returns the longer string of the column title or the hard-coded width of + * its contents for building the packet list layout. */ +const gchar * +get_column_width_string(gint format, gint col) +{ + if(strlen(get_column_longest_string(format)) > + strlen(get_column_title(col))) + return get_column_longest_string(format); + else + return get_column_title(col); +} + /* Returns a string representing the longest possible value for a particular column type. |