Specifies whether to search the current folder only or the current folder and all sub‑folders.
Raises
Description
ValueError
If folder_path is None.
FileNotFoundError
If the path specified in folder_path cannot be located.
Example
fromgroupdocs.viewer.fontsimportFolderFontSource,SearchOption,FontSettingssrc1=FolderFontSource("C:/fonts/primary",SearchOption.ALL_FOLDERS)src2=FolderFontSource("C:/fonts/backup",SearchOption.TOP_FOLDER_ONLY)# Register the font sources for renderingFontSettings.set_font_sources(src1,src2)# When done, reset to avoid leaking sourcesFontSettings.reset_font_sources()