目录搜索
文字
分享


JavaTM 2 Platform
Standard Ed. 6

javax.swing.plaf.multi
类 MultiListUI

1

2

3

4

java.lang.Object

  <img src="../../../../resources/inherit.gif" alt="继承者 ">javax.swing.plaf.ComponentUI

      <img src="../../../../resources/inherit.gif" alt="继承者 ">javax.swing.plaf.ListUI

          <img src="../../../../resources/inherit.gif" alt="继承者 "><b>javax.swing.plaf.multi.MultiListUI</b>


1

public class <b>MultiListUI</b>

extends ListUI

用于组合 ListUI 的多路 UI。

此文件由 AutoMulti 自动生成。


字段摘要
protected  Vector uis
          包含实际 UI 的向量。
 
构造方法摘要
MultiListUI()
           
 
方法摘要
 boolean contains(JComponent a, int b, int c)
          在由此对象处理的每个 UI 上调用 contains 方法。
static ComponentUI createUI(JComponent a)
          如果任意辅助 LookAndFeel 都支持此 UI,则返回一个多路 UI 实例。
 Accessible getAccessibleChild(JComponent a, int b)
          在由此对象处理的每个 UI 上调用 getAccessibleChild 方法。
 int getAccessibleChildrenCount(JComponent a)
          在由此对象处理的每个 UI 上调用 getAccessibleChildrenCount 方法。
 Rectangle getCellBounds(JList a, int b, int c)
          在由此对象处理的每个 UI 上调用 getCellBounds 方法。
 Dimension getMaximumSize(JComponent a)
          在由此对象处理的每个 UI 上调用 getMaximumSize 方法。
 Dimension getMinimumSize(JComponent a)
          在由此对象处理的每个 UI 上调用 getMinimumSize 方法。
 Dimension getPreferredSize(JComponent a)
          在由此对象处理的每个 UI 上调用 getPreferredSize 方法。
 ComponentUI[] getUIs()
          返回与此多路 UI 关联的 UI 列表。
 Point indexToLocation(JList a, int b)
          在由此对象处理的每个 UI 上调用 indexToLocation 方法。
 void installUI(JComponent a)
          在由此对象处理的每个 UI 上调用 installUI 方法。
 int locationToIndex(JList a, Point b)
          在由此对象处理的每个 UI 上调用 locationToIndex 方法。
 void paint(Graphics a, JComponent b)
          在由此对象处理的每个 UI 上调用 paint 方法。
 void uninstallUI(JComponent a)
          在由此对象处理的每个 UI 上调用 uninstallUI 方法。
 void update(Graphics a, JComponent b)
          在由此对象处理的每个 UI 上调用 update 方法。
 
从类 javax.swing.plaf.ComponentUI 继承的方法
getBaseline, getBaselineResizeBehavior
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

字段详细信息

uis

1

protected Vector <b>uis</b>

包含实际 UI 的向量。这是在对 createUI 的调用中生成的,并且可通过调用 getUIs 方法获得它。可以保证第一个元素是从默认外观获得的实际 UI。

构造方法详细信息

MultiListUI

1

public <b>MultiListUI</b>()

方法详细信息

getUIs

1

public ComponentUI[] <b>getUIs</b>()

返回与此多路 UI 关联的 UI 列表。这允许由意识到组件上多路 UI 的应用程序进行 UI 处理。


locationToIndex

1

2

public int <b>locationToIndex</b>(JList a,

                           Point b)

在由此对象处理的每个 UI 上调用 locationToIndex 方法。

指定者:
ListUI 中的 locationToIndex
参数:
a - 列表
b - 点的坐标
返回:
从第一个 UI 获得的值,该 UI 是从默认 LookAndFeel 获得的 UI

indexToLocation

1

2

public Point <b>indexToLocation</b>(JList a,

                             int b)

在由此对象处理的每个 UI 上调用 indexToLocation 方法。

指定者:
ListUI 中的 indexToLocation
参数:
a - 列表
b - 单元索引
返回:
从第一个 UI 获得的值,该 UI 是从默认 LookAndFeel 获得的 UI

getCellBounds

1

2

3

public Rectangle <b>getCellBounds</b>(JList a,

                               int b,

                               int c)

在由此对象处理的每个 UI 上调用 getCellBounds 方法。

指定者:
ListUI 中的 getCellBounds
参数:
a - 列表
b - 范围内第一个索引
c - 范围内第二个索引
返回:
从第一个 UI 获得的值,该 UI 是从默认 LookAndFeel 获得的 UI

contains

1

2

3

public boolean <b>contains</b>(JComponent a,

                        int b,

                        int c)

在由此对象处理的每个 UI 上调用 contains 方法。

覆盖:
ComponentUI 中的 contains
参数:
a - 将在其中查询 x,y 的组件;此参数常被忽略,但如果 UI 对象是无状态的并由多个组件共享,则可以使用该参数
b - 点的 x 坐标
c - 点的 y 坐标
返回:
从第一个 UI 获得的值,该 UI 是从默认 LookAndFeel 获得的 UI
另请参见:
JComponent.contains(int, int), Component.contains(int, int)

update

1

2

public void <b>update</b>(Graphics a,

                   JComponent b)

在由此对象处理的每个 UI 上调用 update 方法。

覆盖:
ComponentUI 中的 update
参数:
a - 将在其中进行绘制的 Graphics 上下文
b - 将绘制的组件;此参数常被忽略,但如果 UI 对象是无状态的并由多个组件共享,则可以使用该参数
另请参见:
ComponentUI.paint(java.awt.Graphics, javax.swing.JComponent), JComponent.paintComponent(java.awt.Graphics)

createUI

1

public static ComponentUI <b>createUI</b>(JComponent a)

如果任意辅助 LookAndFeel 都支持此 UI,则返回一个多路 UI 实例。否则只返回从默认 LookAndFeel 获得的 UI 对象。


installUI

1

public void <b>installUI</b>(JComponent a)

在由此对象处理的每个 UI 上调用 installUI 方法。

覆盖:
ComponentUI 中的 installUI
参数:
a - 将安装此 UI 委托的组件
另请参见:
ComponentUI.uninstallUI(javax.swing.JComponent), JComponent.setUI(javax.swing.plaf.ComponentUI), JComponent.updateUI()

uninstallUI

1

public void <b>uninstallUI</b>(JComponent a)

在由此对象处理的每个 UI 上调用 uninstallUI 方法。

覆盖:
ComponentUI 中的 uninstallUI
参数:
a - 从中移除此 UI 委托的组件;此参数常被忽略,但如果 UI 对象是无状态的并由多个组件共享,则可以使用该参数
另请参见:
ComponentUI.installUI(javax.swing.JComponent), JComponent.updateUI()

paint

1

2

public void <b>paint</b>(Graphics a,

                  JComponent b)

在由此对象处理的每个 UI 上调用 paint 方法。

覆盖:
ComponentUI 中的 paint
参数:
a - 将在其中进行绘制的 Graphics 上下文
b - 将绘制的组件;此参数常被忽略,但如果 UI 对象是无状态的并由多个组件共享,则可以使用该参数
另请参见:
ComponentUI.update(java.awt.Graphics, javax.swing.JComponent)

getPreferredSize

1

public Dimension <b>getPreferredSize</b>(JComponent a)

在由此对象处理的每个 UI 上调用 getPreferredSize 方法。

覆盖:
ComponentUI 中的 getPreferredSize
参数:
a - 将查询其首选大小的组件;此参数常被忽略,但如果 UI 对象是无状态的并由多个组件共享,则可以使用该参数
返回:
从第一个 UI 获得的值,该 UI 是从默认 LookAndFeel 获得的 UI
另请参见:
JComponent.getPreferredSize(), LayoutManager.preferredLayoutSize(java.awt.Container)

getMinimumSize

1

public Dimension <b>getMinimumSize</b>(JComponent a)

在由此对象处理的每个 UI 上调用 getMinimumSize 方法。

覆盖:
ComponentUI 中的 getMinimumSize
参数:
a - 将查询其最小大小的组件;此参数常被忽略,但如果 UI 对象是无状态的并由多个组件共享,则可以使用该参数
返回:
从第一个 UI 获得的值,该 UI 是从默认 LookAndFeel 获得的 UI
另请参见:
JComponent.getMinimumSize(), LayoutManager.minimumLayoutSize(java.awt.Container), ComponentUI.getPreferredSize(javax.swing.JComponent)

getMaximumSize

1

public Dimension <b>getMaximumSize</b>(JComponent a)

在由此对象处理的每个 UI 上调用 getMaximumSize 方法。

覆盖:
ComponentUI 中的 getMaximumSize
参数:
a - 将查询其最大大小的组件;此参数常被忽略,但如果 UI 对象是无状态的并由多个组件共享,则可以使用该参数
返回:
从第一个 UI 获得的值,该 UI 是从默认 LookAndFeel 获得的 UI
另请参见:
JComponent.getMaximumSize(), LayoutManager2.maximumLayoutSize(java.awt.Container)

getAccessibleChildrenCount

1

public int <b>getAccessibleChildrenCount</b>(JComponent a)

在由此对象处理的每个 UI 上调用 getAccessibleChildrenCount 方法。

覆盖:
ComponentUI 中的 getAccessibleChildrenCount
返回:
从第一个 UI 获得的值,该 UI 是从默认 LookAndFeel 获得的 UI
另请参见:
ComponentUI.getAccessibleChild(javax.swing.JComponent, int)

getAccessibleChild

1

2

public Accessible <b>getAccessibleChild</b>(JComponent a,

                                     int b)

在由此对象处理的每个 UI 上调用 getAccessibleChild 方法。

覆盖:
ComponentUI 中的 getAccessibleChild
b - 子对象的从零开始的索引
返回:
从第一个 UI 获得的值,该 UI 是从默认 LookAndFeel 获得的 UI
另请参见:
ComponentUI.getAccessibleChildrenCount(javax.swing.JComponent)

JavaTM 2 Platform
Standard Ed. 6

提交错误或意见
有关更多的 API 参考资料和开发人员文档,请参阅 Java 2 SDK SE 开发人员文档。该文档包含更详细的、面向开发人员的描述,以及总体概述、术语定义、使用技巧和工作代码示例。

版权所有 2004 Sun Microsystems, Inc. 保留所有权利。 请遵守许可证条款。另请参阅文档重新分发政策。

上一篇:MultiLabelUI下一篇:MultiLookAndFeel