LibrePCB Developers Documentation
Loading...
Searching...
No Matches
PartInformationToolTip Class Referencefinal

The PartInformationToolTip class. More...

#include <partinformationtooltip.h>

Inherits QFrame.

+ Collaboration diagram for PartInformationToolTip:

Public Member Functions

 PartInformationToolTip ()=delete
 
 PartInformationToolTip (const PartInformationToolTip &other)=delete
 
 PartInformationToolTip (const WorkspaceSettings &settings, QWidget *parent=nullptr) noexcept
 
 ~PartInformationToolTip () noexcept
 
void setProviderInfo (const QString &name, const QUrl &url, const QPixmap &logo, const QUrl &infoUrl) noexcept
 
void showPart (const std::shared_ptr< const PartInformationProvider::PartInformation > &info, const QPoint &pos) noexcept
 
void hideAndReset (bool reset=true) noexcept
 
virtual bool eventFilter (QObject *watched, QEvent *event) noexcept override
 
PartInformationToolTipoperator= (const PartInformationToolTip &rhs)=delete
 

Protected Member Functions

virtual void showEvent (QShowEvent *e) noexcept override
 
virtual void hideEvent (QHideEvent *e) noexcept override
 

Private Member Functions

void scheduleLoadPicture () noexcept
 
void startLoadPicture (bool onlyCache) noexcept
 
void setLabelPixmap (QLabel *label, const QPixmap &pixmap, const QSize &space) noexcept
 
void updateShape () noexcept
 
void setSourceDetailsExpanded (bool expanded, bool animated) noexcept
 
void openUrl (const QUrl &url) noexcept
 

Private Attributes

const WorkspaceSettingsmSettings
 
QScopedPointer< Ui::PartInformationToolTip > mUi
 
QScopedPointer< WaitingSpinnerWidgetmWaitingSpinner
 
QScopedPointer< QVariantAnimation > mExpandAnimation
 
QScopedPointer< QTimer > mPopUpDelayTimer
 
int mArrowPositionY
 
std::shared_ptr< const PartInformationProvider::PartInformationmPartInfo
 
QScopedPointer< QTimer > mPictureDelayTimer
 

Static Private Attributes

static const constexpr int sPopupDelayMs = 300
 
static const constexpr int sWindowArrowSize = 8
 

Detailed Description

Constructor & Destructor Documentation

◆ PartInformationToolTip() [1/3]

◆ PartInformationToolTip() [2/3]

◆ PartInformationToolTip() [3/3]

PartInformationToolTip ( const WorkspaceSettings settings,
QWidget *  parent = nullptr 
)
explicitnoexcept
+ Here is the call graph for this function:

◆ ~PartInformationToolTip()

~PartInformationToolTip ( )
noexcept

Member Function Documentation

◆ setProviderInfo()

void setProviderInfo ( const QString &  name,
const QUrl &  url,
const QPixmap &  logo,
const QUrl &  infoUrl 
)
noexcept

◆ showPart()

void showPart ( const std::shared_ptr< const PartInformationProvider::PartInformation > &  info,
const QPoint &  pos 
)
noexcept
+ Here is the call graph for this function:

◆ hideAndReset()

void hideAndReset ( bool  reset = true)
noexcept

◆ eventFilter()

bool eventFilter ( QObject *  watched,
QEvent *  event 
)
overridevirtualnoexcept

◆ operator=()

PartInformationToolTip & operator= ( const PartInformationToolTip rhs)
delete

◆ showEvent()

void showEvent ( QShowEvent *  e)
overrideprotectedvirtualnoexcept

◆ hideEvent()

void hideEvent ( QHideEvent *  e)
overrideprotectedvirtualnoexcept

◆ scheduleLoadPicture()

void scheduleLoadPicture ( )
privatenoexcept
+ Here is the call graph for this function:

◆ startLoadPicture()

void startLoadPicture ( bool  onlyCache)
privatenoexcept
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

◆ setLabelPixmap()

void setLabelPixmap ( QLabel *  label,
const QPixmap &  pixmap,
const QSize &  space 
)
privatenoexcept

◆ updateShape()

void updateShape ( )
privatenoexcept

◆ setSourceDetailsExpanded()

void setSourceDetailsExpanded ( bool  expanded,
bool  animated 
)
privatenoexcept

◆ openUrl()

void openUrl ( const QUrl &  url)
privatenoexcept
+ Here is the call graph for this function:
+ Here is the caller graph for this function:

Member Data Documentation

◆ mSettings

const WorkspaceSettings& mSettings
private

◆ mUi

QScopedPointer<Ui::PartInformationToolTip> mUi
private

◆ mWaitingSpinner

QScopedPointer<WaitingSpinnerWidget> mWaitingSpinner
private

◆ mExpandAnimation

QScopedPointer<QVariantAnimation> mExpandAnimation
private

◆ mPopUpDelayTimer

QScopedPointer<QTimer> mPopUpDelayTimer
private

◆ mArrowPositionY

int mArrowPositionY
private

◆ mPartInfo

std::shared_ptr<const PartInformationProvider::PartInformation> mPartInfo
private

◆ mPictureDelayTimer

QScopedPointer<QTimer> mPictureDelayTimer
private

◆ sPopupDelayMs

const constexpr int sPopupDelayMs = 300
staticconstexprprivate

◆ sWindowArrowSize

const constexpr int sWindowArrowSize = 8
staticconstexprprivate

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