Goal
Read, create, and modify annotations and form fields. Fill forms and save.
Tasks
Add annotation FFI: FPDFPage_GetAnnotCount, FPDFPage_GetAnnot, FPDFAnnot_GetSubtype, FPDFAnnot_GetRect, FPDFAnnot_GetStringValue, FPDFAnnot_SetRect, FPDFAnnot_SetStringValue, FPDFPage_CreateAnnot, FPDFPage_RemoveAnnot
Add form FFI: FPDFDOC_InitFormFillEnvironment, FPDFDOC_ExitFormFillEnvironment, FPDFAnnot_GetFormFieldType, FPDFAnnot_GetFormFieldName, FPDFAnnot_GetFormFieldValue, FPDFAnnot_SetFormFieldValue, FPDFAnnot_IsChecked
Implement AnnotationRef, AnnotationType, AnnotationData
Implement annotation read: page_annotations(), annotation_type(), annotation_bounds(), annotation_contents()
Implement annotation write: create_annotation(), set_annotation_contents(), delete_annotation()
Implement form field read: page_form_fields(), form_field_type(), form_field_name(), form_field_value()
Implement form field write: set_form_field_value(), set_form_field_checked()
Integrate form handle into Document drop ordering (form before pages before document)
Tests: read annotations from test PDFs, create annotations, fill form fields, save and verify
Write examples/form_fill.rs
Exit Criterion
Can read, create, and modify annotations. Can fill form fields and save.
Dependencies
Goal
Read, create, and modify annotations and form fields. Fill forms and save.
Tasks
FPDFPage_GetAnnotCount,FPDFPage_GetAnnot,FPDFAnnot_GetSubtype,FPDFAnnot_GetRect,FPDFAnnot_GetStringValue,FPDFAnnot_SetRect,FPDFAnnot_SetStringValue,FPDFPage_CreateAnnot,FPDFPage_RemoveAnnotFPDFDOC_InitFormFillEnvironment,FPDFDOC_ExitFormFillEnvironment,FPDFAnnot_GetFormFieldType,FPDFAnnot_GetFormFieldName,FPDFAnnot_GetFormFieldValue,FPDFAnnot_SetFormFieldValue,FPDFAnnot_IsCheckedAnnotationRef,AnnotationType,AnnotationDatapage_annotations(),annotation_type(),annotation_bounds(),annotation_contents()create_annotation(),set_annotation_contents(),delete_annotation()page_form_fields(),form_field_type(),form_field_name(),form_field_value()set_form_field_value(),set_form_field_checked()Documentdrop ordering (form before pages before document)examples/form_fill.rsExit Criterion
Can read, create, and modify annotations. Can fill form fields and save.
Dependencies