Wireshark mailing list archives

Re: How to format a subtree banner?


From: eymanm <eymanm () gmail com>
Date: Mon, 2 Aug 2010 10:10:20 -0400

and can perfectly generate output, which looks like
string: String1 (1)
using proto_tree_add_item() function. In order to make the output a bit
more user friendly, I'd >prefer to have it as a subtree.

What would be in that subtree?  Presumably there would be more than one
value in it (a >subtree with only one value is generally not that useful);
is the value that's decoded with the >value_string in question one of the
values?  If so, what are the other values?


Here's how the subtree is displayed (line numbers are added by me):

1    1
2        String1 (1)
3        Value...displayed nice...
... Further values of the subtree...

Line 1 is generated by proto_tree_add_uint_format() and
proto_item_add_subtree() functions.
Line 2 is generated by proto_tree_add_item() function.

There is an expansion "+" on line 1. So, if the branch is not expanded, only
"1" is visible. My goal is to display both "String1" and "1" when the tree
is not expanded.

Thanks again!




___________________________________________________________________________
Sent via:    Wireshark-dev mailing list <wireshark-dev () wireshark org>
Archives:    http://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
            mailto:wireshark-dev-request () wireshark org?subject=unsubscribe

___________________________________________________________________________
Sent via:    Wireshark-dev mailing list <wireshark-dev () wireshark org>
Archives:    http://www.wireshark.org/lists/wireshark-dev
Unsubscribe: https://wireshark.org/mailman/options/wireshark-dev
             mailto:wireshark-dev-request () wireshark org?subject=unsubscribe

Current thread: