How to apply custom fonts in print PDF files to support other languages such us Hebrew, Arabic, Chinese

To enable the Chinese Font style for the print PDF functionality, just go to admin dashboard -> WCargo menu -> Frontend Dashaboard and enable the “Enable Chinese Fonts” checkbox then click the save button.

 

To enable font for the Arabic, Hebrew and Cyrillic go to admin dashboard -> WPCargo Menu, then select Font family options that you need.

Note: For Hebrew and Cyrillic select option “Rubic, sans-serif” and for Arabic select “Amira, serif”

 

To add additional Custom font for the options just add this code to your theme functions.php file.

//Adding your own font for the print options
function mycuston_print_fonts_callback( $fonts ){
    $fonts['amiri'] = array(
        'url' => 'https://fonts.googleapis.com/css2?family=Amiri&display=swap',
        'fontfamily' => "'Amiri', serif"
    );
    return $fonts;
}
add_filter( 'wpcargo_print_fonts', 'mycuston_print_fonts_callback', 10, 1 );

NOTE: change your url to your custom font url.

1
    1
    Your Cart
    Remove
    WPCargo Import and Export Add-ons
    1 X $39.00 = $39.00