PulseView  unreleased development snapshot
A Qt-based sigrok GUI
pv::widgets::Popup Class Reference

#include <popup.hpp>

Inheritance diagram for pv::widgets::Popup:
Collaboration diagram for pv::widgets::Popup:

Public Types

enum  Position { Right, Top, Left, Bottom }
 

Signals

void closed ()
 

Public Member Functions

 Popup (QWidget *parent)
 
const QPoint & point () const
 
Position position () const
 
void set_position (const QPoint point, Position pos)
 
bool eventFilter (QObject *obj, QEvent *event)
 
virtual void show ()
 

Protected Member Functions

void showEvent (QShowEvent *)
 

Private Member Functions

bool space_for_arrow () const
 
QPolygon arrow_polygon () const
 
QRegion arrow_region () const
 
QRect bubble_rect () const
 
QRegion bubble_region () const
 
QRegion popup_region () const
 
void reposition_widget ()
 
void closeEvent (QCloseEvent *)
 
void paintEvent (QPaintEvent *)
 
void resizeEvent (QResizeEvent *)
 
void mouseReleaseEvent (QMouseEvent *event)
 

Private Attributes

QPoint point_
 
Position pos_
 

Static Private Attributes

static const unsigned int ArrowLength = 10
 
static const unsigned int ArrowOverlap = 3
 
static const unsigned int MarginWidth = 6
 

Detailed Description

Definition at line 46 of file popup.hpp.

Member Enumeration Documentation

Enumerator
Right 
Top 
Left 
Bottom 

Definition at line 51 of file popup.hpp.

Constructor & Destructor Documentation

pv::widgets::Popup::Popup ( QWidget *  parent)

Definition at line 73 of file popup.cpp.

Member Function Documentation

QPolygon pv::widgets::Popup::arrow_polygon ( ) const
private

Definition at line 171 of file popup.cpp.

Here is the caller graph for this function:

QRegion pv::widgets::Popup::arrow_region ( ) const
private

Definition at line 213 of file popup.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

QRect pv::widgets::Popup::bubble_rect ( ) const
private

Definition at line 218 of file popup.cpp.

Here is the caller graph for this function:

QRegion pv::widgets::Popup::bubble_region ( ) const
private

Definition at line 229 of file popup.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void pv::widgets::Popup::closed ( )
signal

Definition at line 190 of file moc_popup.cpp.

Here is the caller graph for this function:

void pv::widgets::Popup::closeEvent ( QCloseEvent *  )
private

Definition at line 283 of file popup.cpp.

bool pv::widgets::Popup::eventFilter ( QObject obj,
QEvent *  event 
)

Definition at line 101 of file popup.cpp.

void pv::widgets::Popup::mouseReleaseEvent ( QMouseEvent *  event)
private

Definition at line 329 of file popup.cpp.

Here is the call graph for this function:

void pv::widgets::Popup::paintEvent ( QPaintEvent *  )
private

Definition at line 288 of file popup.cpp.

Here is the call graph for this function:

const QPoint & pv::widgets::Popup::point ( ) const

Definition at line 80 of file popup.cpp.

Here is the caller graph for this function:

QRegion pv::widgets::Popup::popup_region ( ) const
private

Definition at line 247 of file popup.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

Popup::Position pv::widgets::Popup::position ( ) const

Definition at line 85 of file popup.cpp.

void pv::widgets::Popup::reposition_widget ( )
private

Definition at line 255 of file popup.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void pv::widgets::Popup::resizeEvent ( QResizeEvent *  )
private

Definition at line 323 of file popup.cpp.

Here is the call graph for this function:

void pv::widgets::Popup::set_position ( const QPoint  point,
Position  pos 
)

Definition at line 90 of file popup.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

void pv::widgets::Popup::show ( )
virtual

Reimplemented in pv::popups::DeviceOptions.

Definition at line 119 of file popup.cpp.

Here is the caller graph for this function:

void pv::widgets::Popup::showEvent ( QShowEvent *  )
protected

Definition at line 339 of file popup.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

bool pv::widgets::Popup::space_for_arrow ( ) const
private

Definition at line 143 of file popup.cpp.

Here is the call graph for this function:

Here is the caller graph for this function:

Member Data Documentation

const unsigned int pv::widgets::Popup::ArrowLength = 10
staticprivate

Definition at line 60 of file popup.hpp.

const unsigned int pv::widgets::Popup::ArrowOverlap = 3
staticprivate

Definition at line 61 of file popup.hpp.

const unsigned int pv::widgets::Popup::MarginWidth = 6
staticprivate

Definition at line 62 of file popup.hpp.

QPoint pv::widgets::Popup::point_
private

Definition at line 107 of file popup.hpp.

Position pv::widgets::Popup::pos_
private

Definition at line 108 of file popup.hpp.


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