-
Notifications
You must be signed in to change notification settings - Fork 95
Switch to QCommandLineParser. #316
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Haha, I like what you do when you're bored ;)
kdwsdl2cpp/src/main.cpp
Outdated
|
||
KWSDL::Compiler compiler; | ||
#if !defined(QT_NO_SSL) | ||
const QString pkcs12File = parser.value(options.pkcs12File), pkcs12Password = parser.value(options.pkcs12Password); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Please split on two separate lines for readability.
d25b49b
to
65bac9c
Compare
Ok, so other than the different formatting for QCommandLineParser's help output, the "Usage" text is currently different. The old text was:
The new text is just:
Are you happy with this, or do you want any changes? |
Good point, it makes the main modes of operations quite hidden compared to before. |
Correct. I was thinking:
Which results in:
I was also wondering what the "generic Qt options" were. The only one that gets added with --help-all is --qmljsdebugger. Any idea why a qml option is getting added for a non gui app? |
Hmm, because the code for it is in QCoreApplicationPrivate...
|
I did that in https://codereview.qt-project.org/c/qt/qtbase/+/261733 because the code that handles that option is actually in QCoreApplication (and that's documented in the QCoreApplication class documentation: I see. The parsing is in QCoreApplication, and then it's used by qtdeclarative/src/qml/debugger/qqmldebugconnector.cpp which is a core-only library. Really just the QML engine, nothing related to UI. |
Ok I didn't realise it was possible to use Qml in a console application, but I suppose that is what qbs is/was? |
Right, good example. |
I was bored. @dfaure-kdab you only have yourself to blame for this pull request:
#224 (comment)