Margin Property

Applies to TestComplete 15.47, last modified on January 20, 2023

Specifies the distance in pixels between the button edge and the image displayed within the button.

Declaration

componentObj.Margin
Read-Write Property Integer
componentObj     One of the user forms components listed in the Applies To section  

Applies To

The property applies to the following components:

TcxButton

Description

Use the Margin property to position the button’s image specified by the Glyph property relative to the button edge. This property specifies the distance between the button edge and the glyph edge. For example, if the glyph is located on the left of the text (that is, Layout is “blGlyphLeft”), Margin specifies the distance between the button’s left edge and the glyph’s left edge. If the button is located at the bottom of the text, Margin means distance between the button’s bottom edge and the glyph’s left edge, and so on.

To get or set the distance between the glyph and the text, use the Spacing property.

Property Value

An integer value that specifies the distance between the button edge and the button’s glyph. The default value is -1, which means that the glyph and the text are centered within the button (the distance between the button edge and the glyph edge equals to the distance between the button’s opposite edge and the button text).

See Also

Glyph Property
Layout Property
Spacing Property

Highlight search results