aspose_pdf_cloud 19.11.0 → 20.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/LICENSE +1 -1
- data/README.md +44 -9
- data/aspose_pdf_cloud.gemspec +1 -1
- data/docs/Border.md +14 -0
- data/docs/BorderEffect.md +11 -0
- data/docs/BorderStyle.md +14 -0
- data/docs/Cell.md +3 -0
- data/docs/CheckBoxField.md +2 -1
- data/docs/ChoiceField.md +3 -1
- data/docs/ComboBoxField.md +3 -2
- data/docs/Dash.md +10 -0
- data/docs/DefaultPageConfig.md +10 -0
- data/docs/Direction.md +11 -0
- data/docs/DisplayProperties.md +18 -0
- data/docs/DisplayPropertiesResponse.md +11 -0
- data/docs/Document.md +1 -0
- data/docs/DocumentConfig.md +12 -0
- data/docs/FormField.md +2 -1
- data/docs/ImageFragment.md +15 -0
- data/docs/ListBoxField.md +33 -0
- data/docs/ListBoxFieldResponse.md +11 -0
- data/docs/ListBoxFields.md +10 -0
- data/docs/ListBoxFieldsResponse.md +11 -0
- data/docs/PageLayout.md +16 -0
- data/docs/PageMode.md +15 -0
- data/docs/PdfApi.md +452 -14
- data/docs/RadioButtonField.md +3 -2
- data/docs/RadioButtonOptionField.md +2 -1
- data/docs/SignatureField.md +2 -1
- data/docs/Table.md +1 -0
- data/docs/TextBoxField.md +2 -1
- data/lib/aspose_pdf_cloud.rb +17 -1
- data/lib/aspose_pdf_cloud/api/pdf_api.rb +1375 -72
- data/lib/aspose_pdf_cloud/api_client.rb +2 -2
- data/lib/aspose_pdf_cloud/api_error.rb +1 -1
- data/lib/aspose_pdf_cloud/configuration.rb +1 -1
- data/lib/aspose_pdf_cloud/models/annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/annotation_flags.rb +1 -1
- data/lib/aspose_pdf_cloud/models/annotation_info.rb +1 -1
- data/lib/aspose_pdf_cloud/models/annotation_state.rb +1 -1
- data/lib/aspose_pdf_cloud/models/annotation_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/annotations_info.rb +1 -1
- data/lib/aspose_pdf_cloud/models/annotations_info_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/antialiasing_processing_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/aspose_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/attachment.rb +1 -1
- data/lib/aspose_pdf_cloud/models/attachment_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/attachments.rb +1 -1
- data/lib/aspose_pdf_cloud/models/attachments_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/bookmark.rb +1 -1
- data/lib/aspose_pdf_cloud/models/bookmark_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/bookmarks.rb +1 -1
- data/lib/aspose_pdf_cloud/models/bookmarks_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/border.rb +249 -0
- data/lib/aspose_pdf_cloud/models/border_corner_style.rb +1 -1
- data/lib/aspose_pdf_cloud/models/border_effect.rb +44 -0
- data/lib/aspose_pdf_cloud/models/border_info.rb +1 -1
- data/lib/aspose_pdf_cloud/models/border_style.rb +47 -0
- data/lib/aspose_pdf_cloud/models/box_style.rb +1 -1
- data/lib/aspose_pdf_cloud/models/cap_style.rb +1 -1
- data/lib/aspose_pdf_cloud/models/caption_position.rb +1 -1
- data/lib/aspose_pdf_cloud/models/caret_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/caret_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/caret_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/caret_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/caret_symbol.rb +1 -1
- data/lib/aspose_pdf_cloud/models/cell.rb +37 -5
- data/lib/aspose_pdf_cloud/models/cell_recognized.rb +1 -1
- data/lib/aspose_pdf_cloud/models/check_box_field.rb +12 -7
- data/lib/aspose_pdf_cloud/models/check_box_field_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/check_box_fields.rb +1 -1
- data/lib/aspose_pdf_cloud/models/check_box_fields_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/choice_field.rb +25 -10
- data/lib/aspose_pdf_cloud/models/circle_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/circle_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/circle_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/circle_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/color.rb +1 -1
- data/lib/aspose_pdf_cloud/models/color_depth.rb +1 -1
- data/lib/aspose_pdf_cloud/models/column_adjustment.rb +1 -1
- data/lib/aspose_pdf_cloud/models/combo_box_field.rb +25 -25
- data/lib/aspose_pdf_cloud/models/combo_box_field_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/combo_box_fields.rb +1 -1
- data/lib/aspose_pdf_cloud/models/combo_box_fields_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/common_figure_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/compression_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/crypto_algorithm.rb +1 -1
- data/lib/aspose_pdf_cloud/models/dash.rb +219 -0
- data/lib/aspose_pdf_cloud/models/default_page_config.rb +209 -0
- data/lib/aspose_pdf_cloud/models/direction.rb +44 -0
- data/lib/aspose_pdf_cloud/models/disc_usage.rb +1 -1
- data/lib/aspose_pdf_cloud/models/display_properties.rb +291 -0
- data/lib/aspose_pdf_cloud/models/display_properties_response.rb +224 -0
- data/lib/aspose_pdf_cloud/models/doc_format.rb +1 -1
- data/lib/aspose_pdf_cloud/models/doc_mdp_access_permission_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/doc_recognition_mode.rb +1 -1
- data/lib/aspose_pdf_cloud/models/document.rb +12 -2
- data/lib/aspose_pdf_cloud/models/document_config.rb +234 -0
- data/lib/aspose_pdf_cloud/models/document_page_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/document_pages_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/document_privilege.rb +1 -1
- data/lib/aspose_pdf_cloud/models/document_properties.rb +1 -1
- data/lib/aspose_pdf_cloud/models/document_properties_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/document_property.rb +1 -1
- data/lib/aspose_pdf_cloud/models/document_property_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/document_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/epub_recognition_mode.rb +1 -1
- data/lib/aspose_pdf_cloud/models/error.rb +1 -1
- data/lib/aspose_pdf_cloud/models/error_details.rb +1 -1
- data/lib/aspose_pdf_cloud/models/field.rb +1 -1
- data/lib/aspose_pdf_cloud/models/field_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/field_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/fields.rb +1 -1
- data/lib/aspose_pdf_cloud/models/fields_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/file_attachment_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/file_attachment_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/file_attachment_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/file_attachment_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/file_icon.rb +1 -1
- data/lib/aspose_pdf_cloud/models/file_version.rb +1 -1
- data/lib/aspose_pdf_cloud/models/file_versions.rb +1 -1
- data/lib/aspose_pdf_cloud/models/files_list.rb +1 -1
- data/lib/aspose_pdf_cloud/models/files_upload_result.rb +1 -1
- data/lib/aspose_pdf_cloud/models/font_encoding_rules.rb +1 -1
- data/lib/aspose_pdf_cloud/models/font_saving_modes.rb +1 -1
- data/lib/aspose_pdf_cloud/models/font_styles.rb +1 -1
- data/lib/aspose_pdf_cloud/models/form_field.rb +15 -10
- data/lib/aspose_pdf_cloud/models/free_text_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/free_text_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/free_text_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/free_text_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/free_text_intent.rb +1 -1
- data/lib/aspose_pdf_cloud/models/graph_info.rb +1 -1
- data/lib/aspose_pdf_cloud/models/highlight_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/highlight_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/highlight_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/highlight_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/horizontal_alignment.rb +1 -1
- data/lib/aspose_pdf_cloud/models/html_document_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/html_markup_generation_modes.rb +1 -1
- data/lib/aspose_pdf_cloud/models/image.rb +1 -1
- data/lib/aspose_pdf_cloud/models/image_footer.rb +1 -1
- data/lib/aspose_pdf_cloud/models/image_fragment.rb +283 -0
- data/lib/aspose_pdf_cloud/models/image_header.rb +1 -1
- data/lib/aspose_pdf_cloud/models/image_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/image_src_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/image_stamp.rb +1 -1
- data/lib/aspose_pdf_cloud/models/image_template.rb +1 -1
- data/lib/aspose_pdf_cloud/models/image_templates_request.rb +1 -1
- data/lib/aspose_pdf_cloud/models/images.rb +1 -1
- data/lib/aspose_pdf_cloud/models/images_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/ink_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/ink_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/ink_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/ink_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/justification.rb +1 -1
- data/lib/aspose_pdf_cloud/models/letters_positioning_methods.rb +1 -1
- data/lib/aspose_pdf_cloud/models/line_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/line_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/line_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/line_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/line_ending.rb +1 -1
- data/lib/aspose_pdf_cloud/models/line_intent.rb +1 -1
- data/lib/aspose_pdf_cloud/models/line_spacing.rb +1 -1
- data/lib/aspose_pdf_cloud/models/link.rb +1 -1
- data/lib/aspose_pdf_cloud/models/link_action_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/link_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/link_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/link_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/link_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/link_element.rb +1 -1
- data/lib/aspose_pdf_cloud/models/link_highlighting_mode.rb +1 -1
- data/lib/aspose_pdf_cloud/models/list_box_field.rb +452 -0
- data/lib/aspose_pdf_cloud/models/list_box_field_response.rb +224 -0
- data/lib/aspose_pdf_cloud/models/list_box_fields.rb +213 -0
- data/lib/aspose_pdf_cloud/models/list_box_fields_response.rb +224 -0
- data/lib/aspose_pdf_cloud/models/margin_info.rb +1 -1
- data/lib/aspose_pdf_cloud/models/markup_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/merge_documents.rb +1 -1
- data/lib/aspose_pdf_cloud/models/movie_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/movie_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/movie_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/movie_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/object_exist.rb +1 -1
- data/lib/aspose_pdf_cloud/models/optimize_options.rb +1 -1
- data/lib/aspose_pdf_cloud/models/option.rb +1 -1
- data/lib/aspose_pdf_cloud/models/page.rb +1 -1
- data/lib/aspose_pdf_cloud/models/page_layout.rb +49 -0
- data/lib/aspose_pdf_cloud/models/page_mode.rb +48 -0
- data/lib/aspose_pdf_cloud/models/page_number_stamp.rb +1 -1
- data/lib/aspose_pdf_cloud/models/page_word_count.rb +1 -1
- data/lib/aspose_pdf_cloud/models/pages.rb +1 -1
- data/lib/aspose_pdf_cloud/models/paragraph.rb +1 -1
- data/lib/aspose_pdf_cloud/models/parts_embedding_modes.rb +1 -1
- data/lib/aspose_pdf_cloud/models/pdf_a_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/pdf_page_stamp.rb +1 -1
- data/lib/aspose_pdf_cloud/models/permissions_flags.rb +1 -1
- data/lib/aspose_pdf_cloud/models/point.rb +1 -1
- data/lib/aspose_pdf_cloud/models/poly_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/poly_intent.rb +1 -1
- data/lib/aspose_pdf_cloud/models/poly_line_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/poly_line_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/poly_line_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/poly_line_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/polygon_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/polygon_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/polygon_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/polygon_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/popup_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/popup_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/popup_annotation_with_parent.rb +1 -1
- data/lib/aspose_pdf_cloud/models/popup_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/popup_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/position.rb +1 -1
- data/lib/aspose_pdf_cloud/models/radio_button_field.rb +25 -25
- data/lib/aspose_pdf_cloud/models/radio_button_field_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/radio_button_fields.rb +1 -1
- data/lib/aspose_pdf_cloud/models/radio_button_fields_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/radio_button_option_field.rb +12 -7
- data/lib/aspose_pdf_cloud/models/raster_images_saving_modes.rb +1 -1
- data/lib/aspose_pdf_cloud/models/rectangle.rb +1 -1
- data/lib/aspose_pdf_cloud/models/redaction_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/redaction_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/redaction_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/redaction_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/rotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/row.rb +1 -1
- data/lib/aspose_pdf_cloud/models/row_recognized.rb +1 -1
- data/lib/aspose_pdf_cloud/models/screen_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/screen_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/screen_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/screen_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/segment.rb +1 -1
- data/lib/aspose_pdf_cloud/models/shape_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/signature.rb +1 -1
- data/lib/aspose_pdf_cloud/models/signature_custom_appearance.rb +1 -1
- data/lib/aspose_pdf_cloud/models/signature_field.rb +12 -7
- data/lib/aspose_pdf_cloud/models/signature_field_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/signature_fields.rb +1 -1
- data/lib/aspose_pdf_cloud/models/signature_fields_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/signature_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/signature_verify_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/sound_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/sound_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/sound_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/sound_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/sound_encoding.rb +1 -1
- data/lib/aspose_pdf_cloud/models/sound_icon.rb +1 -1
- data/lib/aspose_pdf_cloud/models/split_result.rb +1 -1
- data/lib/aspose_pdf_cloud/models/split_result_document.rb +1 -1
- data/lib/aspose_pdf_cloud/models/split_result_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/square_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/square_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/square_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/square_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/squiggly_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/squiggly_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/squiggly_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/squiggly_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamp.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamp_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamp_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamp_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamp_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamp_base.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamp_icon.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamp_info.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamp_type.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamps_info.rb +1 -1
- data/lib/aspose_pdf_cloud/models/stamps_info_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/storage_exist.rb +1 -1
- data/lib/aspose_pdf_cloud/models/storage_file.rb +1 -1
- data/lib/aspose_pdf_cloud/models/strike_out_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/strike_out_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/strike_out_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/strike_out_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/table.rb +12 -2
- data/lib/aspose_pdf_cloud/models/table_broken.rb +1 -1
- data/lib/aspose_pdf_cloud/models/table_recognized.rb +1 -1
- data/lib/aspose_pdf_cloud/models/table_recognized_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/tables_recognized.rb +1 -1
- data/lib/aspose_pdf_cloud/models/tables_recognized_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_box_field.rb +12 -7
- data/lib/aspose_pdf_cloud/models/text_box_field_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_box_fields.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_box_fields_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_footer.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_header.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_horizontal_alignment.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_icon.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_line.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_rect.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_rects.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_rects_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_replace.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_replace_list_request.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_replace_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_stamp.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_state.rb +1 -1
- data/lib/aspose_pdf_cloud/models/text_style.rb +1 -1
- data/lib/aspose_pdf_cloud/models/timestamp_settings.rb +1 -1
- data/lib/aspose_pdf_cloud/models/underline_annotation.rb +1 -1
- data/lib/aspose_pdf_cloud/models/underline_annotation_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/underline_annotations.rb +1 -1
- data/lib/aspose_pdf_cloud/models/underline_annotations_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/vertical_alignment.rb +1 -1
- data/lib/aspose_pdf_cloud/models/word_count.rb +1 -1
- data/lib/aspose_pdf_cloud/models/word_count_response.rb +1 -1
- data/lib/aspose_pdf_cloud/models/wrap_mode.rb +1 -1
- data/lib/aspose_pdf_cloud/version.rb +2 -2
- data/test/pdf_tests.rb +411 -98
- data/test_data/4pagesPdfA.pdf +0 -0
- metadata +35 -2
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -20,5 +20,5 @@ SOFTWARE.
|
|
20
20
|
=end
|
21
21
|
|
22
22
|
module AsposePdfCloud
|
23
|
-
VERSION = "
|
23
|
+
VERSION = "20.5.0"
|
24
24
|
end
|
data/test/pdf_tests.rb
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
=begin
|
2
2
|
--------------------------------------------------------------------------------------------------------------------
|
3
|
-
Copyright (c)
|
3
|
+
Copyright (c) 2020 Aspose.PDF Cloud
|
4
4
|
Permission is hereby granted, free of charge, to any person obtaining a copy
|
5
5
|
of this software and associated documentation files (the "Software"), to deal
|
6
6
|
in the Software without restriction, including without limitation the rights
|
@@ -33,7 +33,6 @@ class PdfTests < Minitest::Test
|
|
33
33
|
def setup
|
34
34
|
# Get App key and App SID from https://aspose.cloud
|
35
35
|
@pdf_api = PdfApi.new('app_key', 'app_sid')
|
36
|
-
|
37
36
|
@temp_folder = 'TempPdfCloud'
|
38
37
|
@test_data_folder = '../test_data/'
|
39
38
|
|
@@ -389,82 +388,121 @@ class PdfTests < Minitest::Test
|
|
389
388
|
end
|
390
389
|
|
391
390
|
def __draw_table
|
392
|
-
|
393
|
-
|
394
|
-
|
395
|
-
|
396
|
-
|
397
|
-
|
398
|
-
|
399
|
-
|
400
|
-
|
401
|
-
|
402
|
-
|
403
|
-
|
404
|
-
|
405
|
-
|
406
|
-
|
407
|
-
|
408
|
-
|
409
|
-
|
410
|
-
|
411
|
-
|
412
|
-
|
413
|
-
|
414
|
-
|
415
|
-
|
416
|
-
|
417
|
-
|
418
|
-
|
419
|
-
|
420
|
-
|
421
|
-
|
422
|
-
|
423
|
-
|
424
|
-
|
425
|
-
|
426
|
-
|
427
|
-
|
428
|
-
|
429
|
-
|
430
|
-
|
431
|
-
|
432
|
-
|
433
|
-
|
434
|
-
|
435
|
-
|
436
|
-
|
437
|
-
|
438
|
-
|
439
|
-
|
440
|
-
|
441
|
-
|
442
|
-
|
443
|
-
|
444
|
-
|
445
|
-
|
446
|
-
|
447
|
-
|
448
|
-
|
449
|
-
|
450
|
-
|
451
|
-
|
452
|
-
|
453
|
-
|
454
|
-
|
455
|
-
|
456
|
-
|
457
|
-
|
458
|
-
|
459
|
-
|
460
|
-
|
461
|
-
|
462
|
-
|
463
|
-
|
464
|
-
|
465
|
-
|
466
|
-
|
467
|
-
|
391
|
+
colorBlack = Color.new({:A => 0xFF, :R => 0, :G => 0, :B => 0})
|
392
|
+
borderGraphInfo = GraphInfo.new({:Color => colorBlack, :LineWidth => 1})
|
393
|
+
image = 'Penguins.jpg'
|
394
|
+
table = Table.new({
|
395
|
+
:Top => 100,
|
396
|
+
:ColumnWidths => '150 300',
|
397
|
+
:IsBordersIncluded => true,
|
398
|
+
:DefaultCellTextState => TextState.new({:FontSize => 11, :ForegroundColor => Color.new({:A => 255, :R => 0, :G => 255, :B => 0})}),
|
399
|
+
:Margin => MarginInfo.new({
|
400
|
+
:Bottom => 10,
|
401
|
+
:Left => 10,
|
402
|
+
:Right => 10,
|
403
|
+
:Top => 10
|
404
|
+
}),
|
405
|
+
:Border => BorderInfo.new({
|
406
|
+
:Top => borderGraphInfo,
|
407
|
+
:Left => borderGraphInfo
|
408
|
+
}),
|
409
|
+
:DefaultCellBorder => BorderInfo.new({
|
410
|
+
:Right => borderGraphInfo,
|
411
|
+
}),
|
412
|
+
:DefaultCellPadding => MarginInfo.new({
|
413
|
+
:Top => 5,
|
414
|
+
:Left => 5,
|
415
|
+
:Right => 5,
|
416
|
+
:Bottom => 5,
|
417
|
+
}),
|
418
|
+
:Rows => [
|
419
|
+
Row.new({
|
420
|
+
:MinRowHeight => 100,
|
421
|
+
:Border => BorderInfo.new({
|
422
|
+
:Bottom => borderGraphInfo,
|
423
|
+
}),
|
424
|
+
:Cells => [
|
425
|
+
Cell.new({
|
426
|
+
:Paragraphs => [
|
427
|
+
TextRect.new({
|
428
|
+
:Text => 'BackgroundImageStorageFile field, from storage file',
|
429
|
+
:HorizontalAlignment => HorizontalAlignment::CENTER,
|
430
|
+
:TextState => TextState.new({:FontSize => 10, :ForegroundColor => Color.new({:A => 0xff, :R => 0x3d, :G => 0x8e, :B =>0xc4})}),
|
431
|
+
})
|
432
|
+
]
|
433
|
+
}),
|
434
|
+
Cell.new({
|
435
|
+
:BackgroundColor => colorBlack,
|
436
|
+
:BackgroundImageStorageFile => "#{@temp_folder}/#{image}"
|
437
|
+
})
|
438
|
+
]
|
439
|
+
}),
|
440
|
+
Row.new({
|
441
|
+
:MinRowHeight => 100,
|
442
|
+
:Border => BorderInfo.new({:Bottom => borderGraphInfo}),
|
443
|
+
:Cells => [
|
444
|
+
Cell.new({
|
445
|
+
:Paragraphs => [
|
446
|
+
TextRect.new({
|
447
|
+
:Text => 'HtmlFragment',
|
448
|
+
:HorizontalAlignment => HorizontalAlignment::CENTER,
|
449
|
+
:TextState => TextState.new({
|
450
|
+
:FontSize => 10,
|
451
|
+
:ForegroundColor => Color.new({:A => 255, :R => 0x3d, :G => 0x8e, :B => 0xc4}),
|
452
|
+
})
|
453
|
+
})
|
454
|
+
]
|
455
|
+
}),
|
456
|
+
Cell.new({:HtmlFragment => '<ul><li>First</li><li>Second</li></ul>'}),
|
457
|
+
]
|
458
|
+
}),
|
459
|
+
Row.new({
|
460
|
+
:FixedRowHeight => 100,
|
461
|
+
:Border => BorderInfo.new({:Bottom => borderGraphInfo}),
|
462
|
+
:Cells => [
|
463
|
+
Cell.new({
|
464
|
+
:Paragraphs => [
|
465
|
+
TextRect.new({:Text => 'FixedRowHeight = 100'}),
|
466
|
+
TextRect.new({
|
467
|
+
:Text => 'Images field, from storage file, without Margin and Size',
|
468
|
+
:HorizontalAlignment => HorizontalAlignment::CENTER,
|
469
|
+
:TextState => TextState.new({:FontSize => 10, :ForegroundColor => Color.new({:A => 255, :R => 0x3d, :G => 0x8e, :B => 0xc4})}),
|
470
|
+
})
|
471
|
+
]
|
472
|
+
}),
|
473
|
+
Cell.new({
|
474
|
+
:BackgroundColor => colorBlack,
|
475
|
+
:Images => [ImageFragment.new({ImageFile: "#{@temp_folder}/#{image}"})]
|
476
|
+
})
|
477
|
+
]
|
478
|
+
}),
|
479
|
+
Row.new({
|
480
|
+
:FixedRowHeight => 100,
|
481
|
+
:Border => BorderInfo.new({:Bottom => borderGraphInfo}),
|
482
|
+
:Cells => [
|
483
|
+
Cell.new({
|
484
|
+
:Paragraphs => [
|
485
|
+
TextRect.new({:Text => 'FixedRowHeight = 100'}),
|
486
|
+
TextRect.new({
|
487
|
+
:Text => 'Images field, from storage file, with no Margin and Size = 150x50',
|
488
|
+
:HorizontalAlignment => HorizontalAlignment::CENTER,
|
489
|
+
:TextState => TextState.new({:FontSize => 10, :ForegroundColor => Color.new({:A => 255, :R => 0x3d, :G => 0x8e, :B => 0xc4})})
|
490
|
+
})
|
491
|
+
]
|
492
|
+
}),
|
493
|
+
Cell.new({
|
494
|
+
:BackgroundColor => colorBlack,
|
495
|
+
:Images => [
|
496
|
+
ImageFragment.new({
|
497
|
+
:ImageFile => "#{@temp_folder}/#{image}",
|
498
|
+
:ImageScale => 0.1
|
499
|
+
})
|
500
|
+
]
|
501
|
+
})
|
502
|
+
]
|
503
|
+
})
|
504
|
+
]
|
505
|
+
})
|
468
506
|
table
|
469
507
|
end
|
470
508
|
|
@@ -3106,7 +3144,7 @@ class PdfTests < Minitest::Test
|
|
3106
3144
|
assert(response, 'Filed to convert PDF to PPTX.')
|
3107
3145
|
end
|
3108
3146
|
|
3109
|
-
def
|
3147
|
+
def test_get_pdf_in_storage_to_te_x
|
3110
3148
|
file_name = '4pages.pdf'
|
3111
3149
|
upload_file(file_name)
|
3112
3150
|
|
@@ -3114,33 +3152,33 @@ class PdfTests < Minitest::Test
|
|
3114
3152
|
:folder => @temp_folder
|
3115
3153
|
}
|
3116
3154
|
|
3117
|
-
response = @pdf_api.
|
3118
|
-
assert(response, 'Filed to convert PDF to
|
3155
|
+
response = @pdf_api.get_pdf_in_storage_to_te_x(file_name, opts)
|
3156
|
+
assert(response, 'Filed to convert PDF to Tex.')
|
3119
3157
|
end
|
3120
3158
|
|
3121
|
-
def
|
3159
|
+
def test_put_pdf_in_storage_to_te_x
|
3122
3160
|
file_name = '4pages.pdf'
|
3123
3161
|
upload_file(file_name)
|
3124
|
-
res_file = 'result.
|
3162
|
+
res_file = 'result.tex'
|
3125
3163
|
|
3126
3164
|
opts = {
|
3127
3165
|
:folder => @temp_folder
|
3128
3166
|
}
|
3129
|
-
response = @pdf_api.
|
3130
|
-
assert(response, 'Filed to convert PDF to
|
3167
|
+
response = @pdf_api.put_pdf_in_storage_to_te_x(file_name, @temp_folder + '/' + res_file, opts)
|
3168
|
+
assert(response, 'Filed to convert PDF to TeX.')
|
3131
3169
|
end
|
3132
3170
|
|
3133
3171
|
|
3134
|
-
def
|
3172
|
+
def test_put_pdf_in_request_to_te_x
|
3135
3173
|
file_name = '4pages.pdf'
|
3136
3174
|
|
3137
|
-
res_file = 'result.
|
3175
|
+
res_file = 'result.tex'
|
3138
3176
|
|
3139
3177
|
opts = {
|
3140
3178
|
:file => ::File.open(@test_data_folder + file_name, 'r') { |io| io.read(io.size) }
|
3141
3179
|
}
|
3142
|
-
response = @pdf_api.
|
3143
|
-
assert(response, 'Filed to convert PDF to
|
3180
|
+
response = @pdf_api.put_pdf_in_request_to_te_x(@temp_folder + '/' + res_file, opts)
|
3181
|
+
assert(response, 'Filed to convert PDF to TeX.')
|
3144
3182
|
end
|
3145
3183
|
|
3146
3184
|
def test_get_pdf_in_storage_to_mobi_xml
|
@@ -3334,16 +3372,16 @@ class PdfTests < Minitest::Test
|
|
3334
3372
|
end
|
3335
3373
|
|
3336
3374
|
|
3337
|
-
def
|
3375
|
+
def test_get_te_x_in_storage_to_pdf
|
3338
3376
|
file_name = 'sample.tex'
|
3339
3377
|
upload_file(file_name)
|
3340
3378
|
|
3341
3379
|
src_path = @temp_folder + '/' + file_name
|
3342
|
-
response = @pdf_api.
|
3343
|
-
assert(response, 'Failed to convert
|
3380
|
+
response = @pdf_api.get_te_x_in_storage_to_pdf(src_path)
|
3381
|
+
assert(response, 'Failed to convert TeX to pdf.')
|
3344
3382
|
end
|
3345
3383
|
|
3346
|
-
def
|
3384
|
+
def test_put_te_x_in_storage_to_pdf
|
3347
3385
|
file_name = 'sample.tex'
|
3348
3386
|
upload_file(file_name)
|
3349
3387
|
result_name = 'fromTex.pdf'
|
@@ -3352,8 +3390,8 @@ class PdfTests < Minitest::Test
|
|
3352
3390
|
opts = {
|
3353
3391
|
:dst_folder => @temp_folder
|
3354
3392
|
}
|
3355
|
-
response = @pdf_api.
|
3356
|
-
assert(response, 'Failed to convert
|
3393
|
+
response = @pdf_api.put_te_x_in_storage_to_pdf(result_name, src_path, opts)
|
3394
|
+
assert(response, 'Failed to convert TeX to pdf.')
|
3357
3395
|
end
|
3358
3396
|
|
3359
3397
|
def test_get_mht_in_storage_to_pdf
|
@@ -3599,6 +3637,28 @@ class PdfTests < Minitest::Test
|
|
3599
3637
|
assert(response, 'Failed to convert markdown to pdf.')
|
3600
3638
|
end
|
3601
3639
|
|
3640
|
+
def test_get_pdf_a_in_storage_to_pdf
|
3641
|
+
file_name = '4pagesPdfA.pdf'
|
3642
|
+
upload_file(file_name)
|
3643
|
+
|
3644
|
+
src_path = @temp_folder + '/' + file_name
|
3645
|
+
response = @pdf_api.get_pdf_a_in_storage_to_pdf(src_path)
|
3646
|
+
assert(response, 'Failed to convert pdfa to pdf.')
|
3647
|
+
end
|
3648
|
+
|
3649
|
+
def test_put_pdf_a_in_storage_to_pdf
|
3650
|
+
file_name = '4pagesPdfA.pdf'
|
3651
|
+
upload_file(file_name)
|
3652
|
+
result_name = 'fromPdfA.pdf'
|
3653
|
+
|
3654
|
+
src_path = @temp_folder + '/' + file_name
|
3655
|
+
opts = {
|
3656
|
+
:dst_folder => @temp_folder
|
3657
|
+
}
|
3658
|
+
response = @pdf_api.put_pdf_a_in_storage_to_pdf(result_name, src_path, opts)
|
3659
|
+
assert(response, 'Failed to convert pdfa to pdf.')
|
3660
|
+
end
|
3661
|
+
|
3602
3662
|
# Document Tests
|
3603
3663
|
|
3604
3664
|
def test_get_document
|
@@ -3658,6 +3718,71 @@ class PdfTests < Minitest::Test
|
|
3658
3718
|
assert(response, 'Failed to create new document')
|
3659
3719
|
end
|
3660
3720
|
|
3721
|
+
def test_post_create_document
|
3722
|
+
file_name = 'empty_post.pdf'
|
3723
|
+
|
3724
|
+
opts = {
|
3725
|
+
:folder => @temp_folder
|
3726
|
+
}
|
3727
|
+
|
3728
|
+
prop = DocumentProperty.new
|
3729
|
+
prop.name = 'prop1'
|
3730
|
+
prop.value = 'val1'
|
3731
|
+
|
3732
|
+
props = DocumentProperties.new
|
3733
|
+
props.list = [prop]
|
3734
|
+
|
3735
|
+
display_props = DisplayProperties.new
|
3736
|
+
display_props.center_window = true
|
3737
|
+
display_props.hide_menu_bar = true
|
3738
|
+
|
3739
|
+
page_config = DefaultPageConfig.new
|
3740
|
+
page_config.height = 100
|
3741
|
+
page_config.width = 100
|
3742
|
+
|
3743
|
+
config = DocumentConfig.new
|
3744
|
+
config.document_properties = props
|
3745
|
+
config.display_properties = display_props
|
3746
|
+
config.default_page_config = page_config
|
3747
|
+
|
3748
|
+
response = @pdf_api.post_create_document(file_name, config, opts)
|
3749
|
+
assert(response, 'Failed to create new document')
|
3750
|
+
end
|
3751
|
+
|
3752
|
+
def test_get_document_display_properties
|
3753
|
+
file_name = '4pages.pdf'
|
3754
|
+
upload_file(file_name)
|
3755
|
+
|
3756
|
+
opts = {
|
3757
|
+
:folder => @temp_folder
|
3758
|
+
}
|
3759
|
+
|
3760
|
+
response = @pdf_api.get_document_display_properties(file_name, opts)
|
3761
|
+
assert(response, 'Failed to read document display properties.')
|
3762
|
+
end
|
3763
|
+
|
3764
|
+
def test_put_document_display_properties
|
3765
|
+
file_name = '4pages.pdf'
|
3766
|
+
upload_file(file_name)
|
3767
|
+
|
3768
|
+
opts = {
|
3769
|
+
:folder => @temp_folder
|
3770
|
+
}
|
3771
|
+
|
3772
|
+
properties = DisplayProperties.new
|
3773
|
+
properties.center_window = true
|
3774
|
+
properties.direction = Direction::L2_R
|
3775
|
+
properties.display_doc_title = true
|
3776
|
+
properties.hide_menu_bar = true
|
3777
|
+
properties.hide_tool_bar = true
|
3778
|
+
properties.hide_window_ui = true
|
3779
|
+
properties.non_full_screen_page_mode = PageMode::USE_NONE
|
3780
|
+
properties.page_layout = PageLayout::TWO_PAGE_LEFT
|
3781
|
+
properties.page_mode = PageMode::USE_OC
|
3782
|
+
|
3783
|
+
response = @pdf_api.put_document_display_properties(file_name, properties, opts)
|
3784
|
+
assert(response, 'Failed to update document display properties.')
|
3785
|
+
end
|
3661
3786
|
|
3662
3787
|
# Fields Tests
|
3663
3788
|
|
@@ -3797,7 +3922,7 @@ class PdfTests < Minitest::Test
|
|
3797
3922
|
assert(response, 'Failed flatten document.')
|
3798
3923
|
end
|
3799
3924
|
|
3800
|
-
def
|
3925
|
+
def test_get_document_sigignature_fields
|
3801
3926
|
file_name = 'adbe.x509.rsa_sha1.valid.pdf'
|
3802
3927
|
upload_file(file_name)
|
3803
3928
|
|
@@ -3809,7 +3934,7 @@ class PdfTests < Minitest::Test
|
|
3809
3934
|
assert(response, 'Failed to read document signature fields.')
|
3810
3935
|
end
|
3811
3936
|
|
3812
|
-
def
|
3937
|
+
def test_get_page_sigignature_fields
|
3813
3938
|
file_name = 'adbe.x509.rsa_sha1.valid.pdf'
|
3814
3939
|
upload_file(file_name)
|
3815
3940
|
|
@@ -3822,7 +3947,75 @@ class PdfTests < Minitest::Test
|
|
3822
3947
|
assert(response, 'Failed to read page signature fields.')
|
3823
3948
|
end
|
3824
3949
|
|
3825
|
-
def
|
3950
|
+
def test_post_sigignature_field
|
3951
|
+
file_name = '4pages.pdf'
|
3952
|
+
upload_file(file_name)
|
3953
|
+
|
3954
|
+
signature_name = '33226.p12'
|
3955
|
+
upload_file(signature_name)
|
3956
|
+
|
3957
|
+
signature = Signature.new
|
3958
|
+
signature.authority = 'Sergey Smal'
|
3959
|
+
signature.contact = 'test@mail.ru'
|
3960
|
+
signature.date = '08/01/2012 12:15:00.000 PM'
|
3961
|
+
signature.form_field_name = 'Signature1'
|
3962
|
+
signature.location = 'Ukraine'
|
3963
|
+
signature.password = 'sIikZSmz'
|
3964
|
+
signature.rectangle = Rectangle.new({:LLX => 100, :LLY => 100, :URX => 500, :URY => 200})
|
3965
|
+
signature.signature_path = @temp_folder + '/' + signature_name
|
3966
|
+
signature.signature_type = SignatureType::PKCS7
|
3967
|
+
signature.visible = true
|
3968
|
+
signature.show_properties = false
|
3969
|
+
|
3970
|
+
field = SignatureField.new
|
3971
|
+
field.partial_name = 'sign1'
|
3972
|
+
field.rect = Rectangle.new({:LLX => 100, :LLY => 100, :URX => 500, :URY => 200})
|
3973
|
+
field.signature = signature
|
3974
|
+
field.page_index = 1
|
3975
|
+
|
3976
|
+
opts = {
|
3977
|
+
:folder => @temp_folder
|
3978
|
+
}
|
3979
|
+
|
3980
|
+
response = @pdf_api.post_signature_field(file_name, field, opts)
|
3981
|
+
assert(response, 'Failed to create signature field.')
|
3982
|
+
end
|
3983
|
+
|
3984
|
+
def test_put_sigignature_field
|
3985
|
+
file_name = 'adbe.x509.rsa_sha1.valid.pdf'
|
3986
|
+
upload_file(file_name)
|
3987
|
+
|
3988
|
+
signature_name = '33226.p12'
|
3989
|
+
upload_file(signature_name)
|
3990
|
+
|
3991
|
+
signature = Signature.new
|
3992
|
+
signature.authority = 'Sergey Smal'
|
3993
|
+
signature.contact = 'test@mail.ru'
|
3994
|
+
signature.date = '08/01/2012 12:15:00.000 PM'
|
3995
|
+
signature.form_field_name = 'Signature1'
|
3996
|
+
signature.location = 'Ukraine'
|
3997
|
+
signature.password = 'sIikZSmz'
|
3998
|
+
signature.rectangle = Rectangle.new({:LLX => 100, :LLY => 100, :URX => 500, :URY => 200})
|
3999
|
+
signature.signature_path = @temp_folder + '/' + signature_name
|
4000
|
+
signature.signature_type = SignatureType::PKCS7
|
4001
|
+
signature.visible = true
|
4002
|
+
signature.show_properties = false
|
4003
|
+
|
4004
|
+
field = SignatureField.new
|
4005
|
+
field.partial_name = 'sign1'
|
4006
|
+
field.rect = Rectangle.new({:LLX => 100, :LLY => 100, :URX => 500, :URY => 200})
|
4007
|
+
field.signature = signature
|
4008
|
+
field.page_index = 1
|
4009
|
+
|
4010
|
+
opts = {
|
4011
|
+
:folder => @temp_folder
|
4012
|
+
}
|
4013
|
+
|
4014
|
+
response = @pdf_api.put_signature_field(file_name, 'Signature1', field, opts)
|
4015
|
+
assert(response, 'Failed to update signature field.')
|
4016
|
+
end
|
4017
|
+
|
4018
|
+
def test_get_sigignature_field
|
3826
4019
|
file_name = 'adbe.x509.rsa_sha1.valid.pdf'
|
3827
4020
|
upload_file(file_name)
|
3828
4021
|
|
@@ -3835,6 +4028,9 @@ class PdfTests < Minitest::Test
|
|
3835
4028
|
assert(response, 'Failed to read signature field.')
|
3836
4029
|
end
|
3837
4030
|
|
4031
|
+
|
4032
|
+
|
4033
|
+
|
3838
4034
|
def test_get_document_text_box_fields
|
3839
4035
|
file_name = 'FormDataTextBox.pdf'
|
3840
4036
|
upload_file(file_name)
|
@@ -4221,6 +4417,123 @@ class PdfTests < Minitest::Test
|
|
4221
4417
|
assert(response, 'Failed to update combo box field.')
|
4222
4418
|
end
|
4223
4419
|
|
4420
|
+
def test_get_document_list_box_fields
|
4421
|
+
file_name = 'PdfWithAcroForm.pdf'
|
4422
|
+
upload_file(file_name)
|
4423
|
+
|
4424
|
+
opts = {
|
4425
|
+
:folder => @temp_folder
|
4426
|
+
}
|
4427
|
+
|
4428
|
+
response = @pdf_api.get_document_list_box_fields(file_name, opts)
|
4429
|
+
assert(response, 'Failed to read document listbox fields.')
|
4430
|
+
end
|
4431
|
+
|
4432
|
+
def test_get_page_list_box_fields
|
4433
|
+
file_name = 'PdfWithAcroForm.pdf'
|
4434
|
+
upload_file(file_name)
|
4435
|
+
|
4436
|
+
page_number = 1
|
4437
|
+
opts = {
|
4438
|
+
:folder => @temp_folder
|
4439
|
+
}
|
4440
|
+
|
4441
|
+
response = @pdf_api.get_page_list_box_fields(file_name, page_number, opts)
|
4442
|
+
assert(response, 'Failed to read page list box fields.')
|
4443
|
+
end
|
4444
|
+
|
4445
|
+
def test_get_list_box_field
|
4446
|
+
file_name = 'PdfWithAcroForm.pdf'
|
4447
|
+
upload_file(file_name)
|
4448
|
+
|
4449
|
+
field_name = 'listboxField'
|
4450
|
+
opts = {
|
4451
|
+
:folder => @temp_folder
|
4452
|
+
}
|
4453
|
+
|
4454
|
+
response = @pdf_api.get_list_box_field(file_name, field_name, opts)
|
4455
|
+
assert(response, 'Failed to read list box field.')
|
4456
|
+
end
|
4457
|
+
|
4458
|
+
def test_post_list_box_fields
|
4459
|
+
file_name = '4pages.pdf'
|
4460
|
+
upload_file(file_name)
|
4461
|
+
|
4462
|
+
field = ListBoxField.new
|
4463
|
+
field.page_index = 1
|
4464
|
+
field.selected_items = [1, 4]
|
4465
|
+
field.multi_select = true
|
4466
|
+
field.color = Color.new({:A => 0xFF, :R => 0, :G => 0xFF, :B => 0})
|
4467
|
+
field.rect = Rectangle.new({:LLX => 100, :LLY => 100, :URX => 160, :URY => 140})
|
4468
|
+
field.partial_name = 'testField'
|
4469
|
+
field.margin = MarginInfo.new({:Bottom => 0, :Left => 0, :Right => 0, :Top => 0})
|
4470
|
+
field.options = [
|
4471
|
+
Option.new({
|
4472
|
+
:Name => 'one',
|
4473
|
+
:Value => 'one',
|
4474
|
+
}),
|
4475
|
+
Option.new({
|
4476
|
+
:Name => 'two',
|
4477
|
+
:Value => 'two',
|
4478
|
+
}),
|
4479
|
+
Option.new({
|
4480
|
+
:Name => 'three',
|
4481
|
+
:Value => 'three',
|
4482
|
+
}),
|
4483
|
+
Option.new({
|
4484
|
+
:Name => 'four',
|
4485
|
+
:Value => 'four',
|
4486
|
+
}),
|
4487
|
+
]
|
4488
|
+
|
4489
|
+
opts = {
|
4490
|
+
:folder => @temp_folder
|
4491
|
+
}
|
4492
|
+
|
4493
|
+
response = @pdf_api.post_list_box_fields(file_name, [field], opts)
|
4494
|
+
assert(response, 'Failed to insert list box fields.')
|
4495
|
+
end
|
4496
|
+
|
4497
|
+
def test_put_list_box_field
|
4498
|
+
file_name = 'PdfWithAcroForm.pdf'
|
4499
|
+
upload_file(file_name)
|
4500
|
+
|
4501
|
+
field_name = 'listboxField'
|
4502
|
+
|
4503
|
+
field = ListBoxField.new
|
4504
|
+
field.page_index = 1
|
4505
|
+
field.selected_items = [1, 4]
|
4506
|
+
field.multi_select = true
|
4507
|
+
field.color = Color.new({:A => 0xFF, :R => 0, :G => 0xFF, :B => 0})
|
4508
|
+
field.rect = Rectangle.new({:LLX => 100, :LLY => 100, :URX => 160, :URY => 140})
|
4509
|
+
field.partial_name = 'testField'
|
4510
|
+
field.margin = MarginInfo.new({:Bottom => 0, :Left => 0, :Right => 0, :Top => 0})
|
4511
|
+
field.options = [
|
4512
|
+
Option.new({
|
4513
|
+
:Name => 'one',
|
4514
|
+
:Value => 'one',
|
4515
|
+
}),
|
4516
|
+
Option.new({
|
4517
|
+
:Name => 'two',
|
4518
|
+
:Value => 'two',
|
4519
|
+
}),
|
4520
|
+
Option.new({
|
4521
|
+
:Name => 'three',
|
4522
|
+
:Value => 'three',
|
4523
|
+
}),
|
4524
|
+
Option.new({
|
4525
|
+
:Name => 'four',
|
4526
|
+
:Value => 'four',
|
4527
|
+
}),
|
4528
|
+
]
|
4529
|
+
|
4530
|
+
opts = {
|
4531
|
+
:folder => @temp_folder
|
4532
|
+
}
|
4533
|
+
|
4534
|
+
response = @pdf_api.put_list_box_field(file_name, field_name, field, opts)
|
4535
|
+
assert(response, 'Failed to update list box field.')
|
4536
|
+
end
|
4224
4537
|
|
4225
4538
|
# Stamp Tests
|
4226
4539
|
|