Text Field Border is not coming in only IPad2, In IPad Air or Resizable Ipad it is coming

126 Views Asked by At

In Ipad2 it is coming like this

In Ipad Air it is coming like this

I am running this app in simulator and in ipad2 and ipad air the style is coming different. Also tested in device same thing is happening. Any Idea how to fix this?

Code Snippet: 
answerField.layer.borderWidth = 0.5
3

There are 3 best solutions below

1
Aanabidden On BEST ANSWER

try by increasing textbox borderwidth by 1px.

1
Simon Degn On

This is a guess, but could it be that some of the simulators are running an older version of your app? Then you should go to "iOS Simulator" -> "Reset Content and Settings..." in the simulators that don't work for you.

0
Joshua On

maybe you can try like this:

#define BorderScaleWidth(width) [[UIScreen mainScreen] scale] > 2.0 ? width / [[UIScreen mainScreen] scale] : width

It will give you correct width.