在Delphi XE 3种形式的gif动画 [英] Animated gif in Delphi XE 3 forms

查看:2268
本文介绍了在Delphi XE 3种形式的gif动画的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

可能重复:结果
  如何使用Gif动​​画德尔福形式

我最近更新我的版本的 Delphi 7中德尔福XE3

I recently updated my version of Delphi 7 to Delphi XE3.

用Delphi 7,我用一个组件把一个GIF上的TImage,德尔福XE3已经与GIF的兼容性,无需安装任何额外的第三方组件。

Using Delphi 7, I used a component to put a GIF on a TImage, delphi XE3 already has compatibility with gif's, it is not necessary to install any additional third party components.

我的问题是:当我附上的GIF TImate,就变成静态的,只显示第一帧

my question is: when I attach the gif to TImate, it becomes static, shows only the first frame.

是对此有任何命令?像Image1.Play什么?

is there any command for this? like Image1.Play or something?

推荐答案

要获得动画开始这样做:

To get the animation started do like this:

(Image1.Picture.Graphic as TGIFImage).AnimateLoop := glEnabled;
(Image1.Picture.Graphic as TGIFImage).Animate := true;

要控制动画的速度,设置0 .. 1000之间的 AnimationSpeed​​ 属性,默认值是100。

To control the animation speed, set the AnimationSpeed property between 0..1000, default value is 100.

又见@ DavidHeffernan的回答,请如何使用Gif动​​画德尔福形式

See also @DavidHeffernan's answer, How to use Animated Gif in a delphi form

这篇关于在Delphi XE 3种形式的gif动画的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆