[Overview][Constants][Types][Classes][Procedures and functions][Variables][Index] Reference for unit 'Controls' (#lcl)

TControl.Font

The font to be used for text display in this control.

Declaration

Source position: controls.pp line 1814

public property TControl.Font : TFont
  read FFont
  write SetFont
  stored IsFontStored;

Description

Font is a TFont property with the typeface and display attributes used for textual values on the control. Use properties in the TFont instance to change attributes like Name (for the typeface), Charset, Color, Height, Orientation (rotation degrees), Pitch, Quality, Size, and Style. Assigning a new TFont instance to the property causes the control to be redrawn.

Remark: Some Font attributes may be ignored in TControl descendants. It depends on the drawing style for the specific control, and whether theme services are enabled for text on the control.
Remark: For the macOS Carbon widgetset, Font does not support use of the fsStrikeOut attribute in its Style property.

The PixelsPerInch property in Font is used to perform font size scaling in methods like Scale96ToFont, ScaleFontTo96, ScaleScreenToFont, and ScaleFontToScreen.

See also

TFont

  

Represents a font used to draw text in an application.


Version 3.2 Generated 2024-02-25 Home