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

A delegate that renders specific table cells as clickable URL links. More...

#include <url_link_delegate.h>

Inheritance diagram for UrlLinkDelegate:
CredentialsUrlDelegate

Public Member Functions

 UrlLinkDelegate (QObject *parent=Q_NULLPTR)
 Constructs a new UrlLinkDelegate object.
 
 ~UrlLinkDelegate ()
 Destroys the UrlLinkDelegate object.
 
void setColCheck (int column, QString &pattern)
 Configures a column to be checked against a regular expression pattern for URL rendering.
 

Protected Member Functions

virtual void paint (QPainter *painter, const QStyleOptionViewItem &option, const QModelIndex &index) const
 Custom paint method to render the cell text as a URL if it matches the pattern.
 

Detailed Description

A delegate that renders specific table cells as clickable URL links.

Constructor & Destructor Documentation

◆ UrlLinkDelegate()

UrlLinkDelegate::UrlLinkDelegate ( QObject *  parent = Q_NULLPTR)
explicit

Constructs a new UrlLinkDelegate object.

Parameters
parentThe parent object.

Member Function Documentation

◆ paint()

void UrlLinkDelegate::paint ( QPainter *  painter,
const QStyleOptionViewItem &  option,
const QModelIndex &  index 
) const
protectedvirtual

Custom paint method to render the cell text as a URL if it matches the pattern.

Parameters
painterThe painter object.
optionThe style option for the item.
indexThe model index of the item.

Reimplemented in CredentialsUrlDelegate.

◆ setColCheck()

void UrlLinkDelegate::setColCheck ( int  column,
QString &  pattern 
)

Configures a column to be checked against a regular expression pattern for URL rendering.

Parameters
columnThe column index to check.
patternThe regular expression pattern string.

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