Chatterino
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
chatterino::TextLayoutElement Class Reference

#include <MessageLayoutElement.hpp>

Inheritance diagram for chatterino::TextLayoutElement:
[legend]
Collaboration diagram for chatterino::TextLayoutElement:
[legend]

Public Member Functions

 TextLayoutElement (MessageElement &creator_, QString &text, const QSize &size, QColor color_, FontStyle style_, float scale_)
 
void listenToLinkChanges ()
 
- Public Member Functions inherited from chatterino::MessageLayoutElement
 MessageLayoutElement (MessageElement &creator_, const QSize &size)
 
virtual ~MessageLayoutElement ()
 
const QRect & getRect () const
 
MessageElementgetCreator () const
 
void setPosition (QPoint point)
 
bool hasTrailingSpace () const
 
int getLine () const
 
void setLine (int line)
 
MessageLayoutElementsetTrailingSpace (bool value)
 
MessageLayoutElementsetLink (const Link &link_)
 
MessageLayoutElementsetText (const QString &text_)
 
const LinkgetLink () const
 
const QString & getText () const
 
FlagsEnum< MessageElementFlaggetFlags () const
 

Protected Member Functions

void addCopyTextToString (QString &str, uint32_t from=0, uint32_t to=UINT32_MAX) const override
 
int getSelectionIndexCount () const override
 
void paint (QPainter &painter) override
 
void paintAnimated (QPainter &painter, int yOffset) override
 
int getMouseOverIndex (const QPoint &abs) const override
 
int getXFromIndex (int index) override
 

Protected Attributes

QColor color_
 
FontStyle style_
 
float scale_
 
pajlada::Signals::SignalHolder managedConnections_
 
- Protected Attributes inherited from chatterino::MessageLayoutElement
bool trailingSpace = true
 

Additional Inherited Members

- Public Attributes inherited from chatterino::MessageLayoutElement
bool reversedNeutral = false
 

Constructor & Destructor Documentation

◆ TextLayoutElement()

chatterino::TextLayoutElement::TextLayoutElement ( MessageElement creator_,
QString &  text,
const QSize &  size,
QColor  color_,
FontStyle  style_,
float  scale_ 
)
Here is the call graph for this function:

Member Function Documentation

◆ addCopyTextToString()

void chatterino::TextLayoutElement::addCopyTextToString ( QString &  str,
uint32_t  from = 0,
uint32_t  to = UINT32_MAX 
) const
overrideprotectedvirtual

Implements chatterino::MessageLayoutElement.

Here is the call graph for this function:

◆ getMouseOverIndex()

int chatterino::TextLayoutElement::getMouseOverIndex ( const QPoint &  abs) const
overrideprotectedvirtual

Implements chatterino::MessageLayoutElement.

Here is the call graph for this function:

◆ getSelectionIndexCount()

int chatterino::TextLayoutElement::getSelectionIndexCount ( ) const
overrideprotectedvirtual

Implements chatterino::MessageLayoutElement.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ getXFromIndex()

int chatterino::TextLayoutElement::getXFromIndex ( int  index)
overrideprotectedvirtual

Implements chatterino::MessageLayoutElement.

Here is the call graph for this function:

◆ listenToLinkChanges()

void chatterino::TextLayoutElement::listenToLinkChanges ( )
Here is the call graph for this function:

◆ paint()

void chatterino::TextLayoutElement::paint ( QPainter &  painter)
overrideprotectedvirtual

Implements chatterino::MessageLayoutElement.

Here is the call graph for this function:

◆ paintAnimated()

void chatterino::TextLayoutElement::paintAnimated ( QPainter &  painter,
int  yOffset 
)
overrideprotectedvirtual

Member Data Documentation

◆ color_

QColor chatterino::TextLayoutElement::color_
protected

◆ managedConnections_

pajlada::Signals::SignalHolder chatterino::TextLayoutElement::managedConnections_
protected

◆ scale_

float chatterino::TextLayoutElement::scale_
protected

◆ style_

FontStyle chatterino::TextLayoutElement::style_
protected

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