Skip to content

Commit 97adc2e

Browse files
author
PSPDFKit
committed
Release 3.4.1
1 parent 8ef5cb0 commit 97adc2e

File tree

9 files changed

+38
-30
lines changed

9 files changed

+38
-30
lines changed

CHANGELOG.md

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,19 @@
11
## Newest Release
22

3+
### 3.4.1 - 18 Nov 2022
4+
5+
- Updates for PSPDFKit 12.0 for iOS. (#37508)
6+
- Fixes missing header file issue. (#37283)
7+
8+
## Previous Releases
9+
310
### 3.4.0 - 26 Oct 2022
411

512
- Adds generating PDF from images, templates and HTML. (#36736)
613
- Updates for PSPDFKit 8.4.1 Android. (#37192)
714
- Updates for PSPDFKit 12.0 for iOS. (#37192)
815
- Fixes keyboard cutting off search results when inline search is disabled. (#35418)
916
- Fixes an issue where the `PspdfkitView` widget is not rendered in Flutter versions 3.3.0 and above on Android. (#37044)
10-
## Previous Releases
1117

1218
### 3.3.0 - 19 Jul 2022
1319

README.md

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
# PSPDFKit Flutter
1+
# Flutter PDF Library by PSPDFKit
22

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

5-
PSPDFKit for Flutter is available at [pub.dev](https://pub.dev/packages/pspdfkit_flutter) and [GitHub](https://github.com/PSPDFKit/pspdfkit-flutter).
5+
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).
66

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

99
- [How I Got Started With Flutter](https://pspdfkit.com/blog/2018/starting-with-flutter/).
10-
- [Getting Started with PSPDFKit Flutter](https://pspdfkit.com/blog/2019/getting-started-with-pspdfkit-flutter/).
10+
- [Getting Started with Flutter PDF Library by PSPDFKit](https://pspdfkit.com/blog/2019/getting-started-with-pspdfkit-flutter/).
1111
- [Opening a PDF in Flutter](https://pspdfkit.com/blog/2019/opening-a-pdf-in-flutter/).
1212
- [How to Bridge Native iOS Code to Flutter](https://pspdfkit.com/blog/2021/how-to-bridge-native-ios-code-to-flutter/).
1313
- [How to Customize Our Flutter PDF SDK for Android](https://pspdfkit.com/blog/2021/how-to-customize-our-flutter-pdf-sdk/).
@@ -275,7 +275,7 @@ Platform specific README exists for [Android](android/) and [iOS](ios/).
275275
276276
# Example App
277277
278-
To see PSPDFKit Flutter in action check out our [Flutter example app](example/).
278+
To see PSPDFKit for Flutter in action check out our [Flutter example app](example/).
279279
280280
Showing a PDF document inside your Flutter app is as simple as this:
281281

example/ios/Podfile

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -31,7 +31,7 @@ flutter_ios_podfile_setup
3131

3232
target "Runner" do
3333
flutter_install_all_ios_pods __dir__
34-
pod "PSPDFKit", "~> 12.0.0"
34+
pod "PSPDFKit", "~> 12.0.1"
3535
end
3636

3737
post_install do |installer|

example/pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: pspdfkit_example
22
description: Demonstrates how to use the pspdfkit plugin.
3-
version: 3.4.0
3+
version: 3.4.1
44
homepage: https://pspdfkit.com/
55
environment:
66
sdk: '>=2.12.0 <3.0.0'

ios/Classes/PspdfkitFlutterHelper.m

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ + (void)processMethodCall:(FlutterMethodCall *)call result:(FlutterResult)result
107107
NSString *outputPath = call.arguments[@"outputFilePath"];
108108
NSArray<NSDictionary<NSString *,NSObject *> *> *pages = call.arguments[@"pages"];
109109
NSURL *processedDocumentURL = [PspdfkitFlutterHelper writableFileURLWithPath:outputPath override:YES copyIfNeeded:NO];
110-
[PspdfkitPdfGenrator generatePdfWithPages:pages outputUrl:processedDocumentURL results:result];
110+
[PspdfkitPdfGenerator generatePdfWithPages:pages outputUrl:processedDocumentURL results:result];
111111
} else {
112112
result(FlutterMethodNotImplemented);
113113
}

ios/Classes/PspdfkitHtmlPdfConvertor.swift

Lines changed: 20 additions & 19 deletions
Original file line numberDiff line numberDiff line change
@@ -10,9 +10,10 @@
1010
import Foundation
1111
import PSPDFKit.PSPDFProcessor
1212

13+
@objc(PspdfkitHtmlPdfConvertor)
1314
public class PspdfkitHtmlPdfConvertor: NSObject {
14-
15-
@objc public static func generateFromHtmlString(html: String, outputFileURL: URL, convertionOptions: Dictionary<String,Any>? , results:@escaping FlutterResult) {
15+
16+
@objc public static func generateFromHtmlString(html: String, outputFileURL: URL, convertionOptions: Dictionary<String,Any>?, results:@escaping FlutterResult) {
1617

1718
var options:[String: Any] = [:]
1819

@@ -23,27 +24,27 @@ public class PspdfkitHtmlPdfConvertor: NSObject {
2324
if(convertionOptions?["numberOfPages"] != nil){
2425
options[PSPDFProcessorNumberOfPagesKey] = convertionOptions?["numberOfPages"]
2526
}
26-
27+
2728
options = options as [String: Any]
28-
29+
2930
Processor.generatePDF(fromHTMLString: html,outputFileURL: outputFileURL, options: options) { outputURL, error in
30-
if let outputURL = outputURL {
31-
results(outputURL.relativePath);
32-
} else if let error = error {
33-
results(FlutterError(code: "PspdfkitError", message: error.localizedDescription,details: nil))
34-
}
35-
}
31+
if let outputURL = outputURL {
32+
results(outputURL.relativePath);
33+
} else if let error = error {
34+
results(FlutterError(code: "PspdfkitError", message: error.localizedDescription,details: nil))
35+
}
36+
}
3637
}
37-
38-
@objc public static func generateFromHtmlURL(htmlURL: URL, outputFileURL: URL, convertionOptions: Dictionary<String,Any>? , results:@escaping FlutterResult) {
39-
38+
39+
@objc public static func generateFromHtmlURL(htmlURL: URL, outputFileURL: URL, convertionOptions: Dictionary<String,Any>?, results:@escaping FlutterResult) {
40+
4041
let options = [PSPDFProcessorNumberOfPagesKey: 1, PSPDFProcessorDocumentTitleKey: "Generated PDF"] as [String: Any]
4142
Processor.generatePDF(from:htmlURL,outputFileURL: outputFileURL, options: options) { outputURL, error in
42-
if let outputURL = outputURL {
43-
results(outputURL.relativePath);
44-
} else if let error = error {
45-
results(FlutterError(code: "PspdfkitError", message: error.localizedDescription,details: nil))
46-
}
47-
}
43+
if let outputURL = outputURL {
44+
results(outputURL.relativePath);
45+
} else if let error = error {
46+
results(FlutterError(code: "PspdfkitError", message: error.localizedDescription,details: nil))
47+
}
48+
}
4849
}
4950
}

ios/Classes/PspdfkitPdfGenerator.swift

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,8 @@
1010
import Foundation
1111
import PSPDFKit.PSPDFProcessor
1212

13-
public class PspdfkitPdfGenrator: NSObject {
13+
@objc(PspdfkitPdfGenerator)
14+
public class PspdfkitPdfGenerator: NSObject {
1415

1516
static let pageAdaptor: PspdfkitPageConvertor = PspdfkitPageConvertor()
1617

ios/pspdfkit_flutter.podspec

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,5 +21,5 @@ Pod::Spec.new do |s|
2121
s.dependency("PSPDFKit")
2222
s.swift_version = "5.0"
2323
s.platform = :ios, "14.0"
24-
s.ios.deployment_target = "14.0"
24+
s.pod_target_xcconfig = { "DEFINES_MODULE" => "YES", "GENERATE_INFOPLIST_FILE" => "YES", "SWIFT_INSTALL_OBJC_HEADER" => "NO" }
2525
end

pubspec.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
name: pspdfkit_flutter
22
description: A Flutter plugin providing a feature-rich PDF viewing and editing experience to your users with the powerful PSPDFKit PDF SDK.
3-
version: 3.4.0
3+
version: 3.4.1
44
homepage: https://pspdfkit.com/
55
repository: https://github.com/PSPDFKit/pspdfkit-flutter
66
issue_tracker: https://support.pspdfkit.com/hc/en-us/requests/new

0 commit comments

Comments
 (0)