|
JavaTM 2 Platform Standard Ed. 6 |
|||||||||
| 上一個類別 下一個類別 | 框架 無框架 | |||||||||
| 摘要: 巢狀 | 欄位 | 建構子 | 方法 | 詳細資訊: 欄位 | 建構子 | 方法 | |||||||||
public interface Border
該介面描述一個能夠呈現圍繞 swing 元件邊緣邊框的物件。有關使用 border 的範例,請參閱 The Java Tutorial 中的 How to Use Borders 一節。
在 Swing 元件集中,作為一種創建元件邊緣四周的裝飾或普通區域的機制,border 取代了 Insets。
用法說明:
setInsets)。
BorderFactory,
EmptyBorder,
CompoundBorder| 方法摘要 | |
|---|---|
Insets |
getBorderInsets(Component c)
返回該邊框的 insets。 |
boolean |
isBorderOpaque()
返回此邊框是否透明。 |
void |
paintBorder(Component c,
Graphics g,
int x,
int y,
int width,
int height)
按指定的位置和尺寸繪製指定元件的邊框。 |
| 方法詳細資訊 |
|---|
void paintBorder(Component c,
Graphics g,
int x,
int y,
int width,
int height)
c - 要為其繪製邊框的元件g - 繪製的圖形x - 所繪製邊框的 x 坐標位置y - 所繪製邊框的 y 坐標位置width - 所繪製邊框的寬度height - 所繪製邊框的高度Insets getBorderInsets(Component c)
c - 要應用此邊框 insets 值的元件boolean isBorderOpaque()
|
JavaTM 2 Platform Standard Ed. 6 |
|||||||||
| 上一個類別 下一個類別 | 框架 無框架 | |||||||||
| 摘要: 巢狀 | 欄位 | 建構子 | 方法 | 詳細資訊: 欄位 | 建構子 | 方法 | |||||||||
版權所有 2008 Sun Microsystems, Inc. 保留所有權利。請遵守GNU General Public License, version 2 only。