本文整理了Java中org.apache.poi.xssf.usermodel.XSSFColor.getTheme()
方法的一些代码示例,展示了XSSFColor.getTheme()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。XSSFColor.getTheme()
方法的具体详情如下:
包路径:org.apache.poi.xssf.usermodel.XSSFColor
类名称:XSSFColor
方法名:getTheme
[英]Index into the collection, referencing a particular or value expressed in the Theme part.
[中]索引到集合中,引用主题部分中表达的特定或值。
代码示例来源:origin: org.apache.poi/poi-ooxml
private boolean sameTheme(XSSFColor other) {
if (isThemed() == other.isThemed()) {
return !isThemed() || getTheme() == other.getTheme();
}
return false;
}
private boolean sameTint(XSSFColor other) {
代码示例来源:origin: org.apache.poi/poi-ooxml
/**
* If the colour is based on a theme, then inherit
* information (currently just colours) from it as
* required.
*/
@Override
public void inheritFromThemeAsRequired(XSSFColor color) {
if(color == null) {
// Nothing for us to do
return;
}
if(! color.getCTColor().isSetTheme()) {
// No theme set, nothing to do
return;
}
// Get the theme colour
XSSFColor themeColor = getThemeColor(color.getTheme());
// Set the raw colour, not the adjusted one
// Do a raw set, no adjusting at the XSSFColor layer either
color.getCTColor().setRgb(themeColor.getCTColor().getRgb());
// All done
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi
private boolean sameTheme(XSSFColor other) {
if (isThemed() == other.isThemed()) {
return !isThemed() || getTheme() == other.getTheme();
}
return false;
}
private boolean sameTint(XSSFColor other) {
代码示例来源:origin: jbaliuka/x4j-analytic
public Color getAwtColor(XSSFColor color) {
if(color == null){
return Color.BLACK;
}
if (color.getRgb() != null) {
return new Color(ByteBuffer.wrap(color.getRgb()).getInt(), true);
}
else {
if(color.getIndexed() == 64){
return Color.BLACK;
}
return getAwtColor(color.getTheme(), color.getTint());
}
}
代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.poi
/**
* If the colour is based on a theme, then inherit
* information (currently just colours) from it as
* required.
*/
@Override
public void inheritFromThemeAsRequired(XSSFColor color) {
if(color == null) {
// Nothing for us to do
return;
}
if(! color.getCTColor().isSetTheme()) {
// No theme set, nothing to do
return;
}
// Get the theme colour
XSSFColor themeColor = getThemeColor(color.getTheme());
// Set the raw colour, not the adjusted one
// Do a raw set, no adjusting at the XSSFColor layer either
color.getCTColor().setRgb(themeColor.getCTColor().getRgb());
// All done
}
代码示例来源:origin: org.openl.rules/org.openl.lib.poi.dev
/**
* If the colour is based on a theme, then inherit
* information (currently just colours) from it as
* required.
*/
public void inheritFromThemeAsRequired(XSSFColor color) {
if(color == null) {
// Nothing for us to do
return;
}
if(! color.getCTColor().isSetTheme()) {
// No theme set, nothing to do
return;
}
// Get the theme colour
XSSFColor themeColor = getThemeColor(color.getTheme());
// Set the raw colour, not the adjusted one
// Do a raw set, no adjusting at the XSSFColor layer either
color.getCTColor().setRgb(themeColor.getCTColor().getRgb());
// All done
}
}
内容来源于网络,如有侵权,请联系作者删除!