|
JavaTM Platform Standard Ed. 6 |
|||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
java.lang.Objectjavax.swing.border.AbstractBorder
javax.swing.border.BevelBorder
javax.swing.border.SoftBevelBorder
public class SoftBevelBorder
实现某种斜面的类,这种斜面要么凸出要么凹入且拐角圆滑。
警告:此类的已序列化对象与以后的 Swing 版本不兼容。当前序列化支持适用于短期存储,或适用于在运行相同 Swing 版本的应用程序之间进行 RMI(Remote Method Invocation,远程方法调用)。从 1.4 版本开始,已在 java.beans 包中添加了支持所有 JavaBeansTM 长期存储的功能。请参见 XMLEncoder。
| 字段摘要 |
|---|
| 从类 javax.swing.border.BevelBorder 继承的字段 |
|---|
bevelType, highlightInner, highlightOuter, LOWERED, RAISED, shadowInner, shadowOuter |
| 构造方法摘要 | |
|---|---|
SoftBevelBorder(int bevelType)
创建具有用指定类型的斜面边框,其颜色将从传递给 paintBorder 方法的组件背景色派生。 |
|
SoftBevelBorder(int bevelType,
Color highlight,
Color shadow)
创建具有指定类型、高亮显示和阴影颜色的斜面边框。 |
|
SoftBevelBorder(int bevelType,
Color highlightOuterColor,
Color highlightInnerColor,
Color shadowOuterColor,
Color shadowInnerColor)
创建具有指定类型、高亮显示和阴影颜色的斜面边框。 |
|
| 方法摘要 | |
|---|---|
Insets |
getBorderInsets(Component c)
返回边框的 insets。 |
Insets |
getBorderInsets(Component c,
Insets insets)
用此边框的当前 Insets 重新初始化 insets 参数。 |
boolean |
isBorderOpaque()
返回边框是否透明。 |
void |
paintBorder(Component c,
Graphics g,
int x,
int y,
int width,
int height)
按照指定的位置和尺寸绘制指定组件的边框。 |
| 从类 javax.swing.border.AbstractBorder 继承的方法 |
|---|
getBaseline, getBaselineResizeBehavior, getInteriorRectangle, getInteriorRectangle |
| 从类 java.lang.Object 继承的方法 |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| 构造方法详细信息 |
|---|
public SoftBevelBorder(int bevelType)
bevelType - 边框斜面类型
public SoftBevelBorder(int bevelType,
Color highlight,
Color shadow)
bevelType - 边框的斜面类型highlight - 斜面高亮显示所用颜色shadow - 斜面阴影所用颜色
public SoftBevelBorder(int bevelType,
Color highlightOuterColor,
Color highlightInnerColor,
Color shadowOuterColor,
Color shadowInnerColor)
bevelType - 边框的斜面类型highlightOuterColor - 斜面外部高亮显示所用颜色highlightInnerColor - 斜面内部高亮显示所用颜色shadowOuterColor - 斜面外部阴影所用颜色shadowInnerColor - 斜面内部阴影所用颜色| 方法详细信息 |
|---|
public void paintBorder(Component c,
Graphics g,
int x,
int y,
int width,
int height)
Border 中的 paintBorderBevelBorder 中的 paintBorderc - 要为其绘制边框的组件g - 绘制的图形x - 所绘制边框的 x 坐标位置y - 所绘制边框的 y 坐标位置width - 所绘制边框的宽度height - 所绘制边框的高度public Insets getBorderInsets(Component c)
Border 中的 getBorderInsetsBevelBorder 中的 getBorderInsetsc - 要应用此边框 insets 值的组件
Insets 对象
public Insets getBorderInsets(Component c,
Insets insets)
BevelBorder 中的 getBorderInsetsc - 应用此边框 insets 值的组件insets - 要重新初始化的对象
insets 对象public boolean isBorderOpaque()
Border 中的 isBorderOpaqueBevelBorder 中的 isBorderOpaque
|
JavaTM Platform Standard Ed. 6 |
|||||||||
| 上一个类 下一个类 | 框架 无框架 | |||||||||
| 摘要: 嵌套 | 字段 | 构造方法 | 方法 | 详细信息: 字段 | 构造方法 | 方法 | |||||||||
版权所有 2007 Sun Microsystems, Inc. 保留所有权利。 请遵守许可证条款。另请参阅文档重新分发政策。