MCPcopy Create free account
hub / github.com/Robotips/uConfig / paint

Method paint

src/pdf_extract/pdfdebugwidget/pdfdebugitemtextbox.cpp:22–40  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

20}
21
22void PdfDebugItemTextBox::paint(QPainter *painter, const QStyleOptionGraphicsItem *option, QWidget *widget)
23{
24 Q_UNUSED(option)
25 Q_UNUSED(widget)
26
27 switch (_textBox->type())
28 {
29 case PDFTextBox::Text:
30 painter->setPen(QPen(QColor(255, 255, 0, 128), 1));
31 break;
32 case PDFTextBox::SubText:
33 painter->setPen(QPen(QColor(0, 255, 0, 128), 0.5));
34 break;
35 case PDFTextBox::Pad:
36 painter->setPen(QPen(QColor(255, 0, 0, 128), 1));
37 break;
38 }
39 painter->drawRect(textBox()->boundingRect());
40}

Callers

nothing calls this directly

Calls 2

typeMethod · 0.45
boundingRectMethod · 0.45

Tested by

no test coverage detected