Okay
  Public Ticket #1579468
Change font family according to the language
Closed

Comments

  •  3
    PepiteAtelier started the conversation

    Hi, 

    My website is in English and Chinese.

    For English i used to Poppins font family.

    I would like to change the font family for the Chinese language : Noto Sans SC (Chinese Simplified).

    For the traduction, i used polylang plugin.

    I tried this in typography theme kalium part (image). But i need to use Noto Sans SC (Chinese Simplified) and the fond isn't in google font repertory... https://fonts.google.com/earlyaccess

    Thanks for your help

    Bastien

    {"wp":{"use":false,"adminUrl":"","username":"","password":""},"ftp":{"use":false,"url":"","port":"","user":"","password":"","path":""}}

  •  3
    PepiteAtelier replied

    Up ! I really need to solve my problem.

    Thanks for your help

    Bastien

  • [deleted] replied

    Hi Bastien,

    The approach you are applying for Chinese fonts is adequate however if this font is not listed on Google can you try the following way:

    1. Upload the font stylesheet file in wp-content/uploads/ (download file here)

    2. Create custom font in typography:


    (view large version)

    3. And assign the URL to that file, in my case http://kalium.local/wp-content/uploads/noto-sans-cs.css:


    (view large version)

    Can you please try this and let me know if it works for you.

  •   PepiteAtelier replied privately
  •  3
    PepiteAtelier replied

    Arlind,

    It's work if i place directly "http://fonts.googleapis.com/earlyaccess/notosanssc.css" in Font Stylesheet URL. But how can i choose the weight of each selector if i have just "Noto Sans SC" in Font Variant ? If we can't do this, it's not a problem. The theme keep Poppins font variant. 

    Thanks

  • [deleted] replied

    Hi Bastien,

    In this case, when the custom font doesn't provide the font weights, you can add the font weight explicitly with Custom CSS, that is the only way for now. Does this works for you?

  •  3
    PepiteAtelier replied

    Hi Arlind,

    In fact, i don't need to change the font weight.
    Thanks for your help :)