01: /*******************************************************************************
02: * Copyright (c) 2004, 2006 IBM Corporation and others.
03: * All rights reserved. This program and the accompanying materials
04: * are made available under the terms of the Eclipse Public License v1.0
05: * which accompanies this distribution, and is available at
06: * http://www.eclipse.org/legal/epl-v10.html
07: *
08: * Contributors:
09: * IBM Corporation - initial API and implementation
10: *******************************************************************************/package org.eclipse.ui.themes;
11:
12: import org.eclipse.swt.graphics.RGB;
13:
14: /**
15: * A factory interface that may be used to specify a color value. This is
16: * (optionally) used by the themes extension point for color value
17: * definitions.
18: * <p>
19: * Example usage:
20: * <br/>
21: * <code>
22: * <colorDefinition
23: * label="Custom Color"
24: * id="example.customColor"
25: * colorFactory="some.implementor.of.IColorFactory">
26: * </colorDefinition>
27: * </code>
28: * </p>
29: *
30: * @since 3.0
31: */
32: public interface IColorFactory {
33:
34: /**
35: * Create a new color.
36: *
37: * @return a new color. This must never be <code>null</code>.
38: */
39: RGB createColor();
40: }
|