Hey,
is there a way to only draw the outline of a QWidget? I tried to find a example, but could not find one yet.
I want only to draw a circle with no fill? The innercircle should be transparent!
Any clues about that?
Thanks in advance
Hey,
is there a way to only draw the outline of a QWidget? I tried to find a example, but could not find one yet.
I want only to draw a circle with no fill? The innercircle should be transparent!
Any clues about that?
Thanks in advance
Hey,
thanks for your answer, but i am pretty sure that is not that easy.
I want a QWidget, with an appearance of only an outline.
Nothing else then the circumference should be visible. No Background, and the inner circle should alos be transparent, e.g.
show the desktop of the os, or what ever is under the widget.
I am pretty sure, it can be done with setMask().
But i still cannot get it.
Anyone with a good example for making a QWidget with a custom shape as appearance?
Thanks in advance,
Quite apart from the Shaped Clock Example that ships with Qt... this works fine here:
Qt Code:
{ Q_OBJECT public: { resize(400, 400); painter.fillRect(pixmap.rect(), Qt::color0); painter.end(); setMask(pixmap); } };To copy to clipboard, switch view to plain text mode
lanz (17th May 2013)
I'm sure it is as easy as clearly expressing your goal. Read your original post again and see if anyone can understand from it what you want.
Even what you posted here is not that clear, look:
QWidget is blank.I want a QWidget, with an appearance of only an outline.
QWidget is blank, it has no circumference visible.Nothing else then the circumference should be visible.
set a transparent brush.No Background
What inner circle?and the inner circle should alos be transparent
Maybe, hard to say without knowing what you want to do. I would rather put my money on TranslucentBackground attribute.I am pretty sure, it can be done with setMask().
Bookmarks