Is the documentation of qtcreator out of date?
-
I am using Qt5.12.6 , but I installed Qt5.13 before, so my qtcreator shows below
Today, I was read the source code of simple browser example. I found that I can use QLayout::setMargin but I could not find this function in the documentation.
what should i do to update my documentation to the same Qt version?
-
"About Qt Creator" tells you about ... Qt Creator. Qt version listed there has no relation to Qt you have installed. It is simply telling you which Qt version was used to compile Qt Creator.
To find out which Qt versions you have, go to Kits section in QtC options, or look it up in the Qt Maintenance Tool.
-
@Mozzie What are you comparing?
Qt Creator is an IDE, you not have to use Qt Creator to build a Qt application.
On your screenshot, you can see that you are using Qt Creator 4.10.2 which has been build with Qt 5.13.2.Please do not mix up:
- Qt Creator version
- Qt Version used to build Qt Creator
- Qt Kit you are using to build your application
-
@Mozzie said in Is the documentation of qtcreator out of date?:
I just want to show you my qt version from my qt creator.
1 instance of Qt Creator can manage many different versions of Qt at the same time.
Example: I can load the source code for 1 project and ask Qt Creator to build it for Qt 5.12.7 LTS and then build it for Qt 5.14.1.
I found that I can use QLayout::setMargin but I could not find this function in the documentation.
QLayout::setMargin()
is obsolete: https://doc.qt.io/qt-5/qlayout-obsolete.html -
@Mozzie said in Is the documentation of qtcreator out of date?:
I just want to show you my qt version from my qt creator
That version is completely irrelevant. It just tells you which version was used to build QtCreator. You need to understand that QtCreator is a Qt application and "About QtCreator" dialog only tells you the version of QtCreator and Qt which was used to build that QtCreator version. It does not mean that you're using same version of Qt for your apps! You can use many different Qt versions in Qt creator.
To check which Qt version you're really using go to "Tools/Options.../Kits" and select the Kit you're using, then you will see the Qt version. -
@JKSH
I know 1 instance of Qt Creator can manage many different versions of Qt at the same time.
but, I just have one version which is Qt5.12.6, 5.13 already have been removed,But my the qt creator's documentation can not show all function of Qt5.12.6
-
-
@Mozzie said in Is the documentation of qtcreator out of date?:
But my the qt creator's documentation can not show all function of Qt5.12.6
Why do you say that it cannot show all functions of Qt 5.12.6?
If it's because
QLayout::setMargins()
is missing, then you should scroll to the top of the QLayout page and click "obsolete members". -
@Mozzie said in Is the documentation of qtcreator out of date?:
but when i followed the symbol to the header of QLayout, this function is not marked as deprecated.
Because it's deprecated since 5.13 and you're using 5.12
-
@Mozzie said in Is the documentation of qtcreator out of date?:
but when i followed the symbol to the header of QLayout, this function is not marked as deprecated.
That's understandable. As @Christian-Ehrlicher said,
QLayout::setMargin()
was deprecated in the header in Qt 5.13. (This was done by Christian, by the way -- thanks for helping to maintain Qt!: https://codereview.qt-project.org/c/qt/qtbase/+/251052 )However, it was marked "obsolete" in the documentation since the very start of Qt 5.0: https://code.qt.io/cgit/qt/qtbase.git/tree/src/widgets/kernel/qlayout.cpp?h=v5.0.0#n348 (probably even earlier) In this case, the header and the documentation were out-of-sync for a long time.