Hide

SftTabs/OCX 6.5 - Tab Control for VB6

Display
Print

SftTabsTabs.DropText Property

Defines whether tab text is dropped if it doesn't fit.

Syntax

Get
VBBoolean = object.DropText As Boolean
Put
VBobject.DropText = Boolean As Boolean

object

A SftTabsTabs object.

Boolean

Defines whether tab text is dropped if it doesn't fit.

BooleanDescription
TrueTab text is dropped if it doesn't fit.
FalseTab text is always displayed.

Comments

The DropText property defines whether tab text is dropped if it doesn't fit.

If the DropText property is set to True, the tab text defined for a tab will only be visible if it can be displayed in its entirety. If it is truncated, possibly because the tab control has insufficient space to display tabs with their best width, the text is not displayed.

Important: This property should only be set to True if all tabs have been defined with a tab graphic (see Tab.Image property). Otherwise an empty tab is displayed which is not desirable.

If the tab text is dropped, the tab graphic is still visible.

Example

This example shows a resizable form with a tab control aligned to the top of its client area. As the form is resized and made smaller, the tab text is eventually dropped and only the tab graphics are visible.

Private Sub Form_Load()
    Dim TabIndex As Integer
    Dim PicObject As StdPicture
    ' make sure Form1.BorderStyle is set to 2 - Sizable
    Set PicObject = LoadPicture("...path-to-bitmap...")
    With SftTabs1
        .Align = vbAlignTop
        .Tabs.DropText = True
        For TabIndex = 0 To .Tabs.Count - 1
            Set .Tab(TabIndex).Picture = PicObject
        Next
    End With
End Sub

See Also SftTabsTabs Object | Object Hierarchy


Last Updated 08/13/2020 - (email)
© 2024 Softel vdm, Inc.