IUIService.Styles プロパティ
アセンブリ: System.Windows.Forms (system.windows.forms.dll 内)


ディクショナリは、ホスト環境からの情報を提供できます。少なくとも、ディクショナリは、標準の UI テキストに使用するフォント、および強調表示に使用する色で構成されています。これらの必須スタイルは "DialogFont" および "HighlightColor" です。
これらのスタイルの値は、スタイルをディクショナリのキーとして使用し、キーをインデクサとして使用してディクショナリにアクセスして取得できます。例 : (IUIService を実装しているオブジェクト).Styles[(引用符で囲まれたスタイル名文字列)]

ホスト環境からダイアログ ボックス フォントを取得するコード例を次に示します。
' The specified IDesigner implements IUIService. Function GetFont(designer As IDesigner) As Font Dim hostfont As Font ' Gets the dialog box font from the host environment. hostfont = CType(CType(designer, IUIService).Styles("DialogFont"), Font) Return hostfont End Function
// The specified IDesigner implements IUIService. Font GetFont(IDesigner designer) { Font hostfont; // Gets the dialog box font from the host environment. hostfont = (Font)((IUIService)designer).Styles["DialogFont"]; return hostfont; }
// The specified IDesigner implements IUIService. System::Drawing::Font^ GetFont( IDesigner^ designer ) { System::Drawing::Font^ hostfont; // Gets the dialog box font from the host environment. hostfont = dynamic_cast<System::Drawing::Font^>(dynamic_cast<IUIService^>(designer)->Styles[ "DialogFont" ]); return hostfont; }

Windows 98, Windows 2000 SP4, Windows Millennium Edition, Windows Server 2003, Windows XP Media Center Edition, Windows XP Professional x64 Edition, Windows XP SP2, Windows XP Starter Edition
開発プラットフォームの中には、.NET Framework によってサポートされていないバージョンがあります。サポートされているバージョンについては、「システム要件」を参照してください。


Weblioに収録されているすべての辞書からIUIService.Styles プロパティを検索する場合は、下記のリンクをクリックしてください。

- IUIService.Styles プロパティのページへのリンク