Lines 173-185
sub draw_text {
Link Here
|
173 |
} |
173 |
} |
174 |
box ($origin_llx, $box_lly, $self->{'width'} - $text_attribs->{'llx'}, $box_height, $pdf); |
174 |
box ($origin_llx, $box_lly, $self->{'width'} - $text_attribs->{'llx'}, $box_height, $pdf); |
175 |
} |
175 |
} |
176 |
# my $font_resource = $pdf->TTFont("/usr/share/fonts/truetype/msttcorefonts/Times_New_Roman_Bold.ttf"); |
176 |
$pdf->Font($text_attribs->{'font'}); |
177 |
# $pdf->FontSize($text_attribs->{'font_size'}); |
177 |
$pdf->FontSize($text_attribs->{'font_size'}); |
178 |
my $font_resource = $pdf->Font($text_attribs->{'font'}); |
|
|
179 |
foreach my $line (@lines) { |
178 |
foreach my $line (@lines) { |
180 |
# $pdf->Text($line->{'Tx'}, $line->{'Ty'}, $line->{'line'}); |
179 |
$pdf->Text($line->{'Tx'}, $line->{'Ty'}, $line->{'line'}); |
181 |
my $text_line = "BT /$font_resource $text_attribs->{'font_size'} Tf $line->{'Tx'} $line->{'Ty'} Td $line->{'Tw'} Tw ($line->{'line'}) Tj ET"; |
|
|
182 |
$pdf->Add($text_line); |
183 |
} |
180 |
} |
184 |
} |
181 |
} |
185 |
} |
182 |
} |
186 |
- |
|
|