【发布时间】:2012-09-28 16:49:06
【问题描述】:
如何创建如图所示的圆角矩形?另外我的第二个问题是如何获得多行,如何格式化以使其成为多行,如红色矩形所示?提前致谢!
CGRect viewRect=CGRectMake(30,30,320,55);
UIView *myView=[[UIView alloc]initWithFrame:viewRect];
myView.backGroundColor=[UIColor whiteColor];
[self.view addSubview:myView]
UILabel *label=[[UILabel alloc]initwithFrame:CGRectMake(30,32,25,12)];
label.font=[UIFont fontWithName:"System" size:12];
label.textColor=[UIColor blackColor];
[self.view addSubview:label]
【问题讨论】: