|
JavaTM Platform Standard Ed. 6 |
|||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
java.lang.Objectjavax.swing.plaf.metal.MetalTheme
javax.swing.plaf.metal.DefaultMetalTheme
public class DefaultMetalTheme
Java Look & Feel のオリジナルの外観 (コード名 Steel) を提供する MetalTheme の具象実装です。デフォルトのテーマの変更方法については、MetalLookAndFeel.setCurrentTheme(javax.swing.plaf.metal.MetalTheme) を参照してください。
DefaultMetalTheme から返される色はすべて完全に不透明です。
DefaultMetalTheme は、多くのコントロールで太字フォントを使用します。すべてのコントロール (内部フレームのタイトルやクライアントで装飾したフレームのタイトルバーを除く) がプレーンフォントを使用するようにするには、次のいずれかを行います。
swing.boldMetal を false に設定する。例: java -Dswing.boldMetal=false MyApp
swing.boldMetal を Boolean.FALSE に設定する。例を示します。UIManager.put("swing.boldMetal", Boolean.FALSE);
swing.boldMetal を設定すると、同じ名前のシステムプロパティーよりも優先して使用されます。デフォルトプロパティーを設定したあとは MetalLookAndFeel を再インストールし、以前に作成したウィジェットの UI をすべて更新する必要があります。そうしない場合は結果が定義できません。次に、この方法を示します。
// turn off bold fonts
UIManager.put("swing.boldMetal", Boolean.FALSE);
// re-install the Metal Look and Feel
UIManager.setLookAndFeel(new MetalLookAndFeel());
// Update the ComponentUIs for all Components. This
// needs to be invoked for all windows.
SwingUtilities.updateComponentTreeUI(rootComponent);
警告: このクラスの直列化されたオブジェクトは、今後の Swing リリースと互換ではなくなる予定です。現在の直列化のサポートは、短期間の運用や、同じバージョンの Swing を実行するアプリケーション間の RMI に適しています。JDK Version 1.4 以降、すべての JavaBeans™ の長期間の運用サポートは、java.beans パッケージに追加されています。詳細は、XMLEncoder を参照してください。
MetalLookAndFeel,
MetalLookAndFeel.setCurrentTheme(javax.swing.plaf.metal.MetalTheme)| コンストラクタの概要 | |
|---|---|
DefaultMetalTheme()
DefaultMetalTheme のインスタンスを生成し、それを返します。 |
|
| メソッドの概要 | |
|---|---|
FontUIResource |
getControlTextFont()
コントロールテキストフォントを返します。 |
FontUIResource |
getMenuTextFont()
メニューテキストフォントを返します。 |
String |
getName()
このテーマの名前を返します。 |
protected ColorUIResource |
getPrimary1()
Primary 1 カラーを返します。 |
protected ColorUIResource |
getPrimary2()
Primary 2 カラーを返します。 |
protected ColorUIResource |
getPrimary3()
Primary 3 カラーを返します。 |
protected ColorUIResource |
getSecondary1()
Secondary 1 カラーを返します。 |
protected ColorUIResource |
getSecondary2()
Secondary 2 カラーを返します。 |
protected ColorUIResource |
getSecondary3()
Secondary 3 カラーを返します。 |
FontUIResource |
getSubTextFont()
サブテキストフォントを返します。 |
FontUIResource |
getSystemTextFont()
システムテキストフォントを返します。 |
FontUIResource |
getUserTextFont()
ユーザーテキストフォントを返します。 |
FontUIResource |
getWindowTitleFont()
ウィンドウタイトルフォントを返します。 |
| クラス java.lang.Object から継承されたメソッド |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| コンストラクタの詳細 |
|---|
public DefaultMetalTheme()
DefaultMetalTheme のインスタンスを生成し、それを返します。
| メソッドの詳細 |
|---|
public String getName()
Steel を返します。
MetalTheme 内の getNameprotected ColorUIResource getPrimary1()
MetalTheme 内の getPrimary1protected ColorUIResource getPrimary2()
MetalTheme 内の getPrimary2protected ColorUIResource getPrimary3()
MetalTheme 内の getPrimary3protected ColorUIResource getSecondary1()
MetalTheme 内の getSecondary1protected ColorUIResource getSecondary2()
MetalTheme 内の getSecondary2protected ColorUIResource getSecondary3()
MetalTheme 内の getSecondary3public FontUIResource getControlTextFont()
MetalTheme 内の getControlTextFontpublic FontUIResource getSystemTextFont()
MetalTheme 内の getSystemTextFontpublic FontUIResource getUserTextFont()
MetalTheme 内の getUserTextFontpublic FontUIResource getMenuTextFont()
MetalTheme 内の getMenuTextFontpublic FontUIResource getWindowTitleFont()
MetalTheme 内の getWindowTitleFontpublic FontUIResource getSubTextFont()
MetalTheme 内の getSubTextFont
|
JavaTM Platform Standard Ed. 6 |
|||||||||
| 前のクラス 次のクラス | フレームあり フレームなし | |||||||||
| 概要: 入れ子 | フィールド | コンストラクタ | メソッド | 詳細: フィールド | コンストラクタ | メソッド | |||||||||
Copyright 2009 Sun Microsystems, Inc. All rights reserved. Use is subject to license terms. Documentation Redistribution Policy も参照してください。