Important: Please read the Qt Code of Conduct -

ContextMenu walk through QWidget ?

  • The menu is the desktop's menu.
    The QWidget is like draw a border on desktop.

    alt text

  • Lifetime Qt Champion

    You kinda forgot the question.
    but i assume you ask how ?

    Its made via a QRegion/setMask that clips out an area from the widget.
    All the magic happens here.

    void XYGifFrame::resizeEvent(QResizeEvent *)
        QRect rect = this->rect();
        rect.adjust(3, 3, -3, -(ui->content->height() + 5));
        mRecordRect = rect;
        QRegion region(this->rect());
        ui->content->move(width() - ui->content->width() - 3, height() - ui->content->height() - 3);

Log in to reply