1 By default, that's not a minimize button in the Qt widget in windows, but a help ("?" symbol) button. If I want to add a minimize button for a dialog at the same remove the help symbol. What I should do.
2 Why I write a file in the patten in a console window:
QFile file("C:\abc\test.txt");
it doesn,t work. But it work in this way : QFile file("C:\\abc\\test.txt"); At the same time, I get the file name from QFileDialog::getOpenFileName and do not need to replace '\' with "\\". and it work fine. Why?
3 My code fragment is showed as the following:
It's strange that even I do not click the CheckBox, but it still execute the above code fragment. I try cloudCheckBox->isChecked() instead, I got the same result. Why?Qt Code:
if(cloudCheckBox->checkState()==Qt::Checked); { for(size_t i=9;i<17;++i) { trimCloud(list[i]); } }To copy to clipboard, switch view to plain text mode
By the way, in the constructor function, I set the CheckBox true.
Qt Code:
cloudCheckBox->setChecked(true); windSpeedCheckBox->setChecked(true);To copy to clipboard, switch view to plain text mode
When i run the app, I click to remove the "√".
4 From my perspective, I do think that try my thinking in a console window is very useful. Also because that I don't know how to test my code in a GUI program, it's very trival.
How do you solve this problem?
Thanks! Any relpy is appreciated!
Bookmarks