• Hi,
    I want to use “baloo 2” google font. The normal Baloo has only 1 wieight and I want to use the lighter versions that Baloo 2 offers.

    I added this code to my child themes function.

    
    function my_new_fonts( $array ) {
        $array[] = 'Baloo 2';
        return $array;
    }
    add_filter( 'ocean_google_fonts_array', 'my_new_fonts' );

    Baloo 2 then appears in my font list, but if I select it for H1, the font does not change to Baloo 2 but reverts to the standard header font I chose.

    I hope someone van help!
    I have done this adding of another font before, but not with the Baloo 2.

    Thanks in advance
    Joke

    • This topic was modified 3 years, 3 months ago by omniafausta.
    • This topic was modified 3 years, 3 months ago by omniafausta.
Viewing 11 replies - 1 through 11 (of 11 total)
  • Hello,

    Tried checking the above code and it’s working well.

    Can you please share a snapshot where the code you have added?
    ALso share the website URL after selecting the font to any section.

    Thread Starter omniafausta

    (@omniafausta)

    Hi Abhishek,

    I added it to the functions.php of my child theme, so far it is the only function besides enqueueing the parent style, so just directly after that.

    The site is not live yet so I can’t share a page.

    I can work around by just adding the google-font in another way and using CSS to make my H1 the way I want it, but I’d rather do it through the customizer.

    thanks
    Joke

    Hello,

    Not an issue. But can you please share the related snapshots?

    SHared snapshot where you have added this code and a snapshot of the customizer settings section with the result.

    In addition, Would you be so kind and go to Elementor > System Info and share the report with us so that we can take a look?

    Thread Starter omniafausta

    (@omniafausta)

    Hi,

    Sorry for my late reply, I have been on vacation. I will look into this today.

    Thanks,
    Joke

    Thread Starter omniafausta

    (@omniafausta)

    or at least I hope to look into it soon… crazy busy after the vacation, so not today.

    • This reply was modified 3 years, 2 months ago by omniafausta.

    Not an issue, take your time.

    Thread Starter omniafausta

    (@omniafausta)

    Hi,

    I just realized my error!
    in the array I entered ‘Baloo 2’ and that should be: ‘”Baloo 2″‘ with extra quotes.

    it now works!

    • This reply was modified 3 years, 1 month ago by omniafausta.
    Thread Starter omniafausta

    (@omniafausta)

    hmmm ,it looked like it worked: now It looks good while using the customizer, but the moment I publish the Baloo 2 turns into the standard font again because the extra quotes get stripped from the css…

    The space in the name seems to be the issue, but not sure how to work around that!

    thanks for any help

    Glad to hear that you found the causes for the issue.

    Thread Starter omniafausta

    (@omniafausta)

    well the cause is the disappearing quotes… the solution I haven’t found!
    While in the customizer the quotes remain, once published the quotes disappear…

    So I guess this is some bug in the theme?
    Is this something you can fix?
    Or do you know a workaround?

    Thanks!

    Hello,

    That’s strange. Can you please replicate the issue and share the site link so that I can take a look?

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘can’t add the “Baloo 2” google font’ is closed to new replies.