miqt/qt6/gen_qcommandlineparser.h

66 lines
3.8 KiB
C
Raw Permalink Normal View History

#pragma once
#ifndef MIQT_QT6_GEN_QCOMMANDLINEPARSER_H
#define MIQT_QT6_GEN_QCOMMANDLINEPARSER_H
2024-10-20 05:21:03 +00:00
#include <stdbool.h>
#include <stddef.h>
#include <stdint.h>
#pragma GCC diagnostic ignored "-Wdeprecated-declarations"
#include "../libmiqt/libmiqt.h"
#ifdef __cplusplus
extern "C" {
#endif
#ifdef __cplusplus
class QCommandLineOption;
class QCommandLineParser;
class QCoreApplication;
#else
typedef struct QCommandLineOption QCommandLineOption;
typedef struct QCommandLineParser QCommandLineParser;
typedef struct QCoreApplication QCoreApplication;
#endif
2024-12-07 04:15:57 +00:00
QCommandLineParser* QCommandLineParser_new();
2024-10-20 05:21:03 +00:00
struct miqt_string QCommandLineParser_Tr(const char* sourceText);
void QCommandLineParser_SetSingleDashWordOptionMode(QCommandLineParser* self, int parsingMode);
void QCommandLineParser_SetOptionsAfterPositionalArgumentsMode(QCommandLineParser* self, int mode);
bool QCommandLineParser_AddOption(QCommandLineParser* self, QCommandLineOption* commandLineOption);
bool QCommandLineParser_AddOptions(QCommandLineParser* self, struct miqt_array /* of QCommandLineOption* */ options);
2024-10-20 05:21:03 +00:00
QCommandLineOption* QCommandLineParser_AddVersionOption(QCommandLineParser* self);
QCommandLineOption* QCommandLineParser_AddHelpOption(QCommandLineParser* self);
void QCommandLineParser_SetApplicationDescription(QCommandLineParser* self, struct miqt_string description);
struct miqt_string QCommandLineParser_ApplicationDescription(const QCommandLineParser* self);
void QCommandLineParser_AddPositionalArgument(QCommandLineParser* self, struct miqt_string name, struct miqt_string description);
void QCommandLineParser_ClearPositionalArguments(QCommandLineParser* self);
void QCommandLineParser_Process(QCommandLineParser* self, struct miqt_array /* of struct miqt_string */ arguments);
2024-10-20 05:21:03 +00:00
void QCommandLineParser_ProcessWithApp(QCommandLineParser* self, QCoreApplication* app);
bool QCommandLineParser_Parse(QCommandLineParser* self, struct miqt_array /* of struct miqt_string */ arguments);
2024-10-20 05:21:03 +00:00
struct miqt_string QCommandLineParser_ErrorText(const QCommandLineParser* self);
bool QCommandLineParser_IsSet(const QCommandLineParser* self, struct miqt_string name);
struct miqt_string QCommandLineParser_Value(const QCommandLineParser* self, struct miqt_string name);
struct miqt_array /* of struct miqt_string */ QCommandLineParser_Values(const QCommandLineParser* self, struct miqt_string name);
2024-10-20 05:21:03 +00:00
bool QCommandLineParser_IsSetWithOption(const QCommandLineParser* self, QCommandLineOption* option);
struct miqt_string QCommandLineParser_ValueWithOption(const QCommandLineParser* self, QCommandLineOption* option);
struct miqt_array /* of struct miqt_string */ QCommandLineParser_ValuesWithOption(const QCommandLineParser* self, QCommandLineOption* option);
struct miqt_array /* of struct miqt_string */ QCommandLineParser_PositionalArguments(const QCommandLineParser* self);
struct miqt_array /* of struct miqt_string */ QCommandLineParser_OptionNames(const QCommandLineParser* self);
struct miqt_array /* of struct miqt_string */ QCommandLineParser_UnknownOptionNames(const QCommandLineParser* self);
2024-10-20 05:21:03 +00:00
void QCommandLineParser_ShowVersion(QCommandLineParser* self);
void QCommandLineParser_ShowHelp(QCommandLineParser* self);
struct miqt_string QCommandLineParser_HelpText(const QCommandLineParser* self);
struct miqt_string QCommandLineParser_Tr2(const char* sourceText, const char* disambiguation);
struct miqt_string QCommandLineParser_Tr3(const char* sourceText, const char* disambiguation, int n);
void QCommandLineParser_AddPositionalArgument3(QCommandLineParser* self, struct miqt_string name, struct miqt_string description, struct miqt_string syntax);
void QCommandLineParser_ShowHelp1(QCommandLineParser* self, int exitCode);
2024-11-19 06:29:06 +00:00
void QCommandLineParser_Delete(QCommandLineParser* self, bool isSubclass);
2024-10-20 05:21:03 +00:00
#ifdef __cplusplus
} /* extern C */
#endif
#endif