Softelvdm.Controls Class Library for Windows Controls 1.0

ButtonPartClass Constructor

Softel vdm, Inc.

Initializes a new instance of the ButtonPartClass class.

Syntax      ButtonPartClass Class (Softelvdm.Controls)

VB   

Public Sub New()
Public Sub New( _
     ByVal Pressed As Boolean, _
     ByVal HAlign As HAlignmentOptionalEnum, _
     ByVal VAlign As VAlignmentOptionalEnum, _
     ByVal Enabled As Boolean, _
     ByVal Toggle As Boolean, _
     ByVal Style As GadgetAppearanceEnum, _
     ByVal Image As Image, _
     ByVal Text As String, _
     ByVal TextFont As Font, _
     ByVal ForeColor As Color )

C#   

public ButtonPartClass();
public ButtonPartClass(
     bool Pressed,
     HAlignmentOptionalEnum HAlign,
     VAlignmentOptionalEnum VAlign,
     bool Enabled,
     bool Toggle,
     GadgetAppearanceEnum Style,
     Image Image,
     string Text,
     Font TextFont,
     Color ForeColor );

C++   

public: ButtonPartClass();
public: ButtonPartClass(
     bool Pressed,
     HAlignmentOptionalEnum HAlign,
     VAlignmentOptionalEnum VAlign,
     bool Enabled,
     bool Toggle,
     GadgetAppearanceEnum Style,
     Image^ Image,
     String^ Text,
     Font^ TextFont,
     Color ForeColor );

Enabled

Defines whether the button is enabled (Enabled property). A disabled button cannot be clicked and appears grayed.

ForeColor

Defines the button's text color (ForeColor poperty).

HAlign

Defines the horizontal alignment (HAlign property) within the part's available space.

HAlignmentOptionalEnum

Value

Description

Left

0

The contents are left aligned within the available space.

Center

1

The contents are centered within the available space.

Right

2

The contents are right aligned within the available space.

Default

-1

The default value is determined by a containing object or by the environment.

Image

Defines the button image (Image property).

Pressed

Defines whether the button is currently pressed (Pressed property).

Style

Defines the button appearance (Appearance property).

GadgetAppearanceEnum

Value

Description

Default

0

The 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.

System

1

The gadget has an appearance that mimics the current operating system, but does not use themes, even if these are enabled by the operating system.

ThemedAppearance

2

The gadget emulates an appearance that mimics Windows XP themes, even on operating systems that do not offer themes.

ThemedSystem

3

The 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.

Plain

4

The gadget has no particular appearance and is completely defined by its own attributes.

Text

Defines the button's text (Text property).

TextFont

Defines the button's text font (Font property) or null/Nothing to use the default font.

Toggle

Defines whether the button is a toggle button (Toggle property). A toggle button remains pressed once it is clicked.

VAlign

Defines the vertical alignment (VAlign property) within the part's available space.

VAlignmentOptionalEnum

Value

Description

Top

0

The contents are aligned with the top of the available space.

Center

1

The contents are vertically centered within the available space.

Bottom

2

The contents are aligned with the bottom of the available space.

Default

-1

The default value is determined by a containing object or by the environment.

Comments

The ButtonPartClass constructor initializes a new instance of the ButtonPartClass class.

Version Information

Supported in version 1.0.
Products Table


Feedback / comments / error reports for this topic
© 2007 - Softel vdm, Inc. - www.softelvdm.com