用图片绘制按钮

/*  

UIButton *backButton = [UIButton buttonWithType:101];

[backButton addTarget:self action:@selector(toolsAction) forControlEvents:UIControlEventTouchUpInside];

backButton.frame = CGRectMake(5.0, 8.0, 18.0, 19.0);

[backButton setTitle:@"返回" forState:UIControlStateNormal];

[backButton setBackgroundImage:[UIImage imageNamed:@"190-bank.png"] forState:UIControlStateNormal];

UIBarButtonItem* backButtonItem = [[UIBarButtonItem alloc] initWithCustomView:backButton];

*/

/*

switchButton = [UIButton buttonWithType:0];

[switchButton addTarget:self action:@selector(switchButtons) forControlEvents:UIControlEventTouchUpInside];

switchButton.frame = CGRectMake(60.0, 462.0, 648.0, 100.0);

switchButton.alpha = 1.000;

switchButton.autoresizesSubviews = YES;

switchButton.autoresizingMask = UIViewAutoresizingFlexibleRightMargin | UIViewAutoresizingFlexibleBottomMargin;

*/

你可能感兴趣的:(用图片绘制按钮)