图像和带有Flex的BitmapImage之间的区别? [英] Differences between Image and BitmapImage with Flex?

查看:121
本文介绍了图像和带有Flex的BitmapImage之间的区别?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

Image 的asdoc中,我们可以看到:

lockquote

包括BitmapImage类。这个类用于将图像嵌入到皮肤和FXG组件中。

但是我们也可以使用 Image 在皮肤中使用 @Embed 图片 ...



因此,我应该在何时何地使用 Image 或 BitmapImage ? b $ b

解决方案 是一个可换肤的类,它封装了 BitmapImage 。由于这样的BitmapImage更轻量级,但图像具有更多的功能。那么什么时候使用的问题可以归结为:如果BitmapImage的功能足够,使用它
;否则使用Image。特别是在移动环境中,尝试使用BitmapImage。



现在有什么功能可以完全添加图像?



  • 图像扩展了SkinnableComponent:这意味着您可以在整个应用程序中一直使用边框或阴影或任何您喜欢的任何图像来指定图像。

  • 它还提供了一个进度指示器,可以在图像加载时显示。

  • 另外一个功能是可以使用将多个图像加载到队列中。


In Image's asdoc, we can see :

Flex also includes the BitmapImage class. This class is used for embedding images into skins and FXG components

but we can also use Image in skins and use @Embed with Image...

Therefore, where and when should I use Image or BitmapImage please ?

解决方案

Image is a skinnable class that wraps BitmapImage. As such BitmapImage is more lightweight, but Image has more features. So the question when to use which boils down to this:
if the features of BitmapImage suffice, use that; otherwise use Image. Especially in mobile environments try to favor the use of BitmapImage.

Now what features does Image add exactly?

这篇关于图像和带有Flex的BitmapImage之间的区别?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

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