Mega Code Archive

 
Categories / Delphi / Examples
 

Display text in any angle

The following works only with TrueType fonts: var LogFont : TLogFont; ... GetObject(Canvas.Font.Handle, SizeOf(TLogFont), @LogFont); // in 1/10 degrees, 450 = 45 degrees LogFont.lfEscapement := Angle*10; Canvas.Font.Handle := CreateFontIndirect(LogFont);