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 | List of all members
QRCodeQWidget Class Reference

The class of the qr code widget. More...

#include <qrcodewidget.h>

+ Inheritance diagram for QRCodeQWidget:

Public Member Functions

 QRCodeQWidget (const QByteArray &text, const QSize &size, QWidget *parent=nullptr)
 
void setMargin (const int margin)
 
int margin () const
 
void setIcon (const QString &path, float percent)
 
QString icon () const
 
void setIconPercent (float percent)
 
float iconPercent () const
 
void setCaseSensitive (bool flag)
 
bool caseSensitive () const
 
void setText (const QByteArray &text)
 
QByteArray text () const
 
void setForegroundColor (const QColor &color)
 
QColor foregroundColor () const
 
void setBackgroundColor (const QColor &color)
 
QColor backgroundColor () const
 
void setMode (QRencodeMode mode)
 
QRencodeMode mode () const
 
void setLevel (QRecLevel level)
 
QRecLevel level () const
 

Private Member Functions

virtual void paintEvent (QPaintEvent *event) overridefinal
 

Detailed Description

The class of the qr code widget.

Author
Jemy Graw jemyg.nosp@m.raw@.nosp@m.gmail.nosp@m..com

Definition at line 31 of file qrcodewidget.h.

Constructor & Destructor Documentation

QRCodeQWidget::QRCodeQWidget ( const QByteArray &  text,
const QSize &  size,
QWidget *  parent = nullptr 
)

Object constructor.

Definition at line 38 of file qrcodewidget.cpp.

References text(), TTK_D, and TTK_INIT_PRIVATE.

Member Function Documentation

QColor QRCodeQWidget::backgroundColor ( ) const

Get qr background color.

Definition at line 130 of file qrcodewidget.cpp.

References TTK_D.

bool QRCodeQWidget::caseSensitive ( ) const

Get case sensitive.

Definition at line 94 of file qrcodewidget.cpp.

References TTK_D.

QColor QRCodeQWidget::foregroundColor ( ) const

Get qr foreground color.

Definition at line 118 of file qrcodewidget.cpp.

References TTK_D.

QString QRCodeQWidget::icon ( ) const

Get qr icon.

Definition at line 69 of file qrcodewidget.cpp.

References TTK_D.

float QRCodeQWidget::iconPercent ( ) const

Get qr icon percent.

Definition at line 81 of file qrcodewidget.cpp.

References TTK_D.

QRecLevel QRCodeQWidget::level ( ) const

Get qr level.

Definition at line 154 of file qrcodewidget.cpp.

References TTK_D.

Referenced by setLevel().

int QRCodeQWidget::margin ( ) const

Get qr margin.

Definition at line 55 of file qrcodewidget.cpp.

References TTK_D.

Referenced by setMargin().

QRencodeMode QRCodeQWidget::mode ( ) const

Get qr mode.

Definition at line 142 of file qrcodewidget.cpp.

References TTK_D.

Referenced by setMode().

void QRCodeQWidget::paintEvent ( QPaintEvent *  event)
finaloverrideprivatevirtual

Override the widget event.

draw icon

Definition at line 160 of file qrcodewidget.cpp.

References QRcode::data, QRcode_encodeString(), QRcode_free(), TTK_D, and QRcode::width.

void QRCodeQWidget::setBackgroundColor ( const QColor &  color)

Set qr background color.

Definition at line 124 of file qrcodewidget.cpp.

References TTK_D.

void QRCodeQWidget::setCaseSensitive ( bool  flag)

Set case sensitive.

Definition at line 87 of file qrcodewidget.cpp.

References TTK_D.

void QRCodeQWidget::setForegroundColor ( const QColor &  color)

Set qr foreground color.

Definition at line 112 of file qrcodewidget.cpp.

References TTK_D.

void QRCodeQWidget::setIcon ( const QString &  path,
float  percent 
)
void QRCodeQWidget::setIconPercent ( float  percent)

Set qr icon percent.

Definition at line 75 of file qrcodewidget.cpp.

References TTK_D.

Referenced by setIcon().

void QRCodeQWidget::setLevel ( QRecLevel  level)

Set qr level.

Definition at line 148 of file qrcodewidget.cpp.

References level(), and TTK_D.

void QRCodeQWidget::setMargin ( const int  margin)
void QRCodeQWidget::setMode ( QRencodeMode  mode)

Set qr mode.

Definition at line 136 of file qrcodewidget.cpp.

References mode(), and TTK_D.

void QRCodeQWidget::setText ( const QByteArray &  text)

Set qr text.

Definition at line 100 of file qrcodewidget.cpp.

References text(), and TTK_D.

Referenced by MusicSongSharingWidget::sendToShare().

QByteArray QRCodeQWidget::text ( ) const

Get qr text.

Definition at line 106 of file qrcodewidget.cpp.

References TTK_D.

Referenced by QRCodeQWidget(), and setText().


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