What is "statusHint" ?
-
Found this info, now asking what is "statusHint" ?
C++ code example would be nice .QStatusBar
The QStatusBar class provides a horizontal bar suitable for presenting status information, for example a can be hint:
statusBar()->showMessage("Ready");
This snippet will show the message- "Ready" on status bar. You can set property statusHint in any widget.
-
Found this info, now asking what is "statusHint" ?
C++ code example would be nice .QStatusBar
The QStatusBar class provides a horizontal bar suitable for presenting status information, for example a can be hint:
statusBar()->showMessage("Ready");
This snippet will show the message- "Ready" on status bar. You can set property statusHint in any widget.
@AnneRanch said in What is "statusHint" ?:
You can set property statusHint in any widget.
Where in the documentation is this stated?
-
I don't know where this info is from, but I think it was supposed to be statusTip, not statusHint (tip and hint mean the same thing).
It's a string that you can set on any widget. If you place that widget in something with status bar and hover the mouse over it you will see that text on the status bar;Example C++ code:
int main(int argc, char *argv[]) { QApplication a(argc, argv); QMainWindow mainWindow; QStatusBar* statusBar = new QStatusBar(); QTextEdit* someWidget = new QTextEdit(); someWidget->setStatusTip("Hello, I'm an example status tip."); mainWindow.setStatusBar(statusBar); mainWindow.setCentralWidget(someWidget); mainWindow.show(); return a.exec(); } -
After more checking - the example is mixing "tool tip" with something which does not exist.
I am using two ways to verify the "status bar" - "setstatusTip " and "showMessage". -
After more checking - the example is mixing "tool tip" with something which does not exist.
I am using two ways to verify the "status bar" - "setstatusTip " and "showMessage".@AnneRanch Those are 3 different functionalities. Tool tip is a popup text that shows over a widget when you hover over it. Status tip is a similar thing, but instead of a popup it shows on a status bar when widget is a child of QMainWindow that has status bar. showMessage is an on demand way to show an arbitrary text on the status bar whenever you want.