Hi TagDiv-support,
I would very much like to use a lighter version of one of the Google Fonts (Merriweather, weight 300). Unfortunately, from the Theme Panel I can only choose between normal and bold.
I’ve looked at the suggestion from Emil in this thread: https://forum.tagdiv.com/topic/cant-choose-more-weight-options-for-google-fonts/ โ but I can’t find the code he is referencing in functions.php. Maybe it’s been moved somewhere else?
I’ve also tried to replicate Emil’s suggestion from the Newsmag forum: https://forum.tagdiv.com/topic/how-to-add-additional-google-fonts-weightstyle/#post-28943 โ but with no luck. I got the options to show up in the Theme Panel but the font weight doesn’t load (still only the default 400 and 700).
Could you point me in the right direction?
Thank you in advance ๐
/Janus
Hi,
Please try to add your custom weight in td_fonts.php so it will be loaded on the page – http://screencast.com/t/wC8yYQf5d and here to be available in panel – http://screencast.com/t/taQHZf4jYc8
Hope this helps!
Hi Alin,
Thank you for your quick response.
I’ve tried doing as you suggested โ but as far as I can tell only the standard weights are being loaded. https://www.evernote.com/shard/s4/sh/f132c35a-ec97-48a9-a589-7f5fb3d20f9f/982bf9644c1ad7df
Since that didn’t seem to work I also tried adding the font weight to td_panel_data_source.php https://www.evernote.com/shard/s4/sh/2c3f7d6c-35dd-423b-9bb3-8f19ef4293b3/e44f24569c7d9e61
Still no luck, I’m afraid…
Hi,
If you want to add this also for the theme default fonts please add font weight here – http://screencast.com/t/nujniu1Gb
Thanks!
Hi Alin,
Thank you – but I’m afraid you might have misunderstood my last post. I’ve not been able to get the solution you posted yesterday to work. It looks like the additional font weights aren’t being loaded.
Only the standard weights (400 and 700) are being loaded – as you can see on this screenshot:
https://www.evernote.com/shard/s4/sh/f132c35a-ec97-48a9-a589-7f5fb3d20f9f/982bf9644c1ad7df
Thanks for your patience ๐
Hi,
I have tested this again and it seems that you need to add the weight also in the td_panel_data_source.php like you said.
So from the beginning I have added the custom weight to these files – http://screencast.com/t/e8EQxssHdUA – http://screencast.com/t/StR0oQuv2k – http://screencast.com/t/3ljF2EAKIW6z
$buffy_font_weight[3] = array('text' => '300', 'val' => '300');
Then please change and save for few times the Theme Fonts settings and also clear the cache.
Result: http://screencast.com/t/szPM63oGCyH1 – http://screencast.com/t/BPttNY9S0Ul – http://screencast.com/t/1KmTFkX2rD
Thanks!