ComponentOne Themes for WinForms
C1ThemeController Class Members
Fields  Properties  Methods  Events

C1.Win.C1Themes.4 Assembly > C1.Win.C1Themes Namespace : C1ThemeController Class

The following tables list the members exposed by C1ThemeController.

Public Constructors
 NameDescription
Public ConstructorInitializes a new instance of the C1ThemeController class.  
Top
Public Fields
 NameDescription
Public FieldThe default theme name id.

When assigned to the Theme property of a theme controller, indicates that it should use the default application theme.

 
Public FieldThe empty theme name id.

When assigned to the "Theme" extender property (provided by C1ThemeController) on a control, indicates that no theme should be applied to that control by the theme controller.

 
Top
Public Properties
 NameDescription
Public Propertystatic (Shared in Visual Basic)Gets or sets the application-wide default theme name.

All theme controllers which have "(default)" set as Theme property value will use this theme.

This name is persisted with key "C1ApplicationTheme" in the application config file (app.config).

 
Public Propertystatic (Shared in Visual Basic)  
Public Property (Inherited from System.ComponentModel.Component)
Public Property (Inherited from System.ComponentModel.Component)
Public PropertyGets or sets the name of the default theme for all objects on the form or user control managed by the current theme controller.  
Public PropertyGets or sets the default theme settings for all objects on the form or user control managed by the current theme controller.  
Top
Public Methods
 NameDescription
Public Methodstatic (Shared in Visual Basic)Recursively applies a theme to a control and its children. Controls that do not support themes are ignored (but the theme is applied to their children).  
Public Methodstatic (Shared in Visual Basic)Applies a theme to an object.

The target object must be either a C1 control supporting themes, or a standard control (such as Button, Label etc) for which basic theming is provided by this library.

 
Public Method (Inherited from System.MarshalByRefObject)
Public Method (Inherited from System.ComponentModel.Component)
Public Method (Inherited from System.MarshalByRefObject)
Public MethodGets the name of a theme set on an object by this theme controller.  
Public Methodstatic (Shared in Visual Basic)Retrieves a theme registered with the application, by its name.  
Public Methodstatic (Shared in Visual Basic)Retrieves the names of all themes registered with the application.  
Public MethodGets the theme settings of a theme set on an object by this theme controller.  
Public Method (Inherited from System.MarshalByRefObject)
Public Methodstatic (Shared in Visual Basic)Checks whether an object supports ComponentOne themes.  
Public Methodstatic (Shared in Visual Basic)  
Public Methodstatic (Shared in Visual Basic)Checks whether a theme with a specified name has been registered.  
Public Methodstatic (Shared in Visual Basic)Overloaded. Loads a theme from a stream, and registeres it for use by theme controllers in the application.

After this method completes, the theme can be set via ApplicationTheme and Theme properties.

his method throws an exception if a theme with same name has already been registered.

 
Public Methodstatic (Shared in Visual Basic)Loads all themes from an assembly, and registeres them for use by theme controllers in the current application.

This method scans all resources in the specified assembly, and selects those with names ending in ".c1theme" (case insensitive). If a theme cannot be loaded (e.g. due to a duplicate name or other error), it is skipped (i.e. no exception is thrown).

 
Public MethodSets a theme name on an object.  
Public MethodSets a theme settings on an object.  
Public Method (Inherited from System.ComponentModel.Component)
Public Methodstatic (Shared in Visual Basic)Unregisters the theme with a specified name.

This method does nothing if a matching theme could not be found.

An exception is thrown if the specified theme is currently in use.

 
Top
Public Events
 NameDescription
Public EventOccurs after a new value has been assigned to the ApplicationTheme property.  
Public EventOccurs before a new value is assigned to the ApplicationTheme property.  
Public Event (Inherited from System.ComponentModel.Component)
Public EventOccurs after a theme has been applied to an object managed by the current theme controller.

See remarks for details.

 
Public EventOccurs when a theme is about to be applied to an object managed by the current theme controller.

See remarks in ObjectThemeApplied for details.

 
Public EventOccurs after a theme on an object managed by the current theme controller has been changed.

See remarks in ObjectThemeApplied for details.

 
Public EventOccurs when a theme on an object managed by the current theme controller is about to be changed.

See remarks in ObjectThemeApplied for details.

 
Public EventOccurs after a new value has been assigned to the Theme property.  
Public EventOccurs before a new value is assigned to the Theme property.  
Top
See Also

Reference

C1ThemeController Class
C1.Win.C1Themes Namespace