tauri_sys::path

Function font_dir

source
pub async fn font_dir() -> Result<PathBuf, Error>
Expand description

Returns the path to the user’s font directory.

§Platform-specific
  • Linux: Resolves to $XDG_DATA_HOME/fonts or $HOME/.local/share/fonts.
  • macOS: Resolves to $HOME/Library/Fonts.
  • Windows: Not supported.

§Example

use tauri_sys::path::font_dir;

let font_dir_path = font_dir().await?;