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属性
相关文章
相关标签/搜索