Sambu
3rd November 2011, 06:46
Hi all,
i want to develope the round ring button.
i am able to create the round button with Push button and Style sheet.
Code as follows:
---------------
QPushButton *pushButton;
pushButton = new QPushButton(this);
pushButton->setObjectName(QString::fromUtf8("pushButton"));
pushButton->setGeometry(QRect(40, 170, 90, 90));
pushButton->setStyleSheet(QString::fromUtf8("border-radius: 45px ;\n"
"border:7px solid gray;\n"
"\n"""));
-------------
but, problem here, if i prees the out side of the ring shape button also ,it is takeing as button press.
how to make mask the out side the ring shape. even user click the out of the ring it show not take it as click/press event.
Can any one guide me on the same.
Regards,
sambu.
i want to develope the round ring button.
i am able to create the round button with Push button and Style sheet.
Code as follows:
---------------
QPushButton *pushButton;
pushButton = new QPushButton(this);
pushButton->setObjectName(QString::fromUtf8("pushButton"));
pushButton->setGeometry(QRect(40, 170, 90, 90));
pushButton->setStyleSheet(QString::fromUtf8("border-radius: 45px ;\n"
"border:7px solid gray;\n"
"\n"""));
-------------
but, problem here, if i prees the out side of the ring shape button also ,it is takeing as button press.
how to make mask the out side the ring shape. even user click the out of the ring it show not take it as click/press event.
Can any one guide me on the same.
Regards,
sambu.