0

ボタン画像にアルファ値を設定するには、次のコードを試します。

UIImageView *imageTopView = [[UIImageView alloc] initWithImage:
  [UIImage imageNamed:@"Top_80.png"]];    
imageTopView.alpha = 0.5;

topBtn = [UIButton buttonWithType:UIButtonTypeCustom];

[topBtn addTarget:self action:@selector(btnRotatingObj:) 
        forControlEvents:UIControlEventTouchUpInside];

[topBtn setImage: imageTopView.image forState:UIControlStateNormal];   
    [topBtn setTitle:@"TOP" forState:UIControlStateNormal];

[self.view addSubview:topBtn];

動いていない.....

4

1 に答える 1