本文整理汇总了Java中org.eclipse.jface.viewers.IColorProvider类的典型用法代码示例。如果您正苦于以下问题:Java IColorProvider类的具体用法?Java IColorProvider怎么用?Java IColorProvider使用的例子?那么, 这里精选的类代码示例或许可以为您提供帮助。
IColorProvider类属于org.eclipse.jface.viewers包,在下文中一共展示了IColorProvider类的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: DecoratingColumLabelProvider
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
/**
* Constructor.
*
* @param labelProvider
* the {@link ILabelProvider} to decorate
* @param labelDecorator
* the {@link ILabelDecorator} adding decoration
*/
public DecoratingColumLabelProvider(ILabelProvider labelProvider, ILabelDecorator labelDecorator) {
this.labelProvider = labelProvider;
if (labelProvider instanceof IFontProvider) {
this.fontProvider = (IFontProvider)labelProvider;
} else {
this.fontProvider = null;
}
if (labelProvider instanceof IColorProvider) {
this.colorProvider = (IColorProvider)labelProvider;
} else {
this.colorProvider = null;
}
this.labelDecorator = labelDecorator;
if (labelDecorator instanceof CellLabelProvider) {
this.cellLabelProvider = (CellLabelProvider)labelDecorator;
} else {
this.cellLabelProvider = null;
}
}
示例2: getForeground
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
public Color getForeground(Object element) {
ILabelDecorator colorProvider = getLabelDecorator();
if (colorProvider instanceof IColorProvider) {
return ((IColorProvider) colorProvider).getForeground(element);
}
// Default
return null;
}
示例3: getBackground
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
public Color getBackground(Object element) {
ILabelDecorator colorProvider = getLabelDecorator();
if (colorProvider instanceof IColorProvider) {
return ((IColorProvider) colorProvider).getBackground(element);
}
// Default
return null;
}
示例4: getBackground
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
private Color getBackground(Object element) {
if (element instanceof ItemsListSeparator) {
return null;
}
if (provider instanceof IColorProvider) {
return ((IColorProvider) provider).getBackground(element);
}
return null;
}
示例5: getForeground
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
private Color getForeground(Object element) {
if (element instanceof ItemsListSeparator) {
return Display.getCurrent().getSystemColor(
SWT.COLOR_WIDGET_NORMAL_SHADOW);
}
if (provider instanceof IColorProvider) {
return ((IColorProvider) provider).getForeground(element);
}
return null;
}
示例6: getForeground
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
@Override
public Color getForeground(Object element) {
if (wrappedLabelProvider instanceof IColorProvider) {
return ((IColorProvider) wrappedLabelProvider).getForeground(element);
}
return null;
}
示例7: getBackground
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
@Override
public Color getBackground(Object element) {
if (wrappedLabelProvider instanceof IColorProvider) {
return ((IColorProvider) wrappedLabelProvider).getBackground(element);
}
return null;
}
示例8: getForeground
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
public Color getForeground(Object element)
{
if (disabled || !invasiveThemesEnabled())
{
if (wrapped instanceof IColorProvider)
{
return ((IColorProvider) wrapped).getForeground(element);
}
return null;
}
return getThemeManager().getCurrentTheme().getForegroundColor();
}
示例9: getColorProvider
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
@Override
public IColorProvider getColorProvider(){
return fileLabelProvider;
}
示例10: getColorProvider
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
@Override
public IColorProvider getColorProvider(){
return labelProvider;
}
示例11: getColorProvider
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
@Override
public IColorProvider getColorProvider(){
// TODO Auto-generated method stub
return null;
}
示例12: getColorProvider
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
@Override
public IColorProvider getColorProvider(){
return null;
}
示例13: getColorProvider
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
/**
* ColorProvider used by the outbox viewer.
*
* @return IColorProvider or null
*/
public IColorProvider getColorProvider();
示例14: getColorProvider
import org.eclipse.jface.viewers.IColorProvider; //导入依赖的package包/类
/**
* ColorProvider used by the inbox viewer.
*
* @return IColorProvider or null
*/
public IColorProvider getColorProvider();