MCPcopy Create free account
hub / github.com/baldurk/renderdoc / paintEvent

Method paintEvent

qrenderdoc/Widgets/Extended/RDLabel.cpp:204–222  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

202}
203
204void RDLabel::paintEvent(QPaintEvent *event)
205{
206 QLabel::paintEvent(event);
207
208 if(m_variant.isValid())
209 {
210 QPainter painter(this);
211
212 QPoint pos = mapFromGlobal(QCursor::pos());
213
214 QRect r = rect();
215 r.setLeft(r.left() + contentsMargins().left() + margin());
216 r.setRight(r.right() - contentsMargins().right() - margin());
217
218 RichResourceTextPaint(this, &painter, r, font(), palette(),
219 r.contains(pos) ? QStyle::State_MouseOver : QStyle::State_None, pos,
220 m_variant);
221 }
222}

Callers

nothing calls this directly

Calls 12

paintEventFunction · 0.85
marginFunction · 0.85
RichResourceTextPaintFunction · 0.85
setLeftMethod · 0.80
setRightMethod · 0.80
posFunction · 0.50
rectFunction · 0.50
fontFunction · 0.50
isValidMethod · 0.45
leftMethod · 0.45
rightMethod · 0.45
containsMethod · 0.45

Tested by

no test coverage detected