Class
ComponentThemableElementTree

Represents a concrete implementation of RadElementTree that provides comprehensive theming and styling capabilities for Telerik controls, managing theme application and lifecycle within the element hierarchy.

Definition

Namespace:Telerik.WinControls

Assembly:Telerik.WinControls.dll

Syntax:

cs-api-definition
public class ComponentThemableElementTree : RadElementTree, IDisposable, IThemeChangeListener

Inheritance: objectRadElementTreeComponentThemableElementTree

Implements: IDisposableIThemeChangeListener

Inherited Members RadElementTree.InitializeRootElement()RadElementTree.Dispose()RadElementTree.GetElementAtPoint<T>(Point)RadElementTree.GetElementAtPoint(Point)RadElementTree.GetElementAtPoint(Point, Predicate<RadElement>)RadElementTree.GetPreferredSize(Size, Size)RadElementTree.PerformLayout()RadElementTree.PerformInnerLayout(bool, int, int, int, int)RadElementTree.OnAutoSizeChanged(EventArgs)RadElementTree.DisposingRadElementTree.RootElementRadElementTree.ControlRadElementTree.ComponentTreeHandlerRadElementTree.TreeNameRadElementTree.IsLayoutSuspended

Constructors

ComponentThemableElementTree(IComponentTreeHandler)

Declaration

cs-api-definition
public ComponentThemableElementTree(IComponentTreeHandler owner)

Parameters

owner

IComponentTreeHandler

Properties

AnimationsEnabled

Gets value indicating whether the animated property changes are suspended for the control. Also see SuspendAnimations().

Declaration

cs-api-definition
public bool AnimationsEnabled { get; }

Property Value

bool

EnableApplicationThemeName

Declaration

cs-api-definition
[Browsable(true)]
public bool EnableApplicationThemeName { get; set; }

Property Value

bool

EnableTheming

Declaration

cs-api-definition
public bool EnableTheming { get; set; }

Property Value

bool

FallbackToControlDefault

Gets or sets a value indicating whether to fallback to control default theme if the control does not support the current theme.

Declaration

cs-api-definition
[Browsable(false)]
public bool FallbackToControlDefault { get; set; }

Property Value

bool

Theme

Gets the currently used theme.

Declaration

cs-api-definition
public Theme Theme { get; }

Property Value

Theme

ThemeClassName

Gets or sets the class name string that ThemeResolutionService will use to find the themes registered for the control.

Declaration

cs-api-definition
public virtual string ThemeClassName { get; set; }

Property Value

string

Remarks

By default the return value is RadControl's type FullName; Some controls like drop down menu has different ThemeClassName depending on the runtime usage of the control.

ThemeName

Gets or sets control's preffered theme name. Themes are stored and retrieved using APIs of ThemeResolutionService.

Declaration

cs-api-definition
[Browsable(true)]
public string ThemeName { get; set; }

Property Value

string

Remarks

If ThemeResolutionService.ApplicatonThemeName refers to a non-empty string, the theme of a RadControl can differ from the one set using RadControls.ThemeName property. If the themes differ, the RadControls.ThemeName property will be overridden by ThemeResolutionService.ApplicatonThemeName. If no theme is registered with a name as ThemeResolutionService.ApplicatonThemeName, then control will revert to the theme specified by its ThemeName property. If ThemeName is assigned to a non-existing theme name, the control may have no visual properties assigned, which will cause it look and behave in unexpected manner. If ThemeName equals empty string, control's theme is set to a theme that is registered within ThemeResolutionService with the name "ControlDefault".

Methods

Dispose(bool)

Releases the unmanaged resources used by the RadElementTree and optionally releases the managed resources.

Declaration

cs-api-definition
protected override void Dispose(bool disposing)

Parameters

disposing

bool

true to release both managed and unmanaged resources; false to release only unmanaged resources.

Overrides RadElementTree.Dispose(bool)

ResumeAnimations()

Resumes the animated property changes for the conrol. For more info see SuspendAnimations()

Declaration

cs-api-definition
public void ResumeAnimations()

SuspendAnimations()

Suspends the animated property changes for the control. When animation are suspended property changes still occur but without aniumations.

Declaration

cs-api-definition
public void SuspendAnimations()