Return to Snippet

Revision: 44251
at April 8, 2011 13:20 by peetj


Initial Code
UITextField *theTextFiels=[[UITextField alloc]initWithFrame:CGRectMake(40, 40, 150, 30)];
    theTextFiels.borderStyle=UITextBorderStyleNone;
    theTextFiels.layer.cornerRadius=8.0f;
    theTextFiels.layer.masksToBounds=YES;
        theTextFiels.backgroundColor=[UIColor redColor];
    theTextFiels.layer.borderColor=[[UIColor blackColor]CGColor];
    theTextFiels.layer.borderWidth= 1.0f;

    [self.view addSubview:theTextFiels];
    [theTextFiels release];

Initial URL
http://stackoverflow.com/questions/1861527/uitextfield-border-color

Initial Description


Initial Title
UITextField border and background

Initial Tags


Initial Language
Objective C