Control Name | Unit | Class |
GIF Animation Control | GIFCtrl | TRxGIFAnimator |
Description:
The TRxGIFAnimator
control can display animated GIF images on the form on which it
is placed. The animated image is stored in the Image property. It
is possible to define number of a frame displayed in the present
moment, in runtime on value of property FrameIndex. You can also
set this value in the designer. The property Transparent
determines, whether the component will be completely transparent
(using the TGIFImage.TransparentColor property).
Control also includes properties similar to the TImage's properties. Set Animate property to True to start animation. The OnStart event is generated when the animation started. The OnStop event is generated when the property Active sets to False.
See also:
RX
ANI file
(TAnimatedCursorImage) and RX Animate (TAnimatedImage),
Standard
Gif (TRxGif).
Property
Animate
Declaration:
Animate: Boolean;
Animate indicates whether the animation control is playing the GIF clip. Set Animate to True to cycle through the frames specified by the Image property. Set Animate to False to interrupt the animation control when it is playing the GIF clip. For continuous sequencing of frames, set the Loop property to True.
Property
FrameIndex
Declaration:
FrameIndex: Integer;
The FrameIndex property stores the frame number of the frame currently displayed. It can be set to the frame number which needs to be displayed. Before using this property, ensure that the GIF image is properly loaded into the Image property. While setting this property, if the value is within the acceptable range (between 0 and the number of frames in the animation, i.e. TGIFImage.Count - 1) then the current frame display is changed and an OnFrameChanged event is generated.
Property
Image
Declaration: Image:
TGIFImage;
The Image property holds the GIF clip (animated image in GIF89 format).
Property
Loop
Declaration:
Loop: Boolean;
This property determines whether the GIF animation sequence should be repeated or not when all the frames are displayed. When set to True (default value) and the component runs out of frames, the FrameIndex property is reset to 0. When Loop property if set to False and the component runs out of frames, the FrameIndex property holds the number of the last displayed frame and the OnStop event is generated.
When the Loop is True use the Animate property to interrupt the animation.
Property
Transparent
Declaration:
Transparent: Boolean;
Set Transparent to True to replace the background color stored in the GIF file with the parent's background. Set Transparent to False to display the background color stored in the GIF clip.
Event
OnFrameChanged
Declaration:
OnFrameChanged: TNotifyEvent;
The OnFrameChanged event is generated for every change in the display of frames. The new frame number can be obtained from the FrameIndex property.
Index Page | About | Download
Creation Date: 4 Feb 1998 | Last Update: 16 Mar 2000