INNER CODE UNIT · Python

s

pairinteraction/pairinteraction · src/pairinteraction_gui/app.py:95

    s = size / 19.0

    def tx(x: float) -> float:
        return (x + 2.0) * s

    def ty(y: float) -> float:
        return (16.0 - y) * s

    painter.save()
    painter.setRenderHint(QPainter.RenderHint.Antialiasing)
    painter.setClipRect(QRectF(0.0, 0.0, float(size), float(size)))

    # White rounded background
    painter.setPen(Qt.PenStyle.NoPen)
    painter.setBrush(QColor("white"))
    painter.drawRoundedRect(QRectF(0.0, 0.0, float(size), float(size)), 4.0 * s, 4.0 * s)

    # Thick round-capped pen

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…