Unit 'GroupedEdit' Package
[Overview][Types][Classes][Index] [#lcl]

TCustomAbstractGroupedEdit.TextHint

Default hint text shown when the Text property is empty for the grouped edit control.

Declaration

Source position: groupededit.pp line 306

public property TCustomAbstractGroupedEdit.TextHint : TTranslateString
  read GetTextHint
  write SetTextHint;

Description

TextHint is a TTranslateString property which contains the inline hint text displayed for the control. It is displayed in the editable area for the TCustomEdit when the Text property is empty. Some platforms may refer to this feature as a "placeholder" or "editing hint". The value in TextHint is normally displayed using the color in clGrayText.

The display behavior for TextHint is platform-specific. On some platforms, the text hint is displayed any time the value in Text is empty. For others, it is displayed only when the control does not have focus.

Read and write access to the property value are redirected to the BaseEditor property. Setting a new value in TextHint causes the widgetset class to be notified, and the value is displayed in the edit control when allowed. If the new property value is an empty string (''), the text hint is removed from the control.

For platforms that do not provide native support for TextHint, an emulated text hint is displayed. This is a TCustomEdit control created to enable the feature, and can be displayed only when the original control does not have focus.

TextHint is different than Hint, which displays a balloon tip when ShowHint is set to True and the mouse is over the control.

See also

TCustomAbstractGroupedEdit.BaseEditor

  

Represents the control used as the editor for the value in the grouped edit control.

TCustomAbstractGroupedEdit.Text

  

String with the text or caption for the control.

TCustomEdit.TextHint

  

Default hint text shown when the Text property is empty for the control.

TCustomEdit.CanShowEmulatedTextHint

  

Indicates if the value in TextHint can be displayed in the edit control.

TControl.Text

  

String with the text or caption for the control.

TControl.Hint

  

The text to show in the Hint window for the control.