#include <roundedrectangle.h>

Inheritance diagram for dnai::views::RoundedRectangle:
Inheritance graph
Collaboration diagram for dnai::views::RoundedRectangle:
Collaboration graph

Signals

void topLeftChanged (bool value)
 
void topRightChanged (bool value)
 
void bottomLeftChanged (bool value)
 
void bottomRightChanged (bool value)
 
void roundedSegmentsChanged (uint segments)
 
- Signals inherited from dnai::views::CustomShape
void radiusChanged (qreal radius)
 
void borderWidthChanged (qreal w)
 
void fillColorChanged (const QColor &color)
 
void borderColorChanged (const QColor &color)
 

Public Member Functions

 RoundedRectangle (QQuickItem *parent=nullptr)
 
virtual QSGNode * updatePaintNode (QSGNode *, UpdatePaintNodeData *) override
 Override updatePaintNode and draw a magnificient rounded rectangle. More...
 
bool topLeft () const
 
bool topRight () const
 
bool bottomLeft () const
 
bool bottomRight () const
 
int roundedSegments () const
 
void setTopLeft (bool value)
 
void setTopRight (bool value)
 
void setBottomLeft (bool value)
 
void setBottomRight (bool value)
 
void setRoundedSegments (uint segments)
 
- Public Member Functions inherited from dnai::views::CustomShape
 CustomShape (QQuickItem *parent=nullptr)
 
qreal radius () const
 
qreal borderWidth () const
 
const QColor & fillColor () const
 
const QColor & borderColor () const
 
void setRadius (qreal radius)
 
virtual void setBorderWidth (qreal w)
 
virtual void setFillColor (const QColor &color)
 
virtual void setBorderColor (const QColor &color)
 
void resetRadius ()
 
void resetBorderWidth ()
 
void resetBorderColor ()
 
void resetFillColor ()
 
void resetPos ()
 
void resetShape ()
 

Properties

bool topLeft
 
bool topRight
 
bool bottomLeft
 
bool bottomRight
 
uint roundedSegments
 
- Properties inherited from dnai::views::CustomShape
qreal radius
 
qreal borderWidth
 
QColor fillColor
 
QColor borderColor
 

Private Member Functions

int getNumberRoundedCorner () const
 return the number of rounded corner More...
 

Private Attributes

bool m_topLeft
 
bool m_topRight
 
bool m_bottomLeft
 
bool m_bottomRight
 
uint m_nbSegments
 

Additional Inherited Members

- Protected Attributes inherited from dnai::views::CustomShape
qreal m_radius
 
qreal m_borderWidth
 
QColor m_fillColor
 
QColor m_borderColor
 
qreal m_saveRadius
 
qreal m_saveBorderWidth
 
QColor m_saveFillColor
 
QColor m_saveBorderColor
 
QPointF m_savePos
 

Constructor & Destructor Documentation

dnai::views::RoundedRectangle::RoundedRectangle ( QQuickItem *  parent = nullptr)

Member Function Documentation

bool dnai::views::RoundedRectangle::bottomLeft ( ) const
inline
void dnai::views::RoundedRectangle::bottomLeftChanged ( bool  value)
signal
bool dnai::views::RoundedRectangle::bottomRight ( ) const
inline
void dnai::views::RoundedRectangle::bottomRightChanged ( bool  value)
signal
int dnai::views::RoundedRectangle::getNumberRoundedCorner ( ) const
private

return the number of rounded corner

Returns
int
int dnai::views::RoundedRectangle::roundedSegments ( ) const
inline
void dnai::views::RoundedRectangle::roundedSegmentsChanged ( uint  segments)
signal
void dnai::views::RoundedRectangle::setBottomLeft ( bool  value)
void dnai::views::RoundedRectangle::setBottomRight ( bool  value)
void dnai::views::RoundedRectangle::setRoundedSegments ( uint  segments)
void dnai::views::RoundedRectangle::setTopLeft ( bool  value)
void dnai::views::RoundedRectangle::setTopRight ( bool  value)
bool dnai::views::RoundedRectangle::topLeft ( ) const
inline
void dnai::views::RoundedRectangle::topLeftChanged ( bool  value)
signal
bool dnai::views::RoundedRectangle::topRight ( ) const
inline
void dnai::views::RoundedRectangle::topRightChanged ( bool  value)
signal
QSGNode * dnai::views::RoundedRectangle::updatePaintNode ( QSGNode *  oldNode,
UpdatePaintNodeData *  data 
)
overridevirtual

Override updatePaintNode and draw a magnificient rounded rectangle.

Returns
QSGNode *

Reimplemented from dnai::views::CustomShape.

Member Data Documentation

bool dnai::views::RoundedRectangle::m_bottomLeft
private
bool dnai::views::RoundedRectangle::m_bottomRight
private
uint dnai::views::RoundedRectangle::m_nbSegments
private
bool dnai::views::RoundedRectangle::m_topLeft
private
bool dnai::views::RoundedRectangle::m_topRight
private

Property Documentation

bool dnai::views::RoundedRectangle::bottomLeft
readwrite
bool dnai::views::RoundedRectangle::bottomRight
readwrite
uint dnai::views::RoundedRectangle::roundedSegments
readwrite
bool dnai::views::RoundedRectangle::topLeft
readwrite
bool dnai::views::RoundedRectangle::topRight
readwrite

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