Querying RStudio's Editor Font Preference via rstudioapi

I'm reposting this question because it seems to have gone unanswered.

Is there a way to query the current editor font using rstudioapi?

My first guess would be to use readRStudioPreference(), but I don't know what the preference name would be. readRStudioPreference("server_editor_font"), which is cited in the RStudio Server Administration Guide, doesn't yield anything when used on RStudio Desktop.

There is not; the desktop font setting is one of a very small handful that are not stored in rstudio-prefs.json, in part because it is OS-specific. It is stored in an undocumented internal state file. You can infer this file's location from the support article that tells you where to go to remove it:

1 Like

Understood. That's a little disappointing, but it looks like I'll have to just abandon that idea for now. Thank you for your help!

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

If you have a query related to it or one of the replies, start a new topic and refer back with a link.