MythTV  master
Public Member Functions | Public Attributes | List of all members
MHIText Class Reference

#include <mhi.h>

Inheritance diagram for MHIText:
Inheritance graph
[legend]
Collaboration diagram for MHIText:
Collaboration graph
[legend]

Public Member Functions

 MHIText (MHIContext *parent)
 
 ~MHIText () override=default
 
void Draw (int x, int y) override
 
void Clear (void) override
 
void AddText (int x, int y, const QString &str, MHRgba colour) override
 
void SetSize (int width, int height) override
 
void SetFont (int size, bool isBold, bool isItalic) override
 
QRect GetBounds (const QString &str, int &strLen, int maxSize=-1) override
 
- Public Member Functions inherited from MHTextDisplay
virtual ~MHTextDisplay ()=default
 

Public Attributes

MHIContextm_parent {nullptr}
 
QImage m_image
 
int m_fontSize {12}
 
bool m_fontItalic {false}
 
bool m_fontBold {false}
 
int m_width {0}
 
int m_height {0}
 

Detailed Description

Definition at line 238 of file mhi.h.

Constructor & Destructor Documentation

◆ MHIText()

MHIText::MHIText ( MHIContext parent)
inlineexplicit

Definition at line 241 of file mhi.h.

◆ ~MHIText()

MHIText::~MHIText ( )
overridedefault

Member Function Documentation

◆ Draw()

void MHIText::Draw ( int  x,
int  y 
)
overridevirtual

Implements MHTextDisplay.

Definition at line 1232 of file mhi.cpp.

◆ Clear()

void MHIText::Clear ( void  )
overridevirtual

Implements MHTextDisplay.

Definition at line 1348 of file mhi.cpp.

◆ AddText()

void MHIText::AddText ( int  x,
int  y,
const QString &  str,
MHRgba  colour 
)
overridevirtual

Implements MHTextDisplay.

Definition at line 1364 of file mhi.cpp.

◆ SetSize()

void MHIText::SetSize ( int  width,
int  height 
)
overridevirtual

Implements MHTextDisplay.

Definition at line 1237 of file mhi.cpp.

◆ SetFont()

void MHIText::SetFont ( int  size,
bool  isBold,
bool  isItalic 
)
overridevirtual

Implements MHTextDisplay.

Definition at line 1243 of file mhi.cpp.

◆ GetBounds()

QRect MHIText::GetBounds ( const QString &  str,
int &  strLen,
int  maxSize = -1 
)
overridevirtual

Implements MHTextDisplay.

Definition at line 1271 of file mhi.cpp.

Member Data Documentation

◆ m_parent

MHIContext* MHIText::m_parent {nullptr}

Definition at line 255 of file mhi.h.

Referenced by AddText(), Draw(), and GetBounds().

◆ m_image

QImage MHIText::m_image

Definition at line 256 of file mhi.h.

Referenced by AddText(), Clear(), and Draw().

◆ m_fontSize

int MHIText::m_fontSize {12}

Definition at line 257 of file mhi.h.

Referenced by AddText(), GetBounds(), and SetFont().

◆ m_fontItalic

bool MHIText::m_fontItalic {false}

Definition at line 258 of file mhi.h.

Referenced by SetFont().

◆ m_fontBold

bool MHIText::m_fontBold {false}

Definition at line 259 of file mhi.h.

Referenced by SetFont().

◆ m_width

int MHIText::m_width {0}

Definition at line 260 of file mhi.h.

Referenced by AddText(), Clear(), Draw(), and SetSize().

◆ m_height

int MHIText::m_height {0}

Definition at line 261 of file mhi.h.

Referenced by AddText(), Clear(), Draw(), and SetSize().


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