Advertisement
Guest User

Untitled

a guest
Dec 22nd, 2014
150
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.75 KB | None | 0 0
  1. for(int i=1;i<6;i++)
  2. {
  3. questButton=[UIButton new];
  4. for (int j=1; j<4; j++)
  5. {
  6. [questButton setFrame:CGRectMake(x, y, 30, 30)];
  7. [questButton setTitle:[NSString stringWithFormat:@"Q%d",i] forState:UIControlStateNormal];
  8. [questButton setTag:i];
  9.  
  10. [self.questionBtnArray addObject:questButton];
  11.  
  12. questButton.backgroundColor = [[UIColor blackColor] colorWithAlphaComponent:0.4f];
  13. [questButton release];
  14. x=x+40;
  15. }
  16. NSLog(@" button frame for %d button is :- %@",i,NSStringFromCGRect(questButton.frame));
  17. y=y+40;
  18. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement