javax.swing.JPanel

實現的接口:Accessible,ImageObserver,MenuContainer,Serializable
已知的直接子類:AbstratColorChooserPanel ,JSpinner.DefaultEditor
 
JPanel是一個通用的輕量級容器。
 
警告:
Serialized objects of thisclass will not be compatible with future Swing releases. Thecurrent serialization support is appropriate for short term storageor RMI between applications running the same version of Swing. Asof 1.4, support for long term storage of all JavaBeansTMhas been added to the java.beans package. Please seeXMLEncoder. 
此類的序列化對象與之後的Swing版本不兼容。當前序列化支持運行相同的Swing版本的應用程序之間的短時間存儲或 RMI(即Remote Method Invoke 遠程方法調用)。在1.4版本中,支持長期存儲的,已經添加到java.beans包中,請參考XMLEncoder.
 
嵌套類歸納:
JPanel.AccessibleJPanel 這個類實現了對JPanel類的可訪問性支持。
 
 
構造方法概述:
JPanel() 建立一個具備雙緩衝和流動佈局的新JPanel。
JPanel(booleanisDoubleBuffered) 創造具備FlowLayout佈局和指定的緩衝策略的新JPanel。
JPanel(LayoutManagerlayout) 建立一個具備雙緩衝和指定佈局的新JPanel。
JPanel(LayoutManagerlayout,booleanisDoubleBuffered) 建立一個指定緩衝策略和指定佈局的新JPanel。
 
方法概述:
AccessibleContextgetAccessibleContext() 
Gets the AccessibleContextassociated with this JPanel. For JPanels, the AccessibleContexttakes the form of an AccessibleJPanel. A new AccessibleJPanelinstance is created if necessary. 
獲取與當前JPanel相關的AccessibleContext 對象。對JPanel來講,AccessibleContext 類以AccessibleJPanel的形式出現,若是必要,一個新的AccessibleJPanel實例會被建立。
PanelUI getUI() -返回渲染該組件的PanelUI對象
String getUIClassID() -獲取渲染組件的類的名字
protected String paramString()- 返回此JPanel的字符串表示。此方法僅用於調試目的,返回的字符串的內容和格式在實現中可能會有所不一樣。返回的字符串多是空的,但可能不是空的。
void setUI(PanelUI ui) -設置渲染該組件的外觀和感受的對象爲ui
void updateUI() -更當前的UI屬性
相關文章
相關標籤/搜索