[]
此接口表示工作簿主题中基于语言的主题字体集合。它通常从 IThemeFontScheme.getMajor() 或 IThemeFontScheme.getMinor() 获取,并允许访问特定 FontLanguageIndex 的主题字体,例如 Latin、EastAsian 或 ComplexScript。
Theme theme = new Theme("CustomTheme", Themes.GetBerlin());
workbook.setTheme(theme);
IThemeFonts themeFonts = workbook.getTheme().getThemeFontScheme().getMajor();
IThemeFont latinFont = themeFonts.get(FontLanguageIndex.Latin);
latinFont.setName("Aptos");
IThemeFont eastAsianFont = themeFonts.get(FontLanguageIndex.EastAsian);
int count = themeFonts.getCount();
get(FontLanguageIndex index) IThemeFont,使用 FontLanguageIndex。intgetCount()IThemeFont,使用 FontLanguageIndex。使用此方法可以访问当前主题字体集合中特定语言类别的主题字体,例如 Latin、EastAsian 或 ComplexScript。此集合通常从 IThemeFontScheme.getMajor() 或 IThemeFontScheme.getMinor() 获取。
IThemeFonts themeFonts = workbook.getTheme().getThemeFontScheme().getMajor();
IThemeFont latinFont = themeFonts.get(FontLanguageIndex.Latin);
String fontName = latinFont.getName();
index - 指定 FontLanguageIndex。IThemeFont。使用此方法可以确定当前 IThemeFonts 集合中有多少个特定语言的主题字体条目可用。
Theme theme = new Theme("CustomTheme", Themes.GetBerlin());
workbook.setTheme(theme);
IThemeFonts majorFonts = workbook.getTheme().getThemeFontScheme().getMajor();
int count = majorFonts.getCount();