[FrameSvg] Rename insetMargin to inset

This commit is contained in:
Mikel Johnson 2020-12-02 11:24:03 +03:00
parent 1be527bd27
commit 0de09e8825
4 changed files with 9 additions and 9 deletions

View File

@ -178,7 +178,7 @@ qreal FrameSvgItemMargins::left() const
if (m_fixed) {
return m_frameSvg->fixedMarginSize(Types::LeftMargin);
} else if(m_inset){
return m_frameSvg->insetMarginSize(Types::LeftMargin);
return m_frameSvg->insetSize(Types::LeftMargin);
} else {
return m_frameSvg->marginSize(Types::LeftMargin);
}
@ -189,7 +189,7 @@ qreal FrameSvgItemMargins::top() const
if (m_fixed) {
return m_frameSvg->fixedMarginSize(Types::TopMargin);
} else if(m_inset){
return m_frameSvg->insetMarginSize(Types::TopMargin);
return m_frameSvg->insetSize(Types::TopMargin);
} else {
return m_frameSvg->marginSize(Types::TopMargin);
}
@ -200,7 +200,7 @@ qreal FrameSvgItemMargins::right() const
if (m_fixed) {
return m_frameSvg->fixedMarginSize(Types::RightMargin);
} else if(m_inset){
return m_frameSvg->insetMarginSize(Types::RightMargin);
return m_frameSvg->insetSize(Types::RightMargin);
} else {
return m_frameSvg->marginSize(Types::RightMargin);
}
@ -211,7 +211,7 @@ qreal FrameSvgItemMargins::bottom() const
if (m_fixed) {
return m_frameSvg->fixedMarginSize(Types::BottomMargin);
} else if(m_inset){
return m_frameSvg->insetMarginSize(Types::BottomMargin);
return m_frameSvg->insetSize(Types::BottomMargin);
} else {
return m_frameSvg->marginSize(Types::BottomMargin);
}

View File

@ -139,7 +139,7 @@ class FrameSvgItem : public QQuickItem
Q_PROPERTY(QObject *fixedMargins READ fixedMargins CONSTANT)
/**
* The margins of the inset
* The inset of the frame
* read only
* @see FrameSvgItemMargins
* @since 5.77

View File

@ -218,7 +218,7 @@ qreal FrameSvg::marginSize(const Plasma::Types::MarginEdge edge) const
}
}
qreal FrameSvg::insetMarginSize(const Plasma::Types::MarginEdge edge) const
qreal FrameSvg::insetSize(const Plasma::Types::MarginEdge edge) const
{
if (!d->frame) {
return .0;
@ -296,7 +296,7 @@ void FrameSvg::getFixedMargins(qreal &left, qreal &top, qreal &right, qreal &bot
bottom = d->frame->fixedBottomMargin;
}
void FrameSvg::getInsetMargins(qreal &left, qreal &top, qreal &right, qreal &bottom) const
void FrameSvg::getInset(qreal &left, qreal &top, qreal &right, qreal &bottom) const
{
if (!d->frame || d->frame->noBorderPadding) {
left = top = right = bottom = 0;

View File

@ -168,7 +168,7 @@ public:
* @return the margin size
* @since 5.77
*/
Q_INVOKABLE qreal insetMarginSize(const Plasma::Types::MarginEdge edge) const;
Q_INVOKABLE qreal insetSize(const Plasma::Types::MarginEdge edge) const;
/**
* Convenience method that extracts the size of the four inset margins
@ -179,7 +179,7 @@ public:
* @param bottom bottom margin size
* @since 5.77
*/
Q_INVOKABLE void getInsetMargins(qreal &left, qreal &top, qreal &right, qreal &bottom) const;
Q_INVOKABLE void getInset(qreal &left, qreal &top, qreal &right, qreal &bottom) const;
/**
* @return the rectangle of the center element, taking the margins into account.