JavaTM Platform
Standard Ed. 6

javax.swing.plaf.basic
クラス BasicSplitPaneUI.BasicHorizontalLayoutManager

java.lang.Object
  上位を拡張 javax.swing.plaf.basic.BasicSplitPaneUI.BasicHorizontalLayoutManager
すべての実装されたインタフェース:
LayoutManager, LayoutManager2
直系の既知のサブクラス:
BasicSplitPaneUI.BasicVerticalLayoutManager
含まれているクラス:
BasicSplitPaneUI

public class BasicSplitPaneUI.BasicHorizontalLayoutManager
extends Object
implements LayoutManager2

HORIZONTAL_SPLIT 方向の JSplitPane の LayoutManager です。


フィールドの概要
protected  Component[] components
           
protected  int[] sizes
           
 
メソッドの概要
 void addLayoutComponent(Component comp, Object constraints)
          指定された制約オブジェクトを使って、指定されたコンポーネントをレイアウトに追加します。
 void addLayoutComponent(String place, Component component)
          コンポーネントを place に追加します。
protected  int getAvailableSize(Dimension containerSize, Insets insets)
          コンテナのサイズとインセットに基づいて有効な幅を返します。
protected  int getInitialLocation(Insets insets)
          Insets が null でない場合は左インセット、null の場合は 0 を返します。
 float getLayoutAlignmentX(Container target)
          x 軸方向の配置を返します。
 float getLayoutAlignmentY(Container target)
          y 軸方向の配置を返します。
protected  int getPreferredSizeOfComponent(Component c)
          渡されたコンポーネントの適切なサイズの幅を返します。
protected  int getSizeOfComponent(Component c)
          渡されたコンポーネントの幅を返します。
protected  int[] getSizes()
          コンポーネントのサイズを返します。
 void invalidateLayout(Container c)
          何も行いません。
 void layoutContainer(Container container)
          実際のレイアウトを行います。
 Dimension maximumLayoutSize(Container target)
          最大のレイアウトサイズを返します。
 Dimension minimumLayoutSize(Container container)
          子を格納するために必要な最小サイズを返します。
 Dimension preferredLayoutSize(Container container)
          子を格納するための適切なサイズを返します。
 void removeLayoutComponent(Component component)
          指定されたコンポーネントを削除します。
protected  void resetSizeAt(int index)
          渡された位置にある Component のサイズをリセットします。
 void resetToPreferredSizes()
          次回このインスタンスが配置されるときに適切なサイズを設定するように、レシーバにマークします。
protected  void setComponentToSize(Component c, int size, int location, Insets insets, Dimension containerSize)
          x 位置を location、y 位置を insets.top に配置することにより、コンポーネント c の幅を size に設定し、その高さを containersize.height から上インセットと下インセットを減算した値に設定します。
protected  void setSizes(int[] newSizes)
          サイズを newSizes に設定します。
protected  void updateComponents()
          コンポーネントを判定します。
 
クラス java.lang.Object から継承されたメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

フィールドの詳細

sizes

protected int[] sizes

components

protected Component[] components
メソッドの詳細

layoutContainer

public void layoutContainer(Container container)
実際のレイアウトを行います。

定義:
インタフェース LayoutManager 内の layoutContainer
パラメータ:
container - 配置されるコンテナ

addLayoutComponent

public void addLayoutComponent(String place,
                               Component component)
コンポーネントを place に追加します。place は、JSplitPane.LEFT、RIGHT、TOP、BOTTOM、または null (ディバイダの場合) のどれかである必要があります。

定義:
インタフェース LayoutManager 内の addLayoutComponent
パラメータ:
place - コンポーネントに関連付けられた文字列
component - 追加されるコンポーネント

minimumLayoutSize

public Dimension minimumLayoutSize(Container container)
子を格納するために必要な最小サイズを返します。幅はそれぞれの子の最小幅の合計、高さはそれぞれの子の最小の高さの最大値です。

定義:
インタフェース LayoutManager 内の minimumLayoutSize
パラメータ:
container - 配置されるコンポーネント
関連項目:
LayoutManager.preferredLayoutSize(java.awt.Container)

preferredLayoutSize

public Dimension preferredLayoutSize(Container container)
子を格納するための適切なサイズを返します。幅はそれぞれの子の適切な幅の合計、高さはそれぞれの子の適切な高さの最大値です。

定義:
インタフェース LayoutManager 内の preferredLayoutSize
パラメータ:
container - 配置されるコンテナ
関連項目:
LayoutManager.minimumLayoutSize(java.awt.Container)

removeLayoutComponent

public void removeLayoutComponent(Component component)
指定されたコンポーネントを削除します。

定義:
インタフェース LayoutManager 内の removeLayoutComponent
パラメータ:
component - 削除されるコンポーネント

addLayoutComponent

public void addLayoutComponent(Component comp,
                               Object constraints)
指定された制約オブジェクトを使って、指定されたコンポーネントをレイアウトに追加します。

定義:
インタフェース LayoutManager2 内の addLayoutComponent
パラメータ:
comp - 追加されるコンポーネント
constraints - レイアウトにコンポーネントを追加する場所/方法

getLayoutAlignmentX

public float getLayoutAlignmentX(Container target)
x 軸方向の配置を返します。これは、そのコンポーネントがほかのコンポーネントに対してどのように配置されるべきかを指定したものです。この値は 0 から 1 の間の数値で、0 は基点に沿った配置を表し、1 は基点からもっとも遠いところに、0.5 は中央に配置されます。

定義:
インタフェース LayoutManager2 内の getLayoutAlignmentX

getLayoutAlignmentY

public float getLayoutAlignmentY(Container target)
y 軸方向の配置を返します。これは、そのコンポーネントがほかのコンポーネントに対してどのように配置されるべきかを指定したものです。この値は 0 から 1 の間の数値で、0 は基点に沿った配置を表し、1 は基点からもっとも遠いところに、0.5 は中央に配置されます。

定義:
インタフェース LayoutManager2 内の getLayoutAlignmentY

invalidateLayout

public void invalidateLayout(Container c)
何も行いません。ビューのどれかのサイズを変更する場合、開発者は JSplitPane.resetToPreferredSizes をメッセージとして送る必要があります。

定義:
インタフェース LayoutManager2 内の invalidateLayout

maximumLayoutSize

public Dimension maximumLayoutSize(Container target)
最大のレイアウトサイズを返します。両方向とも Integer.MAX_VALUE です。

定義:
インタフェース LayoutManager2 内の maximumLayoutSize
関連項目:
Component.getMaximumSize(), LayoutManager

resetToPreferredSizes

public void resetToPreferredSizes()
次回このインスタンスが配置されるときに適切なサイズを設定するように、レシーバにマークします。


resetSizeAt

protected void resetSizeAt(int index)
渡された位置にある Component のサイズをリセットします。


setSizes

protected void setSizes(int[] newSizes)
サイズを newSizes に設定します。


getSizes

protected int[] getSizes()
コンポーネントのサイズを返します。


getPreferredSizeOfComponent

protected int getPreferredSizeOfComponent(Component c)
渡されたコンポーネントの適切なサイズの幅を返します。


getSizeOfComponent

protected int getSizeOfComponent(Component c)
渡されたコンポーネントの幅を返します。


getAvailableSize

protected int getAvailableSize(Dimension containerSize,
                               Insets insets)
コンテナのサイズとインセットに基づいて有効な幅を返します。


getInitialLocation

protected int getInitialLocation(Insets insets)
Insets が null でない場合は左インセット、null の場合は 0 を返します。


setComponentToSize

protected void setComponentToSize(Component c,
                                  int size,
                                  int location,
                                  Insets insets,
                                  Dimension containerSize)
x 位置を location、y 位置を insets.top に配置することにより、コンポーネント c の幅を size に設定し、その高さを containersize.height から上インセットと下インセットを減算した値に設定します。


updateComponents

protected void updateComponents()
コンポーネントを判定します。このメソッドは、新しいインスタンスが既存の SplitPane にインストールされるときに必ず呼び出されます。


JavaTM Platform
Standard Ed. 6

バグの報告と機能のリクエスト
さらに詳しい API リファレンスおよび開発者ドキュメントについては、Java SE 開発者用ドキュメントを参照してください。開発者向けの詳細な解説、概念の概要、用語の定義、バグの回避策、およびコード実例が含まれています。

Copyright 2009 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Documentation Redistribution Policy も参照してください。