BidiMode
From Free Pascal wiki
Jump to navigationJump to searchPhase 1: Add BidiMode property to TControl
TBidiMode already declaired in Classes
property BiDiMode: TBiDiMode read FBiDiMode write SetBiDiMode stored IsBiDiModeStored; property ParentBiDiMode: Boolean read FParentBiDiMode write SetParentBiDiMode default True;
BidiMode must not stored if ParentBidiMode = True
function TControl.IsBiDiModeStored: Boolean; begin Result := not ParentBiDiMode; end;
Add virtual functions
function IsRightToLeft:Boolean; virtual; function UseRightToLeftAlignment: Boolean; virtual; function UseRightToLeftReading: Boolean; virtual; function UseRightToLeftScrollBar: Boolean; virtual; BiDiMode property in public and must published in every control need to RightToLeft
In delphi there is UseRightToLeftAlignment and UseRightToLeftReading and UseRightToLeftScrollBar but there is a Alignment property in TLabel, TEdit not have but we can implement an Alignment so i will not use this technique for now.