hrbrmstr,
@hrbrmstr@mastodon.social avatar

@gws This https://docs.r-wasm.org/webr/latest/plotting.html#text-rendering-and-font-support-1 mentions being able to put fonts into /home/webr_user/fonts but that directory doesn't seem to be in there (under Node) and creating it and putting fonts there doesn't do what the last paragraph says on the tin (or I am doing something wrong). I must be missing something?

gws,
@gws@mstdn.social avatar

@hrbrmstr It's supposed to work something like this: https://observablehq.com/d/32e2b7e465c0b994

Revisiting this, it does seem to be a little fragile. Only the Cairo-based bitmap graphics devices (png, bmp, jpeg, ...) will work with this method, and the fonts need to be in place on the VFS before the device is invoked.

I wasn't able to check with Node.js from here, but I'll be back in front of my work machine on Monday and will double check then.

hrbrmstr,
@hrbrmstr@mastodon.social avatar

@gws ! lemme try it that way (I was doing it on the JS WebR.FS side.

hrbrmstr,
@hrbrmstr@mastodon.social avatar

@gws apologies. 100% on me. Just set up a custom linter for /home/webr_user b/c I can't stop typing that extra r

hrbrmstr,
@hrbrmstr@mastodon.social avatar

@gws Also the attached feels like magic for some reason (y'all are doing amazing work!)

  • All
  • Subscribed
  • Moderated
  • Favorites
  • random
  • DreamBathrooms
  • mdbf
  • ethstaker
  • magazineikmin
  • GTA5RPClips
  • rosin
  • thenastyranch
  • Youngstown
  • InstantRegret
  • slotface
  • osvaldo12
  • kavyap
  • khanakhh
  • Durango
  • megavids
  • everett
  • cisconetworking
  • normalnudes
  • tester
  • ngwrru68w68
  • cubers
  • modclub
  • tacticalgear
  • provamag3
  • Leos
  • anitta
  • JUstTest
  • lostlight
  • All magazines