开发者

How to draw rectangle using Qt to Xlib window

Let say that i have id of another Xlib window and i want to draw over this window rectangle. Is there way to to draw it using Qt? I found on solution but it doesn't work for me:

QPixmap pix = QPixmap::fromX11Pixmap(wId, QPixmap::ExplicitlyShared);
pix.fill(QColor::fromRgb(255,255,255));

I expect it'll fill window with white开发者_如何学JAVA color, but it doesn't.


You could embed this window, place an invisible window on top and render into this invisible window. The effect would be the same : a rectangle over the window.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜