Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Eclipse Draw2d
3.3

org.eclipse.draw2d
Class SchemeBorder.Scheme

java.lang.Object
  extended by
org.eclipse.draw2d.SchemeBorder.Scheme
Direct Known Subclasses:
ButtonBorder.ButtonScheme
Enclosing class:
SchemeBorder

public static class SchemeBorder.Scheme
extends java.lang.Object

Holds a set of information about a border, which can be changed to create a wide range of schemes. Provides support for border opacity, size, highlight side and shadow side colors.


Field Summary
protected  Color[] highlight
          Arrays of Colors, used for highlight and shadow effecsts
protected  Color[] shadow
          Arrays of Colors, used for highlight and shadow effecsts
 
Constructor Summary
protected SchemeBorder.Scheme ()
          Constructs a default border Scheme with no border sides.
  SchemeBorder.Scheme (Color[] colors)
          Constructs a border scheme with the specified colors.
  SchemeBorder.Scheme (Color[] highlight, Color[] shadow)
          Constructs a border Scheme with the specified highlight and shadow colors.
 
Method Summary
protected   Insets calculateInsets ()
          Calculates and returns the Insets for this border Scheme.
protected  boolean calculateOpaque ()
          Calculates and retuns the opaque state of this border scheme.
protected  Color[] getHighlight ()
          Returns the highlight colors of this border scheme as an array of Colors.
protected   Insets getInsets ()
          Returns the Insets required by this Scheme.
protected  Color[] getShadow ()
          Returns the shadow colors of this border scheme as an array of Colors.
protected  void init ()
          Calculates and initializes the properties of this border scheme.
protected  boolean isOpaque ()
          Returns whether this border should be opaque or not.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

highlight

protected Color[] highlight
Arrays of Colors, used for highlight and shadow effecsts


shadow

protected Color[] shadow
Arrays of Colors, used for highlight and shadow effecsts

Constructor Detail

SchemeBorder.Scheme

protected SchemeBorder.Scheme()
Constructs a default border Scheme with no border sides.

Since:
2.0

SchemeBorder.Scheme

public SchemeBorder.Scheme(Color[] highlight,
                           Color[] shadow)
Constructs a border Scheme with the specified highlight and shadow colors. The size of the border depends on the number of colors passed in for each parameter. Hightlight colors are used in the top and left sides of the border, and Shadow colors are used in the bottom and right sides of the border.

Parameters:
highlight - the hightlight colors
shadow - the shadow colors
Since:
2.0

SchemeBorder.Scheme

public SchemeBorder.Scheme(Color[] colors)
Constructs a border scheme with the specified colors. The input colors serve as both highlight and shadow colors. The size of the border is the number of colors passed in as input. Hightlight colors are used in the top and left sides of the border, and Shadow colors are used in the bottom and right sides of the border.

Parameters:
colors - the colors to be used for the border
Since:
2.0
Method Detail

calculateInsets

protected 
Insets calculateInsets()
Calculates and returns the Insets for this border Scheme. The calculations depend on the number of colors passed in as input.

Returns:
the Insets used by this border
Since:
2.0

calculateOpaque

protected boolean calculateOpaque()
Calculates and retuns the opaque state of this border scheme. Returns false if any of the border colors are null. This is done to prevent the appearance of underlying pixels since the border color is null.

Returns:
true if this border is opaque
Since:
2.0

getHighlight

protected Color[] getHighlight()
Returns the highlight colors of this border scheme as an array of Colors.

Returns:
the highlight colors
Since:
2.0

getInsets

protected 
Insets getInsets()
Returns the Insets required by this Scheme.

Returns:
the Insets
Since:
2.0

getShadow

protected Color[] getShadow()
Returns the shadow colors of this border scheme as an array of Colors.

Returns:
the shadow colors
Since:
2.0

init

protected void init()
Calculates and initializes the properties of this border scheme.

Since:
2.0

isOpaque

protected boolean isOpaque()
Returns whether this border should be opaque or not.

Returns:
true if this border is opaque
Since:
2.0

Eclipse Draw2d
3.3

Copyright (c) IBM Corp. and others 2000, 2007. All Rights Reserved.

 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire