Sayonara Player
Public Slots | Public Member Functions | Protected Member Functions | List of all members
Gui::FloatingLabel Class Reference

The FloatingLabel class. A QLabel where the text floats from left to right and vice versa so there's no need for word wrapping anymore. More...

#include <FloatingLabel.h>

Inheritance diagram for Gui::FloatingLabel:
Gui::WidgetTemplate< QLabel > Gui::WidgetTemplateParent

Public Slots

void updateOffset ()
 

Public Member Functions

 FloatingLabel (QWidget *parent=nullptr)
 
void setFloatingText (const QString &text)
 Use this method insteas of using QLabel::setText() More...
 
void setCharsPerSecond (int charsPerSecond)
 set the desired speed More...
 
virtual void showEvent (QShowEvent *e) override
 

Protected Member Functions

void paintEvent (QPaintEvent *event) override
 
void resizeEvent (QResizeEvent *event) override
 
virtual void languageChanged ()
 
virtual void skinChanged ()
 

Detailed Description

The FloatingLabel class. A QLabel where the text floats from left to right and vice versa so there's no need for word wrapping anymore.

Member Function Documentation

◆ setCharsPerSecond()

void Gui::FloatingLabel::setCharsPerSecond ( int  charsPerSecond)

set the desired speed

Parameters
charsPerSeconda good value is 3

◆ setFloatingText()

void Gui::FloatingLabel::setFloatingText ( const QString &  text)

Use this method insteas of using QLabel::setText()

Parameters
text