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

#include <mythpainter_qimage.h>

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

Public Member Functions

 MythQImagePainter ()
 
 ~MythQImagePainter ()
 
QString GetName (void) override
 
bool SupportsAnimation (void) override
 
bool SupportsAlpha (void) override
 
bool SupportsClipping (void) override
 
void Begin (QPaintDevice *parent) override
 
void End () override
 
void SetClipRect (const QRect &clipRect) override
 
void SetClipRegion (const QRegion &region) override
 
void Clear (QPaintDevice *device, const QRegion &region) override
 
void DrawImage (const QRect &r, MythImage *im, const QRect &src, int alpha) override
 
void DrawText (const QRect &r, const QString &msg, int flags, const MythFontProperties &font, int alpha, const QRect &boundRect) override
 
void DrawRect (const QRect &area, const QBrush &fillBrush, const QPen &linePen, int alpha) override
 
void DrawRoundRect (const QRect &area, int cornerRadius, const QBrush &fillBrush, const QPen &linePen, int alpha) override
 
void DrawEllipse (const QRect &area, const QBrush &fillBrush, const QPen &linePen, int alpha) override
 
- Public Member Functions inherited from MythPainter
 MythPainter ()
 
virtual ~MythPainter ()=default
 MythPainter destructor. More...
 
virtual void FreeResources (void)
 
QPaintDevice * GetParent (void)
 
void DrawImage (int x, int y, MythImage *im, int alpha)
 
void DrawImage (const QPoint &topLeft, MythImage *im, int alph)
 
virtual void DrawTextLayout (const QRect &canvasRect, const LayoutVector &layouts, const FormatVector &formats, const MythFontProperties &font, int alpha, const QRect &destRect)
 
virtual void PushTransformation (const UIEffects &zoom, QPointF center=QPointF())
 
virtual void PopTransformation (void)
 
MythImageGetFormatImage ()
 Returns a blank reference counted image in the format required for the Draw functions for this painter. More...
 
void DeleteFormatImage (MythImage *im)
 
void SetDebugMode (bool showBorders, bool showNames)
 
bool ShowBorders (void)
 
bool ShowTypeNames (void)
 
void SetMaximumCacheSizes (int hardware, int software)
 

Protected Member Functions

MythImageGetFormatImagePriv (void) override
 Creates a reference counted image, call DecrRef() to delete. More...
 
void DeleteFormatImagePriv (MythImage *) override
 
void CheckPaintMode (const QRect &area)
 
- Protected Member Functions inherited from MythPainter
void DrawTextPriv (MythImage *im, const QString &msg, int flags, const QRect &r, const MythFontProperties &font)
 
void DrawRectPriv (MythImage *im, const QRect &area, int radius, int ellipse, const QBrush &fillBrush, const QPen &linePen)
 
MythImageGetImageFromString (const QString &msg, int flags, const QRect &r, const MythFontProperties &font)
 
MythImageGetImageFromTextLayout (const LayoutVector &layouts, const FormatVector &formats, const MythFontProperties &font, QRect &canvas, QRect &dest)
 
MythImageGetImageFromRect (const QRect &area, int radius, int ellipse, const QBrush &fillBrush, const QPen &linePen)
 
void ExpireImages (int64_t max=0)
 
virtual void Teardown (void)
 
void CheckFormatImage (MythImage *im)
 

Protected Attributes

QPainter * m_painter {nullptr}
 
QRegion m_clipRegion
 
QRegion m_paintedRegion
 
bool m_copy {false}
 
- Protected Attributes inherited from MythPainter
QPaintDevice * m_Parent {nullptr}
 
int m_HardwareCacheSize {0}
 
int m_MaxHardwareCacheSize
 

Detailed Description

Definition at line 17 of file mythpainter_qimage.h.

Constructor & Destructor Documentation

◆ MythQImagePainter()

MythQImagePainter::MythQImagePainter ( )
inline

Definition at line 20 of file mythpainter_qimage.h.

◆ ~MythQImagePainter()

MythQImagePainter::~MythQImagePainter ( )

Definition at line 13 of file mythpainter_qimage.cpp.

Member Function Documentation

◆ GetName()

QString MythQImagePainter::GetName ( void  )
inlineoverridevirtual

Implements MythPainter.

Reimplemented in MythYUVAPainter.

Definition at line 23 of file mythpainter_qimage.h.

◆ SupportsAnimation()

bool MythQImagePainter::SupportsAnimation ( void  )
inlineoverridevirtual

Implements MythPainter.

Definition at line 25 of file mythpainter_qimage.h.

◆ SupportsAlpha()

bool MythQImagePainter::SupportsAlpha ( void  )
inlineoverridevirtual

Implements MythPainter.

Definition at line 27 of file mythpainter_qimage.h.

◆ SupportsClipping()

bool MythQImagePainter::SupportsClipping ( void  )
inlineoverridevirtual

Implements MythPainter.

Definition at line 29 of file mythpainter_qimage.h.

◆ Begin()

void MythQImagePainter::Begin ( QPaintDevice *  parent)
overridevirtual

Reimplemented from MythPainter.

Definition at line 18 of file mythpainter_qimage.cpp.

◆ End()

void MythQImagePainter::End ( void  )
overridevirtual

Reimplemented from MythPainter.

Definition at line 66 of file mythpainter_qimage.cpp.

◆ SetClipRect()

void MythQImagePainter::SetClipRect ( const QRect &  clipRect)
overridevirtual

Reimplemented from MythPainter.

Definition at line 77 of file mythpainter_qimage.cpp.

Referenced by Begin().

◆ SetClipRegion()

void MythQImagePainter::SetClipRegion ( const QRegion &  region)
overridevirtual

Reimplemented from MythPainter.

Definition at line 95 of file mythpainter_qimage.cpp.

◆ Clear()

void MythQImagePainter::Clear ( QPaintDevice *  device,
const QRegion &  region 
)
overridevirtual

Reimplemented from MythPainter.

Definition at line 110 of file mythpainter_qimage.cpp.

Referenced by VideoOutput::DisplayOSD().

◆ DrawImage()

void MythQImagePainter::DrawImage ( const QRect &  r,
MythImage im,
const QRect &  src,
int  alpha 
)
overridevirtual

Implements MythPainter.

Reimplemented in MythYUVAPainter.

Definition at line 143 of file mythpainter_qimage.cpp.

Referenced by MythYUVAPainter::DrawImage().

◆ DrawText()

void MythQImagePainter::DrawText ( const QRect &  r,
const QString &  msg,
int  flags,
const MythFontProperties font,
int  alpha,
const QRect &  boundRect 
)
overridevirtual

Reimplemented from MythPainter.

Reimplemented in MythYUVAPainter.

Definition at line 161 of file mythpainter_qimage.cpp.

Referenced by MythYUVAPainter::DrawText().

◆ DrawRect()

void MythQImagePainter::DrawRect ( const QRect &  area,
const QBrush &  fillBrush,
const QPen &  linePen,
int  alpha 
)
overridevirtual

Reimplemented from MythPainter.

Reimplemented in MythYUVAPainter.

Definition at line 168 of file mythpainter_qimage.cpp.

Referenced by MythYUVAPainter::DrawRect().

◆ DrawRoundRect()

void MythQImagePainter::DrawRoundRect ( const QRect &  area,
int  cornerRadius,
const QBrush &  fillBrush,
const QPen &  linePen,
int  alpha 
)
overridevirtual

Reimplemented from MythPainter.

Reimplemented in MythYUVAPainter.

Definition at line 174 of file mythpainter_qimage.cpp.

Referenced by MythYUVAPainter::DrawRoundRect().

◆ DrawEllipse()

void MythQImagePainter::DrawEllipse ( const QRect &  area,
const QBrush &  fillBrush,
const QPen &  linePen,
int  alpha 
)
overridevirtual

Reimplemented from MythPainter.

Reimplemented in MythYUVAPainter.

Definition at line 181 of file mythpainter_qimage.cpp.

Referenced by MythYUVAPainter::DrawEllipse().

◆ GetFormatImagePriv()

MythImage* MythQImagePainter::GetFormatImagePriv ( void  )
inlineoverrideprotectedvirtual

Creates a reference counted image, call DecrRef() to delete.

Implements MythPainter.

Definition at line 53 of file mythpainter_qimage.h.

◆ DeleteFormatImagePriv()

void MythQImagePainter::DeleteFormatImagePriv ( MythImage )
inlineoverrideprotectedvirtual

Implements MythPainter.

Definition at line 55 of file mythpainter_qimage.h.

◆ CheckPaintMode()

void MythQImagePainter::CheckPaintMode ( const QRect &  area)
protected

Definition at line 36 of file mythpainter_qimage.cpp.

Referenced by DrawImage().

Member Data Documentation

◆ m_painter

QPainter* MythQImagePainter::m_painter {nullptr}
protected

Definition at line 59 of file mythpainter_qimage.h.

Referenced by Begin(), CheckPaintMode(), DrawImage(), End(), SetClipRect(), and SetClipRegion().

◆ m_clipRegion

QRegion MythQImagePainter::m_clipRegion
protected

Definition at line 60 of file mythpainter_qimage.h.

Referenced by Begin(), SetClipRect(), and SetClipRegion().

◆ m_paintedRegion

QRegion MythQImagePainter::m_paintedRegion
protected

Definition at line 61 of file mythpainter_qimage.h.

Referenced by Begin(), and CheckPaintMode().

◆ m_copy

bool MythQImagePainter::m_copy {false}
protected

Definition at line 62 of file mythpainter_qimage.h.

Referenced by Begin(), and CheckPaintMode().


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