Untitled

mail@pastecode.io avatar
unknown
plain_text
7 months ago
2.1 kB
1
Indexable
Never
  $max_height_name            = 1.5;
    $max_height_company         = 1.1;
    $default_padding_top_qrcode = 0.4;

    // $height_normal = 104;
    $padding_top_normal         = 0.2;
    $padding_bottom_normal      = 0.2;


    $default_font_size_name     = 24;
    $default_line_height_name   = 35;

    $default_font_size_company   = 24;
    $default_line_height_company = 35;

    $default_font_size_jabatan      = 19;
    $default_line_height_jabatan    = 35;


    if (strlen($name) > 56) {
        $default_font_size_name = 11;
        $default_line_height_name = 20;
    } else if (strlen($name) > 34) {
        $default_font_size_name = 20;
        $default_line_height_name = 28;
        // $max_height_name = 1.5;
    } else if (strlen($name) > 24) {
        $default_font_size_name = 16;
        $default_line_height_name = 23;
    } else if (strlen($name) > 19 && strlen($name) <= 24) {
        $default_font_size_name = 19;
        $default_line_height_name = 35;
    }

    if (strlen($company) > 56) {
        $default_font_size_company = 13;
        $default_line_height_company = 21;
    } else if (strlen($company) > 34) {
        $default_font_size_company = 17;
        $default_line_height_company = 21;
        // $max_height_company= 1.5;
    } else if (strlen($company) > 26) {
        $default_font_size_company = 18;
        $default_line_height_company = 21;
    } else if (strlen($company) > 19 && strlen($company) <= 26) {
        $default_font_size_company = 19;
        $default_line_height_company = 35;
    }

    if (strlen($jabatan) > 56) {
        $default_font_size_jabatan = 14;
        $default_line_height_jabatan = 18;
    } else if (strlen($jabatan) > 34) {
        $default_font_size_jabatan = 17;
        $default_line_height_jabatan = 18;
    } else if (strlen($jabatan) > 26) {
        $default_font_size_jabatan = 18;
        $default_line_height_jabatan = 18;
    } else if (strlen($jabatan) > 19 && strlen($jabatan) <= 26) {
        $default_font_size_jabatan = 19;
        $default_line_height_jabatan = 35;
    }
Leave a Comment