Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 7766973
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 1, 20262026-06-01T15:33:32+00:00 2026-06-01T15:33:32+00:00

I am trying to create a text field in objective-c with a big corner

  • 0

I am trying to create a text field in objective-c with a big corner radius, like the searchField in iOS.
In my xib i have added a UITextField.
I style the textfield in objective-C like this:

// corner radius
textField.layer.cornerRadius = 20.0f;
textField.layer.masksToBounds = YES;
textField.backgroundColor = [UIColor clearColor];

[textField setFont:[UIFont fontWithName:@"Univers-Condensed-Medium" size:18.0]];

Result: The corners of the input are not visible, some white background overlays these.
You can see the problem in this image:

Screenshot of the problem

I have tried several things like:

textField.leftView.opaque = NO;
textField.leftView.backgroundColor = [UIColor clearColor];

textField.inputView.opaque = NO;
textField.inputView.backgroundColor = [UIColor clearColor];

textField.rightView.opaque = NO;
textField.rightView.backgroundColor = [UIColor clearColor];

I even added an icon (just for testing) all gave the same result.
What do I need to do to make the corners visible?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-01T15:33:33+00:00Added an answer on June 1, 2026 at 3:33 pm

    I had done some test and no white background overlaps, it is just this way the textfield look like when you change the corner radius. Try to change the background color of the UIView that the textfield is inside, and see that it will be always this way.

    Unfortunately, if you want to change the cornerRadius and want it to be displayed in the way you posted here, maybe you need to use some background image, I do not know.

    If I was you I will use the textField without the cornerRadius.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I am trying to create a search text-field like on the Apple website .
I am trying to create a basic search function. I have a text field
I'm trying to create a new div each time a text field contained in
I am trying to create a rich text editor. I have created some buttons
I am trying to create a text input field that converts the input text
I'm trying to create a a button to add a text field to a
I'm trying to create a button linked to a text field that will let
I'm trying to create an editable text field in a page which highlights the
I'm trying to create a simple text field for WYSIWYG editing. However, I only
I'm trying to create text in html, that once clicked, the the value of

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.