Toggle navigation
Toggle navigation
This project
Loading...
Sign in
flutter_package
/
dart_pdf
Go to a project
Toggle navigation
Projects
Groups
Snippets
Help
Toggle navigation pinning
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Authored by
David PHAM-VAN
2018-09-02 19:14:12 -0400
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
6d66e308ebf92d0e477505c2e5c69ce5b2890f03
6d66e308
1 parent
b73f717d
Fix printing from pdf document
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
8 additions
and
3 deletions
printing/CHANGELOG.md
printing/lib/printing.dart
printing/pubspec.yaml
printing/CHANGELOG.md
View file @
6d66e30
# 1.0.5
*
Fix printing from pdf document
# 1.0.4
*
Update example for pdf 1.0.5
*
Add Contributing
...
...
printing/lib/printing.dart
View file @
6d66e30
...
...
@@ -17,6 +17,7 @@
*/
import
'dart:async'
;
import
'dart:typed_data'
;
import
'dart:ui'
;
import
'package:flutter/services.dart'
;
...
...
@@ -33,8 +34,9 @@ class Printing {
if
(
document
!=
null
)
bytes
=
document
.
save
();
final
Map
<
String
,
dynamic
>
params
=
<
String
,
dynamic
>{
'doc'
:
bytes
,
'doc'
:
new
Uint8List
.
fromList
(
bytes
)
,
};
await
_channel
.
invokeMethod
(
'printPdf'
,
params
);
}
...
...
@@ -50,7 +52,7 @@ class Printing {
}
final
Map
<
String
,
dynamic
>
params
=
<
String
,
dynamic
>{
'doc'
:
bytes
,
'doc'
:
new
Uint8List
.
fromList
(
bytes
)
,
'x'
:
bounds
.
left
,
'y'
:
bounds
.
top
,
'w'
:
bounds
.
width
,
...
...
printing/pubspec.yaml
View file @
6d66e30
...
...
@@ -2,7 +2,7 @@ name: printing
author
:
David PHAM-VAN <dev.nfet.net@gmail.com>
description
:
Plugin that allows Flutter apps to generate and print documents to android or ios compatible printers
homepage
:
https://github.com/DavBfr/dart_pdf/tree/master/printing
version
:
1.0.
4
version
:
1.0.
5
environment
:
sdk
:
"
>=1.19.0
<3.0.0"
...
...
Please
register
or
login
to post a comment