ios - UIView returning wrong values for height with AutoLayout -


i have custom uiview draws "ring" progress of cashaplelayerand uibezierpath. when drawing bezier path view want draw center of view. view has auto layout contrains leading , trailing it's superview , aspect ration 1:1 (so it's perfect square).

my first idea i'll sizes (height , width) of view, divide 2, make cgpoint , use bezier path. logic return exact middle of view wouldn't it?

apparently not. in log view returns 497 height , width, view debugger tells me it's 303 , view looks this:

totally wrong calayer

has , idea why happening?


Comments

Popular posts from this blog

gcc - MinGW's ld cannot perform PE operations on non PE output file -

How to connect android app to App engine -

hadoop - Running Map Reduce Job shows error - Mkdirs failed to create /var/folders/ -