TTKMusicPlayer  3.7.0.0
TTKMusicPlayer imitates Kugou UI, the music player uses of qmmp core library based on Qt for windows and linux
Public Member Functions | Private Member Functions | Private Attributes | List of all members
MusicColorPreviewLabel Class Reference

The class of the lrc color preview label. More...

#include <musicpreviewlabel.h>

+ Inheritance diagram for MusicColorPreviewLabel:

Public Member Functions

 MusicColorPreviewLabel (QWidget *parent=nullptr)
 
void setColors (const QList< QColor > &colors)
 
QList< QColor > colors () const
 
QColor color () const
 
- Public Member Functions inherited from TTKClickedLabel
 TTKClickedLabel (QWidget *parent=nullptr)
 
 TTKClickedLabel (const QString &text, QWidget *parent=nullptr)
 

Private Member Functions

virtual void paintEvent (QPaintEvent *event) overridefinal
 

Private Attributes

QList< QColor > m_gradientColors
 
QLinearGradient m_linearGradient
 

Additional Inherited Members

- Signals inherited from TTKClickedLabel
void clicked ()
 

Detailed Description

The class of the lrc color preview label.

Author
Greedysky greed.nosp@m.ysky.nosp@m.@163..nosp@m.com

Definition at line 27 of file musicpreviewlabel.h.

Constructor & Destructor Documentation

MusicColorPreviewLabel::MusicColorPreviewLabel ( QWidget *  parent = nullptr)
explicit

Object constructor.

Definition at line 4 of file musicpreviewlabel.cpp.

References m_linearGradient.

Member Function Documentation

QColor MusicColorPreviewLabel::color ( ) const

Get linear gradient color.

Definition at line 28 of file musicpreviewlabel.cpp.

References m_gradientColors.

QList< QColor > MusicColorPreviewLabel::colors ( ) const

Get linear gradient colors.

Definition at line 23 of file musicpreviewlabel.cpp.

References m_gradientColors.

Referenced by setColors().

void MusicColorPreviewLabel::paintEvent ( QPaintEvent *  event)
finaloverrideprivatevirtual

Override the widget event.

Definition at line 33 of file musicpreviewlabel.cpp.

References m_linearGradient.

void MusicColorPreviewLabel::setColors ( const QList< QColor > &  colors)

Set linear gradient colors.

Definition at line 10 of file musicpreviewlabel.cpp.

References colors(), m_gradientColors, and m_linearGradient.

Member Data Documentation

QList<QColor> MusicColorPreviewLabel::m_gradientColors
private

Definition at line 56 of file musicpreviewlabel.h.

Referenced by color(), colors(), and setColors().

QLinearGradient MusicColorPreviewLabel::m_linearGradient
private

Definition at line 57 of file musicpreviewlabel.h.

Referenced by MusicColorPreviewLabel(), paintEvent(), and setColors().


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