Condition Coverage

blib/lib/PDF/Builder/Content.pm
Criterion Covered Total %
condition 98 362 27.0


and 3 conditions

line !l l&&!r l&&r condition
122 137 0 6 $self->{'-docompress'} and $self->{'Filter'}
385 9 0 7 $opts{'-translate'} and not defined $opts{'translate'}
386 9 0 7 $opts{'-rotate'} and not defined $opts{'rotate'}
387 9 0 7 $opts{'-scale'} and not defined $opts{'scale'}
388 9 0 7 $opts{'-skew'} and not defined $opts{'skew'}
389 16 0 0 $opts{'-point'} and not defined $opts{'point'}
390 16 0 0 $opts{'-matrix'} and not defined $opts{'matrix'}
391 16 0 0 $opts{'-repeat'} and not defined $opts{'repeat'}
445 1 0 1 defined $opts{'-skew'} and not defined $opts{'skew'}
446 1 0 1 defined $opts{'-scale'} and not defined $opts{'scale'}
447 1 0 1 defined $opts{'-rotate'} and not defined $opts{'rotate'}
448 1 0 1 defined $opts{'-translate'} and not defined $opts{'translate'}
648 0 0 3 $style >= 0 and $style <= 2
724 0 0 3 $style >= 0 and $style <= 2
846 0 0 1 defined $pat{'-pattern'} and not defined $pat{'pattern'}
847 0 0 1 defined $pat{'-shift'} and not defined $pat{'shift'}
866 9 2 0 scalar @pat == 1 and $pat[0] == -1
870 10 1 0 scalar @pat == 2 and ref $pat[0] eq "ARRAY"
11 0 0 scalar @pat == 2 and ref $pat[0] eq "ARRAY" and ref $pat[1] eq ""
1403 138 90 0 not $dir and $alpha > $beta
1404 0 0 0 $alpha == 360 and $beta == 0
1417 90 136 2 $dir and $alpha < $beta
1418 0 2 0 $alpha == 0 and $beta == 360
1877 1 0 0 defined $opts{'-firstseg'} and not defined $opts{'firstseg'}
1878 1 0 0 defined $opts{'-lastseg'} and not defined $opts{'lastseg'}
1879 1 0 0 defined $opts{'-ratio'} and not defined $opts{'ratio'}
1880 1 0 0 defined $opts{'-colinear'} and not defined $opts{'colinear'}
1881 1 0 0 defined $opts{'-debug'} and not defined $opts{'debug'}
1930 6 1 0 $inputs[-2][0] == $inputs[-1][0] and $inputs[-2][1] == $inputs[-1][1]
1994 1 1 6 $i > 0 and $i < $last
1996 6 0 0 $polyline[$i - 1][0] == $polyline[$i][0] and $polyline[$i - 1][1] == $polyline[$i][1]
2045 1 6 0 $i < $last and $colinpt[$i]
2253 0 0 0 $colinear eq "line" and $j > $i
2278 0 0 0 $dtheta >= 0 and $dthetap < 0
0 0 0 $dtheta < 0 and $dthetap >= 0
2359 0 0 0 $i < $last and $type[$i] == 1 || $type[$i] == 3
2430 2 0 0 $ptheta >= 0 and $ttheta >= 0
0 1 1 $ptheta < 0 and $ttheta < 0
2554 8 0 0 $x1 == $x2 and $y1 == $y2
2712 0 0 0 defined $opts{'-rule'} and not defined $opts{'rule'}
2784 0 0 0 defined $opts{'-rule'} and not defined $opts{'rule'}
2868 0 0 0 defined $opts{'-rule'} and not defined $opts{'rule'}
3473 0 0 0 defined $width and defined $vwidth
0 0 0 defined $width and defined $vwidth and defined $height
0 0 0 defined $width and defined $vwidth and defined $height and defined $vheight
3494 0 0 0 $x == 0 and $y == 0
3905 0 0 0 $state{'font'} and $state{'fontsize'}
4051 0 0 0 defined $x and not defined $y
4236 22 1 1 defined $indent and $indent != 0
4348 0 0 181 defined $text and length $text
4618 31 0 0 defined $opts{'-align'} and not defined $opts{'align'}
4619 30 0 1 defined $opts{'-indent'} and not defined $opts{'indent'}
4620 31 0 0 defined $opts{'-underline'} and not defined $opts{'underline'}
4621 31 0 0 defined $opts{'-strokecolor'} and not defined $opts{'strokecolor'}
4622 31 0 0 defined $opts{'-strikethru'} and not defined $opts{'strikethru'}
4643 1 0 0 defined $self->{' font'} and $self->{' fontsize'}
4893 0 0 0 defined $opts{'-underline'} and not defined $opts{'underline'}
4894 0 0 0 defined $opts{'-strikethru'} and not defined $opts{'strikethru'}
4895 0 0 0 defined $opts{'-strokecolor'} and not defined $opts{'strokecolor'}
4922 0 0 0 defined $self->{' font'} and $self->{' fontsize'}
5003 0 0 0 $dump and $cw != $ax
5118 0 0 0 $dir eq 'L' || $dir eq 'R' and $ulxy1[1] > $ulxy2[1]
0 0 0 $dir eq 'T' || $dir eq 'B' and $ulxy1[2] < $ulxy2[2]
5145 4 280 0 defined $item and $item ne ""
5161 518 578 0 defined $item and $item ne ""
5287 0 0 0 defined $opts{'-doKern'} and not defined $opts{'doKern'}
5288 0 0 0 defined $opts{'-minKern'} and not defined $opts{'minKern'}
5292 0 0 0 defined $self->{' font'} and $self->{' fontsize'}
5541 0 159 760 defined $self->{' stream'} and $self->{' stream'} =~ /\s$/

or 2 conditions

line l !l condition
456 2 0 $opts{'rotate'} || 0
644 3 0 lc $linecap // 0
720 3 0 lc $linejoin // 0
851 1 0 $pat{'shift'} || 0
852 1 0 $pat{'shift'} || 0
2713 0 0 $opts{'rule'} // "nonzero"
2785 0 0 $opts{'rule'} // "nonzero"
2869 0 0 $opts{'rule'} // "nonzero"
3447 0 0 $x //= 0
3448 0 0 $y //= 0
3449 0 0 $scale_x //= 1
4494 0 0 $color ||= "black"
4505 0 0 -$self->{' font'}->underlineposition * $self->{' fontsize'} / $upem || 1
4506 0 0 $self->{' font'}->underlinethickness * $self->{' fontsize'} / $upem || 1
4554 0 0 $color ||= "black"
4568 0 0 $self->{' fontsize'} || 20
4570 0 0 $self->{' font'}->underlinethickness * $self->{' fontsize'} / $upem || 1
4901 0 0 $settings->{'dir'} || 'L'
4902 0 0 $settings->{'align'} || 'B'
4903 0 0 $settings->{'dump'} || 0
4904 0 0 $settings->{'script'} || 'Latn'
4909 0 0 $settings->{'minKern'} || 1
5299 0 0 $opts{'doKern'} || 1
5300 0 0 $opts{'minKern'} || 1
5700 0 0 $dict->{$type}{$key} || undef

or 3 conditions

line l !l&&r !l&&!r condition
645 0 0 3 $style eq "butt" or $style eq "b"
646 0 0 3 $style eq "round" or $style eq "r"
647 0 0 3 $style eq "square" or $style eq "s"
721 0 0 3 $style eq "miter" or $style eq "m"
722 0 0 3 $style eq "round" or $style eq "r"
723 0 0 3 $style eq "bevel" or $style eq "b"
843 1 0 3 $pat[0] =~ /^\-?pattern/ or $pat[0] =~ /^\-?shift/
1386 0 0 228 $rx <= 0 or $ry <= 0
2045 1 0 7 $i == 0 or $i < $last and $colinpt[$i]
2278 0 0 0 $dtheta >= 0 and $dthetap < 0 or $dtheta < 0 and $dthetap >= 0
2359 0 0 0 $type[$i] == 1 || $type[$i] == 3
2430 0 1 1 $ptheta >= 0 and $ttheta >= 0 or $ptheta < 0 and $ttheta < 0
3450 0 0 0 $scale_y //= $scale_x
4266 0 0 0 $leading or not $self->{' fontsize'}
4627 17 0 9 $align eq "l" or $align eq "left"
6 0 3 $align eq "c" or $align eq "center"
3 0 0 $align eq "r" or $align eq "right"
0 0 0 $align eq "j" or $align eq "justified"
4661 21 0 9 $align eq "l" or $align eq "j"
4918 0 0 0 $dir eq "T" or $dir eq "B"
4947 0 0 0 $dir eq "L" or $dir eq "T"
4965 0 0 0 $dir eq "L" or $dir eq "R"
5032 0 0 0 $ay != 0 or $dx != 0
0 0 0 $ay != 0 or $dx != 0 or $dy != 0
5087 0 0 0 $dir eq "L" or $dir eq "T"
5104 0 0 0 $dir eq "L" or $dir eq "R"
5110 0 0 0 $dir eq "L" or $dir eq "R"
5118 0 0 0 $dir eq 'L' || $dir eq 'R'
0 0 0 $dir eq 'T' || $dir eq 'B'
0 0 0 $dir eq 'L' || $dir eq 'R' and $ulxy1[1] > $ulxy2[1] or $dir eq 'T' || $dir eq 'B' and $ulxy1[2] < $ulxy2[2]
5302 0 0 0 $dir eq "T" or $dir eq "B"
5324 0 0 0 $dir eq "T" or $dir eq "B"
5692 2 0 0 $self->{'Resources'} //= PDFDict()
5697 0 2 0 $dict->{$type} ||= PDFDict()
5705 0 2 0 $dict->{$type}{$key} ||= $obj