When closing Delphi 6 in Windows XP Delphi does not exit properly. It saves all files and settings but the program is still resident in memory. You have to forcefully close it. This also happens when you want to close a project and the Code Explorer is on. If you attempt this Delphi will close [...]
How to Detect Font and Text Sizes
When creating components you may want to know when the user changed the font or text. This can be quite easily done using the CM_FONTCHANGED and CM_TEXTCHANGED messages.
TComponent1 = class(TComponent)
…
private
…
procedure CMFontChanged(var Message: TMessage); message CM_FONTCHANGED;
procedure CMTextChanged(var Message: TMessage); message CM_TEXTCHANGED;
…
procedure TComponent1.CMTextChanged(var Message:TMessage);
begin
…
end;
procedure TComponent1.CMFontChanged(var Message:TMessage);
begin
…
end;
Merlin’s Delphi Forge