Early Bird Registration for DrupalCon Portland 2024 is open! Register by 23:59 PST on 31 March 2024, to get $100 off your ticket.
Free fonts, list here:
An API would be nice, but we could start with just a static list directly in the module, like we did with Google before they had an API.
Comment | File | Size | Author |
---|---|---|---|
#2 | fontyourface-Edge_Fonts_PoC_2-1794540-2.patch | 6.73 KB | Drave Robber |
#1 | fontyourface-Edge_Fonts_PoC-1794540-1.patch | 5.31 KB | Drave Robber |
Comments
Comment #1
Drave Robber CreditAttribution: Drave Robber commentedProof of concept attached.
The list contains just three fonts with four variants, and preview is not implemented yet, but other than that it even works.
(edit: works to an extent - Abril Fatface does not work because I confused 'font name' and 'family name')
Comment #2
Drave Robber CreditAttribution: Drave Robber commentedSecond attempt:
- fixed css_family issue,
- implemented preview,
- reworked font naming more in line with that used by the provider (we omit 'Regular' though),
- moved helper function providing human-readable descriptions of weights to the .inc file,
- added some more fonts (manually for now, but I'm thinking about writing a scraper for this).
To do:
- implement handling of subsets (as there are two choices - 'default' and 'all' - at the moment, this could be a global configuration).
- implement some logging and such.
Work in progress, but it still could use some review.
Comment #3
Drave Robber CreditAttribution: Drave Robber commentedUpon scraping the whole list (860 fonts in 501 families), the thing got quite huge (.inc file is 70+k), so I created a temporary sandbox for it.
Comment #4
sreynen CreditAttribution: sreynen commentedSandbox looks good to me. I committed it.