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
2021-12-31 14:15:25 -0400
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
0a077256e500e202cf2a55008b302409a5a66926
0a077256
1 parent
5a088e1a
Fix README
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
4 additions
and
4 deletions
pdf/README.md
test/build_gfonts.dart
test/extract_readme.dart
pdf/README.md
View file @
0a07725
...
...
@@ -70,11 +70,11 @@ pdf.addPage(pw.Page(build: (pw.Context context) {
To load an image from the network using the
`printing`
package:
```
dart
final
i
mage
=
await
networkImage
(
'https://www.nfet.net/nfet.jpg'
);
final
netI
mage
=
await
networkImage
(
'https://www.nfet.net/nfet.jpg'
);
pdf
.
addPage
(
pw
.
Page
(
build:
(
pw
.
Context
context
)
{
return
pw
.
Center
(
child:
pw
.
Image
(
i
mage
),
child:
pw
.
Image
(
netI
mage
),
);
// Center
}));
// Page
```
...
...
test/build_gfonts.dart
View file @
0a07725
...
...
@@ -52,7 +52,7 @@ void main(List<String> args) async {
final
Map
m
=
json
.
decode
(
d
.
toString
());
final
file
=
File
(
'../printing/lib/src/fonts/gfonts.dart'
);
final
output
=
await
file
.
openWrite
();
final
output
=
file
.
openWrite
();
output
.
writeln
(
'/*'
);
output
.
writeln
(
...
...
test/extract_readme.dart
View file @
0a07725
...
...
@@ -56,8 +56,8 @@ void buildFile(String src, String dest, bool flutter) {
st
.
writeln
(
'import
\'
package:flutter/services.dart
\'
show rootBundle;'
);
st
.
writeln
(
'import
\'
package:flutter/widgets.dart
\'
show AssetImage;'
);
st
.
writeln
(
'import
\'
package:path_provider/path_provider.dart
\'
;'
);
st
.
writeln
(
'import
\'
package:printing/printing.dart
\'
;'
);
}
st
.
writeln
(
'import
\'
package:printing/printing.dart
\'
;'
);
st
.
writeln
(
'import
\'
package:pdf/pdf.dart
\'
;'
);
st
.
writeln
(
'import
\'
package:pdf/widgets.dart
\'
as pw;'
);
...
...
Please
register
or
login
to post a comment