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
2020-11-24 06:43:29 -0400
Browse Files
Options
Browse Files
Download
Email Patches
Plain Diff
Commit
66b3fa6f4452e616121914bf1657fb9408dd8072
66b3fa6f
1 parent
97d15ba0
Add more asserts
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
24 additions
and
9 deletions
pdf/lib/src/annotation.dart
pdf/lib/widgets/annotations.dart
pdf/lib/src/annotation.dart
View file @
66b3fa6
...
...
@@ -227,7 +227,9 @@ class PdfAnnotText extends PdfAnnotBase {
Set
<
PdfAnnotFlags
>
flags
,
DateTime
date
,
PdfColor
color
,
})
:
super
(
})
:
assert
(
rect
!=
null
),
assert
(
content
!=
null
),
super
(
subtype:
'/Text'
,
rect:
rect
,
border:
border
,
...
...
@@ -280,7 +282,9 @@ class PdfAnnotUrlLink extends PdfAnnotBase {
Set
<
PdfAnnotFlags
>
flags
,
DateTime
date
,
PdfColor
color
,
})
:
super
(
})
:
assert
(
rect
!=
null
),
assert
(
url
!=
null
),
super
(
subtype:
'/Link'
,
rect:
rect
,
border:
border
,
...
...
@@ -317,7 +321,9 @@ abstract class PdfAnnotWidget extends PdfAnnotBase {
PdfColor
color
,
this
.
backgroundColor
,
this
.
highlighting
,
})
:
super
(
})
:
assert
(
rect
!=
null
),
assert
(
fieldType
!=
null
),
super
(
subtype:
'/Widget'
,
rect:
rect
,
border:
border
,
...
...
@@ -388,7 +394,8 @@ class PdfAnnotSign extends PdfAnnotWidget {
DateTime
date
,
PdfColor
color
,
PdfAnnotHighlighting
highlighting
,
})
:
super
(
})
:
assert
(
rect
!=
null
),
super
(
rect:
rect
,
fieldType:
'/Sig'
,
fieldName:
fieldName
,
...
...
@@ -519,7 +526,9 @@ class PdfFormField extends PdfAnnotWidget {
PdfColor
backgroundColor
,
PdfAnnotHighlighting
highlighting
,
this
.
fieldFlags
,
})
:
super
(
})
:
assert
(
rect
!=
null
),
assert
(
fieldType
!=
null
),
super
(
rect:
rect
,
fieldType:
fieldType
,
fieldName:
fieldName
,
...
...
@@ -583,7 +592,8 @@ class PdfTextField extends PdfFormField {
@required
this
.
fontSize
,
@required
this
.
textColor
,
this
.
textAlign
,
})
:
assert
(
fontSize
!=
null
),
})
:
assert
(
rect
!=
null
),
assert
(
fontSize
!=
null
),
assert
(
textColor
!=
null
),
assert
(
font
!=
null
),
super
(
...
...
@@ -655,7 +665,8 @@ class PdfButtonField extends PdfFormField {
Set
<
PdfFieldFlags
>
fieldFlags
,
this
.
value
,
this
.
defaultValue
,
})
:
super
(
})
:
assert
(
rect
!=
null
),
super
(
rect:
rect
,
fieldType:
'/Btn'
,
fieldName:
fieldName
,
...
...
pdf/lib/widgets/annotations.dart
View file @
66b3fa6
...
...
@@ -250,8 +250,11 @@ class Link extends Annotation {
}
class
UrlLink
extends
Annotation
{
UrlLink
({
@required
Widget
child
,
String
destination
})
:
assert
(
child
!=
null
),
UrlLink
({
@required
Widget
child
,
@required
String
destination
,
})
:
assert
(
child
!=
null
),
assert
(
destination
!=
null
),
super
(
child:
child
,
builder:
AnnotationUrl
(
destination
));
}
...
...
@@ -268,6 +271,7 @@ class Signature extends Annotation {
PdfAnnotHighlighting
highlighting
,
})
:
assert
(
child
!=
null
),
assert
(
crypto
!=
null
),
assert
(
name
!=
null
),
super
(
child:
child
,
builder:
AnnotationSignature
(
...
...
Please
register
or
login
to post a comment