zoukankan      html  css  js  c++  java
  • UiImageView控件属性

    UIImageView控件属性:
    
    
    
    1.Image 设置图片,默认显示
    
     UIImageView *_imageView = [[UIImageView alloc]init];
    
    
    
    _imageView.image = [UIImage imageNamed:@"me.png"];
    
    
    
    
    
    2.highlightedImage 设置高亮状态下显示的图片
    
    _imageView.highlightedImage = [UIImage imageNamed:@"other.png"];
    
    
    
    3.animationImages 设置序列帧动画的图片数组
    
     [_imageView setAnimationImages:[NSArray array]];
    
    4.highlightedAnimationImages 设置高亮状态下序列帧动画的图片数组
    
    [_imageView setHighlightedAnimationImages:[NSArray array]];
    
    
    
    5.animationDuration 设置序列帧动画播放的时常
    
    [_imageView setAnimationDuration:0.3f];
    
    6.animationRepeatCount 设置序列帧动画播放的次数
    
    [_imageView setAnimationRepeatCount:2];
    
    7.userInteractionEnabled 设置是否允许用户交互,默认不允许用户交互
    
    [_imageView setUserInteractionEnabled:YES];
    
    
    
    8.highlighted 设置是否为高亮状态,默认为普通状态
    
    _imageView.highlightedImage = [UIImage imageNamed:@"other.png"];
    
    [_imageView setHighlighted:YES];
    
    注意的是在highlighted状态下设置的图片与序列帧动画要显示,必须同时设置UIImageView的状态为highlighted。
  • 相关阅读:
    C#中使用MATLAB
    各种插值法及效果图对比
    Visual Studio中你所不知道的智能感知
    C#中使用Surfer
    XCode中连接使用GitHub
    个人作业Week1
    个人作业Week3
    个人作业Week2
    第一次作业——subway
    执行ajax加载页面中的js总结
  • 原文地址:https://www.cnblogs.com/pocket-mood/p/4331242.html
Copyright © 2011-2022 走看看