Wireshark 4.7.0
The Wireshark network protocol analyzer
Loading...
Searching...
No Matches
Public Slots | Public Member Functions | Protected Member Functions | List of all members
SearchFrame Class Reference

Collapsible search bar that allows searching packet data by display filter, hex value, string, or regular expression, with forward and backward navigation through matching frames. More...

#include <search_frame.h>

Inheritance diagram for SearchFrame:
AccordionFrame StratosharkSearchFrame

Public Slots

void setCaptureFile (capture_file *cf)
 Updates the capture file pointer used for frame searches.
 
void refreshWidgets ()
 Refreshes widget state when external in-packet-find bar visibility changes.
 
void findFrameWithFilter (QString &filter)
 Populates the search field with filter, switches the search type to display filter, and immediately executes a forward search.
 

Public Member Functions

 SearchFrame (QWidget *parent=0)
 Constructs a SearchFrame in its collapsed (hidden) state.
 
virtual ~SearchFrame ()
 Destroys the SearchFrame and releases all associated resources.
 
void animatedShow ()
 Expands the frame with an animation and focuses the search input.
 
void findNext ()
 Navigates to the next frame matching the current search criteria.
 
void findPrevious ()
 Navigates to the previous frame matching the current search criteria.
 
void setFocus ()
 Transfers keyboard focus to the search input field.
 
- Public Member Functions inherited from AccordionFrame
 AccordionFrame (QWidget *parent=0)
 Create an AccordionFrame with the given parent.
 
void animatedShow ()
 Show the frame with a slide-down animation.
 
void animatedHide ()
 Hide the frame with a slide-up animation.
 
void updateStyleSheet ()
 Reapply the stylesheet after a palette or style change.
 

Protected Member Functions

virtual void keyPressEvent (QKeyEvent *event)
 Handles key press events; maps Enter/Return to findNext() and Escape to collapsing the frame.
 
void changeEvent (QEvent *event)
 Responds to language or palette change events by retranslating and refreshing the UI.
 
void updateWidgets ()
 Enables or disables UI controls based on the current search type, direction, and validity of the search expression.
 
QComboBox * searchInComboBox () const
 Returns the "Search In" combo box widget for use by subclasses or tests.
 
- Protected Member Functions inherited from AccordionFrame
virtual void hideEvent (QHideEvent *)
 Emit visibilityChanged(false) when the frame is hidden.
 
virtual void showEvent (QShowEvent *)
 Emit visibilityChanged(true) when the frame is shown.
 

Additional Inherited Members

- Signals inherited from AccordionFrame
void visibilityChanged (bool visible)
 Emitted when the frame's visibility changes.
 

Detailed Description

Collapsible search bar that allows searching packet data by display filter, hex value, string, or regular expression, with forward and backward navigation through matching frames.

Constructor & Destructor Documentation

◆ SearchFrame()

SearchFrame::SearchFrame ( QWidget *  parent = 0)
explicit

Constructs a SearchFrame in its collapsed (hidden) state.

Parameters
parentOptional parent widget.

Member Function Documentation

◆ changeEvent()

void SearchFrame::changeEvent ( QEvent *  event)
protected

Responds to language or palette change events by retranslating and refreshing the UI.

Parameters
eventThe change event.

◆ findFrameWithFilter

void SearchFrame::findFrameWithFilter ( QString &  filter)
slot

Populates the search field with filter, switches the search type to display filter, and immediately executes a forward search.

Parameters
filterDisplay filter expression to search for.

◆ keyPressEvent()

void SearchFrame::keyPressEvent ( QKeyEvent *  event)
protectedvirtual

Handles key press events; maps Enter/Return to findNext() and Escape to collapsing the frame.

Parameters
eventThe key event to process.

◆ searchInComboBox()

QComboBox * SearchFrame::searchInComboBox ( ) const
protected

Returns the "Search In" combo box widget for use by subclasses or tests.

Returns
Pointer to the searchInComboBox widget.

◆ setCaptureFile

void SearchFrame::setCaptureFile ( capture_file cf)
slot

Updates the capture file pointer used for frame searches.

Parameters
cfNew capture file; may be NULL when no file is open.

The documentation for this class was generated from the following files: