ntp
20th June 2008, 19:53
I think I am asking for too much but I would like to have a rounded dialog that keeps its titlebar. I saw the great code in
http://www.qtcentre.org/forum/f-qt-programming-2/t-toplevel-widget-with-rounded-corners-3205.html
which gives me a nice rounded dialog but I see that I lose the titlebar. I create it very simply:
in RoundedTest.h:
RoundedTest(QWidget *parent = 0, Qt::WFlags flags = 0);
in RoundedTest.cpp:
RoundedTest::RoundedTest(QWidget *parent, Qt::WFlags flags)
: QDialog(parent, flags)
{
setupUi(this);
}
and created with:
RoundedTest w;
I tried forcing the title bar by passing in Qt::Window or Qt:: Dialog as the flag but that didn't make a difference. I think that I am going to need to make my own close/minimize button and also interpret mouse events to do the move but if I can the dialog do it for me, that would be better.
http://www.qtcentre.org/forum/f-qt-programming-2/t-toplevel-widget-with-rounded-corners-3205.html
which gives me a nice rounded dialog but I see that I lose the titlebar. I create it very simply:
in RoundedTest.h:
RoundedTest(QWidget *parent = 0, Qt::WFlags flags = 0);
in RoundedTest.cpp:
RoundedTest::RoundedTest(QWidget *parent, Qt::WFlags flags)
: QDialog(parent, flags)
{
setupUi(this);
}
and created with:
RoundedTest w;
I tried forcing the title bar by passing in Qt::Window or Qt:: Dialog as the flag but that didn't make a difference. I think that I am going to need to make my own close/minimize button and also interpret mouse events to do the move but if I can the dialog do it for me, that would be better.