Skip to main content

DevExpress v24.2 Update — Your Feedback Matters

Our What's New in v24.2 webpage includes product-specific surveys. Your response to our survey questions will help us measure product satisfaction for features released in this major update and help us refine our plans for our next major release.

Take the survey Not interested

SimpleButton.ImageToTextAlignment Property

Gets or sets how the button’s image is aligned relative to the button’s text.

Namespace: DevExpress.XtraEditors

Assembly: DevExpress.XtraEditors.v24.2.dll

NuGet Package: DevExpress.Win.Navigation

#Declaration

[Browsable(false)]
[DefaultValue(ImageAlignToText.None)]
[DXCategory("Appearance")]
[EditorBrowsable(EditorBrowsableState.Never)]
public virtual ImageAlignToText ImageToTextAlignment { get; set; }

#Property Value

Type Default Description
ImageAlignToText None

An ImageAlignToText enumeration value that specifies how the button’s image is aligned relative to the button’s text.

Available values:

Show 13 items
Name Description
None

The image isn’t aligned relative to the label’s text. The alignment of the image is specified by the label’s appearance settings.

LeftTop

The image is horizontally aligned on the left and vertically aligned at the top.

ImageAlignment_LeftTop

LeftCenter

The image is horizontally aligned on the left and vertically aligned at the center.

ImageAlignment_LeftCenter

LeftBottom

The image is horizontally aligned on the left and vertically aligned at the bottom.

ImageAlignment_LeftBottom

RightTop

The image is horizontally aligned on the right and vertically aligned at the top.

ImageAlignment_RightTop

RightCenter

The image is horizontally aligned on the right and vertically aligned at the center.

ImageAlignment_RightCenter

RightBottom

The image is horizontally aligned on the right and vertically aligned at the bottom.

ImageAlignment_RightBottom

TopLeft

The image is vertically aligned at the top, and horizontally aligned on the left.

ImageAlignment_TopLeft

TopCenter

The image is vertically aligned at the top, and horizontally aligned at the center.

ImageAlignment_TopCenter

TopRight

The image is vertically aligned at the top, and horizontally aligned on the right.

ImageAlignment_TopRight

BottomLeft

The image is vertically aligned at the bottom, and horizontally aligned on the left.

ImageAlignment_BottomLeft

BottomCenter

The image is vertically aligned at the bottom, and horizontally aligned at the center.

ImageAlignment_BottomCenter

BottomRight

The image is vertically aligned at the bottom, and horizontally aligned on the right.

ImageAlignment_BottomRight

#Remarks

In addition to the button’s text (see SimpleButton.Text), you can display an image in the button. Use the SimpleButton.ImageOptions property to display an image in a button and specify image-related settings.

Use the SimpleButton.ImageOptions.ImageToTextAlignment property to align the image relative to the button’s text. If this property is set to None, the image is aligned based on the SimpleButton.ImageOptions.Location setting.

See Also