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

Object for displaying Dynamic Line Art. More...

#include <mhi.h>

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

Public Member Functions

 MHIDLA (MHIContext *parent, bool isBoxed, MHRgba lineColour, MHRgba fillColour)
 
void Draw (int x, int y) override
 Draw the completed drawing onto the display. More...
 
void SetSize (int width, int height) override
 Set the box size. Also clears the drawing. More...
 
void SetLineSize (int width) override
 
void SetLineColour (MHRgba colour) override
 
void SetFillColour (MHRgba colour) override
 
void Clear (void) override
 Clear the drawing. More...
 
void DrawLine (int x1, int y1, int x2, int y2) override
 
void DrawBorderedRectangle (int x, int y, int width, int height) override
 
void DrawOval (int x, int y, int width, int height) override
 
void DrawArcSector (int x, int y, int width, int height, int start, int arc, bool isSector) override
 
void DrawPoly (bool isFilled, const MHPointVec &xArray, const MHPointVec &yArray) override
 
- Public Member Functions inherited from MHDLADisplay
virtual ~MHDLADisplay ()=default
 

Protected Member Functions

void DrawRect (int x, int y, int width, int height, MHRgba colour)
 
void DrawLineSub (int x1, int y1, int x2, int y2, bool swapped)
 

Protected Attributes

MHIContextm_parent {nullptr}
 
QImage m_image
 
int m_width {0}
 Width of the drawing. More...
 
int m_height {0}
 Height of the drawing. More...
 
bool m_boxed
 Does it have a border? More...
 
MHRgba m_boxLineColour
 Line colour for the background. More...
 
MHRgba m_boxFillColour
 Fill colour for the background. More...
 
MHRgba m_lineColour
 Current line colour. More...
 
MHRgba m_fillColour
 Current fill colour. More...
 
int m_lineWidth {0}
 Current line width. More...
 

Detailed Description

Object for displaying Dynamic Line Art.

Definition at line 315 of file mhi.h.

Constructor & Destructor Documentation

◆ MHIDLA()

MHIDLA::MHIDLA ( MHIContext parent,
bool  isBoxed,
MHRgba  lineColour,
MHRgba  fillColour 
)
inline

Definition at line 318 of file mhi.h.

Member Function Documentation

◆ Draw()

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

Draw the completed drawing onto the display.

Implements MHDLADisplay.

Definition at line 1502 of file mhi.cpp.

◆ SetSize()

void MHIDLA::SetSize ( int  width,
int  height 
)
inlineoverridevirtual

Set the box size. Also clears the drawing.

Implements MHDLADisplay.

Definition at line 325 of file mhi.h.

◆ SetLineSize()

void MHIDLA::SetLineSize ( int  width)
inlineoverridevirtual

Implements MHDLADisplay.

Definition at line 331 of file mhi.h.

◆ SetLineColour()

void MHIDLA::SetLineColour ( MHRgba  colour)
inlineoverridevirtual

Implements MHDLADisplay.

Definition at line 333 of file mhi.h.

◆ SetFillColour()

void MHIDLA::SetFillColour ( MHRgba  colour)
inlineoverridevirtual

Implements MHDLADisplay.

Definition at line 335 of file mhi.h.

◆ Clear()

void MHIDLA::Clear ( void  )
overridevirtual

Clear the drawing.

Implements MHDLADisplay.

Definition at line 1490 of file mhi.cpp.

Referenced by SetSize().

◆ DrawLine()

void MHIDLA::DrawLine ( int  x1,
int  y1,
int  x2,
int  y2 
)
overridevirtual

Implements MHDLADisplay.

Definition at line 1550 of file mhi.cpp.

Referenced by DrawPoly().

◆ DrawBorderedRectangle()

void MHIDLA::DrawBorderedRectangle ( int  x,
int  y,
int  width,
int  height 
)
overridevirtual

Implements MHDLADisplay.

Definition at line 1646 of file mhi.cpp.

◆ DrawOval()

void MHIDLA::DrawOval ( int  x,
int  y,
int  width,
int  height 
)
overridevirtual

Implements MHDLADisplay.

Definition at line 1678 of file mhi.cpp.

◆ DrawArcSector()

void MHIDLA::DrawArcSector ( int  x,
int  y,
int  width,
int  height,
int  start,
int  arc,
bool  isSector 
)
overridevirtual

Implements MHDLADisplay.

Definition at line 1684 of file mhi.cpp.

◆ DrawPoly()

void MHIDLA::DrawPoly ( bool  isFilled,
const MHPointVec xArray,
const MHPointVec yArray 
)
overridevirtual

Implements MHDLADisplay.

Definition at line 1696 of file mhi.cpp.

◆ DrawRect()

void MHIDLA::DrawRect ( int  x,
int  y,
int  width,
int  height,
MHRgba  colour 
)
protected

Definition at line 1448 of file mhi.cpp.

Referenced by Clear(), and DrawBorderedRectangle().

◆ DrawLineSub()

void MHIDLA::DrawLineSub ( int  x1,
int  y1,
int  x2,
int  y2,
bool  swapped 
)
protected

Definition at line 1572 of file mhi.cpp.

Referenced by DrawLine().

Member Data Documentation

◆ m_parent

MHIContext* MHIDLA::m_parent {nullptr}
protected

Definition at line 354 of file mhi.h.

Referenced by Draw().

◆ m_image

QImage MHIDLA::m_image
protected

Definition at line 355 of file mhi.h.

Referenced by Clear(), Draw(), DrawLineSub(), DrawPoly(), and DrawRect().

◆ m_width

int MHIDLA::m_width {0}
protected

Width of the drawing.

Definition at line 356 of file mhi.h.

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

◆ m_height

int MHIDLA::m_height {0}
protected

Height of the drawing.

Definition at line 357 of file mhi.h.

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

◆ m_boxed

bool MHIDLA::m_boxed
protected

Does it have a border?

Definition at line 358 of file mhi.h.

Referenced by Draw().

◆ m_boxLineColour

MHRgba MHIDLA::m_boxLineColour
protected

Line colour for the background.

Definition at line 359 of file mhi.h.

Referenced by Draw().

◆ m_boxFillColour

MHRgba MHIDLA::m_boxFillColour
protected

Fill colour for the background.

Definition at line 360 of file mhi.h.

Referenced by Draw().

◆ m_lineColour

MHRgba MHIDLA::m_lineColour
protected

Current line colour.

Definition at line 361 of file mhi.h.

Referenced by DrawBorderedRectangle(), DrawLineSub(), and SetLineColour().

◆ m_fillColour

MHRgba MHIDLA::m_fillColour
protected

Current fill colour.

Definition at line 362 of file mhi.h.

Referenced by DrawBorderedRectangle(), DrawPoly(), and SetFillColour().

◆ m_lineWidth

int MHIDLA::m_lineWidth {0}
protected

Current line width.

Definition at line 363 of file mhi.h.

Referenced by Draw(), DrawBorderedRectangle(), DrawLineSub(), and SetLineSize().


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