- This topic has 6 replies, 2 voices, and was last updated 10 years, 1 month ago by
Support.
-
AuthorPosts
-
January 13, 2016 at 10:04 am #54588
Hello!
You can use OnPaint event, I think, look attached example.
January 13, 2016 at 1:18 pm #54596'Support' wrote:Hello!
You can use OnPaint event, I think, look attached example.
Thanks for the reply!
When I run the demo using AC version 10.23, I get a stack overflow on line 7327 of acSBUtils:
Code:function TacMainWnd.CallPrevWndProc(const Handle: hwnd; const Msg: longint; const WParam: WPARAM; var LParam: LPARAM): LRESULT;
var
M: TMessage;
begin
if Assigned(OldWndProc) then begin
M.Msg := Msg;
M.WParam := WParam;
M.LParam := LParam;
M.Result := 0;
OldWndProc(M);
Result := M.Result;
LParam := M.LParam;
end
else
if Assigned(OldProc) then
try
Result := CallWindowProc(OldProc, Handle, Msg, WParam, LParam) <<<<<< STACK OVEREFLOW HERE
except
Result := 0;
end
else
Result := 0;
end;but it doesn't happen using version 10.22 (Delphi 7.0 Professional – build 4.453).
I noticed this affects the background of all AC components, is there a way to avoid this side-effect?
Best regards,
Ronaldo
January 13, 2016 at 1:23 pm #54598Yes, I saw this error too, when prepared this demo.
The error is fixed and new package with a fix will be available at the nearest days.
January 14, 2016 at 1:34 pm #54603'Support' wrote:Yes, I saw this error too, when prepared this demo.
The error is fixed and new package with a fix will be available at the nearest days.
Thanks!
The OnPaint approach works fine except for one detail I couldn't fix so far: the background of the statusbar (or any other component I place on the main form) is also drawn with the logo.
Thanks in advance for any help you could provide!
Ronaldo
January 15, 2016 at 6:21 am #54604I think, you can exclude this statusbar rectangle before painting, like this:
ExcludeClipRect(Canvas.Handle, sStatusBar1.Left, sStatusBar1.Top, sStatusBar1…)
January 15, 2016 at 1:46 pm #51074'Support' wrote:I think, you can exclude this statusbar rectangle before painting, like this:
ExcludeClipRect(Canvas.Handle, sStatusBar1.Left, sStatusBar1.Top, sStatusBar1…)
Works perfectly. Thanks!
Ronaldo
-
AuthorPosts
- You must be logged in to reply to this topic.