• Resolved Nomad Programmer

    (@srapsware)


    I am using unicode Hindi font by google input tool and google translate, buts its not showing in PDF. Please help me.

    If need to see pdf then you can place a free test order to see PDF.

    See PDF screenshot: https://prnt.sc/tgarwi

    Thanks

    The page I need help with: [log in to see the link]

Viewing 2 replies - 1 through 2 (of 2 total)
  • Thread Starter Nomad Programmer

    (@srapsware)

    Hello again,

    I am success something but, its start supporting only hindi, i need hindi and english.

    My code is:

    @font-face {
        font-family: 'NewDelhi';
        font-style: normal;
        font-weight: normal;
        src: local('NewDelhi'), local('NewDelhi'), url(https://www.abcd.com/wp-content/themes/storefront-child/fonts/NewDelhi.ttf) format('truetype');
    }
    @font-face {
        font-family: 'NewDelhi';
        font-style: normal;
        font-weight: bold;
        src: local('NewDelhi Bold'), local('NewDelhi-Bold'), url(https://www.abcd.com/wp-content/themes/storefront-child/fonts/NewDelhi-bold.ttf) format('truetype');
    }
    @font-face {
        font-family: 'NewDelhi';
        font-style: italic;
        font-weight: normal;
        src: local('NewDelhi Italic'), local('NewDelhi-Italic'), url(https://www.abcd.com/wp-content/themes/storefront-child/fonts/NewDelhi-italic.ttf) format('truetype');
    }
    @font-face {
        font-family: 'NewDelhi';
        font-style: italic;
        font-weight: bold;
        src: local('NewDelhi Bold Italic'), local('NewDelhi-BoldItalic'), url(https://www.abcd.com/wp-content/themes/storefront-child/fonts/NewDelhi-bolditalic.ttf) format('truetype');
    }
    body {
    	background: #fff;
    	color: #000;
    	margin: 0cm;
    	font-family: 'Open Sans', NewDelhi, sans-serif;
    	/* want to use custom fonts? https://docs.wpovernight.com/woocommerce-pdf-invoices-packing-slips/using-custom-fonts/ */
    	font-size: 9pt;
    	line-height: 100%; /* fixes inherit dompdf bug */
    }

    Please help me now how can i use multiple font same time

    Thread Starter Nomad Programmer

    (@srapsware)

    Hello,

    My issues fixed by this google font.

    https://fonts.google.com/specimen/Hind

    i have used only 2 type of fonts but you can use as you wish.

    @font-face {
        font-family: 'Hind';
        font-style: normal;
        font-weight: normal;
        src: local('Hind'), local('Hind'), url(https://www.abcd.com/wp-content/themes/storefront-child/fonts/Hind-Regular.ttf) format('truetype');
    }
    @font-face {
        font-family: 'Hind';
        font-style: normal;
        font-weight: bold;
        src: local('Hind Bold'), local('Hind-Bold'), url(https://www.abcd.com/wp-content/themes/storefront-child/fonts/Hind-Bold.ttf) format('truetype');
    }

    and change body to font Hind as below:

    body {
    	background: #fff;
    	color: #000;
    	margin: 0cm;
    	font-family: 'Hind', Arial, sans-serif;
    	font-size: 9pt;
    	line-height: 100%; /* fixes inherit dompdf bug */
    }

    thanks for official help on https://docs.wpovernight.com/woocommerce-pdf-invoices-packing-slips/using-custom-fonts/

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Its not supporting Hindi font’ is closed to new replies.