Skip to content

Commit

Permalink
Release 4.0.0
Browse files Browse the repository at this point in the history
  • Loading branch information
PSPDFKit committed Nov 1, 2024
1 parent 6e9787c commit e4129c5
Show file tree
Hide file tree
Showing 97 changed files with 12,929 additions and 982 deletions.
90 changes: 90 additions & 0 deletions ACKNOWLEDGEMENTS.md
Original file line number Diff line number Diff line change
Expand Up @@ -461,6 +461,36 @@ FROM, OUT OF THE USE OR INABILITY TO USE THE FONT SOFTWARE OR FROM
OTHER DEALINGS IN THE FONT SOFTWARE.


--------------------------------------------------------------------------------
// Copyright 2015 The Chromium Authors
//
// Redistribution and use in source and binary forms, with or without
// modification, are permitted provided that the following conditions are
// met:
//
// * Redistributions of source code must retain the above copyright
// notice, this list of conditions and the following disclaimer.
// * Redistributions in binary form must reproduce the above
// copyright notice, this list of conditions and the following disclaimer
// in the documentation and/or other materials provided with the
// distribution.
// * Neither the name of Google LLC nor the names of its
// contributors may be used to endorse or promote products derived from
// this software without specific prior written permission.
//
// THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS
// "AS IS" AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT
// LIMITED TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR
// A PARTICULAR PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT
// OWNER OR CONTRIBUTORS BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL,
// SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
// LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
// DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
// THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
// (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
// OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.


--------------------------------------------------------------------------------
## clipper2 (http://www.angusj.com/delphi/clipper.php)

Expand Down Expand Up @@ -1786,6 +1816,36 @@ THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.


--------------------------------------------------------------------------------
Copyright 2006 Google Inc. All Rights Reserved.
Author: [email protected] (Adam Langley)

Copyright (C) 2006 Google Inc.

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

This software is a description of processes which may be patented.

Use of this software may require patent licenses in some countries.
You are directed to annex I of the JBIG2 specification for information.

Some information could be found at:
http://www.jpeg.org/jbig/index.html
http://www.cl.cam.ac.uk/~mgk25/jbigkit/patents/
http://www.jpeg.org/public/fcd14492.pdf
http://itscj.ipsj.or.jp/sc29/open/29view/29n55161.doc


--------------------------------------------------------------------------------
## koin (https://github.com/InsertKoinIO/koin)

Expand Down Expand Up @@ -3068,6 +3128,36 @@ I, Matt McCutchen, the sole author of the original Big Integer Library, waive my
copyright to it, placing it in the public domain. The library comes with
absolutely no warranty.

--------------------------------------------------------------------------------
MIT License

Copyright (c) 2021 The fast_float authors

Permission is hereby granted, free of charge, to any
person obtaining a copy of this software and associated
documentation files (the "Software"), to deal in the
Software without restriction, including without
limitation the rights to use, copy, modify, merge,
publish, distribute, sublicense, and/or sell copies of
the Software, and to permit persons to whom the Software
is furnished to do so, subject to the following
conditions:

The above copyright notice and this permission notice
shall be included in all copies or substantial portions
of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF
ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED
TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A
PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT
SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR
IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
DEALINGS IN THE SOFTWARE.


--------------------------------------------------------------------------------
## FreeType (www.freetype.org)

Expand Down
15 changes: 13 additions & 2 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,5 +1,18 @@
## Newest Release

### 4.0.0 - 01 Nov 2024

- Adds Pigeon for communication between Flutter and native iOS and Android platforms. (J#HYB-455)
- Fixes issue where annotation preset configurations are not applied to some annotation tools. (J#HYB-185)
- Fixes inconsistency in the `applyInstantJson` method parameter type. It now accepts a string on both iOS and Android. (#45541)
- Updates for Nutrient Android SDK 2024.6.1. (#45458)
- Updates for Nutrient iOS SDK 14.1.1. (#45458)
- Updates for Nutrient Web SDK 2024.7.0. (#45458)

## Previous Releases

### 3.12.0 - 30 Jul 2024

### 3.12.1 - 11 Sep 2024

- Updates for PSPDFKit 2024.5.1 for Android. (J#HYB-506)
Expand All @@ -8,8 +21,6 @@
- Fixes an issue where some annotation toolbar items are not displayed when custom grouping is used. (J#HYB-440)
- Fixes an issue where `onDocumentLoaded` is triggered multiple times. (J#HYB-494)

## Previous Releases

### 3.12.0 - 30 Jul 2024

- Adds `zoomToRect` and `getVisibleRect` APIs to `PspdfkitWidgetController`. (J#HYB-429)
Expand Down
104 changes: 52 additions & 52 deletions README.md
Original file line number Diff line number Diff line change
@@ -1,23 +1,22 @@
# Flutter PDF Library by PSPDFKit
# Flutter PDF Library by Nutrient

![Flutter Intro](screenshots/flutter-intro.png)
![Flutter Intro](screenshots/flutter.png)

PSPDFKit for Flutter is an SDK for viewing, annotating, and editing PDFs. It offers developers the ability to quickly add PDF functionality to any Flutter application. It is available at [pub.dev](https://pub.dev/packages/pspdfkit_flutter) and [GitHub](https://github.com/PSPDFKit/pspdfkit-flutter).
Nutrient Flutter SDK is for viewing, annotating, and editing PDFs. It offers developers the ability to quickly add PDF functionality to any Flutter application. It is available at [pub.dev][pub_dev] and [GitHub][github].

If you are new to Flutter, make sure to check our Flutter blog posts:

- [How I Got Started With Flutter](https://pspdfkit.com/blog/2018/starting-with-flutter/).
- [Getting Started with Flutter PDF Library by PSPDFKit](https://pspdfkit.com/blog/2019/getting-started-with-pspdfkit-flutter/).
- [Opening a PDF in Flutter](https://pspdfkit.com/blog/2019/opening-a-pdf-in-flutter/).
- [How to Bridge Native iOS Code to Flutter](https://pspdfkit.com/blog/2021/how-to-bridge-native-ios-code-to-flutter/).
- [How to Customize Our Flutter PDF SDK for Android](https://pspdfkit.com/blog/2021/how-to-customize-our-flutter-pdf-sdk/).
- [Advances in Hybrid Technologies](https://pspdfkit.com/blog/2019/advances-in-hybrid-technologies/).
- [How We Maintain Our Public Flutter Project Using a Private Monorepo](https://pspdfkit.com/blog/2021/maintaining-open-source-repo-from-monorepo/).
- [How to Download and Display a PDF Document in Flutter with PSPDFKit](https://pspdfkit.com/blog/2022/download-and-display-pdf-in-flutter-with-pspdfkit/).
- [Getting Started with Flutter PDF Library by Nutrient][blog_getting_started_with_pspdfkit_flutter].
- [Opening a PDF in Flutter][blog_opening_a_pdf_in_flutter].
- [How to Customize Our Flutter PDF SDK][blog_customize_flutter_pdf_sdk_android].
- [Advances in Hybrid Technologies][blog_advances_in_hybrid_technologies].
- [How We Maintain Our Public Flutter Project Using a Private Monorepo][blog_maintaining_open_source_repo_from_monorepo].
- [How to Download and Display a PDF Document in Flutter with Nutrient][blog_download_display_pdf_in_flutter_with_pspdfkit].

For our quick-start guides, [check out our website](https://pspdfkit.com/getting-started/mobile/?frontend=flutter).
For our quick-start guides, [check out our website][quick_start_guides].

Platform specific README exists for [Android][android_readme] and [iOS][ios_readme].

Platform specific README exists for [Android](android/) and [iOS](ios/).

# Setup

Expand Down Expand Up @@ -153,7 +152,7 @@ Platform specific README exists for [Android](android/) and [iOS](ios/).
- jvmTarget = '1.8'
+ jvmTarget = '17'
}
...
...
}
```
6. Add the AppCompat AndroidX library to your `android/app/build.gradle` file:
Expand Down Expand Up @@ -184,14 +183,14 @@ Platform specific README exists for [Android](android/) and [iOS](ios/).
Alternatively you can update the `AndroidManifest.xml` file to use `FlutterAppCompatActivity` as the launcher activity:
```diff
<activity
- android:name=".MainActivity"
+ android:name="io.flutter.embedding.android.FlutterAppCompatActivity"
android:launchMode="singleTop"
android:theme="@style/LaunchTheme"
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
android:hardwareAccelerated="true"
android:windowSoftInputMode="adjustResize"
<activity
- android:name=".MainActivity"
+ android:name="io.flutter.embedding.android.FlutterAppCompatActivity"
android:launchMode="singleTop"
android:theme="@style/LaunchTheme"
android:configChanges="orientation|keyboardHidden|keyboard|screenSize|locale|layoutDirection|fontScale|screenLayout|density|uiMode"
android:hardwareAccelerated="true"
android:windowSoftInputMode="adjustResize"
android:exported="true">
```
**NOTE:** <code>FlutterAppCompatActivity</code> isn’t an official part of the Flutter SDK. It’s a custom <code>Activity</code> that extends <code>AppCompatActivity</code> from the AndroidX AppCompat library, and it’s necessary to use PSPDFKit for Android with Flutter. You can read more about this in the [AppCompatActivity Migration][] guide.
Expand Down Expand Up @@ -287,7 +286,7 @@ Platform specific README exists for [Android](android/) and [iOS](ios/).
PSPDFKit for Web library files are distributed as an archive that can be extracted manually.
1. <a href="https://my.pspdfkit.com/download/web/latest" target="_blank" rel="noreferrer">Download the framework here</a>. The download will start immediately and will save a `.tar.gz` archive like `PSPDFKit-Web-binary-<%= latest_version(:web) %>.tar.gz` to your computer.
1. <a href="https://my.nutrient.io/download/web/latest" target="_blank" rel="noreferrer">Download the framework here</a>. The download will start immediately and will save a `.tar.gz` archive like `PSPDFKit-Web-binary-<%= latest_version(:web) %>.tar.gz` to your computer.
2. Once the download is complete, extract the archive and copy the **entire** contents of its `dist` folder to your project’s `web/assets` folder or any other folder of your choice inside the web subfolder.
Expand All @@ -312,49 +311,50 @@ To see PSPDFKit for Flutter in action check out our [Flutter example app](exampl
Showing a PDF document inside your Flutter app is as simple as this:
```dart
```dart
PspdfkitWidget(documentPath: 'file:///path/to/Documentpdf')
```
```
# Upgrading to a Full PSPDFKit License Key
# Upgrading to a Full Nutrient License Key
PSPDFKit is a commercial product and requires the purchase of a license key when used in production. By default, this library will
initialize in demo mode, placing a watermark on each PDF and limiting usage to 60 minutes.
Nutrient is a commercial product and requires the purchase of a license key when used in production. By default, this library will initialize in demo mode, placing a watermark on each PDF and limiting usage to 60 minutes.
To purchase a license for production use, please reach out to us via https://pspdfkit.com/sales/form/.
To purchase a license for production use, please reach out to us via [contact_sales].
To initialize PSPDFKit using a license key, call either of the following before using any other PSPDFKit APIs or features:
To initialize Nutrient using a license key, call either of the following before using any other Nutrient APIs or features:
To set the license key for both Android and iOS, use:
```
await Pspdfkit.setLicenseKeys("YOUR_FLUTTER_ANDROID_LICENSE_KEY_GOES_HERE", "YOUR_FLUTTER_IOS_LICENSE_KEY_GOES_HERE");
```
To set the license key for the currently running platform, use:
```
await Pspdfkit.setLicenseKey("YOUR_FLUTTER_LICENSE_KEY_GOES_HERE");
```dart
await Pspdfkit.initialize(
androidLicenseKey:"YOUR_FLUTTER_ANDROID_LICENSE_KEY_GOES_HERE",
iosLicenseKey:"YOUR_FLUTTER_IOS_LICENSE_KEY_GOES_HERE",
webLicenseKey: "YOUR_FLUTTER_WEB_LICENSE_KEY_GOES_HERE"
);
```
# Migrating from Previous Version
To upgrade PSPDFKit for Flutter in your app, please refer to the [Upgrade and Migration Guides][flutter upgrade] section.
To upgrade Nutrient for Flutter in your app, please refer to the [Upgrade and Migration Guides][flutter_upgrade] section.
# Troubleshooting
For Troubleshooting common issues you might encounter when setting up PSPDFKit for Flutter, please refer to the [Troubleshooting][] section.
For Troubleshooting common issues you might encounter when setting up Nutrient for Flutter, please refer to the [Troubleshooting][troubleshooting] section.
<!-- References -->
[install-flutter]: https://flutter.dev/docs/get-started/install
[android studio]: https://developer.android.com/studio
[install ndk]: https://developer.android.com/studio/projects/install-ndk
[managing avds]: https://developer.android.com/studio/run/managing-avds.html
[xcode]: https://apps.apple.com/us/app/xcode/id497799835?mt=12
[cocoapods releases]: https://github.com/CocoaPods/CocoaPods/releases
[start-the-emulator]: https://developer.android.com/studio/run/emulator#runningemulator
[flutter upgrade]: https://pspdfkit.com/guides/flutter/upgrade/
[troubleshooting]: https://pspdfkit.com/guides/flutter/troubleshoot/
[appcompatactivity migration]: https://pspdfkit.com/guides/flutter/troubleshooting/pspdfkit-widget-appcompat-activity-issue/
[appearance styling]: /guides/android/customizing-the-interface/appearance-styling
[chrome]: https://www.google.com/chrome/
[pub_dev]: https://pub.dev/packages/pspdfkit_flutter
[github]: https://github.com/PSPDFKit/pspdfkit-flutter
[blog_starting_with_flutter]: https://nutrient.io/blog/2018/starting-with-flutter/
[blog_getting_started_with_pspdfkit_flutter]: https://nutrient.io/blog/getting-started-with-pspdfkit-flutter/
[blog_opening_a_pdf_in_flutter]: https://nutrient.io/blog/opening-a-pdf-in-flutter/
[blog_customize_flutter_pdf_sdk_android]: https://www.nutrient.io/guides/flutter/customize/?
[blog_advances_in_hybrid_technologies]: https://nutrient.io/blog/advances-in-hybrid-technologies/
[blog_maintaining_open_source_repo_from_monorepo]: https://nutrient.io/blog/maintaining-open-source-repo-from-monorepo/
[blog_download_display_pdf_in_flutter_with_pspdfkit]: https://nutrient.io/blog/download-and-display-pdf-in-flutter-with-pspdfkit/
[quick_start_guides]: https://nutrient.io/getting-started/mobile/?frontend=flutter
[android_readme]: android/
[ios_readme]: ios/
[contact_sales]: https://nutrient.io/sdk/contact-sales
[flutter_upgrade]: https://nutrient.io/guides/flutter/upgrade/
[troubleshooting]: https://nutrient.io/guides/flutter/troubleshoot/
[appcompatactivity_migration]: https://nutrient.io/guides/flutter/troubleshooting/pspdfkit-widget-appcompat-activity-issue/
14 changes: 7 additions & 7 deletions android/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -56,14 +56,14 @@ android {
}

dependencies {
implementation 'androidx.appcompat:appcompat:1.6.1'
implementation 'androidx.appcompat:appcompat:1.7.0'
implementation "com.pspdfkit:$pspdfkitMavenModuleName:$pspdfkitVersion"
implementation "org.jetbrains.kotlin:kotlin-stdlib:$kotlinVersion"
implementation 'androidx.legacy:legacy-support-v4:1.0.0'
implementation "androidx.compose.material:material:1.6.5"
implementation "androidx.compose.material:material:1.6.3"
implementation "androidx.constraintlayout:constraintlayout:2.1.4"
implementation "androidx.constraintlayout:constraintlayout-compose:1.0.1"
implementation "androidx.compose.foundation:foundation:1.6.3"
implementation "androidx.compose.ui:ui:1.6.3"
implementation "androidx.compose.material:material:1.7.5"
implementation "androidx.compose.material:material:1.7.5"
implementation "androidx.constraintlayout:constraintlayout:2.2.0"
implementation "androidx.constraintlayout:constraintlayout-compose:1.1.0"
implementation "androidx.compose.foundation:foundation:1.7.5"
implementation "androidx.compose.ui:ui:1.7.5"
}
2 changes: 1 addition & 1 deletion android/config.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -38,7 +38,7 @@ if (pspdfkitMavenUrl == null || pspdfkitMavenUrl == '') {

ext.pspdfkitVersion = localProperties.getProperty('pspdfkit.version')
if (pspdfkitVersion == null || pspdfkitVersion == '') {
ext.pspdfkitVersion = '2024.5.1'
ext.pspdfkitVersion = '2024.6.1'
}

ext.pspdfkitMavenModuleName = 'pspdfkit'
Expand Down
Loading

0 comments on commit e4129c5

Please sign in to comment.