aboutsummaryrefslogtreecommitdiffstats
path: root/libqpdf/QPDF_json.cc
diff options
context:
space:
mode:
Diffstat (limited to 'libqpdf/QPDF_json.cc')
-rw-r--r--libqpdf/QPDF_json.cc24
1 files changed, 24 insertions, 0 deletions
diff --git a/libqpdf/QPDF_json.cc b/libqpdf/QPDF_json.cc
index f90096f5..213aa209 100644
--- a/libqpdf/QPDF_json.cc
+++ b/libqpdf/QPDF_json.cc
@@ -473,6 +473,30 @@ QPDF::JSONReactor::dictionaryItem(std::string const& key, JSON const& value)
QTC::TC("qpdf", "QPDF_json bad json version");
error(value.getStart(), "invalid JSON version (must be 2)");
}
+ } else if (key == "pushedinheritedpageresources") {
+ bool v;
+ if (value.getBool(v)) {
+ if ((!this->must_be_complete) && v) {
+ this->pdf.pushInheritedAttributesToPage();
+ }
+ } else {
+ QTC::TC("qpdf", "QPDF_json bad pushedinheritedpageresources");
+ error(
+ value.getStart(),
+ "pushedinheritedpageresources must be a boolean");
+ }
+ } else if (key == "calledgetallpages") {
+ bool v;
+ if (value.getBool(v)) {
+ if ((!this->must_be_complete) && v) {
+ this->pdf.getAllPages();
+ }
+ } else {
+ QTC::TC("qpdf", "QPDF_json bad calledgetallpages");
+ error(
+ value.getStart(),
+ "calledgetallpages must be a boolean");
+ }
} else {
// ignore unknown keys for forward compatibility and to
// skip keys we don't care about like "maxobjectid".