line |
true |
false |
branch |
80
|
0 |
0 |
unless ($xml) |
85
|
0 |
0 |
if (not ref $xml) { } |
|
0 |
0 |
elsif ($xml->can('load')) { } |
88
|
0 |
0 |
unless ($report = 'PDF::ReportWriter::Report'->new({'report', $xml})) |
107
|
0 |
0 |
if ($@) |
124
|
0 |
0 |
unless (defined $data_records) |
128
|
0 |
0 |
if ($report->can('get_data')) |
154
|
0 |
0 |
if (ref $page_list eq 'ARRAY' and scalar @$page_list) { } |
178
|
0 |
0 |
unless (defined $opt) |
184
|
0 |
0 |
if (exists $$opt{'y_margin'}) |
190
|
0 |
0 |
if (exists $$opt{'x_margin'}) |
208
|
0 |
0 |
if ($$opt{'paper'} eq 'A4') { } |
|
0 |
0 |
elsif ($$opt{'paper'} eq 'Letter' or $$opt{'paper'} eq 'letter') { } |
|
0 |
0 |
elsif ($$opt{'paper'} eq 'bsize' or $$opt{'paper'} eq 'Bsize') { } |
|
0 |
0 |
elsif ($$opt{'paper'} eq 'Legal' or $$opt{'paper'} eq 'legal') { } |
|
0 |
0 |
elsif ($$opt{'paper'} =~ /^\s*([\d\.]+)\s*[xX]\s*([\d\.]+)\s*(\w*)$/) { } |
236
|
0 |
0 |
if ($unit eq 'mm') { } |
|
0 |
0 |
elsif ($unit eq 'in') { } |
251
|
0 |
0 |
if (exists $$opt{'orientation'} and $$opt{'orientation'}) |
253
|
0 |
0 |
if ($$opt{'orientation'} eq 'landscape') { } |
|
0 |
0 |
elsif ($$opt{'orientation'} ne 'portrait') { } |
287
|
0 |
0 |
if ($font eq 'Courier') |
292
|
0 |
0 |
if ($font eq 'Helvetica') |
297
|
0 |
0 |
if ($font eq 'Times') |
326
|
0 |
0 |
if ($x >= $$self{'page_width'} - $$self{'right_margin'}) |
337
|
0 |
0 |
unless ($$cell{'font_size'}) |
343
|
0 |
0 |
unless (exists $$cell{'text_whitespace'}) |
362
|
0 |
0 |
if ($type eq 'data') { } |
|
0 |
0 |
elsif ($type eq 'field_headers') { } |
|
0 |
0 |
elsif ($type eq 'page_header') { } |
|
0 |
0 |
elsif ($type eq 'page_footer') { } |
|
0 |
0 |
elsif ($type eq 'group') { } |
363
|
0 |
0 |
if ($$cell{'height'} > $$self{'data'}{'max_cell_height'}) |
369
|
0 |
0 |
unless ($$cell{'background'}) |
375
|
0 |
0 |
if ($$cell{'height'} > $$self{'data'}{'max_field_header_height'}) |
378
|
0 |
0 |
unless ($$cell{'background'}) |
383
|
0 |
0 |
if ($$cell{'height'} > $$self{'data'}{'page_header_max_cell_height'}) |
387
|
0 |
0 |
if ($$cell{'height'} > $$self{'data'}{'page_footer_max_cell_height'}) |
392
|
0 |
0 |
if ($$cell{'height'} > $$group{$group_type . '_max_cell_height'}) |
401
|
0 |
0 |
if (exists $$cell{'aggregate_source'}) |
412
|
0 |
0 |
if ($type ne 'data' and not $$cell{'image'} and not exists $$cell{'bold'}) |
416
|
0 |
0 |
if ($$cell{'image'}) |
420
|
0 |
0 |
unless (exists $$cell{'image'}{'buffer'}) |
433
|
0 |
0 |
if (exists $$cell{'type'}) |
435
|
0 |
0 |
if ($$cell{'type'} eq 'currency') { } |
|
0 |
0 |
elsif ($$cell{'type'} eq 'currency:no_fill') { } |
|
0 |
0 |
elsif ($$cell{'type'} eq 'thousands_separated') { } |
489
|
0 |
0 |
if ($type eq 'group') |
490
|
0 |
0 |
unless (exists $$group{$group_type . '_upper_buffer'}) |
494
|
0 |
0 |
unless (exists $$group{$group_type . '_lower_buffer'}) |
501
|
0 |
0 |
if ($type eq 'data') |
502
|
0 |
0 |
unless (exists $$self{'data'}{'upper_buffer'}) |
506
|
0 |
0 |
unless (exists $$self{'data'}{'lower_buffer'}) |
513
|
0 |
0 |
if ($type eq 'field_headers') |
514
|
0 |
0 |
if (not exists $$self{'data'}{'field_headers_upper_buffer'}) |
533
|
0 |
0 |
if ($$self{'data'}{'cell_borders'}) |
543
|
0 |
0 |
unless ($$self{'data'}{'no_field_headers'}) |
546
|
0 |
0 |
unless ($$self{'data'}{'field_headers'}) |
565
|
0 |
0 |
if ($$self{'data'}{'page'}{'header'}) |
570
|
0 |
0 |
if ($$self{'data'}{'page'}{'footer'}) { } |
|
0 |
0 |
elsif (not $$self{'data'}{'page'}{'footer'} || $$self{'data'}{'page'}{'footerless'}) { } |
603
|
0 |
0 |
if ($$group{$group_type}) |
613
|
0 |
0 |
unless $$group{'name'} eq 'GrandTotals' |
619
|
0 |
0 |
if (ref $data_ref eq 'ARRAY' and ref $$data_ref[0] eq 'ARRAY') |
631
|
0 |
0 |
unless ($$self{'pages'}) |
663
|
0 |
0 |
unless ($want_new_page) |
676
|
0 |
0 |
if ($$self{'y'} - ($$size_calculation{'y_needed'} + $$self{'page_footer_and_margin'}) < 0) |
692
|
0 |
0 |
if ($$group{'name'} eq $$queued_group{'group'}{'name'}) |
713
|
0 |
0 |
if ($want_new_page and $row_counter) |
736
|
0 |
0 |
if ($$group{'footer'}) |
759
|
0 |
0 |
if ($$group{'value'} ne $$row[$$group{'data_column'}] or $want_new_page and $$group{'reprinting_header'}) |
762
|
0 |
0 |
if ($$group{'page_break'}) |
772
|
0 |
0 |
if ($row_counter and $$group{'footer'} and not $want_new_page) |
778
|
0 |
0 |
if ($$group{'header'}) |
790
|
0 |
0 |
if ($$group{'value'} ne $$row[$$group{'data_column'}]) |
815
|
0 |
0 |
unless (exists $$self{'data'}{'cell_mapping'}{$$options{'cell'}}) |
820
|
0 |
0 |
unless (exists $$self{'data'}{'fields'}[$$self{'data'}{'cell_mapping'}{$$options{'cell'}}]{'group_results'}{$$options{'group'}}) |
840
|
0 |
0 |
if (defined $pdf_tmpl and $pdf_tmpl) |
847
|
0 |
0 |
if (my $pdf_doc = 'PDF::API2'->open($pdf_tmpl)) |
854
|
0 |
0 |
unless ($new_page or $user_warned) |
906
|
0 |
0 |
if ($$self{'data'}{'page'}{'header'}) |
922
|
0 |
0 |
if (not $$self{'group_header_queue'} and $$group{'reprinting_header'} and $$group{'value'} ne '!') |
940
|
0 |
0 |
if ($$group{'name'} ne 'GrandTotals') |
968
|
0 |
0 |
if ($y_needed <= $$self{'page_height'} and $$self{'y'} - $y_needed < 0) |
991
|
0 |
5 |
if (exists $$cell{'barcode'}) { } |
|
4 |
1 |
elsif (exists $$cell{'text'}) { } |
1005
|
2 |
2 |
if ($$cell{'text'} =~ /[\r\n][^\s]/o) |
1063
|
0 |
0 |
if ($$cell{'image'}) { } |
1072
|
0 |
0 |
if ($$cell{'image'}{'dynamic'} and ref $$options{'row'} eq 'ARRAY') |
1082
|
0 |
0 |
if (not $imgdata{'img_x'} or $$cell{'image'}{'path'} and $$cell{'image'}{'path'} ne $$cell{'image'}{'previous_path'}) |
1093
|
0 |
0 |
unless ($imgdata{'img_x'}) |
1098
|
0 |
0 |
unless ($imgdata{'img_y'}) |
1103
|
0 |
0 |
if ($$self{'debug'}) |
1107
|
0 |
0 |
if ($$cell{'image'}{'height'} > 0) { } |
|
0 |
0 |
elsif ($$cell{'image'}{'scale_to_fit'}) { } |
1123
|
0 |
0 |
if ($imgdata{'img_y'} > $$self{'y'} - $$self{'page_footer_and_margin'} - $$cell{'image'}{'buffer'} * 2) { } |
1133
|
0 |
0 |
if ($$self{'debug'}) |
1144
|
0 |
0 |
if ($$self{'debug'}) |
1149
|
0 |
0 |
$imgdata{'y_scale_ratio'} < $imgdata{'x_scale_ratio'} ? : |
1153
|
0 |
0 |
if ($$self{'debug'}) |
1164
|
0 |
0 |
if ($$self{'debug'}) |
1179
|
0 |
0 |
if (ref $row eq 'ARRAY') { } |
|
0 |
0 |
elsif ($$cell{'text'}) { } |
1190
|
0 |
0 |
if ($$cell{'wrap_text'}) |
1202
|
0 |
0 |
if ($no_of_new_lines) |
1210
|
0 |
0 |
if (not $row_heights[$$cell{'row'}] or $current_height > $row_heights[$$cell{'row'}]) |
1229
|
0 |
0 |
if ($$self{'group_header_queue'}) |
1238
|
0 |
0 |
unless ($$self{'data'}{'no_field_headers'}) |
1290
|
0 |
0 |
if ($type ne 'page_footer' and $$size_calculation{'y_needed'} <= $$self{'page_height'} and $$self{'y'} - $$size_calculation{'y_needed'} < 0) |
1299
|
0 |
0 |
if ($type eq 'data') |
1305
|
0 |
0 |
if ($type eq 'data' and $$self{'need_data_header'} and not $$self{'data'}{'no_field_headers'}) |
1350
|
0 |
0 |
if ($this_row != $$cell{'row'}) |
1359
|
0 |
0 |
if (ref $$options{'current_row'} eq 'ARRAY') { } |
1392
|
0 |
0 |
if (exists $$cell{'background'}) |
1397
|
0 |
0 |
if (exists $$cell{'custom_render_func'}) |
1404
|
0 |
0 |
if (ref $func_return eq 'HASH') { } |
1407
|
0 |
0 |
if (exists $$func_return{'render_text'}) { } |
|
0 |
0 |
elsif (exists $$func_return{'render_image'}) { } |
|
0 |
0 |
elsif (exists $$func_return{'rendering_done'} and $$func_return{'rendering_done'}) { } |
1438
|
0 |
0 |
if ($$cell{'image'}) { } |
|
0 |
0 |
elsif ($$cell{'barcode'}) { } |
1456
|
0 |
0 |
if ($type eq 'data' and $$cell{'aggregate_function'}) |
1462
|
0 |
0 |
if ($aggr_func) |
1464
|
0 |
0 |
if ($aggr_func eq 'sum') { } |
|
0 |
0 |
elsif ($aggr_func eq 'count') { } |
|
0 |
0 |
elsif ($aggr_func eq 'max') { } |
|
0 |
0 |
elsif ($aggr_func eq 'min') { } |
1483
|
0 |
0 |
if ($cell_value > $$group_res{$$group{'name'}}) |
1492
|
0 |
0 |
if ($cell_value < $$group_res{$$group{'name'}}) |
1516
|
0 |
0 |
if ($$cell{'background_func'}) { } |
1517
|
0 |
0 |
if ($$self{'debug'}) |
1527
|
0 |
0 |
unless (defined $background) |
1534
|
0 |
0 |
if ($$background{'shape'}) |
1536
|
0 |
0 |
if ($$background{'shape'} eq 'ellipse') { } |
|
0 |
0 |
elsif ($$background{'shape'} eq 'box') { } |
1569
|
0 |
0 |
if ($$background{'border'}) |
1581
|
0 |
0 |
if (not exists $$background{'borders'} or uc $$background{'borders'} eq 'ALL') |
1595
|
0 |
0 |
if ($cell_bb =~ /[bB]/) |
1602
|
0 |
0 |
if ($cell_bb =~ /[rR]/) |
1609
|
0 |
0 |
if ($cell_bb =~ /[tT]/) |
1616
|
0 |
0 |
if ($cell_bb =~ /[lL]/) |
1651
|
0 |
0 |
if ($$cell{'type'} eq 'ean13') |
1653
|
0 |
0 |
unless eval {
do {
require GD::Barcode::EAN13
}
} |
1661
|
0 |
0 |
exists $$cell{'quiet_zone'} ? : |
|
0 |
0 |
exists $$cell{'upper_mending_zone'} ? : |
|
0 |
0 |
exists $$cell{'zone'} ? : |
|
0 |
0 |
exists $$cell{'lower_mending_zone'} ? : |
1674
|
0 |
0 |
if ($$cell{'type'} eq 'code128') |
1684
|
0 |
0 |
if ($$cell{'type'} eq 'code39') |
1696
|
0 |
0 |
exists $$cell{'scale'} ? : |
1697
|
0 |
0 |
exists $$cell{'x'} ? : |
1698
|
0 |
0 |
exists $$cell{'y'} ? : |
1703
|
0 |
0 |
if ($align eq 'r') { } |
|
0 |
0 |
elsif ($align eq 'c') { } |
1745
|
0 |
0 |
exists $img_meth{$$imgdata{'img_type'}} ? : |
1749
|
0 |
0 |
unless (defined $img_call) |
1763
|
0 |
0 |
if (not $$self{'pdf'}->can($img_call)) { } |
1777
|
0 |
0 |
if ($@) |
1784
|
0 |
0 |
exists $$cell{'x'} ? : |
1785
|
0 |
0 |
exists $$cell{'y'} ? : |
1788
|
0 |
0 |
if ($$cell{'align'} and $$cell{'align'} eq 'centre' || $$cell{'align'} eq 'center') { } |
|
0 |
0 |
elsif ($$cell{'align'} and $$cell{'align'} eq 'right') { } |
1814
|
0 |
0 |
exists $$cell{'italic'} && $$cell{'italic'} ? : |
|
0 |
0 |
exists $$cell{'italic'} && $$cell{'italic'} ? : |
|
0 |
0 |
exists $$cell{'bold'} && $$cell{'bold'} ? : |
1837
|
0 |
0 |
if ($type eq 'header') { } |
|
0 |
0 |
elsif ($type eq 'data') { } |
|
0 |
0 |
elsif ($type eq 'group_header') { } |
|
0 |
0 |
elsif ($type eq 'group_footer') { } |
|
0 |
0 |
elsif ($type =~ /^page/) { } |
1853
|
0 |
0 |
if (exists $$cell{'aggregate_source'}) { } |
1855
|
0 |
0 |
if ($$cell{'text'} eq 'GrandTotals') { } |
1873
|
0 |
0 |
if ($$cell{'colour_func'}) { } |
1874
|
0 |
0 |
if ($$self{'debug'}) |
1883
|
0 |
0 |
if ($type ne 'header' and $$cell{'format'}) { } |
|
0 |
0 |
elsif ($$cell{'type'} and $$cell{'type'} =~ /^custom:(.+)$/) { } |
1900
|
0 |
0 |
if ($@) |
1917
|
0 |
0 |
if ($$cell{'wrap_text'}) |
1928
|
0 |
0 |
exists $$cell{'y'} ? : |
1932
|
0 |
0 |
exists $$cell{'align'} ? : |
1963
|
0 |
0 |
if ($$cell{'text_width'} > 0) |
1975
|
0 |
0 |
exists $$cell{'x'} ? : |
1977
|
0 |
0 |
if ($align eq 'l') { } |
|
0 |
0 |
elsif ($align eq 'c' or $type eq 'header') { } |
|
0 |
0 |
elsif ($align eq 'r') { } |
|
0 |
0 |
elsif ($align eq 'j') { } |
1990
|
0 |
0 |
$cell_abs_pos ? : |
2000
|
0 |
0 |
if ($cell_abs_pos) { } |
2026
|
0 |
0 |
if ($standard_width) |
2035
|
0 |
0 |
if $target > 1 |
2057
|
0 |
0 |
if ($cell_abs_pos and $y_pos < $line_height) |
2078
|
0 |
0 |
if ($text_width == 0) |
2086
|
0 |
0 |
if ($$options{'strip_breaks'}) |
2099
|
0 |
0 |
if ($paragraph eq '') |
2112
|
0 |
0 |
if (substr($paragraph, $position, 1) eq ' ') |
2120
|
0 |
0 |
if ($position == length $paragraph) { } |
2134
|
0 |
0 |
if ($$self{'debug'}) |
2167
|
0 |
0 |
if (exists $$options{'null_if_zero'} and $$options{'null_if_zero'} and $value == 0) |
2171
|
0 |
0 |
exists $$options{'decimal_places'} ? : |
2174
|
0 |
0 |
if ($decimals) |
2182
|
0 |
0 |
if ($decimals) |
2190
|
0 |
0 |
if ($$options{'decimal_fill'}) |
2191
|
0 |
0 |
if (defined $decimal) { } |
2199
|
0 |
0 |
if ($$options{'separate_thousands'}) |
2205
|
0 |
0 |
if ($$options{'currency'}) |
2210
|
0 |
0 |
if (defined $decimal) { } |
2225
|
0 |
0 |
unless (exists $$self{'pages'} and ref $$self{'pages'}) |
2324
|
0 |
0 |
exists $$opt{'unlink'} ? : |
2328
|
0 |
0 |
unless ($$opt{'command'}) |
2332
|
0 |
0 |
unless @cups_locations |
2336
|
0 |
0 |
unless ($cmd) |
2351
|
0 |
0 |
if ($printer = $$opt{'printer'}) |
2360
|
0 |
0 |
if ($temp_file) { } |
2367
|
0 |
0 |
if ($ok) { } |
2375
|
0 |
0 |
unless ($ok) |
2390
|
0 |
0 |
if $unlink_spool |
2434
|
0 |
0 |
if (my $data = $self->report->get_data($ds_name)) |
2444
|
0 |
0 |
if (ref $row eq 'HASH') { } |
2449
|
0 |
0 |
if ($$cell{'delimiter'}) { } |