change the font size in the exported pdf

Questionschange the font size in the exported pdf
Francisco José Segura Noya asked 4 years ago

Hello Abu, the font size in the exported PDF is too big.
How I can change the font size in the exported PDF?

1 Answers
Abu Ghufran answered 4 years ago

You can change font size and other pdf settings with event handler.

// params are array(<function-name>,<class-object> or <null-if-global-func>)
$e["on_render_pdf"] = array("set_pdf_format", null);
$g->set_events($e);

function set_pdf_format($arr)
{
$pdf = $arr["pdf"];
$data = $arr["data"];

// enable utf8 font
$pdf->SetFont('helvetica', '', 11);
}

Refer demos/export/export-pdf.php

Your Answer

5 + 12 =

Login with your Social Id:

OR, enter

Attach code here and paste link in question.
Attach screenshot here and paste link in question.



How useful was this discussion?

Click on a star to rate it!

Average rating 0 / 5. Vote count: 0

No votes so far! Be the first to rate it.

We are sorry that this post was not useful for you!

Let us improve this post!

Tell us how we can improve this post?