|
JavaTM 2 Platform Standard Ed. 5.0 |
|||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
java.lang.Objectjavax.swing.border.AbstractBorder
javax.swing.border.LineBorder
public class LineBorder
直線ボーダを実装するクラスです。ボーダの太さは任意、カラーは単色です。
警告: このクラスの直列化されたオブジェクトは、今後の Swing リリースと互換ではなくなる予定です。現在の直列化のサポートは、短期間の運用や、同じバージョンの Swing を実行するアプリケーション間の RMI に適しています。JDK バージョン 1.4 以降、すべての JavaBeans™ の長期間の運用サポートは、java.beans パッケージに追加されています。詳細は、XMLEncoder を参照してください。
| フィールドの概要 | |
|---|---|
protected Color |
lineColor
|
protected boolean |
roundedCorners
|
protected int |
thickness
|
| コンストラクタの概要 | |
|---|---|
LineBorder(Color color)
直線ボーダを、指定されたカラーおよび太さ (thickness = 1) で作成します。 |
|
LineBorder(Color color,
int thickness)
指定された色と太さで直線ボーダを作成します。 |
|
LineBorder(Color color,
int thickness,
boolean roundedCorners)
指定された色と太さと隅の形状で直線ボーダを作成します。 |
|
| メソッドの概要 | |
|---|---|
static Border |
createBlackLineBorder()
太さ 1 で Color.black の LineBorder を取得するのに便利なメソッドです。 |
static Border |
createGrayLineBorder()
太さ 1 で Color.gray の LineBorder を取得するのに便利なメソッドです。 |
Insets |
getBorderInsets(Component c)
ボーダのインセットの値を返します。 |
Insets |
getBorderInsets(Component c,
Insets insets)
insets パラメータを、この Border の現在の Insets で初期化し直します。 |
Color |
getLineColor()
ボーダのカラーを返します。 |
boolean |
getRoundedCorners()
ボーダの隅を丸く描画するかどうかを返します。 |
int |
getThickness()
ボーダの太さを返します。 |
boolean |
isBorderOpaque()
ボーダが不透明かどうかを返します。 |
void |
paintBorder(Component c,
Graphics g,
int x,
int y,
int width,
int height)
指定されたコンポーネントのボーダを、指定された位置およびサイズでペイントします。 |
| クラス javax.swing.border.AbstractBorder から継承されたメソッド |
|---|
getInteriorRectangle, getInteriorRectangle |
| クラス java.lang.Object から継承されたメソッド |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| フィールドの詳細 |
|---|
protected int thickness
protected Color lineColor
protected boolean roundedCorners
| コンストラクタの詳細 |
|---|
public LineBorder(Color color)
color - ボーダのカラー
public LineBorder(Color color,
int thickness)
color - ボーダのカラーthickness - ボーダの太さ
public LineBorder(Color color,
int thickness,
boolean roundedCorners)
color - ボーダのカラーthickness - ボーダの太さroundedCorners - ボーダの隅を丸くするかどうか| メソッドの詳細 |
|---|
public static Border createBlackLineBorder()
public static Border createGrayLineBorder()
public void paintBorder(Component c,
Graphics g,
int x,
int y,
int width,
int height)
Border 内の paintBorderAbstractBorder 内の paintBorderc - このボーダがペイントされるコンポーネントg - ペイントのグラフィックスx - ペイントされたボーダの x 座標y - ペイントされたボーダの y 座標width - ペイントされたボーダの幅height - ペイントされたボーダの高さpublic Insets getBorderInsets(Component c)
Border 内の getBorderInsetsAbstractBorder 内の getBorderInsetsc - このボーダのインセットの値を適用するコンポーネント
Insets オブジェクト
public Insets getBorderInsets(Component c,
Insets insets)
AbstractBorder 内の getBorderInsetsc - このボーダのインセットの値を適用するコンポーネントinsets - 初期化し直されるオブジェクト
insets オブジェクトpublic Color getLineColor()
public int getThickness()
public boolean getRoundedCorners()
public boolean isBorderOpaque()
Border 内の isBorderOpaqueAbstractBorder 内の isBorderOpaque
|
JavaTM 2 Platform Standard Ed. 5.0 |
|||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
Copyright 2004 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Documentation Redistribution Policy も参照してください。