Item delegate that visually annotates packet-list rows with relationship indicators — arrows, chevrons, and check marks — showing how each packet relates to the currently selected frame and its conversation.
More...
#include <related_packet_delegate.h>
|
| | RelatedPacketDelegate (QWidget *parent=0) |
| | Constructs a RelatedPacketDelegate with no related frames or conversation.
|
| |
|
void | clear () |
| | Clears all related frame entries and resets the conversation pointer.
|
| |
| void | setCurrentFrame (uint32_t current_frame) |
| | Sets the frame number of the currently selected packet.
|
| |
| void | setConversation (struct conversation *conv) |
| | Associates a conversation with the delegate so that conversation membership can be reflected in the rendered indicators.
|
| |
|
| void | initStyleOption (QStyleOptionViewItem *option, const QModelIndex &index) const |
| | Initialises the style option for a row, suppressing the default focus/selection highlight in the indicator column.
|
| |
| void | paint (QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const |
| | Paints the relationship indicator for the packet at index.
|
| |
| QSize | sizeHint (const QStyleOptionViewItem &option, const QModelIndex &index) const |
| | Returns the preferred size for the indicator cell.
|
| |
Item delegate that visually annotates packet-list rows with relationship indicators — arrows, chevrons, and check marks — showing how each packet relates to the currently selected frame and its conversation.
◆ RelatedPacketDelegate()
| RelatedPacketDelegate::RelatedPacketDelegate |
( |
QWidget * |
parent = 0 | ) |
|
Constructs a RelatedPacketDelegate with no related frames or conversation.
- Parameters
-
| parent | Optional parent widget. |
◆ addRelatedFrame
Registers a frame as related to the current selection.
- Parameters
-
| frame_num | Frame number to mark as related. |
| framenum_type | Relationship type that controls which indicator is drawn (e.g. request, response, reassembly); defaults to FT_FRAMENUM_NONE. |
◆ initStyleOption()
| void RelatedPacketDelegate::initStyleOption |
( |
QStyleOptionViewItem * |
option, |
|
|
const QModelIndex & |
index |
|
) |
| const |
|
protected |
Initialises the style option for a row, suppressing the default focus/selection highlight in the indicator column.
- Parameters
-
| option | Style option to populate. |
| index | Model index of the item being rendered. |
◆ paint()
| void RelatedPacketDelegate::paint |
( |
QPainter * |
painter, |
|
|
const QStyleOptionViewItem & |
option, |
|
|
const QModelIndex & |
index |
|
) |
| const |
|
protected |
Paints the relationship indicator for the packet at index.
- Parameters
-
| painter | Painter to draw with. |
| option | Style option providing geometry and state. |
| index | Model index of the item being painted. |
◆ setConversation()
| void RelatedPacketDelegate::setConversation |
( |
struct conversation * |
conv | ) |
|
Associates a conversation with the delegate so that conversation membership can be reflected in the rendered indicators.
- Parameters
-
| conv | Pointer to the libwireshark conversation, or nullptr to clear. |
◆ setCurrentFrame()
| void RelatedPacketDelegate::setCurrentFrame |
( |
uint32_t |
current_frame | ) |
|
Sets the frame number of the currently selected packet.
Used to determine which relationship indicators to draw relative to the selection.
- Parameters
-
| current_frame | Frame number of the selected packet. |
◆ sizeHint()
| QSize RelatedPacketDelegate::sizeHint |
( |
const QStyleOptionViewItem & |
option, |
|
|
const QModelIndex & |
index |
|
) |
| const |
|
protected |
Returns the preferred size for the indicator cell.
- Parameters
-
| option | Style option providing font metrics and state. |
| index | Model index of the item being measured. |
- Returns
- Recommended QSize for the indicator column cell.
The documentation for this class was generated from the following files:
- /builds/wireshark/wireshark/ui/qt/models/related_packet_delegate.h
- /builds/wireshark/wireshark/ui/qt/models/related_packet_delegate.cpp