ThemeProvider Class

Definition

在设计器环境中为控件提供封装主题和样式表信息的类。Provides a class that encapsulates theme and style sheet information for controls in a designer environment.

public ref class ThemeProvider sealed
public sealed class ThemeProvider
type ThemeProvider = class
Public NotInheritable Class ThemeProvider
Inheritance
ThemeProvider

Remarks

页面开发人员和控件作者不使用 ThemeProvider 类。Page developers and control authors do not use the ThemeProvider class. ASP.NET 开发人员工具和设计器生成器将 ThemeProvider 类与 SkinBuilder 类和 IThemeResolutionService 接口结合使用,以便在设计时将主题及其各自的控件外观应用于控件。ASP.NET developer tool and designer builders use the ThemeProvider class in conjunction with the SkinBuilder class and the IThemeResolutionService interface to apply themes and their respective control skins to controls at design time.

ThemeProvider 类封装将主题或样式表主题及其控件外观应用于设计器中控件的子控件所需的信息。The ThemeProvider class encapsulates the information needed to apply a theme or style sheet theme and its control skins to the child controls of a control in a designer.

Constructors

ThemeProvider(IDesignerHost, String, String, String[], String)

初始化 ThemeProvider 类的新实例。Initializes a new instance of the ThemeProvider class.

Properties

ContentHashCode

获取传递给构造函数的主题定义的哈希代码。Gets the hash of the theme definition passed to the constructor.

CssFiles

如果主题是样式表主题,则获取一组字符串,表示与当前主题关联的所有级联样式表 (CSS) 文件的名称。Gets a set of strings that represent the names of any cascading style sheet (CSS) files associated with the current theme, if the theme is a style sheet theme.

DesignerHost

获取表示当前设计器环境的 IDesignerHost 对象。Gets an IDesignerHost object that represents the current designer environment.

ThemeName

获取 ThemeProvider 实例所表示的主题或样式表主题的名称。Gets the name of the theme or style sheet theme that the ThemeProvider instance represents.

Methods

Equals(Object)

确定指定的对象是否等于当前对象。Determines whether the specified object is equal to the current object.

(Inherited from Object)
GetHashCode()

作为默认哈希函数。Serves as the default hash function.

(Inherited from Object)
GetSkinBuilder(Control)

检索用于在设计器环境中应用主题和控件外观的指定控件的 SkinBuilder 实例。Retrieves a SkinBuilder instance for the specified control, which is used to apply a theme and control skin in a designer environment.

GetSkinControlBuildersForControlType(Type)

获取一个 IDictionary 对象,该对象包含指定的 SkinBuilder 的一组 Type 对象。Gets an IDictionary object that contains a set of SkinBuilder objects for the specified Type.

GetSkinsForControl(Type)

获取与指定的 ICollection 关联的外观标识符的 TypeGets an ICollection of skin identifiers that are associated with the specified Type.

GetType()

获取当前实例的 TypeGets the Type of the current instance.

(Inherited from Object)
MemberwiseClone()

创建当前 Object 的浅表副本。Creates a shallow copy of the current Object.

(Inherited from Object)
ToString()

返回表示当前对象的字符串。Returns a string that represents the current object.

(Inherited from Object)

Applies to

See also