View Issue Details
|ID||Project||Category||View Status||Date Submitted||Last Update|
|0001657||JEDI VCL||04 Feature Request||public||2004-04-17 01:30||2004-07-22 10:13|
|Target Version||Fixed in Version|
|Summary||0001657: Get a new style of appearing for TJvDesktopAlert|
This addressed to everybody, but mostly to Peter as he is the one who created that nice component.
As you already know, the fading doesn't work with D5 and C5. Moreover, even if it is compiled in the application, it won't work under windows before Windows 2000.
So there is a need for an alternative method of appearing. I got the idea from Panda Antivirus which does the exact same thing, but instead of fading, it appears from the center as a growing rectangle. This is quite easy to do with regions applied to windows.
However, I don't really have time to think about the way to implement this nicely, so I just launch the idea in the air, hoping that someone will grasp it <g>.
|Tags||No tags attached.|
It should work with D5 as long as the OS supports it (W2k+)
Do you have any example code to look at regarding using regions to grow the form?
I am thinking that maybe AnimateWindow might be used instead...
This should work under Windows from NT3.51 and 95 up to the latest version.
There shouldn't be much to modify for Linux, provided there is a way to apply regions to a window.
procedure GrowFromCenter(AForm: TForm; Appear: Boolean=True);
XGrowth, YGrowth: Integer;
// The number of growth steps should be determined from the
// duration of appearing (disappearing) animation
growthSteps := 50;
// determine the growth rate for X and Y directions
XGrowth := AForm.Width div growthSteps;
YGrowth := AForm.Height div growthSteps;
if Appear then
RegionRect := TRect(0,0,0,0);
AppearFactor := 1;
RegionRect := TRect(0,0,AForm.Width,AForm.Height);
AppearFactor := -1;
for i := 0 to growthSteps-1 do
Region := CreateRectRgnIndirect(@RegionRect);
SetWindowRgn(AForm.Handle, Region, True);
// Note: According to the documentation, we don't have to destroy the region
// This of course only applies to Windows
// Grow the rectangle and keep it centered
InflateRect(RegionRect, AppearFactor*XGrowth, AppearFactor*YGrowth);
OffsetRect(RegionRect, -AppearFactor*(RegionRect.right-RegionRect.left) div 2,
-AppearFactor*(RegionRect.bottom-RegionRect.top) div 2);
edited on: 04-17-04 19:34
|Thanks for the code, I will have a look at implementing this (as well as the MSN method) ASAP|
|I won't have time to look into this issue, so someone else has to take over.|
||This is now implemented and in CVS. Please see the comments in changelog.txt at the root of the source tree.|
|2004-04-17 01:30||obones||New Issue|
||Note Added: 0003921|
|2004-04-17 19:05||obones||Note Added: 0003924|
|2004-04-17 19:34||obones||Note Edited: 0003924|
||Note Added: 0003926|
||Assigned To||=> user72|
||Status||new => assigned|
||Note Added: 0004630|
||Assigned To||user72 =>|
||Status||assigned => acknowledged|
|2004-07-05 00:38||obones||Status||acknowledged => assigned|
|2004-07-05 00:38||obones||Assigned To||=> obones|
|2004-07-22 10:13||obones||Status||assigned => resolved|
|2004-07-22 10:13||obones||Resolution||open => fixed|
|2004-07-22 10:13||obones||Note Added: 0004800|