クラスSynthScrollBarUI
java.lang.Object
javax.swing.plaf.ComponentUI
javax.swing.plaf.ScrollBarUI
javax.swing.plaf.basic.BasicScrollBarUI
javax.swing.plaf.synth.SynthScrollBarUI
- すべての実装されたインタフェース:
LayoutManager, PropertyChangeListener, EventListener, SynthConstants, SynthUI, SwingConstants
public class SynthScrollBarUI extends BasicScrollBarUI implements PropertyChangeListener, SynthUI
JScrollBarのSynth L&F UIの委譲を提供します。- 導入されたバージョン:
- 1.7
-
ネストされたクラスのサマリー
クラスBasicScrollBarUIで宣言されたネストされたクラス/インタフェース
BasicScrollBarUI.ArrowButtonListener, BasicScrollBarUI.ModelListener, BasicScrollBarUI.PropertyChangeHandler, BasicScrollBarUI.ScrollListener, BasicScrollBarUI.TrackListener修飾子と型クラス説明protected classカーソル・キーのリスナーです。protected classモデル変更を待機するリスナーです。classプロパティ変更ハンドラprotected classScrollPaneで開始されるスクロール・イベントのためのリスナーです。protected classマウス・ドラッグを追跡します。 -
フィールドのサマリー
クラスで宣言されたフィールド BasicScrollBarUI
buttonListener, decrButton, DECREASE_HIGHLIGHT, decrGap, incrButton, INCREASE_HIGHLIGHT, incrGap, isDragging, maximumThumbSize, minimumThumbSize, modelListener, NO_HIGHLIGHT, propertyChangeListener, scrollbar, scrollBarWidth, scrollListener, scrollTimer, thumbColor, thumbDarkShadowColor, thumbHighlightColor, thumbLightShadowColor, thumbRect, trackColor, trackHighlight, trackHighlightColor, trackListener, trackRect修飾子と型フィールド説明protected BasicScrollBarUI.ArrowButtonListenerボタン・リスナーprotected JButtonボタンprotected static final int強調表示を減らすprotected int減分ボタンとトラックの間の距離。protected JButtonインクリメント・ボタンprotected static final intハイライトを上げるprotected int増分ボタンとトラックの間の距離。protected booleanドラッグprotected Dimensionサムの最大サイズprotected Dimension最小のサムのサイズprotected BasicScrollBarUI.ModelListenerモデル・リスナーprotected static final intハイライトなしprotected PropertyChangeListenerプロパティ変更リスナーprotected JScrollBarScrollbarprotected int幅(垂直の場合)または高さ(水平の場合)に関するヒント。protected BasicScrollBarUI.ScrollListenerスクロール・リスナーprotected Timerスクロール・タイマーprotected Colorサムの色protected Colorサムの暗い影の色protected Colorサム・ハイライトの色protected Colorサムの光の影の色protected Rectangleサムの矩形protected Colorトラックの色protected intトラックのハイライトprotected Colorトラックのハイライト・カラーprotected BasicScrollBarUI.TrackListenerトラック・リスナーprotected Rectangleトラック矩形インタフェースで宣言されたフィールド SwingConstants
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST修飾子と型フィールド説明static final intボックスの下端を指定するために使用するボックス配置定数です。static final int領域内の中央位置です。static final int東(右)の方角です。static final int水平方向です。static final int左から右に記述する言語および右から左に記述する言語で使用するテキストのリーディング・エッジを指定します。static final intボックスの左端を指定するために使用するボックス配置定数です。static final intシーケンス内の次の方向を指定します。static final int北(上)の方角です。static final int北東(右上)の方角です。static final int北西(左上)の方角です。static final intシーケンス内の前の方向を指定します。static final intボックスの右端を指定するために使用するボックス配置定数です。static final int南(下)の方角です。static final int南東(右下)の方角です。static final int南西(左下)の方角です。static final intボックスの上端を指定するために使用するボックス配置定数です。static final int左から右に記述する言語および右から左に記述する言語で使用するテキストのトレーリング・エッジを指定します。static final int垂直方向です。static final int西(左)の方角です。インタフェースで宣言されたフィールド SynthConstants
DEFAULT, DISABLED, ENABLED, FOCUSED, MOUSE_OVER, PRESSED, SELECTED修飾子と型フィールド説明static final int領域がデフォルトであることを示します。static final int領域が有効でないことを示すプライマリ状態です。static final intコンポーネントが有効であることを示すプライマリ状態です。static final int領域にフォーカスがあることを示します。static final intマウスが領域上にあることを示すプライマリ状態です。static final int領域が押された状態であることを示すプライマリ状態です。static final int領域が選択されていることを示します。 -
コンストラクタのサマリー
コンストラクタ -
メソッドのサマリー
修飾子と型メソッド説明static ComponentUIUIを返します。指定されたコンポーネントのコンテキストを返します。垂直スクロール・バーの推奨幅は、増分ボタンと減分ボタン(null以外)の推奨幅の最大値、およびつまみの最小幅です。voidpaint(Graphics g, JComponent c) Look & Feelに従って、指定されたコンポーネントをペイントします。protected voidpaint(SynthContext context, Graphics g) 指定されたコンポーネントをペイントします。voidpaintBorder(SynthContext context, Graphics g, int x, int y, int w, int h) ボーダーをペイントします。protected voidpaintThumb(SynthContext context, Graphics g, Rectangle thumbBounds) スクロール・バーのつまみをペイントします。protected voidpaintTrack(SynthContext context, Graphics g, Rectangle trackBounds) スクロール・バーのトラックをペイントします。voidバウンド・プロパティの変更時に呼び出されます。voidupdate(Graphics g, JComponent c) このUI委譲に、指定されたコンポーネントを再ペイントするよう通知します。クラスで宣言されたメソッド BasicScrollBarUI
addLayoutComponent, configureScrollBarColors, createArrowButtonListener, createDecreaseButton, createIncreaseButton, createModelListener, createPropertyChangeListener, createScrollListener, createTrackListener, getMaximumSize, getMaximumThumbSize, getMinimumThumbSize, getSupportsAbsolutePositioning, getThumbBounds, getTrackBounds, installComponents, installDefaults, installKeyboardActions, installListeners, installUI, isThumbRollover, layoutContainer, layoutHScrollbar, layoutVScrollbar, minimumLayoutSize, paintDecreaseHighlight, paintIncreaseHighlight, paintThumb, paintTrack, preferredLayoutSize, removeLayoutComponent, scrollByBlock, scrollByUnit, setThumbBounds, setThumbRollover, uninstallComponents, uninstallDefaults, uninstallKeyboardActions, uninstallListeners, uninstallUI修飾子と型メソッド説明voidaddLayoutComponent(String name, Component child) レイアウト・マネージャがコンポーネントごとの文字列を使用する場合は、レイアウトにコンポーネントcompを追加し、それをnameによって指定された文字列に関連付けます。protected voidスクロール・バーの色を構成します。protected BasicScrollBarUI.ArrowButtonListener矢印ボタン・リスナーを作成します。protected JButtoncreateDecreaseButton(int orientation) 減少ボタンを作成します。protected JButtoncreateIncreaseButton(int orientation) 昇給ボタンを作成します。protected BasicScrollBarUI.ModelListenerモデル・リスナーを作成します。protected PropertyChangeListenerプロパティ変更リスナーを作成します。protected BasicScrollBarUI.ScrollListenerスクロール・リスナーを作成します。protected BasicScrollBarUI.TrackListenerトラック・リスナーを作成します。指定されたコンポーネントの、Look & Feelに適した最大サイズを返します。protected Dimensionつまみに許容される最大のサイズを返します。protected Dimensionつまみに許容される最小のサイズを返します。booleanユーザーがマウス・ジェスチャ(通常はマウスの中央ボタン)を使ってつまみを絶対位置指定できるかどうかを示します。protected Rectangleつまみの現在のサイズ/位置を返します。protected Rectangleトラックの現在の境界(増分ボタンと減分ボタンの間のスペース - イン・セット)を返します。protected voidコンポーネントを取り付けます。protected voidデフォルトをインストールします。protected voidキーボード操作をインストールします。protected voidリスナーをインストールします。voidUIをインストールします。booleanマウスが現在つまみの上にある場合にtrueを返します。voidlayoutContainer(Container scrollbarContainer) 指定されたコンテナを配置します。protected void水平スクロール・バーをレイアウトします。protected void垂直スクロール・バーをレイアウトします。minimumLayoutSize(Container scrollbarContainer) 指定されたコンテナに含まれているコンポーネントを基に、コンテナの最小サイズを計算します。protected void減少ハイライトをペイントします。protected void増加ハイライトをペイントします。protected voidpaintThumb(Graphics g, JComponent c, Rectangle thumbBounds) サムを塗ります。protected voidpaintTrack(Graphics g, JComponent c, Rectangle trackBounds) トラックをペイントします。preferredLayoutSize(Container scrollbarContainer) 指定されたコンテナに含まれているコンポーネントを基に、コンテナの推奨サイズを計算します。voidremoveLayoutComponent(Component child) 指定されたコンポーネントをレイアウトから削除します。protected voidscrollByBlock(int direction) ブロックごとにスクロールします。protected voidscrollByUnit(int direction) 単位でスクロールします。protected voidsetThumbBounds(int x, int y, int width, int height) つまみの境界を設定し、古いthumbBoundsと新しいthumbBoundsを含む再ペイントを強制します。protected voidsetThumbRollover(boolean active) マウスが現在つまみの上にあるかどうかを設定します。protected voidコンポーネントをアンインストールします。protected voidデフォルトをアンインストールします。protected voidキーボード操作をアンインストールします。protected voidリスナーをアンインストールします。voidUIをアンインストールします。クラスで宣言されたメソッド ComponentUI
contains, getAccessibleChild, getAccessibleChildrenCount, getBaseline, getBaselineResizeBehavior, getMinimumSize修飾子と型メソッド説明booleancontains(JComponent c, int x, int y) 指定された x,yの位置が、指定されたコンポーネントのLook & Feel定義の形状内にある場合は、trueを返します。getAccessibleChild(JComponent c, int i) オブジェクトのi番目のAccessibleの子を返します。intオブジェクト内のアクセシビリティ対応の子の数を返します。intgetBaseline(JComponent c, int width, int height) ベースラインを返します。サイズの変化に合わせてコンポーネントのベースラインがどのように変化するかを示す列挙を返します。指定されたコンポーネントの、Look & Feelに適した最小サイズを返します。クラスオブジェクトで宣言されたメソッド
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait修飾子と型メソッド説明protected Objectclone()このオブジェクトのコピーを作成して、返します。booleanこのオブジェクトと他のオブジェクトが等しいかどうかを示します。protected voidfinalize()削除予定のため非推奨: このAPI要素は、将来のバージョンで削除される可能性があります。最終決定は非推奨であり、将来のリリースで削除される可能性があります。final Class<?> getClass()このObjectの実行時クラスを返します。inthashCode()このオブジェクトに対するハッシュ・コード値を返します。final voidnotify()このオブジェクトのモニターで待機中のスレッドを1つ再開します。final voidこのオブジェクトのモニターで待機中のすべてのスレッドを再開します。toString()オブジェクトの文字列表現を返します。final voidwait()現在のスレッドが目覚めるまで待機します。通常、notifiedまたはinterruptedです。final voidwait(long timeoutMillis) 現在のスレッドは、通常、notifiedまたはinterruptedであるか、一定のリアルタイムが経過するまで、目覚めるまで待機します。final voidwait(long timeoutMillis, int nanos) 現在のスレッドは、通常、notifiedまたはinterruptedであるか、一定のリアルタイムが経過するまで、目覚めるまで待機します。
-
コンストラクタの詳細
-
SynthScrollBarUI
public SynthScrollBarUI()SynthScrollBarUIを構築します。
-
-
メソッドの詳細
-
createUI
-
getContext
public SynthContext getContext(JComponent c) 指定されたコンポーネントのコンテキストを返します。- 定義:
getContext、インタフェースSynthUI- パラメータ:
c- SynthContextを要求するコンポーネント。- 戻り値:
- コンポーネントを記述するSynthContext。
-
update
public void update(Graphics g, JComponent c) このUI委譲に、指定されたコンポーネントを再ペイントするよう通知します。 このメソッドはコンポーネントのバックグラウンドをペイントし、paint(SynthContext,Graphics)メソッドを呼び出します。一般に、このメソッドはサブクラスによってオーバーライドする必要はありません。 すべてのLook & Feelの描画コードを
paintメソッドに入れるようにしてください。- オーバーライド:
update、クラスComponentUI- パラメータ:
g- ペイントに使用されるGraphicsオブジェクトc- ペイントされるコンポーネント- 関連項目:
-
paint
public void paint(Graphics g, JComponent c) Look & Feelに従って、指定されたコンポーネントをペイントします。このメソッドは、Synth Look & Feelで使用されません。 ペイントは
paint(SynthContext,Graphics)メソッドによって処理されます。- オーバーライド:
paint、クラスComponentUI- パラメータ:
g- ペイントに使用されるGraphicsオブジェクトc- ペイントされるコンポーネント- 関連項目:
-
paint
protected void paint(SynthContext context, Graphics g) 指定されたコンポーネントをペイントします。- パラメータ:
context- ペイントされるコンポーネントのコンテキストg- ペイントに使用されるGraphicsオブジェクト- 関連項目:
-
paintBorder
public void paintBorder(SynthContext context, Graphics g, int x, int y, int w, int h) ボーダーをペイントします。- 定義:
paintBorder、インタフェースSynthUI- パラメータ:
context- コンポーネント・コンテキストg- ペイントされるGraphicsx- X座標y- Y座標w- ボーダーの幅h- ボーダーの高さ
-
paintTrack
protected void paintTrack(SynthContext context, Graphics g, Rectangle trackBounds) スクロール・バーのトラックをペイントします。- パラメータ:
context- ペイントされるコンポーネントのコンテキストg- ペイントに使用されるGraphicsオブジェクトtrackBounds- トラックのバウンディング・ボックス
-
paintThumb
protected void paintThumb(SynthContext context, Graphics g, Rectangle thumbBounds) スクロール・バーのつまみをペイントします。- パラメータ:
context- ペイントされるコンポーネントのコンテキストg- ペイントに使用されるGraphicsオブジェクトthumbBounds- サムのバウンディング・ボックス
-
getPreferredSize
public Dimension getPreferredSize(JComponent c) 垂直スクロール・バーの推奨幅は、増分ボタンと減分ボタン(null以外)の推奨幅の最大値、およびつまみの最小幅です。 推奨される高さは、同じ部分の推奨される高さの総計です。 水平スクロール・バーの推奨されるサイズの原理も同様です。preferredSizeは1回だけ計算されます。以後、このメソッドを呼び出すと、キャッシュに格納されたサイズ値が返されます。- オーバーライド:
getPreferredSize、クラスBasicScrollBarUI- パラメータ:
c- このメソッドを委譲しているJScrollBar- 戻り値:
- Basic JScrollBarの適切なサイズ
- 関連項目:
-
propertyChange
public void propertyChange(PropertyChangeEvent e) インタフェースからコピーされた説明:PropertyChangeListenerバウンド・プロパティの変更時に呼び出されます。- 定義:
propertyChange、インタフェースPropertyChangeListener- パラメータ:
e- イベント・ソースと変更されたプロパティを記述したPropertyChangeEventオブジェクト。
-