SftTree/DLL 6.0

SFTTREE_CONTROL

Softel vdm, Inc.

The SFTTREE_CONTROL structure is used with GetControlInfo and SetControlInfo to retrieve and set a tree control's color attributes.

typedef struct tagSftTreeControl {

    /* Modifiable fields */
    int cbSize; // structure size

    BOOL fGridHorizontalFull;         // full width horizontal lines (when grid lines enabled)
    int iMouseOverTransitionEffect;   // enable expand/collapse button transition effect when the mouse enters/leaves the tree control
    int nCharSearchMaxInterval;       // interval after which search starts over, if there are no characters typed 
    SFT_PICTURE ButtonExpanded;       // Expand/collapse button images
    SFT_PICTURE ButtonCollapsed;
    SFT_PICTURE ButtonExpandedDown;
    SFT_PICTURE ButtonCollapsedDown;
    SFT_PICTURE ButtonExpandedHot;
    SFT_PICTURE ButtonCollapsedHot;

    /* read/only fields */
    int errorValue; // last GetControlInfo error value

} SFTTREE_CONTROL, * LPSFTTREE_CONTROL;

typedef const SFTTREE_CONTROL * LPCSFTTREE_CONTROL;

Members

cbSize

This field must be set to the SFTTREE_CONTROL structure size before calling GetControlInfo and SetControlInfo otherwise the call will fail.

fGridHorizontalFull

Defines whether horizontal grid lines extend into the empty area next to the last column. An empty area is only available if the last column is not an open-ended column. Set to TRUE so grid lines extend into the empty area next to the last column, otherwise FALSE. This value can be modified using SetControlInfo.

iMouseOverTransitionEffect

Defines whether transition effects for expand/collapse buttons and tree lines are used when the mouse enters/leaves the tree control. Expand/collapse buttons and tree lines must be suitably defined to be visible (using SetShowButtons, SetShowButton0 and SetTreeLineStyle), otherwise this setting has no effect. A gradual, visual transition is used to show/hide the expand/collapse buttons and tree lines. GDI+ support is required for transition effects, otherwise iMouseOverTransitionEffect is ignored.

One value of the following table can be assigned to the iMouseOverTransitionEffect member.

iMouseOverTransitionEffect

Transition effect

SFTTREE_TRANSITION_NONE

No transition effects are used.

SFTTREE_TRANSITION_THEMEDVISTAONLY_NOFOCUS

Transition effects are used on Windows Vista (and up) only, when Windows themes are used. When the tree control does not have the input focus and the mouse cursor enters the tree control area, the expand/collapse buttons and tree lines become visible. When the mouse cursor leaves the tree control area, they are hidden.

SFTTREE_TRANSITION_THEMEDVISTAONLY

Transition effects are used on Windows Vista (and up) only, when Windows themes are used. When the mouse cursor enters the tree control area, the expand/collapse buttons and tree lines become visible. When the mouse cursor leaves the tree control area, they are hidden.

SFTTREE_TRANSITION_ALWAYS_NOFOCUS

Transition effects are on all operating systems. When the tree control does not have the input focus and the mouse cursor enters the tree control area, the expand/collapse buttons and tree lines become visible. When the mouse cursor leaves the tree control area, they are hidden.

SFTTREE_TRANSITION_ALWAYS

Transition effects are on all operating systems. When the mouse cursor enters the tree control area, the expand/collapse buttons and tree lines become visible. When the mouse cursor leaves the tree control area, they are hidden.

Information specific to SftTree/DLL Windows Mobile EditionWindows Mobile Edition:  iMouseOverTransitionEffect is not supported.

This value can be modified using SetControlInfo.

nCharSearchMaxInterval

Defines the interval in milliseconds, after which a search starts again if there is no character input. The default is 1000 (1 second). The exact search method is defined using CharSearchMode. This value can be modified using SetControlInfo.

ButtonExpanded

Defines the image used as the expand/collapse button for all expanded parent items. User-defined expand/collapse button images are only used if the SetButtons(SFTTREE_BUTTON_USERDEF) is in effect and at least ButtonExpanded and ButtonCollapsed define valid images. Use Sft_ClearPicture to omit the user-defined button image. This value can be modified using SetControlInfo.

ButtonCollapsed

Defines the image used as the expand/collapse button for all collapsed parent items. User-defined expand/collapse button images are only used if the SetButtons(SFTTREE_BUTTON_USERDEF) is in effect and at least ButtonExpanded and ButtonCollapsed define valid images. Use Sft_ClearPicture to omit the user-defined button image. This value can be modified using SetControlInfo.

ButtonExpandedDown

Defines the image used as the expand/collapse button for expanded parent items, when the button is pressed. User-defined expand/collapse button images are only used if the SetButtons(SFTTREE_BUTTON_USERDEF) is in effect. If ButtonExpandedDown doesn't define an image, ButtonExpanded is used instead. Use Sft_ClearPicture to omit the user-defined button image. This value can be modified using SetControlInfo.

ButtonCollapsedDown

Defines the image used as the expand/collapse button for collapsed parent items, when the button is pressed. User-defined expand/collapse button images are only used if the SetButtons(SFTTREE_BUTTON_USERDEF) is in effect. If ButtonCollapsedDown doesn't define an image, ButtonCollapsed is used instead. Use Sft_ClearPicture to omit the user-defined button image. This value can be modified using SetControlInfo.

ButtonExpandedHot

Defines the image used as the expand/collapse button for expanded parent items, when the mouse cursor is on the button. User-defined expand/collapse button images are only used if the SetButtons(SFTTREE_BUTTON_USERDEF) is in effect. If ButtonExpandedHot doesn't define an image, ButtonExpanded is used instead. Use Sft_ClearPicture to omit the user-defined button image. This value can be modified using SetControlInfo.

ButtonCollapsedHot

Defines the image used as the expand/collapse button for collapsed parent items, when the mouse cursor is on the button. User-defined expand/collapse button images are only used if the SetButtons(SFTTREE_BUTTON_USERDEF) is in effect. If ButtonCollapsedHot doesn't define an image, ButtonCollapsed is used instead. Use Sft_ClearPicture to omit the user-defined button image. This value can be modified using SetControlInfo.

errorValue

Read/only. If the SetControlInfo function fails, the errorValue member contains an error code, indicating which structure member has caused the failure:

errorValue

Invalid SFTTREE_CONTROL structure member

SFTTREE_ERR_iMouseOverTransitionEffect

iMouseOverTransitionEffect

SFTTREE_ERR_nCharSearchMaxInterval

nCharSearchMaxInterval

Comments

The SFTTREE_CONTROL structure is used with GetControlInfo and SetControlInfo to retrieve and set tree control attributes.

See Also  C/C++ API  |  CategoriesNotifications


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