aboutsummaryrefslogtreecommitdiffstats
path: root/examples/pdf-set-form-values.cc
diff options
context:
space:
mode:
Diffstat (limited to 'examples/pdf-set-form-values.cc')
-rw-r--r--examples/pdf-set-form-values.cc14
1 files changed, 7 insertions, 7 deletions
diff --git a/examples/pdf-set-form-values.cc b/examples/pdf-set-form-values.cc
index a1a19db1..810b9fa3 100644
--- a/examples/pdf-set-form-values.cc
+++ b/examples/pdf-set-form-values.cc
@@ -38,7 +38,7 @@ main(int argc, char* argv[])
qpdf.processFile(infilename);
// We will iterate through form fields by starting at the page level and looking at each
- // field for each page. We could also called QPDFAcroFormDocumentHelper::getFormFields to
+ // field for each page. We could also call QPDFAcroFormDocumentHelper::getFormFields to
// iterate at the field level, but doing it as below illustrates how we can map from
// annotations to fields.
@@ -51,12 +51,12 @@ main(int argc, char* argv[])
// value.
QPDFFormFieldObjectHelper ffh = afdh.getFieldForAnnotation(annot);
if (ffh.getFieldType() == "/Tx") {
- // Set the value. Passing false as the second value prevents qpdf from setting
- // /NeedAppearances to true (but will not turn it off if it's already on), so we
- // call generateAppearance after setting the value. You may or may not want to
- // do this depending on whether the appearance streams generated by qpdf are
- // good enough for your purposes. For additional details, please see comments in
- // QPDFFormFieldObjectHelper.hh for this method.
+ // Set the value. Passing false as the second parameter prevents qpdf from
+ // setting /NeedAppearances to true (but will not turn it off if it's already
+ // on), so we call generateAppearance after setting the value. You may or may
+ // not want to do this depending on whether the appearance streams generated by
+ // qpdf are good enough for your purposes. For additional details, please see
+ // comments in QPDFFormFieldObjectHelper.hh for this method.
ffh.setV(value, false);
ffh.generateAppearance(annot);
}