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

android - Why am I getting the message 'Youractivity.java is not an activity subclass or alias' -

Making Empty C++ Project: General exception (Exception from HRESULT:0x80131500) Visual Studio Community 2015 -

How to fix java warning for "The value of the local variable is not used " -