aboutsummaryrefslogtreecommitdiffstats
path: root/include
diff options
context:
space:
mode:
authorJay Berkenbilt <ejb@ql.org>2022-01-06 15:51:34 +0100
committerJay Berkenbilt <ejb@ql.org>2022-01-30 19:11:03 +0100
commitf8eee83515032eca5e50d668ced44194eac6e36e (patch)
treebdbee189756b6f2757cf1ef7d1ffcce19b31113f /include
parent8dcf6da2590633e00fe9d0334692d5ca482e740a (diff)
downloadqpdf-f8eee83515032eca5e50d668ced44194eac6e36e.tar.zst
Expose QPDFArgParser::usage
Diffstat (limited to 'include')
-rw-r--r--include/qpdf/QPDFArgParser.hh7
1 files changed, 6 insertions, 1 deletions
diff --git a/include/qpdf/QPDFArgParser.hh b/include/qpdf/QPDFArgParser.hh
index e5b2c490..24e6ac48 100644
--- a/include/qpdf/QPDFArgParser.hh
+++ b/include/qpdf/QPDFArgParser.hh
@@ -150,6 +150,12 @@ class QPDFArgParser
QPDF_DLL
void insertCompletion(std::string const&);
+ // Throw a Usage exception with the given message. In completion
+ // mode, this just exits to prevent errors from partial commands
+ // or other error messages from messing up completion.
+ QPDF_DLL
+ void usage(std::string const& message);
+
private:
struct OptionEntry
{
@@ -174,7 +180,6 @@ class QPDFArgParser
void argCompletionBash();
void argCompletionZsh();
- void usage(std::string const& message);
void checkCompletion();
void handleArgFileArguments();
void handleBashArguments();