The TrackBarRenderer class provides a set of static methods that can be used to render each part of a track bar control with the current visual style of the operating system. Rendering a control refers to drawing the user interface of a control. This is useful if you are drawing a custom control that should have the appearance of the current visual style.
If visual styles are enabled in the operating system and visual styles are applied to the client area of application windows, the methods in this class will draw the track bar with the current visual style. Otherwise, the methods in this class will throw an InvalidOperationException. To determine whether the members of this class can be used, you can check the value of the IsSupported property.
This class wraps the functionality of a System.Windows.Forms.VisualStyles..::.VisualStyleRenderer that is set to one of the elements exposed by the System.Windows.Forms.VisualStyles..::.VisualStyleElement..::.TrackBar class. For more information, see Rendering Controls with Visual Styles.
Windows XP Home Edition, Windows XP Professional x64 Edition, Windows Server 2003 Platform Note:
Visual styles are supported only on these platforms.