You are not logged in.


Thursday, June 21st 2012, 7:55am

Displaying help text when the mouse is over pushbutton and lineedit in Qt

I have a pushbutton and a lineedit , and what i want is , when my mouse is over that pushbutton or lineedit a help text(the purpose of that pushbutton and lineedit) shall be shown besides the pushbutton or lineedit. Please give reply soon , i need it urgently .. Thankx in advance ..


Thursday, June 21st 2012, 8:37am

if you are using QtDesigner, you can use for example
ui->pushbutton->setToolTip("Text Text Text"); which is shown right under the push button,
or ui->pushbutton->setStatusTip("Text Text Text"); which shows on the bottom of mainwindow, and same for the lineedit


Tuesday, June 26th 2012, 10:23am

1---In my tool bar one button is there . When i am clicking that button it calls QWhatsThis::enterWhatsThisMode() .
2-- The cursor changes to some red circle kind of thing .
3--I have used lineedit->setWhatsThis(tr("Hello")) . so when the cursor is moving over that lineedit the cursor again changes (arrow +Question)and after clicking that lineedit one helpbox will pop up and the help box disappears once the user perform some action on that UI or press ESC .Then the cursor changes to simple arrow .

NB- lineedit is a object present in that ui file

In between step - 2 to step 3 (mentioned above ) i dont want that red circle cursor . i want my own cursor . but once it passes step 3 the cursor should again changes to simple arrow mark cursor .

or else how to change that red color cursor to a transparent one .

Please do reply soon ..
Thankxx in adv ..

This post has been edited 1 times, last edit by "BibekKumar" (Jun 26th 2012, 10:29am)