Is there any way I can have multiple fall-back fonts for JavaScript context.font?
a fall-back font is a font that the browser
'falls back' to if the current one isn't supported
For example:
ctx.font = '20px arial'
ctx.fillText('Hello World!', 100, 100)
Let's say that arial wasn't supported. How would I make the computer fall back to tahoma and then verdana?
I kind of understand how CSS works: font-family: arial, tahoma, verdana
... But does context.font do the same thing as CSS?
Can I just write this: ctx.font = '20px arial, tahoma, verdana'? Or do I need to do something else for it to work?