ios - UIButton with background image and title using auto layout -


i face problem when using uibutton. have background image designed others this: background image , need place title button right after white vertical bar in background image. tried set left edge content since used auto layout, frame different different screen size(3.5", 4.7"...). there way put text in position related background want auto layout. thanks

i split left side of background image right side. way can have 2 uibuttons next each other horizontal space constraint of 0. right side of button have placed inside uiimageview can set image property of view rather button's background. don't have of course, prefer solution easier manage across different screen sizes.

here visual representation of explained above: separated views single uibutton

you need route touch events of both buttons run same method or function, both right side , left clickable.

note: i'm not sure had in mind highlighting of button, have tested , adapted desired effect.


Comments

Popular posts from this blog

sql - VB.NET Operand type clash: date is incompatible with int error -

SVG stroke-linecap doesn't work for circles in Firefox? -

python - TypeError: Scalar value for argument 'color' is not numeric in openCV -