├── .gitignore ├── CONTRIBUTING.md ├── CollabFirebaseSample ├── .gitignore ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── pdftron │ │ │ └── realtimecollaboration │ │ │ └── ExampleInstrumentedTest.kt │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── pdftron │ │ │ │ └── realtimecollaboration │ │ │ │ ├── CustomTabFragment.kt │ │ │ │ ├── MainActivity.kt │ │ │ │ ├── Server.kt │ │ │ │ ├── ServerEvent.kt │ │ │ │ └── model │ │ │ │ ├── Annotation.kt │ │ │ │ └── User.kt │ │ └── res │ │ │ ├── drawable-v24 │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── drawable │ │ │ └── ic_launcher_background.xml │ │ │ ├── layout │ │ │ ├── activity_main.xml │ │ │ └── fragment_custom_reply_viewer.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ ├── ic_launcher.xml │ │ │ └── ic_launcher_round.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ └── values │ │ │ ├── colors.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── pdftron │ │ └── realtimecollaboration │ │ └── ExampleUnitTest.kt ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle ├── CollabWebSocketSample ├── .gitignore ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── pdftron │ │ │ └── realtimecollaborationws │ │ │ └── ExampleInstrumentedTest.kt │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── pdftron │ │ │ │ └── realtimecollaborationws │ │ │ │ ├── MainActivity.kt │ │ │ │ ├── ServerEvent.kt │ │ │ │ └── WSConnection.kt │ │ └── res │ │ │ ├── drawable-v24 │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── drawable │ │ │ └── ic_launcher_background.xml │ │ │ ├── layout │ │ │ └── activity_main.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ ├── ic_launcher.xml │ │ │ └── ic_launcher_round.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ └── values │ │ │ ├── colors.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── pdftron │ │ └── realtimecollaborationws │ │ └── ExampleUnitTest.kt ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle ├── CustomStickyNote ├── .gitignore ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── pdftron │ │ │ └── android │ │ │ └── samples │ │ │ └── stickynote │ │ │ └── ExampleInstrumentedTest.java │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── pdftron │ │ │ │ └── android │ │ │ │ └── samples │ │ │ │ └── stickynote │ │ │ │ └── ReaderActivity.java │ │ └── res │ │ │ ├── drawable │ │ │ ├── annotation_note_icon_rightarrow_fill.xml │ │ │ └── annotation_note_icon_rightarrow_outline.xml │ │ │ ├── layout │ │ │ └── activity_reader.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── raw │ │ │ ├── sample.pdf │ │ │ └── stickynote_icons.pdf │ │ │ └── values │ │ │ ├── arrays.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── pdftron │ │ └── android │ │ └── samples │ │ └── stickynote │ │ └── ExampleUnitTest.java ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat ├── settings.gradle └── stickynote_icons_default.pdf ├── CustomToolSample ├── .gitignore ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── example │ │ │ └── customtoolsample │ │ │ └── ExampleInstrumentedTest.java │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── example │ │ │ │ └── customtoolsample │ │ │ │ ├── CustomCloudSquare.java │ │ │ │ ├── CustomStamp.java │ │ │ │ └── MainActivity.java │ │ └── res │ │ │ ├── drawable-v24 │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── drawable │ │ │ └── ic_launcher_background.xml │ │ │ ├── layout │ │ │ └── activity_main.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ ├── ic_launcher.xml │ │ │ └── ic_launcher_round.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── raw │ │ │ ├── gettingstarted.pdf │ │ │ └── pdftronlogo.png │ │ │ └── values │ │ │ ├── colors.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── example │ │ └── customtoolsample │ │ └── ExampleUnitTest.java ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle ├── CustomUI ├── .gitignore ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── pdftron │ │ │ └── android │ │ │ └── tutorial │ │ │ └── customui │ │ │ ├── ExampleInstrumentedTest.java │ │ │ └── SampleAnnotTest.java │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── pdftron │ │ │ │ └── android │ │ │ │ └── tutorial │ │ │ │ └── customui │ │ │ │ ├── MainActivity.java │ │ │ │ └── custom │ │ │ │ ├── CustomAnnotationToolbar.java │ │ │ │ ├── CustomLinkClick.java │ │ │ │ ├── CustomQuickMenu.java │ │ │ │ └── CustomizationDelegate.java │ │ └── res │ │ │ ├── color │ │ │ └── selector_tab_text_color.xml │ │ │ ├── drawable-v24 │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── drawable │ │ │ └── ic_launcher_background.xml │ │ │ ├── layout │ │ │ ├── activity_main.xml │ │ │ └── controls_annotation_toolbar_collapsed_layout.xml │ │ │ ├── menu │ │ │ ├── annot_edit_text_markup.xml │ │ │ ├── annot_free_hand.xml │ │ │ ├── annot_free_text.xml │ │ │ ├── annot_general.xml │ │ │ ├── annot_simple_shape.xml │ │ │ └── my_custom_options_toolbar.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ ├── ic_launcher.xml │ │ │ └── ic_launcher_round.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── raw │ │ │ └── sample.pdf │ │ │ ├── values-night │ │ │ ├── colors.xml │ │ │ └── styles.xml │ │ │ └── values │ │ │ ├── colors.xml │ │ │ ├── ids.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── pdftron │ │ └── android │ │ └── tutorial │ │ └── customui │ │ └── ExampleUnitTest.java ├── art │ ├── dark-theme.png │ └── light-theme.png ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle ├── DemoHTML2PDF ├── .gitignore ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── pdftron │ │ │ └── demohtml2pdf │ │ │ └── ExampleInstrumentedTest.kt │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── pdftron │ │ │ │ └── demohtml2pdf │ │ │ │ └── MainActivity.kt │ │ └── res │ │ │ ├── drawable-v24 │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── drawable │ │ │ └── ic_launcher_background.xml │ │ │ ├── layout │ │ │ └── activity_main.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ ├── ic_launcher.xml │ │ │ └── ic_launcher_round.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ └── values │ │ │ ├── colors.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── pdftron │ │ └── demohtml2pdf │ │ └── ExampleUnitTest.kt ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle ├── LICENSE ├── NativeCppExample ├── .gitignore ├── .idea │ └── .gitignore ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── pdftron │ │ │ └── nativecppexample │ │ │ └── ExampleInstrumentedTest.kt │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── cpp │ │ │ ├── CMakeLists.txt │ │ │ └── native-lib.cpp │ │ ├── java │ │ │ └── com │ │ │ │ └── pdftron │ │ │ │ └── nativecppexample │ │ │ │ └── MainActivity.kt │ │ └── res │ │ │ ├── drawable-v24 │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── drawable │ │ │ └── ic_launcher_background.xml │ │ │ ├── layout │ │ │ └── activity_main.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ ├── ic_launcher.xml │ │ │ └── ic_launcher_round.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── raw │ │ │ └── pdfnet.res │ │ │ └── values │ │ │ ├── colors.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── pdftron │ │ └── nativecppexample │ │ └── ExampleUnitTest.kt ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle ├── PDFViewCtrlViewer ├── .gitignore ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── pdftron │ │ │ └── android │ │ │ └── pdfviewctrlviewer │ │ │ └── ExampleInstrumentedTest.java │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── pdftron │ │ │ │ └── android │ │ │ │ └── pdfviewctrlviewer │ │ │ │ └── MainActivity.java │ │ └── res │ │ │ ├── layout │ │ │ └── activity_main.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── raw │ │ │ └── sample.pdf │ │ │ └── values │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── pdftron │ │ └── android │ │ └── pdfviewctrlviewer │ │ └── ExampleUnitTest.java ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle ├── QuickStartPDFViewer ├── .gitignore ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── pdftron │ │ │ └── android │ │ │ └── pdfviewer │ │ │ └── ExampleInstrumentedTest.java │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── pdftron │ │ │ │ └── android │ │ │ │ └── pdfviewer │ │ │ │ └── MainActivity.java │ │ └── res │ │ │ ├── layout │ │ │ └── activity_main.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── raw │ │ │ └── sample.pdf │ │ │ └── values │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── pdftron │ │ └── android │ │ └── pdfviewer │ │ └── ExampleUnitTest.java ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle ├── README.md ├── SigningSample ├── .gitignore ├── .idea │ └── .gitignore ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── pdftron │ │ │ └── pdftronsignapp │ │ │ └── ExampleInstrumentedTest.kt │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── pdftron │ │ │ │ └── pdftronsignapp │ │ │ │ ├── BottomBarAdapter.kt │ │ │ │ ├── MainActivity.kt │ │ │ │ ├── addusertodoc │ │ │ │ ├── AddUserToDocAdapter.kt │ │ │ │ └── AddUserToDocFragment.kt │ │ │ │ ├── customtool │ │ │ │ └── DateFieldCreate.kt │ │ │ │ ├── data │ │ │ │ ├── DocumentToSign.kt │ │ │ │ └── User.kt │ │ │ │ ├── home │ │ │ │ ├── DocumentToSignAdapter.kt │ │ │ │ ├── HomeFragment.kt │ │ │ │ └── SignedDocumentAdapter.kt │ │ │ │ ├── listeners │ │ │ │ ├── MyBasicAnnotationListener.kt │ │ │ │ └── MyTabHostListener.kt │ │ │ │ ├── login │ │ │ │ └── LoginFragment.kt │ │ │ │ └── util │ │ │ │ ├── CustomButtonId.kt │ │ │ │ ├── FirebaseControl.kt │ │ │ │ ├── RequestCode.kt │ │ │ │ └── Utils.kt │ │ └── res │ │ │ ├── drawable-v24 │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── drawable │ │ │ └── ic_launcher_background.xml │ │ │ ├── layout │ │ │ ├── activity_main.xml │ │ │ ├── add_user_to_doc_view_holder.xml │ │ │ ├── bottom_bar_view_holder.xml │ │ │ ├── document_to_sign_view_holder.xml │ │ │ ├── fragment_add_user_to_doc.xml │ │ │ ├── fragment_home.xml │ │ │ ├── fragment_login.xml │ │ │ └── progress_dialog.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ ├── ic_launcher.xml │ │ │ └── ic_launcher_round.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── values-night │ │ │ └── themes.xml │ │ │ └── values │ │ │ ├── colors.xml │ │ │ ├── dimens.xml │ │ │ ├── strings.xml │ │ │ └── themes.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── pdftron │ │ └── pdftronsignapp │ │ └── ExampleUnitTest.kt ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle ├── StandardPDFViewer ├── .gitignore ├── README.md ├── app │ ├── .gitignore │ ├── build.gradle │ ├── proguard-rules.pro │ └── src │ │ ├── androidTest │ │ └── java │ │ │ └── com │ │ │ └── pdftron │ │ │ └── standardpdfviewer │ │ │ └── ExampleInstrumentedTest.java │ │ ├── main │ │ ├── AndroidManifest.xml │ │ ├── java │ │ │ └── com │ │ │ │ └── pdftron │ │ │ │ └── standardpdfviewer │ │ │ │ └── MainActivity.java │ │ └── res │ │ │ ├── drawable-v24 │ │ │ └── ic_launcher_foreground.xml │ │ │ ├── drawable │ │ │ └── ic_launcher_background.xml │ │ │ ├── layout │ │ │ └── activity_main.xml │ │ │ ├── mipmap-anydpi-v26 │ │ │ ├── ic_launcher.xml │ │ │ └── ic_launcher_round.xml │ │ │ ├── mipmap-hdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-mdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ ├── mipmap-xxxhdpi │ │ │ ├── ic_launcher.png │ │ │ └── ic_launcher_round.png │ │ │ └── values │ │ │ ├── colors.xml │ │ │ ├── strings.xml │ │ │ └── styles.xml │ │ └── test │ │ └── java │ │ └── com │ │ └── pdftron │ │ └── standardpdfviewer │ │ └── ExampleUnitTest.java ├── build.gradle ├── gradle.properties ├── gradle │ └── wrapper │ │ ├── gradle-wrapper.jar │ │ └── gradle-wrapper.properties ├── gradlew ├── gradlew.bat └── settings.gradle └── pdftron-version.txt /CONTRIBUTING.md: -------------------------------------------------------------------------------- 1 | # Contributing to Apryse - Android samples 2 | 3 | ## Issues 4 | 1. Check existing issues (open/closed) to avoid duplicates. 5 | 2. Be clear about what the problem is. 6 | 3. Make sure to paste error output or logs. 7 | 4. Code snapshot or demos on online code editor will be very helpful. 8 | 9 | ## Pull requests 10 | 1. Fork the repository. 11 | 2. Create a branch from `master`. 12 | 3. Update the source code. 13 | 4. Commit and push the changes with descriptive messages. 14 | 5. Create a pull request to `master`. 15 | 16 | \* Please note that all pull requests should be tied to an issue, and all but the most trivial pull requests should be discussed beforehand. -------------------------------------------------------------------------------- /CollabFirebaseSample/.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.ap_ 4 | 5 | # Files for the ART/Dalvik VM 6 | *.dex 7 | 8 | # Java class files 9 | *.class 10 | 11 | # Generated files 12 | bin/ 13 | gen/ 14 | out/ 15 | 16 | # Gradle files 17 | .gradle/ 18 | build/ 19 | 20 | # Local configuration file (sdk path, etc) 21 | local.properties 22 | 23 | # Proguard folder generated by Eclipse 24 | proguard/ 25 | 26 | # Log Files 27 | *.log 28 | 29 | # Android Studio Navigation editor temp files 30 | .navigation/ 31 | 32 | # Android Studio captures folder 33 | captures/ 34 | 35 | # Android Studio 36 | .idea/ 37 | 38 | # IntelliJ 39 | *.iml 40 | .idea/workspace.xml 41 | .idea/tasks.xml 42 | .idea/gradle.xml 43 | .idea/assetWizardSettings.xml 44 | .idea/dictionaries 45 | .idea/libraries 46 | .idea/caches 47 | 48 | # Keystore files 49 | # Uncomment the following line if you do not want to check your keystore files in. 50 | #*.jks 51 | 52 | # External native build folder generated in Android Studio 2.2 and later 53 | .externalNativeBuild 54 | 55 | # Google Services (e.g. APIs or Firebase) 56 | google-services.json 57 | 58 | # Freeline 59 | freeline.py 60 | freeline/ 61 | freeline_project_description.json 62 | 63 | # fastlane 64 | fastlane/report.xml 65 | fastlane/Preview.html 66 | fastlane/screenshots 67 | fastlane/test_output 68 | fastlane/readme.md 69 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/androidTest/java/com/pdftron/realtimecollaboration/ExampleInstrumentedTest.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.realtimecollaboration 2 | 3 | import androidx.test.platform.app.InstrumentationRegistry 4 | import androidx.test.ext.junit.runners.AndroidJUnit4 5 | 6 | import org.junit.Test 7 | import org.junit.runner.RunWith 8 | 9 | import org.junit.Assert.* 10 | 11 | /** 12 | * Instrumented test, which will execute on an Android device. 13 | * 14 | * See [testing documentation](http://d.android.com/tools/testing). 15 | */ 16 | @RunWith(AndroidJUnit4::class) 17 | class ExampleInstrumentedTest { 18 | @Test 19 | fun useAppContext() { 20 | // Context of the app under test. 21 | val appContext = InstrumentationRegistry.getInstrumentation().getTargetContext() 22 | assertEquals("com.pdftron.realtimecollaboration", appContext.packageName) 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 13 | 14 | 17 | 18 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/java/com/pdftron/realtimecollaboration/CustomTabFragment.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.realtimecollaboration 2 | 3 | import com.pdftron.collab.ui.reply.bottomsheet.ReplyFragment 4 | import com.pdftron.collab.ui.reply.bottomsheet.ReplyFragmentBuilder 5 | import com.pdftron.collab.ui.viewer.CollabViewerTabFragment2 6 | 7 | class CustomTabFragment : CollabViewerTabFragment2() { 8 | // Define the layout XML file to use for this viewer fragment 9 | override fun getContentLayoutRes(): Int { 10 | return R.layout.fragment_custom_reply_viewer 11 | } 12 | // Instantiate and display the reply UI in the reply container 13 | override fun showReplyFragment(selectedAnnotId: String, authorId: String, selectedAnnotPageNum: Int) { 14 | // Create our reply fragment 15 | val fragment = ReplyFragmentBuilder 16 | .withAnnot(mDocumentId, selectedAnnotId, authorId) 17 | .usingTheme(mReplyTheme) 18 | .build(activity!!, ReplyFragment::class.java) 19 | // Add the fragment to the container 20 | activity!!.supportFragmentManager.beginTransaction() 21 | .add(R.id.reply_container, fragment) 22 | .commit() 23 | } 24 | } -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/java/com/pdftron/realtimecollaboration/ServerEvent.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.realtimecollaboration 2 | 3 | import com.google.android.gms.tasks.Task 4 | import com.google.firebase.auth.AuthResult 5 | 6 | sealed class ServerEvent { 7 | class SignUp(val response: Task) : ServerEvent() 8 | class SignIn(val name: String) : ServerEvent() 9 | class SetUserAndDocument(val authorId: String, val authorName: String, val documentId: String) : ServerEvent() 10 | class ImportXfdfCommand(val xfdfCommand: String, val initial: Boolean) : ServerEvent() 11 | } -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/java/com/pdftron/realtimecollaboration/model/Annotation.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.realtimecollaboration.model 2 | 3 | import com.google.firebase.database.IgnoreExtraProperties 4 | 5 | @IgnoreExtraProperties 6 | data class Annotation( 7 | var authorId: String? = "", 8 | var parentAuthorId: String? = "", 9 | var xfdf: String? = "" 10 | ) 11 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/java/com/pdftron/realtimecollaboration/model/User.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.realtimecollaboration.model 2 | 3 | import com.google.firebase.database.IgnoreExtraProperties 4 | 5 | @IgnoreExtraProperties 6 | data class User( 7 | var authorName: String? = "" 8 | ) -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 18 | 19 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/layout/fragment_custom_reply_viewer.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 6 | 7 | 12 | 13 | 18 | 19 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | #202D3D 5 | #151e29 6 | #ff5722 7 | #9dd8ff 8 | @color/colorPrimary 9 | @color/colorPrimaryDark 10 | 11 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | PDFTron Firebase Demo 3 | Welcome! Tell us your name :) 4 | Your name 5 | Welcome back! :) 6 | Your name is %s 7 | 8 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | 16 | 17 | 18 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /CollabFirebaseSample/app/src/test/java/com/pdftron/realtimecollaboration/ExampleUnitTest.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.realtimecollaboration 2 | 3 | import org.junit.Test 4 | 5 | import org.junit.Assert.* 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * See [testing documentation](http://d.android.com/tools/testing). 11 | */ 12 | class ExampleUnitTest { 13 | @Test 14 | fun addition_isCorrect() { 15 | assertEquals(4, 2 + 2) 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /CollabFirebaseSample/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | ext.kotlin_version = '1.7.20' 5 | repositories { 6 | google() 7 | mavenCentral() 8 | maven { 9 | url 'https://maven.fabric.io/public' 10 | } 11 | } 12 | dependencies { 13 | classpath 'com.android.tools.build:gradle:4.2.0' 14 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 15 | // NOTE: Do not place your application dependencies here; they belong 16 | // in the individual module build.gradle files 17 | classpath 'com.google.gms:google-services:4.2.0' 18 | classpath 'io.fabric.tools:gradle:1.29.0' 19 | } 20 | } 21 | 22 | ext.myPdftronRepo = "https://pdftron-maven.s3.amazonaws.com/release" 23 | ext.myPdftronVersion = file("${rootDir}/../pdftron-version.txt").text.trim() 24 | 25 | allprojects { 26 | repositories { 27 | google() 28 | mavenCentral() 29 | maven { 30 | url myPdftronRepo 31 | } 32 | } 33 | } 34 | 35 | task clean(type: Delete) { 36 | delete rootProject.buildDir 37 | } 38 | -------------------------------------------------------------------------------- /CollabFirebaseSample/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | # Kotlin code style for this project: "official" or "obsolete": 15 | kotlin.code.style=official 16 | 17 | PDFTRON_LICENSE_KEY=YOUR_PDFTRON_LICENSE_KEY_GOES_HERE 18 | android.useAndroidX=true 19 | android.enableJetifier=true -------------------------------------------------------------------------------- /CollabFirebaseSample/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabFirebaseSample/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /CollabFirebaseSample/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jun 03 10:31:57 PDT 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /CollabFirebaseSample/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /CollabWebSocketSample/.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.ap_ 4 | 5 | # Files for the ART/Dalvik VM 6 | *.dex 7 | 8 | # Java class files 9 | *.class 10 | 11 | # Generated files 12 | bin/ 13 | gen/ 14 | out/ 15 | 16 | # Gradle files 17 | .gradle/ 18 | build/ 19 | 20 | # Local configuration file (sdk path, etc) 21 | local.properties 22 | 23 | # Proguard folder generated by Eclipse 24 | proguard/ 25 | 26 | # Log Files 27 | *.log 28 | 29 | # Android Studio Navigation editor temp files 30 | .navigation/ 31 | 32 | # Android Studio captures folder 33 | captures/ 34 | 35 | # Android Studio 36 | .idea/ 37 | 38 | # IntelliJ 39 | *.iml 40 | .idea/workspace.xml 41 | .idea/tasks.xml 42 | .idea/gradle.xml 43 | .idea/assetWizardSettings.xml 44 | .idea/dictionaries 45 | .idea/libraries 46 | .idea/caches 47 | 48 | # Keystore files 49 | # Uncomment the following line if you do not want to check your keystore files in. 50 | #*.jks 51 | 52 | # External native build folder generated in Android Studio 2.2 and later 53 | .externalNativeBuild 54 | 55 | # Google Services (e.g. APIs or Firebase) 56 | google-services.json 57 | 58 | # Freeline 59 | freeline.py 60 | freeline/ 61 | freeline_project_description.json 62 | 63 | # fastlane 64 | fastlane/report.xml 65 | fastlane/Preview.html 66 | fastlane/screenshots 67 | fastlane/test_output 68 | fastlane/readme.md 69 | -------------------------------------------------------------------------------- /CollabWebSocketSample/README.md: -------------------------------------------------------------------------------- 1 | # Collab WebSocket Sample 2 | 3 | This sample creates a real-time document collaboration app that will work out-of-box with [WebViewer's WebSocket sample](https://github.com/PDFTron/webviewer-realtime-collaboration-sqlite3-sample). 4 | 5 | ## Prerequisites 6 | 1. Your server is up and running as described [here](https://github.com/PDFTron/webviewer-realtime-collaboration-sqlite3-sample) 7 | 2. You have the IP address of the local host running server from step 1 8 | 3. Open [WSConnection.kt](./app/src/main/java/com/pdftron/realtimecollaborationws/WSConnection.kt) and replace "MY_LOCAL_HOST_IP" with the IP from step 2 9 | 10 | 11 | ## Project structure 12 | ``` 13 | app/ 14 | src/ - Project source files and resources. 15 | build.gradle - Module level Gradle build file. 16 | build.gradle - Project level Gradle build file. 17 | gradle.properties - Project-wide Gradle settings. Contains Apryse license key and credentials. 18 | ``` 19 | 20 | ## License 21 | See [License](./../LICENSE) 22 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/androidTest/java/com/pdftron/realtimecollaborationws/ExampleInstrumentedTest.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.realtimecollaborationws 2 | 3 | import androidx.test.platform.app.InstrumentationRegistry 4 | import androidx.test.ext.junit.runners.AndroidJUnit4 5 | 6 | import org.junit.Test 7 | import org.junit.runner.RunWith 8 | 9 | import org.junit.Assert.* 10 | 11 | /** 12 | * Instrumented test, which will execute on an Android device. 13 | * 14 | * See [testing documentation](http://d.android.com/tools/testing). 15 | */ 16 | @RunWith(AndroidJUnit4::class) 17 | class ExampleInstrumentedTest { 18 | @Test 19 | fun useAppContext() { 20 | // Context of the app under test. 21 | val appContext = InstrumentationRegistry.getInstrumentation().targetContext 22 | assertEquals("com.pdftron.realtimecollaborationws", appContext.packageName) 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 15 | 16 | 19 | 20 | 23 | 24 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/java/com/pdftron/realtimecollaborationws/ServerEvent.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.realtimecollaborationws 2 | 3 | sealed class ServerEvent { 4 | class importXfdfCommand(val xfdfCommand: String) : ServerEvent() 5 | } 6 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 17 | 18 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #008577 4 | #00574B 5 | #D81B60 6 | 7 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | PDFTron WebSocket Demo 3 | 4 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /CollabWebSocketSample/app/src/test/java/com/pdftron/realtimecollaborationws/ExampleUnitTest.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.realtimecollaborationws 2 | 3 | import org.junit.Test 4 | 5 | import org.junit.Assert.* 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * See [testing documentation](http://d.android.com/tools/testing). 11 | */ 12 | class ExampleUnitTest { 13 | @Test 14 | fun addition_isCorrect() { 15 | assertEquals(4, 2 + 2) 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /CollabWebSocketSample/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | ext.kotlin_version = '1.7.20' 5 | repositories { 6 | google() 7 | mavenCentral() 8 | 9 | } 10 | dependencies { 11 | classpath 'com.android.tools.build:gradle:4.2.0' 12 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 13 | // NOTE: Do not place your application dependencies here; they belong 14 | // in the individual module build.gradle files 15 | } 16 | } 17 | 18 | ext.myPdftronRepo = "https://pdftron-maven.s3.amazonaws.com/release" 19 | ext.myPdftronVersion = file("${rootDir}/../pdftron-version.txt").text.trim() 20 | 21 | allprojects { 22 | repositories { 23 | google() 24 | mavenCentral() 25 | maven { 26 | url myPdftronRepo 27 | } 28 | } 29 | } 30 | 31 | task clean(type: Delete) { 32 | delete rootProject.buildDir 33 | } 34 | -------------------------------------------------------------------------------- /CollabWebSocketSample/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | # AndroidX package structure to make it clearer which packages are bundled with the 15 | # Android operating system, and which are packaged with your app's APK 16 | # https://developer.android.com/topic/libraries/support-library/androidx-rn 17 | android.useAndroidX=true 18 | # Automatically convert third-party libraries to use AndroidX 19 | android.enableJetifier=true 20 | # Kotlin code style for this project: "official" or "obsolete": 21 | kotlin.code.style=official 22 | 23 | PDFTRON_LICENSE_KEY=YOUR_PDFTRON_LICENSE_KEY_GOES_HERE -------------------------------------------------------------------------------- /CollabWebSocketSample/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CollabWebSocketSample/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /CollabWebSocketSample/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jun 03 12:28:45 PDT 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /CollabWebSocketSample/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | rootProject.name='CollabWebSocketSample' 3 | -------------------------------------------------------------------------------- /CustomStickyNote/.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.ap_ 4 | 5 | # Files for the ART/Dalvik VM 6 | *.dex 7 | 8 | # Java class files 9 | *.class 10 | 11 | # Generated files 12 | bin/ 13 | gen/ 14 | out/ 15 | 16 | # Gradle files 17 | .gradle/ 18 | build/ 19 | 20 | # Local configuration file (sdk path, etc) 21 | local.properties 22 | 23 | # Proguard folder generated by Eclipse 24 | proguard/ 25 | 26 | # Log Files 27 | *.log 28 | 29 | # Android Studio Navigation editor temp files 30 | .navigation/ 31 | 32 | # Android Studio captures folder 33 | captures/ 34 | 35 | # IntelliJ 36 | *.iml 37 | .idea/workspace.xml 38 | .idea/tasks.xml 39 | .idea/gradle.xml 40 | .idea/assetWizardSettings.xml 41 | .idea/dictionaries 42 | .idea/libraries 43 | .idea/caches 44 | 45 | # Keystore files 46 | # Uncomment the following line if you do not want to check your keystore files in. 47 | #*.jks 48 | 49 | # External native build folder generated in Android Studio 2.2 and later 50 | .externalNativeBuild 51 | 52 | # Google Services (e.g. APIs or Firebase) 53 | google-services.json 54 | 55 | # Freeline 56 | freeline.py 57 | freeline/ 58 | freeline_project_description.json 59 | 60 | # fastlane 61 | fastlane/report.xml 62 | fastlane/Preview.html 63 | fastlane/screenshots 64 | fastlane/test_output 65 | fastlane/readme.md 66 | .idea/codeStyles/Project.xml 67 | .idea/misc.xml 68 | .idea/modules.xml 69 | .idea/runConfigurations.xml 70 | .idea/vcs.xml 71 | .idea/encodings.xml -------------------------------------------------------------------------------- /CustomStickyNote/README.md: -------------------------------------------------------------------------------- 1 | # Custom sticky note sample 2 | 3 | This sample adds a new icon to the Sticky Note icon picker as described [in this guide](https://docs.apryse.com/documentation/android/guides/advanced/customize-color-picker/#customize-the-icon-picker). 4 | 5 | ## Project structure 6 | ``` 7 | app/ 8 | src/ - Project source files and resources. 9 | build.gradle - Module level Gradle build file. 10 | stickynote_icons_default.pdf - PDF file containing default sticky note icon information. 11 | build.gradle - Project level Gradle build file. 12 | gradle.properties - Project-wide Gradle settings. Contains Apryse license key and credentials. 13 | ``` 14 | 15 | ## Resources 16 | - To create a PDF file from SVG image resource, see guide here: [SVG to PDF with Illustrator](https://pdftron.s3.amazonaws.com/custom/ID-zJWLuhTffd3c/mobilechannel_6D420A76/Android-4h7df%5E34jh/custom/galaxyweblinks/video%20-%20svg%20to%20pdf%20icon.mov) 17 | 18 | ## License 19 | See [License](./../LICENSE) 20 | -------------------------------------------------------------------------------- /CustomStickyNote/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /CustomStickyNote/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 33 5 | defaultConfig { 6 | applicationId "com.pdftron.android.samples.pdftron_android_samples" 7 | minSdkVersion 16 8 | targetSdkVersion 33 9 | versionCode 1 10 | versionName "1.0" 11 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" 12 | multiDexEnabled true 13 | vectorDrawables.useSupportLibrary = true 14 | manifestPlaceholders = [pdftronLicenseKey:PDFTRON_LICENSE_KEY] 15 | } 16 | buildTypes { 17 | release { 18 | minifyEnabled false 19 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 20 | } 21 | } 22 | } 23 | 24 | dependencies { 25 | implementation fileTree(include: ['*.jar'], dir: 'libs') 26 | testImplementation 'junit:junit:4.12' 27 | androidTestImplementation 'androidx.test.ext:junit:1.1.1' 28 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' 29 | 30 | // PDFTron SDK dependencies 31 | implementation "com.pdftron:pdftron:$myPdftronVersion" 32 | implementation "com.pdftron:tools:$myPdftronVersion" 33 | 34 | implementation 'androidx.multidex:multidex:2.0.1' 35 | } 36 | -------------------------------------------------------------------------------- /CustomStickyNote/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /CustomStickyNote/app/src/androidTest/java/com/pdftron/android/samples/stickynote/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.android.samples.stickynote; 2 | 3 | import android.content.Context; 4 | import androidx.test.platform.app.InstrumentationRegistry; 5 | import androidx.test.ext.junit.runners.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext(); 23 | 24 | assertEquals("com.pdftron.android.samples.pdftron_android_samples", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/java/com/pdftron/android/samples/stickynote/ReaderActivity.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.android.samples.stickynote; 2 | 3 | import androidx.appcompat.app.AppCompatActivity; 4 | import android.content.Intent; 5 | import android.os.Bundle; 6 | 7 | import com.pdftron.pdf.controls.DocumentActivity; 8 | 9 | /** 10 | * ReaderActivity is just used to start a DocumentActivity so we can try out our new Sticky Note Icon. 11 | */ 12 | public class ReaderActivity extends AppCompatActivity { 13 | 14 | @Override 15 | protected void onCreate(Bundle savedInstanceState) { 16 | super.onCreate(savedInstanceState); 17 | setContentView(R.layout.activity_reader); 18 | // Open our sample document in the 'res/raw' resource folder 19 | 20 | Intent intent = DocumentActivity.IntentBuilder.fromActivityClass(this, DocumentActivity.class) 21 | .withFileRes(R.raw.sample) 22 | .usingNewUi(true) 23 | .build(); 24 | startActivity(intent); 25 | 26 | finish(); 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/drawable/annotation_note_icon_rightarrow_fill.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/drawable/annotation_note_icon_rightarrow_outline.xml: -------------------------------------------------------------------------------- 1 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/layout/activity_reader.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/raw/sample.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/raw/sample.pdf -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/raw/stickynote_icons.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/app/src/main/res/raw/stickynote_icons.pdf -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/values/arrays.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 5 | 6 | Comment 7 | Help 8 | InsertCaret 9 | Star 10 | LightBulb 11 | NewParagraph 12 | CrossMark 13 | CheckMark 14 | LocationPin 15 | ThumbsUp 16 | RightArrow 17 | 18 | 19 | 21 | 27 | 28 | -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | CustomStickyNote 3 | 4 | -------------------------------------------------------------------------------- /CustomStickyNote/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /CustomStickyNote/app/src/test/java/com/pdftron/android/samples/stickynote/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.android.samples.stickynote; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /CustomStickyNote/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | 5 | repositories { 6 | google() 7 | mavenCentral() 8 | } 9 | dependencies { 10 | classpath 'com.android.tools.build:gradle:4.2.0' 11 | 12 | 13 | // NOTE: Do not place your application dependencies here; they belong 14 | // in the individual module build.gradle files 15 | } 16 | } 17 | 18 | ext.myPdftronRepo = "https://pdftron-maven.s3.amazonaws.com/release" 19 | ext.myPdftronVersion = file("${rootDir}/../pdftron-version.txt").text.trim() 20 | 21 | allprojects { 22 | repositories { 23 | google() 24 | mavenCentral() 25 | maven { 26 | url myPdftronRepo 27 | } 28 | } 29 | } 30 | 31 | task clean(type: Delete) { 32 | delete rootProject.buildDir 33 | } 34 | -------------------------------------------------------------------------------- /CustomStickyNote/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | android.enableJetifier=true 10 | android.useAndroidX=true 11 | org.gradle.jvmargs=-Xmx1536m 12 | # When configured, Gradle will run in incubating parallel mode. 13 | # This option should only be used with decoupled projects. More details, visit 14 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 15 | # org.gradle.parallel=true 16 | PDFTRON_LICENSE_KEY=YOUR_PDFTRON_LICENSE_KEY_GOES_HERE -------------------------------------------------------------------------------- /CustomStickyNote/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /CustomStickyNote/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jun 03 12:38:19 PDT 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /CustomStickyNote/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /CustomStickyNote/stickynote_icons_default.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomStickyNote/stickynote_icons_default.pdf -------------------------------------------------------------------------------- /CustomToolSample/README.md: -------------------------------------------------------------------------------- 1 | # Custom tool sample 2 | 3 | This sample demonstrates how to add a custom tool in Android as described [in this guide](https://docs.apryse.com/documentation/android/guides/advanced/custom-tool/). In addition, it also creates another custom stamper tool. 4 | 5 | ## Project structure 6 | ``` 7 | app/ 8 | src/ - Project source files and resources. 9 | build.gradle - Module level Gradle build file. 10 | build.gradle - Project level Gradle build file. 11 | gradle.properties - Project-wide Gradle settings. Contains Apryse license key and credentials. 12 | ``` 13 | 14 | ## License 15 | See [License](./../LICENSE) 16 | -------------------------------------------------------------------------------- /CustomToolSample/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /CustomToolSample/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 33 5 | defaultConfig { 6 | applicationId "com.example.customtoolsample" 7 | minSdkVersion 16 8 | targetSdkVersion 33 9 | versionCode 1 10 | versionName "1.0" 11 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" 12 | multiDexEnabled true 13 | vectorDrawables.useSupportLibrary = true 14 | manifestPlaceholders = [pdftronLicenseKey: PDFTRON_LICENSE_KEY] 15 | } 16 | buildTypes { 17 | release { 18 | minifyEnabled false 19 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' 20 | } 21 | } 22 | } 23 | 24 | dependencies { 25 | implementation fileTree(dir: 'libs', include: ['*.jar']) 26 | testImplementation 'junit:junit:4.12' 27 | androidTestImplementation 'androidx.test.ext:junit:1.1.1' 28 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' 29 | 30 | // PDFTron SDK dependencies 31 | implementation "com.pdftron:pdftron:$myPdftronVersion" 32 | implementation "com.pdftron:tools:$myPdftronVersion" 33 | 34 | implementation 'androidx.multidex:multidex:2.0.1' 35 | } 36 | -------------------------------------------------------------------------------- /CustomToolSample/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /CustomToolSample/app/src/androidTest/java/com/example/customtoolsample/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.example.customtoolsample; 2 | 3 | import android.content.Context; 4 | import androidx.test.platform.app.InstrumentationRegistry; 5 | import androidx.test.ext.junit.runners.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.assertEquals; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext(); 23 | 24 | assertEquals("com.example.customtoolsample", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 19 | 25 | 26 | 27 | 28 | 29 | 30 | 31 | 34 | 35 | 36 | -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/java/com/example/customtoolsample/CustomCloudSquare.java: -------------------------------------------------------------------------------- 1 | package com.example.customtoolsample; 2 | 3 | import androidx.annotation.NonNull; 4 | 5 | import com.pdftron.common.PDFNetException; 6 | import com.pdftron.pdf.Annot; 7 | import com.pdftron.pdf.PDFDoc; 8 | import com.pdftron.pdf.PDFViewCtrl; 9 | import com.pdftron.pdf.Rect; 10 | import com.pdftron.pdf.annots.Markup; 11 | import com.pdftron.pdf.model.ShapeBorderStyle; 12 | import com.pdftron.pdf.tools.RectCreate; 13 | import com.pdftron.pdf.tools.ToolManager; 14 | import com.pdftron.pdf.utils.AnnotUtils; 15 | 16 | public class CustomCloudSquare extends RectCreate { 17 | 18 | // Since this tool creates polygon annotation, use Annot.e_Polygon as parameter. 19 | public static ToolManager.ToolModeBase MODE = 20 | ToolManager.ToolMode.addNewMode(Annot.e_Polygon); 21 | 22 | public CustomCloudSquare(@NonNull PDFViewCtrl ctrl) { 23 | super(ctrl); 24 | } 25 | 26 | @Override 27 | public ToolManager.ToolModeBase getToolMode() { 28 | return MODE; 29 | } 30 | 31 | @Override 32 | protected Annot createMarkup(@NonNull PDFDoc doc, Rect bbox) throws PDFNetException { 33 | Annot annot = super.createMarkup(doc, bbox); 34 | mBorderStyle = ShapeBorderStyle.CLOUDY; 35 | return annot; 36 | } 37 | } 38 | -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/java/com/example/customtoolsample/CustomStamp.java: -------------------------------------------------------------------------------- 1 | package com.example.customtoolsample; 2 | 3 | import android.net.Uri; 4 | import androidx.annotation.NonNull; 5 | 6 | import com.pdftron.pdf.Annot; 7 | import com.pdftron.pdf.PDFViewCtrl; 8 | import com.pdftron.pdf.tools.Stamper; 9 | import com.pdftron.pdf.tools.ToolManager; 10 | import com.pdftron.pdf.utils.Utils; 11 | 12 | import java.io.File; 13 | 14 | public class CustomStamp extends Stamper { 15 | 16 | // Since this tool creates polygon annotation, use Annot.e_Polygon as parameter. 17 | public static ToolManager.ToolModeBase MODE = 18 | ToolManager.ToolMode.addNewMode(Annot.e_Stamp); 19 | 20 | public CustomStamp(@NonNull PDFViewCtrl ctrl) { 21 | super(ctrl); 22 | } 23 | 24 | @Override 25 | public ToolManager.ToolModeBase getToolMode() { 26 | return MODE; 27 | } 28 | 29 | @Override 30 | protected void addStamp() { 31 | File resource = Utils.copyResourceToLocal(mPdfViewCtrl.getContext(), R.raw.pdftronlogo, "PDFTronLogo", "png"); 32 | createImageStamp(Uri.fromFile(resource), 0, null); 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/raw/gettingstarted.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/raw/gettingstarted.pdf -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/raw/pdftronlogo.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/app/src/main/res/raw/pdftronlogo.png -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #008577 4 | #00574B 5 | #D81B60 6 | 7 | -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | CustomToolSample 3 | 4 | -------------------------------------------------------------------------------- /CustomToolSample/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /CustomToolSample/app/src/test/java/com/example/customtoolsample/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.example.customtoolsample; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.assertEquals; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /CustomToolSample/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | repositories { 5 | google() 6 | mavenCentral() 7 | 8 | } 9 | dependencies { 10 | classpath 'com.android.tools.build:gradle:4.2.0' 11 | 12 | // NOTE: Do not place your application dependencies here; they belong 13 | // in the individual module build.gradle files 14 | } 15 | } 16 | 17 | ext.myPdftronRepo = "https://pdftron-maven.s3.amazonaws.com/release" 18 | ext.myPdftronVersion = file("${rootDir}/../pdftron-version.txt").text.trim() 19 | 20 | allprojects { 21 | repositories { 22 | google() 23 | mavenCentral() 24 | maven { 25 | url myPdftronRepo 26 | } 27 | } 28 | } 29 | 30 | task clean(type: Delete) { 31 | delete rootProject.buildDir 32 | } -------------------------------------------------------------------------------- /CustomToolSample/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | PDFTRON_LICENSE_KEY=LICENSE_KEY 15 | android.useAndroidX=true 16 | android.enableJetifier=true 17 | 18 | 19 | -------------------------------------------------------------------------------- /CustomToolSample/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomToolSample/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /CustomToolSample/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jun 03 12:44:39 PDT 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /CustomToolSample/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /CustomUI/.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.ap_ 4 | 5 | # Files for the ART/Dalvik VM 6 | *.dex 7 | 8 | # Java class files 9 | *.class 10 | 11 | # Generated files 12 | bin/ 13 | gen/ 14 | out/ 15 | 16 | # Gradle files 17 | .gradle/ 18 | build/ 19 | 20 | # Local configuration file (sdk path, etc) 21 | local.properties 22 | 23 | # Proguard folder generated by Eclipse 24 | proguard/ 25 | 26 | # Log Files 27 | *.log 28 | 29 | # Android Studio Navigation editor temp files 30 | .navigation/ 31 | 32 | # Android Studio captures folder 33 | captures/ 34 | 35 | # IntelliJ 36 | *.iml 37 | .idea/workspace.xml 38 | .idea/tasks.xml 39 | .idea/gradle.xml 40 | .idea/assetWizardSettings.xml 41 | .idea/dictionaries 42 | .idea/libraries 43 | .idea/caches 44 | 45 | # Keystore files 46 | # Uncomment the following line if you do not want to check your keystore files in. 47 | #*.jks 48 | 49 | # External native build folder generated in Android Studio 2.2 and later 50 | .externalNativeBuild 51 | 52 | # Google Services (e.g. APIs or Firebase) 53 | google-services.json 54 | 55 | # Freeline 56 | freeline.py 57 | freeline/ 58 | freeline_project_description.json 59 | 60 | # fastlane 61 | fastlane/report.xml 62 | fastlane/Preview.html 63 | fastlane/screenshots 64 | fastlane/test_output 65 | fastlane/readme.md 66 | .idea/codeStyles/Project.xml 67 | .idea/misc.xml 68 | .idea/modules.xml 69 | .idea/runConfigurations.xml 70 | .idea/vcs.xml 71 | .idea/encodings.xml -------------------------------------------------------------------------------- /CustomUI/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /CustomUI/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 33 5 | defaultConfig { 6 | applicationId "com.pdftron.android.tutorial.customui" 7 | minSdkVersion 16 8 | targetSdkVersion 33 9 | versionCode 1 10 | versionName "1.0" 11 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" 12 | multiDexEnabled true 13 | vectorDrawables.useSupportLibrary = true 14 | manifestPlaceholders = [pdftronLicenseKey:PDFTRON_LICENSE_KEY] 15 | } 16 | buildTypes { 17 | release { 18 | minifyEnabled false 19 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' 20 | } 21 | } 22 | } 23 | 24 | dependencies { 25 | implementation fileTree(dir: 'libs', include: ['*.jar']) 26 | implementation "com.pdftron:pdftron:$myPdftronVersion" 27 | implementation "com.pdftron:tools:$myPdftronVersion" 28 | implementation 'androidx.multidex:multidex:2.0.1' 29 | testImplementation 'junit:junit:4.12' 30 | androidTestImplementation 'androidx.test.ext:junit:1.1.1' 31 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' 32 | } 33 | -------------------------------------------------------------------------------- /CustomUI/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /CustomUI/app/src/androidTest/java/com/pdftron/android/tutorial/customui/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.android.tutorial.customui; 2 | 3 | import android.content.Context; 4 | import androidx.test.platform.app.InstrumentationRegistry; 5 | import androidx.test.ext.junit.runners.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext(); 23 | 24 | assertEquals("com.pdftron.android.tutorial.customui", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 14 | 17 | 18 | 19 | 20 | 21 | 22 | 23 | 24 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/java/com/pdftron/android/tutorial/customui/custom/CustomAnnotationToolbar.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.android.tutorial.customui.custom; 2 | 3 | import android.content.Context; 4 | import androidx.annotation.NonNull; 5 | 6 | import com.pdftron.android.tutorial.customui.MainActivity; 7 | import com.pdftron.pdf.controls.PdfViewCtrlTabHostFragment2; 8 | import com.pdftron.pdf.widget.toolbar.component.DefaultToolbars; 9 | 10 | /** 11 | * Delegate class that adds a custom annotation toolbar to a PdfViewCtrlTabHostFragment. This sample 12 | * re-arranges items in the annotation toolbar grouping and manually changes the precedence toolbar. 13 | */ 14 | public class CustomAnnotationToolbar extends CustomizationDelegate { 15 | 16 | public CustomAnnotationToolbar(@NonNull Context context, @NonNull PdfViewCtrlTabHostFragment2 tabHostFragment) { 17 | super(context, tabHostFragment); 18 | } 19 | 20 | @Override 21 | public void applyCustomization(@NonNull PdfViewCtrlTabHostFragment2 tabHostFragment2) { 22 | // When document loaded, launch the shapes toolbar 23 | tabHostFragment2.openToolbarWithTag(MainActivity.SHAPES_TOOLBAR_TAG); 24 | // Then automatically select the rectangle tool 25 | tabHostFragment2.selectToolbarButton(DefaultToolbars.ButtonId.SQUARE); 26 | 27 | } 28 | } 29 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/color/selector_tab_text_color.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | 6 | 7 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 9 | 10 | 18 | 19 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/menu/annot_free_hand.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 10 | 13 | 16 | 19 | 22 | 23 | 24 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/menu/annot_free_text.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 10 | 11 | 14 | 15 | 18 | 19 | 22 | 23 | 24 | 26 | 27 | 28 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/menu/annot_general.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/menu/annot_simple_shape.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 7 | 10 | 13 | 16 | 19 | 20 | 21 | 22 | 24 | 25 | 26 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/menu/my_custom_options_toolbar.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 8 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/raw/sample.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/CustomUI/app/src/main/res/raw/sample.pdf -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/values-night/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #212634 4 | #3D4763 5 | 6 | #828694 7 | 8 | #3D4763 9 | 10 | 11 | -------------------------------------------------------------------------------- /CustomUI/app/src/main/res/values-night/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 11 | 12 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /DemoHTML2PDF/app/src/test/java/com/pdftron/demohtml2pdf/ExampleUnitTest.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.demohtml2pdf 2 | 3 | import org.junit.Test 4 | 5 | import org.junit.Assert.* 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * See [testing documentation](http://d.android.com/tools/testing). 11 | */ 12 | class ExampleUnitTest { 13 | @Test 14 | fun addition_isCorrect() { 15 | assertEquals(4, 2 + 2) 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /DemoHTML2PDF/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | ext.kotlin_version = '1.7.20' 5 | repositories { 6 | google() 7 | mavenCentral() 8 | 9 | } 10 | dependencies { 11 | classpath 'com.android.tools.build:gradle:4.2.0' 12 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 13 | // NOTE: Do not place your application dependencies here; they belong 14 | // in the individual module build.gradle files 15 | } 16 | } 17 | 18 | ext.myPdftronRepo = "https://pdftron-maven.s3.amazonaws.com/release" 19 | ext.myPdftronVersion = file("${rootDir}/../pdftron-version.txt").text.trim() 20 | 21 | allprojects { 22 | repositories { 23 | google() 24 | mavenCentral() 25 | maven { 26 | url myPdftronRepo 27 | } 28 | } 29 | } 30 | 31 | task clean(type: Delete) { 32 | delete rootProject.buildDir 33 | } 34 | -------------------------------------------------------------------------------- /DemoHTML2PDF/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | # Kotlin code style for this project: "official" or "obsolete": 15 | kotlin.code.style=official 16 | 17 | android.useAndroidX=true 18 | android.enableJetifier=true 19 | PDFTRON_LICENSE_KEY=YOUR_PDFTRON_LICENSE_KEY_GOES_HERE 20 | -------------------------------------------------------------------------------- /DemoHTML2PDF/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/DemoHTML2PDF/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /DemoHTML2PDF/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jun 03 17:26:43 PDT 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /DemoHTML2PDF/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | Copyright 2019 PDFTron Systems Inc. All rights reserved. 2 | 3 | PDFTron Android Samples project/codebase or any derived works is only permitted 4 | in solutions with an active commercial PDFTron mobile SDK license. 5 | 6 | For exact licensing terms please refer to your commercial PDFTron license. 7 | 8 | For use in other scenarios, please contact sales@pdftron.com -------------------------------------------------------------------------------- /NativeCppExample/.idea/.gitignore: -------------------------------------------------------------------------------- 1 | # Default ignored files 2 | /shelf/ 3 | /workspace.xml 4 | -------------------------------------------------------------------------------- /NativeCppExample/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | /libs/* 3 | /headers/* -------------------------------------------------------------------------------- /NativeCppExample/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/androidTest/java/com/pdftron/nativecppexample/ExampleInstrumentedTest.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.nativecppexample 2 | 3 | import androidx.test.platform.app.InstrumentationRegistry 4 | import androidx.test.ext.junit.runners.AndroidJUnit4 5 | 6 | import org.junit.Test 7 | import org.junit.runner.RunWith 8 | 9 | import org.junit.Assert.* 10 | 11 | /** 12 | * Instrumented test, which will execute on an Android device. 13 | * 14 | * See [testing documentation](http://d.android.com/tools/testing). 15 | */ 16 | @RunWith(AndroidJUnit4::class) 17 | class ExampleInstrumentedTest { 18 | @Test 19 | fun useAppContext() { 20 | // Context of the app under test. 21 | val appContext = InstrumentationRegistry.getInstrumentation().targetContext 22 | assertEquals("com.pdftron.nativecppexample", appContext.packageName) 23 | } 24 | } 25 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 12 | 14 | 15 | 16 | 17 | 18 | 19 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/cpp/native-lib.cpp: -------------------------------------------------------------------------------- 1 | #include 2 | #include 3 | #include 4 | #include 5 | #include 6 | #include 7 | #include 8 | 9 | #include 10 | #include 11 | 12 | 13 | extern "C" JNIEXPORT jstring JNICALL 14 | Java_com_pdftron_nativecppexample_MainActivity_fontListFromJNI( 15 | JNIEnv *env, 16 | jobject /* this */) { 17 | 18 | double version = pdftron::PDFNet::GetVersion(); 19 | // Ask font list to PDFTron 20 | pdftron::UString fonts = pdftron::PDFNet::GetSystemFontList(); 21 | 22 | // Return result 23 | auto utf8String = fonts.ConvertToUtf8(); 24 | return env->NewStringUTF(utf8String.c_str()); 25 | } 26 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/java/com/pdftron/nativecppexample/MainActivity.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.nativecppexample 2 | 3 | import android.os.Bundle 4 | import androidx.appcompat.app.AppCompatActivity 5 | import com.pdftron.pdf.PDFNet 6 | import kotlinx.android.synthetic.main.activity_main.* 7 | 8 | class MainActivity : AppCompatActivity() { 9 | 10 | override fun onCreate(savedInstanceState: Bundle?) { 11 | super.onCreate(savedInstanceState) 12 | setContentView(R.layout.activity_main) 13 | 14 | // Initialize PDFTron, this will start FontConfig 15 | PDFNet.initialize(this, R.raw.pdfnet, "") 16 | 17 | // Font list 18 | sample_text.text = fontListFromJNI() 19 | } 20 | 21 | /** 22 | * A native method that is implemented by the 'native-lib' native library, 23 | * which is packaged with this application. 24 | */ 25 | external fun fontListFromJNI(): String 26 | 27 | companion object { 28 | // Used to load the 'native-lib' library on application startup. 29 | init { 30 | System.loadLibrary("native-lib") 31 | System.loadLibrary("PDFNetC") 32 | } 33 | } 34 | } 35 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 12 | 13 | 22 | 23 | 24 | 25 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/raw/pdfnet.res: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/app/src/main/res/raw/pdfnet.res -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #6200EE 4 | #3700B3 5 | #03DAC5 6 | 7 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | NativeCpp 3 | 4 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /NativeCppExample/app/src/test/java/com/pdftron/nativecppexample/ExampleUnitTest.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.nativecppexample 2 | 3 | import org.junit.Test 4 | 5 | import org.junit.Assert.* 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * See [testing documentation](http://d.android.com/tools/testing). 11 | */ 12 | class ExampleUnitTest { 13 | @Test 14 | fun addition_isCorrect() { 15 | assertEquals(4, 2 + 2) 16 | } 17 | } 18 | -------------------------------------------------------------------------------- /NativeCppExample/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | ext.kotlin_version = '1.3.61' 5 | repositories { 6 | google() 7 | mavenCentral() 8 | } 9 | dependencies { 10 | classpath 'com.android.tools.build:gradle:4.2.0' 11 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 12 | 13 | // NOTE: Do not place your application dependencies here; they belong 14 | // in the individual module build.gradle files 15 | } 16 | } 17 | 18 | allprojects { 19 | repositories { 20 | google() 21 | mavenCentral() 22 | } 23 | } 24 | 25 | task clean(type: Delete) { 26 | delete rootProject.buildDir 27 | } 28 | -------------------------------------------------------------------------------- /NativeCppExample/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | # AndroidX package structure to make it clearer which packages are bundled with the 15 | # Android operating system, and which are packaged with your app's APK 16 | # https://developer.android.com/topic/libraries/support-library/androidx-rn 17 | android.useAndroidX=true 18 | # Automatically convert third-party libraries to use AndroidX 19 | android.enableJetifier=true 20 | # Kotlin code style for this project: "official" or "obsolete": 21 | kotlin.code.style=official 22 | -------------------------------------------------------------------------------- /NativeCppExample/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/NativeCppExample/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /NativeCppExample/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jun 03 17:34:57 PDT 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /NativeCppExample/settings.gradle: -------------------------------------------------------------------------------- 1 | rootProject.name='NativeCpp' 2 | include ':app' 3 | include ':PDFTron' 4 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.ap_ 4 | 5 | # Files for the ART/Dalvik VM 6 | *.dex 7 | 8 | # Java class files 9 | *.class 10 | 11 | # Generated files 12 | bin/ 13 | gen/ 14 | out/ 15 | 16 | # Gradle files 17 | .gradle/ 18 | build/ 19 | 20 | # Local configuration file (sdk path, etc) 21 | local.properties 22 | 23 | # Proguard folder generated by Eclipse 24 | proguard/ 25 | 26 | # Log Files 27 | *.log 28 | 29 | # Android Studio Navigation editor temp files 30 | .navigation/ 31 | 32 | # Android Studio captures folder 33 | captures/ 34 | 35 | # IntelliJ 36 | *.iml 37 | .idea/workspace.xml 38 | .idea/tasks.xml 39 | .idea/gradle.xml 40 | .idea/assetWizardSettings.xml 41 | .idea/dictionaries 42 | .idea/libraries 43 | .idea/caches 44 | 45 | # Keystore files 46 | # Uncomment the following line if you do not want to check your keystore files in. 47 | #*.jks 48 | 49 | # External native build folder generated in Android Studio 2.2 and later 50 | .externalNativeBuild 51 | 52 | # Google Services (e.g. APIs or Firebase) 53 | google-services.json 54 | 55 | # Freeline 56 | freeline.py 57 | freeline/ 58 | freeline_project_description.json 59 | 60 | # fastlane 61 | fastlane/report.xml 62 | fastlane/Preview.html 63 | fastlane/screenshots 64 | fastlane/test_output 65 | fastlane/readme.md 66 | .idea/codeStyles/Project.xml 67 | .idea/misc.xml 68 | .idea/modules.xml 69 | .idea/runConfigurations.xml 70 | .idea/vcs.xml 71 | .idea/encodings.xml -------------------------------------------------------------------------------- /PDFViewCtrlViewer/README.md: -------------------------------------------------------------------------------- 1 | # PDFViewCtrl Viewer 2 | 3 | Viewer integration using PDFViewCtrl and AnnotationToolbar. 4 | 5 | ## Project structure 6 | ``` 7 | app/ 8 | src/ - Project source files and resources. 9 | build.gradle - Module level Gradle build file. 10 | build.gradle - Project level Gradle build file. 11 | gradle.properties - Project-wide Gradle settings. Contains Apryse license key and credentials. 12 | ``` 13 | 14 | ## License 15 | See [License](./../LICENSE) 16 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 33 5 | defaultConfig { 6 | applicationId "com.pdftron.android.pdfviewctrlviewer" 7 | minSdkVersion 16 8 | targetSdkVersion 33 9 | versionCode 1 10 | versionName "1.0" 11 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" 12 | multiDexEnabled true 13 | vectorDrawables.useSupportLibrary = true 14 | manifestPlaceholders = [pdftronLicenseKey:PDFTRON_LICENSE_KEY] 15 | } 16 | buildTypes { 17 | release { 18 | minifyEnabled false 19 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' 20 | } 21 | } 22 | } 23 | 24 | dependencies { 25 | implementation fileTree(dir: 'libs', include: ['*.jar']) 26 | testImplementation 'junit:junit:4.12' 27 | androidTestImplementation 'androidx.test.ext:junit:1.1.1' 28 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' 29 | 30 | // PDFTron SDK dependencies 31 | implementation "com.pdftron:pdftron:$myPdftronVersion" 32 | implementation "com.pdftron:tools:$myPdftronVersion" 33 | implementation 'androidx.multidex:multidex:2.0.1' 34 | } 35 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/androidTest/java/com/pdftron/android/pdfviewctrlviewer/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.android.pdfviewctrlviewer; 2 | 3 | import android.content.Context; 4 | 5 | import org.junit.Test; 6 | import org.junit.runner.RunWith; 7 | 8 | import androidx.test.ext.junit.runners.AndroidJUnit4; 9 | import androidx.test.platform.app.InstrumentationRegistry; 10 | 11 | import static org.junit.Assert.assertEquals; 12 | 13 | /** 14 | * Instrumented test, which will execute on an Android device. 15 | * 16 | * @see Testing documentation 17 | */ 18 | @RunWith(AndroidJUnit4.class) 19 | public class ExampleInstrumentedTest { 20 | @Test 21 | public void useAppContext() { 22 | // Context of the app under test. 23 | Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext(); 24 | 25 | assertEquals("com.pdftron.android.pdfviewctrlviewer", appContext.getPackageName()); 26 | } 27 | } 28 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 8 | 9 | 10 | 20 | 21 | 22 | 25 | 26 | 30 | 31 | 32 | 33 | 34 | 35 | 36 | 37 | 38 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 15 | 16 | 25 | 26 | 33 | 34 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/raw/sample.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/app/src/main/res/raw/sample.pdf -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | PDFViewCtrlViewer 3 | 4 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | 20 | 21 | 22 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/app/src/test/java/com/pdftron/android/pdfviewctrlviewer/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.android.pdfviewctrlviewer; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /PDFViewCtrlViewer/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | repositories { 5 | google() 6 | mavenCentral() 7 | 8 | } 9 | dependencies { 10 | classpath 'com.android.tools.build:gradle:4.2.0' 11 | 12 | // NOTE: Do not place your application dependencies here; they belong 13 | // in the individual module build.gradle files 14 | } 15 | } 16 | 17 | ext.myPdftronRepo = "https://pdftron-maven.s3.amazonaws.com/release" 18 | ext.myPdftronVersion = file("${rootDir}/../pdftron-version.txt").text.trim() 19 | 20 | allprojects { 21 | repositories { 22 | google() 23 | mavenCentral() 24 | maven { 25 | url myPdftronRepo 26 | } 27 | } 28 | } 29 | 30 | task clean(type: Delete) { 31 | delete rootProject.buildDir 32 | } 33 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | 15 | android.enableJetifier=true 16 | android.useAndroidX=true 17 | PDFTRON_LICENSE_KEY=YOUR_PDFTRON_LICENSE_KEY_GOES_HERE 18 | 19 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/PDFViewCtrlViewer/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /PDFViewCtrlViewer/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jun 03 17:44:19 PDT 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /PDFViewCtrlViewer/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.ap_ 4 | 5 | # Files for the ART/Dalvik VM 6 | *.dex 7 | 8 | # Java class files 9 | *.class 10 | 11 | # Generated files 12 | bin/ 13 | gen/ 14 | out/ 15 | 16 | # Gradle files 17 | .gradle/ 18 | build/ 19 | 20 | # Local configuration file (sdk path, etc) 21 | local.properties 22 | 23 | # Proguard folder generated by Eclipse 24 | proguard/ 25 | 26 | # Log Files 27 | *.log 28 | 29 | # Android Studio Navigation editor temp files 30 | .navigation/ 31 | 32 | # Android Studio captures folder 33 | captures/ 34 | 35 | # IntelliJ 36 | *.iml 37 | .idea/workspace.xml 38 | .idea/tasks.xml 39 | .idea/gradle.xml 40 | .idea/assetWizardSettings.xml 41 | .idea/dictionaries 42 | .idea/libraries 43 | .idea/caches 44 | 45 | # Keystore files 46 | # Uncomment the following line if you do not want to check your keystore files in. 47 | #*.jks 48 | 49 | # External native build folder generated in Android Studio 2.2 and later 50 | .externalNativeBuild 51 | 52 | # Google Services (e.g. APIs or Firebase) 53 | google-services.json 54 | 55 | # Freeline 56 | freeline.py 57 | freeline/ 58 | freeline_project_description.json 59 | 60 | # fastlane 61 | fastlane/report.xml 62 | fastlane/Preview.html 63 | fastlane/screenshots 64 | fastlane/test_output 65 | fastlane/readme.md 66 | .idea/codeStyles/Project.xml 67 | .idea/misc.xml 68 | .idea/modules.xml 69 | .idea/runConfigurations.xml 70 | .idea/vcs.xml 71 | .idea/encodings.xml -------------------------------------------------------------------------------- /QuickStartPDFViewer/README.md: -------------------------------------------------------------------------------- 1 | # Android Quick Start Guide: Add a PDF viewer using the Apryse Android SDK 2 | 3 | **This project contains the source code for [this tutorial](https://docs.apryse.com/documentation/android/guides/getting-started/try-demo/).** 4 | ![](https://onepixel.pdftron.com/pdf-viewer-android) 5 | 6 | ## Project structure 7 | ``` 8 | app/ 9 | src/ - Project source files and resources. 10 | build.gradle - Module level Gradle build file. 11 | build.gradle - Project level Gradle build file. 12 | gradle.properties - Project-wide Gradle settings. Contains Apryse license key and credentials. 13 | ``` 14 | 15 | ## License 16 | See [License](./../LICENSE) 17 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 33 5 | defaultConfig { 6 | applicationId "com.pdftron.android.pdfviewer" 7 | minSdkVersion 16 8 | targetSdkVersion 33 9 | versionCode 1 10 | versionName "1.0" 11 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" 12 | multiDexEnabled true 13 | vectorDrawables.useSupportLibrary = true 14 | manifestPlaceholders = [pdftronLicenseKey:PDFTRON_LICENSE_KEY] 15 | } 16 | buildTypes { 17 | release { 18 | minifyEnabled false 19 | proguardFiles getDefaultProguardFile('proguard-android.txt'), 'proguard-rules.pro' 20 | } 21 | } 22 | } 23 | 24 | dependencies { 25 | implementation fileTree(dir: 'libs', include: ['*.jar']) 26 | testImplementation 'junit:junit:4.12' 27 | androidTestImplementation 'androidx.test.ext:junit:1.1.1' 28 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' 29 | 30 | // PDFTron SDK dependencies 31 | implementation "com.pdftron:pdftron:$myPdftronVersion" 32 | implementation "com.pdftron:tools:$myPdftronVersion" 33 | 34 | implementation 'androidx.multidex:multidex:2.0.1' 35 | } 36 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/androidTest/java/com/pdftron/android/pdfviewer/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.android.pdfviewer; 2 | 3 | import android.content.Context; 4 | import androidx.test.platform.app.InstrumentationRegistry; 5 | import androidx.test.ext.junit.runners.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext(); 23 | 24 | assertEquals("com.pdftron.android.pdfviewer", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/raw/sample.pdf: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/app/src/main/res/raw/sample.pdf -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | PDFViewer 3 | 4 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/app/src/test/java/com/pdftron/android/pdfviewer/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.android.pdfviewer; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /QuickStartPDFViewer/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | 5 | repositories { 6 | google() 7 | mavenCentral() 8 | } 9 | dependencies { 10 | classpath 'com.android.tools.build:gradle:4.2.0' 11 | 12 | 13 | // NOTE: Do not place your application dependencies here; they belong 14 | // in the individual module build.gradle files 15 | } 16 | } 17 | 18 | ext.myPdftronRepo = "https://pdftron-maven.s3.amazonaws.com/release" 19 | ext.myPdftronVersion = file("${rootDir}/../pdftron-version.txt").text.trim() 20 | 21 | allprojects { 22 | repositories { 23 | google() 24 | mavenCentral() 25 | maven { 26 | url myPdftronRepo 27 | } 28 | } 29 | } 30 | 31 | task clean(type: Delete) { 32 | delete rootProject.buildDir 33 | } 34 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | 15 | android.enableJetifier=true 16 | android.useAndroidX=true 17 | PDFTRON_LICENSE_KEY=YOUR_PDFTRON_LICENSE_KEY_GOES_HERE 18 | 19 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/QuickStartPDFViewer/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /QuickStartPDFViewer/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jun 03 17:47:22 PDT 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /QuickStartPDFViewer/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /SigningSample/.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.ap_ 4 | 5 | # Files for the ART/Dalvik VM 6 | *.dex 7 | 8 | # Java class files 9 | *.class 10 | 11 | # Generated files 12 | bin/ 13 | gen/ 14 | out/ 15 | 16 | # Gradle files 17 | .gradle/ 18 | build/ 19 | 20 | # Local configuration file (sdk path, etc) 21 | local.properties 22 | 23 | # Proguard folder generated by Eclipse 24 | proguard/ 25 | 26 | # Log Files 27 | *.log 28 | 29 | # Android Studio Navigation editor temp files 30 | .navigation/ 31 | 32 | # Android Studio captures folder 33 | captures/ 34 | 35 | # IntelliJ 36 | *.iml 37 | .idea/workspace.xml 38 | .idea/tasks.xml 39 | .idea/gradle.xml 40 | .idea/assetWizardSettings.xml 41 | .idea/dictionaries 42 | .idea/libraries 43 | .idea/caches 44 | 45 | # Keystore files 46 | # Uncomment the following line if you do not want to check your keystore files in. 47 | #*.jks 48 | 49 | # External native build folder generated in Android Studio 2.2 and later 50 | .externalNativeBuild 51 | 52 | # Google Services (e.g. APIs or Firebase) 53 | google-services.json 54 | 55 | # Freeline 56 | freeline.py 57 | freeline/ 58 | freeline_project_description.json 59 | 60 | # fastlane 61 | fastlane/report.xml 62 | fastlane/Preview.html 63 | fastlane/screenshots 64 | fastlane/test_output 65 | fastlane/readme.md 66 | .idea/codeStyles/Project.xml 67 | .idea/misc.xml 68 | .idea/modules.xml 69 | .idea/runConfigurations.xml 70 | .idea/vcs.xml 71 | .idea/encodings.xml -------------------------------------------------------------------------------- /SigningSample/.idea/.gitignore: -------------------------------------------------------------------------------- 1 | # Default ignored files 2 | /shelf/ 3 | /workspace.xml 4 | -------------------------------------------------------------------------------- /SigningSample/README.md: -------------------------------------------------------------------------------- 1 | # Signing app sample 2 | 3 | This sample demonstrates how to a Signing App in Android as described [in this blog](https://apryse.com/blog/android/build-a-signing-app-in-android). 4 | 5 | Creating Form | Signing Form 6 | --- | --- 7 | ![Creating Form](https://pdftron.s3.amazonaws.com/custom/websitefiles/android/blog/signing/signing-sample-create.gif) | ![Signing Form](https://pdftron.s3.amazonaws.com/custom/websitefiles/android/blog/signing/signing-the-documnet.gif) 8 | 9 | 10 | ## Prerequisites 11 | Due to security reasons, `app/google-services.json` is not included in this repository however is required to run this project. You can obtain your own `google-services.json` by creating and registering your app with Firebase as described [here](https://firebase.google.com/docs/android/setup?authuser=0). 12 | 13 | ## Project structure 14 | ``` 15 | app/ 16 | src/ - Project source files and resources. 17 | build.gradle - Module level Gradle build file. 18 | build.gradle - Project level Gradle build file. 19 | gradle.properties - Project-wide Gradle settings. Contains Apryse license key and credentials. 20 | ``` 21 | 22 | ## License 23 | See [License](./../LICENSE) -------------------------------------------------------------------------------- /SigningSample/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build -------------------------------------------------------------------------------- /SigningSample/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile -------------------------------------------------------------------------------- /SigningSample/app/src/androidTest/java/com/pdftron/pdftronsignapp/ExampleInstrumentedTest.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.pdftronsignapp 2 | 3 | import androidx.test.platform.app.InstrumentationRegistry 4 | import androidx.test.ext.junit.runners.AndroidJUnit4 5 | 6 | import org.junit.Test 7 | import org.junit.runner.RunWith 8 | 9 | import org.junit.Assert.* 10 | 11 | /** 12 | * Instrumented test, which will execute on an Android device. 13 | * 14 | * See [testing documentation](http://d.android.com/tools/testing). 15 | */ 16 | @RunWith(AndroidJUnit4::class) 17 | class ExampleInstrumentedTest { 18 | @Test 19 | fun useAppContext() { 20 | // Context of the app under test. 21 | val appContext = InstrumentationRegistry.getInstrumentation().targetContext 22 | assertEquals("com.pdftron.pdftronsignapp", appContext.packageName) 23 | } 24 | } -------------------------------------------------------------------------------- /SigningSample/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 17 | 18 | 21 | 25 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | -------------------------------------------------------------------------------- /SigningSample/app/src/main/java/com/pdftron/pdftronsignapp/addusertodoc/AddUserToDocAdapter.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.pdftronsignapp.addusertodoc 2 | 3 | import android.view.LayoutInflater 4 | import android.view.View 5 | import android.view.ViewGroup 6 | import androidx.recyclerview.widget.RecyclerView 7 | import com.pdftron.pdftronsignapp.R 8 | import com.pdftron.pdftronsignapp.data.User 9 | import kotlinx.android.synthetic.main.add_user_to_doc_view_holder.view.* 10 | 11 | class AddUserToDocAdapter(private val userList: MutableList): RecyclerView.Adapter() { 12 | override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): AddUserToDocViewHolder { 13 | return AddUserToDocViewHolder.from(parent) 14 | } 15 | 16 | override fun onBindViewHolder(holder: AddUserToDocViewHolder, position: Int) { 17 | val user = userList[position] 18 | holder.itemView.name_txt.text = user.displayName 19 | holder.itemView.email_txt.text = user.email 20 | } 21 | 22 | override fun getItemCount() = userList.count() 23 | } 24 | 25 | class AddUserToDocViewHolder(itemView: View): RecyclerView.ViewHolder(itemView) { 26 | companion object { 27 | fun from(parent: ViewGroup): AddUserToDocViewHolder { 28 | val layoutInflater = LayoutInflater.from(parent.context) 29 | val view = layoutInflater.inflate(R.layout.add_user_to_doc_view_holder, parent, false) 30 | return AddUserToDocViewHolder(view) 31 | } 32 | } 33 | } -------------------------------------------------------------------------------- /SigningSample/app/src/main/java/com/pdftron/pdftronsignapp/customtool/DateFieldCreate.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.pdftronsignapp.customtool 2 | 3 | import com.pdftron.common.PDFNetException 4 | import com.pdftron.pdf.* 5 | import com.pdftron.pdf.tools.TextFieldCreate 6 | import com.pdftron.pdf.tools.ToolManager 7 | import com.pdftron.sdf.Obj 8 | 9 | class DateFieldCreate(ctrl: PDFViewCtrl): TextFieldCreate(ctrl) { 10 | 11 | companion object { 12 | val MODE: ToolManager.ToolModeBase = ToolManager.ToolMode.addNewMode(Annot.e_Widget) 13 | } 14 | 15 | override fun getToolMode(): ToolManager.ToolModeBase { 16 | return MODE 17 | } 18 | 19 | @Throws(PDFNetException::class) 20 | override fun createMarkup(pdfDoc: PDFDoc, bbox: Rect?): Annot? { 21 | val widget = super.createMarkup(pdfDoc, bbox) 22 | val dateAction: Action = Action.createJavaScript( 23 | pdfDoc, 24 | "AFDate_FormatEx(\"d/m/yy\");" 25 | ) 26 | val aaObj: Obj = widget.sdfObj.putDict("AA") 27 | aaObj.put("K", dateAction.sdfObj) 28 | aaObj.put("F", dateAction.sdfObj) 29 | return widget 30 | } 31 | } -------------------------------------------------------------------------------- /SigningSample/app/src/main/java/com/pdftron/pdftronsignapp/data/DocumentToSign.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.pdftronsignapp.data 2 | 3 | import com.google.firebase.Timestamp 4 | 5 | data class DocumentToSign( 6 | var docId: String = "", 7 | val uid: String, 8 | val email: String, 9 | val docRef: String, 10 | val emails: List, 11 | val requestedTime: Timestamp, 12 | var signed: Boolean, 13 | val signedBy: MutableList, 14 | var signedTime: Timestamp?, 15 | val xfdf: MutableList 16 | ) 17 | -------------------------------------------------------------------------------- /SigningSample/app/src/main/java/com/pdftron/pdftronsignapp/data/User.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.pdftronsignapp.data 2 | 3 | data class User ( 4 | val displayName: String, 5 | val email: String, 6 | val photoURL: String 7 | ) -------------------------------------------------------------------------------- /SigningSample/app/src/main/java/com/pdftron/pdftronsignapp/home/SignedDocumentAdapter.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.pdftronsignapp.home 2 | 3 | import android.view.ViewGroup 4 | import androidx.recyclerview.widget.RecyclerView 5 | import com.pdftron.pdftronsignapp.R 6 | import com.pdftron.pdftronsignapp.data.DocumentToSign 7 | import kotlinx.android.synthetic.main.document_to_sign_view_holder.view.* 8 | import java.text.SimpleDateFormat 9 | 10 | class SignedDocumentAdapter(private val signedDocs: MutableList, val signClicked: (DocumentToSign)->Unit): RecyclerView.Adapter() { 11 | override fun onCreateViewHolder(parent: ViewGroup, viewType: Int): DocumentToSignViewHolder { 12 | return DocumentToSignViewHolder.from(parent) 13 | } 14 | 15 | override fun onBindViewHolder(holder: DocumentToSignViewHolder, position: Int) { 16 | val document = signedDocs[position] 17 | holder.itemView.from_txt.text = document.email 18 | val sdf = SimpleDateFormat("dd MMM yyyy hh:mm") 19 | if(document.signedTime != null) { 20 | val requestedTime = sdf.format(document.signedTime!!.toDate()) 21 | holder.itemView.when_txt.text = requestedTime 22 | } 23 | holder.itemView.when_lbl.text = holder.itemView.context.getString(R.string.signed) 24 | holder.itemView.sign_btn.text = holder.itemView.context.getString(R.string.view) 25 | holder.itemView.sign_btn.setOnClickListener { signClicked(document) } 26 | } 27 | 28 | override fun getItemCount() = signedDocs.count() 29 | } -------------------------------------------------------------------------------- /SigningSample/app/src/main/java/com/pdftron/pdftronsignapp/listeners/MyBasicAnnotationListener.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.pdftronsignapp.listeners 2 | 3 | import android.app.AlertDialog 4 | import android.os.Bundle 5 | import com.pdftron.pdf.Annot 6 | import com.pdftron.pdf.tools.ToolManager 7 | import com.pdftron.pdftronsignapp.data.User 8 | 9 | class MyBasicAnnotationListener: ToolManager.BasicAnnotationListener { 10 | private lateinit var currentUser: User 11 | 12 | override fun onAnnotationSelected(p0: Annot?, p1: Int) { 13 | 14 | } 15 | 16 | override fun onAnnotationUnselected() { 17 | } 18 | 19 | override fun onInterceptAnnotationHandling( 20 | annot: Annot?, 21 | extra: Bundle?, 22 | toolMode: ToolManager.ToolMode? 23 | ): Boolean { 24 | try { 25 | val annotEmail = annot?.getCustomData("email") 26 | if (annotEmail.isNullOrEmpty()) { 27 | annot?.setCustomData("email", currentUser.email) 28 | } 29 | } catch (e: Exception) { 30 | e.printStackTrace() 31 | } 32 | // return false so the other events can continue executing 33 | return false 34 | } 35 | 36 | override fun onInterceptDialog(p0: AlertDialog?): Boolean { 37 | return false 38 | } 39 | 40 | fun setCurrentUser(selectedUser: User){ 41 | currentUser = selectedUser 42 | } 43 | } -------------------------------------------------------------------------------- /SigningSample/app/src/main/java/com/pdftron/pdftronsignapp/util/CustomButtonId.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.pdftronsignapp.util 2 | 3 | class CustomButtonId { 4 | companion object{ 5 | val SIGNATURE_FIELD = 10 6 | val TEXT_FIELD = 11 7 | val DATE = 12 8 | } 9 | } -------------------------------------------------------------------------------- /SigningSample/app/src/main/java/com/pdftron/pdftronsignapp/util/RequestCode.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.pdftronsignapp.util 2 | 3 | class RequestCode { 4 | companion object{ 5 | val PERMISSIONS_REQUEST_CODE = 101 6 | val FILE_REQUEST_CODE = 102 7 | val GOOGLE_SIGN_IN = 103 8 | } 9 | } -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/layout/bottom_bar_view_holder.xml: -------------------------------------------------------------------------------- 1 | 2 | 10 | 11 | 15 | 16 | 31 | 32 | -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/layout/progress_dialog.xml: -------------------------------------------------------------------------------- 1 | 2 | 7 | 8 | 22 | 23 | 35 | -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/values-night/themes.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 16 | -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #FFBB86FC 4 | #FF6200EE 5 | #FF3700B3 6 | #FF03DAC5 7 | #FF018786 8 | #FF000000 9 | #FFFFFFFF 10 | -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/values/dimens.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 16dp 4 | 16dp 5 | -------------------------------------------------------------------------------- /SigningSample/app/src/main/res/values/themes.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 16 | -------------------------------------------------------------------------------- /SigningSample/app/src/test/java/com/pdftron/pdftronsignapp/ExampleUnitTest.kt: -------------------------------------------------------------------------------- 1 | package com.pdftron.pdftronsignapp 2 | 3 | import org.junit.Test 4 | 5 | import org.junit.Assert.* 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * See [testing documentation](http://d.android.com/tools/testing). 11 | */ 12 | class ExampleUnitTest { 13 | @Test 14 | fun addition_isCorrect() { 15 | assertEquals(4, 2 + 2) 16 | } 17 | } -------------------------------------------------------------------------------- /SigningSample/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | buildscript { 3 | ext.kotlin_version = "1.7.20" 4 | repositories { 5 | google() 6 | mavenCentral() 7 | } 8 | dependencies { 9 | classpath 'com.android.tools.build:gradle:4.2.0' 10 | classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version" 11 | classpath 'com.google.gms:google-services:4.3.5' 12 | // NOTE: Do not place your application dependencies here; they belong 13 | // in the individual module build.gradle files 14 | } 15 | } 16 | 17 | ext.myPdftronRepo = "https://pdftron-maven.s3.amazonaws.com/release" 18 | ext.myPdftronVersion = file("${rootDir}/../pdftron-version.txt").text.trim() 19 | 20 | allprojects { 21 | repositories { 22 | google() 23 | mavenCentral() 24 | maven { 25 | url myPdftronRepo 26 | } 27 | } 28 | } 29 | 30 | task clean(type: Delete) { 31 | delete rootProject.buildDir 32 | } -------------------------------------------------------------------------------- /SigningSample/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx2048m -Dfile.encoding=UTF-8 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | # AndroidX package structure to make it clearer which packages are bundled with the 15 | # Android operating system, and which are packaged with your app"s APK 16 | # https://developer.android.com/topic/libraries/support-library/androidx-rn 17 | android.useAndroidX=true 18 | # Automatically convert third-party libraries to use AndroidX 19 | android.enableJetifier=true 20 | # Kotlin code style for this project: "official" or "obsolete": 21 | kotlin.code.style=official 22 | 23 | # Add the PDFTRON_LICENSE_KEY variable here. 24 | # For trial purposes leave it blank. 25 | # For production add a valid commercial license key. 26 | PDFTRON_LICENSE_KEY= -------------------------------------------------------------------------------- /SigningSample/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/SigningSample/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /SigningSample/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jun 03 17:50:02 PDT 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /SigningSample/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | rootProject.name = "PDFTron Sign App" -------------------------------------------------------------------------------- /StandardPDFViewer/.gitignore: -------------------------------------------------------------------------------- 1 | # Built application files 2 | *.apk 3 | *.ap_ 4 | 5 | # Files for the ART/Dalvik VM 6 | *.dex 7 | 8 | # Java class files 9 | *.class 10 | 11 | # Generated files 12 | bin/ 13 | gen/ 14 | out/ 15 | 16 | # Gradle files 17 | .gradle/ 18 | build/ 19 | 20 | # Local configuration file (sdk path, etc) 21 | local.properties 22 | 23 | # Proguard folder generated by Eclipse 24 | proguard/ 25 | 26 | # Log Files 27 | *.log 28 | 29 | # Android Studio Navigation editor temp files 30 | .navigation/ 31 | 32 | # Android Studio captures folder 33 | captures/ 34 | 35 | # IntelliJ 36 | *.iml 37 | .idea/workspace.xml 38 | .idea/tasks.xml 39 | .idea/gradle.xml 40 | .idea/assetWizardSettings.xml 41 | .idea/dictionaries 42 | .idea/libraries 43 | .idea/caches 44 | 45 | # Keystore files 46 | # Uncomment the following line if you do not want to check your keystore files in. 47 | #*.jks 48 | 49 | # External native build folder generated in Android Studio 2.2 and later 50 | .externalNativeBuild 51 | 52 | # Google Services (e.g. APIs or Firebase) 53 | google-services.json 54 | 55 | # Freeline 56 | freeline.py 57 | freeline/ 58 | freeline_project_description.json 59 | 60 | # fastlane 61 | fastlane/report.xml 62 | fastlane/Preview.html 63 | fastlane/screenshots 64 | fastlane/test_output 65 | fastlane/readme.md 66 | .idea/codeStyles/Project.xml 67 | .idea/misc.xml 68 | .idea/modules.xml 69 | .idea/runConfigurations.xml 70 | .idea/vcs.xml 71 | .idea/encodings.xml -------------------------------------------------------------------------------- /StandardPDFViewer/README.md: -------------------------------------------------------------------------------- 1 | # Standard PDF viewer sample 2 | 3 | This sample shows the minimum set of integration required to display a PDF document. It integrates with the [standard version](https://docs.apryse.com/documentation/android/faq/full-vs-standard/) of Apryse Android SDK for minimum APK size. 4 | 5 | ## Project structure 6 | ``` 7 | app/ 8 | src/ - Project source files and resources. 9 | build.gradle - Module level Gradle build file. 10 | build.gradle - Project level Gradle build file. 11 | gradle.properties - Project-wide Gradle settings. Contains Apryse license key and credentials. 12 | ``` 13 | 14 | ## License 15 | See [License](./../LICENSE) 16 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/.gitignore: -------------------------------------------------------------------------------- 1 | /build 2 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/build.gradle: -------------------------------------------------------------------------------- 1 | apply plugin: 'com.android.application' 2 | 3 | android { 4 | compileSdkVersion 33 5 | defaultConfig { 6 | applicationId "com.pdftron.standardpdfviewer" 7 | minSdkVersion 16 8 | targetSdkVersion 33 9 | versionCode 1 10 | versionName "1.0" 11 | testInstrumentationRunner "androidx.test.runner.AndroidJUnitRunner" 12 | multiDexEnabled true 13 | vectorDrawables.useSupportLibrary = true 14 | manifestPlaceholders = [pdftronLicenseKey:PDFTRON_LICENSE_KEY] 15 | } 16 | buildTypes { 17 | release { 18 | minifyEnabled false 19 | proguardFiles getDefaultProguardFile('proguard-android-optimize.txt'), 'proguard-rules.pro' 20 | } 21 | } 22 | } 23 | 24 | dependencies { 25 | implementation fileTree(dir: 'libs', include: ['*.jar']) 26 | testImplementation 'junit:junit:4.12' 27 | androidTestImplementation 'androidx.test.ext:junit:1.1.1' 28 | androidTestImplementation 'androidx.test.espresso:espresso-core:3.2.0' 29 | 30 | // PDFTron SDK dependencies 31 | implementation "com.pdftron:pdftron-standard:$myPdftronVersion" 32 | implementation "com.pdftron:tools:$myPdftronVersion" 33 | 34 | implementation 'androidx.multidex:multidex:2.0.1' 35 | } 36 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/proguard-rules.pro: -------------------------------------------------------------------------------- 1 | # Add project specific ProGuard rules here. 2 | # You can control the set of applied configuration files using the 3 | # proguardFiles setting in build.gradle. 4 | # 5 | # For more details, see 6 | # http://developer.android.com/guide/developing/tools/proguard.html 7 | 8 | # If your project uses WebView with JS, uncomment the following 9 | # and specify the fully qualified class name to the JavaScript interface 10 | # class: 11 | #-keepclassmembers class fqcn.of.javascript.interface.for.webview { 12 | # public *; 13 | #} 14 | 15 | # Uncomment this to preserve the line number information for 16 | # debugging stack traces. 17 | #-keepattributes SourceFile,LineNumberTable 18 | 19 | # If you keep the line number information, uncomment this to 20 | # hide the original source file name. 21 | #-renamesourcefileattribute SourceFile 22 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/androidTest/java/com/pdftron/standardpdfviewer/ExampleInstrumentedTest.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.standardpdfviewer; 2 | 3 | import android.content.Context; 4 | import androidx.test.platform.app.InstrumentationRegistry; 5 | import androidx.test.ext.junit.runners.AndroidJUnit4; 6 | 7 | import org.junit.Test; 8 | import org.junit.runner.RunWith; 9 | 10 | import static org.junit.Assert.*; 11 | 12 | /** 13 | * Instrumented test, which will execute on an Android device. 14 | * 15 | * @see Testing documentation 16 | */ 17 | @RunWith(AndroidJUnit4.class) 18 | public class ExampleInstrumentedTest { 19 | @Test 20 | public void useAppContext() { 21 | // Context of the app under test. 22 | Context appContext = InstrumentationRegistry.getInstrumentation().getTargetContext(); 23 | 24 | assertEquals("com.pdftron.standardpdfviewer", appContext.getPackageName()); 25 | } 26 | } 27 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/AndroidManifest.xml: -------------------------------------------------------------------------------- 1 | 2 | 4 | 5 | 6 | 7 | 15 | 16 | 19 | 20 | 24 | 25 | 27 | 28 | 29 | 30 | 31 | 32 | 33 | 34 | 35 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/java/com/pdftron/standardpdfviewer/MainActivity.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.standardpdfviewer; 2 | 3 | import android.content.Intent; 4 | import android.net.Uri; 5 | import android.os.Bundle; 6 | import androidx.appcompat.app.AppCompatActivity; 7 | 8 | import com.pdftron.pdf.PDFViewCtrl; 9 | import com.pdftron.pdf.config.ViewerConfig; 10 | import com.pdftron.pdf.controls.DocumentActivity; 11 | 12 | public class MainActivity extends AppCompatActivity { 13 | 14 | @Override 15 | protected void onCreate(Bundle savedInstanceState) { 16 | super.onCreate(savedInstanceState); 17 | setContentView(R.layout.activity_main); 18 | 19 | // uncomment to use PDFViewCtrl only 20 | // PDFViewCtrl pdfViewCtrl = findViewById(R.id.pdfviewctrl); 21 | // try { 22 | // pdfViewCtrl.openPDFUri(Uri.parse("https://pdftron.s3.amazonaws.com/downloads/pdfref.pdf"), null); 23 | // } catch (Exception ex) { 24 | // ex.printStackTrace(); 25 | // } 26 | 27 | boolean newUi = true; 28 | 29 | ViewerConfig.Builder builder = new ViewerConfig.Builder() 30 | .useStandardLibrary(true) 31 | .openUrlCachePath(this.getCacheDir().getAbsolutePath()) 32 | .saveCopyExportPath(this.getCacheDir().getAbsolutePath()); 33 | Intent intent = DocumentActivity.IntentBuilder.fromActivityClass(this, DocumentActivity.class) 34 | .withUri(Uri.parse("https://pdftron.s3.amazonaws.com/downloads/pl/PDFTRON_mobile_about.pdf")) 35 | .usingConfig(builder.build()) 36 | .usingNewUi(newUi) 37 | .build(); 38 | startActivity(intent); 39 | finish(); 40 | } 41 | } 42 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/layout/activity_main.xml: -------------------------------------------------------------------------------- 1 | 2 | 8 | 9 | 14 | 15 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-anydpi-v26/ic_launcher.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-anydpi-v26/ic_launcher_round.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 5 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-hdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/app/src/main/res/mipmap-hdpi/ic_launcher.png -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-hdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/app/src/main/res/mipmap-hdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-mdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/app/src/main/res/mipmap-mdpi/ic_launcher.png -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-mdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/app/src/main/res/mipmap-mdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-xhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/app/src/main/res/mipmap-xhdpi/ic_launcher.png -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/app/src/main/res/mipmap-xhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/app/src/main/res/mipmap-xxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher.png -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/app/src/main/res/mipmap-xxxhdpi/ic_launcher_round.png -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/values/colors.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | #008577 4 | #00574B 5 | #D81B60 6 | 7 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/values/strings.xml: -------------------------------------------------------------------------------- 1 | 2 | StandardPDFViewer 3 | 4 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/main/res/values/styles.xml: -------------------------------------------------------------------------------- 1 | 2 | 3 | 4 | 10 | 11 | 12 | -------------------------------------------------------------------------------- /StandardPDFViewer/app/src/test/java/com/pdftron/standardpdfviewer/ExampleUnitTest.java: -------------------------------------------------------------------------------- 1 | package com.pdftron.standardpdfviewer; 2 | 3 | import org.junit.Test; 4 | 5 | import static org.junit.Assert.*; 6 | 7 | /** 8 | * Example local unit test, which will execute on the development machine (host). 9 | * 10 | * @see Testing documentation 11 | */ 12 | public class ExampleUnitTest { 13 | @Test 14 | public void addition_isCorrect() { 15 | assertEquals(4, 2 + 2); 16 | } 17 | } -------------------------------------------------------------------------------- /StandardPDFViewer/build.gradle: -------------------------------------------------------------------------------- 1 | // Top-level build file where you can add configuration options common to all sub-projects/modules. 2 | 3 | buildscript { 4 | repositories { 5 | google() 6 | mavenCentral() 7 | 8 | } 9 | dependencies { 10 | classpath 'com.android.tools.build:gradle:4.2.0' 11 | 12 | // NOTE: Do not place your application dependencies here; they belong 13 | // in the individual module build.gradle files 14 | } 15 | } 16 | 17 | ext.myPdftronRepo = "https://pdftron-maven.s3.amazonaws.com/release" 18 | ext.myPdftronVersion = file("${rootDir}/../pdftron-version.txt").text.trim() 19 | 20 | allprojects { 21 | repositories { 22 | google() 23 | mavenCentral() 24 | maven { 25 | url myPdftronRepo 26 | } 27 | } 28 | } 29 | 30 | task clean(type: Delete) { 31 | delete rootProject.buildDir 32 | } 33 | -------------------------------------------------------------------------------- /StandardPDFViewer/gradle.properties: -------------------------------------------------------------------------------- 1 | # Project-wide Gradle settings. 2 | # IDE (e.g. Android Studio) users: 3 | # Gradle settings configured through the IDE *will override* 4 | # any settings specified in this file. 5 | # For more details on how to configure your build environment visit 6 | # http://www.gradle.org/docs/current/userguide/build_environment.html 7 | # Specifies the JVM arguments used for the daemon process. 8 | # The setting is particularly useful for tweaking memory settings. 9 | org.gradle.jvmargs=-Xmx1536m 10 | # When configured, Gradle will run in incubating parallel mode. 11 | # This option should only be used with decoupled projects. More details, visit 12 | # http://www.gradle.org/docs/current/userguide/multi_project_builds.html#sec:decoupled_projects 13 | # org.gradle.parallel=true 14 | 15 | android.enableJetifier=true 16 | android.useAndroidX=true 17 | PDFTRON_LICENSE_KEY=YOUR_PDFTRON_LICENSE_KEY_GOES_HERE -------------------------------------------------------------------------------- /StandardPDFViewer/gradle/wrapper/gradle-wrapper.jar: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/ApryseSDK/pdftron-android-samples/bf3297e0aec042e1ad97d6cbfb6d25bfc632e923/StandardPDFViewer/gradle/wrapper/gradle-wrapper.jar -------------------------------------------------------------------------------- /StandardPDFViewer/gradle/wrapper/gradle-wrapper.properties: -------------------------------------------------------------------------------- 1 | #Thu Jun 03 18:03:24 PDT 2021 2 | distributionBase=GRADLE_USER_HOME 3 | distributionUrl=https\://services.gradle.org/distributions/gradle-6.7.1-bin.zip 4 | distributionPath=wrapper/dists 5 | zipStorePath=wrapper/dists 6 | zipStoreBase=GRADLE_USER_HOME 7 | -------------------------------------------------------------------------------- /StandardPDFViewer/settings.gradle: -------------------------------------------------------------------------------- 1 | include ':app' 2 | -------------------------------------------------------------------------------- /pdftron-version.txt: -------------------------------------------------------------------------------- 1 | 11.5.0 --------------------------------------------------------------------------------