Hide

SftTree/NET 2.0 - Tree Control for Windows Forms

Display
Print

GadgetAppearanceEnum Enumeration

Defines the basic appearance of a gadget.

Class: (none)
Namespace: Softelvdm.Controls
Assembly: Softelvdm.SftTreeNET

Syntax

public enum GadgetAppearanceEnum;
Public Enum GadgetAppearanceEnum

Values

NameDescription
DefaultThe gadget has an appearance which is determined by a containing object or by the environment. If no containing object or environmental information is available, GadgetAppearanceEnum.Default is identical to GadgetAppearanceEnum.ThemedSystem.
SystemThe gadget has an appearance that mimics the current operating system, but does not use themes, even if these are enabled by the operating system.
ThemedAppearanceThe gadget emulates an appearance that mimics Windows XP themes, even on operating systems that do not offer themes.
ThemedSystemThe gadget has an appearance that mimics the current operating system. For example, on Windows XP (and above), Windows themes would be used if these are enabled by the operating system. When Windows themes are used, certain color related properties no longer take effect, because the rendering is determined by the theme.
PlainThe gadget has no particular appearance and is completely defined by its own attributes.

Comments

Defines the basic appearance of a gadget.

Gadgets can change appearance based on an overall desired style or based on the operating system.

Examples

C#

            cell.Image = img;
            ip = (ImagePartClass) cell.Parts[0];
            ip.Action += new GenericPartClass.ActionEventHandler(ip_Action);

            // Add another item
            item = sftTree1.ItemCollection.Add();

            // Add a progressbar to the first cell
            ProgressBarPartClass pbp = new ProgressBarPartClass(0, 50, 25, 100, 12, GadgetAppearanceEnum.ThemedSystem,
                            Color.Red, Color.White, System.Drawing.Drawing2D.LinearGradientMode.Vertical);
            pbp.PartAlignment = PartAlignmentEnum.EntireArea;
            pbp.Appearance = GadgetAppearanceEnum.System;
            item.Cells[0].Parts.Add(pbp);

            // Add a button to the second cell
            ButtonPartClass bp = new ButtonPartClass(false, HAlignmentOptionalEnum.Default, VAlignmentOptionalEnum.Default,

VB.NET

    cell.Image = img
    ip = cell.Parts(0)
    AddHandler ip.Action, AddressOf ip_Action

    ' Add another item
    item = sftTree1.ItemCollection.Add()

    ' Add a progressbar to the first cell
    Dim pbp As ProgressBarPartClass = New ProgressBarPartClass(0, 50, 25, 100, 12, GadgetAppearanceEnum.ThemedSystem, _
                Color.Red, Color.White, System.Drawing.Drawing2D.LinearGradientMode.Vertical)
    pbp.PartAlignment = PartAlignmentEnum.EntireArea
    pbp.Appearance = GadgetAppearanceEnum.System
    item.Cells(0).Parts.Add(pbp)

    ' Add a button to the second cell
    Dim bp As ButtonPartClass = New ButtonPartClass(False, HAlignmentOptionalEnum.Default, VAlignmentOptionalEnum.Default, _

See Also | Classes | SftTree/NET 2.0